:root {
  --bg: #0d1117;
  --bg-elevated: #161b22;
  --bg-card: #21262d;
  --border: #30363d;
  --border-muted: #21262d;
  --text: #c9d1d9;
  --text-muted: #8b949e;
  --text-dim: #6e7681;
  --accent: #58a6ff;
  --accent-dim: rgba(88, 166, 255, 0.15);
  --good: #3fb950;
  --warn: #f0883e;
  --bad: #f85149;
  --link: #58a6ff;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--link);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

/* === Header === */
.site-header {
  background: linear-gradient(180deg, #0d1117 0%, #161b22 100%);
  border-bottom: 1px solid var(--border);
  padding: 60px 24px 40px;
  text-align: center;
}

.site-header .eyebrow {
  font-size: 0.85rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.site-header h1 {
  font-size: 2.2rem;
  margin: 0 0 10px 0;
  color: #fff;
  font-weight: 600;
  letter-spacing: -0.5px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.site-header .subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 20px;
}

.site-header .byline {
  font-size: 0.9rem;
  color: var(--text-dim);
}

.site-header .byline strong {
  color: var(--text);
  font-weight: 500;
}

.site-nav {
  margin-top: 30px;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.site-nav a {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 0.9rem;
  transition: all 0.2s;
}

.site-nav a:hover {
  background: var(--accent-dim);
  border-color: var(--accent);
  text-decoration: none;
}

/* === Content === */
main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 24px;
}

section {
  margin-bottom: 60px;
  padding: 0;
}

section h2 {
  font-size: 1.6rem;
  color: #fff;
  margin: 0 0 8px 0;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}

section h2 .num {
  color: var(--accent);
  font-size: 0.9em;
  margin-right: 12px;
}

section h3 {
  font-size: 1.1rem;
  color: var(--text);
  margin: 24px 0 10px 0;
  font-weight: 600;
}

section p {
  margin: 0 0 14px 0;
  color: var(--text);
}

section .plain {
  font-size: 1.02rem;
}

section .technical {
  font-size: 0.95rem;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border-left: 3px solid var(--accent);
  padding: 14px 18px;
  border-radius: 4px;
  margin-bottom: 18px;
}

section .technical::before {
  content: "TECHNICAL";
  display: block;
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 1.5px;
  margin-bottom: 6px;
}

section .plain::before {
  content: "PLAIN";
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
  letter-spacing: 1.5px;
  margin-bottom: 6px;
}

.fig {
  margin: 24px 0 30px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.fig img {
  display: block;
  width: 100%;
  height: auto;
}

.fig figcaption {
  padding: 14px 18px;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}

.fig figcaption strong {
  color: var(--text);
}

.callout {
  background: var(--accent-dim);
  border: 1px solid rgba(88, 166, 255, 0.4);
  border-radius: 8px;
  padding: 18px 22px;
  margin: 20px 0;
}

.callout strong { color: #fff; }

.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin: 24px 0;
}

.kpi {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
  text-align: center;
}

.kpi .value {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
  margin: 0;
  line-height: 1;
}

.kpi .label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 8px;
}

.kpi.good .value { color: var(--good); }
.kpi.warn .value { color: var(--warn); }

.industries {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.industry {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
}

.industry h4 {
  margin: 0 0 8px 0;
  color: var(--accent);
  font-size: 1rem;
}

.industry p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}

/* === Footer === */
.site-footer {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  padding: 30px 24px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

.site-footer a { color: var(--text-muted); }

.cite-block {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 4px;
  padding: 14px 18px;
  margin: 18px 0;
  font-family: "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
  overflow-x: auto;
}

.sim-embed {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  margin: 24px 0;
}

.sim-embed iframe {
  display: block;
  width: 100%;
  height: 900px;
  border: 0;
}

.sim-note {
  padding: 12px 18px;
  font-size: 0.85rem;
  color: var(--text-muted);
  background: var(--bg-card);
  border-top: 1px solid var(--border);
}

@media (max-width: 700px) {
  .site-header h1 { font-size: 1.6rem; }
  .sim-embed iframe { height: 1000px; }
}
