/* Rywo website: same tokens as the app (cyanotype light). */
:root {
  color-scheme: dark;
  --light: #3D9BFF; --on-light: #03101F; --ground: #070A10; --tint: #DCE8FF;
  --surface: color-mix(in oklch, var(--ground), var(--tint) 4%);
  --surface-2: color-mix(in oklch, var(--ground), var(--tint) 8%);
  --line: color-mix(in srgb, var(--tint) 9%, transparent);
  --line-2: color-mix(in srgb, var(--tint) 15%, transparent);
  --ink: color-mix(in oklch, #F1F1F1, var(--tint) 35%);
  --ink-2: color-mix(in oklch, #B3B3B3, var(--tint) 25%);
  --ink-3: color-mix(in oklch, #888888, var(--tint) 22%);
  --light-soft: color-mix(in oklch, var(--light) 16%, var(--ground));
  --light-line: color-mix(in oklch, var(--light) 55%, var(--ground));
  --ok: #4FD1A1; --warn: #F2C14E; --bad: #FF6B6B;
  --f-display: 'Bricolage Grotesque', system-ui, sans-serif;
  --f-body: 'Hanken Grotesk', system-ui, sans-serif;
  --f-mono: ui-monospace, 'SF Mono', Menlo, monospace;
  --ease: cubic-bezier(.19, 1, .22, 1);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; background: radial-gradient(70% 55% at 85% -5%, color-mix(in srgb, var(--light) 22%, transparent), transparent 70%), var(--ground); color: var(--ink); font: 16px/1.55 var(--f-body); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
:focus-visible { outline: 2px solid #8FD0E6; outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--light); color: var(--on-light); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
header { display: flex; justify-content: space-between; align-items: center; height: 72px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font: 800 22px/1 var(--f-display); letter-spacing: -.03em; text-decoration: none; }
.wordmark svg { width: 22px; height: 22px; color: var(--light); }
h1 { font: 800 clamp(40px, 6vw, 84px)/.95 var(--f-display); letter-spacing: -.045em; margin: 9vh 0 18px; max-width: 14ch; text-wrap: balance; }
.lede { color: var(--ink-2); font-size: clamp(17px, 1.5vw, 20px); max-width: 52ch; margin: 0 0 40px; }
.grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 24px; align-items: start; padding-bottom: 12vh; }
.card { padding: 28px; border-radius: 16px; background: color-mix(in srgb, var(--surface) 85%, transparent); box-shadow: inset 0 1px 0 rgba(255,255,255,.05), inset 0 0 0 1px var(--line-2), 0 40px 90px -50px #000; backdrop-filter: blur(10px); }
.card h2 { font: 700 26px/1.1 var(--f-display); letter-spacing: -.03em; margin: 0 0 6px; }
.card p.sub { color: var(--ink-2); margin: 0 0 22px; }
label { display: grid; gap: 6px; font-size: 14px; color: var(--ink-2); margin-bottom: 14px; }
input { width: 100%; min-height: 48px; padding: 0 14px; border: 0; border-radius: 10px; background: rgba(0,0,0,.3); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--ink); font: 16px var(--f-body); }
input:focus, select:focus { outline: none; box-shadow: inset 0 0 0 1.5px var(--light); }
select { width: 100%; min-height: 48px; padding: 0 40px 0 14px; border: 0; border-radius: 10px; background: rgba(0,0,0,.3); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--ink); font: 16px var(--f-body); appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-3) 50%), linear-gradient(135deg, var(--ink-3) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
select option { background: #0b0f17; color: var(--ink); }
.opt { color: var(--ink-3); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border: 0; border-radius: 10px; background: var(--surface-2); color: var(--ink); font: 600 15px var(--f-body); text-decoration: none; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line-2); transition: transform .12s var(--ease), background-color .15s; }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--light); color: var(--on-light); box-shadow: 0 10px 30px -12px color-mix(in srgb, var(--light) 60%, transparent); }
.btn.small { min-height: 34px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.msg { margin-top: 12px; font-size: 14px; color: var(--bad); min-height: 20px; }
.keybox { display: flex; gap: 10px; align-items: center; padding: 16px; border-radius: 12px; background: var(--light-soft); box-shadow: inset 0 0 0 1px var(--light-line); margin: 16px 0; }
.keybox code { flex: 1; font: 600 clamp(15px, 2vw, 19px) var(--f-mono); letter-spacing: .04em; overflow-wrap: anywhere; }
.steps { margin: 0; padding-left: 20px; color: var(--ink-2); display: grid; gap: 10px; }
.steps b { color: var(--ink); }
.downloads { display: grid; gap: 10px; margin-top: 18px; }
.fine { font-size: 13px; color: var(--ink-3); }
footer { border-top: 1px solid var(--line); padding: 24px 0 40px; color: var(--ink-3); font-size: 13px; }
@media (max-width: 860px) { .grid { grid-template-columns: minmax(0, 1fr); } h1 { margin-top: 5vh; } }

/* admin */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 24px 0; }
.stat { padding: 16px 18px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.stat b { display: block; font: 700 32px/1.1 var(--f-display); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.stat span { color: var(--ink-3); font-size: 13px; }
.table-wrap { overflow-x: auto; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--line); }
table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 820px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { color: var(--ink-3); font-weight: 500; font-size: 12.5px; background: var(--surface); position: sticky; top: 0; }
td.num { font-variant-numeric: tabular-nums; }
td.fine { white-space: nowrap; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; }
.pill.active { background: color-mix(in srgb, var(--ok) 18%, transparent); color: var(--ok); }
.pill.pending { background: color-mix(in srgb, var(--warn) 18%, transparent); color: var(--warn); }
.pill.revoked { background: color-mix(in srgb, var(--bad) 18%, transparent); color: var(--bad); }
.actions { display: flex; gap: 6px; flex-wrap: wrap; }
.toolbar { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-top: 8px; }
.toolbar input { max-width: 320px; min-height: 40px; }

.tabs { display: flex; gap: 6px; margin: 4px 0 10px; }
.tabs [aria-selected="true"] { background: var(--light-soft); box-shadow: inset 0 0 0 1px var(--light-line); }
.prompt-list { display: grid; gap: 10px; }
.prompt { padding: 14px 16px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.prompt .meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 14px; }
.prompt p { margin: 10px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); }
.pill:not(.active):not(.pending):not(.revoked) { background: var(--light-soft); color: var(--light); }

.breakdown { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin: 0 0 22px; }
.bd { padding: 16px 18px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.bd h3 { margin: 0 0 10px; font: 600 14px var(--f-body); color: var(--ink-2); }
.bd-row { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) 28px; gap: 10px; align-items: center; font-size: 13px; margin: 6px 0; color: var(--ink-2); }
.bd-row i { display: block; height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--light) var(--w), rgba(255,255,255,.06) var(--w)); }
.bd-row b { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink); }
td.wrapcell { white-space: normal; min-width: 150px; }
.note { color: var(--ink-3); font-size: 12px; }
