/* Di2Beta — Dark Gaming Editorial
   Palette: #12151f / #00d1a0 / #ff4f5a
   Fonts: Exo 2 (display) + system-ui (body) — self-hosted */

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ── Tokens ── */
:root {
  --bg: #12151f;
  --surface: #1a1e2e;
  --surface-2: #21263a;
  --teal: #00d1a0;
  --teal-dark: #00a880;
  --red: #ff4f5a;
  --text: #e2e4ed;
  --muted: #7b8299;
  --border: #2a2f45;
  --max: 1180px;
  --font-display: 'Exo 2', system-ui, sans-serif;
  --font-body: 'Mulish', system-ui, sans-serif;
  --r: 3px;
}

/* ── Base ── */
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* ── Typography ── */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: #fff;
}
h1 { font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2rem); margin: 2.5rem 0 1rem; }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.4rem); margin: 2rem 0 0.5rem; }
h4 { font-size: 1.05rem; }
p { margin-bottom: 1.2rem; color: var(--text); }
p:last-child { margin-bottom: 0; }
strong { color: #fff; font-weight: 600; }
em { font-style: italic; color: #c8cad8; }

/* ── Links ── */
.content a { color: var(--teal); border-bottom: 1px solid transparent; }
.content a:hover { border-bottom-color: var(--teal); }

/* ── Layout ── */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 1.5rem; }

/* ── Header & Nav ── */
.site-header {
  background: #0c0e16;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 2rem;
}
.site-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
}
.site-logo svg { flex-shrink: 0; }
.nav-links {
  display: flex;
  gap: 0.2rem;
  align-items: center;
}
.nav-links a {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  padding: 0.4rem 0.75rem;
  border-radius: var(--r);
  transition: color 0.15s, background 0.15s;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.nav-links a:hover, .nav-links a.active { color: var(--teal); }
.nav-cta {
  background: var(--teal);
  color: #0c0e16 !important;
  padding: 0.4rem 1rem !important;
  font-weight: 700 !important;
}
.nav-cta:hover { background: var(--teal-dark); color: #0c0e16 !important; }

/* Mobile nav */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; color: var(--text); }
@media (max-width: 700px) {
  .nav-links { display: none; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: #0c0e16; padding: 1rem 1.5rem; border-bottom: 1px solid var(--border); gap: 0.25rem; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
}

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, #0a0d18 0%, #12151f 60%, #1a1e2e 100%);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
  position: relative;
}
.hero-bg {
  position: absolute; inset: 0;
  background-image: image-set(url('/assets/images/avif/hero-home-1200w.avif') type('image/avif'), url('/assets/images/hero-home.webp') type('image/webp'));
  background-size: cover;
  background-position: center;
  opacity: 0.18;
}
.hero-inner {
  position: relative;
  padding: 5rem 1.5rem 4rem;
  max-width: var(--max);
  margin: 0 auto;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(0,209,160,0.12);
  border: 1px solid rgba(0,209,160,0.3);
  color: var(--teal);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.3rem 0.75rem;
  border-radius: 2px;
  margin-bottom: 1.25rem;
}
.hero h1 { max-width: 680px; margin-bottom: 1.25rem; }
.hero h1 span { color: var(--teal); }
.hero-sub { font-size: 1.1rem; color: var(--muted); max-width: 560px; margin-bottom: 2rem; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: var(--r);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: all 0.15s;
  cursor: pointer;
  border: none;
}
.btn-primary { background: var(--teal); color: #0c0e16; }
.btn-primary:hover { background: var(--teal-dark); }
.btn-ghost { border: 1px solid var(--border); color: var(--text); background: transparent; }
.btn-ghost:hover { border-color: var(--teal); color: var(--teal); }
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* ── Category Lane ── */
.pillar-lanes { padding: 4rem 0; }
.lane { margin-bottom: 3.5rem; }
.lane-header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}
.lane-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
}
.lane-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  margin-right: 0.4rem;
  position: relative;
  top: -1px;
}
.dot-teal { background: var(--teal); }
.dot-red { background: var(--red); }
.dot-yellow { background: #f5c518; }
.lane-link { margin-left: auto; font-size: 0.82rem; color: var(--muted); }
.lane-link:hover { color: var(--teal); }

/* ── Card Grid ── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s, transform 0.15s;
}
.card:hover { border-color: var(--teal); transform: translateY(-2px); }
.card-img { aspect-ratio: 16/9; overflow: hidden; background: var(--surface-2); }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.card:hover .card-img img { transform: scale(1.03); }
.card-body { padding: 1.25rem; flex: 1; display: flex; flex-direction: column; gap: 0.5rem; }
.card-tag {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 2px;
  display: inline-block;
  align-self: flex-start;
}
.tag-teal { background: rgba(0,209,160,0.12); color: var(--teal); border: 1px solid rgba(0,209,160,0.25); }
.tag-red { background: rgba(255,79,90,0.12); color: var(--red); border: 1px solid rgba(255,79,90,0.25); }
.tag-yellow { background: rgba(245,197,24,0.12); color: #f5c518; border: 1px solid rgba(245,197,24,0.25); }
.card h3 { font-size: 1rem; margin: 0; }
.card p { font-size: 0.88rem; color: var(--muted); margin: 0; flex: 1; }
.card-meta { font-size: 0.78rem; color: var(--muted); margin-top: auto; padding-top: 0.75rem; border-top: 1px solid var(--border); }

/* ── Featured Card (wide) ── */
.card-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
.card-featured .card-img { aspect-ratio: auto; min-height: 220px; }
.card-featured .card-body { padding: 2rem; justify-content: center; }
.card-featured h3 { font-size: 1.3rem; }
@media (max-width: 680px) { .card-featured { grid-template-columns: 1fr; } }

/* ── Article Layout ── */
.article-wrap {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 3rem;
  max-width: var(--max);
  margin: 0 auto;
  padding: 3rem 1.5rem;
  align-items: start;
}
@media (max-width: 900px) {
  .article-wrap { grid-template-columns: 1fr; }
  .article-sidebar { display: none; }
}
.article-header { padding: 3rem 1.5rem 0; max-width: var(--max); margin: 0 auto; }
.article-kicker {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 0.75rem;
}
.article-header h1 { margin-bottom: 1rem; }
.article-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--muted);
  flex-wrap: wrap;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.article-meta span { display: flex; align-items: center; gap: 0.35rem; }

/* Content body */
.content { max-width: 740px; }
.content p { font-size: 1.05rem; margin-bottom: 1.4rem; }
.content h2 { margin-top: 2.75rem; }
.content h3 { margin-top: 2rem; }
.content ul, .content ol { padding-left: 1.5rem; margin-bottom: 1.4rem; }
.content ul li { list-style: disc; margin-bottom: 0.4rem; color: var(--text); }
.content ol li { list-style: decimal; margin-bottom: 0.4rem; color: var(--text); }

/* Article hero image */
.article-hero {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: var(--r);
  margin-bottom: 2.5rem;
  border: 1px solid var(--border);
}

/* Section image */
.section-img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: var(--r);
  margin: 2rem 0;
  border: 1px solid var(--border);
}

/* Callout — site-specific (NOT the bg-x/10 border-l-4 cliché) */
.insight-box {
  background: linear-gradient(135deg, rgba(0,209,160,0.06), rgba(0,209,160,0.02));
  border: 1px solid rgba(0,209,160,0.2);
  border-radius: var(--r);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}
.insight-icon { flex-shrink: 0; color: var(--teal); margin-top: 0.1rem; }
.insight-box p { margin: 0; font-size: 0.97rem; }

/* Timeline (SVG infographic wrapper) */
.infographic-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.5rem;
  margin: 2.5rem 0;
  overflow-x: auto;
}
.infographic-caption {
  text-align: center;
  font-size: 0.82rem;
  color: var(--muted);
  margin-top: 1rem;
}
.embed-snippet {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 0.75rem 1rem;
  font-family: monospace;
  font-size: 0.8rem;
  color: var(--muted);
  overflow-x: auto;
  margin-top: 0.75rem;
}

/* ── FAQ ── */
.faq-section { margin: 3rem 0; }
.faq-section h2 { margin-bottom: 1.5rem; }
.faq-item {
  border-top: 1px solid var(--border);
}
.faq-item:last-child { border-bottom: 1px solid var(--border); }
.faq-q {
  width: 100%;
  background: none;
  border: none;
  padding: 1.1rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-display);
  font-size: 0.97rem;
  font-weight: 700;
  color: #fff;
  transition: color 0.15s;
}
.faq-q:hover { color: var(--teal); }
.faq-q svg { flex-shrink: 0; transition: transform 0.2s; }
.faq-q[aria-expanded="true"] svg { transform: rotate(45deg); color: var(--teal); }
.faq-a {
  display: none;
  padding: 0 0 1.25rem;
  font-size: 0.97rem;
  color: var(--muted);
  line-height: 1.75;
}
.faq-a.open { display: block; }

/* ── Sidebar ── */
.article-sidebar { font-size: 0.9rem; }
.sidebar-widget {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}
.sidebar-widget h4 {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.sidebar-widget ul li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
}
.sidebar-widget ul li:last-child { border-bottom: none; }
.sidebar-widget ul li a { color: var(--text); }
.sidebar-widget ul li a:hover { color: var(--teal); }

/* ── Stats row ── */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin: 2.5rem 0;
}
.stat-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.25rem;
  text-align: center;
}
.stat-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: var(--teal);
  display: block;
  line-height: 1;
  margin-bottom: 0.35rem;
}
.stat-label { font-size: 0.82rem; color: var(--muted); }

/* ── Breadcrumb ── */
.breadcrumb {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0.6rem 0;
  font-size: 0.8rem;
  color: var(--muted);
}
.breadcrumb-inner { display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--teal); }
.breadcrumb-sep { opacity: 0.4; }

/* ── Table ── */
.content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.92rem;
  overflow-x: auto;
  display: block;
}
.content th {
  background: var(--surface-2);
  font-family: var(--font-display);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.75rem 1rem;
  text-align: left;
  color: var(--teal);
  border-bottom: 1px solid var(--border);
}
.content td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: top;
}
.content tr:hover td { background: rgba(255,255,255,0.02); }

/* ── Page header (non-article pages) ── */
.page-hero {
  background: linear-gradient(135deg, #0a0d18, #12151f);
  border-bottom: 1px solid var(--border);
  padding: 3.5rem 1.5rem;
  text-align: center;
}
.page-hero h1 { margin-bottom: 0.75rem; }
.page-hero p { color: var(--muted); max-width: 560px; margin: 0 auto; }

/* ── Footer ── */
.site-footer {
  background: #0c0e16;
  border-top: 1px solid var(--border);
  padding: 3rem 0 1.5rem;
  margin-top: 4rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}
.footer-brand p { color: var(--muted); font-size: 0.88rem; margin-top: 0.75rem; max-width: 280px; }
.footer-col h5 {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.75rem;
}
.footer-col li { padding: 0.3rem 0; }
.footer-col a { color: #6b7280; font-size: 0.88rem; }
.footer-col a:hover { color: var(--teal); }
.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--muted);
}
.footer-note { font-size: 0.75rem; color: #4b5563; max-width: 500px; }
@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ── Utilities ── */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.text-teal { color: var(--teal); }
.text-red { color: var(--red); }
.text-muted { color: var(--muted); }
.mt-0 { margin-top: 0; }
.page-content { padding: 3rem 0; }
.page-content .wrap { max-width: 800px; }
