:root {
  color-scheme: dark;
  --bg: #050608;
  --panel: #11151b;
  --panel-2: #171d24;
  --line: #2b333d;
  --text: #f2f5f7;
  --muted: #a5adb8;
  --dim: #6d7682;
  --red: #c6412f;
  --red-2: #7d241c;
  --steel: #d6dde4;
  --green: #83a86c;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --sans: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body.light {
  color-scheme: light;
  --bg: #f1f3f4;
  --panel: #ffffff;
  --panel-2: #e7ebef;
  --line: #c9d0d7;
  --text: #15191f;
  --muted: #4f5964;
  --dim: #6d7682;
  --steel: #1c242d;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 0%, rgba(198,65,47,.22), transparent 32rem),
    linear-gradient(180deg, #080a0d 0%, var(--bg) 30rem);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .8rem clamp(1rem, 3vw, 2.5rem);
  border-bottom: 1px solid rgba(214,221,228,.18);
  background: rgba(5,6,8,.78);
  backdrop-filter: blur(18px);
}
body.light .site-header { background: rgba(241,243,244,.88); }
.brand {
  display: flex;
  align-items: center;
  gap: 0;
  min-width: min(19rem, 58vw);
}
.brand img { width: min(18rem, 58vw); height: auto; object-fit: contain; }
.brand strong { display: block; letter-spacing: .14em; font-size: 1rem; }
.brand span { display: none; color: var(--muted); font-family: var(--mono); font-size: .68rem; letter-spacing: .08em; }
.nav {
  display: flex;
  gap: clamp(.6rem, 2vw, 1.2rem);
  align-items: center;
  color: var(--muted);
  font-size: .9rem;
  flex-wrap: wrap;
}
.nav a:hover, .nav a.active { color: var(--text); }
.toggles { display: flex; align-items: center; gap: .45rem; }
button, .button {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255,255,255,.04);
  padding: .7rem .9rem;
  border-radius: 4px;
  font: 700 .74rem/1 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
  cursor: pointer;
}
button:hover, .button:hover { border-color: var(--red); }

.hero {
  position: relative;
  min-height: 86vh;
  display: grid;
  align-items: end;
  isolation: isolate;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5,6,8,.92), rgba(5,6,8,.58) 45%, rgba(5,6,8,.16));
  z-index: -1;
}
.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  filter: saturate(.86) contrast(1.04);
}
.hero-content {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 7rem 0 5rem;
}
.kicker, .eyebrow {
  color: var(--red);
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .18em;
  text-transform: uppercase;
}
h1, h2, h3 { line-height: 1.02; margin: 0; }
h1 {
  font-size: clamp(3.2rem, 9vw, 8.8rem);
  letter-spacing: .02em;
}
.lede {
  max-width: 42rem;
  color: var(--steel);
  font-size: clamp(1.05rem, 2vw, 1.45rem);
  margin: 1.1rem 0 1.6rem;
}
.sequence {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 1.4rem 0 2rem;
}
.sequence span, .status, .tag {
  border: 1px solid var(--line);
  background: rgba(9,12,16,.72);
  color: var(--steel);
  border-radius: 999px;
  padding: .35rem .7rem;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.status.hot { border-color: rgba(198,65,47,.8); color: #ffb4a9; }
.status.ok { border-color: rgba(131,168,108,.55); color: #cce3bd; }

main { overflow: hidden; }
.section {
  width: min(1320px, calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(3rem, 7vw, 6rem) 0;
}
.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(15rem, 28rem);
  gap: 2rem;
  align-items: end;
  margin-bottom: 2rem;
}
.section h2 { font-size: clamp(2rem, 4vw, 4.4rem); }
.section-head p { color: var(--muted); margin: 0; }

.grid { display: grid; gap: 1rem; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
  border-radius: 6px;
  overflow: hidden;
}
.card.pad { padding: 1.1rem; }
.card img { width: 100%; aspect-ratio: 16/11; object-fit: cover; }
.card h3 { font-size: 1.15rem; margin: .8rem 0 .45rem; }
.card p { color: var(--muted); margin: 0; }
.meta {
  display: flex;
  justify-content: space-between;
  gap: .7rem;
  align-items: center;
  color: var(--dim);
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.program {
  min-height: 23rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.program .number {
  color: rgba(214,221,228,.18);
  font: 800 4.4rem/1 var(--mono);
}
.program ul, .archive-list { padding: 0; margin: 1rem 0 0; list-style: none; }
.program li, .archive-list li {
  border-top: 1px solid var(--line);
  padding: .65rem 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .82rem;
}

.console {
  background: #07090c;
  border: 1px solid #2f3740;
  border-radius: 6px;
  padding: 1rem;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.025);
}
body.light .console { background: #161b20; color: #f2f5f7; }
.log {
  margin: 0;
  white-space: pre-wrap;
  color: #d9e2ea;
  font: .86rem/1.7 var(--mono);
}
.redline {
  color: transparent;
  background: currentColor;
  box-shadow: inset 0 -0.78em #111;
  user-select: none;
}
body.redact [data-open], body.redact [data-public] { display: none; }
body:not(.redact) [data-redacted], body:not(.redact) [data-clearance] { display: none; }
.redact-block {
  background: #111;
  color: #111;
  padding: 0 .25em;
  border-radius: 2px;
}

.split {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(1rem, 4vw, 3rem);
  align-items: center;
}
.feature-image {
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  background: #0b0e12;
}
.feature-image img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }

.image-band {
  width: min(1480px, calc(100% - 2rem));
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  background: #0b0e12;
}
.image-band img {
  width: 100%;
  aspect-ratio: 16/7;
  object-fit: cover;
}

.product-photo {
  height: 12rem;
  margin: -1.1rem -1.1rem 1rem;
  border-bottom: 1px solid var(--line);
  background-image: var(--product-image);
  background-size: 285%;
  background-repeat: no-repeat;
}
.product-photo.coffee { background-position: 6% 12%; }
.product-photo.hat { background-position: 49% 10%; }
.product-photo.shirt { background-position: 43% 68%; }
.product-photo.wedge { background-position: 89% 80%; }
.product-photo.potato { background-position: 86% 20%; }
.product-photo.jacket { background-position: 80% 51%; }

.shop-card .price { color: var(--text); font: 700 1.45rem/1 var(--mono); margin: .75rem 0; }
.shop-card .button { display: inline-block; margin-top: .9rem; }
.notice {
  border-left: 3px solid var(--red);
  background: rgba(198,65,47,.1);
  padding: 1rem;
  color: var(--steel);
  font-family: var(--mono);
  font-size: .85rem;
}

.dossier {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 1rem;
  align-items: stretch;
}
.dossier + .dossier { margin-top: 1rem; }
.dossier .feature-image img { height: 100%; min-height: 22rem; }
.spec-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .7rem;
  margin: 1rem 0;
}
.spec {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: .8rem;
  background: rgba(255,255,255,.03);
}
.spec b {
  display: block;
  color: var(--dim);
  font: .7rem/1 var(--mono);
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .45rem;
}
.spec span { color: var(--steel); }

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}
.metric {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1rem;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.018));
}
.metric .value {
  display: block;
  margin-top: .7rem;
  font: 800 clamp(1.8rem, 4vw, 3.2rem)/1 var(--mono);
  color: var(--text);
}
.meter {
  height: .45rem;
  border-radius: 999px;
  background: #151b22;
  overflow: hidden;
  margin-top: .8rem;
}
.meter span {
  display: block;
  height: 100%;
  width: var(--fill);
  background: linear-gradient(90deg, var(--red), #d6dde4);
}
.blink {
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .45; }
}

.incident-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: .82rem;
}
.incident-table th, .incident-table td {
  border-bottom: 1px solid var(--line);
  padding: .85rem;
  text-align: left;
  vertical-align: top;
}
.incident-table th {
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: .08em;
  background: rgba(255,255,255,.035);
}
.incident-table td { color: var(--steel); }

.live-feed {
  position: relative;
  height: 28rem;
  overflow: hidden;
  border: 1px solid #34404b;
  border-radius: 6px;
  background:
    linear-gradient(180deg, #050608, rgba(5,6,8,.86)),
    repeating-linear-gradient(0deg, transparent 0 28px, rgba(214,221,228,.035) 29px 30px);
}
.live-feed::before,
.live-feed::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 4rem;
  z-index: 2;
  pointer-events: none;
}
.live-feed::before { top: 0; background: linear-gradient(180deg, #050608, transparent); }
.live-feed::after { bottom: 0; background: linear-gradient(0deg, #050608, transparent); }
.feed-track {
  display: grid;
  gap: .7rem;
  padding: 1rem;
  animation: feed-scroll 52s linear infinite;
}
.live-feed:hover .feed-track { animation-play-state: paused; }
.feed-item {
  border: 1px solid rgba(214,221,228,.12);
  border-left: 3px solid var(--red);
  border-radius: 4px;
  padding: .8rem;
  background: rgba(255,255,255,.035);
  font-family: var(--mono);
}
.feed-item b {
  display: block;
  color: var(--steel);
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: .35rem;
}
.feed-item span {
  display: block;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.55;
}
@keyframes feed-scroll {
  from { transform: translateY(0); }
  to { transform: translateY(-50%); }
}

.timeline {
  border-left: 1px solid var(--line);
  margin: 1.4rem 0 0 1rem;
  padding-left: 1rem;
}
.timeline-item {
  position: relative;
  padding: 0 0 1.2rem;
}
.timeline-item::before {
  content: "";
  position: absolute;
  left: -1.31rem;
  top: .25rem;
  width: .55rem;
  height: .55rem;
  border-radius: 50%;
  background: var(--red);
}
.timeline-item b {
  display: block;
  color: var(--steel);
  font-family: var(--mono);
}
.timeline-item p { color: var(--muted); margin: .25rem 0 0; }

.terminal {
  border: 1px solid #34404b;
  border-radius: 6px;
  background: #050608;
  padding: 1rem;
}
.terminal-screen {
  min-height: 14rem;
  color: #d9e2ea;
  white-space: pre-wrap;
  font: .86rem/1.65 var(--mono);
}
.terminal-form {
  display: flex;
  gap: .7rem;
  margin-top: 1rem;
}
.terminal-form input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: rgba(255,255,255,.04);
  color: var(--text);
  padding: .78rem .85rem;
  font: .86rem var(--mono);
}
.chips {
  display: flex;
  gap: .45rem;
  flex-wrap: wrap;
  margin-top: .8rem;
}
.chips button { padding: .48rem .65rem; font-size: .68rem; }

.catalog-label {
  margin: 2rem 0 1rem;
  color: var(--red);
  font: .78rem/1 var(--mono);
  letter-spacing: .16em;
  text-transform: uppercase;
}

.restricted-card {
  border-color: rgba(198,65,47,.45);
}

.echo-show {
  border: 1px solid #202831;
  border-radius: 28px;
  padding: .7rem .7rem 1.9rem;
  background: linear-gradient(180deg, #10151b, #040506 78%);
  box-shadow: 0 24px 70px rgba(0,0,0,.45);
  position: relative;
}
.echo-show::after {
  content: "";
  position: absolute;
  left: 22%;
  right: 22%;
  bottom: .45rem;
  height: .8rem;
  border-radius: 999px;
  background: #171d24;
}
.echo-screen {
  min-height: 23rem;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  display: grid;
  align-items: end;
  background: #050608;
}
.echo-screen img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .72;
  filter: saturate(.86) contrast(1.08);
}
.echo-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5,6,8,.1), rgba(5,6,8,.86));
}
.echo-message {
  position: relative;
  z-index: 1;
  padding: 1.2rem;
}
.echo-message .wake {
  color: #94d8ff;
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.echo-message strong {
  display: block;
  font-size: clamp(1.7rem, 4vw, 3rem);
  line-height: 1;
  margin-top: .45rem;
}
.audio-actions {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}
.audio-note {
  color: var(--dim);
  font-family: var(--mono);
  font-size: .76rem;
}

.footer {
  border-top: 1px solid var(--line);
  padding: 2rem clamp(1rem, 3vw, 2.5rem);
  color: var(--dim);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: .78rem;
}

@media (max-width: 860px) {
  .site-header { align-items: flex-start; flex-direction: column; }
  .nav { width: 100%; }
  .section-head, .split, .dossier, .grid.two, .grid.three, .grid.four, .metric-grid, .spec-grid { grid-template-columns: 1fr; }
  .hero { min-height: 78vh; }
  .hero::before { background: linear-gradient(180deg, rgba(5,6,8,.48), rgba(5,6,8,.95)); }
  .hero-content { padding-top: 10rem; }
  .brand { min-width: min(16rem, 82vw); }
  .brand img { width: min(15rem, 82vw); height: auto; }
  .image-band img { aspect-ratio: 4/3; }
  .echo-screen { min-height: 19rem; }
  .terminal-form { flex-direction: column; }
}
