* {
  box-sizing: border-box;
}

:root {
  --page: #f5f7fb;
  --paper: #ffffff;
  --paper-soft: #f0f3f8;
  --ink: #111418;
  --muted: #667085;
  --muted-strong: #475467;
  --graphite: #17191d;
  --graphite-2: #22262d;
  --graphite-3: #2f3540;
  --line: #d9dee7;
  --line-dark: #363d49;
  --accent: #16c784;
  --accent-ink: #052e1d;
  --low: #12b76a;
  --medium: #eaaa08;
  --high: #f97316;
  --critical: #ef4444;
  --shadow: 0 20px 50px rgba(16, 24, 40, 0.12);
  --radius: 8px;
  --font: "Aptos", "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  overflow-x: hidden;
}

body.mode-live .demo-tab {
  display: none;
}

a {
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

h1,
h2,
h3,
h4,
p,
ul,
ol {
  margin-top: 0;
}

h1,
h2,
h3,
h4 {
  letter-spacing: 0;
}

p,
li {
  line-height: 1.5;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.hidden {
  display: none !important;
}

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

.error {
  color: var(--critical);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 68px;
  padding: 12px 24px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 1rem;
}

.brand-logo {
  width: 34px;
  height: 34px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted-strong);
  font-size: 0.92rem;
}

.site-nav a,
.console-tabs a {
  text-decoration: none;
}

.site-nav a:hover,
.console-tabs a:hover {
  color: var(--ink);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.source-pill,
.risk-chip,
.hero-chip,
.explorer-stream-risk,
.demo-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted-strong);
  font-size: 0.74rem;
  font-weight: 700;
  white-space: nowrap;
}

.risk-chip,
.hero-chip,
.explorer-stream-risk {
  text-transform: capitalize;
}

.pill-ok,
.explorer-badge-ok {
  border-color: rgba(18, 183, 106, 0.35);
  background: #ecfdf3;
  color: #027a48;
}

.explorer-badge-warn {
  border-color: rgba(234, 170, 8, 0.35);
  background: #fffaeb;
  color: #93370d;
}

.mode-switch {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted-strong);
  font-size: 0.82rem;
  font-weight: 700;
}

.mode-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.switch-track {
  width: 42px;
  height: 22px;
  border-radius: 999px;
  background: #dde3ec;
  position: relative;
  border: 1px solid #c8d0dc;
}

.switch-track::before {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  top: 2px;
  left: 2px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 3px rgba(16, 24, 40, 0.2);
  transition: transform 0.16s ease;
}

.mode-switch input:checked + .switch-track {
  background: var(--accent);
  border-color: var(--accent);
}

.mode-switch input:checked + .switch-track::before {
  transform: translateX(20px);
}

.btn {
  min-height: 38px;
  padding: 9px 13px;
  border-radius: 6px;
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: inherit;
  text-decoration: none;
  font-weight: 750;
  font-size: 0.9rem;
  line-height: 1;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.btn-primary:hover {
  filter: brightness(0.96);
}

.btn-secondary,
.btn-soft,
.btn-ghost {
  background: var(--paper);
  border-color: var(--line);
  color: var(--ink);
}

.btn-secondary:hover,
.btn-soft:hover,
.btn-ghost:hover {
  border-color: #aab4c3;
  background: #f9fafb;
}

.hero {
  min-height: 620px;
  display: flex;
  align-items: flex-end;
  background:
    linear-gradient(90deg, rgba(13, 14, 16, 0.86), rgba(13, 14, 16, 0.48) 58%, rgba(13, 14, 16, 0.12)),
    url("/assets/shadow-operator-keyboard.jpg") center / cover;
  color: #ffffff;
}

.hero-inner {
  width: min(1200px, calc(100% - 48px));
  margin: 0 auto;
  padding: 88px 0 42px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 28px;
  align-items: end;
}

.hero-copy {
  max-width: 680px;
}

.hero h1 {
  margin-bottom: 12px;
  font-size: 4.5rem;
  line-height: 0.95;
  font-weight: 850;
}

.hero-lede {
  margin-bottom: 14px;
  font-size: 1.55rem;
  line-height: 1.2;
  font-weight: 700;
}

.hero-subcopy {
  max-width: 620px;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1rem;
}

.hero-actions,
.form-actions,
.audit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.mode-status {
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.88rem;
}

.product-preview {
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius);
  background: rgba(19, 21, 25, 0.88);
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  padding: 16px;
}

.preview-header,
.preview-search,
.preview-score {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.preview-header {
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-dark);
  font-weight: 800;
}

.preview-search {
  margin-top: 16px;
  padding: 12px;
  border-radius: 6px;
  background: var(--graphite-2);
  color: #f8fafc;
}

.preview-search span:first-child,
.preview-score span {
  color: #aeb7c5;
  font-size: 0.82rem;
}

.preview-score {
  margin-top: 16px;
}

.preview-score strong {
  display: block;
  margin-top: 2px;
  font-family: var(--mono);
  font-size: 2rem;
}

.score-bars {
  width: 55%;
  display: grid;
  gap: 5px;
}

.score-bars span {
  height: 7px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--critical));
}

.preview-signals {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
  color: #e6e9ef;
  font-size: 0.9rem;
}

.signal-dot {
  width: 8px;
  height: 8px;
  margin-right: 8px;
  display: inline-block;
  border-radius: 50%;
  background: var(--medium);
}

.signal-dot.critical {
  background: var(--critical);
}

.signal-dot.high {
  background: var(--high);
}

.signal-dot.warn {
  background: var(--medium);
}

.platform-metrics {
  width: min(1200px, calc(100% - 48px));
  margin: -18px auto 34px;
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.platform-metrics article {
  padding: 18px;
  min-height: 118px;
  border-right: 1px solid var(--line);
}

.platform-metrics article:last-child {
  border-right: 0;
}

.platform-metrics span,
.metric-label,
.explorer-stat-label {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
}

.platform-metrics strong,
.metric-value {
  display: block;
  margin-top: 7px;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 1rem;
}

.platform-metrics p,
.metric-sub {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.console-shell,
.capability-band,
.plans-section,
.contact-section {
  width: min(1200px, calc(100% - 48px));
  margin: 0 auto 34px;
}

.console-shell {
  background: var(--graphite);
  color: #f8fafc;
  border: 1px solid #252a33;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: clip;
}

.console-head {
  padding: 22px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: end;
  border-bottom: 1px solid var(--line-dark);
}

.console-head h2 {
  margin-bottom: 4px;
  font-size: 1.55rem;
}

.console-head p {
  margin-bottom: 0;
  color: #b7c0ce;
}

.console-tabs {
  display: inline-flex;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  background: #111318;
  white-space: nowrap;
}

.console-tabs a {
  padding: 8px 10px;
  border-radius: 5px;
  color: #cbd5e1;
  font-size: 0.86rem;
  font-weight: 750;
}

.console-tabs a:hover {
  background: var(--graphite-3);
  color: #ffffff;
}

.console-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 0;
}

.console-main {
  min-width: 0;
  max-width: 100%;
  display: grid;
  gap: 14px;
  padding: 16px;
  overflow: hidden;
}

.console-side {
  min-width: 0;
  padding: 16px;
  display: grid;
  align-content: start;
  gap: 14px;
  border-left: 1px solid var(--line-dark);
  background: #111318;
}

.console-section {
  scroll-margin-top: 86px;
}

.tool-panel,
.side-panel,
.status-panel,
.status.panel,
.panel,
.explorer-card,
.history-entry,
.demo-step,
.explorer-shortcut,
.explorer-stat-card {
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: #1d2026;
  color: #f8fafc;
}

.tool-panel {
  min-width: 0;
  max-width: 100%;
  padding: 16px;
  overflow: hidden;
}

.compact-panel {
  background: #181b20;
}

.side-panel,
.status-panel,
.status.panel {
  padding: 14px;
}

.section-head,
.stream-head,
.explorer-card-head,
.demo-step-head,
.result-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
  max-width: 100%;
}

.section-head,
.stream-head {
  flex-wrap: wrap;
}

.section-head > div,
.stream-head > div {
  flex: 1 1 360px;
  max-width: 100%;
}

.section-head > *,
.stream-head > *,
.explorer-card-head > *,
.demo-step-head > *,
.result-topline > * {
  min-width: 0;
}

.section-head {
  margin-bottom: 14px;
}

.section-head h3,
.stream-head h4,
.side-panel h3 {
  margin-bottom: 4px;
  font-size: 1.05rem;
}

.section-head p,
.side-panel p,
.data-note,
.demo-note {
  margin-bottom: 0;
  color: #aeb7c5;
  font-size: 0.88rem;
}

.risk-form,
.contact-form {
  display: grid;
  gap: 12px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.field-row {
  display: grid;
  gap: 6px;
}

label {
  color: inherit;
  font-size: 0.84rem;
  font-weight: 760;
}

input,
select,
textarea {
  width: 100%;
  min-height: 40px;
  border: 1px solid #414958;
  border-radius: 6px;
  padding: 10px 11px;
  background: #101216;
  color: #f8fafc;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(22, 199, 132, 0.16);
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #cbd5e1;
}

.inline-check input {
  width: 16px;
  min-height: 16px;
}

.scenario-list,
.recent-checks,
.server-audit,
.quick-ops,
.top-risk-list,
.demo-script,
.flow-checklist {
  display: grid;
  gap: 8px;
}

.risk-wallet-samples {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line-dark);
}

.risk-wallet-samples h4,
.risk-wallet-samples p {
  margin: 0;
}

.risk-wallet-samples > div:first-child {
  display: grid;
  gap: 4px;
}

.risk-wallet-samples > div:first-child p:last-child {
  color: #b6c2dc;
}

.quick-ops,
.demo-script,
.flow-checklist {
  margin: 0;
  padding: 0;
  list-style: none;
}

.quick-ops li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line-dark);
}

.quick-ops li:last-child {
  border-bottom: 0;
}

.quick-ops span {
  color: #aeb7c5;
}

.quick-ops strong {
  max-width: 58%;
  text-align: right;
  font-size: 0.84rem;
}

.signal-panel {
  display: grid;
  gap: 12px;
}

.signal-row {
  display: grid;
  gap: 6px;
}

.signal-row p {
  margin-bottom: 0;
  color: #aeb7c5;
  font-size: 0.84rem;
}

.explorer-data-layer,
.explorer-legend,
.explorer-shortcuts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.explorer-controls {
  margin: 14px 0;
  display: grid;
  grid-template-columns: minmax(120px, 180px) minmax(220px, 1fr) minmax(150px, max-content);
  gap: 10px;
  max-width: 100%;
}

.explorer-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.explorer-stat-card,
.explorer-shortcut,
.history-entry,
.demo-step,
.explorer-card {
  padding: 12px;
}

.explorer-shortcut,
.scenario-btn {
  width: 100%;
  text-align: left;
  background: #22262d;
  color: #f8fafc;
  border: 1px solid var(--line-dark);
  border-radius: 6px;
  padding: 10px;
}

.scenario-btn:hover,
.explorer-shortcut:hover,
.explorer-stream-row:hover {
  border-color: #556071;
  background: #282d36;
}

.explorer-shortcut strong,
.explorer-shortcut span {
  display: block;
}

.explorer-shortcut-reason,
.explorer-shortcut-action {
  margin-top: 3px;
  color: #aeb7c5;
  font-size: 0.8rem;
}

.explorer-rank-reason,
.explorer-result,
.explorer-stream {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: #111318;
  color: #d9e1ee;
}

.explorer-rank-reason {
  border-left: 4px solid var(--accent);
}

.explorer-rank-reason h4 {
  margin-bottom: 4px;
}

.reason-list,
.risk-explainer ul,
.signals {
  margin: 8px 0 0;
  padding-left: 20px;
}

.explorer-stream {
  min-height: 160px;
  overflow-x: auto;
  max-width: 100%;
}

.explorer-stream-row {
  display: grid;
  grid-template-columns: 0.65fr 1.55fr 0.7fr 0.9fr 1.35fr 1.3fr 0.65fr;
  gap: 10px;
  align-items: center;
  min-width: 900px;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line-dark);
  color: #d9e1ee;
  font-size: 0.82rem;
}

.explorer-stream-row:last-child {
  border-bottom: 0;
}

.explorer-stream-note,
.explorer-stream-reason {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stream-source-stack {
  display: grid;
  gap: 3px;
  color: #aeb7c5;
  font-size: 0.76rem;
  line-height: 1.25;
}

.stream-source-stack span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stream-head {
  margin-top: 16px;
  align-items: center;
}

.stream-head .btn,
.section-head .btn,
.audit-actions .btn {
  flex: 0 1 auto;
  max-width: 100%;
}

.audit-actions {
  max-width: 100%;
  justify-content: flex-start;
}

@media (max-width: 1180px) {
  .explorer-controls {
    grid-template-columns: minmax(120px, 0.38fr) minmax(180px, 1fr);
  }

  .explorer-controls .btn {
    grid-column: 1 / -1;
    width: 100%;
  }

  .section-head .btn,
  .stream-head .btn {
    width: auto;
  }
}

.explorer-card {
  display: grid;
  gap: 8px;
  background: #191c22;
}

.explorer-card p,
.history-entry p {
  margin-bottom: 0;
}

.risk-explainer {
  margin-top: 4px;
}

.risk-explainer summary {
  cursor: pointer;
  font-weight: 800;
}

.copy-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-height: 24px;
  padding: 4px 7px;
  border-radius: 5px;
  border: 1px solid rgba(22, 199, 132, 0.35);
  background: #d1fadf;
  color: #065f46;
  font-size: 0.72rem;
  font-weight: 800;
  vertical-align: middle;
}

.copy-inline-mini {
  min-height: 20px;
  margin-left: 4px;
  padding: 2px 6px;
  font-size: 0.68rem;
}

.risk-low,
.hero-chip-low {
  color: #067647;
  border-color: rgba(18, 183, 106, 0.35);
  background: #ecfdf3;
}

.risk-medium,
.hero-chip-medium {
  color: #93370d;
  border-color: rgba(234, 170, 8, 0.38);
  background: #fffaeb;
}

.risk-high,
.hero-chip-high {
  color: #9a3412;
  border-color: rgba(249, 115, 22, 0.38);
  background: #fff7ed;
}

.risk-critical,
.hero-chip-critical {
  color: #b42318;
  border-color: rgba(239, 68, 68, 0.35);
  background: #fef3f2;
}

.risk-safe {
  color: #067647;
  border-color: rgba(18, 183, 106, 0.35);
  background: #ecfdf3;
}

.signal.neutral {
  color: var(--low);
}

.signal.medium {
  color: var(--medium);
}

.signal.high {
  color: var(--high);
}

.signal.critical {
  color: var(--critical);
}

.status.panel.level-low {
  border-left-color: var(--low);
}

.status.panel.level-medium {
  border-left-color: var(--medium);
}

.status.panel.level-high {
  border-left-color: var(--high);
}

.status.panel.level-critical {
  border-left-color: var(--critical);
}

.status.panel {
  border-left: 4px solid var(--accent);
  background: #ffffff;
  color: var(--ink);
}

.status.panel .muted {
  color: var(--muted);
}

.status.panel pre {
  max-height: 240px;
  overflow: auto;
  padding: 10px;
  border-radius: 6px;
  background: #f3f5f8;
  color: var(--ink);
}

.status.panel #decision-button,
button[data-action] {
  width: auto;
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 800;
}

.result-topline h2 {
  margin-bottom: 0;
  font-size: 1.15rem;
}

.score {
  font-family: var(--mono);
  font-weight: 900;
}

.decision-panel {
  margin: 10px 0;
}

.history-entry {
  border-left: 4px solid var(--accent);
}

.demo-step.pass {
  border-color: rgba(18, 183, 106, 0.45);
}

.demo-step.fail {
  border-color: rgba(239, 68, 68, 0.45);
}

.demo-step.running {
  border-color: rgba(234, 170, 8, 0.45);
}

.demo-note {
  margin-top: 12px;
  padding: 12px;
  border-radius: 6px;
  background: #111318;
}

.capability-band {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 28px;
  align-items: start;
  padding: 20px 0;
}

.capability-band h2,
.plans-section h2,
.contact-section h2 {
  margin-bottom: 8px;
  font-size: 2rem;
}

.capability-band p,
.plans-section p,
.contact-section p {
  color: var(--muted);
}

.capability-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.capability-grid article,
.plan-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.capability-grid h3,
.plan-card h3 {
  margin-bottom: 7px;
}

.image-band {
  width: min(1200px, calc(100% - 48px));
  margin: 0 auto 34px;
  display: grid;
  grid-template-columns: 1.2fr 0.9fr 0.9fr;
  gap: 12px;
}

.image-band img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: var(--radius);
}

.frontier-band {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 22px;
  align-items: stretch;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(135deg, rgba(20, 36, 78, 0.95), rgba(8, 12, 20, 0.98)),
    var(--graphite);
  color: #f8fafc;
}

.frontier-band h2,
.frontier-band p {
  margin-top: 0;
}

.frontier-band p {
  color: #c7d2e3;
}

.frontier-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.frontier-points article {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
  min-width: 0;
}

.frontier-points strong {
  color: #ffffff;
}

.frontier-points span {
  color: #b7c0ce;
  font-size: 0.94rem;
}

.plans-section,
.contact-section {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 28px;
  align-items: start;
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.plan-card {
  display: grid;
  gap: 12px;
}

.plan-card strong {
  font-size: 1.65rem;
}

.plan-kicker {
  display: inline-flex;
  width: max-content;
  max-width: 100%;
  margin-bottom: 4px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.plan-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted-strong);
}

.plan-card-dark {
  background: var(--graphite);
  border-color: var(--graphite);
  color: #f8fafc;
}

.plan-card-dark p,
.plan-card-dark ul {
  color: #b7c0ce;
}

.contact-section {
  padding-bottom: 54px;
}

.contact-form {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.contact-form label {
  color: var(--ink);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  background: #ffffff;
  border-color: var(--line);
  color: var(--ink);
}

.contact-form .mode-status {
  color: var(--muted);
}

@media (max-width: 1040px) {
  .site-header {
    grid-template-columns: auto 1fr;
  }

  .site-nav {
    order: 3;
    grid-column: 1 / -1;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero-inner,
  .console-grid,
  .capability-band,
  .plans-section,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .console-side {
    border-left: 0;
    border-top: 1px solid var(--line-dark);
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .platform-metrics,
  .capability-grid,
  .plans-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .site-header {
    padding: 10px 14px;
    grid-template-columns: 1fr;
    align-items: start;
  }

  .header-actions,
  .site-nav,
  .console-tabs {
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .header-actions {
    flex-wrap: wrap;
  }

  .hero {
    min-height: auto;
  }

  .hero-inner {
    width: min(100% - 28px, 1200px);
    padding: 84px 0 28px;
  }

  .hero h1 {
    font-size: 3rem;
  }

  .hero-lede {
    font-size: 1.25rem;
  }

  .platform-metrics,
  .console-shell,
  .capability-band,
  .image-band,
  .plans-section,
  .contact-section {
    width: min(100% - 28px, 1200px);
  }

  .platform-metrics,
  .form-grid,
  .explorer-controls,
  .explorer-stats,
  .capability-grid,
  .plans-grid,
  .image-band,
  .console-side {
    grid-template-columns: 1fr;
  }

  .platform-metrics article {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .platform-metrics article:last-child {
    border-bottom: 0;
  }

  .console-head,
  .section-head,
  .stream-head,
  .result-topline {
    display: grid;
  }

  .product-preview {
    display: none;
  }
}

/* Explorer transaction detail renderer */
.explorer-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
}

.explorer-detail-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  padding: 14px;
  min-width: 0;
}

.explorer-detail-card strong,
.explorer-result strong {
  overflow-wrap: anywhere;
}

.tx-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(6, 10, 16, 0.5);
  margin-top: 12px;
}

.tx-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.tx-table th,
.tx-table td {
  border-bottom: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.tx-table th {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.04);
}

.tx-table tr:last-child td {
  border-bottom: 0;
}

.tx-table code,
.tx-instruction code,
.tx-log-list code {
  color: #e9fff4;
  font-family: "Space Mono", Consolas, monospace;
  font-size: 0.82rem;
  overflow-wrap: anywhere;
  white-space: normal;
}

.tx-instruction-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.tx-instruction {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(6, 10, 16, 0.5);
  padding: 12px;
}

.tx-instruction-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 8px;
}

.tx-instruction-meta {
  color: var(--muted);
  font-size: 0.86rem;
}

.explorer-result details {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.025);
  padding: 12px 14px;
  margin-top: 12px;
}

.explorer-result summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 800;
}

.tx-log-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.tx-log-list li {
  border-left: 3px solid var(--accent);
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.075);
  border-radius: 8px;
}

@media (max-width: 760px) {
  .explorer-detail-grid {
    grid-template-columns: 1fr;
  }

  .tx-instruction-head {
    display: block;
  }
}

/* Viewport-safe console rail */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

.console-shell,
.console-grid,
.console-main,
.console-side,
.console-section,
.tool-panel,
.status-panel,
.status.panel,
.explorer-result {
  min-width: 0;
  max-width: 100%;
}

.console-grid {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
}

.console-side > *,
#status,
#status *,
.status-panel *,
.status.panel * {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}

#status,
.status-panel,
.status.panel {
  overflow: hidden;
}

#status a,
#status code,
#status strong,
#status p,
#status li,
#status span,
.status-panel a,
.status-panel code,
.status-panel strong,
.status-panel p,
.status-panel li,
.status-panel span,
.status.panel a,
.status.panel code,
.status.panel strong,
.status.panel p,
.status.panel li,
.status.panel span {
  white-space: normal;
}

#status button,
#status .copy-btn,
.status-panel button,
.status-panel .copy-btn,
.status.panel button,
.status.panel .copy-btn {
  max-width: max-content;
  white-space: nowrap;
  word-break: normal;
}

.recent-checks-panel {
  display: grid;
  gap: 10px;
}

.recent-checks-panel h3,
.recent-checks-panel p {
  margin: 0;
}

.recent-checks-panel .recent-checks {
  display: grid;
  gap: 10px;
}

.recent-checks-panel .recent-checks > * {
  min-width: 0;
  max-width: 100%;
  padding: 12px;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.recent-checks-panel .recent-checks strong,
.recent-checks-panel .recent-checks span,
.recent-checks-panel .recent-checks p {
  white-space: normal;
  overflow-wrap: anywhere;
}

.history-entry-action {
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.history-entry-action:hover,
.history-entry-action:focus-visible {
  border-color: rgba(80, 200, 140, 0.55);
  background: rgba(80, 200, 140, 0.06);
  outline: none;
  transform: translateY(-1px);
}

.history-entry-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px !important;
  color: #b6c2dc;
  font-size: 0.82rem;
}

.history-rerun-btn {
  flex: 0 0 auto;
}

.truth-label {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 4px 9px;
  border: 1px solid rgba(80, 200, 140, 0.35);
  border-radius: 999px;
  background: rgba(80, 200, 140, 0.12);
  color: #b8f6d0;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.evidence-actions {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.evidence-actions strong,
.evidence-actions p {
  margin: 0;
}

.evidence-actions p {
  color: var(--muted);
}

.evidence-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.evidence-buttons .btn,
.evidence-buttons .copy-inline {
  max-width: 100%;
}

.explorer-transaction-view {
  display: grid;
  gap: 16px;
}

.explorer-title-row,
.explorer-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
}

.explorer-title-row h3,
.explorer-card-head h4 {
  margin: 0;
  overflow-wrap: anywhere;
}

.explorer-section-stack {
  display: grid;
  gap: 14px;
}

.explorer-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
  padding: 16px;
  min-width: 0;
  overflow: hidden;
}

.explorer-overview-card {
  border-color: rgba(80, 200, 140, 0.28);
}

.explorer-risk-card {
  border-color: rgba(245, 180, 72, 0.32);
}

.explorer-fact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.explorer-fact-grid.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.explorer-fact {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(6, 10, 16, 0.45);
}

.explorer-fact span {
  color: #9aa8c6;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.explorer-fact strong {
  color: #f7fbff;
  font-size: 0.95rem;
  overflow-wrap: anywhere;
}

.explorer-fact .copy-inline {
  justify-self: start;
  max-width: max-content;
}

.explorer-result .tx-table,
.explorer-result .tx-table td,
.explorer-result .tx-instruction,
.explorer-result .tx-instruction p,
.explorer-result .tx-instruction strong,
.explorer-result .tx-log-list,
.explorer-result .tx-log-list li {
  color: #f7fbff;
}

.explorer-result .tx-instruction-meta,
.explorer-result .muted {
  color: #b6c2dc;
}

@media (max-width: 1380px) {
  .console-grid {
    grid-template-columns: 1fr;
  }

  .console-side {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #status {
    grid-column: 1 / -1;
  }
}

@media (max-width: 900px) {
  .console-side {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .explorer-title-row,
  .explorer-card-head {
    display: grid;
  }

  .explorer-fact-grid,
  .explorer-fact-grid.compact {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1180px) {
  .frontier-band {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .frontier-points {
    grid-template-columns: 1fr;
  }
}

/* Workflow deck */
.workflow-deck {
  display: grid;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.workflow-deck-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.workflow-deck-head h3,
.workflow-deck-head p {
  margin: 0;
}

.workflow-tabs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.workflow-tab {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: #d9e1ee;
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  padding: 10px 14px;
}

.workflow-tab:hover,
.workflow-tab.is-active {
  border-color: rgba(80, 200, 140, 0.55);
  background: rgba(80, 200, 140, 0.16);
  color: #d8ffe8;
}

.workflow-panel {
  display: none;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.workflow-panel.is-active {
  display: block;
}

.workflow-panel.hidden,
body.mode-demo .workflow-deck,
body.mode-demo .investigation-output {
  display: none !important;
}

.workflow-deck > .workflow-panel,
.workflow-deck > .workflow-panel > .tool-panel,
.workflow-deck > .tool-panel.workflow-panel {
  padding: 18px;
}

.stream-panel .stream-head {
  margin-bottom: 12px;
}

.investigation-output {
  display: grid;
  gap: 14px;
}

.investigation-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid rgba(80, 200, 140, 0.25);
  border-radius: 14px;
  background: rgba(80, 200, 140, 0.08);
}

.investigation-actions strong,
.investigation-actions p {
  margin: 0;
}

.investigation-actions p {
  color: var(--muted);
}

.live-sample-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid rgba(80, 200, 140, 0.22);
  border-radius: 14px;
  background: rgba(80, 200, 140, 0.07);
}

.live-sample-actions span {
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .workflow-deck-head {
    display: grid;
  }

  .workflow-tabs {
    justify-content: flex-start;
  }

  .investigation-actions {
    display: grid;
  }

  .live-sample-actions {
    display: grid;
  }
}
