:root {
  --bg: #f4efe4;
  --surface: #fcfaf4;
  --ink: #211c16;
  --muted: #6c6356;
  --line: #e2d9c7;
  --accent: #2f5d50;
  --warn: #9a5b00;
  --danger: #b3261e;
  --ok: #197a4a;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
span { color: var(--muted); font-weight: 400; }
.top { position: sticky; top: 0; z-index: 2; }
.brand { background: var(--ink); color: #fff; padding: 10px 16px; font-weight: 700; }
.brand span { color: #cfc6b6; }
.gate { padding: 8px 16px; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.gate strong { font-size: 18px; letter-spacing: .04em; }
.gate-unknown, .gate-OFF { background: #e9e4da; }
.gate-SHADOW { background: #e6eef6; }
.gate-PILOT { background: #fff1d6; }
.gate-LIVE { background: #e2f3e9; }
.training-band { background: var(--accent); color: #fff; padding: 8px 16px; font-weight: 700; letter-spacing: .03em; }
.training-band span { color: #d7e6e0; display: block; font-weight: 500; }
main { max-width: 760px; margin: 0 auto; padding: 12px 16px 32px; }
.counts { display: flex; gap: 16px; flex-wrap: wrap; margin: 6px 0 12px; }
.counts b { font-size: 22px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin: 12px 0; }
.card.muted { opacity: .75; }
h2 { font-size: 17px; margin: 0 0 8px; }
label { display: block; margin: 4px 0; }
.hint { color: var(--muted); font-size: 14px; margin: 6px 0; }
.hint span, label span, button span, h2 span { display: inline; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
input, select, button, .button {
  font: inherit; min-height: 48px; border-radius: 10px; border: 1px solid #b9ae98; padding: 8px 12px; background: #fff; color: var(--ink);
}
input#lookup { flex: 1; min-width: 0; text-transform: uppercase; }
select { width: 100%; max-width: 100%; }
.row select { width: auto; flex: 1; min-width: 200px; }
button, .button { background: var(--accent); color: #fff; border-color: var(--accent); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
button span, .button span { color: #d7e6e0; }
button.secondary { background: #fff; color: var(--ink); border-color: #b9ae98; }
button.secondary span { color: var(--muted); }
button.danger { color: var(--danger); }
button:disabled { opacity: .5; cursor: not-allowed; }
.check { display: flex; gap: 8px; align-items: flex-start; }
.check input { min-height: 24px; width: 24px; height: 24px; }
.consent { background: #fff; border-left: 4px solid var(--warn); padding: 8px 10px; margin: 6px 0; }
.consent.en { color: var(--muted); }
.result.ok { color: var(--ok); font-weight: 600; }
.result.no { color: var(--danger); font-weight: 600; }
.checks .issue { color: var(--warn); margin: 4px 0; }
.checks .fine { color: var(--ok); font-weight: 600; }
.records { list-style: none; padding: 0; margin: 10px 0 0; font-size: 14px; }
.records li { padding: 6px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.foot { text-align: center; color: var(--muted); font-size: 12px; padding: 16px; }
