/* ============================================
   RESET E VARIABILI
   ============================================ */

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

:root {
    /* Colori principali */
    --color-primary: #61a1aa;
    --color-primary-dark: #4a8089;
    --color-primary-light: #a8d5db;
    --color-secondary: #2c4f54;
    --color-accent: #d4af37;

    /* Colori testo */
    --color-text-dark: #1a1a1a;
    --color-text-medium: #4a4a4a;
    --color-text-light: #777777;
    --color-white: #ffffff;

    /* Colori sfondo */
    --color-bg-light: #f7f7f7;
    --color-bg-white: #ffffff;
    --color-bg-cream: #fafaf8;

    /* Spaziature */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 3rem;
    --spacing-xl: 4rem;
    --spacing-2xl: 6rem;

    /* Typography */
    --font-display: 'Playfair Display', serif;
    --font-body: 'Lora', serif;

    /* Transizioni */
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.5s ease;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ============================================
   TIPOGRAFIA BASE
   ============================================ */

html {
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--color-text-medium);
    background-color: var(--color-bg-light);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    color: var(--color-text-dark);
    line-height: 1.3;
    font-weight: 600;
}

h1 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h2 {
    font-size: clamp(1.5rem, 3.5vw, 2.25rem);
}

h3 {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
}

h4 {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================
   HEADER
   ============================================ */

header {
    position: sticky;
    top: 0;
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(97, 161, 170, 0.1);
    z-index: 1000;
    transition: var(--transition-medium);
}

header.scrolled {
    box-shadow: var(--shadow-md);
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: clamp(1.4rem, 3vw, 1.8rem);
    color: var(--color-text-dark);
    font-weight: 600;
    line-height: 1;
}

header h1 a {
    text-decoration: none;
    display: block;
}

header h1 img {
    height: 56px;
    width: auto;
}

@media (max-width: 768px) {
    header h1 img {
        height: 40px;
    }
}

.dentist-name {
    display: block;
}

.sottotitolo {
    display: block;
    font-size: clamp(0.85rem, 2vw, 1rem);
    color: var(--color-primary);
    font-weight: 400;
    margin-top: 0.2rem;
}

nav ul.menu {
    list-style: none;
    display: flex;
    gap: 2rem;
    align-items: center;
}

nav ul.menu li a {
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--color-text-medium);
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
}

nav ul.menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: width var(--transition-medium);
}

nav ul.menu li a:hover {
    color: var(--color-primary);
}

nav ul.menu li a:hover::after {
    width: 100%;
}

/* ============================================
   DROPDOWN MENU
   ============================================ */

.menu-item-dropdown {
    position: relative;
}

.menu-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    cursor: pointer;
}

.dropdown-arrow {
    font-size: 0.75rem;
    transition: transform var(--transition-fast);
    display: inline-block;
}

.menu-item-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

/* Hide the underline animation for the trigger */
.menu-dropdown-trigger::after {
    display: none !important;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 0.75rem);
    left: 50%;
    transform: translateX(-50%);
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(97, 161, 170, 0.1);
    min-width: 270px;
    padding: 0.5rem 0;
    list-style: none;
    z-index: 999;
    opacity: 0;
    transform: translateX(-50%) translateY(-8px);
    transition: opacity var(--transition-fast), transform var(--transition-fast);
    pointer-events: none;
}

/* Arrow tip */
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 12px;
    background: #ffffff;
    border-left: 1px solid rgba(97, 161, 170, 0.1);
    border-top: 1px solid rgba(97, 161, 170, 0.1);
    rotate: 45deg;
}

.menu-item-dropdown:hover .dropdown-menu,
.menu-item-dropdown:focus-within .dropdown-menu,
.menu-item-dropdown.open .dropdown-menu {
    display: block;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: all;
}

.dropdown-menu li {
    display: block;
}

.dropdown-menu li a {
    display: block;
    padding: 0.6rem 1.25rem;
    font-size: 0.92rem;
    color: var(--color-text-medium);
    font-weight: 500;
    white-space: nowrap;
    border-left: 3px solid transparent;
    transition: var(--transition-fast);
}

.dropdown-menu li a:hover {
    color: var(--color-primary);
    background-color: rgba(97, 161, 170, 0.06);
    border-left-color: var(--color-primary);
}

.dropdown-menu li a::after {
    display: none;
}

/* Flyout submenu */
.has-submenu {
    position: relative;
}

.has-submenu > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.submenu-arrow {
    font-size: 1rem;
    margin-left: 0.5rem;
    opacity: 0.6;
    flex-shrink: 0;
}

.dropdown-submenu {
    display: none;
    position: absolute;
    top: 0;
    left: 100%;
    background: rgba(255, 255, 255, 0.99);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    padding: 0.5rem 0;
    min-width: 210px;
    z-index: 1002;
    list-style: none;
    border: 1px solid rgba(97, 161, 170, 0.1);
    margin-left: 4px;
}

.has-submenu:hover .dropdown-submenu {
    display: block;
    animation: dropdownFade 0.2s ease;
}

.dropdown-submenu li a {
    display: block;
    padding: 0.6rem 1.25rem;
    font-size: 0.9rem;
    color: var(--color-text-medium);
    white-space: nowrap;
    transition: all 0.2s ease;
    text-decoration: none;
}

.dropdown-submenu li a:hover {
    color: var(--color-primary);
    background-color: rgba(97, 161, 170, 0.06);
    padding-left: 1.5rem;
}

.dropdown-submenu li a::after {
    display: none;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
    position: relative;
    width: 100%;
    min-height: 70vh;
    overflow: hidden;
}

.hero-image {
    position: relative;
    width: 100%;
    height: 70vh;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(97, 161, 170, 0.85) 0%,
            rgba(44, 79, 84, 0.7) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
}

.hero-title {
    color: var(--color-white);
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease;
}

.hero-subtitle {
    color: rgba(255, 255, 255, 0.95);
    font-size: clamp(1rem, 2.5vw, 1.4rem);
    font-weight: 400;
    max-width: 600px;
    animation: fadeInUp 1s ease 0.2s backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   CONTAINER
   ============================================ */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ============================================
   SECTION STYLING
   ============================================ */

section {
    padding: var(--spacing-2xl) 0;
}

.section-header {
    margin-bottom: var(--spacing-lg);
}

.section-label {
    display: block;
    font-size: 0.9rem;
    color: var(--color-text-light);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.section-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    color: var(--color-primary);
    margin-bottom: var(--spacing-md);
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--color-accent);
}

.section-title.centered {
    display: block;
    text-align: center;
}

.section-title.centered::after {
    left: 50%;
    transform: translateX(-50%);
}

/* ============================================
   CHI SIAMO SECTION
   ============================================ */

.chi-siamo {
    background-color: var(--color-bg-white);
}

.chi-siamo-content {
    /* Animazioni gestite dall'Intersection Observer */
}

.intro-text {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    line-height: 1.8;
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-md);
    font-weight: 500;
}

.body-text {
    margin-bottom: var(--spacing-md);
    text-align: justify;
}

.cta-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 1rem;
    margin-top: var(--spacing-md);
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
    transition: var(--transition-medium);
}

.cta-link:hover {
    color: var(--color-primary-dark);
    border-bottom-color: var(--color-primary);
}

.cta-link .arrow {
    font-size: 1.5rem;
    transition: transform var(--transition-medium);
}

.cta-link:hover .arrow {
    transform: translateX(5px);
}

/* ============================================
   QUOTE SECTION
   ============================================ */

.quote-section {
    background: linear-gradient(135deg, #f5f5f5 0%, #e8f4f5 100%);
    padding: var(--spacing-2xl) 0;
    position: relative;
    overflow: hidden;
}

.quote-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(97, 161, 170, 0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.quote-wrapper {
    display: flex;
    align-items: center;
    gap: var(--spacing-xl);
    position: relative;
}

.quote-image {
    flex-shrink: 0;
}

.foto-cerchio {
    width: clamp(200px, 30vw, 350px);
    height: clamp(200px, 30vw, 350px);
    border-radius: 50%;
    object-fit: cover;
    border: 6px solid var(--color-white);
    box-shadow: var(--shadow-lg);
}

.quote-text {
    flex: 1;
    position: relative;
}

.quote-mark {
    font-size: 5rem;
    color: var(--color-primary-light);
    font-family: Georgia, serif;
    line-height: 0.5;
    font-weight: bold;
}

.quote-mark-end {
    position: absolute;
    bottom: 0;
    right: 0;
}

.quote-main {
    font-size: clamp(1.4rem, 3vw, 2rem);
    line-height: 1.5;
    color: var(--color-primary);
    font-weight: 600;
    margin: var(--spacing-md) 0;
}

.quote-secondary {
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    color: var(--color-text-dark);
    font-weight: 400;
    margin-bottom: var(--spacing-md);
}

cite {
    display: block;
    font-size: 1rem;
    color: var(--color-text-light);
    font-style: italic;
    margin-top: var(--spacing-md);
}

/* ============================================
   CTA APPOINTMENT SECTION
   ============================================ */

.cta-appointment {
    position: relative;
    background-image: url('img/ufficio1.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    padding: var(--spacing-2xl) 2rem;
    text-align: center;
    overflow: hidden;
}

.cta-appointment::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(97, 161, 170, 0.92) 0%,
            rgba(44, 79, 84, 0.88) 100%);
}

.cta-content {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0 auto;
}

.cta-content h3 {
    color: var(--color-white);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    margin-bottom: var(--spacing-md);
}

.cta-content p {
    color: rgba(255, 255, 255, 0.95);
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    margin-bottom: var(--spacing-lg);
}

/* ============================================
   BUTTONS
   ============================================ */

.btn-primary {
    display: inline-block;
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 2px solid var(--color-white);
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition-medium);
    font-family: var(--font-body);
    box-shadow: var(--shadow-md);
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    max-width: 100%;
    box-sizing: border-box;
}

.btn-primary:hover {
    background-color: transparent;
    color: var(--color-white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   SERVIZI SECTION
   ============================================ */

.servizi {
    background-color: var(--color-bg-cream);
}

.slider-container {
    position: relative;
    max-width: 1000px;
    margin: var(--spacing-lg) auto;
    padding: 0 60px;
    box-sizing: border-box;
    width: 100%;
}

.slider-wrapper {
    overflow: hidden;
    border-radius: 12px;
    width: 100%;
    position: relative;
}

.slider {
    display: flex;
    flex-wrap: nowrap;
    transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1);
    will-change: transform;
}

.slide {
    min-width: 100%;
    width: 100%;
    flex-shrink: 0;
    flex-grow: 0;
    background-color: var(--color-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    box-sizing: border-box;
}

.slide-image {
    width: 100%;
    height: 300px;
    overflow: hidden;
}

.slide-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.slide:hover .slide-image img {
    transform: scale(1.05);
}

.slide-content {
    padding: var(--spacing-lg);
}

.slide-content h4 {
    color: var(--color-primary);
    margin-bottom: var(--spacing-sm);
    font-size: 1.5rem;
}

.slide-content p {
    color: var(--color-text-medium);
    line-height: 1.7;
}

/* Slider Buttons */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-medium);
    font-size: 1.5rem;
    z-index: 10;
    box-shadow: var(--shadow-md);
}

.slider-btn:hover {
    background-color: var(--color-primary);
    color: var(--color-white);
    transform: translateY(-50%) scale(1.1);
}

.slider-btn.prev {
    left: 0;
}

.slider-btn.next {
    right: 0;
}

.slider-btn span {
    line-height: 1;
}

/* Slider Dots */
.slider-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: var(--spacing-lg);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--color-primary-light);
    border: none;
    cursor: pointer;
    transition: var(--transition-medium);
}

.dot:hover {
    background-color: var(--color-primary);
    transform: scale(1.2);
}

.dot.active {
    background-color: var(--color-primary);
    width: 32px;
    border-radius: 6px;
}

/* ============================================
   CONTATTI SECTION
   ============================================ */

.contatti {
    background-color: var(--color-bg-white);
}

.map-contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.map-container {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    height: 450px;
    min-height: 0;
    position: relative;
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.contact-info {
    background-color: var(--color-bg-cream);
    padding: var(--spacing-lg);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}

.contact-info h3 {
    color: var(--color-primary);
    margin-bottom: var(--spacing-lg);
    font-size: 1.75rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    margin-bottom: var(--spacing-md);
    align-items: flex-start;
}

.contact-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-primary-light);
    border-radius: 50%;
    color: var(--color-primary);
    transition: var(--transition-medium);
}

.contact-icon svg {
    width: 22px;
    height: 22px;
    stroke: var(--color-primary);
    transition: var(--transition-medium);
}

.contact-item:hover .contact-icon {
    background-color: var(--color-primary);
    transform: scale(1.1);
}

.contact-item:hover .contact-icon svg {
    stroke: var(--color-white);
}

.contact-item strong {
    display: block;
    color: var(--color-text-dark);
    margin-bottom: 0.3rem;
    font-weight: 600;
}

.contact-item p,
.contact-item a {
    color: var(--color-text-medium);
    font-size: 0.95rem;
    line-height: 1.6;
}

.contact-item a:hover {
    color: var(--color-primary);
}

.orari-list {
    list-style: none;
    padding: 0;
}

.orari-list li {
    padding: 0.3rem 0;
    color: var(--color-text-medium);
}

.contact-info .btn-primary {
    width: 100%;
    margin-top: var(--spacing-md);
    background-color: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
}

.contact-info .btn-primary:hover {
    background-color: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
}

/* ============================================
   COOKIE NOTICE
   ============================================ */

.cookie-notice {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-top: 2px solid var(--color-primary-light);
    padding: 1.5rem;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    animation: slideUp 0.5s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.cookie-content p {
    margin: 0;
    color: var(--color-text-medium);
    font-size: 0.95rem;
    line-height: 1.5;
}

.cookie-content strong {
    color: var(--color-text-dark);
    font-weight: 600;
}

.btn-cookie {
    background-color: var(--color-primary);
    color: var(--color-white);
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition-medium);
    white-space: nowrap;
    font-family: var(--font-body);
}

.btn-cookie:hover {
    background-color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ============================================
   FOOTER
   ============================================ */

footer {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: var(--color-white);
    padding: var(--spacing-lg) 0 var(--spacing-sm);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-md);
    text-align: center;
    margin-bottom: var(--spacing-md);
}

.footer-column h4 {
    color: var(--color-white);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.footer-column p {
    font-size: 0.95rem;
    margin: 0.3rem 0;
    opacity: 0.95;
}

.footer-column a {
    color: var(--color-white);
    text-decoration: underline;
}

.footer-column a:hover {
    opacity: 0.8;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--spacing-md) 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
}

.footer-bottom p {
    margin: 0.5rem 0;
    opacity: 0.9;
}

.footer-keywords {
    font-size: 0.8rem;
    opacity: 0.7;
    line-height: 1.6;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--color-primary);
    outline-offset: 3px;
}

/* Screen reader only */
.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;
}

/* ============================================
   MOBILE NAV — HAMBURGER
   ============================================ */

.mobile-nav {
    display: none;
    flex-direction: column;
    position: sticky;
    top: 0;
    z-index: 999;
    background-color: var(--color-primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
    width: 100%;
    box-sizing: border-box;
}

.mobile-nav-topbar {
    display: flex;
    align-items: center;
    height: 52px;
    padding: 0 .75rem;
}

.mobile-nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 9px;
    background: none;
    border: none;
    cursor: pointer;
    flex-shrink: 0;
    box-sizing: border-box;
}

.mobile-nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: transform .28s ease, opacity .28s ease;
    transform-origin: center;
}

.mobile-nav-toggle.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

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

.mobile-nav-toggle.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav-logo {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.mobile-nav-logo img {
    height: 36px;
    width: auto;
    /* logo ha sfondo trasparente ma è scuro — usiamo filtro per renderlo bianco */
    filter: brightness(0) invert(1);
}

.mobile-nav-brand {
    flex: 1;
    text-align: center;
    color: rgba(255, 255, 255, .95);
    font-family: var(--font-display);
    font-size: .95rem;
    font-weight: 600;
    padding-right: 40px;
    letter-spacing: .3px;
}

.mobile-nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--color-secondary);
    display: flex;
    flex-direction: column;
    z-index: 998;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s ease;
}

.mobile-nav-links.open {
    max-height: 80vh;
    overflow-y: auto;
}

.mobile-nav-links a {
    display: block;
    padding: .75rem 1.4rem;
    color: rgba(255, 255, 255, .92);
    font-family: var(--font-body);
    font-size: .9rem;
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    transition: background .15s, padding-left .15s;
}

.mobile-nav-links a:last-child {
    border-bottom: none;
}

.mobile-nav-links a:active,
.mobile-nav-links a:focus {
    background: rgba(255, 255, 255, .12);
    padding-left: 2rem;
    outline: none;
}

/* Mobile nav – sezione "Servizi" collassabile */
.mobile-nav-section {
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.mobile-nav-section-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: .75rem 1.4rem;
    background: none;
    border: none;
    color: rgba(255, 255, 255, .92);
    font-family: var(--font-body);
    font-size: .9rem;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
}

.mobile-section-arrow {
    font-size: .75rem;
    transition: transform .2s ease;
}

.mobile-nav-section.open .mobile-section-arrow {
    transform: rotate(180deg);
}

.mobile-nav-submenu {
    display: none;
    background: rgba(0, 0, 0, .12);
}

.mobile-nav-section.open .mobile-nav-submenu {
    display: block;
}

.mobile-nav-group-label {
    display: block;
    padding: .45rem 1.6rem .2rem;
    font-family: var(--font-body);
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, .45);
    margin-top: .4rem;
}

.mobile-nav-submenu a {
    padding: .6rem 1.4rem .6rem 2rem;
    font-size: .88rem;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
    color: rgba(255, 255, 255, .85);
}

.mobile-nav-submenu a:last-child {
    border-bottom: none;
}

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

@media (max-width: 1024px) {
    .staff-card-photo {
        width: 260px;
    }
}

@media (max-width: 768px) {

    html,
    body {
        overflow-x: hidden;
        margin: 0;
        padding: 0;
    }

    .btn-primary {
        font-size: 1rem;
        padding: 0.85rem 1.8rem;
        white-space: normal;
        text-align: center;
    }

    .desktop-nav {
        display: none !important;
    }

    .mobile-nav {
        display: flex;
    }

    /* Header: nascosto su mobile, sostituito dalla mobile nav */
    header {
        position: relative;
        display: none;
    }

    /* Hero: attacca direttamente sotto la mobile nav, nessun gap */
    .hero {
        min-height: 75vw;
        margin: 0;
        padding-top: 1.5rem;
    }

    .hero-image {
        height: 75vw;
        min-height: 280px;
        max-height: 500px;
        margin: 0;
    }

    .chi-siamo-content {
        padding: 0;
    }

    .quote-wrapper {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }

    .foto-cerchio {
        width: clamp(120px, 40vw, 200px);
    }

    .slider-container {
        padding: 0 40px;
    }

    .contatti.animate-in .contact-info {
        animation: fadeInUp .8s ease;
    }

    .features-grid {
        grid-template-columns: 1fr 1fr;
    }

    .process-steps {
        grid-template-columns: 1fr;
    }

    .staff-card {
        flex-direction: column;
    }

    .staff-card-photo {
        width: 100%;
        min-height: 280px;
    }

    .staff-card-body {
        padding: 1.5rem;
    }

    .service-intro-grid {
        grid-template-columns: 1fr;
    }

    .service-intro-image {
        height: 260px;
    }

    .map-contact-wrapper {
        flex-direction: column;
        grid-template-columns: 1fr;
    }

    .map-container {
        height: 300px;
    }

    .contact-info {
        padding: 1.25rem;
    }

    .contact-info h3 {
        font-size: 1.35rem;
        margin-bottom: 1rem;
    }

    .contact-item {
        gap: .75rem;
        margin-bottom: 1rem;
    }

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

    .contact-info .btn-primary {
        width: 100%;
        margin-top: 1rem;
    }
}

@media (max-width: 480px) {
    .slider-container {
        padding: 0 32px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .btn-primary {
        display: block;
        width: 100%;
        max-width: 340px;
        margin-left: auto;
        margin-right: auto;
        padding: 0.9rem 1.2rem;
        font-size: 1rem;
        white-space: normal;
        text-align: center;
    }

    .cta-appointment {
        text-align: center;
        padding: 2rem 1rem;
    }

    .contact-info .btn-primary {
        max-width: 100%;
    }

    .mobile-nav-logo {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        text-decoration: none;
    }

    .mobile-nav-logo img {
        height: 36px;
        width: auto;
        /* logo ha sfondo trasparente ma è scuro — usiamo filtro per renderlo bianco */
        filter: brightness(0) invert(1);
    }

    .mobile-nav-brand {
        font-size: .85rem;
    }

    .trust-strip {
        gap: .75rem;
    }

    .trust-item {
        padding: .6rem .75rem;
    }
}

/* ── Footer CTA link ─────────────────────────────────── */
.footer-cta-link {
    text-decoration: underline;
}