:root {
  --signal: #1C7AFE;
  --signal-dark: #0F5BC9;
  --accent-on-dark: #BBD7FF;
  --indigo: #1E1A4E;
  --ink: #111E45;
  --ink-2: #384366;
  --ink-3: #525D7E;
  --ink-4: #6C7694;
  --line: #E5E8EF;
  --paper-warm: #F2F4F9;
  --matrix: #1FB879;
  --matrix-deep: #0E7A4C;
  --caution: #E5A33A;
  --caution-deep: #8A5D08;
  --adverse: #DC3E3E;
  --adverse-deep: #B12626;
  --forest: #0A8C82;
  --forest-deep: #0A7A72;
  --font: 'Onest', system-ui, -apple-system, sans-serif;
  --mono: 'SUSE Mono', ui-monospace, SFMono-Regular, monospace;
}

* { box-sizing: border-box; }

/* ── hero eyebrow + CTAs (marketing embed) ─────────────────── */
.hero-kicker {
  font-family: var(--font);
  text-transform: uppercase;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.13em;
  color: var(--signal);
  margin: 0 0 14px;
}
.hero-ctas {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
  margin: 0 0 36px;
}
.hero-btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font); font-weight: 600; font-size: 15px;
  padding: 12px 22px; border-radius: 10px; text-decoration: none;
  cursor: pointer; transition: transform .15s ease, box-shadow .15s ease;
}
.hero-btn-primary { background: var(--ink); color: #fff; }
.hero-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(17,30,69,0.22); }
.hero-btn-secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.hero-btn-secondary:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(17,30,69,0.10); }
body { margin: 0; font-family: var(--font); background: #fff; }

/* ── hero shell — light signal washing out to white ─────────── */
.hero {
  position: relative;
  background:
    radial-gradient(1100px 620px at 12% 2%, rgba(28,122,254,0.16), transparent 62%),
    radial-gradient(900px 560px at 88% 0%, rgba(28,122,254,0.10), transparent 64%),
    linear-gradient(170deg, #E9F1FE 0%, #F6F9FF 52%, #FFFFFF 100%);
  padding: 76px 32px 0;
  overflow: hidden;
  text-align: center;
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(17,30,69,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(17,30,69,0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 62%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 62%, transparent 100%);
}
.hero-inner { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; }

.hero-headline {
  font-size: clamp(40px, 4.4vw, 57px);
  line-height: 1.07;
  letter-spacing: -0.02em;
  font-weight: 700;
  color: var(--ink);
  text-wrap: balance;
  margin: 0 0 18px;
}
/* Signal on white, not accentOnDark — that token only reads on dark surfaces. */
.hero-headline em { color: var(--signal); font-weight: 300; font-style: normal; }
.hero-sub {
  font-size: 17px; line-height: 1.55; color: var(--ink-2);
  /* wide enough to set on two lines; still narrower than the search bar */
  max-width: 780px; margin: 0 auto 34px;
}

/* ── search bar ─────────────────────────────────────────────── */
.stage { max-width: 880px; margin: 0 auto; text-align: left; }
.search {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 12px;
  padding: 12px 12px 12px 16px;
  box-shadow: 0 10px 30px rgba(17,30,69,0.10); border: 1px solid var(--line);
  position: relative; z-index: 2;
}
.search-ico {
  width: 15px; height: 15px; flex: none; border-radius: 50%;
  border: 2px solid var(--ink-4); position: relative;
}
.search-ico::after {
  content: ""; position: absolute; right: -4px; bottom: -3px;
  width: 6px; height: 2px; background: var(--ink-4); border-radius: 2px;
  transform: rotate(45deg);
}
.search-text { font-size: 15px; color: var(--ink); font-weight: 500; white-space: nowrap; }
.caret {
  display: inline-block; width: 1.5px; height: 17px; background: var(--signal);
  margin-left: 1px; vertical-align: -3px;
  animation: blink 1s steps(1) infinite;
}
.caret.off { opacity: 0; animation: none; }
@keyframes blink { 0%, 50% { opacity: 1; } 50.01%, 100% { opacity: 0; } }
.search-btn {
  margin-left: auto; flex: none;
  background: var(--indigo); color: #fff;
  font-size: 13px; font-weight: 600;
  padding: 9px 18px; border-radius: 9px;
}

/* ── panel ──────────────────────────────────────────────────── */
.panel {
  margin-top: 14px;
  background: #fff; border-radius: 14px;
  box-shadow: 0 1px 2px rgba(17,30,69,0.05), 0 14px 40px rgba(17,30,69,0.10); border: 1px solid var(--line);
  padding: 20px 22px 22px;
  min-height: 452px;
  position: relative;
}

/* thinking — a floating pill so it can sit over the previous, dimmed result */
.thinking {
  position: absolute; left: 50%; top: 26px; transform: translateX(-50%);
  z-index: 3;
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 100px; padding: 9px 16px 9px 11px;
  box-shadow: 0 6px 22px rgba(17,30,69,0.12);
  opacity: 0; transition: opacity .25s ease;
  pointer-events: none; white-space: nowrap;
}
.thinking.on { opacity: 1; }
.thinking-mark {
  width: 22px; height: 22px; border-radius: 7px; flex: none;
  background: var(--indigo); color: #fff;
  font-family: var(--mono); font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.thinking-text { font-size: 13px; color: var(--ink-3); }
.thinking-bar {
  margin-left: auto; width: 160px; height: 3px; border-radius: 3px;
  background: var(--paper-warm); overflow: hidden;
}
/* Determinate: width is driven from the timeline so the bar always reaches
   100% before the snapshot swaps in. */
.thinking-bar i {
  display: block; height: 100%; width: 0; border-radius: 3px;
  background: linear-gradient(90deg, var(--signal), var(--indigo));
}

/* skeleton — first load only; afterwards the previous result holds the space */
.skeleton { display: none; }
.skeleton.on { display: block; }
.sk {
  display: block; border-radius: 6px;
  background: linear-gradient(90deg, #EDEFF4 25%, #F6F7FA 50%, #EDEFF4 75%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease-in-out infinite;
}
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.sk-pill { width: 96px; height: 14px; border-radius: 100px; margin-bottom: 12px; }
.sk-title { width: 58%; height: 28px; border-radius: 8px; margin-bottom: 9px; }
.sk-sub { width: 34%; height: 10px; margin-bottom: 18px; }
.sk-row { display: flex; gap: 8px; margin-bottom: 16px; }
.sk-chip { width: 150px; height: 34px; border-radius: 10px; }
.sk-block { width: 100%; height: 118px; border-radius: 12px; margin-bottom: 16px; }
.sk-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
.sk-tile { height: 52px; border-radius: 9px; }

/* snapshot */
.snap { position: relative; transition: opacity .3s ease; }
.snap.hidden { display: none; }
.snap.stale { opacity: 0.38; }
.snap [data-step] {
  opacity: 0; transform: translateY(10px);
  transition: opacity .45s ease, transform .45s cubic-bezier(.22,.9,.3,1);
}
.snap [data-step].on { opacity: 1; transform: none; }

.snap-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.pill {
  display: inline-block;
  font-family: var(--mono); font-size: 8px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--matrix-deep); background: rgba(31,184,121,0.13);
  border-radius: 100px; padding: 4px 9px; margin-bottom: 8px;
}
.snap-title {
  font-size: 27px; font-weight: 700; letter-spacing: -0.025em;
  color: var(--ink); line-height: 1.1; margin-bottom: 4px;
}
.snap-sub {
  font-family: var(--mono); font-size: 9.5px; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3);
}
.snap-monitor-wrap { position: relative; flex: none; }
.snap-monitor {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font); font-size: 11px; font-weight: 500; color: var(--ink-3);
  border: 1px dashed var(--line); border-radius: 9px; padding: 7px 12px;
  background: #fff; cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .12s ease;
}
.snap-monitor .dot {
  width: 7px; height: 7px; border-radius: 50%;
  border: 1.5px solid var(--ink-4);
  transition: background .15s ease, border-color .15s ease, box-shadow .15s ease;
}
/* pressed → armed: the click reads as a state change, not just a hover */
.snap-monitor.pressed { transform: scale(0.96); }
.snap-monitor.armed {
  border-style: solid; border-color: rgba(31,184,121,0.45);
  background: rgba(31,184,121,0.08); color: var(--matrix-deep);
}
.snap-monitor.armed .dot {
  background: var(--matrix); border-color: var(--matrix);
  box-shadow: 0 0 0 3px rgba(31,184,121,0.18);
}

.monitor-pop {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 4;
  width: 268px; text-align: left;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 14px 38px rgba(17,30,69,0.14);
  padding: 13px 14px 12px;
  opacity: 0; transform: translateY(-6px) scale(0.98); pointer-events: none;
  transition: opacity .28s ease, transform .28s cubic-bezier(.22,.9,.3,1);
}
.monitor-pop.on { opacity: 1; transform: none; }
.monitor-pop-head {
  display: flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 600; color: var(--ink); margin-bottom: 6px;
}
.monitor-pop-live {
  width: 7px; height: 7px; border-radius: 50%; background: var(--matrix);
  box-shadow: 0 0 0 3px rgba(31,184,121,0.18);
}
.monitor-pop-lede { font-size: 11.5px; line-height: 1.45; color: var(--ink-3); margin: 0 0 10px; }
.monitor-pop-list { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 5px; }
.monitor-pop-list li {
  display: flex; align-items: center; gap: 7px;
  font-size: 11px; color: var(--ink-2);
}
.monitor-pop-list li::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: var(--forest); flex: none;
}
.monitor-pop-foot {
  padding-top: 9px; border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--ink-4);
}

/* verified-source chips — matches .co-web-chips .fc-chip in the workbench */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(17,30,69,0.05); border: 1px solid transparent;
  border-radius: 10px; padding: 8px 12px;
  font-size: 12px; font-weight: 500; color: var(--ink);
}
.chip-ico { width: 15px; height: 15px; color: var(--ink-3); stroke-width: 1.85; flex: none; }
.chip-arw { width: 15px; height: 15px; color: var(--ink-3); stroke-width: 2; flex: none; margin-left: -2px; }

/* Marvin's analysis */
.analysis {
  margin-top: 16px;
  background: linear-gradient(135deg, rgba(28,122,254,0.06) 0%, #ffffff 100%);
  border: 1px solid rgba(28,122,254,0.12); border-radius: 12px;
  border-left: 3px solid var(--risk-color, var(--ink-4));
  padding: 13px 16px 14px;
}
.analysis-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 11px; }
.analysis-kicker {
  font-family: var(--mono); font-size: 8.5px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--indigo);
}
.analysis-sources {
  margin-left: auto; font-family: var(--mono); font-size: 9.5px; color: var(--ink-4);
}
.analysis-row { display: flex; align-items: flex-end; gap: 28px; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat-k {
  font-family: var(--mono); font-size: 8.5px; font-weight: 600;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-4);
}
.stat-v { font-size: 23px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); line-height: 1; }
.stat-v.risk { color: var(--risk-color); }
.analysis-flags {
  margin-left: auto; display: flex; flex-direction: column; gap: 4px; align-items: flex-end;
}
.flag { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; color: var(--ink-2); }
.flag i { width: 6px; height: 6px; border-radius: 50%; flex: none; }
.flag i.a { background: var(--caution); }
.flag i.g { background: var(--matrix); }
.analysis-note {
  margin-top: 11px; padding-top: 10px;
  border-top: 1px solid rgba(28,122,254,0.12);
  font-size: 12.5px; line-height: 1.55; color: var(--ink-2);
  /* reserves four lines so the panel doesn't jump between companies */
  min-height: 78px;
}
.analysis-note b { font-weight: 600; color: var(--ink); }

/* Core+ packs */
.packs { margin-top: 15px; }
.packs-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 9px; }
.packs-title { font-size: 12.5px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; }
.packs-badge {
  font-family: var(--mono); font-size: 7.5px; font-weight: 700;
  letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--forest-deep); background: rgba(10,140,130,0.10);
  border-radius: 100px; padding: 3px 8px;
}
.packs-note { font-size: 9.5px; color: var(--ink-4); }
.packs-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
/* Compact tiles — icon sits inline with the name so each tile is one short row
   plus its state, roughly half the height of the stacked version. */
.pack {
  position: relative;
  border: 1px solid var(--line); border-radius: 9px;
  padding: 8px 9px;
  display: flex; flex-direction: column; gap: 4px;
  opacity: 0; transform: translateY(8px) scale(0.98);
  transition: opacity .32s ease, transform .32s cubic-bezier(.22,.9,.3,1);
}
.pack.on { opacity: 1; transform: none; }
.pack-row { display: flex; align-items: center; gap: 7px; }
.pack-ico {
  width: 20px; height: 20px; border-radius: 6px; flex: none;
  background: rgba(10,140,130,0.11); color: var(--forest-deep);
  display: flex; align-items: center; justify-content: center;
}
.pack-ico svg { width: 12px; height: 12px; stroke-width: 1.9; }
.pack.locked .pack-ico { background: var(--paper-warm); color: var(--ink-4); }
.pack-name { font-size: 9.5px; font-weight: 600; color: var(--ink); line-height: 1.2; }
.pack-state {
  font-size: 8px; font-weight: 500;
  letter-spacing: 0.02em; color: var(--forest-deep); padding-left: 25px;
}
.pack.locked .pack-state { color: var(--ink-4); }
.pack-lock {
  position: absolute; top: 7px; right: 7px;
  width: 10px; height: 10px; border-radius: 2px;
  border: 1.5px solid var(--ink-4); border-top-left-radius: 5px; border-top-right-radius: 5px;
  opacity: 0.7;
}

/* progress dots */
.dots { display: flex; gap: 7px; justify-content: center; padding: 20px 0 30px; }
.dots span {
  width: 26px; height: 3px; border-radius: 3px;
  background: rgba(17,30,69,0.12); overflow: hidden;
}
.dots span i {
  display: block; height: 100%; width: 0; background: var(--signal);
}
.dots span.done i { width: 100%; }

@media (max-width: 760px) {
  .hero { padding: 52px 20px 0; }
  .packs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .analysis-row { flex-wrap: wrap; gap: 18px; }
  .analysis-flags { margin-left: 0; align-items: flex-start; }
  .panel { min-height: 460px; }
}

@media (prefers-reduced-motion: reduce) {
  .snap [data-step], .pack { opacity: 1; transform: none; transition: none; }
  .caret, .thinking-bar i, .dots span.run i { animation: none; }
}

/* ── Company registration reveal — the classification detail ─────────
   Anchors to the chips row; only the first company opens it. */
.chips { position: relative; }
.chip[data-chip-reg] { transition: background .15s ease, border-color .15s ease, transform .12s ease; }
.chip.pressed { transform: scale(0.96); }
.chip.open {
  background: rgba(28,122,254,0.08);
  border-color: rgba(28,122,254,0.30);
  color: var(--signal-dark);
}
.chip.open .chip-ico, .chip.open .chip-arw { color: var(--signal); }

.reg-pop {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 4;
  width: 330px; text-align: left;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 14px 38px rgba(17,30,69,0.14);
  padding: 14px 15px 12px;
  opacity: 0; transform: translateY(-6px) scale(0.98); pointer-events: none;
  transition: opacity .28s ease, transform .28s cubic-bezier(.22,.9,.3,1);
}
.reg-pop.on { opacity: 1; transform: none; }
.reg-pop-head {
  display: flex; align-items: center; gap: 7px;
  font-size: 11px; font-weight: 600; color: var(--ink-3);
  padding-bottom: 10px; margin-bottom: 11px; border-bottom: 1px solid var(--line);
}
.reg-pop-head svg { width: 13px; height: 13px; stroke-width: 1.9; }

.reg-naics { display: flex; align-items: center; gap: 12px; }
.reg-naics-code {
  font-family: var(--mono); font-size: 26px; font-weight: 700;
  letter-spacing: -0.02em; color: var(--signal); line-height: 1;
}
.reg-naics-name { font-size: 13px; font-weight: 600; color: var(--ink); }
.reg-naics-conf {
  display: flex; align-items: center; gap: 6px;
  font-size: 10px; color: var(--ink-3); margin-top: 4px;
}
.reg-bar {
  width: 52px; height: 3px; border-radius: 3px;
  background: var(--paper-warm); overflow: hidden; flex: none;
}
.reg-bar i { display: block; height: 100%; background: var(--signal); border-radius: 3px; }

.reg-secondary {
  display: flex; align-items: center; gap: 7px;
  margin-top: 11px; padding-top: 10px; border-top: 1px dashed var(--line);
  font-size: 10.5px; color: var(--ink-3);
}
.reg-2nd-label {
  font-family: var(--mono); font-size: 8px; font-weight: 700;
  letter-spacing: 0.09em; text-transform: uppercase; color: var(--ink-4);
}

.reg-rows { margin-top: 11px; display: flex; flex-direction: column; gap: 6px; }
.reg-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.reg-k {
  font-family: var(--mono); font-size: 8.5px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-4);
}
.reg-v { font-size: 11px; color: var(--ink-2); text-align: right; }
.reg-v b { font-weight: 600; color: var(--matrix-deep); }
.reg-src {
  margin-top: 11px; padding-top: 9px; border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: 9px; color: var(--ink-4);
}


/* "What we can't find is as loud as what we can" — absent facts are shown, not
   hidden or invented. Sleepy Poet genuinely has no incorporation date or EIN on
   file, and the hero says so rather than filling the gap. */
.reg-unknown {
  color: var(--ink-4, #8B97B4);
  font-style: normal;
  border-bottom: 1px dotted currentColor;
  padding-bottom: 1px;
}
