/* ===== Pair Door aesthetic — lifted verbatim from the staging Pair Door ===== */

:root {
  color-scheme: dark;

  /* Warm + cool endpoints (premium silver, never neon/RGB) */
  --warm-key: #ffc48e;   /* amber / gold        */
  --cool-key: #cdddec;   /* platinum, cool-blue whisper */
  --warm-acc: #ff9b8f;   /* warm rose           */
  --cool-acc: #a8c4e8;   /* cool blue whisper   */
  --warm-tint: #1a1512;  /* warm dark room      */
  --cool-tint: #11151d;  /* cool dark room      */

  /* Live colours, recomputed every frame from --warmth */
  --key:  color-mix(in oklab, var(--cool-key), var(--warm-key) calc(var(--warmth) * 100%));
  --acc:  color-mix(in oklab, var(--cool-acc), var(--warm-acc) calc(var(--warmth) * 100%));
  --tint: color-mix(in oklab, var(--cool-tint), var(--warm-tint) calc(var(--warmth) * 100%));

  /* Wordmark gradient stops — washes warm-silver -> cool-platinum,
     both ends light enough on dark to stay fully legible. */
  --mark-hi:  color-mix(in oklab, #eef4fb, #fff7ec calc(var(--warmth) * 100%));
  --mark-mid: color-mix(in oklab, #cdd9e6, #e7d9c4 calc(var(--warmth) * 100%));
  --mark-lo:  color-mix(in oklab, #93a3b5, #b9a98f calc(var(--warmth) * 100%));

  --breath: 4s;   /* play button pulse           */
  --wash: 16s;    /* full warm->cool->warm cycle (4 breaths) */
}

@keyframes wash {
  0%, 100% { --warmth: 1; }   /* warm inhale */
  50%      { --warmth: 0; }   /* cool exhale */
}

@keyframes breathe {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.055); }
}

.door-body {
  overflow-x: hidden;
  overflow-y: auto;           /* the wall lives below the hero on this page */
  background: #08070a;
  color: #e7d9c4;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  animation: none; /* the canvas is the light show; no warmth wash here */
}
#scene { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
/* When the film is on (or its poster is showing), the canvas stays out of the way */
body.video-on #scene { display: none; }

/* full-bleed background film: 16:9 crops gracefully to portrait, centre kept */
.door-video {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
  background: #08070a; /* while nothing is painted yet */
}
/* readability scrim: darker at top and bottom, gentle vignette in the middle */
.door-scrim {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(90% 60% at 50% 58%, rgba(8, 7, 10, 0.30) 0%, rgba(8, 7, 10, 0) 55%),
    linear-gradient(180deg, rgba(8, 7, 10, 0.62) 0%, rgba(8, 7, 10, 0.34) 38%, rgba(8, 7, 10, 0.55) 72%, rgba(6, 5, 8, 0.88) 100%);
}
/* floating "arrivals": readable soft-glow pills that fade in, hold, fade out */
#traces { position: fixed; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.trace {
  position: absolute;
  max-width: min(46vw, 300px);
  padding: 8px 15px;
  border-radius: 16px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-size: clamp(0.86rem, 3.6vw, 1.05rem);
  line-height: 1.3;
  color: rgba(244, 236, 224, 0.94);
  background: rgba(8, 7, 10, 0.5);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.9);
  box-shadow: 0 0 34px rgba(0, 0, 0, 0.6), 0 0 22px rgba(255, 196, 142, 0.12);
  opacity: 0;
  transform: translateY(6px);
}
/* Whole life in one animation: gentle arrival, ~4.5s glow, gentle fade.
   animationend removes the node — no JS timers/counter to leak. */
.trace.is-live { animation: floatLife 7.2s ease-in-out forwards; }
@keyframes floatLife {
  0%   { opacity: 0; transform: translateY(6px); }
  15%  { opacity: 1; transform: none; }
  80%  { opacity: 1; transform: none; }
  100% { opacity: 0; transform: translateY(-4px); }
}

/* subtle scroll cue at the foot of the hero */
.door__scroll {
  position: absolute;
  bottom: 18px; left: 50%; transform: translateX(-50%);
  z-index: 2;
  font-size: 0.7rem; letter-spacing: 0.24em; text-transform: uppercase;
  color: rgba(231, 217, 196, 0.55); text-decoration: none;
  animation: nudge 2.6s ease-in-out infinite;
}
.door__scroll:hover { color: rgba(231, 217, 196, 0.9); }
@keyframes nudge { 0%, 100% { transform: translate(-50%, 0); opacity: 0.65; } 50% { transform: translate(-50%, 5px); opacity: 1; } }

/* the wall section (below the hero) — its own opaque dark surface */
.wall2 {
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, rgba(8, 7, 10, 0.72) 0%, #08070a 10%, #07060a 100%);
  padding: clamp(36px, 8vh, 80px) clamp(16px, 5vw, 28px) 60px;
}
.wall2__inner { max-width: 620px; margin: 0 auto; }
.wall2__head { text-align: center; margin-bottom: 22px; }
.wall2__title {
  margin: 0 0 6px; font-family: "Cormorant Garamond", Georgia, serif; font-weight: 300;
  font-size: clamp(2rem, 8vw, 2.8rem); color: #f4ece0;
}
.wall2__sub { margin: 0 0 16px; font-size: 0.9rem; color: rgba(231, 217, 196, 0.6); }
.wall2__mark {
  border: 1px solid rgb(from var(--key) r g b / 0.4); cursor: pointer;
  background: rgba(255, 255, 255, 0.05); color: #f4ece0;
  font-family: inherit; font-size: 0.95rem; padding: 11px 24px; border-radius: 999px;
  -webkit-tap-highlight-color: transparent;
}
.wall2__mark:hover { border-color: rgb(from var(--key) r g b / 0.7); }

.wall2__form {
  background: rgba(255, 255, 255, 0.04); border: 1px solid rgb(from var(--key) r g b / 0.28);
  border-radius: 16px; padding: 16px; margin-bottom: 22px;
}
.wall2__row { display: flex; gap: 8px; margin-bottom: 8px; }
.wall2__input, .wall2__text {
  width: 100%; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px; padding: 10px 12px; color: #f4ece0; font: inherit; font-size: 1rem; outline: none;
}
.wall2__input:focus, .wall2__text:focus { border-color: rgb(from var(--key) r g b / 0.6); }
.wall2__text { resize: vertical; min-height: 52px; margin-bottom: 8px; }
.wall2__age { margin: 4px 2px 10px; }
.wall2__actions { display: flex; gap: 10px; align-items: center; }
.wall2__submit {
  border: 0; cursor: pointer; border-radius: 999px; padding: 10px 22px; font: inherit; font-weight: 500;
  color: #241a12; background: linear-gradient(180deg, #fff7ee, #e7d9c4);
}
.wall2__submit:disabled { opacity: 0.5; cursor: default; }
.wall2__cancel { background: none; border: 0; cursor: pointer; color: rgba(231, 217, 196, 0.5); font: inherit; text-decoration: underline; text-underline-offset: 2px; }
.wall2__msg { margin: 8px 0 0; min-height: 1.1em; font-size: 0.84rem; color: rgba(231, 217, 196, 0.7); }

.wall2__list { display: flex; flex-direction: column; gap: 12px; }
.wall2__card {
  background: rgba(255, 255, 255, 0.035); border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px; padding: 14px 16px;
}
.wall2__meta { display: flex; align-items: baseline; gap: 6px; margin-bottom: 6px; font-size: 0.82rem; }
.wall2__name { color: #ece0cd; font-weight: 500; }
.wall2__loc { color: rgba(231, 217, 196, 0.5); }
.wall2__time { margin-left: auto; color: rgba(231, 217, 196, 0.4); font-size: 0.74rem; }
.wall2__pill { display: inline-block; padding: 1px 7px; border-radius: 999px; font-size: 0.62rem; font-weight: 600; color: #241a12; background: #e7d9c4; }
.wall2__body { margin: 0; font-size: 1rem; line-height: 1.5; color: #efe6d8; overflow-wrap: anywhere; }
.wall2__empty { text-align: center; color: rgba(231, 217, 196, 0.45); font-style: italic; }
.wall2__foot { text-align: center; margin-top: 34px; font-size: 0.72rem; }
.wall2__foot a { color: rgba(231, 217, 196, 0.4); text-decoration: none; }
.wall2__foot a:hover { color: rgba(231, 217, 196, 0.8); }

.door {
  position: relative;
  z-index: 2;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(24px, 7vw, 64px);
  gap: 22px;
}
.door__brand {
  margin: 0;
  font-size: clamp(0.95rem, 4.5vw, 1.2rem);
  font-weight: 500;
  letter-spacing: 0.62em;
  text-indent: 0.62em;
  color: rgba(231, 217, 196, 0.85);
  text-shadow: 0 0 22px rgba(255, 196, 142, 0.25);
}
.door__panel { display: flex; flex-direction: column; align-items: center; gap: 16px; max-width: 560px; }
.door__title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 300;
  font-size: clamp(2.4rem, 10vw, 4.2rem);
  line-height: 1.12;
  color: #f4ece0;
  text-shadow: 0 0 40px rgba(255, 196, 142, 0.16);
  animation: doorAppear 1.6s ease both;
}
.door__sub {
  margin: 0;
  font-size: clamp(0.92rem, 4vw, 1.05rem);
  color: rgba(231, 217, 196, 0.66);
  animation: doorAppear 1.6s ease 0.35s both;
}
@keyframes doorAppear { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.door__cta {
  margin-top: 10px;
  border: 0;
  cursor: pointer;
  padding: 16px 34px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: #241a12;
  background: radial-gradient(circle at 38% 30%, #fff7ee 0%, #e7d9c4 55%, #cdbb9e 100%);
  box-shadow: inset 0 1px 2px rgba(255,255,255,0.7), 0 0 42px rgba(255,196,142,0.3), 0 12px 34px rgba(0,0,0,0.55);
  -webkit-tap-highlight-color: transparent;
  animation: doorAppear 1.6s ease 0.7s both, breathe 4.4s ease-in-out 2.5s infinite;
}
.door__cta:active { transform: scale(0.97); }
.door__cta:disabled { opacity: 0.7; }

/* Secondary, quieter entry — for people who want the shared room, no friend needed.
   Sits below the primary CTA; text-link weight so "Bring someone in" stays the hero. */
/* Secondary entry — pill on a translucent dark ground so it reads clearly over
   the film (was a faint underline that got lost against bright frames). */
.door__join {
  margin-top: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #f4ece0;
  text-decoration: none;
  padding: 9px 20px;
  border-radius: 999px;
  background: rgba(8, 7, 10, 0.55);
  border: 1px solid rgba(231, 217, 196, 0.45);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s ease, border-color 0.2s ease;
  animation: doorAppear 1.6s ease 0.9s both;
}
.door__join:hover { background: rgba(8, 7, 10, 0.72); border-color: rgba(255, 196, 142, 0.7); }

.door__key { font-size: 2.4rem; color: #e7d9c4; text-shadow: 0 0 30px rgba(255,196,142,0.5); animation: breathe 4.4s ease-in-out infinite; }
.door__member { margin: 0; font-family: "Cormorant Garamond", Georgia, serif; font-size: clamp(1.5rem, 7vw, 2.1rem); color: #f4ece0; }
.door__share { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.door__sharebtn {
  display: inline-block; cursor: pointer; border: 1px solid rgba(231,217,196,0.3);
  background: rgba(255,255,255,0.05); color: #e7d9c4; text-decoration: none;
  font-family: inherit; font-size: 0.9rem; padding: 10px 18px; border-radius: 999px;
  -webkit-tap-highlight-color: transparent;
}
.door__sharebtn:hover { border-color: rgba(255,196,142,0.6); }
.door__linkline { margin: 0; font-size: 0.76rem; color: rgba(231,217,196,0.45); overflow-wrap: anywhere; max-width: 90vw; }
.door__reserve { display: flex; gap: 8px; margin-top: 6px; width: min(380px, 90vw); }
.door__reserve-input {
  flex: 1 1 auto; min-width: 0; background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12); border-radius: 999px;
  padding: 10px 16px; color: #f4ece0; font: inherit; font-size: 0.82rem; outline: none;
}
.door__reserve-btn {
  flex: 0 0 auto; border: 0; cursor: pointer; border-radius: 999px; padding: 0 18px;
  font: inherit; font-size: 0.85rem; color: #241a12; background: #e7d9c4;
}
.door__msg { margin: 0; min-height: 1.2em; font-size: 0.85rem; color: rgba(231,217,196,0.7); }
.door__foot { position: fixed; bottom: 14px; left: 0; right: 0; text-align: center; font-size: 0.72rem; z-index: 2; }
.door__foot a { color: rgba(231,217,196,0.4); text-decoration: none; }
.door__foot a:hover { color: rgba(231,217,196,0.8); }

/* ---------- Respect reduced motion: settle on one balanced blend ---------- */
@media (prefers-reduced-motion: reduce) {
  body { animation: none; }                 /* --warmth stays at its 0.58 blend */
  .glow, .brand__text, .play, .play__halo, .play__ring, .joined, .presence__dot { animation: none; }
  .play.is-playing, .play.is-playing .play__halo, .play.is-playing .play__ring { animation: none; }


/* ===== KEEP-integration: the four production features live below the hero.
   Their markup + JS are byte-identical to prod; this only restyles/positions. ===== */
.next-body { margin: 0; background: #08070a; color: #efe6d8; overflow-x: hidden; }
/* Retire the old page's decorative hero chrome (pure presentation). */
.next-body .aurora,
.next-body .hero .brand,
.next-body .hero .hook,
.next-body .hero .soon,
.next-body .hero .scrollcue { display: none !important; }

/* The hero container becomes a normal below-the-fold section (the film hero is
   the new .door above it). z-index:2 so KEEP content sits over the fixed video. */
.next-body .hero { position: relative; z-index: 2; min-height: 0; padding: clamp(40px,10vh,90px) 20px 10px; gap: 22px; background: linear-gradient(180deg, rgba(8,7,10,0.65) 0%, #08070a 12%); }
.next-body .wall, .next-body .footer { position: relative; z-index: 2; background: #08070a; }
.next-body .footer { padding-bottom: 40px; }

/* The pearl (Mixcloud play) — kept, recoloured to sit on the dark section. */
.next-body .play { position: relative; }

/* "Who's already here" wall rendered by app.js (#wall-list) — dark cards. */
.next-body .wall { padding: 10px 20px 30px; }
.next-body .wall__list { max-width: 620px; margin: 0 auto; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }

/* Listening popup overlay above everything. */
.next-body .popup { z-index: 50; }

