/* Hexwick website. The same fireside look as the app (app/src/theme.ts):
   deep charcoal, candlelight amber, ember orange, soft cream text.
   Big, high-contrast text throughout. Text sits in soft clouds of smoke sized to its
   words; buttons and form controls keep ordinary edges so they're easy to find.
   With "reduce motion" on, nothing moves: things only fade. */

@font-face { font-family: "Fell"; src: url("/assets/fonts/fell-italic.woff2") format("woff2"); font-style: italic; font-display: swap; }
@font-face { font-family: "Spectral"; src: url("/assets/fonts/spectral-400.woff2") format("woff2"); font-display: swap; }

:root {
  --bg: #1f1510;          /* the app's background */
  --bar: #140d09;         /* the app's top bar */
  --ink: #f5ebdd;         /* soft cream text */
  --muted: #d8c9b6;       /* secondary text (lighter than the app's, for small print on the web) */
  --amber: #f2a93b;       /* candlelight amber: main buttons */
  --on-amber: #1f1510;
  --gold: #f7c766;        /* glowing headings */
  --ember: #e8743b;
  --danger: #ffb4a6;
  --line: #6b5240;
  --smoke-core: 24 17 13; /* the dark heart of a cloud, so words stay crisp */
  --smoke-haze: 165 146 132;
  --gutter: clamp(1rem, 5vw, 2.5rem);
  --measure: 38rem;
  color-scheme: dark;
}

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

html {
  /* 20px text on phones, growing a little on big screens; respects the reader's own text size. */
  font-size: clamp(125%, 1.05rem + 0.45vw, 150%);
  background: var(--bar);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  min-height: 100vh;
  font-family: "Spectral", Georgia, "Times New Roman", serif;
  line-height: 1.55;
  color: var(--ink);
  /* Deep warm brown, a little warmer towards the fire below. The change from top to bottom is
     gentle, so the gold words, buttons and firelight stand out against it. */
  background: linear-gradient(#120a06, #180d08 18%, #22120a 55%, #2e170b);
  background-attachment: fixed;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; }
a { color: var(--gold); text-underline-offset: 0.18em; text-decoration-thickness: 0.08em; }
a:hover { color: #ffe0a0; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
.defs { position: absolute; width: 0; height: 0; overflow: hidden; }
[hidden] { display: none !important; }
/* The waitlist's honeypot: off-screen, for bots only (it's also hidden from screen readers). */
.trap { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 0.75rem; top: -5rem; z-index: 50;
  padding: 0.7rem 1rem; background: var(--amber); color: var(--on-amber); font-weight: 700; border-radius: 10px;
}
.skip:focus { top: 0.75rem; color: var(--on-amber); }

/* ---- The room: a hearth glowing under a cauldron, behind everything ------------------
   Firelight from below that swells and settles like slow breathing (one breath takes
   about ten seconds, and the change is small: there is no flicker). A little pale steam
   and a few slow embers rise through it. Only opacity and position ever change, which a
   phone can do without redrawing anything, so the page stays smooth. */
.stage { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
/* The fire itself, just out of sight under the bottom edge. */
.stage .fire {
  position: absolute; left: -10%; right: -10%; bottom: 0; height: 64vh; transform-origin: 50% 100%;
  background:
    radial-gradient(ellipse 58% 100% at 50% 100%, rgb(240 128 54 / 0.22), rgb(214 92 34 / 0.09) 46%, transparent 74%),
    linear-gradient(rgb(214 96 40 / 0), rgb(214 96 40 / 0.05) 50%, rgb(226 108 42 / 0.16));
  animation: hearth 10s ease-in-out infinite;
}
/* Its light climbing the middle of the room, a breath behind the fire. */
.stage .rise {
  position: absolute; left: 50%; bottom: 0; width: min(120vw, 70rem); height: 100vh; margin-left: max(-60vw, -35rem);
  transform-origin: 50% 100%;
  background: radial-gradient(ellipse 50% 78% at 50% 100%, rgb(255 170 92 / 0.09), rgb(240 140 70 / 0.035) 55%, transparent 76%);
  animation: hearth 10s ease-in-out -9.4s infinite;
}
@keyframes hearth {
  0%, 100% { opacity: 0.86; transform: scale3d(1, 1, 1); }
  46% { opacity: 1; transform: scale3d(1.015, 1.04, 1); }
}
.haze {
  position: absolute; border-radius: 50%;
  /* Light, see-through wisps, lit warm by the fire. */
  background: radial-gradient(closest-side, rgb(255 214 184 / 0.08), rgb(255 196 156 / 0.035) 55%, transparent);
  animation: haze-drift var(--d, 46s) ease-in-out infinite alternate;
}
.haze.a { width: 90vmax; height: 46vmax; left: -30vmax; top: 6vh; --d: 52s; }
.haze.b { width: 80vmax; height: 40vmax; right: -34vmax; top: 38vh; --d: 64s; animation-delay: -20s; }
.haze.c { width: 70vmax; height: 36vmax; left: -10vmax; bottom: -8vmax; --d: 58s; animation-delay: -35s; }
@keyframes haze-drift {
  from { transform: translate3d(-4vw, 1.5vh, 0) scale(1); }
  to { transform: translate3d(6vw, -3vh, 0) scale(1.12); }
}

/* Steam off the cauldron: three pale wisps, one at a time, rising slowly and thinning out. */
.wisps i {
  position: absolute; left: var(--x); bottom: -30vmin;
  width: var(--w, 26vmin); height: var(--h, 58vmin); border-radius: 50%;
  background:
    radial-gradient(ellipse 46% 40% at 44% 64%, rgb(255 232 212 / 0.17), transparent 72%),
    radial-gradient(ellipse 38% 46% at 58% 36%, rgb(255 224 200 / 0.13), transparent 72%);
  filter: url(#smoke-b);
  opacity: 0; will-change: transform, opacity;
  animation: wisp-rise var(--t, 38s) linear infinite;
  animation-delay: var(--d, 0s);
}
.wisps i:nth-child(1) { --x: 30%; --t: 40s; --d: -6s; --dx: 5vw; --turn: 7deg; }
.wisps i:nth-child(2) { --x: 56%; --t: 46s; --d: -24s; --dx: -6vw; --turn: -9deg; --w: 30vmin; --h: 66vmin; }
.wisps i:nth-child(3) { --x: 43%; --t: 52s; --d: -39s; --dx: 3vw; --turn: 5deg; --w: 22vmin; --h: 52vmin; }
@keyframes wisp-rise {
  0% { transform: translate3d(0, 0, 0) rotate(0deg) scale(0.8); opacity: 0; }
  14% { opacity: 1; }
  62% { opacity: 0.7; }
  100% { transform: translate3d(var(--dx, 4vw), -96vh, 0) rotate(var(--turn, 6deg)) scale(1.7); opacity: 0; }
}

/* Embers: a few small sparks lifting off the hearth behind the candles, slowly, cooling as they
   climb. They live only in the band between the logo and the tagline, so they never drift
   across words. Each sways a little on its way up, and glows steadily: nothing flickers.
   (Each <i> is a column as tall as the band; moving it up by its own height carries its spark,
   drawn at its foot, from the bottom of the band to the top.) */
.embers { position: absolute; z-index: -1; left: -45%; right: -45%; top: var(--ember-top, 34%); bottom: var(--ember-bottom, 26%); pointer-events: none; }
.embers i {
  position: absolute; left: var(--x); bottom: 0; width: 4px; height: 100%;
  opacity: 0; will-change: transform, opacity;
  animation: ember-rise var(--t, 11s) linear infinite, ember-sway var(--sw, 6s) ease-in-out infinite alternate;
  animation-delay: var(--w, 0s), var(--w, 0s);
}
.embers i::before {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: var(--s, 3px); height: var(--s, 3px); border-radius: 50%;
  background: #ffe7bd;
  box-shadow: 0 0 4px 1px rgb(255 176 84 / 0.7), 0 0 11px 3px rgb(255 122 40 / 0.26);
}
.embers i:nth-child(1) { --x: 5%; --t: 12s; --w: -2s; --sway: 14px; --sw: 6.5s; }
.embers i:nth-child(2) { --x: 15%; --t: 10s; --w: -7s; --sway: -12px; --sw: 5.5s; --s: 2px; }
.embers i:nth-child(3) { --x: 25%; --t: 13s; --w: -4s; --sway: 16px; --sw: 7s; --s: 4px; }
.embers i:nth-child(4) { --x: 74%; --t: 11s; --w: -9s; --sway: -15px; --sw: 6s; }
.embers i:nth-child(5) { --x: 85%; --t: 12.5s; --w: -5s; --sway: 11px; --sw: 5.8s; --s: 2px; }
.embers i:nth-child(6) { --x: 95%; --t: 14s; --w: -11s; --sway: -13px; --sw: 7.5s; }
@keyframes ember-rise {
  0% { transform: translate3d(0, 0, 0); opacity: 0; }
  12% { opacity: 0.75; }
  55% { opacity: 0.5; }
  100% { transform: translate3d(0, -100%, 0); opacity: 0; }
}
@keyframes ember-sway { from { translate: 0 0; } to { translate: var(--sway, 12px) 0; } }

/* ---- Smoke clouds: text boxes with no outline or corners, sized to their words ------- */
.cloud {
  position: relative; isolation: isolate;
  width: fit-content; max-width: 100%;
  margin-inline: auto;
  padding: 0.9em 1.3em;
  text-shadow: 0 1px 3px rgb(20 10 6 / 0.85);
}
.cloud::before, .cloud::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
}
/* The body of the cloud: pale, see-through smoke with ragged edges, lit warm from below.
   It's only just thick enough for the cream words to stay easy to read. */
.cloud::before {
  inset: -0.55em -0.75em;
  border-radius: 2.6em;
  background: linear-gradient(rgb(72 50 40 / 0.4), rgb(70 42 28 / 0.5));
  filter: url(#smoke-a);
}
/* Brighter wisps round it, slowly drifting. */
.cloud::after {
  inset: -1.5em -1.9em;
  border-radius: 50%;
  background:
    radial-gradient(42% 60% at 22% 30%, rgb(255 232 214 / 0.2), transparent 70%),
    radial-gradient(40% 55% at 80% 68%, rgb(255 214 184 / 0.17), transparent 70%),
    radial-gradient(60% 70% at 50% 50%, rgb(40 24 16 / 0.3), transparent 72%);
  filter: url(#smoke-b);
  z-index: -2;
  animation: cloud-drift 19s ease-in-out infinite alternate;
}
.cloud.v2::before { filter: url(#smoke-b); border-radius: 3em 2.2em 2.8em 2.4em; }
.cloud.v2::after { filter: url(#smoke-c); animation-duration: 24s; animation-delay: -9s; }
.cloud.v3::before { filter: url(#smoke-c); border-radius: 2.2em 3em 2.3em 2.9em; }
.cloud.v3::after { filter: url(#smoke-a); animation-duration: 28s; animation-delay: -15s; }
.cloud.warm::after {
  background:
    radial-gradient(42% 60% at 24% 34%, rgb(255 190 120 / 0.24), transparent 70%),
    radial-gradient(40% 55% at 78% 66%, rgb(255 170 110 / 0.2), transparent 70%),
    radial-gradient(60% 70% at 50% 50%, rgb(40 24 16 / 0.3), transparent 72%);
}
@keyframes cloud-drift {
  from { transform: translate3d(-0.5em, 0.2em, 0) scale(1); }
  to { transform: translate3d(0.6em, -0.3em, 0) scale(1.06); }
}
.cloud > :first-child { margin-top: 0; }
.cloud > :last-child { margin-bottom: 0; }

/* ---- Layout -------------------------------------------------------------------------- */
.page { position: relative; z-index: 1; overflow-x: clip; }
.hero, main, .foot { padding-inline: var(--gutter); }
.doc-page main { padding-inline: clamp(1.2rem, 5vw, 2.6rem); margin-inline: max(0.75rem, calc(50% - 21rem)); }
/* The home page is kept short: sections follow each other closely, with little empty space. */
section { max-width: var(--measure); margin: 0 auto; padding-block: clamp(1rem, 3vh, 1.8rem); }
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; line-height: 1.2; margin: 0 0 0.6em; }
h2 { font-size: 1.7rem; color: var(--gold); text-align: center; text-shadow: 0 0 22px rgb(242 169 59 / 0.35); }
h3 { font-size: 1.2rem; color: var(--gold); margin-bottom: 0.25em; }
p { margin: 0 0 0.9em; }

/* ---- Hero ---------------------------------------------------------------------------- */
.hero {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding-top: clamp(0.75rem, 3vh, 2rem); padding-bottom: clamp(0.4rem, 1.5vh, 1rem);
  gap: clamp(0.55rem, 2.3vh, 1.6rem);
}
/* The logo is the centrepiece. On a phone the whole picture, frame lines and ™ included,
   fits inside the screen with a little space either side. */
.mark {
  --mark: min(94vw, 52rem, 78vh);
  position: relative; z-index: 0; flex: none; width: var(--mark); max-width: none;
  /* The picture has empty space above and below the lettering: tuck it up, and let the candles tuck under. */
  margin: calc(var(--mark) * -0.07) 0 0;
}
/* Behind the logo: a soft, dark shadow so the fiery lettering stands out, fading smoothly to
   nothing well before its own edges (so there's never a line), with a faint warm glow at its
   heart that breathes with the hearth, a moment after it. */
.mark::before, .mark::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
}
.mark::before {
  inset: -16% -10% -14%;
  background: radial-gradient(closest-side, rgb(10 5 3 / 0.72), rgb(10 5 3 / 0.55) 40%, rgb(10 5 3 / 0.24) 70%, rgb(10 5 3 / 0.07) 88%, rgb(10 5 3 / 0));
}
.mark::after {
  inset: 18% 20% 14%;
  background: radial-gradient(closest-side, rgb(255 150 64 / 0.16), rgb(255 130 50 / 0.06) 60%, rgb(255 130 50 / 0));
  animation: glow-breathe 10s ease-in-out -8.5s infinite;
}
@keyframes glow-breathe {
  0%, 100% { opacity: 0.84; transform: scale3d(1, 1, 1); }
  46% { opacity: 1; transform: scale3d(1.025, 1.025, 1); }
}
.mark img {
  display: block; width: 100%;
  -webkit-mask-image: radial-gradient(ellipse 62% 64% at 50% 50%, #000 60%, transparent 100%);
  mask-image: radial-gradient(ellipse 62% 64% at 50% 50%, #000 60%, transparent 100%);
}
.candle {
  --candle: min(80vw, 38vh, 25rem);
  position: relative; flex: none; width: var(--candle);
  /* The picture fades out round its edge, so it can sit close under the logo and over the tagline. */
  margin-block: calc(var(--candle) * -0.33) calc(var(--candle) * -0.2);
}
.candle img {
  display: block; width: 100%;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 50%, transparent 70%);
  mask-image: radial-gradient(circle at 50% 50%, #000 50%, transparent 70%);
}
.candle .glow {
  position: absolute; inset: -22%; z-index: -1; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(255 138 42 / 0.3), rgb(255 138 42 / 0.1) 55%, transparent);
  animation: glow-breathe 10s ease-in-out -9.1s infinite;
}
.fx { position: absolute; inset: 0; pointer-events: none; }
.fx i { position: absolute; }
/* Soft light over each flame in the picture, so the candles flicker. */
.flame {
  transform-origin: 50% 100%;
  background: radial-gradient(ellipse 50% 50% at 50% 62%, rgb(255 238 196 / 0.6), rgb(242 169 59 / 0.28) 52%, transparent);
  animation: lick 4.3s ease-in-out infinite;
}
.flame.left { left: 39.6%; top: 22%; width: 8%; height: 17%; }
.flame.right { left: 51.4%; top: 22.4%; width: 7.6%; height: 16.6%; animation-duration: 5.1s; animation-delay: -1.7s; }
@keyframes lick {
  0%, 100% { opacity: 0.55; transform: scale(1, 1) skewX(0deg); }
  18% { opacity: 0.85; transform: scale(0.97, 1.05) skewX(1.4deg); }
  37% { opacity: 0.6; transform: scale(1.02, 0.97) skewX(-1deg); }
  58% { opacity: 0.95; transform: scale(0.96, 1.07) skewX(-1.6deg); }
  79% { opacity: 0.66; transform: scale(1.01, 0.99) skewX(0.8deg); }
}
.tagline {
  margin: 0; font-family: "Fell", Georgia, serif; font-style: italic;
  font-size: clamp(1.75rem, 6.2vw, 2.7rem); line-height: 1.15;
  color: var(--gold); text-shadow: 0 0 26px rgb(242 169 59 / 0.45), 0 2px 3px #000;
}
/* The line under the tagline, in its own small cloud of smoke that hugs the words:
   darker in the middle so the cream words stay crisp, thinning to pale wisps at the edges. */
.lede { font-size: 1.3rem; line-height: 1.42; margin-block: 0.3rem; padding: 0.5em 0.85em; text-wrap: balance; max-width: 12.9em; }
/* (The widths keep the box as wide as its longest line and no wider, so the smoke hugs the words:
   three lines on a phone, two on a tablet, one on a computer.) */
@media (min-width: 40rem) { .lede { font-size: 1.24rem; max-width: 19.5em; } }
@media (min-width: 62rem) { .lede { max-width: 100%; } }
.lede strong { color: var(--gold); font-weight: 400; white-space: nowrap; }
/* The shadowed heart of the smoke, close behind the words: a warm dark brown, so the cream
   words stay crisp. */
.cloud.lede::before {
  inset: 0.05em 0.1em;
  border-radius: 1.6em;
  background: radial-gradient(ellipse 60% 70% at 50% 50%, rgb(22 12 6 / 0.5), rgb(28 15 8 / 0.32) 60%, transparent);
  filter: blur(9px);
}
/* The smoke itself: a soft, see-through amber-brown haze, like smoke lit by the fire below,
   a little thicker round the edge of the words and thinning to nothing, drifting slowly. */
.cloud.lede::after {
  inset: -0.3em -0.3em -0.24em;
  border-radius: 2.2em;
  background:
    radial-gradient(ellipse 54% 56% at 50% 50%, transparent 34%, rgb(200 120 58 / 0.16) 76%, rgb(214 136 70 / 0.22)),
    rgb(150 84 38 / 0.08);
  filter: url(#smoke-fine);
  animation: cloud-drift 26s ease-in-out infinite alternate;
}

/* ---- Buttons and controls: ordinary edges, big and easy to hit --------------------- */
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.9rem; width: 100%; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  min-height: 3.4rem; padding: 0.75rem 1.6rem;
  font: 700 1.2rem/1.2 Georgia, "Times New Roman", serif;
  border-radius: 14px; border: 2px solid transparent; cursor: pointer; text-decoration: none;
  transition: background-color 0.2s, opacity 0.2s;
}
.btn.primary { background: var(--amber); color: var(--on-amber); box-shadow: 0 0 28px rgb(242 169 59 / 0.35); }
.btn.primary:hover { background: #ffc15a; color: var(--on-amber); }
.btn.ghost { background: rgb(20 13 9 / 0.85); color: var(--ink); border-color: var(--amber); }
.btn.ghost:hover { background: #3a2614; color: var(--ink); }
.btn[disabled] { opacity: 0.55; cursor: default; }
.btn svg { width: 1.2em; height: 1.2em; flex: none; }
@media (max-width: 30rem) { .actions .btn { width: 100%; } }
/* The slim "Join the waitlist" links (top and bottom of the page): a neat amber pill.
   Still at least 48px tall, so it's easy to tap. (The form's own button is unchanged.) */
.btn.slim {
  min-height: 2.6rem; padding: 0.4rem 2.1rem;
  font-size: 1rem; letter-spacing: 0.02em;
  border-radius: 999px;
  background: linear-gradient(#f8bd58, #eb9f30);
  box-shadow: 0 0 22px rgb(242 169 59 / 0.3), inset 0 1px 0 rgb(255 240 205 / 0.55), inset 0 -1px 0 rgb(120 62 10 / 0.25);
}
.btn.slim:hover { background: linear-gradient(#ffcb6e, #f4ad3e); }
@media (max-width: 30rem) { .actions .btn.slim { width: auto; min-width: 13rem; } }

/* ---- Hexey's captions: her words on screen, each phrase lighting up as it's spoken ---- */
.icon-stop, .is-playing .icon-play { display: none; }
.is-playing .icon-stop { display: block; }
.captions { text-align: center; margin-top: 0.6rem; }
.cap-who { margin: 0 0 0.15em; font-size: 0.9rem; color: var(--muted); letter-spacing: 0.04em; }
.cap-lines { margin: 0; font-family: "Fell", Georgia, serif; font-style: italic; font-size: 1.45rem; line-height: 1.35; max-width: 22em; }
.cap-lines span { color: rgb(245 235 221 / 0.5); transition: color 0.5s; }
.cap-lines span.said { color: var(--ink); }

/* ---- The waitlist form: ordinary boxes and edges, large and easy to see ------------- */
.intro { text-align: center; margin-bottom: 0.5rem; font-size: 1.1rem; }
.join { display: flex; flex-direction: column; gap: 0.5rem; max-width: 30rem; margin: 0.9rem auto 0; }
.join > label:not(.consent) { font-weight: 700; font-size: 1.1rem; }
.join input[type="email"] {
  width: 100%; min-height: 3.6rem; padding: 0.6rem 0.9rem;
  font: inherit; font-size: 1.2rem; color: var(--ink);
  background: #1c110b; border: 2px solid var(--amber); border-radius: 12px;
  box-shadow: 0 0 1.2rem rgb(242 169 59 / 0.18);
}
.join input[type="email"]::placeholder { color: rgb(245 235 221 / 0.5); font-style: italic; }
.join input[type="email"]:focus { border-color: var(--amber); outline: 3px solid rgb(242 169 59 / 0.45); outline-offset: 0; }
.join input[aria-invalid="true"] { border-color: var(--danger); }
.consent { display: flex; gap: 0.85rem; align-items: flex-start; margin: 0.9rem 0 0.4rem; cursor: pointer; }
/* The tick box: amber-edged, filling amber with a dark tick when checked. */
.consent input {
  -webkit-appearance: none; appearance: none;
  flex: none; width: 1.85rem; height: 1.85rem; margin: 0.1rem 0 0; cursor: pointer;
  background: #1c110b; border: 2px solid var(--amber); border-radius: 7px;
  box-shadow: 0 0 0.8rem rgb(242 169 59 / 0.18);
}
.consent input:checked {
  background: var(--amber) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%231f1510' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round' d='M5 12.5l4.6 4.6L19.2 7'/%3E%3C/svg%3E") center / 82% no-repeat;
}
.join .btn { width: 100%; margin-top: 0.6rem; min-height: 3.8rem; font-size: 1.35rem; }
.status { min-height: 1.6em; margin: 0.5rem 0 0; font-weight: 700; color: var(--gold); text-align: center; }
.status.is-error { color: var(--danger); }
/* The promise under the button: small, but cream on dark brown, so it stays easy to read. */
.promise {
  margin: 0 auto; max-width: 27rem; padding: 0.75rem 1rem;
  font-size: 0.88rem; line-height: 1.55; color: var(--muted); text-align: center; text-wrap: pretty;
  border-top: 1px solid rgb(242 169 59 / 0.28);
}
.promise strong { color: var(--gold); font-weight: 700; }
.preview-note { margin: 0.4rem 0 0; padding: 0.7rem 0.9rem; font-size: 0.9rem; color: var(--muted); border: 1px dashed var(--line); border-radius: 10px; }
#human:not(:empty) { margin-top: 0.4rem; }

.thanks { display: flex; flex-direction: column; align-items: center; gap: 2.4rem; text-align: center; margin-top: 2.2rem; outline: none; }
.thanks > .cloud, .thanks > .btn { opacity: 0; transition: opacity 1.4s ease-out 0.4s; }
.thanks.is-in > .cloud, .thanks.is-in > .btn { opacity: 1; }
.thanks h2, .thanks h3 { font-size: 1.6rem; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

/* ---- After a sign-up: the parchment, the wand and the cauldron ----- --------------- */
.ritual {
  position: fixed; inset: 0; z-index: 40; opacity: 0; pointer-events: none;
  background: radial-gradient(ellipse at 50% 70%, rgb(42 22 14 / 0.94), rgb(10 6 4 / 0.97) 70%);
  display: flex; align-items: center; justify-content: center;
}
.ritual-box { position: relative; width: min(92vw, 26rem); height: min(90vh, 40rem); }
.ritual-pot { position: absolute; inset: 0; width: 100%; height: 100%; }
.parchment {
  position: absolute; left: 50%; top: 0; width: min(78%, 17rem); opacity: 0; will-change: transform, opacity;
  /* The torn edge. The burning edge is cut to the same shape, so it never glows outside the paper. */
  clip-path: polygon(1% 6%, 9% 1%, 24% 4%, 41% 0, 58% 3%, 77% 0, 93% 4%, 100% 12%, 97% 33%, 100% 55%, 96% 78%, 99% 95%, 86% 100%, 66% 96%, 47% 100%, 27% 97%, 10% 100%, 0 93%, 3% 70%, 0 48%, 4% 26%);
}
.parchment-paper {
  padding: 1.15rem 1.1rem 1.25rem; text-align: center;
  font-family: "Fell", Georgia, serif; font-style: italic; font-size: 1.2rem; line-height: 1.25; color: #2e1a0c;
  overflow-wrap: anywhere;
  background:
    radial-gradient(ellipse at 30% 20%, rgb(255 244 214 / 0.55), transparent 60%),
    radial-gradient(ellipse at 85% 90%, rgb(120 78 36 / 0.45), transparent 55%),
    linear-gradient(170deg, #e3cfa3, #c9a96c 60%, #b08a4e);
  box-shadow: inset 0 0 1.2rem rgb(90 55 20 / 0.55);
}
.parchment-ember { position: absolute; inset: 0; pointer-events: none; mix-blend-mode: normal; }
/* The gnarled wand that lights the parchment, and its sparks. */
.wand { position: absolute; transform-origin: 50% 100%; opacity: 0; will-change: transform, opacity; filter: drop-shadow(0 6px 10px rgb(0 0 0 / 0.6)); }
.ritual-wand { left: 0; top: 0; width: 2.4rem; height: 13.6rem; }
.wand svg { display: block; width: 100%; height: 100%; overflow: visible; }
.wand-ember { animation: ember-pulse 0.9s ease-in-out infinite alternate; }
@keyframes ember-pulse { from { opacity: 0.65; } to { opacity: 1; } }
.wand-tip { position: absolute; left: 51.1%; top: 2%; width: 1px; height: 1px; }
.spark { position: absolute; border-radius: 50%; box-shadow: 0 0 6px 2px rgb(255 190 80 / 0.75); will-change: transform, opacity; pointer-events: none; }

/* The heart in the thank-you. It fades in (this is the only movement with reduce motion on). */
.thanks-heart { width: 6.5rem; height: auto; opacity: 0; transition: opacity 1.8s ease-out; filter: drop-shadow(0 0 1.2rem rgb(255 110 130 / 0.75)); }
.thanks.is-in .thanks-heart { opacity: 1; }

/* ---- What makes Hexwick different: the cauldron ------------------------------------- */
/* Four short numbered points: a tight list on a phone, two by two on a tablet, side by side on a computer. */
#different { max-width: 68rem; }
#different h2 { margin-bottom: 0.5em; }
.points {
  list-style: none; margin: 0 auto; padding: 0;
  display: grid; gap: 0.5rem; max-width: 30rem;
}
.points li {
  display: flex; align-items: flex-start; gap: 0.65rem;
  padding: 0.55rem 0.85rem; border-radius: 14px;
  font-size: 0.95rem; line-height: 1.38; text-align: left;
  background: rgb(22 14 10 / 0.5); box-shadow: inset 0 0 0 1px rgb(242 169 59 / 0.16);
  text-shadow: 0 1px 2px rgb(20 10 6 / 0.8);
}
.points .num {
  flex: none; display: grid; place-items: center; width: 1.7em; height: 1.7em; margin-top: -0.05em;
  border-radius: 50%; font: 700 0.85em/1 Georgia, "Times New Roman", serif;
  color: var(--on-amber); background: linear-gradient(#f8bd58, #eb9f30);
}
@media (min-width: 40rem) { .points { grid-template-columns: 1fr 1fr; max-width: 46rem; } }
@media (min-width: 62rem) { .points { grid-template-columns: repeat(4, 1fr); max-width: none; } .points li { font-size: 0.9rem; } }
/* Hexey's cauldron on its fire, small, with her button beside it (under it on a narrow phone). */
.hexey { display: flex; align-items: center; justify-content: center; gap: 0.4rem 1.2rem; flex-wrap: wrap; margin-top: 0.6rem; }
.cauldron {
  display: block; flex: none; width: clamp(8rem, 26vw, 9.5rem); aspect-ratio: 6 / 7;
  /* The steam's pink glow fades out softly at the top, and the fire's glow at the bottom, so
     neither ends in a straight line. */
  -webkit-mask-image: linear-gradient(transparent, #000 24%, #000 90%, transparent);
  mask-image: linear-gradient(transparent, #000 24%, #000 90%, transparent);
}
.hexey-play { min-height: 2.8rem; padding: 0.5rem 1.3rem; font-size: 1.05rem; }
#different .captions { margin-top: 0.6rem; }
#different .cap-lines { font-size: 1.3rem; }

/* ---- The long pages (Privacy, Terms, Delete my data): one calm, readable panel ------- */
.doc-head { text-align: center; padding: 0.5rem var(--gutter) 0; margin-bottom: -1.5rem; }
.doc-head a { display: inline-block; width: min(70%, 20rem); }
.doc-head img { display: block; width: 100%; -webkit-mask-image: radial-gradient(ellipse 62% 64% at 50% 50%, #000 60%, transparent 100%); mask-image: radial-gradient(ellipse 62% 64% at 50% 50%, #000 60%, transparent 100%); }
.doc {
  max-width: 42rem; margin: 0.5rem auto 2rem; padding: clamp(1.2rem, 5vw, 2.6rem);
  background: rgb(var(--smoke-core) / 0.82); border-radius: 2rem;
  box-shadow: 0 0 2.5rem 1.5rem rgb(var(--smoke-core) / 0.82);
}
.doc h1 { font-size: 2rem; color: var(--gold); margin-bottom: 0.2em; }
.doc h2 { text-align: left; font-size: 1.45rem; margin: 2.2em 0 0.5em; }
.doc h3 { margin: 1.5em 0 0.3em; }
.doc ul { padding-left: 1.3em; margin: 0 0 0.9em; }
.doc li { margin-bottom: 0.5em; }
.doc .updated { color: var(--muted); font-size: 0.95rem; }
.draft { padding: 0.9rem 1.1rem; border: 2px solid var(--amber); border-radius: 12px; background: #3a2614; color: #f3d9b1; }
.solicitor { padding: 0.7rem 1rem; border-left: 4px solid var(--ember); background: rgb(232 116 59 / 0.1); font-size: 0.95rem; color: var(--muted); }
.doc-nav { display: flex; flex-wrap: wrap; gap: 0.3rem 1.4rem; margin: 1rem 0; }
.doc-nav a, .doc a { overflow-wrap: anywhere; }
.unsubscribe { text-align: center; }

/* ---- Footer -------------------------------------------------------------------------- */
/* Small and quiet. (The links keep some padding so they're still easy to tap.) */
.foot {
  position: relative; z-index: 1; text-align: center; font-size: 0.7rem; color: rgb(216 201 182 / 0.75);
  padding-block: 0.6rem 1.2rem; background: linear-gradient(transparent, rgb(20 13 9 / 0.7) 45%);
}
.foot nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 0.7rem; margin-bottom: 0.15rem; font-size: 0.75rem; }
.foot nav a { display: inline-block; padding: 0.4rem 0.15rem; color: rgb(216 201 182 / 0.85); }
.foot nav a:hover { color: var(--gold); }
.foot p { margin: 0.1rem 0; }

/* ---- Reduce motion: nothing moves, things only fade ---------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; }
  .embers, .wisps { display: none; }
  .btn { transition: none; }
}
