/* ==========================================================================
   FARMACIA MAGGIORE - STYLE.CSS (MASTER 2026 - FINAL EDITION)
   ========================================================================== */

/* 1. SETUP & VARIABILI */
:root {
    --primary: #0B3D5E;
    --accent: #205d86;
    --warning: #ffb703;
    --success: #28a745;
    --danger: #dc3545;
    --light: #F4F8FB;
    --white: #ffffff;
    --text: #1a1a1a;
    --header-h: 110px;
    --top-h: 55px; 
    --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-snap-type: y mandatory; }

body { 
    font-family: 'Open Sans', sans-serif; color: var(--text); 
    background-color: var(--white); line-height: 1.6; 
    padding-bottom: 0 !important; margin: 0; overflow-x: hidden; width: 100%;
}

body.chat-open { overflow: hidden; } 
body.menu-open { overflow: hidden !important; position: fixed; width: 100%; height: 100%; }
body.modal-open { overflow: hidden !important; }

h1, h2, h3, h4 { font-family: 'Montserrat', sans-serif; color: var(--primary); text-align: center; width: 100%; }
a { text-decoration: none; transition: var(--transition-smooth); color: inherit; }
a:focus, button:focus { outline: 3px solid var(--accent); outline-offset: 2px; }

ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* ==========================================================================
   3. HEADER E TOP BAR
   ========================================================================== */
.top-bar { 
    background: var(--primary); color: white; min-height: var(--top-h); height: auto;
    position: fixed; top: 0; left: 0; width: 100%; z-index: 2000; 
    display: flex; align-items: center; justify-content: center; font-size: 0.85rem; font-weight: 400; 
}

.container-top { width: 100%; max-width: 1200px; display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: center; padding: 8px 20px; box-sizing: border-box; }

.hours-wrapper { display: flex; align-items: center; position: relative; }
.top-info-text { display: flex; align-items: center; gap: 10px; color: #e0e0e0; font-size: 0.85rem; font-weight: 400; margin: 0; padding: 0;}
.top-separator { opacity: 0.4; font-weight: 300; }
#desktop-auth-box { display: flex; align-items: center; gap: 10px; margin: 0; }

.top-bar .login-link-top { 
    color: #ffffff; font-weight: 400; padding: 6px 18px; border-radius: 20px; 
    transition: var(--transition-smooth); font-size: 0.85rem; display: inline-flex; align-items: center; 
    justify-content: center; white-space: nowrap; background: rgba(255,255,255,0.1); 
    border: 1px solid rgba(255,255,255,0.3); gap: 6px; letter-spacing: 0.5px;
}
.top-bar .login-link-top:hover { transform: translateY(-1px); border-color: #fff; background-color: rgba(255,255,255,0.25); }

.top-bar #orario-live { 
    background: #ffffff; color: var(--primary); border: none; 
    padding: 6px 18px; border-radius: 20px; font-weight: 600; 
    font-size: 0.85rem; cursor: pointer; display: inline-flex; 
    align-items: center; justify-content: center; gap: 6px; 
    box-shadow: 0 2px 5px rgba(0,0,0,0.15); transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s;
}
.top-bar #orario-live:has(.fa-door-open) { background-color: var(--success); color: #ffffff; }
.top-bar #orario-live:has(.fa-door-closed) { background-color: var(--danger); color: #ffffff; }
.top-bar #orario-live:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(0,0,0,0.2); }
.top-bar #orario-live i, .top-bar .login-link-top i { margin-top: -1px; }

.user-dropdown-container { position: relative; display: inline-block; }
.user-name-btn { background: none; border: none; font-weight: 600; color: #dbebf5; font-size: 0.9rem; cursor: pointer; display: flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 8px; transition: 0.2s; outline: none; font-family: 'Open Sans', sans-serif; margin-right: 10px;}
.user-name-btn:hover { background: rgba(255,255,255,0.1); color: white; }
.user-dropdown-menu { position: absolute; top: 100%; right: 0; background: white; min-width: 200px; box-shadow: 0 10px 25px rgba(0,0,0,0.15); border-radius: 12px; padding: 10px 0; margin-top: 10px; display: none !important; z-index: 9999; border: 1px solid #eee; text-align: left; }
.user-dropdown-menu.show { display: block !important; }
.dropdown-item { display: block; padding: 10px 20px; color: #333; text-decoration: none; font-size: 0.9rem; font-weight: 600; transition: 0.2s; cursor: pointer; border: none; background: none; width: 100%; text-align: left; font-family: 'Open Sans', sans-serif; }
.dropdown-item:hover { background: #f8fafc; color: #0B3D5E; }
.dropdown-item.danger { color: #d9534f; }

header { background: white; height: var(--header-h); position: fixed; top: var(--top-h); left: 0; width: 100%; z-index: 1000; box-shadow: 0 4px 15px rgba(0,0,0,0.05); display: flex; align-items: center; justify-content: center; transition: top 0.3s ease; }
.navbar-container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; display: flex; justify-content: space-between; align-items: center; position: relative; }
.logo-box { display: flex; align-items: center; }
.logo-box img { max-height: 85px; display: block; }

.nav-links { display: flex; gap: 15px; align-items: center; }
.nav-links li { list-style: none; }
.nav-links a { color: var(--primary); font-weight: 700; font-size: 1rem; padding: 10px 25px; border-radius: 50px; transition: var(--transition-smooth); border: 1px solid transparent; }
.nav-links a:hover, .nav-links a.active-link { background-color: var(--accent); color: white !important; box-shadow: 0 4px 15px rgba(32, 93, 134, 0.4); transform: translateY(-2px); }

.mobile-only { display: none; }
.hamburger { display: none; cursor: pointer; font-size: 1.8rem; color: var(--primary); padding: 5px; z-index: 10002; }

/* FIX POPUP ORARI */
.hours-popup { 
    display: none; position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%);
    background-color: #ffffff !important; color: #222; padding: 20px; border-radius: 12px; 
    box-shadow: 0 15px 40px rgba(0,0,0,0.4) !important; border: 1px solid #ddd; 
    z-index: 999999 !important; text-align: center; opacity: 0; 
    transition: var(--transition-smooth); width: 280px; 
}
.hours-popup.active { display: block; opacity: 1; }
.hours-popup::before { content: ""; position: absolute; top: -8px; left: 50%; margin-left: -8px; border-left: 8px solid transparent; border-right: 8px solid transparent; border-bottom: 8px solid #ffffff; }
.hours-tabs-clean { display: flex; border-bottom: 1px solid #eee; margin-bottom: 15px; }
.hour-tab-btn-clean { flex: 1; background: none; border: none; padding: 10px 5px; font-size: 0.85rem; font-weight: 500; color: #666; cursor: pointer; border-bottom: 2px solid transparent; transition: 0.3s; }
.hour-tab-btn-clean.active { color: var(--primary); border-bottom: 2px solid var(--primary); font-weight: 600; }
.hour-content-clean { display: none; text-align: center; }
.hour-content-clean.active { display: block; }
.hour-row-clean { font-size: 0.95rem; color: #333; margin-bottom: 10px; display: flex; align-items: center; justify-content: center; gap: 10px; font-weight: 500; }

/* ==========================================================================
   4. SEZIONI GENERALI E ACCESSIBILITA'
   ========================================================================== */
section { 
    width: 100% !important; 
    min-height: 100vh !important; 
    height: 100vh !important; 
    scroll-snap-align: start !important; 
    scroll-snap-stop: always !important; 
    padding-top: 165px !important; 
    padding-bottom: 40px !important; 
    padding-left: 20px !important; 
    padding-right: 20px !important;
    display: flex !important; 
    flex-direction: column !important; 
    align-items: center !important; 
    justify-content: center !important; 
    text-align: center !important; 
    border-bottom: 1px solid rgba(0,0,0,0.05) !important; 
    position: relative !important; 
    overflow: hidden !important; 
    box-sizing: border-box !important;
}

@media (max-height: 800px) { section { height: auto !important; min-height: 100vh !important; } }

section:focus-visible { outline: none !important; box-shadow: inset 0 0 0 6px var(--warning) !important; transition: box-shadow 0.2s ease; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, [role="button"]:focus-visible, .filter-item:focus-visible { outline: 4px solid var(--warning) !important; outline-offset: 3px !important; border-radius: 6px; z-index: 10; }
main:focus-visible, body:focus-visible { outline: none !important; }

.skip-link { position: absolute; top: -100px; left: 50%; transform: translateX(-50%); background: #0B3D5E; color: #ffffff !important; padding: 12px 24px; font-weight: 800; z-index: 100000; border-radius: 0 0 10px 10px; text-decoration: none; box-shadow: 0 4px 15px rgba(0,0,0,0.3); transition: top 0.3s ease; }
.skip-link:focus, .skip-link:focus-visible { top: 0; outline: 3px solid #ffeb3b !important; }

.content-box { width: 100%; max-width: 1200px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; flex-grow: 0; }
.section-header { margin-bottom: 40px; width: 100%; text-align: center; display: flex; flex-direction: column; align-items: center; }
.section-header h2 { font-size: 2.5rem; margin-top: 5px; font-weight: 800; } 
.section-header span { color: var(--accent); font-weight: 800; text-transform: uppercase; font-size: 0.9rem; letter-spacing: 1px; }

/* ==========================================================================
   5. HERO SECTION
   ========================================================================== */
.hero { background: linear-gradient(rgba(255,255,255,0.92), rgba(255,255,255,0.92)), url('immagini/farmacia_esterna.jpg'); background-size: cover; background-position: center; background-attachment: fixed; }
.hero h1 { font-size: 4rem; margin-bottom: 20px; color: var(--primary); line-height: 1.1; font-weight: 800; }
.hero-slogan { font-size: 1.8rem; font-weight: 600; font-style: italic; color: var(--accent); margin-bottom: 35px !important; } 
.hero-buttons { display: flex; gap: 20px; flex-wrap: wrap; width: 100%; justify-content: center !important; }
.btn { padding: 16px 40px; border-radius: 50px; font-weight: 700; display: inline-block; transition: var(--transition-smooth); cursor: pointer; text-transform: uppercase; letter-spacing: 0.5px; font-size: 0.95rem;}
.btn-primary { background: var(--primary); color: white !important; border: none; box-shadow: 0 8px 20px rgba(11, 61, 94, 0.2); }
.btn-primary:hover { background: #051e2e; transform: translateY(-3px); box-shadow: 0 12px 25px rgba(11, 61, 94, 0.3); }
.btn-visit { background-color: white; color: var(--primary) !important; box-shadow: 0 5px 15px rgba(0,0,0,0.1); border: 2px solid var(--primary); display: inline-flex; align-items: center; gap: 10px;}
.btn-visit:hover { background-color: var(--primary); color: white !important; transform: translateY(-3px); box-shadow: 0 10px 25px rgba(11, 61, 94, 0.3); }

/* ==========================================================================
   6. CHI SIAMO
   ========================================================================== */
.about-section { background: var(--white); }
.about-container { display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 60px; width: 100%; height: 100%; }
.about-text { flex: 1; min-width: 300px; text-align: left; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
.about-text .section-header, .about-text h2 { text-align: left !important; align-items: flex-start !important; }
.about-text p { font-size: 1.1rem; color: #555; line-height: 1.8; margin-bottom: 25px; }
.about-image { flex: 1; display: flex; justify-content: center; align-items: center; }
.about-image img { width: 100%; max-width: 500px; border-radius: 20px; box-shadow: 0 20px 50px rgba(0,0,0,0.15); object-fit: cover; }

/* ==========================================================================
   7. VETRINA OFFERTE
   ========================================================================== */
section.premium-offers-master { 
    width: 100% !important; 
    height: auto !important; 
    min-height: 100vh !important; 
    padding-top: 185px !important; 
    padding-bottom: 60px !important; 
    display: flex !important; 
    flex-direction: column !important; 
    justify-content: flex-start !important; 
    overflow-y: visible !important; 
    overflow-x: hidden !important; 
    background-color: var(--light) !important;
}

.ordinary-offers-block { 
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    flex-grow: 1;
}

.premium-filters-pill { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 20px; }
.pill-btn { background: transparent; border: 1px solid #ddd; color: #444; border-radius: 50px; padding: 5px 16px; font-size: 0.75rem; font-weight: 700; cursor: pointer; transition: 0.2s; text-transform: uppercase; }
.pill-btn:hover, .pill-btn.active { background: #111; color: #fff; border-color: #111; box-shadow: 0 4px 15px rgba(0,0,0,0.2); }

.flyer-layout-container { display: flex; align-items: center; justify-content: flex-start; gap: 30px; width: 1040px !important; margin: 0 auto; padding: 0; }

.flyer-grid-wrapper { 
    width: 930px !important; 
    height: auto !important; 
    min-height: 680px !important; 
    flex-shrink: 0; 
    display: block; 
    overflow: visible !important; 
}

.flyer-grid { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 25px; 
    align-content: flex-start; 
    padding-bottom: 25px !important; 
}

.flyer-vertical-nav { width: 80px !important; height: 300px !important; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; background: #fff; border-radius: 50px; border: 1px solid #eaeaea; box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.flyer-arrow-vert { width: 50px; height: 50px; border-radius: 50%; background: #fff; color: var(--primary); border: 2px solid var(--primary); font-size: 1.3rem; cursor: pointer; transition: 0.3s; display: flex; align-items: center; justify-content: center; }
.flyer-arrow-vert:hover { background: var(--primary); color: #fff; transform: scale(1.1); box-shadow: 0 4px 10px rgba(11,61,94,0.2); }
.flyer-page-indicator-vert { font-weight: 800; color: #888; font-size: 1.2rem; }

.flyer-card { flex: 0 0 275px; width: 275px !important; height: 305px !important; background: #fff; border-radius: 12px; border: 1px solid #eaeaea; display: flex; flex-direction: column; padding: 12px; box-shadow: 0 2px 8px rgba(0,0,0,0.03); transition: 0.2s; outline: none; margin-bottom: 5px; cursor: pointer !important; position: relative; overflow: hidden; }
.flyer-card:hover { transform: translateY(-3px); border-color: var(--primary); box-shadow: 0 6px 15px rgba(11, 61, 94, 0.1); }
.flyer-img-box { position: relative; display: flex; align-items: center; justify-content: center; background: #fafbfc; border-radius: 8px; margin-bottom: 10px; height: 115px; }
.flyer-img-box img { max-width: 85%; max-height: 85%; mix-blend-mode: multiply; transition: 0.3s; }
.flyer-card:hover .flyer-img-box img { transform: scale(1.06); filter: brightness(0.95); }
.min-badges { position: absolute; bottom: 5px; left: 5px; z-index: 5; display: flex; gap: 4px; }
.min-badge-discount { background: #e0f7fa; color: #006064; font-size: 0.7rem; font-weight: 800; padding: 3px 6px; border-radius: 4px; }
.flyer-info { display: flex; flex-direction: column; flex-grow: 1; justify-content: space-between; }
.flyer-title { font-size: 0.9rem; font-weight: 700; color: var(--primary); line-height: 1.2; margin-bottom: 6px; text-align: center; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; height: 2.4em; }
.flyer-price-row { display: flex; flex-direction: column; align-items: center; margin-bottom: 8px; }
.flyer-old { font-size: 0.75rem; color: #aaa; text-decoration: line-through; line-height: 1; }
.flyer-new { font-size: 1.25rem; font-weight: 800; color: #d9534f; line-height: 1.1; }
.flyer-actions { display: flex; align-items: center; justify-content: center; gap: 8px; }
.flyer-btn-cart { flex-grow: 1; background: var(--primary); color: #fff !important; font-size: 0.75rem; font-weight: 800; padding: 8px 10px; border-radius: 6px; text-transform: uppercase; display: flex; align-items: center; justify-content: center; gap: 5px; z-index: 99; transition: 0.2s;}
.flyer-btn-cart:hover { background: #25D366; }
.min-btn-heart { color: #ccc; font-size: 1.15rem; cursor: pointer; z-index: 99; transition: 0.2s;}
.min-btn-heart:hover, .min-btn-heart.fas { color: #e91e63; }
.flyer-img-box::after { content: "\f00e"; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) scale(0.8); width: 45px; height: 45px; background: rgba(11, 61, 94, 0.85); color: #ffffff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; opacity: 0; visibility: hidden; transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1); z-index: 5; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
.flyer-card:hover .flyer-img-box::after { opacity: 1; visibility: visible; transform: translate(-50%, -50%) scale(1); }
.unstealable-img { pointer-events: none; user-select: none; -webkit-user-drag: none; -webkit-touch-callout: none; -moz-user-select: none; -ms-user-select: none; }
.glass-shield { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 10; background: transparent; cursor: default; }

/* ==========================================================================
   POPUP DETTAGLIATO PRODOTTI (FIX SCROLLBAR VERTICALE)
   ========================================================================== */
.product-modal-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); z-index: 1000000; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.3s ease; backdrop-filter: blur(4px); }
.product-modal-overlay.show { display: flex; opacity: 1; }

.product-modal-container { background: #fff; width: 90%; max-width: 750px; border-radius: 20px; padding: 30px; position: relative; box-shadow: 0 25px 50px rgba(0,0,0,0.3); transform: translateY(20px); transition: transform 0.3s ease; max-height: 85vh; overflow-y: auto; overflow-x: hidden !important; z-index: 100; }
.product-modal-overlay.show .product-modal-container { transform: translateY(0); }

.product-modal-close { position: absolute; top: 15px; right: 20px; background: none; border: none; font-size: 2.2rem; color: #888; cursor: pointer; transition: 0.2s; z-index: 110; }
.product-modal-close:hover { color: var(--danger); }

.product-modal-grid { display: flex; flex-direction: column; gap: 20px; align-items: center; width: 100%; overflow-x: hidden; }

.product-modal-img-box { width: 100%; max-width: 280px; aspect-ratio: 1; background: #fafbfc; border-radius: 12px; display: flex; align-items: center; justify-content: center; padding: 15px; border: 1px solid #eee; position: relative; z-index: 2; flex-shrink: 0; }
.product-modal-img-box img { max-width: 100%; max-height: 100%; object-fit: contain; mix-blend-mode: multiply; }

.product-modal-info { display: flex; flex-direction: column; text-align: left; position: relative; z-index: 2; width: 100%; min-width: 0; word-wrap: break-word; overflow-wrap: break-word; }
.product-modal-info h3 { font-size: 1.4rem; color: var(--primary); font-weight: 800; margin-bottom: 10px; text-align: left !important; }

.product-modal-price-row { margin-bottom: 20px; display: flex; align-items: baseline; gap: 12px; }

#desc-slider-viewport {
    margin-top: 15px; 
    border-top: 1px solid #eee; 
    padding-top: 15px;
    padding-right: 10px;
    width: 100%; 
    max-height: 300px;
    overflow-y: auto !important; 
    overflow-x: hidden !important; 
    position: relative; 
}

#desc-slider-viewport::-webkit-scrollbar { width: 6px; }
#desc-slider-viewport::-webkit-scrollbar-track { background: #f4f8fb; border-radius: 10px; }
#desc-slider-viewport::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 10px; }
#desc-slider-viewport::-webkit-scrollbar-thumb:hover { background: var(--primary); }

#modal-desc-track {
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    width: 100%;
    display: block !important; 
    padding-top: 15px;
}

.modal-full-desc-text { font-size: 1rem; color: #444; line-height: 1.6; margin: 0; padding-bottom: 5px; }

@media (min-width: 850px) {
    .product-modal-grid { flex-direction: row; align-items: flex-start; }
    .product-modal-img-box { width: 280px; }
    .product-modal-info { flex: 1; }
}

@media (max-width: 768px) {
    .product-modal-container { padding: 20px; max-height: 85vh; }
    #desc-slider-viewport { height: 16em; } 
    .product-modal-close {
        position: -webkit-sticky !important; 
        position: sticky !important;
        top: 5px; float: right; 
        margin-top: -10px; margin-right: -10px; margin-bottom: -40px; 
        background-color: #ffffff !important; 
        width: 42px; height: 42px; line-height: 40px;
        text-align: center; border-radius: 50%;
        font-size: 1.8rem !important; box-shadow: 0 4px 15px rgba(0,0,0,0.25); 
        z-index: 99999 !important;
    }
}

/* ==========================================================================
   8. SERVIZI E ALTRE SEZIONI
   ========================================================================== */
.services-section { background: var(--white) !important; }
.services-grid { display: grid !important; grid-template-columns: repeat(5, 1fr) !important; gap: 20px !important; width: 100% !important; max-width: 1300px !important; align-items: stretch !important; }
.service-card { background: var(--light) !important; padding: 30px 20px !important; border-radius: 20px !important; display: flex !important; flex-direction: column !important; align-items: center !important; text-align: center !important; border: 1px solid rgba(0,0,0,0.05) !important; box-shadow: 0 10px 20px rgba(0,0,0,0.02) !important; transition: var(--transition-smooth) !important; }
.service-card:hover { transform: translateY(-8px) !important; background: white !important; box-shadow: 0 20px 40px rgba(11, 61, 94, 0.1) !important; border-color: var(--accent) !important; }
.service-icon { font-size: 2.2rem !important; color: var(--accent) !important; margin-bottom: 15px !important; width: 70px !important; height: 70px !important; line-height: 70px !important; background: white !important; border-radius: 50% !important; display: inline-flex !important; align-items: center; justify-content: center; box-shadow: 0 8px 15px rgba(0,0,0,0.05) !important; border: 1px solid #eee !important; transition: 0.3s !important; }
.service-card.whatsapp-card .service-icon { color: #25D366 !important; }
.service-card.whatsapp-card:hover .service-icon { background: #25D366 !important; color: white !important; border-color: #25D366 !important; }
.service-card:not(.whatsapp-card):hover .service-icon { background: var(--primary) !important; color: white !important; transform: scale(1.1) !important; border-color: var(--primary) !important; }
.service-card h3 { font-size: 1.1rem !important; margin-bottom: 10px !important; color: var(--primary) !important; font-weight: 800 !important; line-height: 1.2 !important; }
.service-card p { color: #666 !important; font-size: 0.9rem !important; margin: 0 !important; line-height: 1.4 !important;}

/* ==========================================================================
   9. MAGAZINE SALUTE
   ========================================================================== */
.magazine-section { background-color: var(--light); }
.magazine-layout { display: flex; gap: 40px; width: 100%; max-width: 1200px; align-items: stretch; justify-content: center; }
.focus-article { flex: 2; background: #fff; border-radius: 20px; overflow: hidden; border: 1px solid #eee; transition: var(--transition-smooth); box-shadow: 0 10px 30px rgba(0,0,0,0.05); }
.focus-article:hover { transform: translateY(-5px); box-shadow: 0 20px 40px rgba(11, 61, 94, 0.15); }
.focus-image { width: 100%; height: 280px; position: relative; overflow: hidden; }
.focus-image img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s ease;}
.focus-article:hover .focus-image img { transform: scale(1.05); }
.focus-tag { position: absolute; top: 20px; left: 20px; background: var(--danger); color: white; padding: 6px 18px; border-radius: 50px; font-size: 0.8rem; font-weight: 800; text-transform: uppercase; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
.focus-content { padding: 35px; text-align: left; }
.focus-content h3 { text-align: left !important; font-size: 1.6rem; color: var(--primary); margin-bottom: 15px; font-weight: 800; }
.focus-content p { color: #555; margin-bottom: 20px; line-height: 1.7; text-align: left; font-size: 1.05rem; }
.btn-text { color: var(--accent); font-weight: 800; text-transform: uppercase; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 8px; transition: var(--transition-smooth);}
.btn-text:hover { color: var(--warning); padding-left: 5px; }

.tips-sidebar { flex: 1; display: flex; flex-direction: column; justify-content: space-between; gap: 20px; width: 100%; }
.sidebar-widget { background: #fff; padding: 25px; border-radius: 20px; border: 1px solid #eee; margin:0; box-shadow: 0 5px 20px rgba(0,0,0,0.03); }
.sidebar-title { margin-top: 0; font-size: 1.1rem; text-align: left; color: var(--primary); font-weight: 800; border-bottom: 2px solid #f0f0f0; padding-bottom: 10px; margin-bottom: 15px;}

/* ==========================================================================
   10. FARMADAY
   ========================================================================== */
.farmaday-section { background-color: var(--primary); background-image: linear-gradient(135deg, var(--primary) 0%, #051e2e 100%); color: white; }
.farmaday-section .section-header h2 { color: #ffffff !important; }
.farmaday-desc { color: #dbebf5; font-size: 1.05rem; line-height: 1.6; max-width: 900px; margin: 0 auto 30px auto; font-weight: 400; text-align: center; }
.farmaday-unified-card { background: white; border-radius: 20px; box-shadow: 0 15px 40px rgba(0,0,0,0.15); padding: 40px; width: 100%; max-width: 1050px; margin: 0 auto; }
.farmaday-grid { display: grid; grid-template-columns: 300px 1fr; gap: 40px; align-items: stretch; }
.today-column { display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; border-right: 1px solid #f0f0f0; padding-right: 40px; }
.archive-column { display: flex; flex-direction: column; justify-content: center; }
.iframe-container { width: 100%; height: 240px !important; position: relative; flex-grow: 1; flex-shrink: 0; }
.pagination-controls { display: flex; align-items: center; justify-content: center; gap: 15px; padding-top: 15px; border-top: 1px solid #f0f0f0; margin-top: 5px; }
.pagination-select { padding: 6px 12px; border-radius: 6px; border: 1px solid #dcdcdc; background: #f8f9fa; font-family: inherit; font-weight: 600; color: #333; cursor: pointer; outline: none; }
.pagination-arrow { background: none; border: none; font-size: 1.1rem; color: #555; cursor: pointer; transition: 0.2s; padding: 5px; }
.pagination-arrow:hover { color: var(--primary); transform: scale(1.2); }
.card-icon-big { font-size: 4.5rem !important; color: var(--accent) !important; margin-bottom: 20px; display: block !important; }

/* ==========================================================================
   11. DOVE SIAMO
   ========================================================================== */
.location-section-final { background-color: #f8fbff !important; }
.content-box-final { width: 100% !important; max-width: 1000px !important; margin: 0 auto !important; display: flex !important; flex-direction: row !important; align-items: stretch !important; gap: 40px !important; background: white !important; padding: 40px !important; border-radius: 20px !important; box-shadow: 0 15px 40px rgba(0,0,0,0.08) !important; border: 1px solid #eee !important; }
.map-box-final { flex: 1.2 !important; width: 100% !important; min-height: 350px !important; height: 350px !important; border-radius: 15px !important; overflow: hidden !important; border: 1px solid #eee !important; position: relative; z-index: 1; }
#google-map-container iframe, .map-box-final iframe { width: 100% !important; height: 100% !important; min-height: 350px !important; display: block !important; border: 0 !important; }
.info-box-final { flex: 1 !important; display: flex !important; flex-direction: column !important; justify-content: center !important; text-align: left !important; }
.info-grid { display: flex !important; flex-direction: column !important; gap: 20px !important; width: 100% !important; margin-bottom: 30px !important; }
.info-item { display: flex !important; align-items: center !important; gap: 18px !important; padding: 15px 20px !important; background: #ffffff !important; border-radius: 15px !important; border: 1px solid #eee !important; box-shadow: 0 4px 15px rgba(0,0,0,0.02) !important; }
.icon-circle { width: 45px !important; height: 45px !important; font-size: 1.1rem !important; background: var(--light) !important; color: var(--primary) !important; border-radius: 50% !important; display: flex !important; align-items: center !important; justify-content: center !important; flex-shrink: 0 !important; }
.info-item h4 { font-size: 0.8rem !important; margin: 0 0 4px 0 !important; color: #666 !important; text-transform: uppercase; font-weight: 800; letter-spacing: 1px;}
.info-item p { font-size: 1.05rem !important; margin: 0 !important; color: var(--primary) !important; font-weight: 700 !important; }
.btn-directions-final { background: var(--primary) !important; color: white !important; padding: 16px !important; border-radius: 50px !important; font-weight: 800; font-size: 0.95rem !important; text-align: center !important; display: block !important; width: 100% !important; text-transform: uppercase !important; text-decoration: none !important; transition: var(--transition-smooth); box-shadow: 0 8px 20px rgba(11, 61, 94, 0.2);}
.btn-directions-final:hover { transform: translateY(-3px); box-shadow: 0 15px 30px rgba(11, 61, 94, 0.3); background: #082d45 !important; }

/* ==========================================================================
   12. FOOTER & LEGAL
   ========================================================================== */
footer { background-color: #082d45; color: #ffffff; padding: 60px 20px 40px; font-size: 0.95rem; position: relative; z-index: 10; border-top: 5px solid var(--warning); width: 100%; display: flex; flex-direction: column; align-items: center; scroll-snap-align: start; min-height: auto; height: auto; justify-content: flex-start; }
.footer-container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px 40px; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 50px; justify-items: center; text-align: center; }
.footer-col { width: 100%; max-width: 350px; display:flex; flex-direction:column; align-items:center; }
.footer-col h4 { color: #ffffff; font-size: 1.2rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 25px; text-align: center; border-bottom: 2px solid var(--accent); padding-bottom: 10px; display:inline-block; }
.footer-desc { color: #dbebf5; line-height: 1.6; margin-bottom: 10px;}
.footer-social-box { display: flex; flex-direction: column; gap: 15px; margin-bottom: 20px; width: 100%; align-items: center; }
.social-btn { display: inline-flex; align-items: center; justify-content: center; padding: 14px 25px; border-radius: 50px; text-decoration: none; color: white !important; font-weight: 700; transition: var(--transition-smooth); width: 100%; max-width: 250px; gap: 10px; border: 1px solid transparent; font-size: 0.95rem;}
.social-btn.facebook-footer { background: #1877F2 !important; box-shadow: 0 4px 15px rgba(24, 119, 242, 0.3); } 
.social-btn.facebook-footer:hover { background: #1461c7 !important; transform: translateY(-2px); }
.social-btn.whatsapp-footer { background: var(--success); box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3); } 
.social-btn.whatsapp-footer:hover { background: #218838 !important; transform: translateY(-2px); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 25px; text-align: center; font-size: 0.85rem; color: #a5c2d6; display: flex; flex-direction: column; gap: 10px; width: 100%; margin-bottom: 0 !important; }

/* ==========================================================================
   13. COOKIE BANNER E MODALI
   ========================================================================== */
.cookie-banner { position: fixed; bottom: 0; left: 0; width: 100%; background: var(--primary); color: #ffffff; box-shadow: 0 -10px 30px rgba(0,0,0,0.3); padding: 25px 20px; z-index: 120000; animation: slideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1); transition: transform 0.4s ease; }
.cookie-content { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; gap: 30px; }
.cookie-text h4 { color: #fff; text-align: left; font-size: 1.1rem; margin-bottom: 5px; font-weight: 800; text-transform: uppercase; }
.cookie-text p { margin: 0; font-size: 0.9rem; color: #dbebf5; }
.cookie-buttons { display: flex; gap: 12px; flex-shrink: 0; }
.btn-cookie-accept { background-color: #fff; color: var(--primary); border: 2px solid white; padding: 12px 30px; border-radius: 50px; font-weight: 800; cursor: pointer; transition: 0.2s; box-shadow: 0 4px 10px rgba(0,0,0,0.2); text-transform: uppercase; font-size: 0.85rem;}
.btn-cookie-accept:hover { background-color: #f0f0f0; transform: translateY(-2px); }
.btn-cookie-decline { background-color: transparent; border: 2px solid rgba(255,255,255,0.4); color: white; padding: 10px 25px; border-radius: 50px; font-weight: 700; cursor: pointer; transition: 0.2s; text-transform: uppercase; font-size: 0.85rem;}
.btn-cookie-decline:hover { background-color: rgba(255,255,255,0.1); border-color: white;}

.modal-overlay { display: none !important; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.8); z-index: 1000000; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.3s ease; backdrop-filter: blur(5px); }
.modal-overlay.show { display: flex !important; opacity: 1; }
.modal-container { background: white; width: 90%; max-width: 420px; border-radius: 25px; padding: 40px; position: relative; box-shadow: 0 25px 60px rgba(0,0,0,0.5); transform: translateY(20px); transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.modal-overlay.show .modal-container { transform: translateY(0); }
.modal-close { position: absolute; top: 15px; right: 20px; background: none; border: none; font-size: 2rem; color: #999; cursor: pointer; transition: 0.2s; }
.modal-close:hover { color: var(--danger); transform: scale(1.1); }
.auth-tabs { display: flex; border-bottom: 2px solid #eee; margin-bottom: 30px; }
.tab-btn { flex: 1; background: none; border: none; padding: 15px; font-size: 1.05rem; font-weight: 800; color: #aaa; cursor: pointer; border-bottom: 3px solid transparent; transition: 0.3s; text-transform: uppercase; letter-spacing: 0.5px;}
.tab-btn.active { color: var(--primary); border-bottom: 3px solid var(--primary); }

#modal-form-login, #modal-form-otp, #modal-form-register, #modal-form-forgot { display: none; animation: fadeIn 0.4s; }
#modal-form-login.active, #modal-form-register.active, #modal-form-forgot.active { display: block; }

.input-group { position: relative; margin-bottom: 20px; }
.input-group i.fa-user, .input-group i.fa-envelope, .input-group i.fa-lock { position: absolute; left: 20px; top: 50%; transform: translateY(-50%); color: var(--primary); font-size: 1.1rem;}
.input-group input { width: 100%; padding: 15px 20px 15px 55px; border: 2px solid #eee; border-radius: 50px; outline: none; transition: 0.3s; font-size: 1rem; font-family: 'Open Sans', sans-serif;}
.input-group input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(32, 93, 134, 0.1); background-color: #fafbfc;}
.btn-full { width: 100%; padding: 15px; border: none; border-radius: 50px; background: var(--primary); color: white; font-weight: 800; cursor: pointer; margin-top: 10px; font-size: 1.05rem; transition: var(--transition-smooth); text-transform: uppercase; letter-spacing: 1px; box-shadow: 0 5px 15px rgba(11, 61, 94, 0.2);}
.btn-full:hover { background: #082d45; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(11, 61, 94, 0.3);}

/* ==========================================================================
   16. CHATBOT E BOTTONI BASE 
   ========================================================================== */
body.chat-open #chat-toggle-btn { opacity: 0 !important; pointer-events: none; transform: scale(0); }

#chat-container { 
    position: fixed; bottom: 110px !important; right: 30px !important; 
    width: 380px; height: 600px; max-height: 80vh;
    background: white; border-radius: 25px !important; 
    box-shadow: 0 25px 70px rgba(0,0,0,0.3); display: flex; flex-direction: column; 
    z-index: 1000001 !important; opacity: 0; visibility: hidden; transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1); border: 1px solid rgba(0,0,0,0.08); overflow: hidden;
}
#chat-container.active { opacity: 1; visibility: visible; transform: translateY(0); }

.chat-header { background: linear-gradient(135deg, var(--primary), #0f4c75) !important; color: white !important; padding: 20px 25px !important; display: flex !important; justify-content: space-between !important; align-items: center !important; height: 75px !important; border-top-left-radius: 25px !important; border-top-right-radius: 25px !important; }
.chat-title-container { display: flex !important; flex-direction: column !important; align-items: flex-start !important; }
.chat-title-container h4 { color: #ffffff !important; margin: 0 !important; text-align: left !important; font-size: 1.2rem !important; font-weight: 800 !important; line-height: 1.2 !important; }
.chat-status-badge { background: rgba(255, 255, 255, 0.2) !important; padding: 4px 10px !important; border-radius: 20px !important; font-size: 0.75rem !important; display: inline-flex !important; align-items: center !important; margin-top: 5px !important; color: white !important; font-weight: 700 !important; }
.chat-status-badge .dot { width: 8px !important; height: 8px !important; background: #25d366 !important; border-radius: 50% !important; margin-right: 8px !important; box-shadow: 0 0 8px #25d366 !important; animation: pulse-dot 1.5s infinite alternate !important; }
.chat-close-btn { background: none; border: none; color: white; cursor: pointer; font-size: 2rem; line-height: 1; padding: 0 5px; margin-top: -15px; transition: 0.2s; opacity: 0.8; }
.chat-close-btn:hover { opacity: 1; transform: scale(1.1); }

#chat-body { flex: 1; padding: 25px; overflow-y: auto; background-color: #f8fafc; display: flex; flex-direction: column; gap: 15px; }
.message { padding: 12px 18px; border-radius: 20px; max-width: 85%; line-height: 1.5; font-size: 0.95rem; }
.message.bot { background: white; color: #333; align-self: flex-start; border-bottom-left-radius: 5px; border: 1px solid #eee; box-shadow: 0 2px 5px rgba(0,0,0,0.02);}
.message.user { background: var(--primary); color: white; align-self: flex-end; border-bottom-right-radius: 5px; box-shadow: 0 2px 5px rgba(11, 61, 94, 0.2);}
.chat-input-area { display: none !important; }
#chat-suggestions { padding: 15px !important; background: #fff !important; border-top: 1px solid #f0f0f0 !important; display: flex !important; flex-wrap: wrap !important; justify-content: center !important; gap: 10px !important; border-bottom-left-radius: 25px !important; border-bottom-right-radius: 25px !important; }
.chat-chip { background: #f1f8ff !important; color: var(--primary) !important; border: 1px solid var(--primary) !important; padding: 8px 16px !important; border-radius: 50px !important; font-size: 0.85rem !important; font-weight: 700 !important; cursor: pointer !important; transition: var(--transition-smooth) !important; display: inline-flex !important; align-items: center !important; gap: 8px !important; white-space: nowrap !important; }
.chat-chip:hover { background: var(--primary) !important; color: white !important; transform: translateY(-2px) !important; box-shadow: 0 5px 15px rgba(11, 61, 94, 0.2) !important; }

/* ==========================================================================
   18. STILE MODULO OTP
   ========================================================================== */
#2fa-loading, #2fa-setup-view, #2fa-active-view { display: none; width: 100%; }
.otp-icon-animated { width: 80px; height: 80px; background: linear-gradient(135deg, #e3f2fd, #bbdefb); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; box-shadow: 0 10px 20px rgba(11, 61, 94, 0.1); position: relative; }
.otp-icon-animated::before { content: ''; position: absolute; width: 100%; height: 100%; border-radius: 50%; border: 2px solid #bbdefb; animation: pulse-ring 2s infinite cubic-bezier(0.215, 0.61, 0.355, 1); }
.otp-icon-animated i { font-size: 2.2rem; color: var(--primary); z-index: 2; }
@keyframes pulse-ring { 0% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.5); opacity: 0; } }
.otp-title { color: var(--primary); font-size: 1.4rem; font-weight: 800; margin: 0 0 8px 0; }
.otp-subtitle { font-size: 0.95rem; color: #666; line-height: 1.4; margin: 0; }
.otp-input-container { margin-bottom: 10px; position: relative; }
#modal-form-otp .otp-input-container input { width: 100%; padding: 18px 20px; border: 2px solid #dcebf7; border-radius: 16px; outline: none; transition: var(--transition-smooth); font-size: 2.2rem; letter-spacing: 18px; font-weight: 800; text-align: center; background: #f8fbff; color: var(--primary); font-family: 'Montserrat', monospace, sans-serif; box-shadow: inset 0 2px 5px rgba(0,0,0,0.02); }
#modal-form-otp .otp-input-container input::placeholder { color: #c5d6e6; font-weight: 400; letter-spacing: 12px; }
#modal-form-otp .otp-input-container input:focus { border-color: var(--primary); background-color: #ffffff; box-shadow: 0 8px 20px rgba(11, 61, 94, 0.08); transform: translateY(-2px); }
.otp-feedback-msg { text-align: center; font-size: 0.95rem; font-weight: 700; min-height: 24px; margin-bottom: 20px; color: var(--danger); }
.btn-otp-submit { width: 100%; padding: 16px; background: linear-gradient(135deg, var(--primary), #0a2d45); color: white; font-weight: 800; border: none; border-radius: 12px; cursor: pointer; font-size: 1.05rem; transition: var(--transition-smooth); text-transform: uppercase; letter-spacing: 1px; display: flex; align-items: center; justify-content: center; gap: 10px; box-shadow: 0 8px 20px rgba(11, 61, 94, 0.25); }
.btn-otp-submit:hover { transform: translateY(-3px); box-shadow: 0 12px 25px rgba(11, 61, 94, 0.35); background: #08253a; }


/* ==========================================================================
   17. GESTIONE STRUMENTI (DESKTOP CLASSICO VS PILLOLA MOBILE)
   ========================================================================== */

/* --------------------------------------------------------
   SU DESKTOP E SCHERMI GRANDI (PC)
   -------------------------------------------------------- */
@media screen and (min-width: 1025px) {
    .pill-left-section, .pill-right-section { display: contents; }
    .chat-txt-mobile, .testo-strumento { display: none !important; }
    .strumenti-master-container { display: block; }
    .mobile-voice-btn { display: none !important; }
    
    /* Posizioni classiche dei pulsanti slegati */
    .float-btn-reader { position: fixed; bottom: 30px; left: 30px; background-color: var(--primary); color: white; border: none; border-radius: 50px; padding: 14px 24px; font-size: 0.95rem; font-weight: 700; cursor: pointer; box-shadow: 0 10px 30px rgba(11, 61, 94, 0.4); z-index: 99999; display: inline-flex; align-items: center; gap: 10px; }
    .float-btn-reader .testo-strumento { display: inline-block !important; }
    .float-btn-reader:hover { background-color: var(--accent); transform: translateY(-3px) scale(1.05); }
    
    .float-btn.btn-chat { position: fixed; bottom: 30px; right: 30px; width: 70px; height: 70px; border-radius: 50%; border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 32px; color: white; background: var(--primary); box-shadow: 0 10px 30px rgba(11, 61, 94, 0.4); z-index: 1000000; transition: 0.3s ease; }
    .float-btn.btn-chat:hover { transform: scale(1.1) rotate(5deg); background: #082d45; }
    
    /* Player TTS Desktop */
    .tts-player-bar { position: fixed; bottom: 30px; left: 30px; background-color: var(--primary); color: white; border-radius: 50px; padding: 10px 20px; box-shadow: 0 10px 30px rgba(11, 61, 94, 0.4); display: flex; align-items: center; gap: 10px; z-index: 99999; }
    .tts-player-btn { background: none; border: none; color: white; cursor: pointer; font-size: 0.9rem; font-weight: 700; padding: 8px 14px; border-radius: 20px; display: flex; align-items: center; gap: 6px; }
    .tts-player-btn:hover { background: rgba(255, 255, 255, 0.15); }
    .tts-player-btn.stop-btn { color: #ffb3b3; }
    .tts-player-btn.stop-btn:hover { background: rgba(217, 83, 79, 0.2); color: #fff; }
}

/* --------------------------------------------------------
   SU MOBILE E TABLET (La Pillola Azzurrina)
   -------------------------------------------------------- */
@media screen and (max-width: 1024px) {
    
    /* La Pillola in basso al centro */
    .strumenti-master-container {
        display: flex !important; 
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: stretch !important;
        position: fixed !important;
        bottom: 15px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 92% !important;
        max-width: 400px !important;
        background-color: #e3f2fd !important;
        border: 2px solid #bbdefb !important;
        border-radius: 50px !important;
        padding: 5px !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15) !important;
        z-index: 9999 !important;
    }

    /* Le Due Stanze Matematiche (66% e 33%) */
    .pill-left-section {
        display: flex !important;
        flex-direction: row !important;
        width: 66% !important;
        justify-content: space-evenly !important;
        align-items: center !important;
    }

    .pill-right-section {
        display: flex !important;
        flex-direction: row !important;
        width: 33% !important;
        justify-content: center !important;
        align-items: center !important;
        border-left: 1px solid rgba(11, 61, 94, 0.15) !important; /* Divisorio elegante */
    }

    /* I 3 Bottoni Interni */
    .strumenti-master-container button {
        position: static !important;
        background: transparent !important;
        border: none !important;
        color: #0B3D5E !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 5px !important;
        flex: 1 !important; 
        height: auto !important;
        width: 100% !important;
        padding: 6px 0 !important;
        margin: 0 !important;
        border-radius: 15px !important;
        box-shadow: none !important;
        transform: none !important;
        transition: transform 0.2s ease, color 0.3s ease !important;
    }

    /* Reset totale icone e testi per allineamento millimetrico */
    .strumenti-master-container button i { font-size: 1.4rem !important; color: #008542 !important; margin: 0 !important; padding: 0 !important; display: block !important; line-height: 1 !important; }
    .testo-strumento { display: block !important; line-height: 1 !important; font-size: 0.75rem !important; font-weight: 700 !important; margin: 0 !important; padding: 0 !important; }
    .chat-txt-mobile { display: block !important; }

    /* Animazione Click */
    .strumenti-master-container button:active { transform: scale(0.9) !important; }

    /* EFFETTO ASCOLTA (Rosso e pulsante) */
    .strumenti-master-container button.reading i,
    .strumenti-master-container button:has(.fa-stop) i {
        color: #d9534f !important;
        animation: pulse-stop-btn 1.2s infinite alternate;
    }
    .strumenti-master-container button.reading .testo-strumento,
    .strumenti-master-container button:has(.fa-stop) .testo-strumento { color: #d9534f !important; }

    @keyframes pulse-stop-btn {
        0% { transform: scale(1); opacity: 1; filter: drop-shadow(0 0 0 rgba(217,83,79,0)); }
        100% { transform: scale(1.15); opacity: 0.85; filter: drop-shadow(0 0 8px rgba(217,83,79,0.6)); }
    }

    /* ========================================================
       IL PLAYER FLUTTUANTE (TTS) - La nuvoletta sopra la pillola
       ======================================================== */
    .tts-player-bar {
        position: fixed !important;
        bottom: 85px !important; /* Si solleva perfettamente sopra la pillola */
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: auto !important;
        min-width: 150px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 20px !important;
        padding: 10px 25px !important;
        border-radius: 50px !important;
        background-color: #0B3D5E !important;
        box-shadow: 0 8px 25px rgba(0,0,0,0.3) !important;
        z-index: 100000 !important;
    }
    
    /* Bottoni Play e Stop orizzontali all'interno della nuvoletta */
    .tts-player-bar button {
        position: static !important;
        background: transparent !important;
        flex-direction: row !important; 
        padding: 5px !important;
        margin: 0 !important;
        border: none !important;
        box-shadow: none !important;
        color: white !important;
        transform: none !important;
    }
    .tts-player-bar button i { font-size: 1.6rem !important; color: white !important; display: inline-block !important; margin: 0 !important; padding: 0 !important; }
    
    /* Colori: Verde (Play) / Rosso (Stop) */
    .tts-player-bar button.play-btn i, .tts-player-bar button:first-child i { color: #25d366 !important; }
    .tts-player-bar button.stop-btn i, .tts-player-bar button:last-child i { color: #d9534f !important; }
}

/* ==========================================================================
   19. MEDIA QUERIES GLOBALI
   ========================================================================== */
@media (max-width: 1080px) {
    .flyer-layout-container { width: 100% !important; max-width: 720px !important; }
    .flyer-grid-wrapper { width: 100% !important; }
    .flyer-grid { width: 100% !important; justify-content: center; }
}

@media (max-width: 1024px) {
    .hamburger { display: block; z-index: 1001; }
    
    .nav-links { 
        position: absolute; top: 100%; left: 0; width: 100%; 
        height: calc(100vh - var(--header-h) - var(--top-h)); 
        background-color: white; flex-direction: column; padding: 0 0 50px 0; margin: 0; gap: 0; 
        transform: translateX(100%); transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1); 
        border-top: 1px solid #eee; display: flex; z-index: 10001; 
        justify-content: flex-start; align-items: stretch; overflow-y: auto; 
        -webkit-overflow-scrolling: touch;
    }
    .nav-links.active { transform: translateX(0); }
    .nav-links li { width: 100%; border-bottom: 1px solid #f5f5f5; display: block; margin: 0; padding: 0;}
    .nav-links a { 
        width: 100%; display: block; padding: 22px 20px !important; 
        background: transparent !important; border-radius: 0 !important; 
        text-align: center; font-size: 1.2rem; border: none !important;
        color: var(--primary) !important; font-weight: 800; margin: 0; box-shadow: none !important;
    }
    .nav-links a:hover { background-color: #f9f9f9 !important; color: var(--accent) !important; transform: none !important;}
    
    .mobile-only { display: flex !important; flex-direction: column !important; align-items: center !important; width: 100%; margin-top: 20px; padding: 0 20px 100px; border-bottom: none; gap: 15px; }
    .mobile-only span { font-size: 1.2rem !important; color: var(--primary) !important; font-weight: 800 !important; margin-bottom: 5px !important; }
    .mobile-only a { width: 100%; max-width: 350px; display: block; padding: 16px !important; background: var(--primary) !important; color: white !important; border-radius: 50px !important; text-align: center; box-shadow: 0 8px 20px rgba(11,61,94,0.2) !important; font-size: 1rem; text-transform: uppercase; letter-spacing: 1px; margin: 0 !important; }
    .mobile-only a[onclick*="Logout"] { background: var(--danger) !important; box-shadow: 0 8px 20px rgba(220, 53, 69, 0.2) !important; }
    
    .about-container { flex-direction: column !important; text-align: center; gap: 30px; }
    .about-text { align-items: center; text-align: center; }
    .about-text .section-header, .about-text h2 { text-align: center !important; align-items: center !important; }
    .services-grid { grid-template-columns: repeat(3, 1fr) !important; max-width: 800px !important; } 
    
    .farmaday-grid { grid-template-columns: 1fr; gap: 30px; }
    .today-column { border-right: none; border-bottom: 1px solid #f0f0f0; padding-right: 0; padding-bottom: 30px; }
    .card-icon-big { display: none !important; }
    
    .magazine-layout { flex-direction: column; }
}

@keyframes pulse-mic-green { 0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.6); } 70% { transform: scale(1.1); box-shadow: 0 0 0 15px rgba(40, 167, 69, 0); } 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(40, 167, 69, 0); } }

@media (max-width: 992px) {
    #desktop-auth-box { display: none !important; }
    .container-top { justify-content: center; gap: 10px; }
}

@media (max-width: 850px) {
    section.premium-offers-master { 
        height: auto !important; 
        min-height: auto !important; 
        padding-top: 130px !important;
        padding-bottom: 20px !important; 
    }

    .flyer-layout-container { flex-direction: column; width: 100% !important; padding: 0 !important; }
    .flyer-grid-wrapper { height: auto !important; width: 100vw !important; margin: 0 !important; }
    
    .flyer-grid { 
        width: 100vw !important; 
        display: flex !important; 
        flex-wrap: nowrap !important; 
        overflow-x: auto !important; 
        overflow-y: hidden !important; 
        scroll-snap-type: x mandatory !important; 
        -webkit-overflow-scrolling: touch !important; 
        gap: calc(100vw - 300px) !important; 
        padding: 20px calc(50vw - 150px) !important; 
        -ms-overflow-style: none; scrollbar-width: none; 
    }
    .flyer-grid::-webkit-scrollbar { display: none; }
    
    .flyer-card { 
        flex: 0 0 300px !important; 
        width: 300px !important; 
        max-width: 300px !important; 
        scroll-snap-align: center !important; 
        margin: 0 !important; 
    }
    
    .flyer-vertical-nav { display: none !important; }
    .empty-card { display: none !important; }
}

@media (max-width: 480px) {
    .services-grid { grid-template-columns: 1fr !important; }
    .about-image img { max-width: 100%; border-radius: 15px;}
    .hero h1 { font-size: 2.2rem; }
    
    .premium-filters-pill { margin-bottom: 15px; gap: 6px; }
    .pill-btn { font-size: 0.75rem; padding: 6px 14px; }
}