:root {
  color-scheme: dark;
  --bg: #07141f;
  --panel: #0d2030;
  --panel-2: #112a3c;
  --line: #24465a;
  --text: #eef7fb;
  --muted: #9eb4c2;
  --teal: #25d5c7;
  --blue: #5aa9ff;
  --yellow: #ffc857;
  --red: #ff6b6b;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: radial-gradient(circle at 80% -10%, #16475b 0, transparent 36%), var(--bg); color: var(--text); font: 15px/1.5 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; min-height: 100vh; }
.topbar { height: 66px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 5vw; background: rgba(7,20,31,.82); backdrop-filter: blur(16px); position: sticky; top: 0; z-index: 3; }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 18px; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; color: #041118; background: linear-gradient(135deg, var(--teal), var(--blue)); font-size: 13px; }
.mode, .eyebrow, .kicker { color: var(--teal); letter-spacing: .14em; font-size: 11px; font-weight: 800; }
main { width: min(1500px, 92vw); margin: 0 auto; padding: 54px 0 80px; }
.hero { display: grid; grid-template-columns: 1.5fr .8fr; gap: 56px; align-items: end; margin-bottom: 42px; }
h1 { font-size: clamp(38px, 5.5vw, 76px); line-height: .98; max-width: 900px; margin: 10px 0 24px; letter-spacing: -.045em; }
.lede { color: #bdd0dc; max-width: 800px; font-size: 19px; }
.hero-card { border: 1px solid var(--line); border-radius: 22px; padding: 22px 26px; background: linear-gradient(145deg, rgba(24,60,79,.9), rgba(10,29,43,.92)); box-shadow: 0 24px 70px rgba(0,0,0,.22); }
.hero-card > span { color: var(--blue); font-weight: 800; text-transform: uppercase; font-size: 11px; letter-spacing: .13em; }
.hero-card ol { margin: 14px 0 0; padding-left: 22px; color: #dce9ef; }
.hero-card li { padding: 4px 0; }
.workspace { display: grid; grid-template-columns: minmax(390px,.8fr) minmax(520px,1.2fr); gap: 26px; align-items: start; }
.panel { border: 1px solid var(--line); border-radius: 24px; background: rgba(13,32,48,.92); box-shadow: 0 25px 80px rgba(0,0,0,.2); }
.input-panel { padding: 26px; position: sticky; top: 90px; }
.results-panel { min-height: 610px; padding: 28px; }
.panel-heading, .result-head { display: flex; align-items: start; justify-content: space-between; gap: 24px; }
h2 { margin: 2px 0 18px; font-size: 27px; line-height: 1.15; }
h3 { margin: 28px 0 12px; font-size: 15px; color: #dce8ef; }
label { display: block; color: #dbe8ef; font-weight: 700; margin: 16px 0; }
input, textarea { width: 100%; margin-top: 8px; color: var(--text); background: #081722; border: 1px solid #2b5066; border-radius: 12px; padding: 12px 13px; font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
textarea { resize: vertical; }
button { border: 0; border-radius: 11px; padding: 12px 16px; font-weight: 800; cursor: pointer; }
button:disabled { opacity: .6; cursor: wait; }
.primary { width: 100%; background: linear-gradient(135deg, var(--teal), #49a8ff); color: #041219; font-size: 15px; }
.secondary { background: #17374b; color: #cae0eb; border: 1px solid #31566d; font-size: 12px; }
.hint { color: var(--muted); font-size: 12px; margin-bottom: 0; }
.empty { min-height: 545px; display: grid; place-content: center; text-align: center; color: var(--muted); }
.empty h2 { color: var(--text); margin-top: 22px; }
.radar { width: 94px; height: 94px; margin: auto; border: 1px solid var(--teal); border-radius: 50%; background: radial-gradient(circle, rgba(37,213,199,.5) 0 4px, transparent 5px), repeating-radial-gradient(circle, transparent 0 20px, rgba(37,213,199,.16) 21px 22px); box-shadow: 0 0 50px rgba(37,213,199,.2); }
.score { min-width: 86px; height: 86px; display: grid; place-items: center; border-radius: 22px; font-size: 35px; font-weight: 900; background: #183649; border: 1px solid var(--line); }
.score[data-severity="critical"] { color: #fff; background: rgba(255,107,107,.17); border-color: var(--red); }
.score[data-severity="high"] { color: var(--yellow); border-color: var(--yellow); }
.metric-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }
.metric-grid article { background: var(--panel-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.metric-grid span, .assets span { display: block; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.metric-grid strong { font-size: 18px; }
.risk-list { padding-left: 20px; color: #d9e7ee; }
.risk-list li { margin: 7px 0; }
.assets { display: grid; gap: 9px; }
.assets article { display: flex; justify-content: space-between; gap: 20px; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #0a1a27; }
.assets p { margin: 0; color: #b7cbd7; }
details { border-top: 1px solid var(--line); padding: 18px 0 0; margin-top: 20px; }
summary { cursor: pointer; font-weight: 800; }
pre { white-space: pre-wrap; overflow-wrap: anywhere; background: #07141f; border: 1px solid #214155; border-radius: 14px; padding: 16px; color: #cfe3ec; font: 12px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; max-height: 440px; overflow: auto; }
.trace article { display: flex; gap: 12px; padding: 10px 0; }
.trace strong { text-transform: capitalize; }
.trace p { margin: 2px 0 0; color: var(--muted); }
.dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 7px; background: var(--teal); box-shadow: 0 0 12px rgba(37,213,199,.6); flex: 0 0 auto; }
.dot.proposed { background: var(--yellow); }
@media (max-width: 980px) { .hero, .workspace { grid-template-columns: 1fr; } .input-panel { position: static; } .metric-grid { grid-template-columns: 1fr; } }
