/**
 * Leadgen — Hero Slider CSS
 * ~180 lignes. Aucune dépendance externe.
 * Transitions : fade, slide, slide-up, zoom, clip (wipe).
 */

/* ── Conteneur ────────────────────────────────────── */
.lghs-slider {
    position: relative;
    width: 100%;
    height: 85vh;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
}

/* ── Track ────────────────────────────────────────── */
.lghs-track {
    position: absolute;
    inset: 0;
}

/* ── Slide ────────────────────────────────────────── */
.lghs-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    will-change: opacity, transform;
}

.lghs-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    z-index: 2;
}

.lghs-slide.is-prev {
    z-index: 1;
    opacity: 1;
}

/* ── Fond image ───────────────────────────────────── */
.lghs-bg {
    position: absolute;
    inset: -4%;  /* marge pour l'effet zoom/parallax */
    background-size: cover;
    background-repeat: no-repeat;
    will-change: transform;
    transition: transform 8s ease-out;
}

.lghs-slide.is-active .lghs-bg {
    transform: scale(1.04);
}

.lghs-slide:not(.is-active) .lghs-bg {
    transform: scale(1);
}

/* ── Overlay ──────────────────────────────────────── */
.lghs-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
}

/* ── Contenu ──────────────────────────────────────── */
.lghs-content {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    padding: 0 60px;
}

.lghs-valign--top    { align-items: flex-start; padding-top: 80px; }
.lghs-valign--bottom { align-items: flex-end;   padding-bottom: 80px; }

.lghs-inner {
    max-width: 760px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.lghs-align--center { margin: 0 auto; text-align: center; align-items: center; }
.lghs-align--right  { margin-left: auto; text-align: right; align-items: flex-end; }
.lghs-align--left   { align-items: flex-start; }

/* ── Textes ───────────────────────────────────────── */
.lghs-eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #F4A024;
    margin-bottom: 14px;
}

.lghs-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.025em;
    color: #ffffff;
    margin: 0 0 18px;
}

.lghs-desc {
    font-size: clamp(14px, 1.8vw, 17px);
    line-height: 1.8;
    color: rgba(255,255,255,0.78);
    margin: 0 0 32px;
    max-width: 560px;
}

.lghs-align--center .lghs-desc { max-width: 100%; }

/* ── Boutons ──────────────────────────────────────── */
.lghs-btns {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.lghs-align--center .lghs-btns { justify-content: center; }
.lghs-align--right  .lghs-btns { justify-content: flex-end; }

.lghs-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 28px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 8px;
    border: 2px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.15s;
    white-space: nowrap;
    line-height: 1;
}

.lghs-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.lghs-btn:active { transform: translateY(0); }

.lghs-btn--primary  { background: #F4A024; color: #0F2540; }
.lghs-btn--outline  { background: transparent; color: #fff; border-color: #fff; }
.lghs-btn--ghost    { background: transparent; color: #fff; border-color: transparent; padding-left: 0; }

/* ── Animations éléments ──────────────────────────── */
.lghs-anim {
    opacity: 0;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* États initiaux selon l'animation choisie */
.lghs-anim[data-anim="fade-up"]    { transform: translateY(30px); }
.lghs-anim[data-anim="fade-down"]  { transform: translateY(-30px); }
.lghs-anim[data-anim="fade-left"]  { transform: translateX(40px); }
.lghs-anim[data-anim="fade-right"] { transform: translateX(-40px); }
.lghs-anim[data-anim="zoom-in"]    { transform: scale(0.88); }
.lghs-anim[data-anim="fade"]       { transform: none; }
.lghs-anim[data-anim="none"]       { opacity: 1; transform: none; }

/* Entrée : déclenché par JS (classe .is-in) */
.lghs-anim.is-in {
    opacity: 1;
    transform: none;
}

/* Reset quand slide inactive */
.lghs-slide:not(.is-active) .lghs-anim {
    opacity: 0;
}

.lghs-slide:not(.is-active) .lghs-anim[data-anim="fade-up"]    { transform: translateY(30px); }
.lghs-slide:not(.is-active) .lghs-anim[data-anim="fade-down"]  { transform: translateY(-30px); }
.lghs-slide:not(.is-active) .lghs-anim[data-anim="fade-left"]  { transform: translateX(40px); }
.lghs-slide:not(.is-active) .lghs-anim[data-anim="fade-right"] { transform: translateX(-40px); }
.lghs-slide:not(.is-active) .lghs-anim[data-anim="zoom-in"]    { transform: scale(0.88); }
.lghs-slide:not(.is-active) .lghs-anim[data-anim="none"]       { opacity: 1; transform: none; }

/* ── EFFETS DE TRANSITION ─────────────────────────── */

/* 1. Fade (défaut) — déjà géré par opacity sur .lghs-slide */
.lghs-transition--fade .lghs-slide {
    transition: opacity 0.8s ease;
}

/* 2. Slide horizontal */
.lghs-transition--slide .lghs-slide {
    transition: opacity 0s, transform 0.8s cubic-bezier(0.77,0,0.18,1);
}
.lghs-transition--slide .lghs-slide:not(.is-active):not(.is-prev) {
    transform: translateX(100%);
    opacity: 1;
}
.lghs-transition--slide .lghs-slide.is-active {
    transform: translateX(0);
    opacity: 1;
}
.lghs-transition--slide .lghs-slide.is-prev {
    transform: translateX(-100%);
    opacity: 1;
}
.lghs-transition--slide .lghs-slide.slide-from-prev:not(.is-active):not(.is-prev) {
    transform: translateX(-100%);
}

/* 3. Slide vertical */
.lghs-transition--slide-up .lghs-slide {
    transition: opacity 0s, transform 0.8s cubic-bezier(0.77,0,0.18,1);
}
.lghs-transition--slide-up .lghs-slide:not(.is-active):not(.is-prev) {
    transform: translateY(100%); opacity: 1;
}
.lghs-transition--slide-up .lghs-slide.is-active {
    transform: translateY(0); opacity: 1;
}
.lghs-transition--slide-up .lghs-slide.is-prev {
    transform: translateY(-100%); opacity: 1;
}

/* 4. Zoom out */
.lghs-transition--zoom .lghs-slide {
    transition: opacity 0.9s ease, transform 0.9s ease;
}
.lghs-transition--zoom .lghs-slide:not(.is-active) {
    transform: scale(1.08);
}
.lghs-transition--zoom .lghs-slide.is-active {
    transform: scale(1);
}

/* 5. Clip / Wipe */
.lghs-transition--clip .lghs-slide {
    transition: clip-path 0.9s cubic-bezier(0.77,0,0.18,1), opacity 0s;
    clip-path: inset(0 100% 0 0);
    opacity: 1;
}
.lghs-transition--clip .lghs-slide.is-active {
    clip-path: inset(0 0% 0 0);
    opacity: 1;
}
.lghs-transition--clip .lghs-slide.is-prev {
    clip-path: inset(0 0% 0 0);
    opacity: 1;
}

/* ── Flèches ──────────────────────────────────────── */
.lghs-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    border: 1.5px solid rgba(255,255,255,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, opacity 0.2s;
    color: #fff;
}

.lghs-arrow--prev { left: 24px; }
.lghs-arrow--next { right: 24px; }
.lghs-arrow:hover { background: rgba(255,255,255,0.22); border-color: rgba(255,255,255,0.5); }

.lghs-arrow svg { stroke: currentColor; }

/* ── Dots ─────────────────────────────────────────── */
.lghs-dots {
    position: absolute;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Ronds */
.lghs-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    border: 1.5px solid transparent;
    cursor: pointer;
    transition: background 0.25s, transform 0.25s, border-color 0.25s;
    padding: 0;
}
.lghs-dot.is-active {
    background: #F4A024;
    border-color: #F4A024;
    transform: scale(1.3);
}

/* Lignes */
.lghs-dot-line {
    width: 28px;
    height: 3px;
    border-radius: 2px;
    background: rgba(255,255,255,0.35);
    cursor: pointer;
    transition: background 0.25s, width 0.25s;
    padding: 0;
    border: none;
}
.lghs-dot-line.is-active {
    background: #F4A024;
    width: 44px;
}

/* Numéros */
.lghs-dot--num {
    font-size: 12px;
    font-weight: 700;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    border: 1.5px solid rgba(255,255,255,0.25);
    color: rgba(255,255,255,0.65);
    cursor: pointer;
    transition: all 0.25s;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lghs-dot--num.is-active {
    background: #F4A024;
    border-color: #F4A024;
    color: #0F2540;
}

/* Barre progress */
.lghs-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255,255,255,0.15);
}
.lghs-progress-fill {
    height: 100%;
    background: #F4A024;
    width: 0%;
    transition: width linear;
}

/* ── Responsive ───────────────────────────────────── */
@media (max-width: 768px) {
    .lghs-content { padding: 0 24px; }
    .lghs-arrow   { display: none; }
    .lghs-title   { font-size: clamp(1.6rem, 7vw, 2.5rem); }
}

@media (max-width: 480px) {
    .lghs-btns { flex-direction: column; align-items: flex-start; }
    .lghs-align--center .lghs-btns { align-items: center; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .lghs-slide, .lghs-anim, .lghs-bg, .lghs-progress-fill { transition: none !important; }
}
