/* =========================================================================
   Mariage Chanaëlle & Karl — feuille de style
   Palette, typographies et composants reproduisant le thème Odoo d'origine.
   ========================================================================= */

:root {
  --gold:        #d2c167;
  --gold-deep:   #8f7f2a;
  --gold-bright: #ffde45;
  --peach:       #f0cda8;
  --cream:       #f6f5f4;
  --white:       #ffffff;
  --plum:        #1b1319;
  --ink:         #212529;
  --ink-soft:    rgba(33, 37, 41, 0.55);

  --font-script: "Parisienne", cursive;
  --font-serif:  "Tinos", "Times New Roman", serif;
  --font-sans:   "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-he:     "Frank Ruhl Libre", "Times New Roman", serif;

  --maxw: 760px;
  --radius: 22px;
  --shadow-soft: 0 10px 40px rgba(27, 19, 25, 0.12);
}

/* --------------------------------- base --------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

p { margin: 0 0 .4em; }

a { color: var(--gold-deep); }

sup { font-size: .6em; }

/* gradient doré pour les titres (identique au thème Odoo) */
.gold-text {
  background-image: radial-gradient(circle at 55% 55%, var(--gold-bright) 0%, #452100 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.amp { font-style: italic; }

/* ----------------------------- reveal anim ----------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .9s ease, transform .9s ease;
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* =============================== HERO =============================== */
.hero {
  position: relative;
  min-height: 100vh;   /* fallback */
  min-height: 100svh;  /* stable sur mobile (pas de saut de barre d'adresse) */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}
.hero__bg {
  position: absolute;
  inset: -15% 0;
  background: url("assets/img/hero-bg.jpg") center 75% / cover no-repeat;
  z-index: 0;
}
.hero__overlay {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.15);
  z-index: 1;
}
.hero__content {
  position: relative;
  z-index: 2;
  padding: 1.5rem;
  width: 100%;
}
.hero__monogram {
  width: clamp(120px, 22vw, 180px);
  height: auto;
  margin: 0 auto .25rem;
  filter: drop-shadow(0 4px 14px rgba(0,0,0,.25));
}
.hero__title {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(2.2rem, 11vw, 5.5rem);
  line-height: 1.05;
  margin: 0 0 1.6rem;
  white-space: nowrap;   /* « Chanaëlle & Karl » sur une seule ligne */
}
.hero__wave {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  z-index: 2;
  line-height: 0;
}
.hero__wave svg { width: 100%; height: clamp(60px, 9vw, 120px); display: block; }

/* Bouton "Invitation" — bordure dorée animée (repris du SCSS Odoo) */
.btn-invitation {
  position: relative;
  display: inline-block;
  padding: 14px 44px;
  border-radius: 10px;
  font-family: var(--font-script);
  font-size: 1.7rem;
  line-height: 1;
  color: #7a5500;
  text-decoration: none;
  background: #fff;
  overflow: hidden;
  z-index: 0;
  box-shadow: 0 8px 26px rgba(0,0,0,.18);
  transition: color .2s;
}
.btn-invitation::after {
  content: "";
  position: absolute; inset: 3px;
  border-radius: 7px;
  background: #fff;
  z-index: -1;
  transition: background .2s;
}
.btn-invitation::before {
  content: "";
  position: absolute;
  width: 250%; height: 250%;
  top: -75%; left: -75%;
  background: conic-gradient(
    #b8860b 0deg, #ffd700 60deg, #fffacd 100deg, #ffd700 140deg,
    #b8860b 200deg, #8b6914 260deg, #b8860b 360deg);
  z-index: -2;
  animation: rotateBorder 7s linear infinite;
}
.btn-invitation:hover { color: #5a3c00; }
.btn-invitation:hover::after { background: #fffdf0; }
.btn-invitation:hover::before { animation-duration: 2.5s; }

@keyframes rotateBorder { from { transform: rotate(0); } to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .btn-invitation::before { animation: none; }
}

/* =============================== FAIRE-PART =============================== */
.fairepart {
  position: relative;
  padding: clamp(3rem, 9vw, 6rem) 1rem;
  overflow: hidden;
  display: flex;
  justify-content: center;
}
.fairepart__bg {
  position: absolute; inset: -15% 0;
  background: url("assets/img/fairepart-bg.jpg") 57% 50% / cover no-repeat;
  z-index: 0;
}
.fairepart__veil {
  position: absolute; inset: 0;
  background: rgba(255, 255, 255, 0.78);
  z-index: 1;
}
.fairepart__card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--maxw);
  background: rgba(255, 255, 255, 0.72);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 5vw, 3rem);
  box-shadow: var(--shadow-soft);
  text-align: center;
}
.fairepart__bsd {
  text-align: right;
  color: var(--gold);
  font-family: var(--font-he);
  font-size: 1rem;
  margin-bottom: .5rem;
}
.fairepart__monogram {
  width: clamp(200px, 60%, 360px);
  margin: 0 auto 1.5rem;
}
.fairepart__families {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  font-family: var(--font-script);
  font-size: clamp(.8rem, 3vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink);
  margin-bottom: 1.6rem;
}
.fam { display: flex; flex-direction: column; }
.fam--left { text-align: left; flex: 0 0 auto; }
.fam--left span { white-space: nowrap; }   /* chaque famille sur une seule ligne */
.fam--right { text-align: right; align-self: flex-start; flex: 1 1 auto; }
.fairepart__intro {
  font-family: var(--font-script);
  font-size: clamp(1.2rem, 4.7vw, 1.85rem);
  line-height: 1.3;
  color: var(--ink);
  margin: 0 auto 1.4rem;
  max-width: 34ch;
}
.fairepart__names {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(1.7rem, 8.3vw, 3.4rem);
  margin: .2rem 0;
  line-height: 1.05;
  white-space: nowrap;   /* « Chanaëlle & Karl » sur une seule ligne */
}
.fairepart__names-he {
  font-family: var(--font-he);
  font-weight: 500;
  font-size: clamp(1.45rem, 6.2vw, 2.4rem);
  color: var(--ink);
  margin: .2rem 0 1.2rem;
  white-space: nowrap;
}
.amp-he { color: var(--gold-deep); }
.fairepart__convient {
  font-family: var(--font-script);
  font-size: clamp(1.15rem, 4.3vw, 1.7rem);
  color: var(--ink);
  margin: 0;
}

/* =============================== TABS =============================== */
.tabs { background: var(--white); }
.tabs__nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  background: var(--white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}
.tabs__tab {
  flex: 1;
  appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-family: var(--font-script);
  font-size: clamp(1.8rem, 7vw, 2.6rem);
  line-height: 1;
  padding: .7em .2em .55em;
  color: var(--gold);
  position: relative;
  transition: color .25s;
}
.tabs__tab.is-active { color: var(--ink); }
.tabs__tab.is-active::after {
  content: "";
  position: absolute;
  left: 18%; right: 18%; bottom: 8px;
  height: 3px;
  border-radius: 3px;
  background: var(--ink);
}
.tabs__pane {
  padding: clamp(2rem, 7vw, 3.5rem) 1rem;
  max-width: var(--maxw);
  margin: 0 auto;
  text-align: center;
}
.tabs__pane[hidden] { display: none; }

/* --------------------------- countdown --------------------------- */
.countdown {
  display: flex;
  justify-content: center;
  gap: clamp(1.6rem, 9vw, 3.4rem);
  margin-bottom: 2.4rem;
}
.countdown__item { display: flex; flex-direction: column; align-items: center; }
.countdown__num {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(1.7rem, 6vw, 2.2rem);
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}
.countdown__label {
  font-family: var(--font-sans);
  font-size: .7rem;
  letter-spacing: .06em;
  color: var(--ink-soft);
  text-transform: none;
}

/* --------------------------- mairie --------------------------- */
.mairie__photo { border-radius: 14px; margin: 0 auto 2rem; box-shadow: var(--shadow-soft); }
.mairie__names {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(2rem, 9.5vw, 3.8rem);
  margin: .3rem 0 1rem;
  white-space: nowrap;
}
.mairie__oui {
  font-family: var(--font-script);
  font-size: clamp(2rem, 8vw, 3rem);
  color: var(--ink);
  margin: 0 0 1.6rem;
}
.scribble { position: relative; display: inline-block; color: var(--ink); padding: 0 .15em; }
.scribble svg {
  position: absolute;
  left: 0; right: 0; bottom: -.18em;
  width: 100%; height: .5em;
  color: var(--gold);
  overflow: visible;
}
.mairie__where {
  font-family: var(--font-script);
  font-size: clamp(1.7rem, 6.5vw, 2.3rem);
  color: var(--ink);
  margin: 0;
}
.mairie__addr {
  font-family: var(--font-script);
  font-size: clamp(1.3rem, 5vw, 1.8rem);
  color: var(--ink);
  margin: 0 0 1.6rem;
}
.mairie__date {
  font-family: var(--font-script);
  font-size: clamp(1.9rem, 7vw, 2.6rem);
  color: var(--ink);
  margin: 0;
}
.mairie__time {
  font-family: var(--font-script);
  font-size: clamp(1.7rem, 6.5vw, 2.3rem);
  color: var(--ink);
  margin: 0 0 1.8rem;
}
.mairie__precise { font-size: .55em; display: inline-block; }
.mairie__decor { width: clamp(160px, 45%, 260px); margin: 1.6rem auto; border-radius: 14px; }

.tab__refrain {
  font-family: var(--font-script);
  font-size: clamp(1.5rem, 6vw, 2.1rem);
  color: var(--ink);
  margin-top: 1.4rem;
}

/* --------------------------- itinéraire btn --------------------------- */
.btn-route {
  display: inline-block;
  font-family: var(--font-script);
  font-size: 1.5rem;
  line-height: 1;
  padding: 10px 30px;
  color: var(--gold-deep);
  background: #fff;
  border: 1px solid var(--gold);
  border-radius: 8px;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(0,0,0,.12);
  transition: transform .2s, box-shadow .2s, background .2s;
}
.btn-route:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.18); background: #fffdf3; }

/* =============================== PROGRAMME (cards) =============================== */
.programme__title {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(2.2rem, 9vw, 3.4rem);
  margin: 0 0 1.6rem;
}
.cards {
  display: flex;
  flex-direction: column;
  gap: 2.2rem;
  margin: 0 auto 2.5rem;
}
.card {
  position: sticky;
  min-height: 74vh;
  min-height: 74svh;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  overflow: hidden;
  color: #fff;
  text-align: center;
  background-size: cover;
  background-position: center;
  box-shadow: 0 18px 50px rgba(27,19,25,.28);
}
.card--cocktail { background-image: url("assets/img/card-cocktail.webp"); top: 3.5rem; }
.card--houppa   { background-image: url("assets/img/card-houppa.webp");   top: 4.5rem; }
.card--salle    { background-image: url("assets/img/card-salle.webp");    top: 5.5rem; }
.card__video {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
.card__overlay { position: absolute; inset: 0; background: rgba(0,0,0,.34); z-index: 1; }
.card__body { position: relative; z-index: 1; padding: 2rem 1.4rem; }
.card__kicker {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(2rem, 8vw, 3rem);
  margin: 0 0 .4rem;
  text-shadow: 0 2px 12px rgba(0,0,0,.4);
}
.card__big {
  font-family: var(--font-script);
  font-size: clamp(2.4rem, 10vw, 3.6rem);
  line-height: 1.1;
  margin: 0 0 .6rem;
  text-shadow: 0 2px 12px rgba(0,0,0,.45);
}
.card__huge {
  font-family: var(--font-script);
  font-size: clamp(3.2rem, 15vw, 5.5rem);
  line-height: 1;
  margin: 0 0 .4rem;
  text-shadow: 0 2px 14px rgba(0,0,0,.45);
}
.card__time {
  font-family: var(--font-script);
  font-weight: 700;
  font-size: clamp(2.6rem, 11vw, 4rem);
  margin: 0;
  text-shadow: 0 2px 12px rgba(0,0,0,.5);
}
.card__place-sub {
  font-family: var(--font-script);
  font-size: clamp(1.8rem, 7vw, 2.6rem);
  margin: 0 0 .2rem;
  text-shadow: 0 2px 12px rgba(0,0,0,.5);
}
.card__place {
  font-family: var(--font-script);
  font-size: clamp(2.6rem, 11vw, 4rem);
  line-height: 1.05;
  margin: 0 0 1.4rem;
  text-shadow: 0 2px 14px rgba(0,0,0,.5);
}
.card--salle .btn-route { font-size: 1.7rem; }

/* =============================== MAP =============================== */
.map {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 11;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  background: var(--cream);
}
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; }

/* =============================== RSVP =============================== */
.rsvp {
  background:
    linear-gradient(rgba(246,245,244,.93), rgba(246,245,244,.93)),
    url("assets/img/fairepart-bg.jpg") center / cover no-repeat;
  padding: clamp(3rem, 9vw, 5.5rem) 1rem;
  text-align: center;
}
.section-title {
  font-family: var(--font-script);
  font-weight: 400;
  font-size: clamp(2.4rem, 10vw, 3.6rem);
  margin: 0 0 .4rem;
}
.rsvp__refrain {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--ink-soft);
  margin: 0 auto 2.2rem;
  max-width: 36ch;
}
.rsvp__form {
  max-width: 460px;
  margin: 0 auto;
  text-align: left;
  background: #fff;
  border-radius: var(--radius);
  padding: clamp(1.5rem, 5vw, 2.4rem);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(210,193,103,.35);
}
.field { margin-bottom: 1.3rem; }
.field > label, .rsvp__presence legend {
  display: block;
  font-weight: 600;
  font-size: .95rem;
  color: var(--ink);
  margin-bottom: .5rem;
}
.req { color: var(--gold-deep); }
.rsvp__form input[type="text"],
.rsvp__form input[type="number"],
.rsvp__form textarea {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--ink);
  padding: .8rem .9rem;
  border: 1px solid #d9d6ce;
  border-radius: 12px;
  background: #fdfdfc;
  transition: border-color .2s, box-shadow .2s;
}
.rsvp__form input[type="text"]:focus,
.rsvp__form input[type="number"]:focus,
.rsvp__form textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(210,193,103,.25);
}
.rsvp__form textarea { resize: vertical; }
.rsvp__presence, .rsvp__events { border: 0; margin: 0 0 1.3rem; padding: 0; }
.rsvp__ifpresent[hidden] { display: none; }
.choices { display: flex; flex-direction: column; gap: .7rem; }
.choices--check { flex-direction: row; flex-wrap: wrap; }
.choices--check .choice { flex: 1 1 130px; }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice__box {
  display: block;
  padding: .8rem 1rem;
  border: 1px solid #d9d6ce;
  border-radius: 12px;
  background: #fdfdfc;
  font-size: 1rem;
  text-align: center;
  transition: border-color .2s, background .2s, color .2s;
}
.choice input:focus-visible + .choice__box { box-shadow: 0 0 0 3px rgba(210,193,103,.25); }
.choice input:checked + .choice__box {
  border-color: var(--gold);
  background: linear-gradient(180deg, #fffdf3, #fbf4dd);
  color: var(--gold-deep);
  font-weight: 600;
}
.btn-send {
  display: block;
  width: 100%;
  appearance: none;
  border: 0;
  cursor: pointer;
  font-family: var(--font-script);
  font-size: 1.7rem;
  line-height: 1;
  color: #5a3c00;
  padding: .7em 1em;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold) 55%, var(--gold-deep));
  box-shadow: 0 10px 26px rgba(143,127,42,.35);
  transition: transform .15s, box-shadow .2s, filter .2s;
}
.btn-send:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(143,127,42,.45); }
.btn-send:disabled { filter: grayscale(.4) opacity(.7); cursor: progress; transform: none; }
.rsvp__status { margin: 1rem 0 0; font-size: .95rem; text-align: center; min-height: 1.2em; }
.rsvp__status.is-ok { color: #2c7a4b; font-weight: 600; }
.rsvp__status.is-err { color: #b3261e; font-weight: 600; }

/* =============================== GALERIE =============================== */
.gallery { padding: clamp(2.5rem, 8vw, 4.5rem) 1rem; }
.gallery__scatter {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  height: clamp(380px, 95vw, 560px);
}
.photo {
  position: absolute;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(27,19,25,.22);
  object-fit: cover;
  border: 5px solid #fff;
}
.photo--1 { width: 42%; aspect-ratio: 4/3;  top: 2%;  left: 3%;  transform: rotate(-7deg); z-index: 2; }
.photo--2 { width: 40%; aspect-ratio: 3/4;  top: 30%; left: 30%; transform: rotate(4deg);  z-index: 4; }
.photo--3 { width: 46%; aspect-ratio: 4/3;  top: 46%; left: 6%;  transform: rotate(6deg);  z-index: 3; }
.photo--4 { width: 40%; aspect-ratio: 3/4;  top: 8%;  right: 3%; transform: rotate(9deg);  z-index: 1; }

/* =============================== HOMMAGE =============================== */
.hommage { padding: clamp(2rem, 6vw, 3.5rem) 1rem 1rem; text-align: center; }
.hommage__intro {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--ink);
  margin-bottom: 1rem;
}
.hommage__names {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem;
  line-height: 1.9;
  color: var(--ink);
}

/* =============================== FOOTER =============================== */
.site-footer {
  padding: 2.5rem 1rem 3rem;
  text-align: center;
  font-size: .9rem;
  color: var(--ink-soft);
}
.site-footer a { color: var(--gold); text-decoration: none; font-weight: 600; }
.site-footer a:hover { text-decoration: underline; }

/* =============================== MUSIC TOGGLE =============================== */
.music-toggle {
  position: fixed;
  right: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 80;
  width: 50px; height: 50px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold-deep));
  box-shadow: 0 8px 22px rgba(0,0,0,.28);
  display: grid;
  place-items: center;
  transition: transform .2s;
}
.music-toggle[hidden] { display: none; }
.music-toggle:hover { transform: scale(1.07); }
.music-toggle__icon {
  width: 20px; height: 20px;
  background: #fff;
  -webkit-mask: no-repeat center / contain;
  mask: no-repeat center / contain;
  -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 18V6l10-2v12' fill='none' stroke='black' stroke-width='2'/><circle cx='6' cy='18' r='3'/><circle cx='16' cy='16' r='3'/></svg>");
  mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 18V6l10-2v12' fill='none' stroke='black' stroke-width='2'/><circle cx='6' cy='18' r='3'/><circle cx='16' cy='16' r='3'/></svg>");
}
.music-toggle.is-muted { background: linear-gradient(135deg, #bbb, #777); }
.music-toggle.is-muted .music-toggle__icon { opacity: .85; }

/* =============================== DESKTOP =============================== */
@media (min-width: 768px) {
  .map { aspect-ratio: 21 / 9; }
  .card { min-height: 70vh; min-height: 70svh; }
  .gallery__scatter { height: 540px; }
  .photo--1 { width: 32%; left: 6%;  top: 6%; }
  .photo--2 { width: 30%; left: 36%; top: 26%; }
  .photo--3 { width: 34%; left: 14%; top: 48%; }
  .photo--4 { width: 30%; right: 6%; top: 12%; }
}

/* honeypot anti-bot : invisible et hors flux */
.hp {
  position: absolute !important;
  left: -9999px;
  width: 1px; height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* compte à rebours terminé */
.countdown__over {
  font-family: var(--font-script);
  font-size: clamp(1.7rem, 6vw, 2.3rem);
  color: var(--gold-deep);
  margin: 0;
}

/* feedback tactile + neutralisation du hover « collant » sur écran tactile */
.btn-invitation:active, .btn-route:active { transform: translateY(0); }
.btn-send:active { transform: translateY(0); filter: brightness(.95); }
@media (hover: none) {
  .btn-invitation:hover, .btn-route:hover, .btn-send:hover { transform: none; }
}
