/* ============ ML2M CREA — vitrine ============ */
:root {
    --ink: #0c0a0e;
    --ink2: #141117;
    --card: #17131b;
    --line: rgba(222, 196, 140, .22);
    --gold: #d9b878;
    --gold-l: #f1dfb4;
    --ivory: #f6efe2;
    --text: #e9e2d6;
    --muted: #a39a8c;
    --red: #e3867b;
    --gold-grad: linear-gradient(180deg, #fff6e2 0%, #f0d9a6 35%, #c9a15b 62%, #f3e2b8 82%, #b48c4c 100%);
    --gold-flat: linear-gradient(100deg, #b98c45 0%, #f1dbab 45%, #c79d55 70%, #edd49f 100%);
    --serif: "Cormorant Garamond", Georgia, serif;
    --caps: "Cinzel", Georgia, serif;
    --sans: "Montserrat", system-ui, sans-serif;
    --radius: 18px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
    margin: 0; background: var(--ink); color: var(--text);
    font-family: var(--sans); font-size: 16px; line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; }
a { color: var(--gold-l); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; color: var(--ivory); line-height: 1.1; margin: 0; }
.ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.eyebrow {
    font-family: var(--caps); font-size: 13px; letter-spacing: .3em; text-transform: uppercase;
    color: var(--gold); margin: 0 0 14px;
}

/* ---------- Boutons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    font-family: var(--caps); font-weight: 600; font-size: 13px; letter-spacing: .18em; text-transform: uppercase;
    color: #1b1206; text-decoration: none;
    background: var(--gold-flat); background-size: 200% 100%;
    border: 0; border-radius: 999px; padding: 16px 30px; cursor: pointer;
    box-shadow: 0 12px 30px rgba(217, 184, 120, .22);
    transition: background-position .5s, transform .15s;
}
.btn:hover { background-position: 100% 0; transform: translateY(-1px); }
.btn:focus-visible { outline: 2px solid var(--gold-l); outline-offset: 4px; }
.btn--ghost { color: var(--gold-l); background: transparent; border: 1px solid var(--gold); box-shadow: none; }
.btn--ghost:hover { background: rgba(217, 184, 120, .1); }
.btn--small { padding: 11px 20px; font-size: 11px; }
.btn--block { display: flex; width: 100%; margin-top: 10px; }

/* ---------- Barre du haut ---------- */
.nav {
    position: sticky; top: 0; z-index: 50;
    display: flex; align-items: center; justify-content: space-between; gap: 20px;
    padding: 14px 32px;
    background: rgba(12, 10, 14, .78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}
.nav__logo { display: flex; align-items: center; gap: 12px; text-decoration: none; font-family: var(--caps); font-size: 17px; letter-spacing: .14em; color: var(--ivory); }
.nav__logo i, .footer__logo i { font-family: var(--serif); font-style: italic; letter-spacing: 0; text-transform: none; font-size: 1.25em; color: var(--gold-l); }
.nav__mono {
    width: 38px; height: 38px; display: inline-grid; place-items: center; flex: none;
    font-family: var(--serif); font-weight: 600; font-size: 22px; color: var(--gold-l);
    border: 1px solid var(--gold); border-radius: 50%;
    box-shadow: inset 0 0 0 3px var(--ink), inset 0 0 0 4px rgba(217, 184, 120, .35);
}
.nav__menu { display: flex; align-items: center; gap: 28px; }
.nav__menu a:not(.btn) {
    font-family: var(--caps); font-size: 12px; letter-spacing: .2em; text-transform: uppercase;
    color: var(--muted); text-decoration: none; transition: color .2s;
}
.nav__menu a:not(.btn):hover { color: var(--gold-l); }

/* ---------- Accueil ---------- */
.hero { position: relative; overflow: hidden; padding: 80px 32px 90px; }
.hero__glow {
    position: absolute; inset: 0; pointer-events: none;
    background:
        radial-gradient(50% 60% at 80% 30%, rgba(217, 184, 120, .16), transparent 70%),
        radial-gradient(40% 50% at 10% 90%, rgba(150, 110, 200, .10), transparent 70%);
}
.hero__grid { position: relative; max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1.05fr .95fr; gap: 50px; align-items: center; }
.hero h1 { font-size: clamp(46px, 6.4vw, 84px); font-weight: 500; letter-spacing: -.01em; }
.hero h1 em { font-style: italic; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__lead { font-size: 18px; max-width: 540px; margin: 24px 0 32px; color: var(--text); }
.hero__lead b { color: var(--gold-l); font-weight: 500; }
.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__chips { list-style: none; padding: 0; margin: 34px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.hero__chips li {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px;
    border: 1px solid var(--line); border-radius: 999px; font-size: 14px; color: var(--muted);
}
.hero__chips .ico { color: var(--gold); width: 18px; height: 18px; }

/* Téléphones qui jouent les extraits */
.hero__phones { position: relative; height: 600px; }
.phone {
    position: absolute; width: 230px; aspect-ratio: 9 / 16;
    border-radius: 34px; padding: 9px;
    background: linear-gradient(160deg, #3a3240, #15111a);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .08), 0 40px 80px rgba(0, 0, 0, .6), 0 0 60px rgba(217, 184, 120, .12);
}
.phone video { width: 100%; height: 100%; object-fit: cover; border-radius: 26px; background: #000; }
.phone--0 { left: 0; top: 70px; transform: rotate(-7deg); }
.phone--1 { left: 50%; top: 0; transform: translateX(-50%); z-index: 2; width: 250px; }
.phone--2 { right: 0; top: 90px; transform: rotate(7deg); }

/* ---------- Sections ---------- */
.section { max-width: 1100px; margin: 0 auto; padding: 90px 32px; }
.section--wide { max-width: 1240px; }
.section__head { text-align: center; margin-bottom: 46px; }
.section h2 { font-size: clamp(36px, 4.6vw, 56px); font-weight: 500; }
.section__lead { max-width: 620px; margin: 14px auto 0; color: var(--muted); }

/* Services */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.service {
    position: relative; padding: 34px 30px; border-radius: var(--radius);
    background: linear-gradient(180deg, var(--card), var(--ink2)); border: 1px solid var(--line);
}
.service--star { border-color: rgba(217, 184, 120, .55); box-shadow: 0 0 50px rgba(217, 184, 120, .1); }
.service__ico {
    width: 52px; height: 52px; display: grid; place-items: center; margin-bottom: 18px;
    border-radius: 14px; color: var(--gold-l); background: rgba(217, 184, 120, .1); border: 1px solid var(--line);
}
.service__ico .ico { width: 26px; height: 26px; }
.service h3 { font-size: 30px; margin-bottom: 10px; }
.service p { margin: 0 0 18px; color: var(--muted); }
.service ul { list-style: none; padding: 0; margin: 0; }
.service li { display: flex; gap: 10px; padding: 5px 0; font-size: 15px; }
.service li .ico { color: var(--gold); width: 18px; height: 18px; margin-top: 3px; }

/* Réalisations */
.filters { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.filter {
    font: inherit; font-size: 14px; color: var(--muted); cursor: pointer;
    background: transparent; border: 1px solid var(--line); border-radius: 999px; padding: 9px 18px;
    transition: color .2s, border-color .2s, background .2s;
}
.filter:hover { color: var(--ivory); }
.filter.is-active { color: #1b1206; background: var(--gold-flat); border-color: transparent; font-weight: 600; }

.works { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; align-items: start; }
.work { border-radius: var(--radius); overflow: hidden; background: var(--card); border: 1px solid var(--line); transition: transform .25s, border-color .25s; }
.work:hover { transform: translateY(-4px); border-color: rgba(217, 184, 120, .5); }
.work[hidden] { display: none; }
.work--h { grid-column: span 2; }
.work__media {
    position: relative; display: block; width: 100%; padding: 0; border: 0; cursor: pointer;
    aspect-ratio: 9 / 13; background: #000; overflow: hidden;
}
.work--h .work__media { aspect-ratio: 16 / 9; }
.work__media video, .work__media img { width: 100%; height: 100%; object-fit: cover; }
.work__media video { object-position: center 30%; }
.work__play {
    position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
    width: 62px; height: 62px; display: grid; place-items: center; border-radius: 50%;
    color: #1b1206; background: rgba(241, 223, 180, .92); box-shadow: 0 10px 30px rgba(0, 0, 0, .4);
    transition: transform .2s, opacity .3s;
}
.work__play .ico { fill: currentColor; stroke: none; width: 24px; height: 24px; margin-left: 3px; }
.work.is-playing .work__play { opacity: 0; transform: translate(-50%, -50%) scale(.8); }
.work__media:hover .work__play, .work__media:focus-visible .work__play { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
.work__badge {
    position: absolute; top: 12px; left: 12px; padding: 4px 10px; border-radius: 999px;
    font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ivory); background: rgba(12, 10, 14, .7);
}
/* Sites : diaporama des trois écrans */
.slides { position: absolute; inset: 0; background: #000; }
/* chaque écran reste 3 s, quel que soit leur nombre (--n) */
.slides img { position: absolute; inset: 0; object-position: top; opacity: 0; animation: diapo3 calc(var(--n, 3) * 3s) infinite; animation-delay: calc(var(--i) * 3s); }
.slides[style*="--n: 3"] img { animation-name: diapo3; }
.slides[style*="--n: 6"] img { animation-name: diapo6; }
@keyframes diapo3 { 0%, 30% { opacity: 1; } 36%, 100% { opacity: 0; } }
@keyframes diapo6 { 0%, 15% { opacity: 1; } 18%, 100% { opacity: 0; } }
/* la visionneuse défile horizontalement quand il y a beaucoup d'écrans */
.viewer__content .galerie { overflow-x: auto; scroll-snap-type: x mandatory; justify-content: flex-start; max-width: 94vw; }
.viewer__content .galerie img { scroll-snap-align: center; flex: none; }
.work__body { padding: 20px 22px 24px; }
.work__sous { margin: 0 0 4px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); }
.work h3 { font-size: 30px; margin-bottom: 8px; }
.work__body p:last-child { margin: 0; color: var(--muted); font-size: 15px; }

/* Méthode */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: none; }
.steps li { padding: 28px 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--ink2); }
.steps b {
    display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 16px; border-radius: 50%;
    font-family: var(--serif); font-size: 24px; color: #1b1206; background: var(--gold-flat);
}
.steps h3 { font-size: 26px; margin-bottom: 8px; }
.steps p { margin: 0; color: var(--muted); font-size: 15px; }
.promise { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 30px; }
.promise p { margin: 0; padding: 18px 20px; border-left: 2px solid var(--gold); color: var(--muted); font-size: 15px; background: linear-gradient(90deg, rgba(217, 184, 120, .06), transparent); }
.promise b { color: var(--ivory); font-weight: 600; }

/* Contact */
.card { max-width: 760px; margin: 0 auto; padding: 40px; border-radius: var(--radius); background: linear-gradient(180deg, var(--card), var(--ink2)); border: 1px solid var(--line); }
.field { display: block; margin: 0 0 20px; padding: 0; border: 0; min-width: 0; }
.field > span, .field legend { display: block; margin-bottom: 6px; padding: 0; font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
input[type=text], input[type=email], input[type=tel], select, textarea {
    width: 100%; font: inherit; font-size: 16px; color: var(--ivory);
    background: rgba(255, 255, 255, .04); border: 1px solid rgba(217, 184, 120, .3); border-radius: 12px;
    padding: 13px 14px; transition: border-color .2s, background .2s;
}
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--gold) 50%), linear-gradient(135deg, var(--gold) 50%, transparent 50%); background-position: calc(100% - 20px) 55%, calc(100% - 14px) 55%; background-size: 6px 6px; background-repeat: no-repeat; }
select option { color: #111; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--gold-l); background: rgba(217, 184, 120, .07); }
.checks { display: flex; flex-wrap: wrap; gap: 10px; }
.check { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-size: 15px; }
.check input { accent-color: var(--gold); width: 17px; height: 17px; }
.check:has(input:checked) { border-color: var(--gold); background: rgba(217, 184, 120, .1); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.field__err { display: block; margin-top: 6px; font-size: 14px; color: var(--red); }
.field.is-invalid input, .field.is-invalid select { border-color: var(--red); }
.alert { max-width: 760px; margin: 0 auto 20px; padding: 14px 22px; border: 1px solid var(--red); border-radius: 12px; background: rgba(227, 134, 123, .08); }
.alert p { margin: 0 0 4px; } .alert b { color: var(--red); } .alert ul { margin: 0; padding-left: 20px; }
.merci { text-align: center; }
.merci h3 { font-size: 54px; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.merci p { color: var(--muted); margin: 10px 0 24px; }

/* Pied de page */
.footer { text-align: center; padding: 50px 24px 60px; border-top: 1px solid var(--line); color: var(--muted); }
.footer__logo { display: inline-flex; align-items: center; gap: 12px; margin: 0 0 12px; font-family: var(--caps); letter-spacing: .14em; color: var(--ivory); }
.footer__links { margin: 0 0 8px; }
.footer__links a { text-decoration: none; }
.footer__small { margin: 0; font-size: 13px; }

/* Visionneuse */
.viewer { padding: 0; border: 0; background: transparent; color: var(--ivory); max-width: min(94vw, 1100px); max-height: 94vh; overflow: visible; }
.viewer::backdrop { background: rgba(6, 5, 8, .9); backdrop-filter: blur(6px); }
.viewer__title { margin: 0 0 10px; font-family: var(--caps); font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-l); text-align: center; }
.viewer__content video { max-height: 82vh; width: auto; max-width: 100%; margin: 0 auto; border-radius: 14px; background: #000; }
.viewer__content .galerie { display: flex; gap: 14px; justify-content: center; }
.viewer__content .galerie img { height: min(78vh, 720px); width: auto; border-radius: 14px; border: 1px solid var(--line); }
.viewer__close {
    position: absolute; top: -6px; right: -6px; z-index: 1; width: 42px; height: 42px; border-radius: 50%;
    font-size: 18px; color: #1b1206; background: var(--gold-l); border: 0; cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .slides img:first-child { opacity: 1; }
    html { scroll-behavior: auto; }
}

/* ---------- Tablette / téléphone ---------- */
@media (max-width: 980px) {
    .hero__grid { grid-template-columns: 1fr; text-align: center; }
    .hero__lead { margin-left: auto; margin-right: auto; }
    .hero__cta, .hero__chips { justify-content: center; }
    .hero__phones { height: 470px; max-width: 520px; width: 100%; margin: 0 auto; }
    .phone { width: 180px; } .phone--1 { width: 200px; }
    .services, .steps, .promise { grid-template-columns: 1fr 1fr; }
    .works { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
    .nav { padding: 12px 16px; }
    .nav__menu a:not(.btn) { display: none; }
    .nav__logo span:last-child { font-size: 14px; }
    .hero { padding: 50px 16px 60px; }
    .hero__phones { height: 360px; }
    .phone { width: 140px; border-radius: 24px; padding: 6px; } .phone video { border-radius: 19px; }
    .phone--1 { width: 156px; }
    .section { padding: 64px 16px; }
    .services, .steps, .promise, .field-row { grid-template-columns: 1fr; }
    .field-row { gap: 0; }
    .works { grid-template-columns: 1fr; }
    .work--h { grid-column: auto; }
    .card { padding: 26px 18px; }
    .viewer__content .galerie { overflow-x: auto; justify-content: flex-start; scroll-snap-type: x mandatory; }
    .viewer__content .galerie img { height: 70vh; scroll-snap-align: center; }
}

@media (max-width: 640px) { .sm-cache { display: none; } .nav .btn--small { padding: 10px 18px; } }
.nav .btn--small { gap: 0; }

/* Téléphones de l'accueil : une offre par téléphone, avec son étiquette */
.phone { overflow: visible; }
.phone .slides { inset: 9px; border-radius: 26px; overflow: hidden; }
.phone__label {
    position: absolute; left: 50%; bottom: -18px; transform: translateX(-50%); z-index: 3;
    display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
    padding: 8px 14px; border-radius: 999px;
    font-family: var(--caps); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
    color: #1b1206; background: var(--gold-flat); box-shadow: 0 10px 24px rgba(0, 0, 0, .45);
}
.phone__label .ico { width: 15px; height: 15px; }
.phone--0 .phone__label, .phone--2 .phone__label { transform: translateX(-50%); }
@media (max-width: 640px) {
    .phone .slides { inset: 6px; border-radius: 19px; }
    .phone__label { font-size: 9px; padding: 6px 10px; gap: 5px; bottom: -14px; letter-spacing: .08em; }
    .phone__label .ico { width: 12px; height: 12px; }
}

/* Cartes d'une même rangée : même hauteur (le clip paysage s'étire à la hauteur de ses voisines) */
.works { align-items: stretch; }
.work { display: flex; flex-direction: column; }
.work__body { flex: 1 1 auto; }
.work--h .work__media { aspect-ratio: auto; flex: 1 1 auto; min-height: 300px; }
.work--h .work__body { flex: none; }
.work--h .work__media video { object-position: center 35%; }
@media (max-width: 980px) {
    .work--h .work__media { aspect-ratio: 16 / 9; flex: none; min-height: 0; }
}
.works { grid-auto-flow: row dense; } /* comble les trous (tablette) */

/* Type d'événement : pastilles à choix unique (remplace la liste déroulante) */
.check--radio input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.check--radio { position: relative; padding: 10px 18px; transition: border-color .2s, background .2s, color .2s; }
.check--radio:hover { border-color: rgba(217, 184, 120, .55); }
.check--radio:has(input:checked) { color: #1b1206; background: var(--gold-flat); border-color: transparent; font-weight: 600; }
.check--radio:has(input:focus-visible) { outline: 2px solid var(--gold-l); outline-offset: 3px; }
.field.is-invalid .check { border-color: rgba(227, 134, 123, .6); }

/* Bouton WhatsApp flottant */
.wa-float {
    position: fixed; right: 20px; bottom: 20px; z-index: 60;
    display: inline-flex; align-items: center; gap: 10px;
    padding: 12px 18px 12px 14px; border-radius: 999px;
    font-weight: 600; font-size: 15px; color: #fff; text-decoration: none;
    background: #25d366; box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
    transition: transform .2s, box-shadow .2s;
}
.wa-float:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(37, 211, 102, .35); }
.wa-float svg { width: 26px; height: 26px; }
@media (max-width: 640px) {
    .wa-float { right: 14px; bottom: 14px; padding: 13px; }
    .wa-float span { display: none; }
}

/* ---------- Galerie en rangées centrées (remplace la grille) ----------
   3 Save the Date / clip de Lior en pleine largeur / Noah + Noam centrés / 3 sites */
.works { display: flex; flex-wrap: wrap; justify-content: center; gap: 26px; }
.work { width: calc((100% - 52px) / 3); }
.work--h { width: 100%; grid-column: auto; }
.work--h .work__media { aspect-ratio: 21 / 9; flex: none; min-height: 0; }
.work--h .work__media video { object-position: center 40%; }
@media (max-width: 980px) {
    .work { width: calc((100% - 26px) / 2); }
    .work--h { width: 100%; }
    .work--h .work__media { aspect-ratio: 16 / 9; }
}
@media (max-width: 640px) {
    .work, .work--h { width: 100%; }
}
/* Les sites commencent toujours une nouvelle rangée (sans espace en plus) */
.works__break { flex-basis: 100%; height: 0; margin-top: -26px; }

/* Nom de marque « ML2M CREA » : CREA en capitales dorées (remplace « Création » manuscrit) */
.nav__logo i, .footer__logo i {
    font-family: var(--caps); font-style: normal; font-size: 1em; letter-spacing: .14em; margin-left: .3em;
    background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
/* Logo et bouton du haut toujours sur une ligne ; menu texte masqué dès la tablette */
.nav__logo span:last-child, .nav .btn { white-space: nowrap; }
@media (max-width: 980px) { .nav__menu a:not(.btn) { display: none; } }
/* Diaporama à 4 écrans (ouverture, accueil, programme, formulaire) */
.slides[style*="--n: 4"] img { animation-name: diapo4; }
@keyframes diapo4 { 0%, 22% { opacity: 1; } 26%, 100% { opacity: 0; } }

/* Visionneuse des sites : tous les écrans côte à côte, sans barre de défilement (ordinateur / tablette) */
@media (min-width: 641px) {
    .viewer:has(.galerie) { width: min(96vw, 1240px); }
    .viewer__content .galerie {
        display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); gap: 14px;
        overflow: visible; max-width: none;
        /* la hauteur des écrans (format 780x1688) ne dépasse pas 80 % de la fenêtre */
        width: min(100%, calc(80vh * 780 / 1688 * var(--n, 4) + 14px * (var(--n, 4) - 1)));
        margin: 0 auto;
    }
    .viewer__content .galerie img { width: 100%; height: auto; max-height: none; }
}
