/* ============================================================
   Admiche Hero v3 - front
   ============================================================ */
.admh-hero{
    position:relative;
    width:100%;
    min-height:var(--admh-height,70vh);
    display:flex;
    align-items:center;
    overflow:hidden;
    isolation:isolate;
    font-family:var(--admh-font,inherit);
}
.admh-hero.admh-fullscreen{
    min-height:100vh;
    min-height:100svh;
    min-height:100dvh;
}

.admh-bg{ position:absolute; inset:0; z-index:1; overflow:hidden; }
.admh-bg-img{ position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }

/* Vidéo MP4 auto-hébergée : couvre tout le hero */
.admh-mp4{
    position:absolute; inset:0;
    width:100%; height:100%;
    object-fit:cover;
    pointer-events:none;
}

/* Vidéo YouTube (iframe injectée en JS) */
.admh-video{ position:absolute; inset:0; width:100%; height:100%; pointer-events:none; }
.admh-video iframe{
    position:absolute; top:50%; left:50%;
    width:100vw; height:56.25vw;
    min-width:177.77vh; min-height:100%;
    transform:translate(-50%,-50%);
    border:0; opacity:0; transition:opacity .6s ease;
}
.admh-video.is-ready iframe{ opacity:1; }

.admh-bgcolor{ position:absolute; inset:0; background:var(--admh-bg-color,transparent); opacity:var(--admh-bg-opacity,0); }
.admh-overlay{ position:absolute; inset:0; background:#000; opacity:var(--admh-overlay,.45); }
/* Voile dégradé (v3.9) : assombrit un côté, laisse l'image visible ailleurs */
.admh-ov-bas .admh-overlay{
    background:linear-gradient(to top, rgba(0,0,0,var(--admh-overlay,.45)) 0%, rgba(0,0,0,calc(var(--admh-overlay,.45) * .35)) 45%, rgba(0,0,0,0) 85%);
    opacity:1;
}
.admh-ov-haut .admh-overlay{
    background:linear-gradient(to bottom, rgba(0,0,0,var(--admh-overlay,.45)) 0%, rgba(0,0,0,calc(var(--admh-overlay,.45) * .35)) 45%, rgba(0,0,0,0) 85%);
    opacity:1;
}

.admh-content{
    position:relative; z-index:2;
    width:100%; max-width:var(--admh-content-width,1100px); margin:0 auto;
    /* marges intérieures personnalisables (défaut 2rem / 1.5rem) */
    padding:var(--admh-pad-y,2rem) var(--admh-pad-x,1.5rem);
    color:#fff;
}
.admh-align-center .admh-content{ text-align:center; }
.admh-align-left   .admh-content{ text-align:left;  }
.admh-align-right  .admh-content{ text-align:right; }

.admh-title{
    margin:0 0 .5em;
    color:var(--admh-title-color,#fff);
    font-family:var(--admh-font,inherit);
    font-size:var(--admh-title-size, clamp(1.8rem,4vw,3.2rem));
    line-height:1.15;
    text-shadow:var(--admh-tsh-title, 0 2px 12px rgba(0,0,0,.35));
}
.admh-subtitle{
    margin:0 auto 1.4em; max-width:var(--admh-content-width,640px);
    color:var(--admh-sub-color,#fff);
    font-family:var(--admh-font,inherit);
    font-size:var(--admh-sub-size, clamp(1rem,1.6vw,1.25rem));
    line-height:1.5;
    text-shadow:var(--admh-tsh-sub, 0 1px 8px rgba(0,0,0,.35));
}
.admh-align-left  .admh-subtitle{ margin-left:0; }
.admh-align-right .admh-subtitle{ margin-right:0; }

.admh-buttons{ display:flex; gap:.8rem; flex-wrap:wrap; }
.admh-align-center .admh-buttons{ justify-content:center; }
.admh-align-right  .admh-buttons{ justify-content:flex-end; }

/* --- Styles de texte par élément (v3.3) --- */
/* Alignement par élément (surcharge le global) */
.admh-title.admh-ta-left,   .admh-subtitle.admh-ta-left{ text-align:left; }
.admh-title.admh-ta-center, .admh-subtitle.admh-ta-center{ text-align:center; }
.admh-title.admh-ta-right,  .admh-subtitle.admh-ta-right{ text-align:right; }
.admh-subtitle.admh-ta-left{ margin-left:0; margin-right:auto; }
.admh-subtitle.admh-ta-right{ margin-right:0; margin-left:auto; }
.admh-subtitle.admh-ta-center{ margin-left:auto; margin-right:auto; }
/* Alignement des boutons (surcharge le global) */
.admh-buttons.admh-ba-left{ justify-content:flex-start; }
.admh-buttons.admh-ba-center{ justify-content:center; }
.admh-buttons.admh-ba-right{ justify-content:flex-end; }
/* Graisse */
.admh-w500{ font-weight:500; }
.admh-w700{ font-weight:700; }
/* Italique */
.admh-italic{ font-style:italic; }
/* Majuscules */
.admh-upper{ text-transform:uppercase; letter-spacing:.02em; }

/* Ombre de texte (v3.9) : détache le texte d'un fond clair. Pilote les variables. */
.admh-tsh-soft{ --admh-tsh-title:0 2px 8px rgba(0,0,0,.45); --admh-tsh-sub:0 1px 6px rgba(0,0,0,.45); }
.admh-tsh-strong{ --admh-tsh-title:0 3px 14px rgba(0,0,0,.75), 0 1px 3px rgba(0,0,0,.6); --admh-tsh-sub:0 2px 10px rgba(0,0,0,.7), 0 1px 3px rgba(0,0,0,.5); }
.admh-tsh-none{ --admh-tsh-title:none; --admh-tsh-sub:none; }

.admh-btn{
    display:inline-block;
    padding:var(--admh-btn-pad-y, .85em) var(--admh-btn-pad-x, 1.7em);
    border-radius:var(--admh-btn-radius, 8px);
    font-weight:700; text-decoration:none;
    font-size:var(--admh-btn-size, 16px);
    transition:background-color .18s ease, color .18s ease, transform .15s ease, border-color .18s ease, box-shadow .18s ease;
    border:var(--admh-btn-border, 2px) solid transparent;
}
.admh-btn:hover{ transform:translateY(-2px); }
/* Ombre (v3.6) */
.admh-btnshadow-soft .admh-btn{ box-shadow:0 4px 14px rgba(0,0,0,.18); }
.admh-btnshadow-strong .admh-btn{ box-shadow:0 8px 24px rgba(0,0,0,.30); }
.admh-btnshadow-soft .admh-btn:hover{ box-shadow:0 6px 18px rgba(0,0,0,.24); }
.admh-btnshadow-strong .admh-btn:hover{ box-shadow:0 12px 30px rgba(0,0,0,.36); }
/* Majuscules boutons */
.admh-btn-upper .admh-btn{ text-transform:uppercase; letter-spacing:.03em; }
.admh-btn-1{ background:var(--admh-b1-bg,#f57c00); color:var(--admh-b1-c,#fff); border-color:var(--admh-b1-bg,#f57c00); }
.admh-btn-1:hover{ background:var(--admh-b1-bgh,#e06c00); color:var(--admh-b1-ch,#fff); border-color:var(--admh-b1-bgh,#e06c00); }
.admh-btn-2.admh-btn-outline{ background:transparent; color:var(--admh-b2-c,#fff); border-color:var(--admh-b2-c,#fff); }
.admh-btn-2.admh-btn-outline:hover{ background:var(--admh-b2-bgh,#fff); color:var(--admh-b2-ch,#1565c0); border-color:var(--admh-b2-bgh,#fff); }
.admh-btn-2.admh-btn-solid{ background:var(--admh-b2-bg,#fff); color:var(--admh-b2-c,#1565c0); border-color:var(--admh-b2-bg,#fff); }
.admh-btn-2.admh-btn-solid:hover{ background:var(--admh-b2-bgh,#fff); color:var(--admh-b2-ch,#1565c0); border-color:var(--admh-b2-bgh,#fff); }

/* --- Flèche de défilement (corrigée pour le TACTILE mobile) --- */
.admh-scroll{
    position:absolute; left:50%; bottom:22px;
    transform:translateX(-50%);
    z-index:5;                          /* au-dessus de tout */
    display:flex; flex-direction:column; align-items:center; gap:8px;
    background:none; border:0; cursor:pointer; padding:10px;
    -webkit-tap-highlight-color:transparent;
    touch-action:manipulation;          /* réactif au tap mobile */
    pointer-events:auto;                /* cliquable même si parent non-cliquable */
}
.admh-scroll-mouse{ width:24px; height:38px; border:2px solid #fff; border-radius:14px; position:relative; }
.admh-scroll-mouse::before{
    content:""; position:absolute; left:50%; top:7px;
    width:4px; height:8px; border-radius:2px; background:#fff;
    transform:translateX(-50%); animation:admh-wheel 1.6s ease-in-out infinite;
}
.admh-scroll-chevron{ width:12px; height:12px; border-right:2px solid #fff; border-bottom:2px solid #fff; transform:rotate(45deg); animation:admh-bounce 1.6s ease-in-out infinite; }
@keyframes admh-wheel{ 0%{opacity:1;top:7px} 60%{opacity:0;top:16px} 100%{opacity:0} }
@keyframes admh-bounce{ 0%,100%{transform:rotate(45deg) translate(0,0)} 50%{transform:rotate(45deg) translate(3px,3px)} }

/* ============================================================
   MOBILE
   ============================================================ */
@media (max-width:781px){
    /* Typo mobile indépendante (si définie, sinon reprend le PC) */
    .admh-hero{ font-family:var(--admh-font-m, var(--admh-font, inherit)); }
    .admh-title{
        font-family:var(--admh-font-m, var(--admh-font, inherit));
        font-size:var(--admh-title-size-m, var(--admh-title-size, clamp(1.6rem,7vw,2.4rem)));
    }
    .admh-subtitle{
        font-family:var(--admh-font-m, var(--admh-font, inherit));
        font-size:var(--admh-sub-size-m, var(--admh-sub-size, clamp(.95rem,3.6vw,1.1rem)));
    }
    .admh-btn{ font-size:var(--admh-btn-size-m, var(--admh-btn-size, 15px)); }

    /* YouTube : masquée sur mobile sauf si demandé (pas d'image) */
    .admh-video{ display:none; }
    .admh-video-mobile .admh-video{ display:block; }
    /* MP4 : masquée sur mobile sauf si demandé */
    .admh-mp4{ display:none; }
    .admh-video-mobile .admh-mp4{ display:block; }

    .admh-hero:not(.admh-fullscreen){ min-height:60vh; }
    .admh-scroll{ bottom:16px; }
}

@media (prefers-reduced-motion:reduce){
    .admh-video,.admh-mp4{ display:none; }
    .admh-scroll-mouse::before,.admh-scroll-chevron{ animation:none; }
}
