/* Apéro — "Nuit lounge" demo. Plain CSS, mobile-first. */
:root {
  /* Night palette (scroll end) — values mixed by JS into --sky-* */
  --plum: #2a1230;
  --midnight: #0d0716;
  --ivory: #f4ecdf;
  --mist: #cdbfcf;
  --lantern: #f5b85c;
  --neon: #ff4f8b;
  --violet: #8d6bff;

  --sky-a: #4b2636;       /* updated live: top of sky */
  --sky-b: #1d1026;       /* updated live: bottom of sky */
  --glow: #f5b85c;        /* updated live: accent light */
  --glow-2: #ff4f8b;

  --serif: "Fraunces", "Times New Roman", serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(.22,.8,.2,1);
  --r-lg: 28px;
  --r-sm: 14px;
  --pad: clamp(20px, 5vw, 64px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font: 300 1.0625rem/1.65 var(--sans);
  color: var(--ivory);
  background: var(--midnight);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body::before { /* the sky: day → night */
  content: ""; position: fixed; inset: 0; z-index: -3;
  background: linear-gradient(170deg, var(--sky-a) 0%, var(--sky-b) 70%);
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; background: var(--ivory); color: var(--midnight); border-radius: 8px; }
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--lantern); outline-offset: 3px; border-radius: 6px; }
.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 var(--pad); }
.muted { color: var(--mist); font-size: .9em; }

.display {
  font-family: var(--serif);
  font-variation-settings: "SOFT" 60, "opsz" 144;
  font-weight: 350;
  font-size: clamp(2.6rem, 8vw, 6rem);
  line-height: .95;
  letter-spacing: -.02em;
}

/* ---------- Light orbs ---------- */
.orbs { position: fixed; inset: 0; z-index: -2; pointer-events: none; overflow: hidden; }
.orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; will-change: transform; }
.o1 { width: 46vmax; height: 46vmax; left: -14vmax; top: -10vmax; background: var(--glow); opacity: .28; animation: drift 26s ease-in-out infinite alternate; }
.o2 { width: 38vmax; height: 38vmax; right: -12vmax; top: 30vh; background: var(--glow-2); opacity: .22; animation: drift 32s ease-in-out infinite alternate-reverse; }
.o3 { width: 30vmax; height: 30vmax; left: 30vw; bottom: -14vmax; background: var(--violet); opacity: .2; animation: drift 38s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translate3d(6vw, -5vh, 0) scale(1.12); } }

/* ---------- Glass ---------- */
.glass {
  background: linear-gradient(145deg, rgba(255,255,255,.11), rgba(255,255,255,.03));
  border: 1px solid rgba(255,255,255,.14);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 30px 60px -30px rgba(0,0,0,.6);
}

/* ---------- Buttons (magnetic in JS) ---------- */
.btn {
  --mx: 0px; --my: 0px;
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: .8em 1.6em;
  font: 500 .98rem/1.1 var(--sans); letter-spacing: .01em; text-decoration: none;
  color: var(--midnight); background: var(--ivory);
  border: 1px solid var(--ivory); border-radius: 999px; cursor: pointer;
  transform: translate3d(var(--mx), var(--my), 0);
  transition: transform .45s var(--ease), background .3s, color .3s, box-shadow .3s;
}
.btn:hover { background: var(--glow); border-color: var(--glow); box-shadow: 0 0 40px -6px var(--glow); }
.btn-ghost { background: transparent; color: var(--ivory); border-color: rgba(244,236,223,.5); }
.btn-ghost:hover { color: var(--midnight); }
.btn-sm { min-height: 44px; padding: .6em 1.2em; font-size: .9rem; }
.btn-wa { width: 100%; background: var(--lantern); border-color: var(--lantern); }
.btn-wa:hover { background: var(--ivory); border-color: var(--ivory); box-shadow: 0 0 40px -6px var(--lantern); }

/* ---------- Header ---------- */
.top {
  position: fixed; inset: 0 0 auto 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--pad);
  transition: background .4s, backdrop-filter .4s;
}
.top.is-scrolled { background: rgba(13,7,22,.55); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.brand { font: 400 1.7rem/1 var(--serif); font-variation-settings: "SOFT" 100; text-decoration: none; display: flex; flex-direction: column; }
.brand small, .foot-brand small { font: 400 .62rem/1.6 var(--sans); letter-spacing: .32em; color: var(--mist); }
.top nav { display: none; }
.top ul { list-style: none; display: flex; gap: 32px; margin: 0; padding: 0; }
.top nav a { text-decoration: none; font-size: .95rem; color: var(--mist); transition: color .2s; }
.top nav a:hover { color: var(--ivory); }

/* ---------- Clock ---------- */
.clock {
  position: fixed; z-index: 41; left: 50%; top: 20px; margin-left: -46px;
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px; border-radius: 999px;
  font: 400 1rem/1 var(--serif); font-variant-numeric: tabular-nums; letter-spacing: .04em;
  opacity: 0; transform: translateY(10px); transition: opacity .5s, transform .5s;
}
.clock.is-on { opacity: 1; transform: none; }
.clock:not(.is-on) { pointer-events: none; }
.clock-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--glow); box-shadow: 0 0 12px 2px var(--glow); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100svh; display: grid; align-items: end; overflow: hidden; isolation: isolate; }
.kb, .hero-veil { position: absolute; inset: 0; }
.kb { z-index: -2; background: var(--midnight); }
.kb-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.8s ease; }
.kb-slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); }
.kb-slide.is-on { opacity: 1; }
.kb-slide.is-on img { animation: kenburns 9s linear forwards; }
.kb-slide:nth-child(2n).is-on img { animation-name: kenburns2; }
@keyframes kenburns { from { transform: scale(1.04) translate(0,0); } to { transform: scale(1.18) translate(-2%, -1.5%); } }
@keyframes kenburns2 { from { transform: scale(1.18) translate(2%, 1%); } to { transform: scale(1.04) translate(0,0); } }
.hero-veil {
  z-index: -1;
  background:
    radial-gradient(90% 80% at 10% 95%, rgba(13,7,22,.92) 15%, transparent 70%),
    linear-gradient(90deg, rgba(13,7,22,.55) 0%, transparent 60%),
    linear-gradient(180deg, rgba(13,7,22,.6) 0%, rgba(13,7,22,.15) 35%, rgba(42,18,48,.9) 100%);
}
.hero-inner { padding: 120px var(--pad) 110px; max-width: 1100px; }
/* QA fix: stronger veil on phones so the headline stays readable over busy photos */
@media (max-width: 700px) {
  .hero-veil { background: linear-gradient(180deg, rgba(13,7,22,.55) 0%, rgba(13,7,22,.35) 30%, rgba(13,7,22,.88) 58%, rgba(42,18,48,.96) 100%); }
}
.hero-kicker { font-size: .95rem; color: var(--ivory); text-shadow: 0 1px 10px rgba(0,0,0,.7); margin-bottom: 8px; }
.hero-title {
  font-family: var(--serif);
  font-variation-settings: "SOFT" 100, "opsz" 144;
  font-weight: 300;
  font-size: clamp(5.2rem, 30vw, 17rem);
  line-height: .82; letter-spacing: -.045em;
  margin-left: -.04em;
  text-shadow: 0 0 60px rgba(245,184,92,.35);
}
.ht-line { display: inline-block; }
.hero-lede { max-width: 34ch; font-size: clamp(1.05rem, 2.2vw, 1.3rem); margin: 18px 0 28px; color: #efe5d6; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-quote { display: none; }
.scroll-cue { position: absolute; right: var(--pad); bottom: 28px; width: 44px; height: 64px; display: grid; place-items: center; }
.cue-line { width: 1px; height: 48px; background: linear-gradient(var(--ivory), transparent); animation: cue 2.4s var(--ease) infinite; transform-origin: top; }
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* Hero load sequence (the one orchestrated moment) */
.hero-kicker, .ht-line, .hero-lede, .hero-ctas { opacity: 0; transform: translateY(24px); filter: blur(8px); animation: rise 1.1s var(--ease) forwards; }
.ht-line { animation-delay: .15s; animation-duration: 1.5s; }
.hero-lede { animation-delay: .55s; }
.hero-ctas { animation-delay: .75s; }
@keyframes rise { to { opacity: 1; transform: none; filter: blur(0); } }

/* ---------- Horizontal section ---------- */
.hz { position: relative; padding: 96px 0 72px; }
.hz-track {
  display: flex; gap: 20px; align-items: stretch;
  overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  padding: 0 var(--pad) 24px; scroll-padding-inline: var(--pad); scrollbar-width: none;
}
.hz-track::-webkit-scrollbar { display: none; }
.hz-intro, .moment { flex: 0 0 auto; scroll-snap-align: start; }
.hz-intro { width: min(72vw, 420px); display: flex; flex-direction: column; justify-content: center; gap: 18px; padding-bottom: 8px; }
.hz-intro p { color: var(--mist); max-width: 30ch; }
.moment { position: relative; width: 82vw; display: grid; gap: 12px; align-content: end; }
.moment-hour {
  font: italic 300 clamp(4.5rem, 20vw, 11rem)/.8 var(--serif);
  font-variation-settings: "SOFT" 100, "opsz" 144;
  color: transparent; -webkit-text-stroke: 1px rgba(244,236,223,.7);
  letter-spacing: -.04em;
}
.moment-media { overflow: hidden; border-radius: var(--r-lg); }
.moment-media img { width: 100%; height: 100%; object-fit: cover; }
.m-tall { aspect-ratio: 4/5; }
.m-wide { aspect-ratio: 4/3; }
.m-small { display: none; }
.moment-text { padding: 20px 22px; border-radius: var(--r-sm); display: grid; gap: 8px; justify-items: start; }
.moment-text h3 { font: 400 1.6rem/1.1 var(--serif); }
.moment-text p { color: #e6dbe6; font-size: .98rem; }
.hz-progress { display: none; }

/* ---------- Gallery ---------- */
.gallery { padding: 96px 0; }
.sec-head { display: grid; gap: 16px; margin-bottom: 40px; }
.sec-head p { color: var(--mist); max-width: 46ch; }
.masonry { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 10px; }
.masonry li { break-inside: avoid; margin-bottom: 10px; }
.tile {
  display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in;
  border-radius: var(--r-sm); overflow: hidden; position: relative;
}
.tile img { width: 100%; transition: transform .8s var(--ease), filter .5s; }
.tile::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); pointer-events: none; }
.tile:hover img { transform: scale(1.05); filter: saturate(1.15) brightness(1.05); }

/* ---------- Reservation ---------- */
.resa { padding: 96px 0; }
.resa-grid { display: grid; gap: 40px; }
.resa-copy { display: grid; gap: 20px; align-content: start; }
.resa-copy > p { max-width: 44ch; color: #e6dbe6; }
.resa-alt a { color: var(--lantern); }
.carte { padding: 22px; border-radius: var(--r-sm); display: grid; gap: 10px; justify-items: start; max-width: 440px; }
.carte h3 { font: italic 400 1.5rem/1.1 var(--serif); }
.carte p { color: var(--mist); font-size: .95rem; }
.resa-form { padding: 24px; border-radius: var(--r-lg); display: grid; gap: 18px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label, legend { font-size: .88rem; color: var(--mist); }
fieldset { border: 0; margin: 0; padding: 0; }
input, select {
  width: 100%; min-width: 0; min-height: 50px; padding: 12px 14px;
  font: 400 1rem var(--sans); color: var(--ivory);
  background: rgba(13,7,22,.45); border: 1px solid rgba(255,255,255,.2); border-radius: 12px;
  color-scheme: dark; appearance: none; -webkit-appearance: none;
}
select { background-image: linear-gradient(45deg, transparent 50%, var(--mist) 50%), linear-gradient(135deg, var(--mist) 50%, transparent 50%); background-position: calc(100% - 18px) 22px, calc(100% - 13px) 22px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
select option { background: #1d1026; }
input::placeholder { color: #a99aad; }
input:focus, select:focus { border-color: var(--lantern); outline: none; box-shadow: 0 0 0 3px rgba(245,184,92,.3); }
[aria-invalid="true"] { border-color: #ff8fa8; }
.err { min-height: 0; font-size: .82rem; color: #ffb3c4; }
.err:empty { display: none; }
.stepper { display: flex; align-items: center; gap: 14px; margin-top: 6px; }
.step { width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.06); color: var(--ivory); font-size: 1.4rem; cursor: pointer; transition: background .2s; }
.step:hover { background: rgba(255,255,255,.16); }
.stepper output { font: 400 2rem/1 var(--serif); min-width: 2ch; text-align: center; font-variant-numeric: tabular-nums; }
.preview { padding: 14px 16px; border-radius: 12px; background: rgba(13,7,22,.35); border: 1px dashed rgba(255,255,255,.18); }
.preview-label { font-size: .8rem; color: var(--mist); margin-bottom: 4px; }
.preview-text { font-size: .95rem; white-space: pre-line; }
.form-note { font-size: .82rem; color: var(--mist); text-align: center; }

/* ---------- Infos ---------- */
.infos { padding: 96px 0; }
.infos-grid { display: grid; gap: 16px; }
.infos-card { padding: 28px 24px; border-radius: var(--r-lg); display: grid; gap: 20px; justify-items: start; }
.infos-card .display { font-size: clamp(2.4rem, 6vw, 4rem); }
.status { display: inline-flex; align-items: center; gap: 10px; font-size: .95rem; }
.status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--mist); }
.status.open::before { background: #7dffb0; box-shadow: 0 0 10px #7dffb0; }
.status.closed::before { background: #ff8fa8; }
dl { margin: 0; display: grid; gap: 14px; width: 100%; }
dl div { display: grid; grid-template-columns: 6.5em 1fr; gap: 12px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.12); }
dt { color: var(--mist); font-size: .92rem; }
dd { margin: 0; }
dd a { color: var(--lantern); }
.map { min-height: 340px; border-radius: var(--r-lg); overflow: hidden; border: 1px solid rgba(255,255,255,.14); }
.map iframe { width: 100%; height: 100%; min-height: 340px; border: 0; display: block; filter: invert(.9) hue-rotate(200deg) saturate(.7) contrast(.95); }

/* ---------- Instagram ---------- */
.insta { padding: 110px 0 120px; text-align: center; }
.insta-inner { display: grid; gap: 22px; justify-items: center; }
.insta-count { color: var(--mist); }
.insta-count span { color: var(--ivory); font-family: var(--serif); font-size: 1.3em; }
.insta-handle { font: italic 300 clamp(2.6rem, 13.5vw, 9.5rem)/.9 var(--serif); font-variation-settings: "SOFT" 100, "opsz" 144; letter-spacing: -.03em; max-width: 100%; overflow-wrap: anywhere; }
.insta-handle a { text-decoration: none; background: linear-gradient(90deg, var(--lantern), var(--neon) 55%, var(--violet)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.insta-ctas { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* ---------- Footer ---------- */
.foot { padding: 48px 0 84px; border-top: 1px solid rgba(255,255,255,.1); background: rgba(7,4,12,.5); }
.foot-inner { display: grid; gap: 14px; color: var(--mist); font-size: .92rem; }
.foot-brand { font: 400 1.8rem/1 var(--serif); color: var(--ivory); display: flex; flex-direction: column; }
.foot a { color: var(--ivory); }
.demo-note { font-style: italic; }

/* ---------- Lightbox ---------- */
.lb { width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(7,4,12,.92); color: var(--ivory); }
.lb::backdrop { background: rgba(7,4,12,.7); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.lb[open] { display: grid; place-items: center; animation: lbIn .4s var(--ease); }
@keyframes lbIn { from { opacity: 0; } }
.lb figure { margin: 0; display: grid; gap: 12px; justify-items: center; padding: 64px 16px; }
.lb img { max-width: min(92vw, 1400px); max-height: 78vh; width: auto; border-radius: var(--r-sm); }
.lb figcaption { max-width: 60ch; text-align: center; color: var(--mist); font-size: .92rem; }
.lb-btn { position: absolute; width: 52px; height: 52px; border-radius: 50%; border: 1px solid rgba(255,255,255,.3); background: rgba(255,255,255,.08); color: var(--ivory); font-size: 1.8rem; line-height: 1; cursor: pointer; }
.lb-btn:hover { background: rgba(255,255,255,.2); }
.lb-close { top: 14px; right: 14px; }
.lb-prev { left: 14px; bottom: 14px; }
.lb-next { right: 14px; bottom: 14px; }

/* ================= Larger screens ================= */
@media (min-width: 700px) {
  .masonry { columns: 3; column-gap: 14px; }
  .masonry li { margin-bottom: 14px; }
  .moment { width: 56vw; }
}

@media (min-width: 900px) {
  .top nav { display: block; }
  .clock { top: auto; bottom: 28px; left: var(--pad); margin-left: 0; }
  .hero-quote { display: block; text-shadow: 0 2px 18px rgba(0,0,0,.8); position: absolute; right: var(--pad); top: 50%; max-width: 15ch; text-align: right; font: italic 300 1.6rem/1.2 var(--serif); color: #efe5d6; }
  .hero-quote span { display: block; margin-top: 10px; font: 400 .8rem/1.4 var(--sans); color: var(--mist); }
  .resa-grid { grid-template-columns: 1fr 1.05fr; column-gap: 72px; row-gap: 28px; align-items: start; }
  .resa-copy { grid-column: 1; grid-row: 1; }
  .resa-form { grid-column: 2; grid-row: 1 / span 2; }
  .carte { grid-column: 1; grid-row: 2; }
  .resa-form { padding: 36px; }
  .infos-grid { grid-template-columns: 1fr 1.3fr; gap: 20px; }
  .infos-card { padding: 44px 40px; }
  .foot-inner { grid-template-columns: 1fr auto auto; align-items: end; gap: 40px; }

  /* Pinned horizontal scroll (enabled by JS with .hz--pinned) */
  .hz--pinned { padding: 0; }
  .hz--pinned .hz-sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
  .hz--pinned .hz-track { overflow: visible; scroll-snap-type: none; padding: 0 0 0 var(--pad); gap: 6vw; will-change: transform; width: max-content; }
  .hz--pinned .hz-intro { width: 30vw; justify-content: flex-end; align-self: center; }
  .moment { width: auto; grid-template-columns: auto auto; grid-template-rows: auto 1fr; column-gap: 24px; row-gap: 0; align-content: center; }
  .moment-hour { grid-column: 1 / -1; margin-bottom: -.3em; position: relative; z-index: 1; pointer-events: none; }
  .moment-media { height: 58vh; }
  .m-tall { aspect-ratio: 4/5; }
  .m-wide { aspect-ratio: 4/3; }
  .m-small { display: block; aspect-ratio: 3/4; height: 40vh; align-self: end; }
  .moment-text { position: absolute; right: -2vw; bottom: 4vh; width: 300px; z-index: 2; }
  .moment-duo .moment-text { right: auto; left: 2vw; bottom: -2vh; }
  .moment-last { padding-right: 18vw; }
  .moment-last .moment-text { right: 6vw; }
  .hz-progress { display: block; position: absolute; left: var(--pad); right: var(--pad); bottom: 36px; height: 1px; background: rgba(255,255,255,.15); }
  .hz-progress span { display: block; height: 100%; width: 100%; background: var(--glow); transform-origin: left; transform: scaleX(0); box-shadow: 0 0 12px var(--glow); }
}

@media (min-width: 1200px) {
  .masonry { columns: 4; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .hero-kicker, .ht-line, .hero-lede, .hero-ctas { opacity: 1; transform: none; filter: none; }
  .kb-slide.is-on img { animation: none; transform: none; }
  .btn { transform: none; }
}
