/* trainything.ryanrinkel.online — one page. Tokens are the reviewer UI's (src/ui/styles.css). */
:root {
  color-scheme: light dark;
  --bg: #f6f6f4; --panel: #ffffff; --fg: #16161a; --muted: #6a6a73; --line: #e3e3de;
  --accent: #2b5fd9; --link: #1f52c4; --accept: #1a7a4b; --reject: #b23a2f; --notice: #fdf6e3;
  --shadow: rgba(0,0,0,.08); --on-accent: #ffffff; --reject-ink: #b23a2f;
  /* aliases the gesture drawings (copied from the modes plan) expect */
  --ink-3: var(--muted); --accent-ink: var(--link); --on-bar: #ffffff;
  --accent-soft: color-mix(in srgb, var(--accent) 14%, transparent);
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121215; --panel: #1b1b20; --fg: #eeeef2; --muted: #9a9aa4; --line: #2e2e36;
    --accent: #6c8cf5; --link: #93aefb; --accept: #2f9c62; --reject: #d1584a; --notice: #2a2418;
    --shadow: rgba(0,0,0,.5); --on-accent: #0f1116; --reject-ink: #e47b6f;
  }
}
:root[data-theme="dark"] {
  --bg: #121215; --panel: #1b1b20; --fg: #eeeef2; --muted: #9a9aa4; --line: #2e2e36;
  --accent: #6c8cf5; --link: #93aefb; --accept: #2f9c62; --reject: #d1584a; --notice: #2a2418;
  --shadow: rgba(0,0,0,.5); --on-accent: #0f1116; --reject-ink: #e47b6f;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-decoration: none; border-bottom: 1px solid var(--line); }
a:hover { border-bottom-color: var(--link); }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
code, kbd, pre { font-family: var(--mono); }
code { font-size: .9em; background: var(--panel); border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; }
pre { margin: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; font-size: 13px; line-height: 1.55; overflow-x: auto; color: var(--fg); }
pre .c { color: var(--muted); }
pre .k { color: var(--link); font-weight: 600; }
pre .ok { color: var(--accept); font-weight: 600; }
pre .no { color: var(--reject-ink); font-weight: 600; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
h2 { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin: 0 0 18px; }
p { margin: 0 0 12px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; }
.brand { font-weight: 700; font-size: 18px; letter-spacing: -.01em; border: 0; color: var(--fg); }
.brand b { color: var(--accent); font-weight: 700; }
.top a.mail { font-size: 14px; color: var(--muted); border-bottom-color: transparent; }
.top a.mail:hover { color: var(--link); }

/* hero */
.hero { padding: 36px 0 28px; }
.hero h1 { font-size: clamp(30px, 5.2vw, 50px); font-weight: 750; max-width: 22ch; }
.hero .sub { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 44ch; margin: 16px 0 26px; }
.cmd { display: inline-flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; margin: 0 0 18px; }
.cmd code { background: none; border: 0; padding: 0; font-size: 16px; }
.cmd code .p { color: var(--muted); }
.pill { font: 600 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 5px 9px; white-space: nowrap; }
.pill.live { color: var(--accept); border-color: color-mix(in srgb, var(--accept) 45%, transparent); }
button.copy { font: 600 13px/1 system-ui, sans-serif; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; cursor: pointer; }
button.copy:hover { border-color: var(--accent); }

/* form */
.join { max-width: 560px; }
.join .row { display: flex; gap: 8px; flex-wrap: wrap; }
.join input[type=email] { flex: 1 1 220px; min-width: 0; font: inherit; font-size: 16px; color: var(--fg); background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; min-height: 48px; }
.join button[type=submit] { font: 600 16px/1 system-ui, sans-serif; color: var(--on-accent); background: var(--accent); border: 0; border-radius: 8px; padding: 0 18px; min-height: 48px; cursor: pointer; }
.join button[type=submit]:hover { filter: brightness(1.06); }
.join .check { display: flex; align-items: flex-start; gap: 10px; margin: 12px 0 6px; font-size: 15px; cursor: pointer; }
.join .check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.join .fine { font-size: 13.5px; color: var(--muted); margin: 6px 0 0; }
.join .thanks { display: none; font-size: 16px; color: var(--accept); font-weight: 600; margin: 8px 0 0; }
.join.done .row, .join.done .check, .join.done .fine { display: none; }
.join.done .thanks { display: block; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* the hero: words, command, form and the agent's side on the left; the reviewer's phone on the right */
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; gap: 30px 40px; align-items: start; }
.hero-text { min-width: 0; grid-column: 1; grid-row: 1; }
pre.agent { font-size: 12.5px; grid-column: 1; grid-row: 2; min-width: 0; }
.phone { grid-column: 2; grid-row: 1 / span 2; margin: 0; }
.phone { width: min(300px, 78vw); aspect-ratio: 390 / 844; border: 1px solid var(--line); border-radius: 28px; background: var(--panel); box-shadow: 0 12px 40px var(--shadow); overflow: hidden; position: relative; justify-self: end; align-self: center; }
.phone video, .phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.phone .poster { display: none; }
@media (prefers-reduced-motion: reduce) { .phone video { display: none; } .phone .poster { display: block; } }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero-text, pre.agent, .phone { grid-column: 1; }
  .hero-text { grid-row: 1; } .phone { grid-row: 2; justify-self: center; width: min(260px, 70vw); } pre.agent { grid-row: 3; }
}

/* sections */
section { padding: 44px 0 8px; border-top: 1px solid var(--line); margin-top: 36px; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px; min-width: 0; }
.step .n { font: 600 12px/1 var(--mono); color: var(--accent); letter-spacing: .08em; margin: 0 0 8px; }
.step h3 { font-size: 17px; margin: 0 0 8px; }
.step pre { font-size: 12px; padding: 10px 12px; margin-top: 10px; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

.family { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.mode { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 14px 12px 12px; min-width: 0; }
.mode svg { display: block; width: 100%; height: auto; max-width: 148px; margin: 0 auto 10px; }
.mode .name { font: 600 14px/1.2 var(--mono); color: var(--link); margin: 0 0 4px; }
.mode .does { font-size: 14px; margin: 0 0 4px; }
.mode .yield { font: 600 11px/1.35 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 0; }
@media (max-width: 900px) { .family { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .family { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.kinds { margin: 18px 0 0; font-size: 16px; color: var(--muted); }
.kinds b { color: var(--fg); font-weight: 600; }

.stories { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.story { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; }
.story h3 { font-size: 17px; margin: 0 0 8px; }
.story p { margin: 0; font-size: 15.5px; }
@media (max-width: 760px) { .stories { grid-template-columns: 1fr; } }

.thesis { font-size: clamp(20px, 2.6vw, 26px); font-weight: 700; letter-spacing: -.01em; margin: 0 0 20px; }
.tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.tier { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 18px; display: flex; flex-direction: column; min-width: 0; }
.tier.cloud { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.tier h3 { font-size: 16px; margin: 0 0 4px; }
.tier .price { font-size: 26px; font-weight: 750; letter-spacing: -.02em; margin: 0 0 12px; }
.tier .price small { font-size: 14px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.tier p { font-size: 15px; margin: 0 0 14px; }
.tier .foot { margin-top: auto; font-size: 14px; color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.tier .foot code { font-size: 13px; }
.licence { margin: 18px 0 0; font-size: 14.5px; color: var(--muted); }
@media (max-width: 760px) { .tiers { grid-template-columns: 1fr; } }

footer { border-top: 1px solid var(--line); margin-top: 44px; padding: 22px 0 40px; font-size: 14px; color: var(--muted); display: flex; gap: 8px 22px; flex-wrap: wrap; justify-content: space-between; }
footer a { color: var(--muted); border-bottom-color: transparent; }
footer a:hover { color: var(--link); }
