:root {
  --bg: #0b0f14;
  --surface: #121a24;
  --text: #e8eef5;
  --muted: #8fa3b8;
  --accent: var(--fm-accent);
  --accent-dim: var(--fm-accent-deep);
  --danger: #e76f6f;
  --truth: #52b788;
  --border: #1e2a38;
  --font: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --serif: Georgia, 'Times New Roman', Times, serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem 0.75rem;
}

.logo {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  text-decoration: none;
  color: var(--text);
}

.logo:hover {
  text-decoration: none;
}

.logo-brand {
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  line-height: 1.2;
}

.logo-edition {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.site-nav a {
  font-size: 0.9rem;
}

.nav-staff {
  color: var(--muted);
}

/* Edition tabs */
.edition-bar {
  display: flex;
  gap: 0.35rem;
  padding: 0 1.5rem 0;
  border-top: 1px solid rgba(30, 42, 56, 0.6);
  margin-top: 0.25rem;
}

.edition-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.65rem 1rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
}

.edition-tab:hover {
  color: var(--text);
  text-decoration: none;
}

.edition-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.edition-soon {
  cursor: not-allowed;
  opacity: 0.55;
}

.edition-soon-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: var(--border);
  color: var(--muted);
}

.site-main {
  max-width: 52rem;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 1.5rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
}

.hero {
  margin-bottom: 2.5rem;
}

.hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin: 0 0 0.5rem;
}

.hero p {
  color: var(--muted);
  font-size: 1.1rem;
  margin: 0;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
}

.card h2,
.card h3 {
  margin-top: 0;
}

.meta {
  font-size: 0.85rem;
  color: var(--muted);
  font-family: var(--mono);
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  background: var(--border);
  color: var(--muted);
  margin-right: 0.35rem;
}

.badge-tier-s { background: #1b4332; color: var(--truth); }
.badge-tier-a { background: #1d3557; color: #a8dadc; }
.badge-tier-b { background: #3d2c1e; color: #f4a261; }
.badge-tier-c { background: #3d1e1e; color: var(--danger); }

.wall-truth h2 { color: var(--truth); }
.wall-shame h2 { color: var(--danger); }

.policy-page {
  max-width: 42rem;
  margin: 0 auto;
  padding: 0 0 3rem;
}

.policy-hero {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.policy-hero-kicker {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 0 0 0.5rem;
}

.policy-hero-lead {
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--muted);
  margin: 0;
}

.policy-content {
  font-size: 1rem;
  line-height: 1.65;
}

.policy-content h1 {
  font-size: 1.75rem;
  line-height: 1.25;
  margin: 0 0 1rem;
}

.policy-content h2 {
  margin-top: 2.25rem;
  margin-bottom: 0.75rem;
  font-size: 1.2rem;
  line-height: 1.35;
  color: var(--text);
  padding-top: 0.25rem;
}

.policy-content p {
  margin: 0 0 1rem;
}

.policy-content a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.policy-content a:hover {
  color: var(--text);
}

.policy-list {
  margin: 0 0 1.25rem;
  padding-left: 1.35rem;
}

.policy-list li {
  margin-bottom: 0.5rem;
}

.policy-list li::marker {
  color: var(--accent);
}

.policy-table-wrap {
  overflow-x: auto;
  margin: 0 0 1.25rem;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.policy-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.policy-table th,
.policy-table td {
  padding: 0.65rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.policy-table th {
  background: rgba(15, 23, 35, 0.6);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.policy-table tbody tr:last-child td {
  border-bottom: none;
}

.policy-table tbody tr:nth-child(even) td {
  background: rgba(15, 23, 35, 0.25);
}

.policy-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

.policy-footer-note {
  margin-top: 2rem !important;
  font-size: 0.95rem;
  color: var(--muted);
  text-align: center;
}

.policy-content ul {
  padding-left: 1.25rem;
}

.form-note {
  background: #1a2332;
  border-left: 3px solid var(--accent);
  padding: 1rem;
  margin: 1rem 0;
  font-size: 0.95rem;
}

.empty {
  color: var(--muted);
  font-style: italic;
}

/* Newsroom */
.newsroom-field {
  display: block;
  margin: 1rem 0;
}

.newsroom-field input {
  display: block;
  width: 100%;
  max-width: 28rem;
  margin-top: 0.35rem;
  padding: 0.55rem 0.75rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
}

.newsroom-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.btn {
  padding: 0.5rem 0.9rem;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  font-size: 0.9rem;
}

.btn:hover:not(:disabled) {
  border-color: var(--accent-dim);
}

.btn:disabled,
.btn[hidden] {
  display: none;
}

.btn-primary {
  background: var(--accent-dim);
  border-color: var(--accent-dim);
  color: #fff;
}

.newsroom-table-wrap {
  overflow-x: auto;
  margin: 1rem 0;
}

.newsroom-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.newsroom-table th,
.newsroom-table td {
  border-bottom: 1px solid var(--border);
  padding: 0.55rem 0.4rem;
  text-align: left;
  vertical-align: top;
}

.newsroom-table th {
  color: var(--muted);
  font-weight: 600;
}

.newsroom-log {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem;
  max-height: 16rem;
  overflow: auto;
  font-family: var(--mono);
  font-size: 0.8rem;
  white-space: pre-wrap;
  margin: 0;
}
