/* The bot demo's layout; its look is the platform's (/platform.css, loaded after this). Green is decided alone and
   right, amber is "the bot asks you", red is decided alone and wrong. Labels never darker than #999. */

:root {
  --bg: #000000;
  --surface: #0d0d0d;
  --surface-2: #141414;
  --rail: #5a5a5a;
  --hair: #242424;
  --text: #ffffff;
  --text-2: #eaeaea;
  --text-3: #c8c8c8;
  --text-4: #a6a6a6;
  --accent: #ffffff;
  --accent-light: #eaeaea;
  --green: #6ee7b7;
  --green-line: #34d399;
  --green-bg: #002619;
  --amber: #fcd34d;
  --amber-bg: #2a1f00;
  --red: #fca5a5;
  --red-line: #f87171;
  --red-bg: #2b0a0a;
  --radius: 8px;
  --sans: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }

.kicker { margin: 0; font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); }
.kicker.dim { color: var(--text-4); }
.kicker.ask { color: var(--amber); }
.kicker.approve { color: var(--green); }
.kicker.reject { color: var(--text); }
.sub { margin: 0; font-family: var(--mono); font-size: 12px; line-height: 1.5; color: var(--text-4); }

.head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 28px; border-bottom: 1px solid var(--rail); }
.brand { display: flex; align-items: center; gap: 16px; }
.logo { height: 30px; display: block; }
.divider { width: 1px; height: 22px; background: var(--rail); }
.product { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.status { display: flex; align-items: center; gap: 12px; }

main { max-width: 1180px; margin: 0 auto; padding: 24px 28px 40px; display: flex; flex-direction: column; gap: 20px; }
.promise { margin: 0; padding: 12px 14px; border: 1px solid var(--rail); border-radius: var(--radius); background: var(--surface); font-size: 15px; line-height: 1.5; color: var(--text-2); }
.promise b { color: var(--text); font-weight: 600; }
.small { margin: 0; font-family: var(--mono); font-size: 12px; line-height: 1.6; color: var(--text-4); }

.panel { display: flex; flex-direction: column; gap: 16px; padding: 26px 28px 28px; border: 1px solid var(--rail); border-radius: 12px; background: var(--surface); min-width: 0; }
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.lede { margin: 0; max-width: 46rem; font-size: 17px; line-height: 1.55; color: var(--text-3); }
.hint { margin: 0; max-width: 46rem; font-size: 14px; line-height: 1.55; color: var(--text-3); }
.game { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }

/* The bot itself: the Glyphh cat with the mohawk (os/src/renderer/character.js, the "spiky" head). Big where the
   visitor meets it, small beside everything it says. */
.meet { align-items: center; text-align: center; gap: 18px; padding-top: 34px; padding-bottom: 34px; }
.meet .mascot { height: 148px; width: auto; }
.meet .say { max-width: 22rem; }
.meet .sub { max-width: 26rem; }
.meet .primary { min-width: 180px; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: flex; flex-direction: column; gap: 10px; text-align: left; font-size: 17px; color: var(--text-2); }
.steps li { counter-increment: step; display: flex; align-items: baseline; gap: 12px; }
.steps li::before { content: counter(step); font-family: var(--mono); font-size: 13px; color: var(--text-4); }
.panel-head.who { justify-content: flex-start; align-items: center; gap: 12px; }
.panel-head.who .mascot { height: 40px; width: auto; }

.say { margin: 0; font-size: 30px; font-weight: 600; line-height: 1.2; letter-spacing: -0.02em; color: var(--text); }
.facts { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 20px; font-size: 16px; }
.facts dt { font-family: var(--mono); font-size: 11px; letter-spacing: 0.09em; text-transform: uppercase; color: var(--text-4); align-self: center; }
.facts dd { margin: 0; color: var(--text); }
.facts dd.seen::after { content: 'Ada sees this'; margin-left: 10px; font-family: var(--mono); font-size: 11px; color: var(--text-4); }
.facts .flag { color: var(--amber); }

#bot { display: flex; flex-direction: column; gap: 16px; }
.verdict { margin: 0; font-size: 30px; font-weight: 600; line-height: 1.2; letter-spacing: -0.02em; }
.verdict.ask { color: var(--amber); }
.verdict.approve { color: var(--green); }
.why { margin: 0; font-size: 15px; line-height: 1.55; color: var(--text-3); }
.basis { display: flex; flex-direction: column; gap: 8px; padding-top: 14px; border-top: 1px solid var(--hair); }
.basis-row { display: grid; grid-template-columns: minmax(0, 1fr) max-content max-content; align-items: center; gap: 12px; font-size: 14px; color: var(--text-2); }
.basis-row i { font-style: normal; font-family: var(--mono); font-size: 12px; color: var(--text-4); }
.pill { display: inline-block; font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; padding: 4px 8px; border: 1px solid var(--rail); border-radius: 6px; color: var(--text-3); white-space: nowrap; }
.pill.approve { border-color: var(--green-line); color: var(--green); background: var(--green-bg); }
.keys { margin: 0; font-family: var(--mono); font-size: 12px; color: var(--text-4); }
.keys kbd { font: inherit; padding: 1px 6px; border: 1px solid var(--rail); border-radius: 4px; color: var(--text-3); }

.primary { font-family: var(--sans); font-size: 16px; font-weight: 500; padding: 14px 24px; background: #fff; color: #000; border: 0; border-radius: var(--radius); cursor: pointer; }
.primary:disabled, .outline:disabled { opacity: 0.55; cursor: default; }
.outline { font-family: var(--sans); font-size: 16px; font-weight: 500; padding: 13px 24px; background: transparent; color: var(--text); border: 1px solid var(--rail); border-radius: var(--radius); cursor: pointer; }
.outline:hover:not(:disabled) { border-color: var(--text-3); }
.ghost { display: inline-block; font-family: var(--mono); font-size: 13px; padding: 8px 12px; background: transparent; color: var(--text-3); border: 1px solid var(--rail); border-radius: var(--radius); cursor: pointer; text-decoration: none; }
.ghost:hover { color: var(--text); border-color: var(--text-3); }
.error { margin: 0; padding: 12px 14px; border: 1px solid var(--red-line); border-radius: var(--radius); background: var(--surface); color: var(--text-2); font-size: 14px; }

/* How the bot is doing: one cell an expense, in order. */
.strip { display: grid; grid-template-columns: repeat(20, minmax(0, 1fr)); gap: 6px; }
.cell { display: flex; align-items: center; justify-content: center; aspect-ratio: 1; max-height: 44px; border: 1px solid var(--hair); border-radius: 6px; font-family: var(--mono); font-size: 14px; font-style: normal; font-weight: 600; color: var(--text-4); }
.cell.asked { border-color: var(--amber); color: var(--amber); background: var(--amber-bg); }
.cell.right { border-color: var(--green-line); color: var(--green); background: var(--green-bg); }
.cell.wrong { border-color: var(--red-line); color: var(--red); background: var(--red-bg); }
.cell.now { border-color: var(--text); }
.legend { display: flex; flex-wrap: wrap; gap: 18px; font-family: var(--mono); font-size: 12px; color: var(--text-3); }
.legend span { display: inline-flex; align-items: center; gap: 8px; }
.legend .cell { width: 22px; height: 22px; font-size: 12px; }

#weights { display: flex; flex-direction: column; gap: 12px; padding-top: 16px; border-top: 1px solid var(--hair); }
.bars { display: flex; flex-direction: column; gap: 10px; max-width: 40rem; }
.bar { display: grid; grid-template-columns: 130px minmax(0, 1fr) 44px; align-items: center; gap: 12px; font-family: var(--mono); font-size: 13px; color: var(--text-3); }
.bar div { height: 8px; background: var(--hair); border-radius: 4px; }
.bar i { display: block; height: 100%; border-radius: 4px; background: var(--text); transition: width 0.5s cubic-bezier(.2,.7,.2,1); }
.bar b { text-align: right; font-weight: 500; color: var(--text); font-variant-numeric: tabular-nums; }

.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.stat { display: flex; flex-direction: column; gap: 6px; padding: 16px; border: 1px solid var(--hair); border-radius: var(--radius); }
.stat b { font-size: 34px; font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 14px; line-height: 1.45; color: var(--text-3); }
#summary { display: flex; flex-direction: column; gap: 16px; }

@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.rise { animation: rise 0.35s cubic-bezier(.2,.7,.2,1) both; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
@media (max-width: 900px) {
  .game { grid-template-columns: 1fr; }
  .say, .verdict { font-size: 24px; }
  .strip { grid-template-columns: repeat(10, minmax(0, 1fr)); }
  .stats { grid-template-columns: 1fr; }
  .head { padding: 14px 18px; }
  main { padding: 18px 18px 32px; }
  .panel { padding: 20px 18px 22px; }
  .kicker:not(h2):not(h3) { display: none; }
  .keys { display: none; }
}
