/* messy.here: the playhound page. Calm version: the app's own colours, Geist throughout, Fredoka only for the wordmark. */

@font-face { font-family: "Fredoka"; src: url("/assets/fonts/fredoka.woff2") format("woff2"); font-weight: 500 700; font-display: swap; }
@font-face { font-family: "Geist"; src: url("/assets/fonts/geist.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }

:root {
  --bg: #08080a;
  --bg-2: #0e0e12;
  --surface: #121217;
  --surface-2: #17171d;
  --text: #ececf1;
  --muted: rgba(236, 236, 241, .62);
  --faint: rgba(236, 236, 241, .42);
  --border: rgba(255, 255, 255, .08);
  --border-2: rgba(255, 255, 255, .14);
  --accent: #d946ef;
  --accent-ink: #f0abfc;
  --accent-soft: rgba(217, 70, 239, .14);
  --on-accent: #fff;
  --ok: #4ade80;
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, .8), 0 2px 8px rgba(0, 0, 0, .35);
  --radius: 14px;
  --wrap: 1120px;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root {
    --bg: #f3f3f6;
    --bg-2: #ebebf0;
    --surface: #ffffff;
    --surface-2: #f7f7fa;
    --text: #17171c;
    --muted: rgba(23, 23, 28, .64);
    --faint: rgba(23, 23, 28, .46);
    --border: rgba(23, 23, 28, .09);
    --border-2: rgba(23, 23, 28, .16);
    --accent: #a21caf;
    --accent-ink: #86198f;
    --accent-soft: rgba(162, 28, 175, .09);
    --ok: #15803d;
    --shadow: 0 24px 50px -28px rgba(23, 23, 28, .45), 0 2px 6px rgba(23, 23, 28, .08);
    color-scheme: light;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -.02em; font-weight: 650; }
p { margin: 0; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i, .fi { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.i { width: 16px; height: 16px; }

.wrap { width: 100%; max-width: var(--wrap); margin-left: auto; margin-right: auto; padding-left: 24px; padding-right: 24px; }
section { padding: 72px 0 0; }

/* ── header ── */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-in { display: flex; align-items: center; gap: 28px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 600 21px/1 "Fredoka", "Geist", sans-serif; letter-spacing: -.01em; }
.nav nav { display: flex; gap: 22px; margin-left: auto; }
.nav nav a { text-decoration: none; color: var(--muted); font-size: 14.5px; transition: color .15s; }
.nav nav a:hover { color: var(--text); }

/* ── buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: 10px;
  font: 600 15px/1 "Geist", sans-serif; text-decoration: none; white-space: nowrap;
  border: 1px solid transparent;
  transition: background-color .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.btn small { font-weight: 500; font-size: 12.5px; opacity: .7; }
.btn.sm { height: 34px; padding: 0 13px; font-size: 13.5px; border-radius: 8px; }
.btn.primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 8px 24px -10px var(--accent); }
.btn.primary:hover { background: color-mix(in srgb, var(--accent) 88%, #fff); transform: translateY(-1px); }
.btn.ghost { background: var(--surface); border-color: var(--border-2); color: var(--text); }
.btn.ghost:hover { border-color: color-mix(in srgb, var(--accent) 55%, var(--border-2)); }
@media (prefers-color-scheme: light) {
  .btn.primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
}

/* ── hero ── */
.hero {
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); gap: 56px; align-items: center;
  padding-top: 72px; padding-bottom: 8px;
}
.chip {
  display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 6px 13px 6px 11px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--muted); font-size: 13px; line-height: 1.3;
}
.chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 22%, transparent); }
.chip #ver { color: var(--text); font-weight: 600; }
.chip .sep { opacity: .5; }
h1 { margin-top: 20px; font-size: clamp(36px, 5.2vw, 58px); line-height: 1.04; letter-spacing: -.035em; font-weight: 700; text-wrap: balance; }
.lede { margin-top: 20px; max-width: 34em; font-size: 18px; line-height: 1.6; color: var(--muted); }
.ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 22px 0 0; padding: 0; list-style: none; font-size: 14px; color: var(--muted); }
.facts li { display: flex; align-items: center; gap: 7px; }
.facts .i { color: var(--ok); width: 15px; height: 15px; stroke-width: 2.2; }

.shot { border-radius: var(--radius); border: 1px solid var(--border-2); box-shadow: var(--shadow); background: #0e0d12; }
.hero-shot { position: relative; justify-self: center; width: 100%; max-width: 500px; padding-right: 150px; }
.hero-shot::before {
  content: ""; position: absolute; inset: 8% 4% 2% -8%; z-index: -1;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 30%, transparent), transparent);
  filter: blur(30px); opacity: .7;
}
.shot-scripts { width: 100%; }
.shot-emu { position: absolute; right: 0; bottom: -40px; width: 58%; border-color: color-mix(in srgb, var(--accent) 40%, var(--border-2)); background: transparent; }

/* ── timeline strip ── */
.timeline { padding-top: 64px; }
.timeline figure { margin: 0; }
.timeline .shot { width: 100%; }
.timeline figcaption { margin: 14px auto 0; max-width: 46em; text-align: center; font-size: 14px; color: var(--faint); }

/* ── section heads ── */
.head { max-width: 40em; margin-bottom: 32px; }
.head h2, .spot h2, .trust h2 { font-size: clamp(26px, 3.2vw, 36px); letter-spacing: -.03em; }
.head p { margin-top: 10px; color: var(--muted); font-size: 17px; }
.eyebrow { color: var(--accent-ink); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 12px; }

/* ── features ── */
.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.features article { background: var(--bg-2); padding: 26px 24px 28px; }
.features .fi { width: 22px; height: 22px; color: var(--accent-ink); }
.features h3 { margin-top: 14px; font-size: 16.5px; letter-spacing: -.01em; }
.features p { margin-top: 7px; font-size: 14.5px; line-height: 1.58; color: var(--muted); }

.more { display: none; }

/* ── spotlight rows ── */
.spot { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; padding-top: 96px; }
.spot.flip .spot-copy { order: 2; }
.spot-copy p { color: var(--muted); font-size: 16.5px; }
.spot-copy h2 + p { margin-top: 16px; }
.spot-copy p + p { margin-top: 14px; }
.spot-shot { display: flex; justify-content: center; }
.spot-shot .shot { width: 100%; max-width: 420px; }
.spot-shot .shot.tall { max-width: 360px; aspect-ratio: 464 / 824; object-fit: cover; object-position: top; }

/* the face: a CYD in its printed case, the screen drawn by assets/face.js */
.cyd { margin: 0; width: 100%; max-width: 460px; }
.cyd-case {
  position: relative; border-radius: 26px; padding: 8.5% 7.5% 8.5% 12.5%;
  background:
    repeating-linear-gradient(0deg, rgba(70, 52, 24, .075) 0 1px, rgba(255, 255, 255, .05) 1px 2px, transparent 2px 3px),
    radial-gradient(130% 110% at 26% 0%, #f2ecdf, #ded4bf 55%, #cdc1a7);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, .8),
    inset 0 -4px 8px rgba(90, 66, 30, .22),
    inset 5px 0 10px rgba(255, 255, 255, .25),
    0 12px 0 #b2a385,
    0 12px 0 1px rgba(80, 60, 28, .3),
    0 44px 56px -22px rgba(0, 0, 0, .75);
}
.cyd-ldr {
  position: absolute; left: 4.6%; top: 55%; width: 3.6%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at 42% 36%, #5a4634, #140e0a 72%);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .75), 0 -1px 0 rgba(90, 66, 30, .35), 0 1px 0 rgba(255, 255, 255, .6);
}
.cyd-glass {
  position: relative; padding: 2.4% 4.2% 2.4% 2.4%; border-radius: 3px; background: #0a0a0c;
  box-shadow:
    0 0 0 1px rgba(60, 44, 20, .5),
    0 -3px 0 3px rgba(120, 92, 50, .3),
    0 3px 0 3px rgba(255, 255, 255, .55),
    0 0 0 4px rgba(150, 125, 85, .35);
}
.cyd-glass::after {
  content: ""; position: absolute; inset: 0; border-radius: 3px; pointer-events: none;
  background: linear-gradient(116deg, rgba(255, 255, 255, .14) 0%, rgba(255, 255, 255, .04) 36%, transparent 36.5%);
}
.cyd-screen { position: relative; }
.cyd-screen::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 16px rgba(30, 16, 50, .22); }
.cyd canvas {
  display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; image-rendering: pixelated;
  background: #f0eef6 url("/assets/img/shots/face-still.png") center / 100% 100% no-repeat;
}
.cyd figcaption { margin-top: 32px; text-align: center; }
.moods { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.moods span {
  padding: 3px 10px; border-radius: 999px; font-size: 12.5px; color: var(--faint);
  border: 1px solid var(--border); transition: color .3s, background-color .3s, border-color .3s;
}
.moods span.on { color: var(--accent-ink); background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
.cyd-note { display: block; margin-top: 10px; font-size: 12.5px; color: var(--faint); }
.ticks { margin: 20px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 26px; color: var(--muted); font-size: 15px; }
.ticks li::before {
  content: ""; position: absolute; left: 2px; top: .42em; width: 13px; height: 13px; border-radius: 4px;
  background: var(--accent-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 45%, transparent);
}
.ticks li::after {
  content: ""; position: absolute; left: 6px; top: calc(.42em + 3px); width: 3px; height: 6px;
  border: solid var(--accent-ink); border-width: 0 1.6px 1.6px 0; transform: rotate(45deg);
}

/* ── devices ── */
section#devices { padding-top: 104px; }
.devices { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.devices > div { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 20px 20px 22px; }
.devices h3 { font-size: 15.5px; letter-spacing: -.01em; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.devices p { margin-top: 8px; font-size: 14px; line-height: 1.55; color: var(--muted); }
.tag { font-size: 11px; font-weight: 600; letter-spacing: .02em; padding: 2px 7px; border-radius: 999px; color: var(--accent-ink); background: var(--accent-soft); }

/* ── plugins ── */
.plugins { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.plug {
  display: flex; gap: 14px; align-items: flex-start; padding: 16px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--border); text-decoration: none;
  transition: border-color .15s, transform .15s;
}
.plug:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border-2)); transform: translateY(-1px); }
.plug img, .plug i { width: 44px; height: 44px; border-radius: 11px; flex: none; }
.plug i {
  display: grid; place-items: center; font: 600 14px/1 "Geist", sans-serif; font-style: normal; letter-spacing: .02em;
  color: var(--accent-ink); background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 28%, transparent);
}
.plug span { font-size: 13.5px; line-height: 1.5; color: var(--muted); }
.plug b { display: block; margin-bottom: 2px; font-size: 15px; font-weight: 600; color: var(--text); }
.plug.own { border-style: dashed; border-color: var(--border-2); background: transparent; }
.plug.own i { font-size: 22px; font-weight: 400; }

/* ── safety / privacy ── */
.trust { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; padding-top: 104px; }
.trust > div { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 30px 30px 32px; }
.trust h2 { font-size: 24px; }
.trust > div > p { margin-top: 10px; color: var(--muted); }

/* ── download ── */
section#download { padding-top: 104px; }
.ways { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "web app" "src app"; grid-template-rows: auto 1fr; gap: 16px; align-items: start; }
.way.web { grid-area: web; }
.way.main { grid-area: app; }
.way.src { grid-area: src; }
.way { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; }
.way.main { border-color: color-mix(in srgb, var(--accent) 45%, var(--border-2)); box-shadow: 0 0 0 4px var(--accent-soft); }
.way h3 { font-size: 18px; }
.way > p { margin-top: 8px; color: var(--muted); font-size: 14.5px; }
.way .btn { margin-top: 20px; width: 100%; }
.files { margin: 16px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--border); }
.files li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.files a { text-decoration: none; color: var(--text); }
.files a:hover { color: var(--accent-ink); }
.files span { color: var(--faint); font-variant-numeric: tabular-nums; }
.way .fine { margin-top: 14px; font-size: 13px; color: var(--faint); }
.way .fine a { color: var(--muted); }
pre {
  margin: 18px 0 0; padding: 14px 16px; border-radius: 10px; background: var(--bg); border: 1px solid var(--border);
  font: 13px/1.7 ui-monospace, "Cascadia Code", "SF Mono", Menlo, Consolas, monospace; color: var(--muted);
  white-space: pre; overflow-x: auto; scrollbar-width: thin;
}

/* ── footer ── */
footer { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; margin-top: 104px; padding-top: 28px; padding-bottom: 40px; }
footer::before { content: ""; position: absolute; top: 0; left: 24px; right: 24px; border-top: 1px solid var(--border); }
.foot-brand { display: flex; align-items: center; gap: 8px; font: 600 17px/1 "Fredoka", "Geist", sans-serif; }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.foot-links a { color: var(--muted); text-decoration: none; font-size: 14px; }
.foot-links a:hover { color: var(--text); }
.foot-note { flex-basis: 100%; font-size: 13px; color: var(--faint); }

/* ── smaller screens ── */
@media (max-width: 980px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 56px; padding-top: 56px; }
  .hero-shot { max-width: 480px; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .devices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plugins { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spot { gap: 40px; }
  .ways { grid-template-columns: minmax(0, 1fr); grid-template-areas: "web" "app" "src"; max-width: 560px; }
}
@media (max-width: 760px) {
  section { padding-top: 64px; }
  .nav nav { display: none; }
  .nav .btn { margin-left: auto; }
  .hero { padding-top: 40px; }
  .lede { font-size: 16.5px; }
  .chip .plat, .chip .sep { display: none; }
  .ctas .btn { flex: 1 1 100%; }
  .hero-shot { padding-right: 96px; }
  .timeline { padding-top: 56px; }
  .timeline figure > div { overflow-x: auto; border-radius: var(--radius); scrollbar-width: thin; }
  .timeline .shot { width: 760px; max-width: none; }
  .features, .devices, .plugins, .trust { grid-template-columns: minmax(0, 1fr); }
  .features article { padding: 20px 20px 22px; }
  .features.collapsed article:nth-child(n+7) { display: none; }
  .more:not([hidden]) { display: flex; width: 100%; margin-top: 12px; }
  .features .fi { float: left; margin: 0 11px 0 0; width: 20px; height: 20px; }
  .features h3 { margin-top: 0; line-height: 20px; }
  .devices > div { padding: 16px 18px 18px; }
  .plug { padding: 14px; }
  .spot { grid-template-columns: minmax(0, 1fr); padding-top: 72px; }
  .spot.flip .spot-copy { order: 0; }
  section#devices, .trust, section#download { padding-top: 72px; }
  .trust > div { padding: 24px; }
  footer { margin-top: 72px; }
}

/* ── 404 ── */
.lost { min-height: calc(100vh - 220px); display: flex; flex-direction: column; justify-content: center; padding-top: 72px; padding-bottom: 72px; }
.lost h1 { margin-top: 14px; }
.lost .lede { margin-top: 16px; }
