/**
 * Black Friday 2025 - Stili Completi v2
 * Il Covo del Nerd
 * SFONDO BLU + DIMENSIONI RIDOTTE
 */

/* =====================================================
   TOPBAR BLACK FRIDAY
   ===================================================== */

.bf-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: #1875B5;
    z-index: 9999;
    padding: 10px 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.bf-topbar-link {
    text-decoration: none;
    color: white;
    display: block;
}

.bf-topbar-link:hover {
    opacity: 0.95;
}

.bf-topbar-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.bf-logo {
    width: 150px;
    height: 30px;
    object-fit: contain;
    flex-shrink: 0;
}

.bf-text {
    color: white;
    font-size: 16px;
    line-height: 1.4;
    overflow: hidden;
    text-shadow: 
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
}

.bf-text-content {
    display: inline-block;
    white-space: nowrap;
}

.bf-text strong {
    font-weight: 700;
    color: white;
    text-shadow: 
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
}

.bf-text .bf-discount {
    color: #ff0000;
    text-shadow: 
        -1px -1px 0 #fff,
        1px -1px 0 #fff,
        -1px 1px 0 #fff,
        1px 1px 0 #fff;
}

.bf-text .bf-grattaevinci {
    color: #E3B13F;
    font-weight: 700;
    text-shadow: 
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
}

/* Padding body per non coprire contenuti */
body {
    padding-top: 50px !important;
}

/* Admin Bar Compatibility */
body.admin-bar .bf-topbar {
    top: 32px;
}

/* =====================================================
   MESSAGE BOX GRATTA E VINCI - SFONDO BLU
   ===================================================== */

.bf-gratta-vinci-box {
    background: linear-gradient(135deg, #1875B5 0%, #125a8f 100%);
    border: 2px solid #E3B13F;
    border-radius: 8px;
    padding: 12px 15px;
    margin: 12px 0;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(24, 117, 181, 0.3);
    position: relative;
    overflow: hidden;
}

.bf-gratta-vinci-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(227, 177, 63, 0.1) 0%, transparent 70%);
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

/* Immagine Gratta e Vinci */
.bf-ticket-image {
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.bf-ticket-image img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 2px 6px rgba(227, 177, 63, 0.4));
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

/* Contenuto Testo */
.bf-ticket-content {
    flex: 1;
    color: #fff;
    position: relative;
    z-index: 1;
}

.bf-ticket-title {
    font-size: 14px;
    font-weight: 700;
    color: #E3B13F;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
}

.bf-ticket-text {
    font-size: 13px;
    margin-bottom: 6px;
    line-height: 1.4;
    text-shadow: 
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
}

.bf-ticket-text strong {
    color: #ffeb3b;
    font-weight: 700;
}

.bf-ticket-conditions {
    font-size: 9px;
    color: #e0e0e0;
    line-height: 1.5;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-style: italic;
}

.bf-ticket-conditions strong {
    color: #fff;
    font-style: italic;
}

/* Link Premi */
.bf-link-premi {
    margin-top: 8px;
    font-size: 9px;
    text-align: center;
}

.bf-link-premi a {
    color: #fff !important;
    text-decoration: underline;
    font-style: italic;
    font-weight: 400;
    transition: opacity 0.3s;
}

.bf-link-premi a:hover {
    opacity: 0.8;
}

/* =====================================================
   RESPONSIVE DESKTOP
   ===================================================== */

@media (min-width: 769px) {
    /* Message Box - Carrello */
    .bf-box-cart {
        padding: 15px 20px;
        gap: 20px;
    }
    
    .bf-box-cart .bf-ticket-image img {
        width: 100px;
        height: 100px;
    }
    
    .bf-box-cart .bf-ticket-title {
        font-size: 16px;
    }
    
    .bf-box-cart .bf-ticket-text {
        font-size: 14px;
    }
    
    .bf-box-cart .bf-ticket-conditions {
        font-size: 10px;
    }
    
    /* Message Box - Pagina Prodotto */
    .bf-box-product {
        max-width: 550px;
    }
}

/* =====================================================
   RESPONSIVE TABLET
   ===================================================== */

@media (max-width: 768px) {
    /* TopBar */
    .bf-topbar {
        padding: 8px 10px;
    }
    
    .bf-topbar-content {
        gap: 10px;
    }
    
    .bf-logo {
        width: 130px;
        height: 30px;
    }
    
    .bf-text {
        font-size: 14px;
        flex: 1;
        min-width: 0;
    }
    
    .bf-text-content {
        animation: scroll-text 15s linear infinite;
        padding-left: 100%;
    }
    
    @keyframes scroll-text {
        0% {
            transform: translateX(0);
        }
        100% {
            transform: translateX(-100%);
        }
    }
    
    body {
        padding-top: 40px !important;
    }
    
    /* Admin Bar */
    body.admin-bar .bf-topbar {
        top: 46px;
    }
    
    /* Message Box */
    .bf-gratta-vinci-box {
        flex-direction: column;
        text-align: center;
        padding: 12px;
        gap: 12px;
    }
    
    .bf-ticket-image img {
        width: 70px;
        height: 70px;
    }
    
    .bf-ticket-title {
        font-size: 13px;
    }
    
    .bf-ticket-text {
        font-size: 12px;
    }
    
    .bf-ticket-conditions {
        font-size: 9px;
    }
}

/* =====================================================
   RESPONSIVE MOBILE
   ===================================================== */

@media (max-width: 480px) {
    /* TopBar */
    .bf-topbar {
        padding: 6px 8px;
    }
    
    .bf-logo {
        width: 130px;
        height: 30px;
    }
    
    .bf-text {
        font-size: 12px;
    }
    
    /* Message Box */
    .bf-gratta-vinci-box {
        padding: 10px;
        gap: 10px;
    }
    
    .bf-ticket-image img {
        width: 60px;
        height: 60px;
    }
    
    .bf-ticket-title {
        font-size: 12px;
    }
    
    .bf-ticket-text {
        font-size: 11px;
    }
    
    .bf-ticket-conditions {
        font-size: 9px;
    }
    
    .bf-link-premi {
        font-size: 8px;
    }
}

/* =====================================================
   MINI CART SPECIFICO
   ===================================================== */

.bf-box-minicart {
    margin: 10px 0;
    padding: 10px 12px;
}

.bf-box-minicart .bf-ticket-image img {
    width: 60px;
    height: 60px;
}

.bf-box-minicart .bf-ticket-title {
    font-size: 12px;
}

.bf-box-minicart .bf-ticket-text {
    font-size: 11px;
}

.bf-box-minicart .bf-ticket-conditions {
    font-size: 8px;
}

@media (max-width: 768px) {
    .bf-box-minicart .bf-ticket-image img {
        width: 55px;
        height: 55px;
    }
}
