:root {
  --wine: #64171b;
  --wine-deep: #3d0c11;
  --wine-bright: #8f2929;
  --paper: #f4e9d2;
  --moon: #efcf8f;
  --moon-hot: #fff1c6;
  --ink-muted: rgba(244, 233, 210, 0.62);
  --line: rgba(244, 233, 210, 0.28);
  --progress: 0;
  --moon-shift: 0%;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--paper);
  background: var(--wine);
  font-family: "Manrope", sans-serif;
}

button, input { font: inherit; }
textarea { font: inherit; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 2px solid var(--moon-hot);
  outline-offset: 5px;
}

.experience {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  min-height: 100svh;
  overflow-x: hidden;
  padding: 30px clamp(24px, 4.4vw, 72px) 26px;
  background: linear-gradient(115deg, var(--wine-deep), var(--wine) 45%, #71191d 100%);
}

/* Progress-linked glow used to live in .experience's own background (radial-gradient
   position + opacity recalculated from --progress on every drag frame), which forced a
   full-viewport repaint ~60 times/sec while dragging — the main remaining lag source.
   Moved to its own layer: only `opacity` changes now, which the compositor can animate
   without repainting anything. */
.glow {
  position: absolute;
  z-index: -1;
  inset: 0;
  opacity: calc(.3 + var(--progress) * .006);
  background: radial-gradient(circle at 76% 42%, rgba(238, 171, 84, .5), transparent 38%);
  pointer-events: none;
  will-change: opacity;
}

.grain {
  position: absolute;
  z-index: -1;
  inset: -50%;
  opacity: .15;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.36'/%3E%3C/svg%3E");
  animation: grain 8s steps(8) infinite;
}

.halo {
  position: absolute;
  z-index: -2;
  border: 1px solid rgba(255, 220, 157, .11);
  border-radius: 50%;
  pointer-events: none;
}

.halo-one { width: 70vw; height: 70vw; right: -30vw; top: -36vw; }
.halo-two { width: 42vw; height: 42vw; left: -26vw; bottom: -28vw; }

.masthead,
footer,
.chapter-line,
.range-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.masthead {
  z-index: 5;
  position: relative;
  justify-content: center;
  text-align: center;
}

.language-toggle {
  position: relative;
  display: flex;
  align-items: center;
  width: 126px;
  height: 38px;
  margin: 0 0 24px;
  padding: 3px;
  border: 1px solid rgba(239, 207, 143, .55);
  border-radius: 999px;
  color: var(--paper);
  background: rgba(61, 12, 17, .5);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .14em;
}

.language-toggle-indicator {
  position: absolute;
  z-index: 0;
  left: 3px;
  top: 3px;
  width: calc(50% - 3px);
  height: 30px;
  border-radius: 999px;
  background: var(--moon);
  box-shadow: 0 3px 14px rgba(20, 0, 2, .24);
  transition: transform 280ms cubic-bezier(.2, .72, .2, 1);
}

.language-toggle[data-active-lang="en"] .language-toggle-indicator {
  transform: translateX(100%);
}

.language-toggle button {
  position: relative;
  z-index: 1;
  width: 50%;
  height: 30px;
  padding: 0;
  border: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
}

.language-toggle button[aria-pressed="true"] {
  color: var(--wine-deep);
}

.mark {
  display: block;
  width: clamp(42px, 4.2vw, 62px);
  color: inherit;
  text-decoration: none;
}

.mark img {
  display: block;
  width: 100%;
  max-height: 72px;
  height: auto;
  object-fit: contain;
}

.edition,
.sound-toggle,
.eyebrow,
.range-labels,
.chapter-line,
footer {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.edition {
  position: absolute;
  left: 50%;
  top: calc(100% + 8px);
  margin: 0;
  color: var(--ink-muted);
  transform: translateX(-50%);
  white-space: nowrap;
}

.sound-toggle {
  position: absolute;
  right: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 0;
  padding: 8px 0;
  border: 0;
  color: var(--ink-muted);
  background: transparent;
  cursor: pointer;
}

.sound-toggle svg {
  width: 19px;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  fill-rule: evenodd;
}

.sound-toggle[aria-pressed="false"] .sound-wave { opacity: .2; }

.stage {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: clamp(8px, 1.5vh, 18px);
  width: min(780px, 100%);
  margin: 0 auto;
  padding: clamp(28px, 5vh, 70px) 0 clamp(20px, 3vh, 42px);
  text-align: center;
}

.copy-panel {
  position: relative;
  z-index: 2;
  text-align: center;
}
.eyebrow { margin: 0 0 16px; color: var(--moon); }

h1 {
  position: relative;
  height: clamp(118px, 17vw, 248px);
  margin: 0;
}

.word-none,
.word-none-accent {
  position: absolute;
  left: 50%;
  bottom: 0;
  display: block;
  width: min(640px, 90%);
  height: auto;
  transition: opacity 700ms ease, transform 900ms cubic-bezier(.2,.72,.2,1), filter 700ms ease;
}

.word-none {
  opacity: calc(1 - max(0, (var(--progress) - 74) / 26));
  transform: translateX(-50%);
}
.word-none-accent {
  opacity: max(0, (var(--progress) - 72) / 28);
  transform: translate(-50%, calc((100 - var(--progress)) * .08px));
  /* dynamic filter blur removed — recomputing blur radius per input event was a
     major drag-lag source on iOS. Opacity/transform alone carry the reveal. */
}

.story {
  width: min(390px, 100%);
  min-height: 96px;
  margin: 0 auto;
  padding: 0 18px;
  border-left: 0;
}

.story-kicker {
  margin: 0 0 8px;
  font-family: "Xanh Mono", monospace;
  font-size: clamp(19px, 1.8vw, 26px);
  font-style: italic;
}

.story-body {
  margin: 0;
  color: var(--ink-muted);
  font-size: 12px;
  font-weight: 300;
  line-height: 1.7;
  text-wrap: pretty;
}

.story.is-changing { animation: story-change 450ms ease; }

.moon-field {
  position: relative;
  display: grid;
  place-items: center;
  min-height: clamp(290px, 44vh, 480px);
}

.moon-wrap { position: relative; }

.moon {
  position: relative;
  width: clamp(245px, 31vw, 440px);
  aspect-ratio: 1;
  border-radius: 50%;
  /* iOS/WebKit fix: this element is the clip host ONLY — it must never carry its own
     transform. Safari does not reliably clip a descendant that has its own compositing
     layer (.moon-shadow uses translate3d) when the clipping ancestor is ALSO transformed;
     the scale-with-progress effect lives on the untransformed .moon-scale child instead.
     clip-path + mask-image are both set (mask-image has historically been the more
     reliable of the two on Safari for clipping composited descendants) — belt and
     braces since this bug still surfaced once already. contain:paint stays removed —
     it aggravated the same WebKit clipping bug. */
  -webkit-clip-path: circle(50% at 50% 50%);
  clip-path: circle(50% at 50% 50%);
  -webkit-mask-image: radial-gradient(circle closest-side, #000 99%, transparent 100%);
  mask-image: radial-gradient(circle closest-side, #000 99%, transparent 100%);
  overflow: hidden;
  /* Static glow (fixed blur radius). box-shadow renders outside clip-path, and a constant
     radius avoids per-frame blur re-rasterization while dragging the slider (perf). */
  box-shadow: 0 0 46px rgba(239, 207, 143, .16);
}

.moon-scale {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  transform: scale(calc(.93 + var(--progress) * .0007));
  transition: transform 500ms ease;
}

.moon-light {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 37% 31%, rgba(255,255,255,.5) 0 1.2%, transparent 1.5%),
    radial-gradient(circle at 62% 63%, rgba(112,70,44,.12) 0 5%, transparent 5.5%),
    radial-gradient(circle at 34% 71%, rgba(112,70,44,.09) 0 8%, transparent 8.5%),
    radial-gradient(circle at 66% 27%, rgba(112,70,44,.08) 0 10%, transparent 10.5%),
    radial-gradient(circle at 42% 42%, var(--moon-hot), var(--moon));
}

.moon-shadow {
  position: absolute;
  z-index: 2;
  inset: -3%;
  border-radius: 50%;
  background: var(--wine-deep);
  transform: translate3d(var(--moon-shift), 0, 0);
  box-shadow: 22px 0 34px rgba(255, 227, 174, .18);
  transition: transform 140ms linear;
}

.moon-texture {
  position: absolute;
  z-index: 3;
  inset: 0;
  border-radius: inherit;
  opacity: calc(.05 + var(--progress) * .0014);
  mix-blend-mode: multiply;
  background-image: radial-gradient(circle at 28% 44%, #7c5339 0 1.5%, transparent 1.7%), radial-gradient(circle at 68% 36%, #7c5339 0 2.6%, transparent 2.9%), radial-gradient(circle at 50% 74%, #7c5339 0 3.3%, transparent 3.6%);
}

.moon-message {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 50%;
  width: 72%;
  margin: 0;
  opacity: calc(max(0, (var(--progress) - 58) / 42));
  color: var(--wine-deep);
  font-family: "Xanh Mono", monospace;
  font-size: clamp(15px, 1.55vw, 22px);
  font-style: italic;
  line-height: 1.35;
  text-align: center;
  text-wrap: balance;
  transform: translate(-50%, calc(-42% + (100 - var(--progress)) * .12px));
  /* dynamic filter blur removed for drag performance (see .word-none-accent) */
}

.moon-reflection {
  position: absolute;
  width: 68%;
  height: 18%;
  left: 16%;
  bottom: -23%;
  opacity: calc(var(--progress) * .004);
  filter: blur(24px);
  background: var(--moon);
  border-radius: 50%;
}

.orbit {
  position: absolute;
  border: 1px solid rgba(244, 233, 210, .16);
  border-radius: 50%;
  transform: rotate(-18deg);
}

.orbit::after {
  content: "";
  position: absolute;
  width: 6px;
  aspect-ratio: 1;
  top: 12%;
  left: 17%;
  border-radius: 50%;
  background: var(--moon);
  box-shadow: 0 0 12px var(--moon);
}

.orbit-one { width: 84%; aspect-ratio: 1; opacity: calc(.22 + var(--progress) * .004); }
.orbit-two { width: 105%; aspect-ratio: 1; opacity: .18; transform: rotate(28deg); }
.orbit-two::after { top: auto; left: auto; right: 9%; bottom: 25%; width: 3px; }

.control-panel {
  z-index: 4;
  width: min(900px, calc(100% - clamp(28px, 6vw, 72px)));
  margin: 0 auto;
  text-align: center;
}

.ugc-gate {
  position: fixed;
  z-index: 8;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(61, 12, 17, .92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transition: opacity 650ms ease, visibility 650ms ease;
}

.experience.is-unlocked .ugc-gate {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.ugc-form {
  display: grid;
  justify-items: center;
  width: min(660px, 100%);
  text-align: center;
}

.ugc-step {
  margin: 0 0 20px;
  color: var(--moon);
  font-size: 9px;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.ugc-form h2 {
  margin: 0 0 13px;
  font-family: "Xanh Mono", monospace;
  font-size: clamp(27px, 4.5vw, 52px);
  font-weight: 500;
  line-height: 1.15;
  text-wrap: balance;
}

.ugc-prompt {
  margin: 0 0 27px;
  color: var(--ink-muted);
  font-family: "Manrope", sans-serif;
  font-size: clamp(10px, 1.15vw, 13px);
  font-weight: 400;
  line-height: 1.5;
  text-wrap: balance;
}

.message-field {
  position: relative;
  width: min(530px, 100%);
}

#ugc-message {
  display: block;
  width: 100%;
  min-height: 86px;
  resize: none;
  padding: 20px 48px 18px 20px;
  border: 0;
  border-bottom: 1px solid rgba(244, 233, 210, .55);
  border-radius: 0;
  color: var(--paper);
  background: rgba(244, 233, 210, .05);
  font-family: "Manrope", sans-serif;
  font-size: clamp(16px, 1.8vw, 18px);
  font-weight: 300;
  line-height: 1.5;
  text-align: center;
  outline: none;
}

#ugc-message::placeholder { color: rgba(244, 233, 210, .34); }
#ugc-message.is-changing-suggestion::placeholder { animation: suggestion-cycle 520ms ease both; }
#ugc-message:focus { border-color: var(--moon-hot); background: rgba(244, 233, 210, .08); }

.character-count {
  position: absolute;
  right: 10px;
  bottom: 10px;
  color: var(--ink-muted);
  font-size: 9px;
  letter-spacing: .08em;
}

.form-error {
  min-height: 20px;
  margin: 9px 0 0;
  color: var(--moon-hot);
  font-size: 11px;
}

.ugc-actions,
.completion-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
}

.unlock-button,
.save-card {
  min-height: 44px;
  padding: 12px 24px;
  border: 1px solid var(--moon);
  border-radius: 999px;
  color: var(--wine-deep);
  background: var(--moon);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 250ms ease, background 250ms ease;
}

.unlock-button:hover,
.save-card:hover { transform: translateY(-2px); background: var(--moon-hot); }

.replay {
  min-height: 44px;
  margin: 0;
  padding: 12px 0;
  border: 0;
  border-bottom: 1px solid rgba(239, 207, 143, .6);
  color: var(--paper);
  background: transparent;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
}

.control-panel.is-locked { opacity: .34; pointer-events: none; }

.slider-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 0 12px;
  color: var(--moon-hot);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .12em;
  text-transform: uppercase;
  transition: opacity 380ms ease, transform 380ms ease;
  animation: slider-cta-pulse 1.8s ease-in-out infinite;
}
.slider-cta svg { width: 28px; fill: none; stroke: currentColor; stroke-width: 1.4; }
.control-panel.has-interacted .slider-cta { opacity: 0; transform: translateY(4px); animation: none; pointer-events: none; }

.range-labels {
  justify-content: center;
  gap: clamp(28px, 8vw, 100px);
  margin-bottom: 15px;
  color: var(--ink-muted);
  text-align: center;
}
.range-labels span:last-child { color: var(--paper); }
.slider-wrap { position: relative; height: 66px; }

.track {
  position: absolute;
  top: 27px;
  width: 100%;
  height: 3px;
  border-radius: 999px;
  background: rgba(244, 233, 210, .3);
  box-shadow: 0 0 0 1px rgba(255, 241, 198, .08), 0 0 18px rgba(255, 225, 163, .1);
}

.track-progress {
  width: calc(var(--progress) * 1%);
  height: 100%;
  background: var(--moon-hot);
  border-radius: inherit;
  box-shadow: 0 0 18px rgba(255, 237, 190, .68);
}

.chapter-marks { position: absolute; inset: -3px 0 auto; display: flex; justify-content: space-between; }
.chapter-marks i { width: 9px; aspect-ratio: 1; border: 1px solid rgba(255,241,198,.75); border-radius: 50%; background: var(--wine); box-shadow: 0 0 8px rgba(255,225,163,.14); }

#feeling-slider {
  position: absolute;
  z-index: 2;
  inset: 5px 0 auto;
  width: 100%;
  height: 44px;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.thumb-hint {
  position: absolute;
  z-index: 1;
  left: calc(var(--progress) * 1%);
  top: 4px;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  transform: translateX(-50%);
  border: 2px solid rgba(255, 241, 198, .95);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #8f2929, var(--wine-deep));
  box-shadow: 0 0 0 7px rgba(100,23,27,.48), 0 0 26px rgba(255,225,163,.28);
  pointer-events: none;
}

.thumb-hint span {
  position: absolute;
  bottom: 51px;
  width: 130px;
  color: var(--moon-hot);
  font-size: 9px;
  letter-spacing: .12em;
  text-align: center;
  text-transform: uppercase;
  transition: opacity 400ms ease;
}

.thumb-hint svg { width: 23px; fill: none; stroke: var(--paper); stroke-width: 1; }
.has-started .thumb-hint span { opacity: 0; }

@keyframes slider-cta-pulse {
  0%, 100% { opacity: .72; transform: translateX(-3px); }
  50% { opacity: 1; transform: translateX(3px); }
}

.chapter-line {
  justify-content: center;
  gap: 18px;
  padding-top: 11px;
  border-top: 1px solid rgba(244,233,210,.1);
  color: var(--ink-muted);
}

.chapter-title { margin: 0; color: var(--paper); }

.reveal-card {
  display: block;
  min-height: 46px;
  margin: 22px auto 0;
  padding: 12px 26px;
  border: 1px solid var(--moon);
  border-radius: 999px;
  opacity: 0;
  visibility: hidden;
  color: var(--wine-deep);
  background: var(--moon);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  transform: translateY(8px);
  cursor: pointer;
  transition: opacity 420ms ease, visibility 420ms ease, transform 420ms ease, background 250ms ease;
}

.is-journey-ready .reveal-card { opacity: 1; visibility: visible; transform: none; }
.reveal-card:hover { background: var(--moon-hot); }

footer {
  z-index: 4;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: clamp(18px, 3vh, 34px);
  color: var(--ink-muted);
  font-family: "Xanh Mono", monospace;
  line-height: 1.5;
  text-align: center;
  text-transform: none;
}

footer p { margin: 0; }
footer p:first-child {
  font-style: italic;
  white-space: pre-line;
}
.instruction { font-size: 8px; }

.completion {
  position: fixed;
  z-index: 10;
  inset: 0;
  display: grid;
  align-content: start;
  justify-items: center;
  padding: 42px 24px 64px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  background: rgba(55, 7, 12, .9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: opacity 700ms ease, visibility 700ms;
}

.is-complete .completion { opacity: 1; visibility: visible; }
.postcard-step { display: grid; justify-items: center; transition: opacity 420ms ease, transform 420ms ease; }
.postcard {
  position: relative;
  display: grid;
  align-content: space-between;
  justify-items: center;
  width: min(400px, 92vw);
  aspect-ratio: 9 / 16;
  padding: clamp(28px, 5vw, 54px);
  overflow: hidden;
  color: var(--paper);
  background:
    radial-gradient(circle at 50% 45%, rgba(239, 207, 143, .15), transparent 32%),
    linear-gradient(145deg, #751d21, var(--wine-deep));
  border: 1px solid rgba(239, 207, 143, .32);
  box-shadow: 0 30px 80px rgba(21, 0, 3, .36);
  text-align: center;
}

.postcard::before {
  content: "";
  position: absolute;
  width: 72%;
  aspect-ratio: 1;
  left: 14%;
  top: 27%;
  background: radial-gradient(circle at 36% 30%, var(--moon-hot), var(--moon) 68%, #c99b5d 100%);
  border: 1px solid rgba(255, 241, 198, .4);
  border-radius: 50%;
  box-shadow: 0 0 70px rgba(239, 207, 143, .08);
}

.postcard-moon {
  position: absolute;
  width: 72%;
  aspect-ratio: 1;
  left: 14%;
  top: 27%;
  overflow: hidden;
  border-radius: 50%;
  box-shadow: 0 0 52px rgba(239, 207, 143, .2);
  pointer-events: none;
}

.postcard-crater { position: absolute; border-radius: 50%; background: rgba(92, 55, 32, .12); }
.crater-one { width: 17%; aspect-ratio: 1; left: 24%; top: 27%; }
.crater-two { width: 25%; aspect-ratio: 1; right: 18%; top: 35%; }
.crater-three { width: 19%; aspect-ratio: 1; left: 35%; bottom: 18%; }

.postcard-logo { position: absolute; top: 4.5%; width: 42px; height: auto; }
.postcard-kicker { position: absolute; top: 19%; width: 82%; margin: 0; color: var(--moon); font-size: 13px; font-weight: 650; line-height: 1.2; letter-spacing: .12em; text-transform: none; }
.postcard-message { position: absolute; z-index: 2; left: 50%; top: 47.25%; width: 62%; margin: 0; color: var(--wine-deep); font-family: "Xanh Mono", monospace; font-size: clamp(24px, 4.3vw, 38px); font-style: italic; line-height: 1.16; text-wrap: balance; transform: translate(-50%, -50%); }
.postcard-signoff { position: absolute; top: 70%; width: 78%; margin: 0; color: var(--paper); font-size: 9px; line-height: 1.65; letter-spacing: .08em; text-transform: uppercase; }
.postcard-concept { position: absolute; left: 50%; bottom: 5%; width: 78px; height: auto; transform: translateX(-50%); }
.completion-actions { margin-top: 24px; }
.save-card-jpg { color: var(--moon); background: transparent; }
.save-card-jpg:hover { color: var(--wine-deep); }

.answer-board {
  display: none;
  width: min(980px, 92vw);
  margin-top: 70px;
  padding: clamp(34px, 6vw, 70px);
  border: 1px solid rgba(239, 207, 143, .25);
  background: linear-gradient(145deg, rgba(117,29,33,.94), rgba(61,12,17,.97));
  box-shadow: 0 30px 80px rgba(21, 0, 3, .28);
  text-align: center;
}
.completion.is-showing-board { align-content: center; }
.completion.is-showing-board .postcard-step { display: none; }
.completion.is-showing-board .answer-board { display: block; animation: board-reveal 700ms both; }
.answer-board-logo { display: block; width: clamp(46px, 5vw, 62px); height: auto; margin: 0 auto 25px; object-fit: contain; }
.answer-board-eyebrow { margin: 0 0 12px; color: var(--moon); font-size: 9px; letter-spacing: .2em; text-transform: uppercase; }
.answer-board h2 { margin: 0; font-size: clamp(28px, 4vw, 52px); font-style: italic; font-weight: 400; }
.answer-board-intro { width: min(570px, 100%); margin: 16px auto 36px; color: var(--ink-muted); font-size: 11px; line-height: 1.7; }
.word-cloud { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: clamp(15px, 2.7vw, 34px); min-height: 260px; padding: 20px 0; }
.word-cloud span { max-width: 100%; color: var(--cloud-color, var(--paper)); font-family: "Manrope", sans-serif; font-size: var(--cloud-size); font-style: normal; font-weight: var(--cloud-weight, 500); line-height: 1.18; overflow-wrap: anywhere; opacity: calc(.68 + var(--weight) * .32); text-wrap: balance; animation: cloud-in 700ms both; animation-delay: var(--delay); }
.answer-board .replay { margin-top: 30px; }
.skip-download { min-height: 44px; margin: 0; padding: 12px 0; border: 0; border-bottom: 1px solid rgba(239, 207, 143, .6); color: var(--paper); background: transparent; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; cursor: pointer; }
.export-status { min-height: 18px; margin: 13px 0 0; color: var(--moon); font-size: 10px; line-height: 1.5; text-align: center; }
.export-fallback { width: min(390px, 88vw); margin-top: 20px; padding: 18px; border: 1px solid rgba(239,207,143,.28); background: rgba(61,12,17,.96); text-align: center; }
.export-fallback[hidden] { display: none; }
.export-preview { display: block; width: min(210px, 62vw); height: auto; margin: 0 auto 14px; box-shadow: 0 14px 38px rgba(21,0,3,.36); }
.export-fallback p { margin: 0 0 13px; color: var(--ink-muted); font-size: 10px; line-height: 1.5; }
.export-fallback-actions { display: flex; align-items: center; justify-content: center; gap: 20px; }
.open-export, .finish-export { padding: 9px 0; border: 0; border-bottom: 1px solid var(--moon); color: var(--paper); background: transparent; font-size: 9px; letter-spacing: .12em; text-decoration: none; text-transform: uppercase; cursor: pointer; }

@keyframes cloud-in { from { opacity: 0; transform: translateY(10px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes board-reveal { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }

@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(3%, -2%); }
  40% { transform: translate(-2%, 3%); }
  60% { transform: translate(2%, 4%); }
  80% { transform: translate(-4%, -2%); }
}

@keyframes story-change {
  0% { opacity: 1; transform: translateY(0); }
  45% { opacity: 0; transform: translateY(5px); }
  55% { opacity: 0; transform: translateY(-5px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes suggestion-cycle {
  0% { opacity: 0; transform: translateY(5px); }
  100% { opacity: 1; transform: translateY(0); }
}

@media (max-width: 760px) {
  .experience { grid-template-rows: auto 1fr auto auto; padding: 22px 20px 20px; }
  .edition { display: none; }
  .sound-toggle { right: 0; }
  .stage { grid-template-columns: 1fr; gap: 4px; align-content: center; padding: 20px 0 10px; }
  .copy-panel { order: 1; margin-top: clamp(24px, 7vh, 54px); text-align: center; }
  .eyebrow { margin: 0 0 9px; }
  h1 { height: 62px; }
  .word-none { transform: translateX(-50%); }
  .word-none-accent { transform: translate(-50%, calc((100 - var(--progress)) * .06px)); }
  .story { min-height: 88px; margin: 0 auto; padding: 0 10px; border-left: 0; }
  .story-kicker { margin-bottom: 6px; font-size: clamp(15px, 4.4vw, 18px); line-height: 1.2; }
  .story-body { font-size: clamp(9px, 2.7vw, 11px); line-height: 1.55; }
  .moon-field { order: 2; min-height: min(40vh, 330px); }
  .story { order: 3; }
  .moon { width: min(58vw, 270px); }
  .moon-scale { transform: none; }
  .moon-shadow { inset: -4%; box-shadow: 10px 0 18px rgba(255, 227, 174, .13); transition-duration: 100ms; }
  .moon-message { width: 76%; font-size: clamp(12px, 3.7vw, 17px); line-height: 1.3; }
  .orbit-one { width: 72%; }
  .orbit-two { width: 88%; }
  .control-panel { width: calc(100% - 52px); margin-top: 6px; }
  .slider-cta { gap: 8px; margin-bottom: 10px; font-size: 9px; letter-spacing: .09em; }
  .slider-cta svg { width: 24px; }
  .range-labels { font-size: 8px; letter-spacing: .07em; }
  .thumb-hint span { display: none; }
  footer { margin-top: 12px; justify-content: center; text-align: center; }
  .instruction { display: none; }
  footer p:first-child { max-width: 300px; }
  .ugc-form h2 { margin-bottom: 26px; }
  .ugc-actions, .completion-actions { flex-direction: column; gap: 8px; }
  .postcard { width: min(360px, 88vw, calc(68vh * 9 / 16)); }
  .postcard-logo { top: 4%; width: 34px; }
  .postcard-kicker { top: 18.5%; width: 88%; font-size: clamp(13px, 3.8vw, 16px); letter-spacing: .08em; }
  .postcard-message { top: 47%; width: 66%; max-height: 32%; overflow: hidden; font-size: clamp(21px, 5.8vw, 31px); line-height: 1.14; }
  .postcard-signoff { top: 72%; width: 82%; }
  .answer-board { width: calc(100vw - 24px); margin-top: 28px; padding: 30px 16px; }
  .answer-board h2 { font-size: clamp(25px, 8vw, 36px); line-height: 1.12; }
  .answer-board-intro { margin: 13px auto 24px; font-size: 10px; }
  .word-cloud { gap: 12px 15px; min-height: 220px; padding: 10px 0; }
  .word-cloud span { --mobile-cloud-size: clamp(12px, calc(var(--cloud-scale) * 1vw), 25px); flex: 0 1 auto; max-width: min(100%, 290px); font-size: var(--mobile-cloud-size); line-height: 1.22; }
}

@media (max-width: 380px) {
  .experience { padding-right: 14px; padding-left: 14px; }
  .moon-field { min-height: min(37vh, 290px); }
  .answer-board { width: calc(100vw - 16px); padding-right: 12px; padding-left: 12px; }
  .word-cloud { gap: 10px 12px; }
  .word-cloud span { max-width: 260px; }
  .control-panel { width: calc(100% - 44px); }
  .slider-cta { font-size: 8px; }
}

@media (max-height: 680px) and (min-width: 761px) {
  .experience { padding-top: 20px; padding-bottom: 18px; }
  .stage { padding: 16px 0; }
  .moon-field { min-height: 380px; }
  .story { margin-top: 18px; }
  footer { margin-top: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
