/**
 * Hero Samadhi — impianto dell'hero di optlyx.com nella palette del centro.
 *
 * Stessa gerarchia: eyebrow spaziata, titolo enorme con sottolineatura tracciata
 * a mano sull'ultima parola, riga d'accento in corsivo, sottotitolo, due CTA a
 * pillola, rassicurazione, striscia di tre punti-chiave. Al posto del cielo
 * animato resta la foto della sala, sfumata verso l'avorio della pagina.
 */

.sxh {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 780px;
    padding: 148px 24px 84px;
    overflow: hidden;
    background: #142620;
    text-align: center;
}

@media (min-width: 640px) {
    .sxh {
        min-height: 100vh;
        padding: 168px 24px 96px;
    }
}

.sxh-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center bottom;
    z-index: 0;
}

/* Velo verde: la sala resta leggibile sotto, il testo chiaro sopra stacca.
 * Stesso trattamento delle pagine locali (seo-local.css). */
.sxh-veil {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg,
            rgba(20, 38, 32, .58) 0%,
            rgba(20, 38, 32, .74) 55%,
            rgba(20, 38, 32, .88) 100%);
    pointer-events: none;
}

.sxh-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
}

.sxh-eyebrow {
    margin: 0;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .18em;
    color: var(--col-accent, #d6c6b0);
}

.sxh-title {
    margin: 24px auto 0;
    max-width: 26ch;
    font-family: var(--sx-display);
    font-size: clamp(36px, 6.4vw, 82px);
    font-weight: 400;
    text-wrap: balance;
    line-height: .98;
    letter-spacing: -.035em;
    color: #fdfcf8;
}

.sxh-title-line {
    display: block;
}

.sxh-accent {
    display: block;
    margin-top: 10px;
    font-style: italic;
    font-weight: 300;
    letter-spacing: -.03em;
    color: var(--col-accent, #d6c6b0);
}

/* Sottolineatura tracciata: si disegna una volta, dopo il titolo. */
.sxh-underline {
    position: relative;
    display: inline-block;
    white-space: nowrap;
}

.sxh-underline svg {
    position: absolute;
    left: -2%;
    bottom: -.11em;
    width: 104%;
    height: .28em;
    overflow: visible;
}

.sxh-underline path {
    fill: none;
    stroke: var(--col-accent, #d6c6b0);
    stroke-width: 6;
    stroke-linecap: round;
    stroke-dasharray: 400;
    stroke-dashoffset: 400;
    animation: sxh-draw .9s cubic-bezier(.22, 1, .36, 1) .85s forwards;
}

@keyframes sxh-draw {
    to {
        stroke-dashoffset: 0;
    }
}

.sxh-sub {
    margin: 30px auto 0;
    max-width: 46ch;
    font-size: 1.05rem;
    line-height: 1.7;
    color: rgba(253, 252, 248, .88);
}

@media (min-width: 640px) {
    .sxh-sub {
        font-size: 1.15rem;
    }
}

.sxh-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    gap: 12px;
    margin-top: 34px;
}

@media (min-width: 640px) {
    .sxh-actions {
        flex-direction: row;
        align-items: center;
    }
}

.sxh-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 50px;
    padding: 13px 28px;
    border-radius: 9999px;
    font-size: .95rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform .2s cubic-bezier(.22, 1, .36, 1), background .2s, color .2s;
}

.sxh-btn-primary {
    background: var(--col-bg, #fdfcf8);
    color: var(--col-primary, #1f3b32);
    border: 1px solid var(--col-bg, #fdfcf8);
    box-shadow: 0 16px 40px rgba(0, 0, 0, .28);
}

.sxh-btn-primary:hover {
    transform: translateY(-2px);
    background: #fff;
}

.sxh-btn-ghost {
    background: rgba(253, 252, 248, .08);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: #fdfcf8;
    border: 1px solid rgba(253, 252, 248, .5);
}

.sxh-btn-ghost:hover {
    background: rgba(253, 252, 248, .16);
    border-color: #fdfcf8;
    transform: translateY(-2px);
}

.sxh-note {
    margin: 20px 0 0;
    font-size: .82rem;
    color: rgba(253, 252, 248, .66);
}

/* Entrata scaglionata, come le righe dell'hero Optlyx. */
.sxh-rise {
    animation: sxh-rise .7s cubic-bezier(.16, 1, .3, 1) both;
}

.sxh-eyebrow.sxh-rise {
    animation-delay: 0s;
}

.sxh-title.sxh-rise {
    animation-delay: .08s;
}

.sxh-sub.sxh-rise {
    animation-delay: .22s;
}

.sxh-actions.sxh-rise {
    animation-delay: .34s;
}

.sxh-note.sxh-rise {
    animation-delay: .46s;
}

@keyframes sxh-rise {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sxh-rise {
        animation: none;
    }

    .sxh-underline path {
        animation: none;
        stroke-dashoffset: 0;
    }
}
