/* ChroniumX — glass design system */
:root {
  --bg: #040b07;
  --bg-2: #07110c;
  --text: #f2f2f2;
  --muted: rgba(255, 255, 255, 0.58);
  --faint: rgba(255, 255, 255, 0.36);
  --line: rgba(255, 255, 255, 0.07);
  --line-hi: rgba(255, 255, 255, 0.14);

  --glass: rgba(14, 14, 16, 0.38);
  --glass-strong: rgba(16, 18, 20, 0.62);
  --glass-tint: rgba(255, 255, 255, 0.1);
  --glass-tint-hi: rgba(255, 255, 255, 0.16);
  --glass-blur: blur(20px) saturate(1.6);
  --glass-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), 0 8px 30px rgba(0, 0, 0, 0.3);
  --glass-shadow-lg: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 24px 60px rgba(0, 0, 0, 0.45);

  --accent: #34d399;
  --accent-2: #a78bfa;
  --accent-3: #38bdf8;
  --warn: #fbbf24;
  --danger: #f87171;

  --t-html: #fb923c;
  --t-css: #60a5fa;
  --t-js: #facc15;
  --t-json: #34d399;
  --t-map: #c084fc;
  --t-text: #94a3b8;
  --t-image: #f472b6;
  --t-font: #a78bfa;

  --radius: 22px;
  --radius-sm: 14px;
  --pill: 999px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --nav-h: 64px;
  color-scheme: dark;
}

*,
*::before,
*::after { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.is-booting { overflow: hidden; }

::selection { background: rgba(52, 211, 153, 0.35); }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 99px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(255, 255, 255, 0.2); }
::-webkit-scrollbar-track { background: transparent; }

.icon { width: 1em; height: 1em; display: inline-block; flex: none; vertical-align: -0.125em; }

/* ── Ambient background ───────────────────────────────────────────────── */
.ambient { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.ambient .blob {
  position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.55;
  will-change: transform; animation: drift 26s var(--ease) infinite alternate;
}
.ambient .b1 { width: 52vmax; height: 52vmax; left: -14vmax; top: -18vmax; background: radial-gradient(circle, rgba(16, 185, 129, 0.42), transparent 65%); }
.ambient .b2 { width: 46vmax; height: 46vmax; right: -16vmax; top: 8vmax; background: radial-gradient(circle, rgba(139, 92, 246, 0.3), transparent 65%); animation-duration: 32s; animation-delay: -8s; }
.ambient .b3 { width: 40vmax; height: 40vmax; left: 22vmax; bottom: -24vmax; background: radial-gradient(circle, rgba(14, 165, 233, 0.26), transparent 65%); animation-duration: 38s; animation-delay: -16s; }
.ambient .grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 50% 20%, #000 20%, transparent 75%);
}
.ambient .grain {
  position: absolute; inset: -50%; opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes drift {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(6vmax, 4vmax, 0) scale(1.08); }
  100% { transform: translate3d(-4vmax, 7vmax, 0) scale(0.94); }
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-5%, 3%); }
  40% { transform: translate(4%, -6%); }
  60% { transform: translate(-3%, 5%); }
  80% { transform: translate(6%, 2%); }
}

/* ── Glass primitives ─────────────────────────────────────────────────── */
.glass {
  background: var(--glass);
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--line);
  box-shadow: var(--glass-shadow);
}
.glass-card {
  background: var(--glass);
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--line);
  box-shadow: var(--glass-shadow-lg);
  border-radius: var(--radius);
  position: relative;
}
.glass-card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(135deg, rgba(255,255,255,0.06), transparent 40%);
}

/* ── Buttons ──────────────────────────────────────────────────────────── */
.btn {
  --h: 44px;
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: var(--h); padding: 0 20px; border-radius: var(--pill);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--glass-tint);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  backdrop-filter: blur(20px) saturate(1.5);
  color: var(--text); font-weight: 600; font-size: 14px; letter-spacing: 0.01em; white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 4px 14px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s var(--ease), background-color 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease), color 0.3s var(--ease), opacity 0.2s;
  user-select: none; -webkit-tap-highlight-color: transparent;
}
.btn::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.18) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform 0.7s var(--ease-out);
}
.btn:hover { background: var(--glass-tint-hi); border-color: rgba(255, 255, 255, 0.2); transform: translateY(-1px); }
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: scale(0.95); }
.btn:focus-visible { outline: 2px solid rgba(255, 255, 255, 0.6); outline-offset: 2px; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn .icon { font-size: 16px; }

.btn-primary {
  background: #f2f2f2; color: #000; border-color: transparent;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.25), 0 8px 10px -6px rgba(0, 0, 0, 0.2);
}
.btn-primary::after { background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.9) 50%, transparent 70%); }
.btn-primary:hover { background: #fff; color: #000; transform: scale(1.05); box-shadow: 0 0 0 6px rgba(255,255,255,0.06), 0 20px 40px -8px rgba(255, 255, 255, 0.18); }
.btn-primary:active { transform: scale(0.95); }

.btn-danger { color: #fecaca; border-color: rgba(248, 113, 113, 0.25); background: rgba(248, 113, 113, 0.1); }
.btn-danger:hover { background: rgba(248, 113, 113, 0.2); border-color: rgba(248, 113, 113, 0.45); }

.btn-sm { --h: 34px; padding: 0 14px; font-size: 13px; }
.btn-xs { --h: 28px; padding: 0 11px; font-size: 12px; gap: 6px; }
.btn-lg { --h: 52px; padding: 0 28px; font-size: 16px; }
.btn-icon { width: var(--h); padding: 0; }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.btn-ghost:hover { background: rgba(255,255,255,0.08); border-color: transparent; }
.btn.is-active { background: #f2f2f2; color: #000; border-color: transparent; }

.btn-group {
  display: inline-flex; align-items: center; gap: 2px; padding: 4px; border-radius: var(--pill);
  background: var(--glass-tint); border: 1px solid rgba(255,255,255,0.1);
  -webkit-backdrop-filter: blur(20px) saturate(1.5); backdrop-filter: blur(20px) saturate(1.5);
}
.btn-group .btn { background: transparent; border-color: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.btn-group .btn:hover { background: rgba(255,255,255,0.08); transform: none; }
.btn-group .btn.is-active { background: #f2f2f2; color: #000; }
.btn-group .divider { width: 1px; height: 18px; background: rgba(255,255,255,0.12); margin: 0 2px; }

.ripple {
  position: absolute; border-radius: 50%; pointer-events: none; z-index: 0;
  background: currentColor; opacity: 0.22; transform: scale(0);
  animation: ripple 0.6s var(--ease-out) forwards;
}
@keyframes ripple { to { transform: scale(2.6); opacity: 0; } }

/* ── Navigation ───────────────────────────────────────────────────────── */
.topbar {
  position: fixed; top: 16px; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
  pointer-events: none;
}
.topbar > * { pointer-events: auto; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: -0.02em; font-size: 17px; }
.brand-mark { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; }
.brand-mark svg { width: 22px; height: 22px; }
.brand small { display: block; font-weight: 500; font-size: 11px; color: var(--faint); letter-spacing: 0.04em; }

.nav {
  position: relative; display: flex; align-items: center; gap: 4px; height: 52px; padding: 0 6px; border-radius: var(--pill);
}
.nav-indicator {
  position: absolute; top: 6px; left: 0; height: 40px; border-radius: var(--pill); background: #f2f2f2;
  box-shadow: 0 6px 20px rgba(255,255,255,0.12);
  transition: transform 0.55s var(--spring), width 0.55s var(--spring), opacity 0.3s;
  z-index: 0;
}
.nav-btn {
  position: relative; z-index: 1; height: 40px; padding: 0 18px; border-radius: var(--pill); border: 0;
  background: transparent; color: rgba(255,255,255,0.62); font-weight: 500; font-size: 14px;
  display: inline-flex; align-items: center; gap: 8px; transition: color 0.3s var(--ease);
}
.nav-btn:hover { color: #fff; }
.nav-btn.active { color: #000; }
.nav-btn .icon { font-size: 15px; }
.nav-btn .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); animation: pulse 1.4s infinite; }

.top-actions { display: flex; align-items: center; gap: 8px; }
.engine-pill {
  height: 40px; display: inline-flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: var(--pill);
  font-size: 12px; font-weight: 600; color: var(--muted);
}
.engine-pill .led { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); }
.engine-pill.ok .led { background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.engine-pill.warn .led { background: var(--warn); box-shadow: 0 0 12px var(--warn); }

@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.45; transform: scale(0.8); } }

/* ── Layout ───────────────────────────────────────────────────────────── */
.app { position: relative; z-index: 1; min-height: 100vh; }
.page { padding: 104px 24px 48px; max-width: 1240px; margin: 0 auto; }
.page.full { max-width: none; padding: 88px 16px 16px; height: 100vh; display: flex; flex-direction: column; }
.page-enter { animation: pageIn 0.6s var(--ease-out) both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(14px) scale(0.99); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }

::view-transition-old(root) { animation: vtOut 0.28s var(--ease) both; }
::view-transition-new(root) { animation: vtIn 0.5s var(--ease-out) both; }
@keyframes vtOut { to { opacity: 0; filter: blur(6px); transform: scale(0.99); } }
@keyframes vtIn { from { opacity: 0; filter: blur(8px); transform: translateY(10px); } }

.reveal { opacity: 0; transform: translateY(18px); filter: blur(6px); transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out), filter 0.8s var(--ease-out); transition-delay: calc(var(--i, 0) * 70ms); }
.is-ready .reveal { opacity: 1; transform: none; filter: none; }

.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 0 0 16px; }
.section-head h2 { margin: 0; font-size: 20px; letter-spacing: -0.02em; }
.section-head p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--faint); font-weight: 600; }

/* ── Hero / Home ─────────────────────────────────────────────────────── */
.hero { text-align: center; padding: 48px 0 28px; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 14px; border-radius: var(--pill); font-size: 12px; color: var(--muted); font-weight: 500; }
.hero-badge b { color: var(--accent); font-weight: 600; }
.hero h1 {
  margin: 22px auto 14px; font-size: clamp(36px, 6.4vw, 76px); line-height: 1.02; letter-spacing: -0.045em; font-weight: 800; max-width: 920px;
}
.hero h1 .grad {
  background: linear-gradient(100deg, #fff 10%, #a7f3d0 40%, #c4b5fd 70%, #fff 95%);
  background-size: 200% auto; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: sheen 8s linear infinite;
}
@keyframes sheen { to { background-position: 200% center; } }
.hero p.lead { margin: 0 auto; max-width: 620px; color: var(--muted); font-size: 17px; }

.omnibox {
  margin: 34px auto 0; max-width: 780px; display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 22px; border-radius: var(--pill);
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.3s var(--ease-out);
}
.omnibox:focus-within { border-color: rgba(255,255,255,0.2); box-shadow: var(--glass-shadow), 0 0 0 6px rgba(52, 211, 153, 0.08), 0 0 80px rgba(52, 211, 153, 0.12); transform: translateY(-2px); }
.omnibox .icon { font-size: 20px; color: var(--faint); }
.omnibox input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; font-size: 17px; height: 52px; }
.omnibox input::placeholder { color: var(--faint); }

.chip-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 16px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: var(--pill);
  font-size: 12px; font-weight: 500; color: var(--muted); background: rgba(255,255,255,0.05); border: 1px solid var(--line);
  transition: all 0.25s var(--ease);
}
button.chip:hover { color: #fff; background: rgba(255,255,255,0.1); border-color: var(--line-hi); }
.chip b { color: var(--text); font-weight: 600; }
.chip .icon { font-size: 13px; }

.grid-2 { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 18px; margin-top: 40px; }
.panel { padding: 22px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 18px; }
.panel-head h3 { margin: 0; font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.panel-head h3 .icon { color: var(--accent); }

.field { margin-bottom: 18px; }
.field:last-child { margin-bottom: 0; }
.field-label { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; color: var(--muted); font-weight: 500; margin-bottom: 8px; }
.field-label output { color: var(--text); font-family: var(--mono); font-size: 12px; font-weight: 600; }
.input {
  width: 100%; height: 42px; padding: 0 14px; border-radius: 12px; outline: 0;
  background: rgba(0, 0, 0, 0.25); border: 1px solid var(--line); transition: border-color 0.2s, box-shadow 0.2s;
}
.input:focus { border-color: rgba(255,255,255,0.22); box-shadow: 0 0 0 4px rgba(255,255,255,0.05); }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpath d='M2 4l4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
select.input option { background: #111; }

.range { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 99px; outline: 0;
  background: linear-gradient(90deg, #f2f2f2 var(--fill, 50%), rgba(255,255,255,0.1) var(--fill, 50%)); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 5px rgba(255,255,255,0.12), 0 4px 10px rgba(0,0,0,0.4); cursor: grab; transition: transform 0.2s var(--spring); }
.range::-webkit-slider-thumb:active { transform: scale(1.2); cursor: grabbing; }
.range::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 0; }

.toggles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.toggle {
  display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 14px; cursor: pointer;
  background: rgba(255,255,255,0.03); border: 1px solid var(--line); transition: background 0.25s, border-color 0.25s;
}
.toggle:hover { background: rgba(255,255,255,0.06); border-color: var(--line-hi); }
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.switch { position: relative; flex: none; width: 36px; height: 20px; border-radius: 99px; background: rgba(255,255,255,0.14); transition: background 0.3s var(--ease); }
.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.4); transition: transform 0.4s var(--spring); }
.toggle input:checked + .switch { background: var(--accent); }
.toggle input:checked + .switch::after { transform: translateX(16px); }
.toggle input:focus-visible + .switch { outline: 2px solid #fff; outline-offset: 2px; }
.toggle-text { min-width: 0; }
.toggle-text b { display: block; font-size: 13px; font-weight: 600; }
.toggle-text span { display: block; font-size: 11.5px; color: var(--faint); line-height: 1.35; }

details.more { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 14px; }
details.more summary { cursor: pointer; list-style: none; font-size: 13px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 8px; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary .icon { transition: transform 0.3s var(--ease); }
details.more[open] summary .icon { transform: rotate(90deg); }
details.more .more-body { padding-top: 14px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; animation: pageIn 0.4s var(--ease-out); }

/* ── Mission control ─────────────────────────────────────────────────── */
.mission { display: grid; grid-template-columns: 220px 1fr; gap: 22px; align-items: center; }
.ring-wrap { position: relative; width: 200px; height: 200px; margin: 0 auto; }
.ring-wrap svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-track { fill: none; stroke: rgba(255,255,255,0.07); stroke-width: 10; }
.ring-fill { fill: none; stroke: url(#ringGrad); stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 0.8s var(--ease-out); filter: drop-shadow(0 0 10px rgba(52, 211, 153, 0.5)); }
.ring-center { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.ring-center strong { display: block; font-size: 42px; font-weight: 800; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.ring-center span { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.14em; }
.ring-orbit { position: absolute; inset: -8px; border-radius: 50%; border: 1px dashed rgba(255,255,255,0.08); animation: spin 14s linear infinite; }
.ring-orbit::before { content: ""; position: absolute; top: -4px; left: 50%; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 14px var(--accent); }
.ring-wrap.idle .ring-orbit { animation-play-state: paused; opacity: 0.4; }
.ring-wrap.running::after { content: ""; position: absolute; inset: 18px; border-radius: 50%; background: conic-gradient(from 0deg, transparent, rgba(52,211,153,0.16), transparent 30%); animation: spin 2.4s linear infinite; z-index: -1; }
@keyframes spin { to { transform: rotate(360deg); } }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.stat { padding: 14px; border-radius: 16px; background: rgba(255,255,255,0.035); border: 1px solid var(--line); }
.stat .label { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.1em; font-weight: 600; }
.stat .value { font-size: 26px; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; margin-top: 2px; }
.phase-line { margin-top: 14px; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); min-height: 22px; }
.phase-line .spinner { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255,255,255,0.15); border-top-color: var(--accent); animation: spin 0.8s linear infinite; }
.phase-line .eta { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--faint); }

.feed { margin-top: 14px; height: 196px; overflow: hidden; display: flex; flex-direction: column; gap: 6px; mask-image: linear-gradient(#000 70%, transparent); }
.feed-item { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 10px; background: rgba(255,255,255,0.03); font-size: 12px; font-family: var(--mono); color: var(--muted); animation: feedIn 0.45s var(--ease-out) both; white-space: nowrap; }
.feed-item span.p { overflow: hidden; text-overflow: ellipsis; }
@keyframes feedIn { from { opacity: 0; transform: translateY(-10px) scale(0.98); filter: blur(4px); } }

.type-badge { flex: none; min-width: 38px; text-align: center; padding: 2px 6px; border-radius: 6px; font-size: 10px; font-weight: 700; font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.04em; }
.type-badge.html { background: rgba(251,146,60,0.14); color: var(--t-html); }
.type-badge.css { background: rgba(96,165,250,0.14); color: var(--t-css); }
.type-badge.js { background: rgba(250,204,21,0.12); color: var(--t-js); }
.type-badge.json { background: rgba(52,211,153,0.12); color: var(--t-json); }
.type-badge.map { background: rgba(192,132,252,0.14); color: var(--t-map); }
.type-badge.text { background: rgba(148,163,184,0.14); color: var(--t-text); }
.type-badge.image { background: rgba(244,114,182,0.14); color: var(--t-image); }
.type-badge.font { background: rgba(167,139,250,0.14); color: var(--t-font); }

.bar { height: 6px; border-radius: 99px; background: rgba(255,255,255,0.07); overflow: hidden; position: relative; }
.bar > i { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--accent-3)); box-shadow: 0 0 16px rgba(52,211,153,0.6); transition: width 0.6s var(--ease-out); }
.bar.indeterminate > i { width: 35%; animation: indet 1.3s var(--ease) infinite; }
@keyframes indet { from { transform: translateX(-100%); } to { transform: translateX(300%); } }

.result-card { margin-top: 18px; padding: 18px; border-radius: 18px; background: linear-gradient(135deg, rgba(52,211,153,0.1), rgba(139,92,246,0.08)); border: 1px solid rgba(52,211,153,0.2); animation: pageIn 0.6s var(--ease-out); }
.result-card h4 { margin: 0 0 6px; font-size: 16px; }
.result-card .chip-row { justify-content: flex-start; margin-top: 10px; }

/* Saved scrapes */
.saved-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.site-card { padding: 18px; cursor: pointer; transition: transform 0.45s var(--ease-out), border-color 0.3s, box-shadow 0.45s; overflow: hidden; }
.site-card:hover { transform: translateY(-4px); border-color: var(--line-hi); box-shadow: var(--glass-shadow-lg), 0 30px 60px -20px rgba(52,211,153,0.18); }
.site-card .top { display: flex; align-items: center; gap: 12px; }
.avatar { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; font-size: 16px; color: #000; flex: none; }
.site-card .name { font-weight: 700; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-card .url { font-size: 12px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-card .meta { display: flex; gap: 14px; margin-top: 14px; font-size: 12px; color: var(--muted); }
.site-card .meta b { color: var(--text); font-weight: 700; }
.site-card .actions { position: absolute; top: 14px; right: 14px; display: flex; gap: 6px; opacity: 0; transform: translateY(-4px); transition: all 0.3s var(--ease); }
.site-card:hover .actions { opacity: 1; transform: none; }
.empty { text-align: center; padding: 40px 20px; color: var(--faint); border: 1px dashed var(--line-hi); border-radius: var(--radius); }
.empty .icon { font-size: 28px; margin-bottom: 8px; color: var(--muted); }

/* ── Workspace ───────────────────────────────────────────────────────── */
.ws { flex: 1; min-height: 0; display: grid; grid-template-columns: 52px var(--side-w, 300px) 1fr; border-radius: var(--radius); overflow: hidden; }
.ws.side-collapsed { grid-template-columns: 52px 0 1fr; }
.ws-activity { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 0; border-right: 1px solid var(--line); background: rgba(0,0,0,0.18); }
.act-btn { position: relative; width: 38px; height: 38px; border-radius: 12px; border: 0; background: transparent; color: var(--faint); display: grid; place-items: center; transition: all 0.25s var(--ease); }
.act-btn .icon { font-size: 18px; }
.act-btn:hover { color: #fff; background: rgba(255,255,255,0.07); }
.act-btn.active { color: #000; background: #f2f2f2; }
.act-btn .count { position: absolute; top: 2px; right: 2px; min-width: 15px; height: 15px; padding: 0 4px; border-radius: 99px; background: var(--accent); color: #000; font-size: 9px; font-weight: 800; display: grid; place-items: center; }
.act-spacer { flex: 1; }

.ws-side { position: relative; min-width: 0; display: flex; flex-direction: column; border-right: 1px solid var(--line); background: rgba(0,0,0,0.12); overflow: hidden; }
.ws-resizer { position: absolute; top: 0; right: -3px; width: 6px; height: 100%; cursor: col-resize; z-index: 5; }
.ws-resizer:hover, .ws-resizer.dragging { background: linear-gradient(90deg, transparent 2px, var(--accent) 2px, var(--accent) 4px, transparent 4px); }
.side-view { display: flex; flex-direction: column; min-height: 0; flex: 1; }
.side-head { padding: 12px 12px 8px; display: flex; flex-direction: column; gap: 8px; }
.side-title { display: flex; align-items: center; justify-content: space-between; font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--faint); font-weight: 700; }
.side-input { height: 34px; border-radius: 10px; font-size: 13px; padding: 0 12px; }
.type-filters { display: flex; flex-wrap: wrap; gap: 4px; }
.tf { height: 24px; padding: 0 8px; border-radius: 99px; border: 1px solid var(--line); background: transparent; font-size: 10.5px; font-weight: 700; font-family: var(--mono); text-transform: uppercase; color: var(--faint); transition: all 0.2s; }
.tf.on { color: var(--c); border-color: color-mix(in srgb, var(--c) 40%, transparent); background: color-mix(in srgb, var(--c) 12%, transparent); }
.tree { flex: 1; overflow: auto; padding: 4px 6px 12px; font-size: 13px; }
.tree-row { display: flex; align-items: center; gap: 6px; height: 26px; padding: 0 8px 0 calc(8px + var(--d, 0) * 14px); border-radius: 8px; cursor: pointer; color: var(--muted); white-space: nowrap; user-select: none; position: relative; }
.tree-row:hover { background: rgba(255,255,255,0.05); color: var(--text); }
.tree-row.active { background: rgba(255,255,255,0.1); color: #fff; }
.tree-row.active::before { content: ""; position: absolute; left: 0; top: 5px; bottom: 5px; width: 3px; border-radius: 3px; background: var(--accent); }
.tree-row .chev { font-size: 12px; transition: transform 0.2s var(--ease); color: var(--faint); }
.tree-row.open .chev { transform: rotate(90deg); }
.tree-row .name { overflow: hidden; text-overflow: ellipsis; flex: 1; min-width: 0; }
.tree-row .sz { font-size: 10.5px; color: var(--faint); font-family: var(--mono); }
.tree-row .dirty { width: 7px; height: 7px; border-radius: 50%; background: var(--warn); flex: none; }
.tree-row .cb { width: 14px; height: 14px; margin: 0; accent-color: var(--accent); flex: none; opacity: 0; transition: opacity 0.2s; }
.tree-row:hover .cb, .tree.selecting .cb, .tree-row .cb:checked { opacity: 1; }
.ficon { width: 16px; height: 16px; flex: none; border-radius: 4px; display: grid; place-items: center; font-size: 8px; font-weight: 800; font-family: var(--mono); }
.ficon.html { color: var(--t-html); } .ficon.css { color: var(--t-css); } .ficon.js { color: var(--t-js); } .ficon.json { color: var(--t-json); } .ficon.map { color: var(--t-map); } .ficon.text { color: var(--t-text); } .ficon.image { color: var(--t-image); } .ficon.font { color: var(--t-font); }
.ficon.folder { color: #93c5fd; font-size: 15px; }
.side-foot { padding: 10px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 6px; }
.side-foot .grow { flex: 1; }
.side-count { font-size: 11px; color: var(--faint); }

.search-opts { display: flex; gap: 4px; }
.search-results { flex: 1; overflow: auto; padding: 0 6px 12px; font-size: 12.5px; }
.sr-file { display: flex; align-items: center; gap: 6px; padding: 6px 8px; color: var(--text); font-weight: 600; cursor: pointer; border-radius: 8px; }
.sr-file:hover { background: rgba(255,255,255,0.05); }
.sr-file .n { margin-left: auto; font-size: 10.5px; color: var(--faint); background: rgba(255,255,255,0.07); padding: 1px 7px; border-radius: 99px; }
.sr-line { padding: 3px 8px 3px 30px; font-family: var(--mono); font-size: 11.5px; color: var(--muted); cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-radius: 6px; }
.sr-line:hover { background: rgba(255,255,255,0.05); color: var(--text); }
.sr-line mark { background: rgba(250, 204, 21, 0.28); color: #fff; border-radius: 3px; }
.sr-line .ln { color: var(--faint); margin-right: 8px; }

.info-body { flex: 1; overflow: auto; padding: 4px 12px 16px; font-size: 13px; }
.kv { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid var(--line); color: var(--muted); }
.kv b { color: var(--text); font-family: var(--mono); font-size: 12px; }
.warn-item { font-size: 11.5px; color: #fde68a; background: rgba(251,191,36,0.07); border-radius: 8px; padding: 6px 8px; margin-top: 6px; word-break: break-all; font-family: var(--mono); }

.ws-main { min-width: 0; display: flex; flex-direction: column; background: rgba(5, 9, 7, 0.5); }
.tabs { display: flex; align-items: stretch; height: 40px; overflow-x: auto; overflow-y: hidden; border-bottom: 1px solid var(--line); background: rgba(0,0,0,0.2); scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { position: relative; display: flex; align-items: center; gap: 8px; padding: 0 10px 0 14px; max-width: 220px; border-right: 1px solid var(--line); color: var(--faint); font-size: 12.5px; cursor: pointer; white-space: nowrap; animation: tabIn 0.35s var(--ease-out); transition: background 0.2s, color 0.2s; }
@keyframes tabIn { from { opacity: 0; transform: translateY(6px); } }
.tab:hover { color: var(--text); background: rgba(255,255,255,0.03); }
.tab.active { color: #fff; background: rgba(255,255,255,0.06); }
.tab.active::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.tab .name { overflow: hidden; text-overflow: ellipsis; }
.tab .x { width: 18px; height: 18px; border-radius: 6px; display: grid; place-items: center; border: 0; background: transparent; color: inherit; opacity: 0; font-size: 12px; }
.tab:hover .x, .tab.active .x { opacity: 0.7; }
.tab .x:hover { background: rgba(255,255,255,0.12); opacity: 1; }
.tab.dirty .x::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--warn); }
.tab.dirty .x .icon { display: none; }
.tab.dirty .x:hover::before { display: none; }
.tab.dirty .x:hover .icon { display: block; }

.ed-toolbar { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-bottom: 1px solid var(--line); min-height: 46px; }
.crumbs { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--faint); min-width: 0; overflow: hidden; white-space: nowrap; flex: 1; }
.crumbs .sep { opacity: 0.5; font-size: 10px; }
.crumbs .last { color: var(--text); font-weight: 600; }
.ed-actions { display: flex; align-items: center; gap: 6px; flex: none; }
.ed-body { flex: 1; min-height: 0; display: flex; position: relative; }
.editor-host { flex: 1; min-width: 0; position: relative; }
.editor-host .fallback { width: 100%; height: 100%; resize: none; border: 0; outline: 0; background: transparent; color: #d4d4d4; font-family: var(--mono); font-size: 13px; padding: 14px; white-space: pre; }
.split-preview { width: 44%; min-width: 240px; border-left: 1px solid var(--line); display: flex; flex-direction: column; background: #fff; }
.split-preview .sp-bar { display: flex; align-items: center; gap: 8px; height: 32px; padding: 0 10px; background: #0d1210; color: var(--faint); font-size: 11.5px; border-bottom: 1px solid var(--line); }
.split-preview iframe { flex: 1; border: 0; width: 100%; background: #fff; }
.ws-media { position: absolute; inset: 0; overflow: auto; display: grid; place-items: center; padding: 28px; gap: 14px; text-align: center;
  background-color: #0c0f10; background-image: linear-gradient(45deg, rgba(255,255,255,0.035) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.035) 75%), linear-gradient(45deg, rgba(255,255,255,0.035) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.035) 75%);
  background-size: 22px 22px; background-position: 0 0, 11px 11px; }
.ws-media[hidden] { display: none; }
.ws-media img { max-width: 100%; max-height: 70vh; border-radius: 10px; box-shadow: 0 20px 60px rgba(0,0,0,0.45); animation: fadeUp 0.35s var(--spring) both; }
.ws-media .meta { font-size: 12px; color: var(--faint); }
.ws-media .font-sample { font-size: 44px; line-height: 1.25; color: var(--text); max-width: 760px; }
.ws-media .font-sample small { display: block; font-size: 18px; color: var(--muted); margin-top: 10px; }
.ws-welcome { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 24px; }
.ws-welcome .mark { width: 72px; height: 72px; margin: 0 auto 16px; border-radius: 22px; display: grid; place-items: center; }
.ws-welcome h3 { margin: 0 0 6px; font-size: 20px; }
.ws-welcome p { margin: 0 0 18px; color: var(--muted); }
.kbd-list { display: grid; grid-template-columns: auto auto; gap: 8px 18px; justify-content: center; font-size: 12.5px; color: var(--muted); text-align: left; margin-top: 18px; }
kbd { font-family: var(--mono); font-size: 11px; padding: 2px 7px; border-radius: 6px; background: rgba(255,255,255,0.08); border: 1px solid var(--line-hi); border-bottom-width: 2px; color: var(--text); }

.statusbar { display: flex; align-items: center; gap: 16px; height: 28px; padding: 0 12px; border-top: 1px solid var(--line); font-size: 11.5px; color: var(--faint); background: rgba(0,0,0,0.25); white-space: nowrap; overflow: hidden; }
.statusbar .sb-item { display: inline-flex; align-items: center; gap: 6px; }
.statusbar .sb-right { margin-left: auto; display: flex; gap: 16px; }
.statusbar a { text-decoration: none; max-width: 360px; overflow: hidden; text-overflow: ellipsis; }
.statusbar a:hover { color: var(--text); }
.statusbar .mod { color: var(--warn); }

/* ── Preview page ────────────────────────────────────────────────────── */
.pv-toolbar { display: flex; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; align-items: center; gap: 10px; padding: 10px; border-radius: var(--pill); margin-bottom: 14px; }
.pv-toolbar .input { height: 36px; border-radius: 99px; max-width: 300px; min-width: 140px; flex: 0 1 300px; }
.pv-toolbar > * { flex-shrink: 0; }
.pv-toolbar > .pv-status, .pv-toolbar > .input { flex-shrink: 1; }
.pv-toolbar .grow { flex: 1; }
.pv-status { flex: 1 1 0; min-width: 0; font-size: 12px; color: var(--faint); padding: 0 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pv-notice { display: flex; align-items: center; gap: 10px; padding: 10px 14px; margin-bottom: 10px; border-radius: 14px; font-size: 13px; color: var(--muted); animation: fadeUp 0.35s var(--spring) both; }
.pv-notice[hidden] { display: none; }
.pv-notice > span { flex: 1; min-width: 0; }
.pv-notice svg { flex: none; width: 16px; height: 16px; color: var(--accent, #9be7c4); }
.pv-stage { flex: 1; min-height: 0; display: flex; justify-content: center; padding: 14px; border-radius: var(--radius); }
.device { height: 100%; width: 100%; border-radius: 14px; overflow: hidden; background: #fff; box-shadow: 0 30px 80px rgba(0,0,0,0.5); transition: width 0.6s var(--spring), border-radius 0.5s; display: flex; flex-direction: column; }
.device .chrome { flex: none; height: 34px; display: flex; align-items: center; gap: 6px; padding: 0 12px; background: #15191a; border-bottom: 1px solid #222; }
.device .chrome i { width: 10px; height: 10px; border-radius: 50%; background: #333; }
.device .chrome i:nth-child(1) { background: #ff5f57; } .device .chrome i:nth-child(2) { background: #febc2e; } .device .chrome i:nth-child(3) { background: #28c840; }
.device .chrome .addr { flex: 1; margin-left: 10px; height: 22px; border-radius: 99px; background: #0d1011; color: #8a8f91; font-size: 11px; display: flex; align-items: center; padding: 0 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
/* The page is laid out at a real device width (desktop 1366px) and scaled to fit, so responsive
   sites show the same layout Chrome captured instead of a squeezed tablet one. */
.device .vp { flex: 1; position: relative; overflow: hidden; min-height: 0; background: #fff; }
.device .vp iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; background: #fff; transform-origin: 0 0; }
.device.tablet { width: 820px; } .device.mobile { width: 400px; border-radius: 28px; }

/* ── Console ─────────────────────────────────────────────────────────── */
.console { flex: 1; min-height: 0; display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden; }
.console-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.console-bar .input { height: 34px; border-radius: 99px; max-width: 260px; }
.console-bar .grow { flex: 1; }
.log { flex: 1; overflow: auto; padding: 10px 0; font-family: var(--mono); font-size: 12px; }
.log-line { display: flex; gap: 12px; padding: 2px 16px; animation: feedIn 0.3s var(--ease-out); }
.log-line:hover { background: rgba(255,255,255,0.03); }
.log-line .ts { color: var(--faint); flex: none; }
.log-line .tag { flex: none; width: 46px; font-weight: 700; }
.log-line .msg { word-break: break-all; color: var(--muted); }
.log-line.info .tag { color: var(--accent-3); } .log-line.success .tag { color: var(--accent); } .log-line.warn .tag { color: var(--warn); } .log-line.error .tag { color: var(--danger); } .log-line.dim .tag { color: var(--faint); }
.log-line.error .msg { color: #fecaca; } .log-line.warn .msg { color: #fde68a; } .log-line.success .msg { color: #bbf7d0; }

/* ── Updates ─────────────────────────────────────────────────────────── */
.timeline { position: relative; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(var(--accent), var(--accent-2), transparent); border-radius: 2px; }
.release { position: relative; padding: 20px 22px; margin-bottom: 16px; }
.release::before { content: ""; position: absolute; left: -26px; top: 26px; width: 12px; height: 12px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); box-shadow: 0 0 12px var(--accent); }
.release h3 { margin: 0; font-size: 17px; display: flex; align-items: center; gap: 10px; }
.release .tag-new { font-size: 10px; padding: 2px 8px; border-radius: 99px; background: var(--accent); color: #000; font-weight: 800; letter-spacing: 0.08em; }
.release ul { margin: 12px 0 0; padding-left: 18px; color: var(--muted); }
.release li { margin: 5px 0; }

/* ── Overlays: modal, palette, toasts ────────────────────────────────── */
.overlay { position: fixed; inset: 0; z-index: 200; display: grid; place-items: start center; padding: 14vh 16px 16px; background: rgba(0,0,0,0.45); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: opacity 0.3s var(--ease); }
.overlay.open { opacity: 1; pointer-events: auto; }
.overlay.center { place-items: center; padding: 16px; }
.modal { width: min(440px, 100%); padding: 24px; transform: translateY(16px) scale(0.97); transition: transform 0.45s var(--spring); background: var(--glass-strong); }
.overlay.open .modal, .overlay.open .palette { transform: none; }
.modal h3 { margin: 0 0 8px; font-size: 18px; }
.modal p { margin: 0 0 20px; color: var(--muted); }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; }

.palette { width: min(640px, 100%); overflow: hidden; transform: translateY(-12px) scale(0.98); transition: transform 0.4s var(--spring); background: var(--glass-strong); }
.palette input { width: 100%; height: 56px; padding: 0 20px; border: 0; outline: 0; background: transparent; font-size: 16px; border-bottom: 1px solid var(--line); }
.palette-list { max-height: 50vh; overflow: auto; padding: 6px; }
.pal-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 12px; cursor: pointer; font-size: 13px; }
.pal-item .dir { color: var(--faint); font-size: 12px; margin-left: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 55%; }
.pal-item.sel { background: rgba(255,255,255,0.1); }
.pal-item b { color: var(--accent); font-weight: 700; }
.pal-empty { padding: 20px; text-align: center; color: var(--faint); }

.toasts { position: fixed; right: 18px; bottom: 18px; z-index: 300; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; pointer-events: none; }
.toast { pointer-events: auto; min-width: 260px; max-width: 380px; display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 18px; position: relative; overflow: hidden; background: var(--glass-strong); animation: toastIn 0.5s var(--spring) both; }
.toast.out { animation: toastOut 0.35s var(--ease) forwards; }
.toast .icon { font-size: 18px; margin-top: 1px; }
.toast.success .icon { color: var(--accent); } .toast.warn .icon { color: var(--warn); } .toast.error .icon { color: var(--danger); } .toast.info .icon { color: var(--accent-3); }
.toast b { display: block; font-size: 13.5px; }
.toast span { display: block; font-size: 12.5px; color: var(--muted); word-break: break-word; }
.toast .life { position: absolute; left: 0; bottom: 0; height: 2px; background: currentColor; opacity: 0.4; animation: life linear forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateX(30px) scale(0.95); filter: blur(6px); } }
@keyframes toastOut { to { opacity: 0; transform: translateX(30px) scale(0.95); } }
@keyframes life { from { width: 100%; } to { width: 0; } }

/* ── Boot loader ─────────────────────────────────────────────────────── */
.boot { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; background: var(--bg); overflow: hidden; transition: opacity 0.8s var(--ease), visibility 0.8s; }
.boot.leaving { opacity: 0; visibility: hidden; }
.boot.leaving .boot-inner { transform: scale(1.08); filter: blur(12px); opacity: 0; }
.boot .ambient { position: absolute; }
.boot-inner { position: relative; text-align: center; transition: transform 0.8s var(--ease), filter 0.8s var(--ease), opacity 0.6s; }
.boot-logo { width: 104px; height: 104px; margin: 0 auto 26px; position: relative; }
.boot-logo svg { width: 100%; height: 100%; overflow: visible; }
.boot-logo .draw { fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 400; stroke-dashoffset: 400; animation: draw 1.4s var(--ease-out) forwards; }
.boot-logo .draw.d2 { animation-delay: 0.25s; stroke: var(--accent); }
.boot-logo .draw.d3 { animation-delay: 0.45s; stroke: var(--accent-2); }
.boot-logo .core { fill: #fff; transform-origin: center; transform: scale(0); animation: pop 0.6s var(--spring) 0.9s forwards; }
.boot-logo::after { content: ""; position: absolute; inset: -30px; border-radius: 50%; background: radial-gradient(circle, rgba(52,211,153,0.25), transparent 60%); animation: breathe 2.4s var(--ease) infinite; z-index: -1; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pop { to { transform: scale(1); } }
@keyframes breathe { 0%, 100% { opacity: 0.6; transform: scale(0.9); } 50% { opacity: 1; transform: scale(1.1); } }
.boot-title { font-size: clamp(34px, 6vw, 56px); font-weight: 800; letter-spacing: -0.05em; margin: 0; display: flex; justify-content: center; }
.boot-title span { display: inline-block; opacity: 0; transform: translateY(24px) rotateX(-60deg); filter: blur(8px); animation: letter 0.8s var(--ease-out) forwards; animation-delay: calc(0.5s + var(--i) * 55ms); }
.boot-title span.x { color: var(--accent); }
@keyframes letter { to { opacity: 1; transform: none; filter: none; } }
.boot-sub { margin: 10px 0 30px; color: var(--muted); font-size: 14px; opacity: 0; animation: fadeUp 0.8s var(--ease-out) 1.1s forwards; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.boot-progress { width: min(320px, 70vw); margin: 0 auto; opacity: 0; animation: fadeUp 0.6s var(--ease-out) 1.2s forwards; }
.boot-progress .bar { height: 3px; }
.boot-step { display: flex; justify-content: space-between; margin-top: 12px; font-size: 11.5px; font-family: var(--mono); color: var(--faint); }
.boot-step #bootStep { transition: opacity 0.25s; }
.boot-skip { position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%); font-size: 11.5px; color: var(--faint); opacity: 0; animation: fadeUp 0.6s var(--ease-out) 2s forwards; }

/* ── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 1080px) {
  .grid-2 { grid-template-columns: 1fr; }
  .engine-pill .label { display: none; }
}
@media (max-width: 860px) {
  .topbar { top: 12px; padding: 0 16px; }
  .nav { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); height: 60px; padding: 0 8px; }
  .nav-indicator { top: 8px; height: 44px; }
  .nav-btn { height: 44px; padding: 0 14px; flex-direction: column; justify-content: center; gap: 1px; font-size: 10px; }
  .nav-btn .icon { font-size: 18px; }
  .page { padding: 84px 16px 110px; }
  .page.full { padding: 76px 10px 92px; }
  .mission { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .toggles, details.more .more-body { grid-template-columns: 1fr; }
  .ws, .ws.side-collapsed { grid-template-columns: 46px 1fr; }
  .ws .ws-side { position: absolute; z-index: 20; left: 46px; top: 0; bottom: 0; width: min(300px, 80vw); box-shadow: 20px 0 40px rgba(0,0,0,0.5); background: rgba(8,12,10,0.96); }
  .ws.side-collapsed .ws-side { display: none; }
  .ws { position: relative; }
  .split-preview { display: none; }
  .ed-actions .hide-sm { display: none; }
  .toasts { left: 16px; right: 16px; bottom: 92px; align-items: stretch; }
}
@media (max-width: 520px) {
  .hide-xs { display: none; }
  .nav-btn span.t { display: none; }
  .omnibox { padding-left: 16px; }
  .omnibox .btn-lg { padding: 0 18px; }
  .omnibox .btn-lg .t { display: none; }
  .brand small { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
