/* SERVICE HERO 15 - SCROLL, LE SERVICE EN DIRECT
   La version `scroll` de service-hero-4 : sombre et compact, fil d'Ariane,
   H1 et description à gauche, demande de devis et numéro d'urgence à droite,
   chiffres en pied. Le fond devient le film du service, cadré comme un
   tournage (coins de viseur, compteur d'étape, piste de montage) ; chapitres
   et chiffres défilent dessus, la conclusion reprend les boutons.

   Mécanique partagée : heros/main.css et heros/main.js (`data-hero-scroll`).
   Tout texte est posé sur l'image : blanc, voile écrit ici (§4.14). */

.service-hero-15 {
    --service-hero-15-gouttiere: clamp(1rem, 4vw, 3.5rem);
    --service-hero-15-cadre: clamp(0.75rem, 2.5vw, 2rem);
    /* Rouge de STATUT (« enregistrement en cours ») : ne suit pas la charte,
       un voyant d'enregistrement est rouge sur tous les sites (§4.1). */
    --service-hero-15-rec: #e5372c;

    background: var(--black);
    color: var(--white);
}

.service-hero-15__voile {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.72) 0, rgba(0, 0, 0, 0.35) 55%, rgba(0, 0, 0, 0.5) 100%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.45) 0, transparent 30%, rgba(0, 0, 0, 0.6) 100%);
}

/* ---- Le viseur --------------------------------------------- */
.service-hero-15__viseur {
    position: absolute;
    z-index: 2;
    inset: calc(var(--header-height, 80px) + var(--service-hero-15-cadre)) var(--service-hero-15-cadre) var(--service-hero-15-cadre);
    pointer-events: none;
}

.service-hero-15__coin {
    position: absolute;
    width: clamp(1.25rem, 3vw, 2.25rem);
    height: clamp(1.25rem, 3vw, 2.25rem);
    border: 0 solid color-mix(in srgb, var(--white) 75%, transparent);
}

.service-hero-15__coin--hg { top: 0; left: 0; border-top-width: 2px; border-left-width: 2px; }
.service-hero-15__coin--hd { top: 0; right: 0; border-top-width: 2px; border-right-width: 2px; }
.service-hero-15__coin--bg { bottom: 0; left: 0; border-bottom-width: 2px; border-left-width: 2px; }
.service-hero-15__coin--bd { bottom: 0; right: 0; border-bottom-width: 2px; border-right-width: 2px; }

/* ---- Le compteur d'étape ----------------------------------- */
.service-hero-15__compteur {
    position: absolute;
    z-index: 3;
    top: calc(var(--header-height, 80px) + var(--service-hero-15-cadre) + 0.9rem);
    right: calc(var(--service-hero-15-cadre) + 1rem);
    display: grid;
    align-items: center;
    grid-template-columns: auto auto;
    column-gap: 0.55rem;
    margin: 0;
    padding: 0.35rem 0.7rem;
    border-radius: 0.3rem;
    background: rgba(0, 0, 0, 0.55);
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    line-height: 1.2;
    text-transform: uppercase;
}

/* Le point d'enregistrement (couleur de statut, nommée sur la racine). */
.service-hero-15__rec {
    grid-column: 1;
    grid-row: 1;
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 50%;
    background: var(--service-hero-15-rec);
    animation: serviceHero15Rec 1.6s ease-in-out infinite;
}

@keyframes serviceHero15Rec {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.25; }
}

.service-hero-15__compteur-etape {
    grid-column: 2;
    grid-row: 1;
    color: var(--white);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-hero-15__compteur-etape.is-actif {
    opacity: 1;
}

/* ---- Les étapes -------------------------------------------- */
.service-hero-15__etapes {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: grid;
    padding: calc(var(--header-height, 80px) + var(--service-hero-15-cadre) + 3.5rem) calc(var(--service-hero-15-cadre) + var(--service-hero-15-gouttiere)) clamp(5rem, 12vh, 7.5rem);
}

.service-hero-15__etape {
    grid-area: 1 / 1;
    align-self: end;
    max-width: 44rem;
    opacity: 0;
    visibility: hidden;
    clip-path: inset(0 100% 0 0);
    transition: opacity 0.4s ease, clip-path 0.7s cubic-bezier(0.7, 0, 0.2, 1), visibility 0s linear 0.7s;
}

.service-hero-15__etape.is-actif {
    opacity: 1;
    visibility: visible;
    clip-path: inset(0 0 0 0);
    transition: opacity 0.4s ease 0.05s, clip-path 0.8s cubic-bezier(0.7, 0, 0.2, 1) 0.05s, visibility 0s;
}

.service-hero-15__etape--ouverture {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem 3rem;
    max-width: none;
}

.service-hero-15__gauche {
    flex: 1 1 26rem;
    min-width: 0;
    max-width: 40rem;
}

.service-hero-15__droite {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: flex-end;
    gap: 1rem;
}

/* ---- Fil d'Ariane (balisage de mcl_noeud_fil_ariane(), non classable) -- */
.service-hero-15__ariane {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 1rem;
    color: color-mix(in srgb, var(--white) 75%, transparent);
    font-family: var(--font-body);
    font-size: 0.85rem;
    line-height: 1.4;
}

.service-hero-15__ariane a {
    color: color-mix(in srgb, var(--white) 75%, transparent);
    text-decoration: none;
    transition: color 0.2s ease;
}

.service-hero-15__ariane a:hover,
.service-hero-15__ariane a:focus-visible {
    color: var(--white);
    text-decoration: underline;
}

.service-hero-15__ariane a:focus-visible {
    outline: 2px solid var(--white);
    outline-offset: 2px;
}

.service-hero-15__ariane span {
    color: color-mix(in srgb, var(--white) 65%, transparent);
}

.service-hero-15__ariane .current {
    color: var(--white);
}

.service-hero-15__ariane .mcl-accent {
    color: inherit;
    font-style: italic;
}

/* ---- Textes ------------------------------------------------ */
.service-hero-15__titre,
.service-hero-15__titre:hover {
    margin: 0;
    color: var(--white);
    font-family: var(--font-display);
    font-size: clamp(2.1rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.05;
    text-wrap: balance;
}

.service-hero-15__chapitre,
.service-hero-15__chapitre:hover {
    margin: 0;
    color: var(--white);
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4.2vw, 3.2rem);
    font-weight: 700;
    line-height: 1.08;
    text-wrap: balance;
}

.service-hero-15__titre .mcl-accent,
.service-hero-15__chapitre .mcl-accent {
    color: var(--white);
    font-style: italic;
}

.service-hero-15__description,
.service-hero-15__texte {
    margin: 1rem 0 0;
    max-width: 34rem;
    color: var(--white);
    font-family: var(--font-body);
    font-size: clamp(0.98rem, 1.3vw, 1.1rem);
    line-height: 1.65;
}

.service-hero-15__description .mcl-accent,
.service-hero-15__texte .mcl-accent {
    color: var(--white);
    font-weight: 700;
}

.service-hero-15__repere {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    margin: 0 0 1rem;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    line-height: 1.3;
    text-transform: uppercase;
}

.service-hero-15__repere-numero {
    color: var(--white);
    font-family: var(--font-display);
    font-size: 1.6rem;
    letter-spacing: 0;
    line-height: 1;
}

.service-hero-15__repere-texte {
    color: var(--white);
}

/* ---- Chiffres ---------------------------------------------- */
.service-hero-15__etape--chiffres {
    max-width: 64rem;
}

.service-hero-15__chiffres {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 2rem;
    margin: 1.5rem 0 0;
    padding: 0;
    list-style: none;
}

.service-hero-15__chiffre {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding-left: 1rem;
    border-left: 2px solid color-mix(in srgb, var(--white) 45%, transparent);
    color: var(--white);
}

.service-hero-15__chiffre-valeur {
    color: var(--white);
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    font-weight: 700;
    line-height: 1;
}

.service-hero-15__chiffre-libelle {
    color: color-mix(in srgb, var(--white) 82%, transparent);
    font-family: var(--font-body);
    font-size: 0.85rem;
    line-height: 1.4;
}

/* ---- Boutons et urgence ------------------------------------ */
.service-hero-15__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.service-hero-15__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    padding: 0.85rem 1.7rem;
    border: 0;
    border-radius: 0.3rem;
    background: none;
    color: inherit;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.service-hero-15__btn--principal {
    background: var(--accent);
    color: var(--on-accent);
}

.service-hero-15__btn--principal:hover,
.service-hero-15__btn--principal:focus-visible {
    background: color-mix(in srgb, var(--accent) 86%, var(--black));
    color: var(--on-accent);
    transform: translateY(-1px);
}

.service-hero-15__btn--secondaire {
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--white) 70%, transparent);
    color: var(--white);
}

.service-hero-15__btn--secondaire:hover,
.service-hero-15__btn--secondaire:focus-visible {
    background: var(--white);
    color: var(--black);
}

.service-hero-15__btn:focus-visible,
.service-hero-15__tel:focus-visible,
.service-hero-15__passer:focus-visible {
    outline: 2px solid var(--white);
    outline-offset: 3px;
}

.service-hero-15__urgence {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.4rem;
    margin: 0;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.9rem;
    line-height: 1.4;
}

.service-hero-15__etape--conclusion .service-hero-15__urgence {
    margin-top: 1rem;
}

.service-hero-15__urgence-libelle {
    color: color-mix(in srgb, var(--white) 80%, transparent);
}

.service-hero-15__tel {
    border: 0;
    background: none;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
    cursor: pointer;
}

.service-hero-15__tel:hover,
.service-hero-15__tel:focus-visible {
    color: var(--white);
    text-decoration: underline;
}

/* ---- La piste de montage ----------------------------------- */
.service-hero-15__piste {
    position: absolute;
    z-index: 3;
    left: calc(var(--service-hero-15-cadre) + var(--service-hero-15-gouttiere));
    right: calc(var(--service-hero-15-cadre) + var(--service-hero-15-gouttiere));
    bottom: calc(var(--service-hero-15-cadre) + 1.25rem);
    height: 3px;
    background: color-mix(in srgb, var(--white) 25%, transparent);
}

.service-hero-15__piste-barre {
    position: absolute;
    inset: 0;
    background: var(--white);
    transform: scaleX(var(--hero-scroll-avance, 0));
    transform-origin: left;
}

.service-hero-15__encoche {
    position: absolute;
    top: 50%;
    left: var(--service-hero-15-pos, 0%);
    width: 2px;
    height: 0.8rem;
    background: color-mix(in srgb, var(--white) 55%, transparent);
    transform: translateY(-50%);
    transition: background-color 0.3s ease, height 0.3s ease;
}

.service-hero-15__encoche.is-actif,
.service-hero-15__encoche.est-vue {
    background: var(--white);
}

.service-hero-15__encoche.is-actif {
    height: 1.2rem;
}

.service-hero-15__passer {
    position: absolute;
    z-index: 3;
    right: calc(var(--service-hero-15-cadre) + var(--service-hero-15-gouttiere));
    bottom: calc(var(--service-hero-15-cadre) + 2.25rem);
    padding: 0.4rem 0;
    border: 0;
    background: none;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    line-height: 1.3;
    text-decoration: underline;
    text-underline-offset: 0.3em;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.service-hero-15__passer:hover,
.service-hero-15__passer:focus-visible {
    color: var(--white);
    opacity: 1;
}

/* ---- État statique : sans JS, ou mouvement réduit ---------- */
/* En colonne flex, l'alignement de la grille animée (end, center) décalerait
   l'étape : elle reprend toute la largeur. */
.service-hero-15.is-statique .service-hero-15__etape {
    align-self: stretch;
}

.service-hero-15.is-statique .service-hero-15__etapes {
    position: relative;
    inset: auto;
    display: flex;
    flex-direction: column;
    gap: clamp(3rem, 9vh, 5rem);
    min-height: 100vh;
    min-height: 100svh;
}

.service-hero-15.is-statique .service-hero-15__etape {
    clip-path: none;
}

.service-hero-15.is-statique .service-hero-15__voile {
    background: rgba(0, 0, 0, 0.64);
}

.service-hero-15.is-statique .service-hero-15__compteur {
    display: none;
}

/* ---- Responsive -------------------------------------------- */
@media (min-width: 1024px) {
    .service-hero-15__chiffres {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .service-hero-15__droite {
        align-items: stretch;
        width: 100%;
    }

    .service-hero-15__etape--ouverture {
        gap: 1.25rem;
    }

    .service-hero-15__btn {
        flex: 1 1 100%;
    }

    .service-hero-15__coin--bg,
    .service-hero-15__coin--bd {
        display: none;
    }

    .service-hero-15__passer {
        left: calc(var(--service-hero-15-cadre) + var(--service-hero-15-gouttiere));
        right: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .service-hero-15__rec {
        animation: none;
    }
}
