:root {
  color-scheme: light;
  --bg: #F5F2EA; --card: #FFFFFF; --ink: #15171C; --muted: #5E6168; --line: #E7E2D6;
  --orange: #FF5A1F; --glow: #FF7A45; --night: #14161B; --orange-soft: #FFE7DC; --orange-ink: #8A2E08; --side: #14161B; --side-2: #2A2D35;
  --good: #16794A; --good-soft: #DDF3E6; --bad: #B42318; --blue: #2B5FD9; --blue-soft: #E3ECFF;
  --accent: var(--orange);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: Barlow, system-ui, sans-serif; font-size: 16px; }
a { color: var(--ink); }
h1, .display { font-family: 'Barlow Condensed', sans-serif; font-style: italic; font-weight: 800; line-height: 1; }
h1 { font-size: 46px; margin: 4px 0 0; }
h2 { font-size: 22px; font-weight: 800; margin: 0 0 12px; }
.boot { padding: 40px; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.layout { display: flex; min-height: 100vh; }
nav.side { width: 240px; flex-shrink: 0; background: var(--side); color: #fff; padding: 24px 16px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; }
.logo { font-family: 'Barlow Condensed', sans-serif; font-style: italic; font-weight: 800; font-size: 32px; }
.logo { line-height: 0; }
.logo svg.brand { height: 30px; width: auto; display: block; }
.side .logo { margin: 2px 0 6px 4px; }
.side .sub { font-size: 13px; color: #B9BCC4; margin-bottom: 18px; }
.side a { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 12px; color: #D9DBE0; text-decoration: none; font-weight: 600; }
.side a.on { background: var(--side-2); color: #fff; font-weight: 800; }
.side a:hover { background: var(--side-2); color: #fff; }
.side .grow { flex-grow: 1; }
.side .who { padding: 12px; border-radius: 14px; background: var(--side-2); font-size: 13px; color: #D9DBE0; display: flex; flex-direction: column; gap: 8px; }
.side .who b { color: #fff; }
.side select { width: 100%; padding: 8px; border-radius: 10px; border: 0; font: inherit; }
main { flex-grow: 1; padding: 32px 40px 60px; display: flex; flex-direction: column; gap: 24px; min-width: 0; max-width: 1240px; }
header.top { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--card); font-weight: 700; font-size: 14px; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--good); }
.grid { display: grid; gap: 16px; }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { background: var(--card); border-radius: 20px; padding: 20px; }
.card.dark { background: var(--ink); color: #fff; }
.kpi .label { font-size: 14px; font-weight: 700; color: var(--muted); }
.card.dark .label, .card.dark .muted { color: #D9DBE0; }
.kpi .value { font-family: 'Barlow Condensed', sans-serif; font-style: italic; font-weight: 800; font-size: 46px; line-height: 1.1; }
.card.dark .value { color: #FF7A45; }
.moment { display: flex; flex-direction: column; gap: 10px; }
.moment .head { display: flex; align-items: center; gap: 12px; }
.moment .ico { width: 42px; height: 42px; border-radius: 13px; display: flex; align-items: center; justify-content: center; background: var(--orange-soft); color: #B8400F; flex-shrink: 0; }
.moment .ico.blue { background: var(--blue-soft); color: var(--blue); }
.moment .ico.green { background: var(--good-soft); color: var(--good); }
.moment .title { font-size: 19px; font-weight: 800; }
.count { margin-left: auto; padding: 5px 11px; border-radius: 999px; background: var(--orange-soft); color: var(--orange-ink); font-weight: 800; font-size: 14px; white-space: nowrap; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tag { padding: 5px 10px; border-radius: 9px; background: var(--bg); font-size: 13px; font-weight: 700; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
button, .btn { font: inherit; font-weight: 800; border-radius: 13px; padding: 11px 16px; border: 2px solid var(--ink); background: #fff; color: var(--ink); cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
button.primary, .btn.primary { background: var(--orange); border-color: var(--orange); }
button.dark { background: var(--ink); color: #fff; }
button.link { border: 0; background: none; padding: 4px; text-decoration: underline; font-weight: 700; }
button.danger { border-color: var(--bad); color: var(--bad); }
button:disabled { opacity: .5; cursor: default; }
label { display: block; font-size: 14px; font-weight: 700; color: var(--muted); margin-bottom: 4px; }
input, textarea, select { width: 100%; padding: 11px 13px; border-radius: 12px; border: 2px solid var(--line); font: inherit; font-size: 16px; color: var(--ink); background: #fff; }
input:focus, textarea:focus, select:focus { outline: 3px solid var(--orange-soft); border-color: var(--orange); }
textarea { resize: vertical; min-height: 80px; }
form.stack, .stack { display: flex; flex-direction: column; gap: 12px; }
.check { display: flex; gap: 8px; align-items: center; font-weight: 700; color: var(--ink); }
.check input { width: 20px; height: 20px; accent-color: var(--orange); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th { text-align: left; font-size: 13px; color: var(--muted); padding: 8px; }
td { padding: 12px 8px; border-top: 1px solid var(--line); vertical-align: top; }
.empty { padding: 18px; border-radius: 16px; background: var(--card); color: var(--muted); }
.note { padding: 12px 14px; border-radius: 14px; background: var(--blue-soft); color: #1B3A86; font-size: 14px; line-height: 1.4; }
.ok { padding: 12px 14px; border-radius: 14px; background: var(--good-soft); color: #125E3A; font-weight: 700; }
.err { padding: 12px 14px; border-radius: 14px; background: #FDE7E5; color: var(--bad); font-weight: 700; }
.season { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.season div { padding: 12px; border-radius: 14px; background: var(--bg); font-weight: 700; font-size: 14px; }
.season div b { display: block; font-size: 12px; color: var(--muted); letter-spacing: .5px; }
.season div.now { background: var(--ink); color: #fff; }
.season div.now b { color: #FF7A45; }
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login .card { width: 100%; max-width: 420px; padding: 32px; display: flex; flex-direction: column; gap: 14px; }
.big-input { font-size: 22px; padding: 16px; letter-spacing: 1px; }
#reader { width: 100%; max-width: 420px; border-radius: 16px; overflow: hidden; }
#toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 14px; font-weight: 700; opacity: 0; transition: opacity .2s; pointer-events: none; }
#toast.show { opacity: 1; }
.burger { display: none; }
@media (max-width: 900px) {
  .layout { flex-direction: column; }
  nav.side { width: 100%; height: auto; position: static; flex-direction: row; flex-wrap: wrap; padding: 12px 16px; }
  .side .sub, .side .grow { display: none; }
  .side .who { width: 100%; }
  main { padding: 20px 16px 60px; }
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3, .g2 { grid-template-columns: 1fr; }
  .season { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  h1 { font-size: 36px; }
}
.modal { position: fixed; inset: 0; background: rgba(21, 23, 28, .45); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 10; }
.modal .card { max-width: 420px; width: 100%; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { #toast { transition: none; } }
