:root {
    --clr-bg: #050505;
    --clr-surface: #111111;
    --clr-primary: #ca251b;
    /* Colore estratto dal logo TiWrappo */
    --clr-primary-glow: rgba(202, 37, 27, 0.4);
    --clr-text: #f8fafc;
    --clr-muted: #94a3b8;

    --ff-heading: 'Oswald', sans-serif;
    --ff-body: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--ff-body);
    background-color: var(--clr-bg);
    color: var(--clr-text);
    overflow-x: hidden;
}

body.no-scroll {
    overflow: hidden;
}

/* Typography Utilities */
h1,
h2,
h3,
h4 {
    font-family: var(--ff-heading);
    text-transform: uppercase;
    line-height: 1.1;
}

/* === Hero Section === */
#hero {
    position: relative;
    width: 100vw;
    height: 100dvh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

/* Layer 1: Background Video (Sempre in play sul fondo) */
.hero-bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.bg-video-element {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.9) contrast(1.1);
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, var(--clr-bg) 0%, rgba(5, 5, 5, 0.2) 100%);
    z-index: 2;
    /* Sopra il video, sotto la saracinesca */
}

/* Layer 2: Garage Door */
.garage-door-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    /* Sopra il video, sotto i testi */
    overflow: hidden;
    pointer-events: none;
    /* Let clicks pass through to video/buttons once open */
}

/* Open State */
.garage-door-layer.open .garage-door {
    transform: translateY(-100%);
    /* Movimento pesante e meccanico */
    transition: transform 2.5s cubic-bezier(0.5, 0, 0.1, 1);
}

.garage-door {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: #1a1a1a;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
    will-change: transform;
    pointer-events: auto;
    /* Blocca i click durante l'apertura */
    position: relative;
    /* Container per gli elementi decorativi assoluti */
}

/* Simulazione Spot Light centrale sul portone */
.garage-door::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.08) 0%, transparent 60%);
    pointer-events: none;
    z-index: 2;
}

/* Singola doga della saracinesca */
.door-panel {
    flex: 1;
    width: 100%;
    border-bottom: 2px solid #0a0a0a;
    border-top: 1px solid #2a2a2a;
    background: linear-gradient(to bottom, #222, #181818);
    position: relative;
    box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.02);
    z-index: 1;
}

/* Texture scanalata per un realismo in stile garage/racing */
.door-panel::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 100% 12px;
    pointer-events: none;
}

/* === Decorazioni Saracinesca === */

.door-graphics {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

.door-logo-container {
    text-align: center;
    transform: translateY(-5vh);
    /* Leggermente più su del centro esatto */
    opacity: 0.15;
    /* Effetto vernice sbiadita/stencil nero o grigio scuro */
}

/* Facciamo sembrare il logo "dipinto" sul metallo con mix-blend-mode e opacità */
.door-stencil-logo {
    font-family: var(--ff-heading);
    font-size: clamp(3.5rem, 15vw, 15rem);
    font-weight: 800;
    color: #fff;
    line-height: 0.9;
    letter-spacing: -3px;
    /* Diamo un colore scuro e usiamo overlay o multiply per fonderlo col metallo */
    color: #050505;
    text-shadow: 1px 1px 0px rgba(255, 255, 255, 0.05);
}

.door-stencil-sub {
    font-family: var(--ff-heading);
    font-size: clamp(1.2rem, 5vw, 4rem);
    color: #050505;
    letter-spacing: clamp(5px, 2vw, 15px);
    margin-top: -10px;
}

.door-accent {
    color: #ca251b;
    /* Rosso spento/scuro per fondersi senza stonare */
    opacity: 0.8;
}

/* Blocco inferiore strutturale (maniglione, prese d'aria) */
.door-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 4;
}

/* Prese d'aria (Vents) */
.door-vents {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.vent {
    width: 60px;
    height: 15px;
    background: #000;
    border-radius: 20px;
    border-top: 1px solid #111;
    border-bottom: 1px solid #333;
    box-shadow: inset 0 5px 10px rgba(0, 0, 0, 0.8);
}

/* Maniglione in metallo */
.door-handle-metal {
    width: 180px;
    height: 25px;
    background: linear-gradient(to bottom, #777, #444);
    border-radius: 4px;
    border: 1px solid #222;
    border-bottom: 2px solid #111;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.8), inset 0 2px 5px rgba(255, 255, 255, 0.3);
    margin-bottom: 40px;
    position: relative;
}

/* Finti bulloni di fissaggio maniglia */
.door-handle-metal::before,
.door-handle-metal::after {
    content: '';
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #2a2a2a;
    box-shadow: inset 0 -1px 2px rgba(0, 0, 0, 0.8), 0 1px 1px rgba(255, 255, 255, 0.2);
}

.door-handle-metal::before {
    left: 15px;
}

.door-handle-metal::after {
    right: 15px;
}

/* Nastro segnaletico Rosso e Nero alla base del portone */
.warning-tape {
    width: 100%;
    height: 20px;
    background: repeating-linear-gradient(45deg,
            var(--clr-primary),
            var(--clr-primary) 20px,
            #050505 20px,
            #050505 40px);
    border-top: 2px solid #000;
    opacity: 0.8;
    /* Per non renderlo fastidioso, lo invecchiamo leggermente */
    box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.5);
}

/* Layer 3: Hero Content (Sempre visibile in primissimo piano) */
.hero-content {
    position: relative;
    z-index: 10;
    /* Sempre sopra ogni cosa, compresa la saracinesca quando scende o sale */
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 2rem;
}

/* === Entrata Scenica Testi Hero === */
.hero-logo-text,
.hero-title,
.hero-subtitle,
.hero-content .racing-btn {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.2, 0.8, 0.2, 1), transform 1s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hero-logo-text {
    transform: translateY(50px) scale(0.9);
    transition: opacity 1.5s cubic-bezier(0.2, 0.8, 0.2, 1), transform 1.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hero-content.enter .hero-logo-text {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition-delay: 0.3s;
}

.hero-content.enter .hero-title {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.6s;
}

.hero-content.enter .hero-subtitle {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.8s;
}

.hero-content.enter .racing-btn {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 1.1s;
}

.hero-logo-text {
    font-size: clamp(4rem, 10vw, 8rem);
    font-weight: 800;
    color: #fff;
    margin-bottom: 1rem;
    letter-spacing: -2px;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
}

.hero-logo-text span {
    color: var(--clr-primary);
}

.hero-title {
    font-size: clamp(2rem, 5vw, 4rem);
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    color: #fff;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
}

.hero-subtitle {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: var(--clr-muted);
    margin-bottom: 3rem;
    font-weight: 500;
    text-shadow: 0 5px 20px rgba(0, 0, 0, 0.9);
}

/* === Buttons (Racing Style) === */
.racing-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1.2rem 3rem;
    text-decoration: none;
    color: #fff;
    font-family: var(--ff-heading);
    font-size: 1.5rem;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    border: none;
    background: transparent;
    cursor: pointer;
}

.racing-btn .btn-text {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
}

.racing-btn .btn-skew {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--clr-primary);
    transform: skewX(-20deg);
    z-index: 1;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px var(--clr-primary-glow);
}

.racing-btn:hover .btn-skew {
    transform: skewX(-20deg) scale(1.05);
    box-shadow: 0 0 30px var(--clr-primary);
    background: #fff;
}

.racing-btn:hover .btn-text {
    color: var(--clr-primary);
}

.wa-color .btn-skew {
    background: #25D366;
    box-shadow: 0 0 20px rgba(37, 211, 102, 0.4);
}

.wa-color:hover .btn-skew {
    background: #fff;
    box-shadow: 0 0 30px #25D366;
}

.wa-color:hover .btn-text {
    color: #25D366;
}

/* Socials Section Styles */
.social-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.social-icon {
    color: #fff;
}

.ig-color .btn-skew {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    box-shadow: 0 0 20px rgba(220, 39, 67, 0.4);
}

.ig-color:hover .btn-skew {
    box-shadow: 0 0 30px #dc2743;
}

.ig-color:hover .btn-text {
    /* Gradiente testuale nativo Instagram via background-clip */
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    /* Fallback */
}

/* L'icona SVG non eredita il background-clip del testo ma eredita purtroppo il color:transparent.
   Le diamo esplicitamente uno dei toni del gradiente Instagram per mantenerla visibile. */
.ig-color:hover .btn-text svg {
    stroke: #dc2743;
    /* Colore centrale del gradiente: rosa/rosso scuro */
}

.tt-color .btn-skew {
    background: #000;
    border: 1px solid #00f2fe;
    box-shadow: 0 0 10px rgba(0, 242, 254, 0.4);
}

.tt-color:hover .btn-skew {
    background: #fff;
    border-color: #FE2C55;
    box-shadow: -4px 0 10px rgba(0, 242, 254, 0.4), 4px 0 10px rgba(254, 44, 85, 0.4);
}

.tt-color:hover .btn-text {
    color: #000;
    text-shadow: -2px 0px 0px #00f2fe, 2px 0px 0px #FE2C55;
}

/* Applichiamo lo stesso effetto glitch all'icona SVG di TikTok (che ora è un path pieno, non stroke) */
.tt-color:hover .btn-text svg {
    filter: drop-shadow(-2px 0px 0px #00f2fe) drop-shadow(2px 0px 0px #FE2C55);
}

.outline-btn .btn-skew {
    background: transparent;
    border: 2px solid var(--clr-muted);
    box-shadow: none;
}

.outline-btn:hover .btn-skew {
    background: var(--clr-muted);
    border-color: var(--clr-muted);
}

.outline-btn:hover .btn-text {
    color: var(--clr-bg);
}

/* === Global Layout & Sections === */
.section {
    padding: 8rem 0;
    width: 100vw;
    display: flex;
    justify-content: center;
}

@media (max-width: 768px) {
    .section {
        padding: 4rem 0;
    }
}

.section-inner {
    width: 100%;
    max-width: 1400px;
    padding: 0 2rem;
}

.dark-section {
    position: relative;
    background: radial-gradient(circle at 0% 0%, rgba(202, 37, 27, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 100% 100%, rgba(202, 37, 27, 0.08) 0%, transparent 50%),
        linear-gradient(180deg, var(--clr-surface) 0%, #0a0a0a 100%);
    overflow: hidden;
}

.dark-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Subtle dot grid pattern */
    background-image: radial-gradient(rgba(255, 255, 255, 0.04) 1.5px, transparent 1.5px);
    background-size: 30px 30px;
    pointer-events: none;
    z-index: 0;
}

/* Make sure inner content stays above the background */
.dark-section>.section-inner {
    position: relative;
    z-index: 1;
}

.section-header {
    margin-bottom: 4rem;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    color: #fff;
    letter-spacing: 1px;
}

.section-title span {
    color: var(--clr-primary);
}

.racing-line {
    width: 100px;
    height: 6px;
    background: var(--clr-primary);
    transform: skewX(-30deg);
    margin-top: 1rem;
}

.racing-line.left-aligned {
    margin-left: 0;
}

/* Carbon Fiber Pattern Background */
.carbon-bg {
    background:
        radial-gradient(#1a1a1a 15%, transparent 16%) 0 0,
        radial-gradient(#1a1a1a 15%, transparent 16%) 8px 8px,
        radial-gradient(rgba(255, 255, 255, 0.03) 15%, transparent 20%) 0 1px,
        radial-gradient(rgba(255, 255, 255, 0.03) 15%, transparent 20%) 8px 9px;
    background-color: #0d0d0d;
    background-size: 16px 16px;
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* === Services Grid === */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 3rem;
}

.service-card {
    display: block;
    text-decoration: none;
    color: inherit;
    background: var(--clr-bg);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.4s ease, border-color 0.4s ease;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--clr-primary);
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: var(--clr-primary);
    transition: width 0.4s ease;
}

.service-card:hover::after {
    width: 100%;
}

.card-video-wrap {
    width: 100%;
    height: 250px;
    position: relative;
    overflow: hidden;
    background: #000;
}

.service-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(40%);
    transition: filter 0.4s ease, transform 0.6s ease;
}

.service-card:hover .service-video {
    filter: grayscale(0%);
    transform: scale(1.05);
}

.card-video-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(0deg, var(--clr-bg) 0%, transparent 100%);
}

.card-info {
    padding: 2.5rem;
}

.card-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #fff;
}

.card-info p {
    color: var(--clr-muted);
    font-size: 1.1rem;
    line-height: 1.6;
}

.card-action {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    color: var(--clr-primary);
    font-family: var(--ff-heading);
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.service-card:hover .card-action {
    color: #fff;
}

.card-action svg {
    width: 20px;
    height: 20px;
    animation: pointRight 1.5s infinite ease-in-out;
}

@keyframes pointRight {

    0%,
    100% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(8px);
    }
}

/* === Brands Section === */
.brands-container {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
    /* Ridotto il gap tra categorie da 4rem a 2.5rem */
}

.brand-category h3 {
    color: #fff;
    font-size: 1.5rem;
    /* Ridotto da 1.8rem */
    margin-bottom: 1.2rem;
    /* Ridotto da 2rem */
    text-transform: uppercase;
    letter-spacing: 2px;
    border-left: 4px solid var(--clr-primary);
    padding-left: 1rem;
}

.brand-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    /* Ridotto da 200px per farne entrare di più riga */
    gap: 1.5rem;
    /* Ridotto da 2rem */
}

.chemical-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.brand-item {
    background: #111;
    border: 1px solid #222;
    padding: 1.5rem;
    /* Ridotto da 2rem */
    text-align: center;
    color: #fff;
    font-family: var(--ff-heading);
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 90px;
    /* Ridotto da 120px */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    /* Ombra leggermente ridotta */
    position: relative;
    overflow: hidden;
}

.chemical-item .brand-logo {
    opacity: 0.6;
    /* Torniamo all'opacità standard pre-hover */
}

/* Correzione specifica per il logo Meguiar's: è un logo colorato
   Non possiamo usare la combo brightness(0) invert(1) perché diventerebbe un blocco unico.
   Usiamo un mix di filtri per renderlo una sagoma leggibile grigio-chiara/bianca */
img[alt="Meguiar's"] {
    filter: grayscale(100%) contrast(500%) brightness(1.5) invert(1);
}

.brand-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: skewX(-20deg);
    transition: left 0.5s ease;
}

.brand-item:hover::before {
    left: 150%;
}

.brand-item:hover {
    transform: translateY(-5px);
    border-color: var(--clr-primary);
    color: var(--clr-primary);
    box-shadow: 0 15px 40px rgba(202, 37, 27, 0.2);
}

.chemical-item {
    border-color: #333;
    font-size: 2rem;
}

.brand-logo {
    max-width: 80%;
    max-height: 60px;
    object-fit: contain;
    position: relative;
    z-index: 2;
    color: transparent;
    font-size: 0;
    /* Metodo affidabile che preserva l'anti-aliasing e l'alpha channel: 
       brightness(0) converte tutto in nero, invert(1) inverte il nero in bianco puro senza ingrossare i bordi */
    filter: brightness(0) invert(1);
    opacity: 0.6;
    transition: all 0.4s ease;
}

/* Correzione specifica per il logo Oracal: ha scritte bianche in negativo su un foglio rosso.
   Applichiamo la matematica dei filtri per trasformare il rosso in nero (poi invertito in bianco) 
   e il bianco in bianco (poi invertito in nero, mascherandolo sullo sfondo scuro). */
img[alt="Oracal"] {
    filter: grayscale(100%) contrast(500%) invert(1);
}

.brand-item:hover {
    transform: translateY(-5px);
    border-color: var(--clr-primary);
    color: var(--clr-primary);
    box-shadow: 0 15px 40px rgba(202, 37, 27, 0.2);
    /* Aggiungiamo un forte bagliore bianco dietro l'immagine al passaggio del mouse
       così sia i loghi neri che bianchi avranno contrasto perfetto sul fondale scuro */
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.8) 0%, rgba(17, 17, 17, 1) 70%), #111;
}

.brand-item:hover .brand-logo {
    /* Rivela i veri colori del brand al passaggio del mouse */
    filter: none;
    opacity: 1;
    transform: scale(1.1);
}

.brand-name {
    display: none;
}

/* === About Section === */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
}

@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

.owners-names {
    font-size: 2.5rem;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    color: #fff;
}

.about-text {
    font-size: 1.2rem;
    color: var(--clr-muted);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-bullets {
    list-style: none;
    margin-top: 2rem;
}

.about-bullets li {
    font-size: 1.2rem;
    font-family: var(--ff-heading);
    letter-spacing: 1px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.about-bullets span {
    color: var(--clr-primary);
    margin-right: 15px;
    font-size: 1.5rem;
}

.image-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
}

.frame-backdrop {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    border: 4px solid var(--clr-primary);
    z-index: 1;
}

.owners-photo-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #222, #111);
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.placeholder-text {
    font-family: var(--ff-heading);
    font-size: 2rem;
    color: rgba(255, 255, 255, 0.2);
    letter-spacing: 2px;
}

/* === Contact Section === */
.text-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.contact-subtitle {
    font-size: 1.2rem;
    color: var(--clr-muted);
    margin-top: 1.5rem;
}

.contact-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    margin-top: 4rem;
}

.contact-box {
    background: var(--clr-bg);
    padding: 4rem 3rem;
    border: 1px solid rgba(255, 255, 255, 0.03);
    text-align: center;
    position: relative;
}

.box-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    color: var(--clr-primary);
}

.box-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.wa-icon {
    color: #25D366;
}

.loc-icon {
    color: var(--clr-primary);
}

.contact-box h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.contact-box p {
    color: var(--clr-muted);
    font-size: 1.1rem;
    margin-bottom: 3rem;
    line-height: 1.6;
}

/* Footer */
.site-footer {
    background: #000;
    padding: 2rem;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.site-footer p {
    color: var(--clr-muted);
    font-size: 1rem;
}

/* Utilities */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.1, 0.7, 0.1, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* === Modals === */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    padding: 2rem;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: var(--clr-surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 1000px;
    max-height: 90vh;
    border-radius: 8px;
    position: relative;
    transform: translateY(50px);
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: transparent;
    border: none;
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 10;
    background: rgba(0, 0, 0, 0.5);
    transition: background 0.3s, color 0.3s;
}

.modal-close:hover {
    background: var(--clr-primary);
    color: #fff;
}

.modal-close svg {
    width: 24px;
    height: 24px;
}

.modal-header {
    padding: 2.5rem 3rem 1.5rem;
}

.modal-header p {
    color: var(--clr-muted);
    margin-top: 1rem;
    font-size: 1.1rem;
}

/* === Comparison Slider === */
.comparison-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    /* Proporzione fissa per le foto auto */
    background: #000;
    overflow: hidden;
    cursor: col-resize;
    -webkit-user-select: none;
    user-select: none;
}

.slider-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.before-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    /* Questo valore verrà manipolato tramite JS */
    height: 100%;
    overflow: hidden;
    /* Taglia l'immagine PRIMA qui */
    border-right: 2px solid #fff;
    /* Linea di separazione fallback */
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

/* L'immagine dentro al prima è forzata alla grandezza totale dello slider
   così quando il wrapper si croppa, l'immagine sotto rimane fissa. */
.before-wrapper .slider-image {
    width: 100vw;
    /* Verrà forzata via JS alla larghezza esatta del container */
    max-width: none;
}

.slider-handle {
    position: absolute;
    top: 0;
    left: 50%;
    /* Manipolato via JS */
    height: 100%;
    width: 4px;
    background: #fff;
    z-index: 3;
    transform: translateX(-50%);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    pointer-events: none;
    /* Il Drag avviene sul contenitore principale */
}

.handle-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--clr-primary);
    border: 3px solid #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.handle-button svg {
    width: 16px;
    height: 16px;
    color: #fff;
}

.slider-label {
    position: absolute;
    bottom: 1.5rem;
    padding: 0.5rem 1rem;
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    color: #fff;
    font-family: var(--ff-heading);
    letter-spacing: 2px;
    font-size: 0.9rem;
    border-radius: 4px;
    z-index: 4;
    pointer-events: none;
}

.label-before {
    left: 1.5rem;
}

.label-after {
    right: 1.5rem;
    text-align: right;
}

.modal-footer {
    padding: 1.5rem 3rem 2.5rem;
    display: flex;
    justify-content: flex-end;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.3) 0%, transparent 100%);
}

@media (max-width: 768px) {

    .modal-header,
    .modal-footer {
        padding: 1.5rem;
    }

    .comparison-slider {
        aspect-ratio: 4/3;
    }

    /* Sui telefoni mostriamo un po' più verticale */
}