:root {
  --bg: #14120f; --panel: #1f1b16; --panel2: #262119; --line: #2e2922; --text: #e8e2d6; --dim: #a9a29a;
  --accent: #f2b84b; --accent2: #b8822a; --green: #7fd07a; --red: #e5604a; --blue: #6fb3e0;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.45 Inter, "Segoe UI", system-ui, sans-serif; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
nav.top { display: flex; align-items: center; gap: 4px; padding: 10px 20px; background: var(--panel); border-bottom: 1px solid var(--line); flex-wrap: wrap; position: sticky; top: 0; z-index: 5; }
nav.top a { color: var(--dim); padding: 6px 10px; border-radius: 4px; }
nav.top a.active, nav.top a:hover { color: var(--text); background: var(--panel2); text-decoration: none; }
nav.top .brand { font-weight: 800; font-size: 20px; color: var(--accent); letter-spacing: 1px; margin-right: 10px; }
nav.top .spacer { flex: 1; }
nav.top .dim { color: var(--dim); }
.period button { background: transparent; color: var(--dim); border: 1px solid var(--line); padding: 4px 10px; border-radius: 4px; cursor: pointer; }
.period button.on { color: #14120f; background: var(--accent); border-color: var(--accent); font-weight: 600; }
.badge { background: var(--red); color: #fff; border-radius: 10px; padding: 0 6px; font-size: 11px; margin-left: 4px; }
main { padding: 20px 24px 40px; max-width: 1500px; margin: 0 auto; }
h1 { font-size: 24px; margin: 4px 0 18px; }
h2 { font-size: 16px; color: var(--dim); margin: 26px 0 10px; text-transform: uppercase; letter-spacing: .5px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 12px 14px; }
.card .v { font-size: 26px; font-weight: 700; color: var(--text); }
.card .l { color: var(--dim); font-size: 12px; margin-top: 2px; }
.card.warn .v { color: var(--red); }
.card.good .v { color: var(--green); }
.chart { background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 12px; height: 300px; margin: 8px 0 16px; }
.chart.tall { height: 380px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 1000px) { .grid2 { grid-template-columns: 1fr; } }
table { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
th, td { padding: 7px 10px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--dim); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .4px; background: var(--panel2); }
tr:hover td { background: var(--panel2); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.bar { display: inline-block; height: 8px; background: var(--accent); border-radius: 2px; vertical-align: middle; margin-right: 6px; }
.tag { display: inline-block; padding: 1px 7px; border-radius: 3px; font-size: 12px; background: var(--panel2); color: var(--dim); }
.tag.new { background: #4a2a22; color: #ffb3a7; }
.tag.done { background: #23402a; color: #a9e2a3; }
.tag.seen { background: #2b3b4a; color: #a9d4f2; }
.stars { color: var(--accent); letter-spacing: 1px; }
pre { background: #0f0d0b; border: 1px solid var(--line); border-radius: 6px; padding: 12px; overflow: auto; max-height: 420px; font-size: 12px; }
form.inline { display: inline-flex; gap: 6px; align-items: center; }
input, select, textarea, button.btn { background: var(--panel2); color: var(--text); border: 1px solid var(--line); border-radius: 4px; padding: 6px 8px; font: inherit; }
button.btn { background: var(--accent); color: #14120f; font-weight: 600; cursor: pointer; border: 0; padding: 7px 14px; }
button.btn.secondary { background: var(--panel2); color: var(--text); border: 1px solid var(--line); }
textarea { width: 100%; min-height: 120px; font-family: Consolas, monospace; }
.login { max-width: 360px; margin: 120px auto; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 28px; }
.login h1 { color: var(--accent); font-size: 32px; margin: 0 0 16px; }
.login input { width: 100%; margin: 8px 0 14px; }
.muted { color: var(--dim); }
.small { font-size: 12px; }
.text { white-space: pre-wrap; max-width: 700px; }
footer { color: var(--dim); text-align: center; padding: 20px; font-size: 12px; border-top: 1px solid var(--line); }
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.kv { display: grid; grid-template-columns: 180px 1fr; gap: 4px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 12px; }
.kv b { color: var(--dim); font-weight: 500; }
.pager { justify-content: center; margin-top: 12px; }
.pager { justify-content: center; margin-top: 12px; }
.tag.fix { background: #4a3a1e; color: #f2c26b; }
.tag.archived { background: #2a2620; color: #8a827a; }
.tag.rejected, .tag.rework { background: #4a2a22; color: #ffb3a7; }

/* Workshop (Forge): its own colour so the section reads apart from the telemetry pages. */
.nav-sep { display: inline-block; width: 1px; height: 18px; background: var(--line); margin: 0 6px; vertical-align: middle; }
nav.top a.nav-workshop { color: #e08a3c; }
nav.top a.nav-workshop.active { color: #fff; background: #b25e1e; }
/* Platforms (R45-H): Steam Deck and Proton stand out from the Windows majority. */
.tag.plat-steamdeck { background: #2a2f4a; color: #b9c4ff; }
.tag.plat-proton { background: #3a2a4a; color: #d9b3ff; }
.tag.plat-linux { background: #3a3a1e; color: #efe08a; }
.tag.plat-macos, .tag.plat-android { background: #23363a; color: #a3dce2; }

/* Crash page key lines (R45-K): the launcher's summary on top, the cause and missing pieces in red. */
table.crash-key th { width: 170px; color: var(--dim); font-weight: 500; text-align: left; vertical-align: top; }
table.crash-key td { font-family: ui-monospace, Consolas, monospace; font-size: 13px; white-space: pre-wrap; word-break: break-word; }
table.crash-key tr.alarm td, table.crash-key tr.alarm th, .alarm-text { color: #ff8a7a; }

/* Tester programme (docs/dev/63): the public pages are narrow and readable. */
main.tester { max-width: 900px; }
.tester-error { background: #4a2a22; color: #ffb3a7; padding: 8px 12px; border-radius: 4px; }
.tester-form { display: flex; flex-direction: column; gap: 12px; max-width: 420px; margin: 12px 0 24px; }
.tester-form input[name=key], .tester-form input[name=code] { width: 100%; font-size: 18px; letter-spacing: 1px; }
.tester-form .check { display: flex; gap: 8px; align-items: center; }
.tester-rules ol li { margin-bottom: 6px; }
a.btn { display: inline-block; background: var(--accent); color: #14120f; font-weight: 600; padding: 7px 14px; border-radius: 4px; }
a.btn.secondary { background: var(--panel2); color: var(--text); border: 1px solid var(--line); }
.tester-ok { background: #1f3a26; color: #a8e6b4; padding: 8px 12px; border-radius: 4px; font-weight: bold; }
.tester-code { font: bold 28px/1.2 ui-monospace, Consolas, monospace; letter-spacing: 3px; padding: 2px 10px; border: 1px solid #555; border-radius: 4px; }
.tester-big { font-size: 20px; padding: 12px 28px; margin: 8px 0; }
.tester-howto { border-left: 4px solid #4a8; padding: 4px 16px; margin: 12px 0 20px; }
.tester-howto ol li { margin-bottom: 6px; }
.tester-cur { display: inline-flex; gap: 6px; margin-right: 12px; }
.tester-cur a { padding: 0 6px; border-radius: 3px; }
.tester-cur a.active { background: #4a8; color: #fff; }
.row-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.danger-box { display: inline-flex; gap: 6px; margin-left: 18px; padding-left: 14px; border-left: 2px solid #6b2a22; }
button.btn.danger { background: #8a2e24; color: #fff; }
