:root, :root[data-theme=light] .terminal, :root[data-theme=light] .try-screen, :root[data-theme=light] .example, :root[data-theme=light] .syntax, :root[data-theme=light] .anatomy-bar, :root[data-theme=light] .ink {
  --bg: #0B0B0E;
  --surface: #13141A;
  --surface-2: #1A1C24;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --hover: rgba(255, 255, 255, 0.04);
  --accent: #B47B55;
  --accent-strong: #CB936B;
  --accent-fill: #B47B55;
  --accent-fill-hover: #C58C66;
  --on-accent: #0B0B0E;
  --accent-soft: rgba(180, 123, 85, .14);
  --iris: #818CF8;
  --iris-strong: #6366F1;
  --iris-soft: rgba(129, 140, 248, .14);
  --warm: #818CF8;
  --warm-strong: #6366F1;
  --warm-soft: rgba(129, 140, 248, .14);
  --threat: #F43F5E;
  --threat-soft: rgba(244, 63, 94, .12);
  --easy: #38BDF8;
  --medium: #FBBF24;
  --hard: #F97316;
  --intense: #F43F5E;
  --text: #F4F4F6;
  --text-2: #D4D4D8;
  --muted: #9CA3AF;
  --faint: #6B7280;
  --shadow: none;
  color: var(--text);
}
:root[data-theme=light] {
  color-scheme: light;
  --bg: #FAF9F6;
  --surface: #FFFFFF;
  --surface-2: #F5F5F4;
  --border: #E7E5E4;
  --border-strong: #D6D3D1;
  --hover: rgba(24, 24, 27, 0.04);
  --accent: #8A5536;
  --accent-strong: #6F4229;
  --accent-fill: #8A5536;
  --accent-fill-hover: #6F4229;
  --on-accent: #FFFFFF;
  --accent-soft: rgba(138, 85, 54, .1);
  --iris: #4F46E5;
  --iris-strong: #4338CA;
  --iris-soft: rgba(79, 70, 229, .1);
  --warm: #4F46E5;
  --warm-strong: #4338CA;
  --warm-soft: rgba(79, 70, 229, .1);
  --threat: #E11D48;
  --threat-soft: rgba(225, 29, 72, .08);
  --easy: #0284C7;
  --medium: #B45309;
  --hard: #C2410C;
  --intense: #BE123C;
  --text: #18181B;
  --text-2: #3F3F46;
  --muted: #57534E;
  --faint: #A8A29E;
  --shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
}
:root {
  color-scheme: dark;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --ui: Inter, "Geist Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 14px;
  --radius-sm: 9px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --shell: min(1200px, calc(100% - 48px));
}
*, *::before, *::after { box-sizing: border-box }
html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100% }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font: 15px/1.6 var(--ui); -webkit-font-smoothing: antialiased; overflow-x: hidden }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0 }
ul, ol { padding: 0; list-style: none }
h1, h2, h3, h4 { font-weight: 650; letter-spacing: -.03em; line-height: 1.1; text-wrap: balance }
h1 { font-size: clamp(2.4rem, 5.2vw, 4.2rem); letter-spacing: -.045em }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem) }
h3 { font-size: 1.1rem; letter-spacing: -.02em }
h4 { font-size: .95rem; letter-spacing: -.01em }
p { color: var(--muted); text-wrap: pretty }
a { color: inherit; text-decoration: none }
img, svg { display: block; max-width: 100% }
button, input, select, textarea { font: inherit; color: inherit }
button { cursor: pointer; background: none; border: 0; padding: 0 }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px }
::selection { background: var(--accent-fill); color: var(--on-accent) }
[hidden] { display: none !important }
.shell { width: var(--shell); margin-inline: auto }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums }
.muted { color: var(--muted) }
.accent { color: var(--accent) }
.iris { color: var(--iris) }
.sub { color: var(--muted); font-size: .98rem; max-width: 68ch }
.warm { color: var(--warm) }
.threat { color: var(--threat) }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; font: 500 .7rem/1.4 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted) }
.eyebrow::before { content: ""; width: 14px; height: 1px; background: var(--accent) }
.card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); min-width: 0; transition: border-color .15s, background .15s }
.card.lift:hover { border-color: var(--border-strong); background: var(--surface-2) }
.card.glow { border-color: var(--border-strong) }
.logo { width: 26px; height: 26px; flex: none }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: var(--radius-sm); border: 1px solid var(--accent-fill); background: var(--accent-fill); color: var(--on-accent); font-weight: 600; font-size: .88rem; letter-spacing: -.01em; white-space: nowrap; transition: background .15s, border-color .15s, color .15s }
.btn:hover { background: var(--accent-fill-hover); border-color: var(--accent-fill-hover) }
.btn:active { background: var(--accent-fill) }
.btn.ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong) }
.btn.ghost:hover { background: var(--surface-2); border-color: var(--border-strong) }
.btn.danger { background: transparent; color: var(--threat); border-color: color-mix(in srgb, var(--threat) 40%, transparent) }
.btn.danger:hover { background: var(--threat-soft) }
.btn.iris { background: var(--iris-strong); border-color: var(--iris-strong); color: #FFFFFF }
.btn.iris:hover { background: var(--iris); border-color: var(--iris) }
.btn.sm { min-height: 32px; padding: 0 12px; font-size: .8rem }
.btn:disabled { opacity: .5; cursor: not-allowed }
.badge { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 5px; border: 1px solid var(--border-strong); font: 500 .66rem/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); white-space: nowrap }
.badge.ok { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, transparent); background: var(--accent-soft) }
.badge.bad { color: var(--threat); border-color: color-mix(in srgb, var(--threat) 40%, transparent); background: var(--threat-soft) }
.badge.warn { color: var(--medium); border-color: color-mix(in srgb, var(--medium) 40%, transparent); background: color-mix(in srgb, var(--medium) 8%, transparent) }
.badge.info { color: var(--warm); border-color: color-mix(in srgb, var(--warm) 35%, transparent); background: var(--warm-soft) }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent) }
.field { display: grid; gap: 7px; font-size: .82rem; color: var(--muted) }
.field > span { display: flex; justify-content: space-between; gap: 8px }
.input, select.input, textarea.input { width: 100%; min-width: 0; min-height: 40px; padding: 8px 12px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: .92rem; transition: border-color .15s }
textarea.input { min-height: 110px; resize: vertical; line-height: 1.5 }
.input:hover { border-color: var(--border-strong) }
.input:focus { outline: 0; border-color: var(--accent) }
.input::placeholder { color: var(--faint) }
.field.invalid .input { border-color: var(--threat) }
.field .error { color: var(--threat); font-size: .76rem; min-height: 1em }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--accent) var(--fill, 50%), var(--border-strong) var(--fill, 50%)); outline-offset: 8px }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--text); border: 0; cursor: grab }
input[type=range]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--text); border: 0; cursor: grab }
.chip { display: inline-flex; align-items: center; gap: 7px; min-height: 32px; padding: 0 12px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface); color: var(--muted); font-size: .82rem; transition: color .15s, border-color .15s, background .15s }
.chip:hover { color: var(--text); border-color: var(--border-strong) }
.chip[aria-pressed=true], .chip[aria-selected=true], .chip.on { color: var(--text); border-color: var(--accent); background: var(--accent-soft) }
.chip .count { font: 500 .7rem var(--mono); opacity: .7 }
.chips { display: flex; flex-wrap: wrap; gap: 8px }
.skeleton { position: relative; overflow: hidden; background: var(--surface); border-radius: var(--radius-sm); min-height: 14px; color: transparent !important; border-color: var(--border) !important }
.skeleton::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--muted) 6%, transparent), transparent); animation: shimmer 1.4s infinite }
@keyframes shimmer { to { transform: translateX(100%) } }
.reveal { opacity: 0; transition: opacity .4s ease; transition-delay: var(--delay, 0ms) }
.reveal.in { opacity: 1 }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface) }
table { width: 100%; border-collapse: collapse; font-size: .86rem }
th { text-align: left; font: 500 .66rem var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 11px 16px; border-bottom: 1px solid var(--border); white-space: nowrap; background: var(--bg) }
td { padding: 11px 16px; border-bottom: 1px solid var(--border); vertical-align: middle }
tbody tr:hover { background: var(--surface-2) }
tbody tr:last-child td { border-bottom: 0 }
.bar { height: 4px; border-radius: 4px; background: var(--border); overflow: hidden }
.bar > i { display: block; height: 100%; width: var(--value, 0%); border-radius: inherit; background: var(--accent); transition: width .5s var(--ease) }
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 110; display: grid; gap: 8px; width: min(360px, calc(100vw - 40px)) }
.toast { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border-strong); border-left: 2px solid var(--accent); font-size: .86rem; animation: toast-in .2s ease }
.toast.bad { border-left-color: var(--threat) }
.toast.out { animation: toast-out .2s ease forwards }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px) } }
@keyframes toast-out { to { opacity: 0 } }
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: color-mix(in srgb, var(--bg) 80%, transparent); animation: fade .15s }
.modal > .card { width: min(720px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; border-color: var(--border-strong) }
.modal .close { position: absolute; top: 14px; right: 14px; width: 30px; height: 30px; border-radius: 6px; border: 1px solid var(--border); color: var(--muted); display: grid; place-items: center }
.modal .close:hover { color: var(--text); border-color: var(--border-strong) }
@keyframes fade { from { opacity: 0 } }
@keyframes rise { from { opacity: 0; transform: translateY(8px) } }
.tabs { display: inline-flex; justify-self: start; width: fit-content; gap: 2px; padding: 3px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); max-width: 100%; overflow-x: auto }
.tabs button { padding: 6px 13px; border-radius: 5px; color: var(--muted); font-size: .84rem; font-weight: 550; white-space: nowrap; transition: color .15s, background .15s }
.tabs button:hover { color: var(--text) }
.tabs button[aria-selected=true] { background: var(--surface-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--border-strong) }
.empty { display: grid; place-items: center; gap: 8px; padding: 44px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--border-strong); border-radius: var(--radius) }
.stat { display: grid; gap: 4px }
.stat b { font: 600 1.6rem/1.1 var(--mono); letter-spacing: -.04em; color: var(--text) }
.stat small { font-size: .74rem; color: var(--muted) }
.grid { display: grid; gap: 18px }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap }
.between { justify-content: space-between }
.kbd { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 4px; font: 500 .66rem var(--mono); color: var(--muted); background: var(--bg) }
.chart text { font: 10px var(--mono); fill: var(--muted) }
.chart .axis { stroke: var(--border); stroke-width: 1 }
.chart-tip { position: fixed; z-index: 95; pointer-events: none; padding: 6px 9px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--border-strong); font: 500 .72rem var(--mono); color: var(--text); white-space: nowrap; transform: translate(-50%, calc(-100% - 12px)); opacity: 0; transition: opacity .1s }
.chart-tip.on { opacity: 1 }
@media (max-width: 640px) { :root { --shell: calc(100% - 32px) } .card { padding: 20px } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important } .reveal { opacity: 1 } }
