:root {
  --accent: #1F5E7A;
  --bg: #F4F5F2; --ink: #15181C; --muted: #3E464E; --faint: #B9BEB6; --line: #D9DCD6;
  --on-accent: #FFFFFF; --accent-text: var(--accent);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #111417; --ink: #EEF0EC; --muted: #B5BCC3; --faint: #4A525A; --line: #2A2F35;
  --accent-text: #84A6B6; --on-accent: #111417;
  color-scheme: dark;
}
:root[data-theme="dark"] .btn-primary { background: var(--accent-text); }
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  background: var(--bg); color: var(--ink); min-height: 100vh;
  transition: background .3s, color .3s;
}
a { color: var(--accent-text); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; }
.mono { font-family: "IBM Plex Mono", ui-monospace, Menlo, monospace; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px;
  font: 500 16px/1 inherit; font-family: inherit; text-decoration: none; border-radius: 6px; cursor: pointer; gap: 8px; }
.btn-primary { background: var(--accent); color: var(--on-accent); border: 0; }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--faint); }
.theme-toggle { min-width: 48px; padding: 0 12px; }
.theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }
:root[data-theme="dark"] .theme-toggle .moon { display: none; }

/* Landing */
.landing { min-height: 100vh; padding: 48px 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 32px; }
.landing h1 { margin: 0; font-size: 40px; font-weight: 600; letter-spacing: -0.02em; text-align: center; }
.landing p { margin: 0; font-size: 17px; color: var(--muted); text-align: center; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.orbit { position: relative; width: 100%; max-width: 600px; aspect-ratio: 1 / 1; font: 500 15px "IBM Plex Mono", ui-monospace, monospace; color: var(--muted); }
.orbit svg { position: absolute; left: 20%; top: 20%; width: 60%; height: 60%; }
.orbit .tag { position: absolute; transform: translate(-50%, -50%); white-space: nowrap; }
.orbit .tag.main { color: var(--accent-text); }
.e-faint { stroke: var(--faint); } .e-accent { stroke: var(--accent-text); } .e-ink { stroke: var(--ink); }
.f-accent { fill: var(--accent-text); } .f-ink { fill: var(--ink); }
@keyframes spin { to { transform: rotate(360deg); } }
.spin { transform-box: fill-box; transform-origin: center; animation: spin 40s linear infinite; }
.spin-rev { transform-box: fill-box; transform-origin: center; animation: spin 22s linear infinite reverse; }
@media (prefers-reduced-motion: reduce) { .spin, .spin-rev { animation: none; } body { transition: none; } }
@media (max-width: 480px) { .orbit { font-size: 12px; } .landing h1 { font-size: 32px; } }

/* News */
.topbar { border-bottom: 1px solid var(--line); }
.wrap { max-width: 880px; margin: 0 auto; padding: 0 24px; }
.topbar .wrap { padding-top: 16px; padding-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.back { padding: 12px 0; font: 500 15px "IBM Plex Mono", ui-monospace, monospace; color: var(--ink); text-decoration: none; }
main.wrap { padding-top: 64px; padding-bottom: 96px; display: flex; flex-direction: column; gap: 40px; }
.intro { display: flex; flex-direction: column; gap: 12px; }
.intro h1 { margin: 0; font-size: 44px; line-height: 1.1; font-weight: 600; letter-spacing: -0.02em; }
.intro p { margin: 0; font-size: 18px; line-height: 1.6; color: var(--muted); max-width: 64ch; }
.intro .updated { font-size: 13px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { min-height: 44px; padding: 0 16px; font: 500 15px inherit; font-family: inherit; border-radius: 22px; cursor: pointer;
  background: transparent; color: var(--ink); border: 1px solid var(--faint); }
.pill[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.news-item { padding: 24px 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.news-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--muted); }
.news-meta .src { color: var(--accent-text); }
.news-item h2 { margin: 0; font-size: 21px; line-height: 1.35; font-weight: 600; }
.news-item h2 a { color: var(--ink); text-decoration: none; }
.news-item h2 a:hover { text-decoration: underline; }
.news-item p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--muted); }
.status { padding: 24px 0; border-top: 1px solid var(--line); color: var(--muted); }
.sources { display: flex; flex-direction: column; gap: 16px; padding-top: 24px; border-top: 1px solid var(--line); }
.sources h2 { margin: 0; font-size: 24px; font-weight: 600; }
.sources > p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--muted); }
.source-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.source { padding: 20px; border: 1px solid var(--line); border-radius: 8px; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 6px; }
.source .grp { font-size: 13px; color: var(--accent-text); }
.source .nm { font-size: 17px; font-weight: 600; }
.source .ds { font-size: 15px; line-height: 1.5; color: var(--muted); }
@media (max-width: 480px) { .intro h1 { font-size: 34px; } }
.orbit .t1 { left: 50%; top: 4%; }
.orbit .t2 { left: 92%; top: 36%; }
.orbit .t3 { left: 77%; top: 87%; }
.orbit .t4 { left: 23%; top: 87%; }
.orbit .t5 { left: 8%; top: 36%; }
.btn-icon { width: 20px; height: 20px; display: block; flex: none; }
.logo-dark { display: none; }
:root[data-theme="dark"] .logo-light { display: none; }
:root[data-theme="dark"] .logo-dark { display: block; }
