/* ═══════════════════════════════════════════════════════════
   Carte de mariage immersive — Sarah & Yonatan
   Film hybride (auto + scroll) · texte libre sur l'image
   Ivoire + or · Cormorant Garamond + Jost
   ═══════════════════════════════════════════════════════════ */
:root {
  --bg: #faf6ee;
  --paper: #fffdf8;
  --ink: #3a2f22;
  --muted: #8b7b61;
  --gold: #b08a3e;
  --gold-clair: #d9b26b;
  --ivoire-lum: #fdf8ec;
  --ombre-txt: 0 1px 6px rgba(30, 22, 12, 0.55), 0 3px 22px rgba(30, 22, 12, 0.45);
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Jost", system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: var(--sans); cursor: pointer; }

.kicker {
  font-size: 0.78rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold);
  text-align: center;
}
.section-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2rem, 5vw, 3rem);
  text-align: center;
  margin: 0.4rem 0 1.2rem;
}

/* ─────────── NAV ─────────── */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.4rem;
  color: var(--ivoire-lum);
  background: linear-gradient(rgba(30, 24, 16, 0.45), transparent);
  transition: background 0.4s, color 0.4s, box-shadow 0.4s;
}
.nav--solid {
  color: var(--ink);
  background: rgba(250, 246, 238, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(58, 47, 34, 0.08);
}
.nav__logo { font-family: var(--serif); font-size: 1.5rem; letter-spacing: 0.12em; }
.nav__logo span { color: var(--gold-clair); }
.nav--solid .nav__logo span { color: var(--gold); }
.nav__links { display: flex; gap: 1.3rem; font-size: 0.82rem; letter-spacing: 0.1em; }
.nav__links a { opacity: 0.9; transition: color 0.25s, opacity 0.25s; }
.nav__links a:hover { opacity: 1; color: var(--gold-clair); }
.nav--solid .nav__links a:hover { color: var(--gold); }

/* ─────────── MUSIQUE ─────────── */
.mute {
  position: fixed;
  right: 0.9rem;
  bottom: 0.9rem;
  z-index: 55;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 50%;
  border: 1px solid rgba(217, 178, 107, 0.55);
  background: rgba(24, 20, 14, 0.5);
  color: var(--gold-clair);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: 1.05rem;
  line-height: 1;
  transition: opacity 0.3s;
}
.mute.is-off { color: #9b8d74; text-decoration: line-through; }

/* ─────────── FILM ─────────── */
.film { height: 900vh; position: relative; }
.film__sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: #efe7d6;
}
.film__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.03);
}
@media (min-aspect-ratio: 4/5) {
  .film__video {
    object-fit: contain;
    transform: none;
    filter: drop-shadow(0 20px 60px rgba(58, 47, 34, 0.28));
  }
}

/* ─────────── ÉCRAN D'OUVERTURE ─────────── */
.landing {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  text-align: center;
  padding: 1.2rem;
  color: var(--ivoire-lum);
  background: radial-gradient(ellipse at center, rgba(20, 16, 10, 0.06), rgba(20, 16, 10, 0.44));
  transition: opacity 0.9s ease;
}
.landing.is-off { opacity: 0; pointer-events: none; }
.landing__bsd { font-size: 0.9rem; letter-spacing: 0.2em; opacity: 0.9; text-shadow: var(--ombre-txt); }
.landing__kicker {
  font-size: 0.82rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  max-width: 30ch;
  text-shadow: var(--ombre-txt);
}
.landing__names {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.7rem, 10vw, 5rem);
  line-height: 1.08;
  color: #fffdf8;
  text-shadow: var(--ombre-txt);
}
.landing__names span { color: var(--gold-clair); font-style: italic; }
.landing__date {
  letter-spacing: 0.26em;
  text-transform: uppercase;
  font-size: 0.82rem;
  text-shadow: var(--ombre-txt);
}
.landing__btn {
  margin-top: 1.2rem;
  font-size: 0.88rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #2e2416;
  background: linear-gradient(120deg, #e8c886, var(--gold-clair));
  border: none;
  border-radius: 999px;
  padding: 1rem 2.2rem;
  box-shadow: 0 10px 34px rgba(30, 22, 12, 0.4);
  transition: transform 0.25s, box-shadow 0.25s;
  animation: btnPulse 2.6s infinite;
}
.landing__btn:hover { transform: translateY(-2px); }
@keyframes btnPulse {
  0%, 100% { box-shadow: 0 10px 34px rgba(30, 22, 12, 0.4), 0 0 0 0 rgba(217, 178, 107, 0.5); }
  50%      { box-shadow: 0 10px 34px rgba(30, 22, 12, 0.4), 0 0 0 14px rgba(217, 178, 107, 0); }
}
.landing__hint {
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.75;
  text-shadow: var(--ombre-txt);
}

.countdown { display: flex; gap: 0.6rem; margin-top: 0.9rem; }
.countdown__cell {
  min-width: 4.2rem;
  padding: 0.55rem 0.4rem 0.45rem;
  border: 1px solid rgba(217, 178, 107, 0.45);
  border-radius: 10px;
  background: rgba(24, 20, 14, 0.42);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.countdown__cell b {
  display: block;
  font-family: var(--serif);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--gold-clair);
  line-height: 1.1;
}
.countdown__cell i {
  font-style: normal;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #d8cbae;
}

/* ─────────── TEXTE LIBRE SUR L'IMAGE (sans cadre) ─────────── */
.fiche {
  position: absolute;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  width: min(90vw, 560px);
  text-align: center;
  color: var(--ivoire-lum);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.7s ease, transform 0.7s ease, visibility 0.7s;
  z-index: 5;
  pointer-events: none;
}
.fiche.is-on { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
/* positions selon le plan */
.fiche--top { top: max(4.6rem, calc(env(safe-area-inset-top) + 3.6rem)); bottom: auto; }
.fiche--mid { top: 50%; bottom: auto; transform: translate(-50%, calc(-50% + 16px)); }
.fiche--mid.is-on { transform: translate(-50%, -50%); }
.fiche--low { bottom: max(4.2rem, calc(env(safe-area-inset-bottom) + 3.4rem)); top: auto; }

.fiche__index {
  font-size: 0.68rem;
  letter-spacing: 0.34em;
  color: var(--gold-clair);
  text-transform: uppercase;
  margin-bottom: 0.3rem;
  text-shadow: var(--ombre-txt);
}
.fiche__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.7rem, 6.4vw, 2.6rem);
  line-height: 1.18;
  color: #fffdf8;
  text-shadow: var(--ombre-txt);
}
.fiche__desc {
  font-size: 0.95rem;
  margin-top: 0.4rem;
  text-shadow: var(--ombre-txt);
}
.fiche__desc b { color: var(--gold-clair); font-weight: 500; }
.fiche__desc .heb { display: block; font-family: var(--serif); font-size: 1.25rem; margin-top: 0.2rem; color: var(--gold-clair); }

/* ─────────── PROGRESSION ─────────── */
.dots {
  position: absolute;
  right: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  z-index: 5;
}
.dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.4);
  box-shadow: 0 0 6px rgba(30, 22, 12, 0.4);
  transition: background 0.3s, transform 0.3s;
}
.dots i.on { background: var(--gold-clair); transform: scale(1.45); }

/* ─────────── FIN DE LECTURE ─────────── */
.suite {
  position: absolute;
  left: 50%;
  bottom: max(3.2rem, calc(env(safe-area-inset-bottom) + 2.4rem));
  transform: translateX(-50%);
  display: flex;
  gap: 0.8rem;
  z-index: 12;
  opacity: 0;
  transition: opacity 0.8s ease;
}
.suite.is-on { opacity: 1; }
.suite[hidden] { display: none; }
.suite__btn {
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ivoire-lum);
  background: rgba(24, 20, 14, 0.55);
  border: 1px solid rgba(217, 178, 107, 0.5);
  border-radius: 999px;
  padding: 0.75rem 1.5rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.suite__btn--gold {
  color: #2e2416;
  background: linear-gradient(120deg, #e8c886, var(--gold-clair));
  border: none;
}

/* ─────────── DÉTAILS (invitation écrite, aérée, sans cadre) ─────────── */
.details {
  padding: 5.5rem 1.4rem 4.5rem;
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}
.details__bsd { font-size: 0.78rem; letter-spacing: 0.2em; color: var(--gold); }
.details__passouk {
  font-family: var(--serif);
  font-size: 1.25rem;
  color: var(--gold);
  margin: 0.6rem 0 1.6rem;
}
.details__familles {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.9rem;
  align-items: center;
  font-size: 0.88rem;
  line-height: 1.85;
  color: #5d4e38;
  margin-bottom: 1.2rem;
}
.details__mono {
  font-family: var(--serif);
  font-size: 1.2rem;
  color: var(--gold);
  border: 1px solid rgba(176, 138, 62, 0.4);
  border-radius: 50%;
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.details__thanks { font-size: 0.92rem; color: #5d4e38; max-width: 44ch; margin: 0 auto 0.5rem; }
.details__names {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.3rem, 8vw, 3.2rem);
  line-height: 1.12;
  margin: 0.4rem 0;
}
.details__names span { color: var(--gold); font-style: italic; }
.details__invite { font-size: 0.92rem; color: #5d4e38; }
.details__date {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 500;
  margin-top: 0.5rem;
  line-height: 1.35;
}
.details__date span { font-size: 1.15rem; color: var(--gold); }
.details__sep { color: var(--gold-clair); font-size: 0.75rem; margin: 1rem 0; }
.details__ligne { font-size: 1rem; }
.details__ligne b { color: var(--gold); font-weight: 500; }
.details__lieu {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 500;
  margin-top: 0.4rem;
}
.details__pensee {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1rem;
  color: #7a6a4e;
  max-width: 40ch;
  margin: 0 auto;
}
.details__tenue { font-size: 0.84rem; color: #7a6a4e; margin-top: 0.5rem; }

/* ─────────── RSVP ─────────── */
.rsvp { padding: 4.5rem 1.4rem 5rem; max-width: 620px; margin: 0 auto; }
.rsvp__deadline { text-align: center; color: var(--muted); margin-bottom: 2rem; }
.rsvp__deadline b { color: var(--gold); font-weight: 500; }
.rsvp__form { display: flex; flex-direction: column; gap: 1.1rem; }
.rsvp__form label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.rsvp__form input, .rsvp__form select, .rsvp__form textarea {
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid rgba(58, 47, 34, 0.16);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.rsvp__form input:focus, .rsvp__form select:focus, .rsvp__form textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(176, 138, 62, 0.15);
}
.rsvp__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.rsvp__btn {
  margin-top: 0.4rem;
  font-size: 0.9rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fffdf8;
  background: linear-gradient(120deg, #c69c4e, var(--gold));
  border: none;
  border-radius: 999px;
  padding: 0.95rem;
  transition: transform 0.2s, box-shadow 0.2s;
}
.rsvp__btn:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(176, 138, 62, 0.35); }
.rsvp__btn:disabled { opacity: 0.6; cursor: default; transform: none; box-shadow: none; }
.rsvp__ok { text-align: center; color: var(--gold); }

/* ─────────── MOBILE ─────────── */
@media (max-width: 600px) {
  .nav { padding: 0.8rem 1rem; }
  .nav__links { gap: 0.9rem; font-size: 0.72rem; }
  .countdown__cell { min-width: 3.4rem; }
  .countdown__cell b { font-size: 1.35rem; }
  .fiche__desc { font-size: 0.86rem; }
  .details__familles { font-size: 0.76rem; }
  .rsvp__row { grid-template-columns: 1fr; }
}

/* ─────────── ACCESSIBILITÉ ─────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .landing__btn { animation: none; }
  .fiche { transition: opacity 0.2s; }
}
