/* FG-HEADERCSS: stile che stava dentro includes/header.php, spostato qui dall'installer */
/* 💝 TOP DONATION BANNER */
    .donation-banner-top {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        color: white;
        padding: 12px 20px;
        text-align: center;
        font-size: 14px;
        position: sticky;
        top: 0;
        z-index: 10000;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }

    .donation-banner-content {
        max-width: 1200px;
        margin: 0 auto;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 15px;
        flex-wrap: wrap;
    }

    .donation-banner-text {
        font-weight: 500;
    }

    .donation-banner-text strong {
        font-weight: 700;
    }

    .donation-banner-btn {
        background: white;
        color: #667eea;
        padding: 8px 20px;
        border-radius: 20px;
        text-decoration: none;
        font-weight: 700;
        font-size: 13px;
        transition: all 0.3s;
    }

    .donation-banner-btn:hover {
        transform: scale(1.05);
        box-shadow: 0 4px 15px rgba(255, 255, 255, 0.3);
        color: #667eea;
        text-decoration: none;
    }

    /* 📱 MOBILE - Banner più compatto */
    @media (max-width: 768px) {
        .donation-banner-top {
            padding: 6px 15px;
            font-size: 12px;
            transition: transform 0.3s ease;
        }
        
        .donation-banner-top.hidden {
            transform: translateY(-100%);
        }
        
        .donation-banner-btn {
            padding: 6px 16px;
            font-size: 12px;
        }
    }

    /* 💻 DESKTOP - Maggiore spazio per bandiere e social */
    @media (min-width: 769px) {
        .site-header .wrap {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 40px;
        }

        .brand-container {
            display: flex;
            align-items: center;
            gap: 20px;
        }

        .main-nav {
            flex: 1;
            display: flex;
            justify-content: center;
            gap: 20px;
        }

        .header-socials {
            display: flex;
            align-items: center;
            gap: 15px;
            margin-left: auto;
        }
    }

    /* 🍔 HAMBURGER BUTTON */
    .mobile-menu-toggle {
        display: none;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 8px;
        width: 40px;
        height: 40px;
        z-index: 1001;
    }

    .mobile-menu-toggle span {
        width: 100%;
        height: 3px;
        background: #2c2c2c;
        border-radius: 2px;
        transition: all 0.3s;
    }

    .mobile-menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }

    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }

    /* 📱 MOBILE MENU */
    .mobile-menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
        transition: opacity 0.3s;
    }

    .mobile-menu-overlay.active {
        display: block;
        opacity: 1;
    }

    .mobile-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 85%;
        max-width: 400px;
        height: 100%;
        background: white;
        z-index: 1000;
        transition: right 0.3s ease;
        overflow-y: auto;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.2);
    }

    .mobile-menu.active {
        right: 0;
    }

    .mobile-menu-content {
        padding: 110px 30px 50px;
    }

    .mobile-lang-flags {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-bottom: 40px;
        padding-bottom: 30px;
        border-bottom: 2px solid #f0f0f0;
    }

    .mobile-lang-flags a {
        display: block;
        width: 50px;
        height: 38px;
        border-radius: 8px;
        overflow: hidden;
        box-shadow: 0 3px 10px rgba(0,0,0,0.2);
        transition: all 0.3s;
    }

    .mobile-lang-flags a:hover {
        transform: scale(1.1);
        box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    }

    .mobile-lang-flags img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .mobile-menu-links {
        display: flex;
        flex-direction: column;
        gap: 5px;
    }

    .mobile-menu-links a {
        padding: 16px 20px;
        color: #2c2c2c;
        text-decoration: none;
        font-size: 16px;
        font-weight: 600;
        border-radius: 12px;
        transition: all 0.3s;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-menu-links a:hover {
        background: #f5f5f5;
        transform: translateX(5px);
    }

    .mobile-menu-links .ai-chef-btn {
        background: linear-gradient(135deg, #d4705f, #b55a4a);
        color: white;
        margin: 15px 0;
        font-weight: 700;
    }

    .mobile-menu-links .ai-chef-btn:hover {
        transform: scale(1.02);
        box-shadow: 0 5px 20px rgba(212, 112, 95, 0.3);
    }

    .mobile-menu-links .donation-link {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        color: white;
        margin: 10px 0;
        font-weight: 700;
    }

    .mobile-menu-links .donation-link:hover {
        transform: scale(1.02);
        box-shadow: 0 5px 20px rgba(102, 126, 234, 0.3);
    }

    .user-greeting {
        padding: 16px 20px;
        color: #667eea;
        font-size: 15px;
        font-weight: 600;
    }

    /* 🔐 SECURITY BUTTON - 2FA */
    .security-btn {
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        color: white !important;
        padding: 8px 16px;
        border-radius: 8px;
        font-weight: 600;
        font-size: 14px;
        text-decoration: none;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        transition: all 0.3s ease;
        box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
    }

    .security-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
        color: white !important;
        text-decoration: none;
    }

    .security-btn .shield-icon {
        font-size: 16px;
    }

    /* Mobile Security Button */
    .mobile-menu-links .security-btn {
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        color: white !important;
        margin: 10px 0;
        padding: 16px 20px;
        border-radius: 12px;
        font-weight: 700;
        font-size: 16px;
        justify-content: flex-start;
    }

    .mobile-menu-links .security-btn:hover {
        transform: translateX(5px);
        box-shadow: 0 5px 20px rgba(16, 185, 129, 0.3);
        background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    }

    /* Badge 2FA non configurato */
    .security-badge {
        background: #fef3c7;
        color: #d97706;
        font-size: 10px;
        font-weight: 700;
        padding: 2px 6px;
        border-radius: 10px;
        margin-left: 5px;
        animation: pulse-badge 2s infinite;
    }

    @keyframes pulse-badge {
        0%, 100% { opacity: 1; }
        50% { opacity: 0.6; }
    }

    /* Dark mode per security button */
    body.dark-mode .security-btn {
        background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
        box-shadow: 0 2px 8px rgba(5, 150, 105, 0.4);
    }

    body.dark-mode .security-btn:hover {
        box-shadow: 0 4px 15px rgba(5, 150, 105, 0.5);
    }

    body.dark-mode .security-badge {
        background: #422006;
        color: #fbbf24;
    }

    .mobile-social-icons {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-top: 40px;
        padding-top: 30px;
        border-top: 2px solid #f0f0f0;
    }

    .mobile-social-icons a {
        width: 45px;
        height: 45px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        transition: all 0.3s;
    }

    .mobile-social-icons a.facebook { background: #1877f2; }
    .mobile-social-icons a.instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
    .mobile-social-icons a.youtube { background: #ff0000; }
    .mobile-social-icons a.tiktok { background: #000; }

    .mobile-social-icons a:hover {
        transform: scale(1.15);
        box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    }

    .mobile-social-icons svg {
        width: 22px;
        height: 22px;
    }

    .brand-container {
        display: flex;
        align-items: center;
        gap: 15px;
    }

    .desktop-lang-flags {
        display: flex;
        gap: 8px;
    }

    .desktop-lang-flags a {
        display: block;
        width: 36px;
        height: 28px;
        border-radius: 5px;
        overflow: hidden;
        box-shadow: 0 2px 6px rgba(0,0,0,0.15);
        transition: all 0.2s;
    }

    .desktop-lang-flags a:hover {
        transform: scale(1.1);
        box-shadow: 0 3px 10px rgba(0,0,0,0.25);
    }

    .desktop-lang-flags img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .header-socials {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .social-text {
        color: #2c2c2c;
        font-weight: 700;
        font-size: 14px;
    }

    .social-icon {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        transition: all 0.3s;
        text-decoration: none;
    }

    .social-icon.facebook { background: #1877f2; }
    .social-icon.instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
    .social-icon.youtube { background: #ff0000; }
    .social-icon.tiktok { background: #000; }

    .social-icon:hover {
        transform: scale(1.1);
        box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    }

    .social-icon svg {
        width: 20px;
        height: 20px;
    }

    @media (max-width: 768px) {
        .donation-banner-top {
            padding: 10px 15px;
            font-size: 13px;
        }

        .donation-banner-content {
            gap: 10px;
        }

        .donation-banner-btn {
            padding: 6px 15px;
            font-size: 12px;
        }

        .main-nav,
        .header-socials,
        .desktop-lang-flags {
            display: none !important;
        }

        .mobile-menu-toggle {
            display: flex !important;
        }
    }

    @media (min-width: 769px) {
        .mobile-menu,
        .mobile-menu-overlay {
            display: none !important;
        }
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       🌙 DARK MODE TOGGLE BUTTON
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    .theme-toggle {
        background: linear-gradient(135deg, #667eea, #764ba2);
        border: none;
        width: 45px;
        height: 45px;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 20px;
        transition: all 0.3s;
        box-shadow: 0 2px 10px rgba(0,0,0,0.2);
        margin-left: 15px;
    }

    .theme-toggle:hover {
        transform: scale(1.1);
        box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    }

    .theme-toggle .sun-icon {
        display: none;
    }

    .theme-toggle .moon-icon {
        display: block;
    }

    body.dark-mode .theme-toggle .sun-icon {
        display: block;
    }

    body.dark-mode .theme-toggle .moon-icon {
        display: none;
    }

    body.dark-mode .theme-toggle {
        background: linear-gradient(135deg, #f39c12, #e74c3c);
    }

    @media (max-width: 768px) {
        .theme-toggle {
            position: fixed;
            bottom: 90px;
            left: 20px;
            z-index: 9998;
            width: 50px;
            height: 50px;
        }
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       🌙 DARK MODE STYLES
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    body.dark-mode {
        background-color: #0a0a0a !important;
        color: #e0e0e0 !important;
    }

    body.dark-mode .site-header {
        background: linear-gradient(135deg, #1a1a1a, #2d2d2d) !important;
        border-bottom: 1px solid #333 !important;
    }

    body.dark-mode .site-header a {
        color: #e0e0e0 !important;
    }

    body.dark-mode .main-nav a:hover {
        color: #e8826f !important;
    }

    body.dark-mode .donation-banner-top {
        background: linear-gradient(135deg, #1a1a1a, #2d2d2d) !important;
    }

    body.dark-mode .mobile-menu {
        background: #1a1a1a !important;
    }

    body.dark-mode .mobile-menu-links a {
        color: #e0e0e0 !important;
    }

    body.dark-mode .mobile-menu-links a:hover {
        background: #2d2d2d !important;
    }

    body.dark-mode .mobile-lang-flags a {
        box-shadow: 0 3px 10px rgba(0,0,0,0.5) !important;
    }

    /* Dark mode per footer e contenuti generici */
    body.dark-mode main,
    body.dark-mode .content,
    body.dark-mode article {
        background-color: #0a0a0a !important;
    }

    body.dark-mode h1, body.dark-mode h2, body.dark-mode h3,
    body.dark-mode h4, body.dark-mode h5, body.dark-mode h6 {
        color: #e8826f !important;
    }

    body.dark-mode p, body.dark-mode span, body.dark-mode li {
        color: #cccccc !important;
    }

    body.dark-mode .card, body.dark-mode .box, body.dark-mode .panel {
        background: #1a1a1a !important;
        border-color: #333 !important;
    }

    body.dark-mode input, body.dark-mode textarea, body.dark-mode select {
        background: #1a1a1a !important;
        color: #e0e0e0 !important;
        border-color: #444 !important;
    }

    body.dark-mode input::placeholder, body.dark-mode textarea::placeholder {
        color: #888 !important;
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       🌙 DARK MODE - MINI CHAT
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    body.dark-mode .mini-ai-chat {
        background: #1a1a1a !important;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6) !important;
    }

    body.dark-mode .mini-chat-header {
        background: linear-gradient(135deg, #2d2d2d, #1a1a1a) !important;
    }

    body.dark-mode .mini-chat-content {
        background: #0a0a0a !important;
    }

    body.dark-mode .mini-chat-welcome h3 {
        color: #e8826f !important;
    }

    body.dark-mode .mini-chat-welcome p {
        color: #cccccc !important;
    }

    body.dark-mode .quick-btn {
        background: linear-gradient(135deg, #2d2d2d, #1a1a1a) !important;
        color: #e0e0e0 !important;
        border: 1px solid #444 !important;
    }

    body.dark-mode .quick-btn:hover {
        background: linear-gradient(135deg, #667eea, #764ba2) !important;
        color: white !important;
    }

    body.dark-mode .or-divider span {
        background: #0a0a0a !important;
        color: #888 !important;
    }

    body.dark-mode .or-divider::before,
    body.dark-mode .or-divider::after {
        background: #333 !important;
    }

    body.dark-mode .chat-message.ai {
        background: #2d2d2d !important;
        color: #e0e0e0 !important;
    }

    body.dark-mode .chat-message.user {
        background: linear-gradient(135deg, #d4705f, #b55a4a) !important;
        color: white !important;
    }

    body.dark-mode .mini-chat-input-area {
        background: #1a1a1a !important;
        border-color: #333 !important;
    }

    body.dark-mode #miniChatInput {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
        border-color: #444 !important;
    }

    body.dark-mode #miniChatInput::placeholder {
        color: #888 !important;
    }

    body.dark-mode .mini-chat-footer {
        background: #000000 !important;
        border-color: #1a1a1a !important;
    }

    body.dark-mode .full-chat-link {
        color: #e8826f !important;
    }

    body.dark-mode .floating-ai-btn {
        box-shadow: 0 5px 30px rgba(0, 0, 0, 0.8) !important;
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       📱 INSTALLA APP BUTTON - SUPER SPETTACOLARE! 🔥
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    .install-app-btn {
        position: relative;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        background: linear-gradient(135deg, #FF6B6B 0%, #FF8E53 50%, #FFD93D 100%);
        background-size: 200% 200%;
        color: white !important;
        padding: 10px 20px;
        border-radius: 30px;
        text-decoration: none !important;
        font-weight: 700;
        font-size: 14px;
        box-shadow: 0 4px 20px rgba(255, 107, 107, 0.5);
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        overflow: hidden;
        animation: gradientShift 3s ease infinite, gentlePulse 2s ease-in-out infinite;
        white-space: nowrap;
    }

    .install-app-btn::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.3) 50%, transparent 70%);
        transform: rotate(45deg);
        animation: shimmer 3s infinite;
    }

    @keyframes shimmer {
        0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
        100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
    }

    @keyframes gradientShift {
        0%, 100% { background-position: 0% 50%; }
        50% { background-position: 100% 50%; }
    }

    @keyframes gentlePulse {
        0%, 100% {
            transform: scale(1);
            box-shadow: 0 4px 20px rgba(255, 107, 107, 0.5);
        }
        50% {
            transform: scale(1.02);
            box-shadow: 0 6px 30px rgba(255, 107, 107, 0.7);
        }
    }

    .install-app-btn:hover {
        transform: translateY(-3px) scale(1.05);
        box-shadow: 0 8px 35px rgba(255, 107, 107, 0.8);
        text-decoration: none !important;
        color: white !important;
    }

    .install-app-btn:active {
        transform: translateY(-1px) scale(1.02);
    }

    .install-app-icon {
        font-size: 18px;
        animation: bounce 2s ease-in-out infinite;
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    }

    @keyframes bounce {
        0%, 100% { transform: translateY(0); }
        25% { transform: translateY(-4px) rotate(-5deg); }
        75% { transform: translateY(-2px) rotate(5deg); }
    }

    .install-app-badge {
        position: absolute;
        top: -10px;
        right: -10px;
        background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
        color: #000;
        font-size: 9px;
        font-weight: 900;
        padding: 4px 8px;
        border-radius: 12px;
        box-shadow: 0 3px 10px rgba(255, 215, 0, 0.8);
        animation: badgePulse 1.5s ease-in-out infinite;
        text-transform: uppercase;
        letter-spacing: 0.8px;
        border: 2px solid white;
    }

    @keyframes badgePulse {
        0%, 100% {
            transform: scale(1);
            box-shadow: 0 3px 10px rgba(255, 215, 0, 0.8);
        }
        50% {
            transform: scale(1.15);
            box-shadow: 0 5px 20px rgba(255, 215, 0, 1);
        }
    }

    .main-nav .install-app-btn {
        margin-left: 8px;
    }

    .mobile-menu-links .install-app-btn {
        width: 100%;
        justify-content: center;
        padding: 18px 20px;
        font-size: 16px;
        margin: 15px 0;
        border-radius: 15px;
        box-shadow: 0 6px 25px rgba(255, 107, 107, 0.6);
    }

    .mobile-menu-links .install-app-btn .install-app-icon {
        font-size: 22px;
    }

    .mobile-menu-links .install-app-btn:hover {
        transform: scale(1.03);
    }

    /* Hide install button if app is installed */
    .install-app-btn.hidden {
        display: none !important;
    }

    @media (max-width: 1200px) {
        .install-app-btn {
            padding: 8px 16px;
            font-size: 13px;
        }
        
        .install-app-icon {
            font-size: 16px;
        }
        
        .install-app-badge {
            font-size: 8px;
            padding: 3px 6px;
        }
    }

    @media (max-width: 768px) {
        .main-nav .install-app-btn {
            display: none;
        }
        
        .mobile-menu-links .install-app-btn {
            display: flex !important;
        }
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       🌙 DARK MODE - TOTAL BLACK AGGRESSIVO 🖤
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    body.dark-mode {
        background-color: #000000 !important;
        color: #e0e0e0 !important;
    }

    body.dark-mode * {
        border-color: #1a1a1a !important;
    }

    body.dark-mode main,
    body.dark-mode .page,
    body.dark-mode .wrap,
    body.dark-mode .content,
    body.dark-mode article,
    body.dark-mode section,
    body.dark-mode .container {
        background-color: #000000 !important;
    }

    body.dark-mode .site-header {
        background: #000000 !important;
        border-bottom: 1px solid #1a1a1a !important;
        box-shadow: 0 2px 20px rgba(0, 0, 0, 0.8) !important;
    }

    body.dark-mode .site-header a {
        color: #e0e0e0 !important;
    }

    body.dark-mode .main-nav a:hover {
        color: #e8826f !important;
    }

    body.dark-mode .donation-banner-top {
        background: linear-gradient(135deg, #1a1a1a, #0a0a0a) !important;
        border-bottom: 1px solid #333 !important;
    }

    body.dark-mode .mobile-menu {
        background: #000000 !important;
    }

    body.dark-mode .mobile-menu-links a {
        color: #e0e0e0 !important;
        background: #0a0a0a !important;
    }

    body.dark-mode .mobile-menu-links a:hover {
        background: #1a1a1a !important;
        color: #e8826f !important;
    }

    /* Dark mode per testi */
    body.dark-mode h1, body.dark-mode h2, body.dark-mode h3,
    body.dark-mode h4, body.dark-mode h5, body.dark-mode h6 {
        color: #ffffff !important;
    }

    body.dark-mode p, body.dark-mode span, body.dark-mode li,
    body.dark-mode td, body.dark-mode th, body.dark-mode label,
    body.dark-mode div {
        color: #e0e0e0 !important;
    }

    body.dark-mode a {
        color: #e8826f !important;
    }

    body.dark-mode a:hover {
        color: #ff9d8a !important;
    }

    /* Dark mode per cards e box */
    body.dark-mode .card, body.dark-mode .box, body.dark-mode .panel,
    body.dark-mode .recipe-card, body.dark-mode .info-card {
        background: #0a0a0a !important;
        border: 1px solid #1a1a1a !important;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5) !important;
    }

    body.dark-mode .card:hover, body.dark-mode .recipe-card:hover {
        box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7) !important;
    }

    /* Dark mode per inputs */
    body.dark-mode input, body.dark-mode textarea, body.dark-mode select {
        background: #0a0a0a !important;
        color: #ffffff !important;
        border: 1px solid #333 !important;
    }

    body.dark-mode input:focus, body.dark-mode textarea:focus, body.dark-mode select:focus {
        border-color: #d4705f !important;
        box-shadow: 0 0 0 3px rgba(212, 112, 95, 0.2) !important;
    }

    body.dark-mode input::placeholder, body.dark-mode textarea::placeholder {
        color: #666 !important;
    }

    /* Dark mode per recipe details */
    body.dark-mode .recipe-detail,
    body.dark-mode .recipe-content,
    body.dark-mode .recipe-info,
    body.dark-mode .ingredients-section,
    body.dark-mode .instructions-section,
    body.dark-mode .procedimento {
        background: #000000 !important;
    }

    body.dark-mode .recipe-detail h1,
    body.dark-mode .recipe-detail h2,
    body.dark-mode .recipe-detail h3 {
        color: #e8826f !important;
    }

    body.dark-mode .recipe-detail p,
    body.dark-mode .recipe-detail li,
    body.dark-mode .recipe-detail span {
        color: #e0e0e0 !important;
    }

    body.dark-mode .recipe-meta span,
    body.dark-mode .recipe-time,
    body.dark-mode .recipe-servings,
    body.dark-mode .recipe-difficulty {
        color: #cccccc !important;
        background: #1a1a1a !important;
    }

    /* Dark mode per buttons */
    body.dark-mode .btn, body.dark-mode button {
        background: #1a1a1a !important;
        color: #e0e0e0 !important;
        border-color: #333 !important;
    }

    body.dark-mode .btn:hover, body.dark-mode button:hover {
        background: #2a2a2a !important;
    }

    body.dark-mode .btn-primary, body.dark-mode .btn-primary-small {
        background: linear-gradient(135deg, #d4705f, #b55a4a) !important;
        color: white !important;
    }

    /* Dark mode per footer */
    body.dark-mode footer, body.dark-mode .site-footer {
        background: #000000 !important;
        border-top: 1px solid #1a1a1a !important;
    }

    body.dark-mode footer p, body.dark-mode footer a,
    body.dark-mode .site-footer p, body.dark-mode .site-footer a {
        color: #999 !important;
    }

    /* Dark mode per tables */
    body.dark-mode table {
        background: #0a0a0a !important;
    }

    body.dark-mode th {
        background: #1a1a1a !important;
        color: #e8826f !important;
    }

    body.dark-mode td {
        background: #0a0a0a !important;
        border-color: #1a1a1a !important;
    }

    body.dark-mode tr:hover td {
        background: #1a1a1a !important;
    }

    /* Dark mode per mini chat - TOTAL BLACK */
    body.dark-mode .mini-ai-chat {
        background: #000000 !important;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9) !important;
        border: 1px solid #1a1a1a !important;
    }

    body.dark-mode .mini-chat-header {
        background: #0a0a0a !important;
        border-bottom: 1px solid #1a1a1a !important;
    }

    body.dark-mode .mini-chat-content {
        background: #000000 !important;
    }

    body.dark-mode .mini-chat-welcome h3 {
        color: #e8826f !important;
    }

    body.dark-mode .mini-chat-welcome p {
        color: #cccccc !important;
    }

    body.dark-mode .quick-btn {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
        border: 1px solid #333 !important;
    }

    body.dark-mode .quick-btn:hover {
        background: linear-gradient(135deg, #d4705f, #b55a4a) !important;
        color: white !important;
        border-color: #d4705f !important;
    }

    body.dark-mode .or-divider span {
        background: #000000 !important;
        color: #666 !important;
    }

    body.dark-mode .or-divider::before,
    body.dark-mode .or-divider::after {
        background: #333 !important;
    }

    body.dark-mode .chat-message.ai {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
        border: 1px solid #1a1a1a !important;
    }

    body.dark-mode .chat-message.user {
        background: linear-gradient(135deg, #d4705f, #b55a4a) !important;
        color: white !important;
    }

    body.dark-mode .mini-chat-input-area {
        background: #0a0a0a !important;
        border-top: 1px solid #1a1a1a !important;
    }

    body.dark-mode #miniChatInput {
        background: #000000 !important;
        color: #ffffff !important;
        border: 1px solid #333 !important;
    }

    body.dark-mode #miniChatInput:focus {
        border-color: #d4705f !important;
    }

    body.dark-mode #miniChatInput::placeholder {
        color: #666 !important;
    }

    /* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
       🖤 DARK MODE EXTRA AGGRESSIVO - OVERRIDE TOTALE 
       ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
    
    /* TUTTO NERO - Background universale */
    body.dark-mode,
    body.dark-mode html,
    body.dark-mode body,
    body.dark-mode main,
    body.dark-mode article,
    body.dark-mode section,
    body.dark-mode aside,
    body.dark-mode nav,
    body.dark-mode header,
    body.dark-mode div,
    body.dark-mode .page,
    body.dark-mode .wrap,
    body.dark-mode .container,
    body.dark-mode .content,
    body.dark-mode .wrapper,
    body.dark-mode .main-content,
    body.dark-mode .site-content,
    body.dark-mode .page-content,
    body.dark-mode .entry-content,
    body.dark-mode .post-content,
    body.dark-mode .recipe-page,
    body.dark-mode .recipes-page,
    body.dark-mode .hero,
    body.dark-mode .hero-section,
    body.dark-mode .banner,
    body.dark-mode .jumbotron {
        background-color: #000000 !important;
        background: #000000 !important;
    }

    /* TESTI BIANCHI - Override totale */
    body.dark-mode h1, body.dark-mode h2, body.dark-mode h3,
    body.dark-mode h4, body.dark-mode h5, body.dark-mode h6,
    body.dark-mode .title, body.dark-mode .heading,
    body.dark-mode .recipe-title, body.dark-mode .recipe-name,
    body.dark-mode .page-title, body.dark-mode .entry-title {
        color: #ffffff !important;
    }

    body.dark-mode p, body.dark-mode span, body.dark-mode li,
    body.dark-mode td, body.dark-mode th, body.dark-mode label,
    body.dark-mode small, body.dark-mode strong, body.dark-mode b,
    body.dark-mode em, body.dark-mode i, body.dark-mode u,
    body.dark-mode blockquote, body.dark-mode q, body.dark-mode cite,
    body.dark-mode pre, body.dark-mode code, body.dark-mode samp,
    body.dark-mode .text, body.dark-mode .description,
    body.dark-mode .recipe-description, body.dark-mode .recipe-text,
    body.dark-mode .content-text, body.dark-mode .body-text,
    body.dark-mode .summary, body.dark-mode .excerpt,
    body.dark-mode .meta, body.dark-mode .info,
    body.dark-mode .details, body.dark-mode .caption {
        color: #e0e0e0 !important;
    }

    /* LINK in corallo */
    body.dark-mode a,
    body.dark-mode a:link,
    body.dark-mode a:visited,
    body.dark-mode .link {
        color: #e8826f !important;
    }

    body.dark-mode a:hover,
    body.dark-mode a:active {
        color: #ff9d8a !important;
    }

    /* CARDS e BOX - nero scuro con bordo */
    body.dark-mode .card, body.dark-mode .box, body.dark-mode .panel,
    body.dark-mode .tile, body.dark-mode .item, body.dark-mode .block,
    body.dark-mode .widget, body.dark-mode .module, body.dark-mode .component,
    body.dark-mode .recipe-card, body.dark-mode .recipe-item,
    body.dark-mode .recipe-box, body.dark-mode .info-card,
    body.dark-mode .feature-card, body.dark-mode .stat-card,
    body.dark-mode .grid-item, body.dark-mode .list-item,
    body.dark-mode .media, body.dark-mode .media-object {
        background: #0a0a0a !important;
        background-color: #0a0a0a !important;
        border: 1px solid #222 !important;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6) !important;
    }

    /* FORM elements - sfondo nero */
    body.dark-mode input,
    body.dark-mode textarea,
    body.dark-mode select,
    body.dark-mode option,
    body.dark-mode button,
    body.dark-mode .input,
    body.dark-mode .textarea,
    body.dark-mode .select,
    body.dark-mode .form-control,
    body.dark-mode .form-input,
    body.dark-mode .field,
    body.dark-mode [type="text"],
    body.dark-mode [type="email"],
    body.dark-mode [type="password"],
    body.dark-mode [type="search"],
    body.dark-mode [type="number"],
    body.dark-mode [type="tel"],
    body.dark-mode [type="url"] {
        background: #0a0a0a !important;
        background-color: #0a0a0a !important;
        color: #ffffff !important;
        border: 1px solid #333 !important;
    }

    body.dark-mode input::placeholder,
    body.dark-mode textarea::placeholder {
        color: #888 !important;
    }

    body.dark-mode input:focus,
    body.dark-mode textarea:focus,
    body.dark-mode select:focus {
        border-color: #d4705f !important;
        outline: none !important;
        box-shadow: 0 0 0 2px rgba(212, 112, 95, 0.3) !important;
    }

    /* BOTTONI */
    body.dark-mode .btn,
    body.dark-mode .button,
    body.dark-mode button:not(.install-app-btn):not(.theme-toggle):not(.floating-ai-btn):not(.mobile-menu-toggle) {
        background: #1a1a1a !important;
        color: #e0e0e0 !important;
        border: 1px solid #333 !important;
    }

    body.dark-mode .btn:hover,
    body.dark-mode .button:hover,
    body.dark-mode button:hover:not(.install-app-btn):not(.theme-toggle):not(.floating-ai-btn):not(.mobile-menu-toggle) {
        background: #2a2a2a !important;
        border-color: #444 !important;
    }

    body.dark-mode .btn-primary,
    body.dark-mode .btn-primary-small,
    body.dark-mode .primary-btn {
        background: linear-gradient(135deg, #d4705f, #b55a4a) !important;
        color: #ffffff !important;
        border: none !important;
    }

    /* TABELLE */
    body.dark-mode table,
    body.dark-mode .table {
        background: #000000 !important;
        border-color: #222 !important;
    }

    body.dark-mode thead,
    body.dark-mode th {
        background: #0a0a0a !important;
        color: #e8826f !important;
        border-color: #222 !important;
    }

    body.dark-mode tbody,
    body.dark-mode td,
    body.dark-mode tr {
        background: #000000 !important;
        color: #e0e0e0 !important;
        border-color: #1a1a1a !important;
    }

    body.dark-mode tr:hover td {
        background: #0a0a0a !important;
    }

    /* RECIPE DETAILS PAGE - Specifico */
    body.dark-mode .recipe-detail,
    body.dark-mode .recipe-content,
    body.dark-mode .recipe-info,
    body.dark-mode .recipe-header,
    body.dark-mode .recipe-body,
    body.dark-mode .recipe-footer,
    body.dark-mode .ingredients,
    body.dark-mode .ingredients-section,
    body.dark-mode .ingredients-list,
    body.dark-mode .instructions,
    body.dark-mode .instructions-section,
    body.dark-mode .procedimento,
    body.dark-mode .procedure,
    body.dark-mode .steps,
    body.dark-mode .method {
        background: #000000 !important;
        color: #e0e0e0 !important;
    }

    body.dark-mode .recipe-detail h1,
    body.dark-mode .recipe-detail h2,
    body.dark-mode .recipe-detail h3,
    body.dark-mode .recipe-detail h4 {
        color: #e8826f !important;
    }

    body.dark-mode .recipe-meta,
    body.dark-mode .recipe-meta span,
    body.dark-mode .recipe-time,
    body.dark-mode .recipe-servings,
    body.dark-mode .recipe-difficulty,
    body.dark-mode .recipe-category,
    body.dark-mode .cooking-time,
    body.dark-mode .prep-time,
    body.dark-mode .servings,
    body.dark-mode .difficulty {
        color: #cccccc !important;
        background: #0a0a0a !important;
        border-color: #222 !important;
    }

    /* STEP degli ingredienti e procedimento */
    body.dark-mode .step,
    body.dark-mode .ingredient,
    body.dark-mode .instruction-step,
    body.dark-mode ol li,
    body.dark-mode ul li {
        color: #e0e0e0 !important;
    }

    body.dark-mode .step-number,
    body.dark-mode .step-index {
        background: #d4705f !important;
        color: #ffffff !important;
    }

    /* FOOTER */
    body.dark-mode footer,
    body.dark-mode .footer,
    body.dark-mode .site-footer,
    body.dark-mode .page-footer {
        background: #000000 !important;
        border-top: 1px solid #1a1a1a !important;
    }

    body.dark-mode footer *,
    body.dark-mode .footer *,
    body.dark-mode .site-footer *,
    body.dark-mode .page-footer * {
        color: #888 !important;
    }

    /* SCROLLBAR dark */
    body.dark-mode ::-webkit-scrollbar {
        width: 10px;
        background: #000000;
    }

    body.dark-mode ::-webkit-scrollbar-track {
        background: #0a0a0a;
    }

    body.dark-mode ::-webkit-scrollbar-thumb {
        background: #333;
        border-radius: 5px;
    }

    body.dark-mode ::-webkit-scrollbar-thumb:hover {
        background: #444;
    }

    /* IMMAGINI - Leggera ombra */
    body.dark-mode img {
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    }

    /* BORDER universale */
    body.dark-mode *,
    body.dark-mode *::before,
    body.dark-mode *::after {
        border-color: #222 !important;
    }

    /* SELECTION text */
    body.dark-mode ::selection {
        background: #d4705f !important;
        color: #ffffff !important;
    }

    /* ALERT e NOTIFICHE */
    body.dark-mode .alert,
    body.dark-mode .notice,
    body.dark-mode .notification,
    body.dark-mode .message {
        background: #0a0a0a !important;
        border-color: #333 !important;
        color: #e0e0e0 !important;
    }

    /* MODAL e POPUP */
    body.dark-mode .modal,
    body.dark-mode .modal-content,
    body.dark-mode .popup,
    body.dark-mode .dialog,
    body.dark-mode .overlay-content {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
        border: 1px solid #222 !important;
    }

    /* DROPDOWN */
    body.dark-mode .dropdown,
    body.dark-mode .dropdown-menu,
    body.dark-mode .dropdown-content,
    body.dark-mode .submenu {
        background: #0a0a0a !important;
        border: 1px solid #222 !important;
    }

    body.dark-mode .dropdown-item,
    body.dark-mode .dropdown-menu a,
    body.dark-mode .dropdown-menu li {
        color: #e0e0e0 !important;
    }

    body.dark-mode .dropdown-item:hover,
    body.dark-mode .dropdown-menu a:hover {
        background: #1a1a1a !important;
        color: #e8826f !important;
    }

    /* BADGE e TAG */
    body.dark-mode .badge,
    body.dark-mode .tag,
    body.dark-mode .label,
    body.dark-mode .chip {
        background: #1a1a1a !important;
        color: #e0e0e0 !important;
        border: 1px solid #333 !important;
    }

    /* HR separator */
    body.dark-mode hr {
        border-color: #222 !important;
        background: #222 !important;
    }

    /* BLOCKQUOTE */
    body.dark-mode blockquote {
        background: #0a0a0a !important;
        border-left: 4px solid #d4705f !important;
        color: #cccccc !important;
    }

    /* CODE blocks */
    body.dark-mode code,
    body.dark-mode pre {
        background: #0a0a0a !important;
        color: #e8826f !important;
        border: 1px solid #222 !important;
    }

    /* Rating stars */
    body.dark-mode .stars,
    body.dark-mode .star-rating {
        color: #f39c12 !important;
    }

    /* Share buttons container */
    body.dark-mode .share-buttons,
    body.dark-mode .social-share {
        background: #0a0a0a !important;
    }

    /* Comments section */
    body.dark-mode .comments,
    body.dark-mode .comment,
    body.dark-mode .review,
    body.dark-mode .reviews-section {
        background: #000000 !important;
        border-color: #222 !important;
    }

    body.dark-mode .comment-body,
    body.dark-mode .review-body {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
    }

    /* Pagination */
    body.dark-mode .pagination,
    body.dark-mode .pager {
        background: #000000 !important;
    }

    body.dark-mode .pagination a,
    body.dark-mode .page-link {
        background: #0a0a0a !important;
        color: #e0e0e0 !important;
        border-color: #222 !important;
    }

    body.dark-mode .pagination a:hover,
    body.dark-mode .page-link:hover {
        background: #1a1a1a !important;
        color: #e8826f !important;
    }

    body.dark-mode .pagination .active,
    body.dark-mode .page-item.active .page-link {
        background: #d4705f !important;
        color: #ffffff !important;
    }

/* ========================================
   🔥 DROPDOWN MENU CATEGORIE - MOBILE FIRST
   ======================================== */

/* Mobile Dropdown (Default - Mobile First) */
.mobile-dropdown {
    margin: 8px 0;
}

.mobile-dropdown-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    color: #2c2c2c;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s;
    cursor: pointer;
    background: #f9f9f9;
}

.mobile-dropdown-toggle:hover {
    background: #f0f0f0;
}

.mobile-dropdown-toggle .dropdown-arrow {
    font-size: 14px;
    transition: transform 0.3s;
}

.mobile-dropdown.active .mobile-dropdown-toggle .dropdown-arrow {
    transform: rotate(180deg);
}

.mobile-dropdown-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    background: white;
    border-radius: 0 0 12px 12px;
    margin-top: -8px;
}

.mobile-dropdown.active .mobile-dropdown-menu {
    max-height: 600px;
}

.mobile-dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px 14px 35px;
    color: #555;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.mobile-dropdown-menu a:hover,
.mobile-dropdown-menu a:active {
    background: rgba(212, 112, 95, 0.05);
    color: #d4705f;
    border-left-color: #d4705f;
    padding-left: 40px;
}

.mobile-dropdown-menu .category-icon {
    font-size: 20px;
}

/* Desktop Dropdown (Min 769px) */
.dropdown {
    position: relative;
    display: none; /* Hidden on mobile */
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    padding: 8px 16px;
    color: #2c2c2c;
    text-decoration: none;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s;
}

.dropdown-toggle:hover {
    background: rgba(212, 112, 95, 0.1);
    color: #d4705f;
}

.dropdown-arrow {
    font-size: 12px;
    transition: transform 0.3s;
}

.dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    min-width: 250px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    margin-top: 8px;
    overflow: hidden;
}

.dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    color: #2c2c2c;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-menu a:last-child {
    border-bottom: none;
}

.dropdown-menu a:hover {
    background: linear-gradient(135deg, rgba(212, 112, 95, 0.1), rgba(181, 90, 74, 0.1));
    color: #d4705f;
    padding-left: 25px;
}

.category-icon {
    font-size: 22px;
    width: 30px;
    text-align: center;
}

/* Dark Mode */
body.dark-mode .mobile-dropdown-toggle {
    background: #3c3c3c;
    color: #e0e0e0;
}

body.dark-mode .mobile-dropdown-toggle:hover {
    background: #4c4c4c;
}

body.dark-mode .mobile-dropdown-menu {
    background: #2c2c2c;
}

body.dark-mode .mobile-dropdown-menu a {
    color: #b0b0b0;
}

body.dark-mode .mobile-dropdown-menu a:hover,
body.dark-mode .mobile-dropdown-menu a:active {
    background: rgba(212, 112, 95, 0.15);
    color: #ff8a73;
    border-left-color: #ff8a73;
}

body.dark-mode .dropdown-toggle {
    color: #e0e0e0;
}

body.dark-mode .dropdown-toggle:hover {
    background: rgba(212, 112, 95, 0.2);
    color: #ff8a73;
}

body.dark-mode .dropdown-menu {
    background: #2c2c2c;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

body.dark-mode .dropdown-menu a {
    color: #e0e0e0;
    border-bottom: 1px solid #3c3c3c;
}

body.dark-mode .dropdown-menu a:hover {
    background: linear-gradient(135deg, rgba(212, 112, 95, 0.2), rgba(181, 90, 74, 0.2));
    color: #ff8a73;
}

/* Responsive - Desktop (769px+) */
@media (min-width: 769px) {
    .dropdown {
        display: inline-block; /* Show on desktop */
    }
    
    .mobile-dropdown {
        display: none; /* Hide on desktop */
    }
}


/* 🤖 AI CHEF DROPDOWN - MOBILE FIRST */
.ai-dropdown {
    position: relative;
    display: inline-block;
}

.ai-dropdown-toggle {
    background: linear-gradient(135deg, #d4705f, #b55a4a);
    color: white;
    padding: 12px 20px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: none;
    font-size: 0.95rem;
    transition: all 0.3s;
    min-width: 180px;
}

.ai-dropdown-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(212, 112, 95, 0.4);
}

.ai-dropdown-arrow {
    transition: transform 0.3s;
    font-size: 0.8rem;
}

.ai-dropdown.active .ai-dropdown-arrow {
    transform: rotate(180deg);
}

.ai-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #d4705f;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    z-index: 1000;
    overflow: hidden;
}

.ai-dropdown.active .ai-dropdown-menu {
    display: block;
}

.ai-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    text-decoration: none;
    color: #333;
    transition: background 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.ai-dropdown-item:last-child {
    border-bottom: none;
}

.ai-dropdown-item:hover {
    background: #FFF5E1;
}

.ai-dropdown-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.ai-dropdown-info {
    flex: 1;
}

.ai-dropdown-info strong {
    display: block;
    color: #d4705f;
    font-size: 0.95rem;
    margin-bottom: 2px;
}

.ai-dropdown-info small {
    display: block;
    color: #666;
    font-size: 0.8rem;
}

/* MOBILE: Dropdown in mobile menu */
@media (max-width: 768px) {
    .ai-dropdown-toggle {
        width: 100%;
        margin: 10px 0;
    }
    
    .ai-dropdown-menu {
        position: relative;
        top: 0;
        margin-top: 8px;
    }
}

/* DESKTOP: Hide in main nav if already has buttons */
@media (min-width: 769px) {
    .mobile-only-dropdown {
        display: none;
    }
}
.mystery-box-fab,.dopamine-fab.mystery-box-fab{display:none!important;visibility:hidden!important;opacity:0!important;pointer-events:none!important;width:0!important;height:0!important}
@media (max-width: 768px){
  /* barra XP con livello */
  .xp-bar-container, .xp-bar, .level-badge, .xp-level-badge,
  .gm-level-section, .gm-level-badge,
  /* fiamma serie */
  .streak-badge, .streak-content, .streak-display, [class*="streak"]:not(.gm-stat-card),
  /* ruota della fortuna e monete nella barra */
  .rewards-btn, .coins-display,
  /* footer */
  .site-footer{
    display: none !important;
  }
}
@media (max-width: 768px){
  .dopamine-xp-bar, .xp-info, .xp-current, .rewards-btn,
  .gm-stats-panel, .gm-daily-modal, .gm-daily-btn,
  .streak-badge, .coins-display, .site-footer{
    display: none !important;
  }
}
.dopamine-challenge-progress,.dopamine-achievement-popup,.dopamine-toast,.level-up-badge{display:none!important;visibility:hidden!important;opacity:0!important;pointer-events:none!important}
.social-proof-indicator,.social-proof,[class*="social-proof"]{display:none!important;visibility:hidden!important;opacity:0!important}
#lightbox{display:none}#lightbox.show{display:flex}
/* desktop: griglia compatta accanto al logo */
.desktop-lang-flags{display:grid!important;grid-template-columns:repeat(7,25px);gap:3px;
  width:auto;max-width:196px;align-content:center;padding:2px}
.desktop-lang-flags a{width:25px;height:18px;border-radius:3px;overflow:hidden;display:block;
  opacity:.85;transition:opacity .15s,transform .15s}
.desktop-lang-flags a:hover{opacity:1;transform:scale(1.2)}
.desktop-lang-flags img{width:100%;height:100%;object-fit:cover;display:block}
/* MOBILE: le bandiere stanno SOLO nel menu, mai nell'header */
@media(max-width:768px){
  .desktop-lang-flags{display:none!important}
  .mobile-lang-flags{display:grid!important;grid-template-columns:repeat(5,44px);
    justify-content:center;gap:9px 11px;margin:0 auto 22px;padding:4px 0 16px;max-width:300px}
  .mobile-lang-flags a{width:44px;height:32px;border-radius:5px;overflow:hidden;display:block;margin:0;
    box-shadow:0 1px 4px rgba(0,0,0,.14)}
  .mobile-lang-flags img{width:100%;height:100%;object-fit:cover;display:block}
}
@media(min-width:769px){.mobile-lang-flags{display:none}}
/* ─── selettore lingua: un bottone, una tendina ─── */
.lang-pick{position:relative;display:none;flex:0 0 auto;margin-right:6px}
@media(min-width:769px){.lang-pick{display:block}.desktop-lang-flags{display:none!important}}
.lang-pick__btn{display:flex;align-items:center;gap:7px;height:34px;padding:0 10px 0 7px;
  background:rgba(255,255,255,.9);border:1px solid rgba(0,0,0,.09);border-radius:9px;
  cursor:pointer;font:inherit;font-size:.82rem;color:var(--text,#2c2c2c);line-height:1;
  box-shadow:0 1px 3px rgba(0,0,0,.05);transition:border-color .16s,box-shadow .16s,transform .16s}
.lang-pick__btn:hover{border-color:rgba(212,112,95,.45);box-shadow:0 2px 8px rgba(212,112,95,.16)}
.lang-pick__btn:active{transform:scale(.97)}
.lang-pick__flag{width:22px;height:16px;border-radius:3px;object-fit:cover;display:block;flex:0 0 auto}
.lang-pick__code{font-weight:600;letter-spacing:.03em;text-transform:uppercase;font-size:.72rem;opacity:.8}
.lang-pick__arrow{width:0;height:0;border-left:4px solid transparent;border-right:4px solid transparent;
  border-top:5px solid currentColor;opacity:.5;transition:transform .2s}
.lang-pick.is-open .lang-pick__arrow{transform:rotate(180deg)}
.lang-pick__panel{position:absolute;top:calc(100% + 7px);right:0;z-index:1200;
  background:#fff;border:1px solid rgba(0,0,0,.08);border-radius:13px;
  box-shadow:0 12px 34px rgba(0,0,0,.14);padding:7px;
  display:grid;grid-template-columns:repeat(2,minmax(138px,1fr));gap:2px;
  max-height:min(420px,68vh);overflow-y:auto;overscroll-behavior:contain;
  opacity:0;visibility:hidden;transform:translateY(-6px) scale(.985);
  transition:opacity .17s ease,transform .17s ease,visibility .17s}
.lang-pick.is-open .lang-pick__panel{opacity:1;visibility:visible;transform:none}
.lang-pick__item{display:flex;align-items:center;gap:9px;padding:7px 9px;border-radius:8px;
  text-decoration:none;color:var(--text,#2c2c2c);font-size:.83rem;white-space:nowrap;
  transition:background .13s}
.lang-pick__item:hover{background:rgba(212,112,95,.09)}
.lang-pick__item img{width:23px;height:17px;border-radius:3px;object-fit:cover;flex:0 0 auto}
.lang-pick__item--now{background:rgba(212,112,95,.13);font-weight:600;pointer-events:none}
.lang-pick__panel::-webkit-scrollbar{width:7px}
.lang-pick__panel::-webkit-scrollbar-thumb{background:rgba(0,0,0,.16);border-radius:4px}
body.dark-mode .lang-pick__btn{background:rgba(42,42,46,.9);border-color:rgba(255,255,255,.12);color:#eee}
body.dark-mode .lang-pick__panel{background:#242428;border-color:rgba(255,255,255,.1)}
body.dark-mode .lang-pick__item{color:#e8e8e8}
body.dark-mode .lang-pick__item:hover{background:rgba(212,112,95,.2)}
html[dir="rtl"] .lang-pick__panel{right:auto;left:0}
@media(max-width:900px) and (min-width:769px){
  .lang-pick__panel{grid-template-columns:1fr;max-height:60vh}
}
