:root {
  color-scheme: dark;
  --bg: #04101a;
  --panel: #081c2a;
  --panel-2: #0a2534;
  --line: rgba(100, 221, 234, .18);
  --text: #eafcff;
  --muted: #8caebb;
  --cyan: #19e0eb;
  --teal: #36bdb6;
  --amber: #f3a712;
  --danger: #ff6b5f;
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 76% 2%, rgba(11, 118, 143, .19), transparent 31rem),
    linear-gradient(rgba(25,224,235,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(25,224,235,.025) 1px, transparent 1px), var(--bg);
  background-size: auto, 34px 34px, 34px 34px, auto;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: inherit; text-decoration: none; }
button, textarea { font: inherit; }
.topbar {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between;
  min-height: 72px; padding: 0 max(5vw, 24px); border-bottom: 1px solid var(--line);
  background: rgba(4,16,26,.82); backdrop-filter: blur(18px);
}
.brand { font-weight: 800; letter-spacing: -.02em; }
.brand-mark { display: inline-grid; place-items: center; width: 33px; height: 33px; margin-right: 9px; border: 1px solid var(--cyan); border-radius: 8px; color: var(--cyan); font: 700 12px ui-monospace, monospace; }
nav { display: flex; align-items: center; gap: 28px; color: var(--muted); font-size: 14px; }
nav a:hover { color: var(--text); }
.nav-cta { padding: 9px 15px; border: 1px solid var(--line); border-radius: 99px; color: var(--text); }
main, footer { width: min(1180px, 90vw); margin-inline: auto; }
.hero { min-height: 650px; display: grid; grid-template-columns: 1.12fr .88fr; align-items: center; gap: 6vw; padding: 90px 0 70px; }
.eyebrow { color: var(--cyan); text-transform: uppercase; letter-spacing: .17em; font-size: 11px; font-weight: 800; }
.eyebrow span { display: inline-block; width: 7px; height: 7px; margin-right: 9px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 17px var(--cyan); }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 25px; font-size: clamp(54px, 7vw, 92px); line-height: .96; letter-spacing: -.065em; }
h1 em { color: var(--cyan); font-style: normal; }
.lede { max-width: 650px; color: var(--muted); font-size: clamp(17px, 1.7vw, 21px); line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button { min-height: 46px; padding: 0 19px; border: 1px solid transparent; border-radius: 10px; cursor: pointer; font-weight: 750; transition: .2s ease; }
.button:hover { transform: translateY(-2px); }
.primary { background: var(--cyan); color: #001116; box-shadow: 0 9px 35px rgba(25,224,235,.15); }
.scope-art { position: relative; aspect-ratio: 1; border: 1px solid var(--line); border-radius: 50%; background: radial-gradient(circle, rgba(25,224,235,.11), transparent 63%); box-shadow: inset 0 0 70px rgba(25,224,235,.06), 0 0 70px rgba(4,90,107,.12); overflow: hidden; }
.reticle { position: absolute; inset: 12%; border: 1px solid rgba(25,224,235,.4); border-radius: 50%; }
.reticle::before, .reticle::after { content: ""; position: absolute; background: rgba(25,224,235,.25); }
.reticle::before { width: 1px; height: 116%; left: 50%; top: -8%; }
.reticle::after { height: 1px; width: 116%; top: 50%; left: -8%; }
.reticle span { position: absolute; width: 16%; height: 16%; border-color: var(--cyan); border-style: solid; }
.reticle span:nth-child(1) { left: 9%; top: 9%; border-width: 2px 0 0 2px; }
.reticle span:nth-child(2) { right: 9%; top: 9%; border-width: 2px 2px 0 0; }
.reticle span:nth-child(3) { left: 9%; bottom: 9%; border-width: 0 0 2px 2px; }
.reticle span:nth-child(4) { right: 9%; bottom: 9%; border-width: 0 2px 2px 0; }
.qr-grid { position: absolute; inset: 27%; image-rendering: pixelated; opacity: .85; background: conic-gradient(from 90deg at 25% 25%, var(--cyan) 25%, transparent 0 50%, var(--cyan) 0 75%, transparent 0) 0 0/28px 28px; clip-path: polygon(0 0,100% 0,100% 25%,86% 25%,86% 41%,100% 41%,100% 100%,63% 100%,63% 86%,43% 86%,43% 100%,0 100%); }
.scanline { position: absolute; left: 15%; right: 15%; top: 30%; height: 2px; background: var(--cyan); box-shadow: 0 0 18px 3px var(--cyan); animation: scan 3.7s ease-in-out infinite alternate; }
@keyframes scan { to { top: 70%; } }
.risk-chip { position: absolute; right: 0; bottom: 15%; padding: 11px 15px; border: 1px solid var(--line); background: rgba(4,16,26,.88); border-radius: 9px; }
.risk-chip b, .risk-chip small { display: block; }
.risk-chip b { color: var(--cyan); font: 800 12px ui-monospace, monospace; }
.risk-chip small { margin-top: 3px; color: var(--muted); font-size: 9px; letter-spacing: .11em; }
.playground, .signals, .pipeline { padding: 90px 0; border-top: 1px solid var(--line); }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 50px; margin-bottom: 35px; }
h2 { margin-bottom: 0; font-size: clamp(36px, 5vw, 61px); letter-spacing: -.05em; }
.section-heading > p { max-width: 470px; margin-bottom: 5px; color: var(--muted); line-height: 1.6; }
.workbench { display: grid; grid-template-columns: 1fr 1fr; min-height: 430px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(8,28,42,.8); box-shadow: 0 25px 80px rgba(0,0,0,.23); }
.input-panel, .result-panel { padding: 30px; }
.input-panel { border-right: 1px solid var(--line); }
label, .score-row small { color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.image-picker { margin-bottom: 20px; }
.drop-zone {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 15px;
  min-height: 108px;
  padding: 17px;
  border: 1px dashed rgba(25, 224, 235, .48);
  border-radius: 11px;
  background: rgba(4, 19, 31, .82);
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}
.drop-zone.dragging {
  border-color: var(--cyan);
  background: rgba(25, 224, 235, .09);
  transform: translateY(-2px);
}
.drop-zone[data-state="busy"] { opacity: .72; }
.drop-mark {
  position: relative;
  width: 45px;
  height: 45px;
  border: 2px solid var(--cyan);
}
.drop-mark::before,
.drop-mark::after,
.drop-mark i::before,
.drop-mark i::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  background: var(--cyan);
}
.drop-mark::before { left: 6px; top: 6px; }
.drop-mark::after { right: 6px; top: 6px; }
.drop-mark i::before { left: 6px; bottom: 6px; }
.drop-mark i::after { right: 9px; bottom: 9px; box-shadow: -8px -8px 0 var(--cyan); }
.drop-copy strong,
.drop-copy small { display: block; }
.drop-copy strong { margin-bottom: 6px; font-size: 14px; }
.drop-copy small { color: var(--muted); font-size: 10px; line-height: 1.45; }
.picker-button {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--cyan);
  border-radius: 8px;
  background: transparent;
  color: var(--cyan);
  cursor: pointer;
  font-size: 11px;
  font-weight: 800;
}
.picker-button:hover,
.picker-button:focus-visible { background: var(--cyan); color: var(--bg); outline: none; }
.picker-button:disabled { cursor: wait; opacity: .55; }
.decode-feedback {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 47px;
  margin-top: 9px;
}
.decode-feedback img {
  width: 43px;
  height: 43px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  object-fit: contain;
}
.decode-feedback img[hidden] { display: none; }
.decode-feedback p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.45; }
.decode-feedback p[data-state="busy"] { color: var(--cyan); }
.decode-feedback p[data-state="success"] { color: var(--teal); }
.decode-feedback p[data-state="error"] { color: var(--danger); }
.payload-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 4px 0 18px;
  color: var(--muted);
  font: 700 9px ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.payload-divider::before,
.payload-divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }
textarea { width: 100%; min-height: 195px; margin: 12px 0; padding: 18px; resize: vertical; border: 1px solid var(--line); border-radius: 10px; outline: none; background: #04131f; color: #c9f8fa; font: 14px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; }
textarea:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(25,224,235,.09); }
.samples { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 16px; }
.samples button { padding: 6px 10px; border: 1px solid var(--line); border-radius: 99px; background: transparent; color: var(--muted); cursor: pointer; font-size: 11px; }
.samples button:hover { border-color: var(--cyan); color: var(--cyan); }
.full { width: 100%; }
.result-panel { background: linear-gradient(145deg, rgba(10,37,52,.8), rgba(4,16,26,.75)); }
.score-row { display: flex; justify-content: space-between; align-items: center; padding-bottom: 23px; border-bottom: 1px solid var(--line); }
.score-row strong { display: block; margin-top: 3px; font-size: 52px; letter-spacing: -.06em; }
.level { padding: 7px 10px; border: 1px solid var(--line); border-radius: 99px; color: var(--muted); font: 800 10px ui-monospace, monospace; }
.level.low { color: var(--teal); border-color: var(--teal); }
.level.medium { color: var(--amber); border-color: var(--amber); }
.level.high, .level.critical { color: var(--danger); border-color: var(--danger); }
.preview { margin: 20px 0; color: #b9d4dc; font: 13px/1.55 ui-monospace, monospace; overflow-wrap: anywhere; }
.findings { display: grid; gap: 8px; padding: 0; list-style: none; }
.findings li { display: grid; grid-template-columns: 43px 1fr; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; background: rgba(4,16,26,.48); }
.findings b { color: var(--amber); font: 800 12px ui-monospace, monospace; }
.findings span { color: #c8e1e7; font-size: 13px; }
.signal-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; }
.signal-grid article { min-height: 245px; padding: 25px; border: 1px solid var(--line); border-radius: 13px; background: linear-gradient(145deg, rgba(10,37,52,.68), rgba(4,16,26,.4)); }
.signal-grid article > span { color: var(--cyan); font: 700 11px ui-monospace, monospace; }
.signal-grid h3 { margin: 65px 0 12px; font-size: 19px; }
.signal-grid p { color: var(--muted); font-size: 14px; line-height: 1.6; }
.pipeline { text-align: center; }
.steps { display: flex; align-items: center; justify-content: center; margin-top: 45px; }
.steps div { min-width: 170px; padding: 20px 12px; }
.steps b, .steps span, .steps small { display: block; }
.steps b { width: 31px; height: 31px; margin: 0 auto 13px; padding-top: 7px; border-radius: 50%; background: var(--cyan); color: var(--bg); font-size: 12px; }
.steps span { font-weight: 800; }
.steps small { margin-top: 7px; color: var(--muted); }
.steps i { color: var(--cyan); font-style: normal; }
footer { display: flex; justify-content: space-between; padding: 35px 0 50px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
footer a:hover { color: var(--cyan); }
@media (max-width: 860px) {
  nav a:not(.nav-cta) { display: none; }
  .hero { grid-template-columns: 1fr; padding-top: 65px; }
  .scope-art { width: min(500px, 88vw); margin-inline: auto; }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 18px; }
  .workbench { grid-template-columns: 1fr; }
  .input-panel { border-right: 0; border-bottom: 1px solid var(--line); }
  .signal-grid { grid-template-columns: 1fr 1fr; }
  .steps { display: grid; grid-template-columns: 1fr 1fr; }
  .steps i { display: none; }
}
@media (max-width: 520px) {
  main, footer { width: min(92vw, 1180px); }
  h1 { font-size: 50px; }
  .scope-art { width: 100%; }
  .signal-grid { grid-template-columns: 1fr; }
  .workbench .input-panel, .workbench .result-panel { padding: 21px; }
  .drop-zone { grid-template-columns: auto 1fr; }
  .picker-button { grid-column: 1 / -1; width: 100%; }
  footer { display: grid; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; }
}
