/* ============================================================
   MASSOTERAPIA MORENA BRANCA — style.css  v1.2
   FIX MOBILE: pannello nav a tutto schermo + dropdown ad accordion
   (niente più display:grid/block che si rompe su alcuni browser)
   ============================================================ */

/* ── 1. DESIGN TOKENS ─────────────────────────────────────── */
:root {
    --primary:        #8071B1;
    --primary-dark:   #5D5187;
    --primary-light:  #A090CC;
    --secondary:      #CABBFC;
    --secondary-dark: #A899D8;
    --accent:         #E8E2FA;
    --accent-warm:    #F5F0FF;
    --white:          #FFFFFF;
    --off-white:      #FAF9FD;
    --gray-50:        #F4F2F9;
    --gray-100:       #EAE7F3;
    --gray-200:       #D5D0E8;
    --gray-400:       #9B95B7;
    --gray-600:       #5E5875;
    --gray-800:       #2D2840;
    --dark:           #1A1628;
    --text-primary:   #1A1628;
    --text-secondary: #3D3657;
    --text-muted:     #5E5875;
    --link-color:     #5D5187;
    --link-hover:     #8071B1;
    --success:        #2E7D32;
    --error:          #C62828;
    --focus-ring:     0 0 0 3px rgba(128,113,177,0.45);
    --font-display:   'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-body:      'Jost', 'Segoe UI', Arial, sans-serif;
    --space-xs: 0.25rem; --space-sm: 0.5rem; --space-md: 1rem;
    --space-lg: 1.5rem; --space-xl: 2rem; --space-2xl: 3rem; --space-3xl: 5rem;
    --container-max: 1180px;
    --section-pad:   5rem;
    --border-radius: 12px;
    --border-radius-sm: 6px;
    --transition: 0.28s ease;
    --shadow-sm: 0 2px 8px rgba(26,22,40,0.06);
    --shadow-md: 0 4px 20px rgba(26,22,40,0.10);
    --shadow-lg: 0 8px 40px rgba(26,22,40,0.14);
    --header-h: 80px;
}

/* ── 2. RESET & BASE ──────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
    font-family: var(--font-body); font-size: 1rem; line-height: 1.7;
    color: var(--text-primary); background: var(--white);
    overflow-x: hidden; padding-top: var(--header-h);
}
:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: var(--border-radius-sm); }
:focus:not(:focus-visible) { outline: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border-width: 0; }
.skip-link { position: absolute; top: -100%; left: 1rem; z-index: 9999; background: var(--primary-dark); color: var(--white); padding: 0.6rem 1.2rem; border-radius: 0 0 8px 8px; font-weight: 600; text-decoration: none; transition: top 0.2s; }
.skip-link:focus { top: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link-color); transition: color var(--transition); }
a:hover { color: var(--link-hover); }
ul[role="list"], ol[role="list"] { list-style: none; }
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ── 3. TIPOGRAFIA ────────────────────────────────────────── */
h1,h2,h3,h4,h5,h6 { font-family: var(--font-display); color: var(--text-primary); line-height: 1.2; font-weight: 500; letter-spacing: 0.01em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 2rem); }
h4 { font-size: 1.25rem; font-family: var(--font-body); font-weight: 600; }
p { margin-bottom: var(--space-md); }
p:last-child { margin-bottom: 0; }
.text-center { text-align: center; }
.lead { font-size: 1.15rem; color: var(--text-secondary); line-height: 1.75; }
strong { font-weight: 600; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); text-align: center; margin-bottom: var(--space-sm); color: var(--primary-dark); }
.section-title::after { content: ''; display: block; width: 60px; height: 3px; background: linear-gradient(90deg, var(--primary), var(--secondary)); margin: 0.8rem auto 0; border-radius: 2px; }
.section-subtitle { text-align: center; color: var(--text-muted); font-size: 1.05rem; margin-bottom: var(--space-2xl); max-width: 650px; margin-left: auto; margin-right: auto; }
.tagline { font-size: 0.85rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--primary); margin-bottom: 0.75rem; }

/* ── 4. LAYOUT ────────────────────────────────────────────── */
.container { width: 100%; max-width: var(--container-max); margin: 0 auto; padding: 0 var(--space-lg); }
.section-padding { padding: var(--section-pad) 0; }
.section-padding-sm { padding: 3rem 0; }
.row { display: flex; flex-wrap: wrap; margin: 0 -0.75rem; }
[class^="col-"] { padding: 0 0.75rem; }
.col-12 { width: 100%; }
.col-md-4 { width: 100%; } .col-md-6 { width: 100%; }
.col-lg-4 { width: 100%; } .col-lg-6 { width: 100%; } .col-lg-8 { width: 100%; }
@media (min-width: 768px) { .col-md-4 { width: 33.3333%; } .col-md-6 { width: 50%; } }
@media (min-width: 992px) { .col-lg-4 { width: 33.3333%; } .col-lg-6 { width: 50%; } .col-lg-8 { width: 66.6667%; } }
.mb-4 { margin-bottom: 1.5rem; } .mb-0 { margin-bottom: 0; }
.mt-3 { margin-top: 1rem; } .mt-4 { margin-top: 1.5rem; } .mt-5 { margin-top: 3rem; }
.align-items-center { align-items: center; }
.justify-content-center { justify-content: center; }
.d-flex { display: flex; } .flex-wrap { flex-wrap: wrap; }
.gap-2 { gap: 0.5rem; } .gap-3 { gap: 1rem; }
.bg-accent { background-color: var(--accent); }
.bg-off-white { background-color: var(--off-white); }

/* ── 5. BUTTONS ───────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.75rem 1.8rem; border: 2px solid transparent; border-radius: 50px; font-family: var(--font-body); font-size: 0.85rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: all var(--transition); white-space: nowrap; }
.btn:focus-visible { box-shadow: var(--focus-ring); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: var(--white); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-secondary { background: transparent; border-color: var(--primary); color: var(--primary); }
.btn-secondary:hover { background: var(--primary); color: var(--white); transform: translateY(-2px); }
.btn-light { background: var(--white); border-color: var(--white); color: var(--primary-dark); }
.btn-light:hover { background: var(--accent); border-color: var(--accent); color: var(--primary-dark); }
.btn-outline-light { background: transparent; border-color: rgba(255,255,255,0.7); color: var(--white); }
.btn-outline-light:hover { background: rgba(255,255,255,0.15); border-color: var(--white); color: var(--white); }
.btn-lg { padding: 1rem 2.4rem; font-size: 0.9rem; }
.btn-sm { padding: 0.5rem 1.2rem; font-size: 0.78rem; }
.btn-link-style { background: none; border: none; padding: 0; font: inherit; color: var(--link-color); cursor: pointer; text-decoration: underline; font-size: 0.85rem; }
.btn-link-style:hover { color: var(--link-hover); }

/* ═══════════════════════════════════════════════════════════
   ── 6. HEADER & NAV — DESKTOP ──────────────────────────────
   ═══════════════════════════════════════════════════════════ */
.main-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    height: var(--header-h);
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition: all var(--transition);
}
.main-header.scrolled { box-shadow: var(--shadow-sm); border-bottom-color: var(--gray-100); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.site-logo img { height: 52px; width: auto; }

.main-nav { display: flex; align-items: center; }
.main-nav > ul { display: flex; align-items: center; gap: 0.1rem; list-style: none; margin: 0; padding: 0; }
.main-nav > ul > li { position: relative; }
.main-nav > ul > li > a {
    display: flex; align-items: center; gap: 0.35rem;
    padding: 0.5rem 0.9rem; font-size: 0.9rem; font-weight: 500; letter-spacing: 0.04em;
    color: var(--text-secondary); text-decoration: none; border-radius: var(--border-radius-sm);
    transition: color var(--transition), background var(--transition); white-space: nowrap;
}
.main-nav > ul > li > a:hover,
.main-nav > ul > li > a[aria-current="page"],
.main-nav > ul > li > a.active { color: var(--primary); background: var(--accent); }
.main-nav > ul > li > a.nav-cta { background: var(--primary); color: var(--white); padding: 0.5rem 1.3rem; border-radius: 50px; font-size: 0.84rem; letter-spacing: 0.1em; margin-left: 0.4rem; }
.main-nav > ul > li > a.nav-cta:hover { background: var(--primary-dark); color: var(--white); }
.main-nav .dropdown-chevron { font-size: 0.7rem; transition: transform 0.25s ease; pointer-events: none; }
.has-dropdown.is-open > a .dropdown-chevron { transform: rotate(180deg); }

/* Dropdown desktop — posizionato assoluto, due colonne */
.dropdown-menu {
    display: none;
    position: absolute; top: calc(100% + 10px); left: 50%;
    transform: translateX(-50%);
    width: 560px; max-width: 92vw; max-height: 70vh;
    overflow-y: auto; overflow-x: hidden;
    background: var(--white); border-radius: var(--border-radius);
    box-shadow: 0 8px 40px rgba(26,22,40,0.15), 0 0 0 1px rgba(128,113,177,0.1);
    padding: 1rem 0; list-style: none; z-index: 200;
}
.has-dropdown.is-open > .dropdown-menu {
    display: grid;
    grid-template-columns: 1fr 1fr;
}
.dropdown-menu .dropdown-cat-header {
    grid-column: 1 / -1; padding: 0.3rem 1.2rem 0.2rem;
    font-size: 0.7rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--primary); border-bottom: 1px solid var(--gray-100); margin-bottom: 0.2rem;
}
.dropdown-menu .dropdown-cat-header:not(:first-child) { margin-top: 0.6rem; }
.dropdown-menu li a {
    display: block; padding: 0.42rem 1.2rem; font-size: 0.86rem; color: var(--text-secondary);
    text-decoration: none; white-space: normal; line-height: 1.35;
    transition: background var(--transition), color var(--transition), padding-left var(--transition);
}
.dropdown-menu li a:hover,
.dropdown-menu li a[aria-current="page"],
.dropdown-menu li a.active { background: var(--accent); color: var(--primary-dark); padding-left: 1.5rem; }

/* Hamburger */
.menu-toggle { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 44px; height: 44px; background: none; border: none; cursor: pointer; padding: 8px; border-radius: var(--border-radius-sm); transition: background var(--transition); z-index: 1001; position: relative; }
.menu-toggle:hover { background: var(--accent); }
.burger-bar { display: block; width: 22px; height: 2px; background: var(--primary); border-radius: 2px; transition: all 0.3s ease; }
.menu-toggle[aria-expanded="true"] .burger-bar:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.menu-toggle[aria-expanded="true"] .burger-bar:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] .burger-bar:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

.nav-overlay { display: none; position: fixed; inset: 0; background: rgba(26,22,40,0.45); z-index: 900; backdrop-filter: blur(2px); }
.nav-overlay.open { display: block; }

/* ── 7. HERO ──────────────────────────────────────────────── */
.hero-section { position: relative; min-height: 92vh; display: flex; align-items: center; background-size: cover; background-position: center; background-repeat: no-repeat; overflow: hidden; }
.hero-section::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(26,22,40,0.65) 0%, rgba(128,113,177,0.35) 60%, rgba(202,187,252,0.15) 100%); z-index: 1; }
.hero-section .container { position: relative; z-index: 2; }
.hero-content { max-width: 700px; color: var(--white); }
.hero-content h1 { color: var(--white); font-size: clamp(2.4rem,5.5vw,4.2rem); font-weight: 400; font-style: italic; margin-bottom: var(--space-md); text-shadow: 0 2px 20px rgba(0,0,0,0.3); }
.hero-content p.hero-sub { font-size: clamp(1rem,2vw,1.2rem); color: rgba(255,255,255,0.88); margin-bottom: var(--space-xl); font-weight: 300; letter-spacing: 0.03em; }
.hero-actions { display: flex; gap: var(--space-md); flex-wrap: wrap; align-items: center; margin-bottom: var(--space-xl); }
.hero-badge { position: absolute; bottom: 2rem; right: 2rem; background: rgba(255,255,255,0.15); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.3); border-radius: var(--border-radius); padding: 1rem 1.5rem; color: var(--white); text-align: center; z-index: 2; }
.hero-badge strong { display: block; font-size: 1.3rem; font-family: var(--font-display); }
.hero-badge span { font-size: 0.8rem; opacity: 0.85; }
.scroll-indicator { position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%); z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 0.4rem; color: rgba(255,255,255,0.6); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; }
.scroll-indicator span { animation: scrollBounce 1.8s ease-in-out infinite; }
@keyframes scrollBounce { 0%,100% { transform: translateY(0); } 50% { transform: translateY(6px); } }

/* ── 8. SERVICE HERO ──────────────────────────────────────── */
.service-hero { min-height: 55vh; display: flex; align-items: flex-end; background-size: cover; background-position: center; position: relative; padding-bottom: 3rem; }
.service-hero::before { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(26,22,40,0.75) 0%, rgba(26,22,40,0.2) 60%); }
.service-hero .container { position: relative; z-index: 1; }
.service-hero h1 { color: var(--white); margin-bottom: 0.5rem; }
.service-hero .lead { color: rgba(255,255,255,0.85); }

/* ── 9. CARDS ─────────────────────────────────────────────── */
.card { border: none; border-radius: var(--border-radius); overflow: hidden; box-shadow: var(--shadow-sm); background: var(--white); transition: transform var(--transition), box-shadow var(--transition); display: flex; flex-direction: column; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card-img-top { width: 100%; height: 220px; object-fit: cover; }
.card-body { padding: 1.5rem; flex: 1; display: flex; flex-direction: column; }
.card-title { font-family: var(--font-display); font-size: 1.35rem; margin-bottom: 0.5rem; color: var(--primary-dark); }
.card-text { color: var(--text-secondary); font-size: 0.93rem; flex: 1; }
.card-body .btn { margin-top: auto; align-self: flex-start; padding-top: 1rem; }
.service-img-placeholder { width: 100%; height: 220px; background: linear-gradient(135deg, var(--accent) 0%, var(--secondary) 100%); display: flex; align-items: center; justify-content: center; font-size: 3.5rem; color: var(--primary); }

/* ── 10. ABOUT ────────────────────────────────────────────── */
.about-section .img-wrapper { position: relative; }
.about-section .img-wrapper img { border-radius: var(--border-radius); width: 100%; height: 500px; object-fit: cover; box-shadow: var(--shadow-lg); }
.about-section .img-wrapper .img-badge { position: absolute; bottom: -1.5rem; right: -1.5rem; background: var(--primary); color: var(--white); border-radius: var(--border-radius); padding: 1.2rem 1.5rem; text-align: center; box-shadow: var(--shadow-md); }
.about-section .img-wrapper .img-badge strong { display: block; font-size: 2rem; font-family: var(--font-display); line-height: 1; }
.about-section .img-wrapper .img-badge span { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.85; }
.about-content { padding: 2rem 0 2rem 3rem; }
.icon-list { list-style: none; padding: 0; margin: 1.5rem 0; }
.icon-list li { display: flex; align-items: flex-start; gap: 0.75rem; margin-bottom: 0.6rem; font-size: 0.95rem; }
.icon-list li i { color: var(--primary); margin-top: 0.2rem; flex-shrink: 0; }

/* ── 11. FEATURES ─────────────────────────────────────────── */
.features-section { background: var(--accent); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; }
.feature-item { text-align: center; padding: 2rem 1.5rem; background: var(--white); border-radius: var(--border-radius); box-shadow: var(--shadow-sm); }
.feature-icon { width: 64px; height: 64px; background: linear-gradient(135deg, var(--primary) 0%, var(--secondary-dark) 100%); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 1.2rem; font-size: 1.6rem; color: var(--white); }
.feature-item h3 { font-size: 1.1rem; font-family: var(--font-body); font-weight: 600; margin-bottom: 0.5rem; }
.feature-item p { font-size: 0.9rem; color: var(--text-muted); margin: 0; }

/* ── 12. REVIEWS ──────────────────────────────────────────── */
.review-card { background: var(--off-white); border-radius: var(--border-radius); padding: 2rem; box-shadow: var(--shadow-sm); }
.review-card .stars { color: #E8B84B; font-size: 1.1rem; margin-bottom: 1rem; }
.review-card blockquote { font-style: italic; font-size: 1.05rem; color: var(--text-secondary); margin-bottom: 1rem; }
.review-card cite { font-size: 0.85rem; font-weight: 600; color: var(--primary); font-style: normal; }
.review-card .review-source { font-size: 0.78rem; color: var(--text-muted); }

/* ── 13. CTA ──────────────────────────────────────────────── */
.cta-section { background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%); color: var(--white); text-align: center; padding: var(--section-pad) 0; }
.cta-section h2 { color: var(--white); margin-bottom: 1rem; }
.cta-section p { color: rgba(255,255,255,0.85); margin-bottom: 2rem; font-size: 1.05rem; }

/* ── 14. FORM ─────────────────────────────────────────────── */
.form-group { margin-bottom: 1.5rem; }
.form-label { display: block; font-size: 0.88rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 0.4rem; }
.form-label .required { color: var(--error); margin-left: 2px; }
.form-control { width: 100%; padding: 0.8rem 1rem; border: 2px solid var(--gray-200); border-radius: var(--border-radius-sm); font-family: var(--font-body); font-size: 0.95rem; color: var(--text-primary); background: var(--white); transition: border-color var(--transition), box-shadow var(--transition); }
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(128,113,177,0.25); }
textarea.form-control { min-height: 140px; resize: vertical; }
.form-check { display: flex; align-items: flex-start; gap: 0.6rem; margin-bottom: 1rem; }
.form-check-input { width: 20px; height: 20px; accent-color: var(--primary); flex-shrink: 0; margin-top: 2px; cursor: pointer; }
.form-check-label { font-size: 0.88rem; color: var(--text-secondary); }
.form-feedback { font-size: 0.82rem; margin-top: 0.3rem; }
.form-feedback.success { color: var(--success); }
.form-feedback.error { color: var(--error); }

/* ── 15. SERVICE DETAIL ───────────────────────────────────── */
.benefits-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0.6rem; }
.benefits-list li { display: flex; align-items: flex-start; gap: 0.6rem; padding: 0.5rem 0; }
.benefits-list li i { color: var(--primary); flex-shrink: 0; margin-top: 0.25rem; }
.sidebar-services { background: var(--accent); border-radius: var(--border-radius); padding: 1.8rem; position: sticky; top: calc(var(--header-h) + 1.5rem); }
.sidebar-services h4 { margin-bottom: 1rem; font-family: var(--font-display); font-size: 1.4rem; }
.services-sidebar-list { list-style: none; padding: 0; }
.services-sidebar-list li { border-bottom: 1px solid var(--gray-200); }
.services-sidebar-list li:last-child { border-bottom: none; }
.services-sidebar-list a { display: block; padding: 0.55rem 0.5rem; font-size: 0.88rem; color: var(--text-secondary); text-decoration: none; transition: color var(--transition), padding-left var(--transition); }
.services-sidebar-list a:hover { color: var(--primary); padding-left: 0.8rem; }
.services-sidebar-list a.active { color: var(--primary); font-weight: 600; }

/* ── 16. INFO BOX ─────────────────────────────────────────── */
.info-box { background: var(--off-white); border-left: 4px solid var(--primary); border-radius: 0 var(--border-radius) var(--border-radius) 0; padding: 1.5rem 2rem; margin-bottom: 1.5rem; }
.contact-list { list-style: none; padding: 0; }
.contact-list li { display: flex; align-items: flex-start; gap: 0.75rem; margin-bottom: 0.75rem; font-size: 0.95rem; }
.contact-list li i { color: var(--primary); width: 18px; flex-shrink: 0; margin-top: 0.2rem; }
.contact-list a { color: var(--text-primary); text-decoration: none; }
.contact-list a:hover { color: var(--primary); }

/* ── 17. FOOTER ───────────────────────────────────────────── */
.main-footer { background: var(--dark); color: rgba(255,255,255,0.8); padding-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 3rem; padding-bottom: 3rem; }
.footer-brand img { margin-bottom: 1rem; filter: brightness(0) invert(1); opacity: 0.9; }
.footer-brand p { font-size: 0.9rem; line-height: 1.6; opacity: 0.75; }
.footer-col h3 { font-family: var(--font-body); font-size: 0.82rem; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase; color: var(--secondary); margin-bottom: 1.2rem; }
.footer-col ul { list-style: none; padding: 0; }
.footer-col ul li { margin-bottom: 0.5rem; }
.footer-col a { color: rgba(255,255,255,0.7); text-decoration: none; font-size: 0.9rem; transition: color var(--transition); }
.footer-col a:hover { color: var(--secondary); }
.footer-contact .contact-list li { color: rgba(255,255,255,0.75); }
.footer-contact .contact-list a { color: rgba(255,255,255,0.75); }
.footer-contact .contact-list a:hover { color: var(--secondary); }
.footer-contact .contact-list li i { color: var(--secondary); }
.social-links { display: flex; gap: 0.75rem; margin-top: 1.2rem; }
.social-links a { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,0.1); border-radius: 50%; color: rgba(255,255,255,0.8); font-size: 0.95rem; transition: all var(--transition); text-decoration: none; }
.social-links a:hover { background: var(--primary); color: var(--white); transform: translateY(-2px); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 1.5rem 0; text-align: center; font-size: 0.82rem; opacity: 0.6; display: flex; flex-direction: column; gap: 0.4rem; align-items: center; }
.footer-bottom a { color: inherit; text-decoration: underline; }
.footer-bottom button.btn-link-style { color: inherit; font-size: 0.82rem; }

/* ── 18. WHATSAPP FLOAT ───────────────────────────────────── */
.whatsapp-float { position: fixed; bottom: 1.8rem; right: 1.8rem; z-index: 850; width: 56px; height: 56px; background: #25D366; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.6rem; color: var(--white); text-decoration: none; box-shadow: 0 4px 16px rgba(37,211,102,0.4); transition: all var(--transition); }
.whatsapp-float:hover { background: #1ebe5a; transform: scale(1.1); color: var(--white); }
.whatsapp-tooltip { position: absolute; right: calc(100% + 10px); top: 50%; transform: translateY(-50%); background: var(--dark); color: var(--white); padding: 0.4rem 0.8rem; border-radius: 6px; font-size: 0.78rem; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity var(--transition); }
.whatsapp-float:hover .whatsapp-tooltip { opacity: 1; }

/* ── 19. PAGE HERO ────────────────────────────────────────── */
.page-hero { background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%); padding: 4rem 0 3rem; text-align: center; color: var(--white); }
.page-hero h1 { color: var(--white); margin-bottom: 0.5rem; }
.page-hero p { color: rgba(255,255,255,0.8); font-size: 1.05rem; margin: 0; }
.page-hero .breadcrumb { justify-content: center; color: rgba(255,255,255,0.7); }
.page-hero .breadcrumb a { color: rgba(255,255,255,0.7); }
.page-hero .breadcrumb a:hover { color: var(--white); }
.page-hero .breadcrumb [aria-current="page"] { color: var(--white); }

/* ── 20. BREADCRUMB ───────────────────────────────────────── */
.breadcrumb { display: flex; align-items: center; gap: 0.5rem; font-size: 0.82rem; color: var(--text-muted); padding: 1rem 0; flex-wrap: wrap; }
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .separator { opacity: 0.5; }
.breadcrumb [aria-current="page"] { color: var(--primary); font-weight: 600; }

/* ── 21. SERVICES GRID ────────────────────────────────────── */
.services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; }
.service-tag { display: inline-block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 0.2rem 0.6rem; border-radius: 50px; background: var(--accent); color: var(--primary); margin-bottom: 0.5rem; }

/* ── 22. 404 ──────────────────────────────────────────────── */
.error-404 { min-height: 60vh; display: flex; align-items: center; }
.error-404 .error-code { font-family: var(--font-display); font-size: clamp(6rem,15vw,12rem); color: var(--secondary); line-height: 1; margin-bottom: 1rem; }

/* ── 23. CERT BADGES ──────────────────────────────────────── */
.certification-badges { display: flex; flex-wrap: wrap; gap: 1rem; margin: 1.5rem 0; }
.cert-badge { background: var(--accent); border-radius: 50px; padding: 0.4rem 1rem; font-size: 0.82rem; font-weight: 600; color: var(--primary-dark); display: inline-flex; align-items: center; gap: 0.4rem; }

/* ── 24. MAP ──────────────────────────────────────────────── */
.map-wrapper { border-radius: var(--border-radius); overflow: hidden; box-shadow: var(--shadow-md); }
.map-wrapper iframe { display: block; }

/* ── 25. SCROLL REVEAL ────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.revealed { opacity: 1; transform: translateY(0); }

/* ── 26. POLICY PAGES ─────────────────────────────────────── */
.policy-page h2 { margin-top: 2.5rem; margin-bottom: 1rem; font-size: 1.6rem; }
.policy-page h3 { margin-top: 1.8rem; margin-bottom: 0.75rem; font-size: 1.2rem; }
.policy-page ul, .policy-page ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.policy-page li { margin-bottom: 0.4rem; }

/* ══════════════════════════════════════════════════════════════
   ── 27. MOBILE NAV — RISCRITTO COMPLETAMENTE ────────────────
   Pannello a tutto schermo (drawer) + dropdown ad ACCORDION
   (max-height invece di display grid/block: molto più robusto,
   nessun conflitto di rendering su nessun browser mobile)
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 991px) {

    .menu-toggle { display: flex; }

    /* Pannello nav: drawer laterale, altezza fissata esplicitamente
       (non solo top+bottom) per evitare bug di stretching su iOS Safari */
    .main-nav {
        display: block !important;      /* sovrascrive .main-nav{display:flex} desktop */
        position: fixed;
        top: var(--header-h);
        right: 0;
        width: min(340px, 88vw);
        height: calc(100vh - var(--header-h));
        height: calc(100dvh - var(--header-h)); /* fallback moderno per barra indirizzi mobile */
        background: var(--white);
        z-index: 950;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0.5rem 0 2rem;
        transform: translateX(100%);
        transition: transform 0.32s ease;
        box-shadow: -6px 0 30px rgba(0,0,0,0.15);
    }
    .main-nav.open { transform: translateX(0); }

    .main-nav > ul {
        display: flex;
        flex-direction: column;
        gap: 0;
        width: 100%;
    }
    .main-nav > ul > li {
        position: static;
        width: 100%;
        border-bottom: 1px solid var(--gray-100);
    }
    .main-nav > ul > li:last-child { border-bottom: none; }

    .main-nav > ul > li > a {
        width: 100%;
        padding: 1rem 1.4rem;
        font-size: 1rem;
        border-radius: 0;
        justify-content: space-between;
    }
    .main-nav > ul > li > a.nav-cta {
        width: calc(100% - 2.4rem);
        margin: 0.75rem auto 0.25rem;
        text-align: center;
        justify-content: center;
        border-radius: 50px;
        padding: 0.85rem 1.4rem;
    }

    /* ── DROPDOWN "SERVIZI" SU MOBILE = ACCORDION ─────────────
       Nessun position:absolute, nessun display:grid.
       Si espande in linea sotto la voce, con max-height animato. */
    .has-dropdown > .dropdown-menu {
        display: block !important;      /* sovrascrive il display:none desktop-default */
        position: static !important;
        width: 100% !important;
        max-width: 100% !important;
        transform: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        background: var(--gray-50);

        /* Stato CHIUSO di default: altezza zero, contenuto tagliato */
        max-height: 0;
        overflow: hidden;
        padding: 0;
        margin: 0;
        transition: max-height 0.35s ease, padding 0.35s ease;

        grid-template-columns: 1fr !important; /* una sola colonna su mobile */
    }
    /* Stato APERTO: altezza generosa che contiene tutti i 24 elementi */
    .has-dropdown.is-open > .dropdown-menu {
        max-height: 2000px;
        padding: 0.4rem 0 0.6rem;
    }

    .dropdown-menu .dropdown-cat-header {
        padding: 0.6rem 1.6rem 0.3rem;
        grid-column: unset;
    }
    .dropdown-menu li a {
        padding: 0.65rem 2rem;
        font-size: 0.92rem;
    }
    .dropdown-menu li a:hover,
    .dropdown-menu li a:active {
        padding-left: 2.4rem;
    }

    /* Layout fixes generali */
    .about-content { padding: 2rem 0 0; }
    .about-section .img-wrapper .img-badge { right: 0; }
    .hero-badge { display: none; }
    .service-hero { min-height: 40vh; }
    .col-lg-8, .col-lg-6, .col-lg-4 { width: 100%; }
}

@media (max-width: 575px) {
    :root { --section-pad: 3.5rem; }
    .hero-section { min-height: 75vh; }
    .hero-content h1 { font-size: 2.2rem; }
    .features-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .services-grid { grid-template-columns: 1fr; }
    .hero-actions { flex-direction: column; align-items: flex-start; }
    .benefits-list { grid-template-columns: 1fr; }
    .main-nav { width: 100vw; }
}

@media print {
    .main-header, .main-footer, .whatsapp-float, #cookie-banner, .menu-toggle { display: none !important; }
    body { padding-top: 0 !important; }
    a[href]::after { content: ' (' attr(href) ')'; font-size: 0.8em; }
}

@media (forced-colors: active) {
    .btn-primary, .btn-secondary, .btn-light { border: 2px solid ButtonText; }
    .main-header { border-bottom: 2px solid ButtonText; }
}
