/* scraper-hub dashboard — Vercel-inspired, larger readable type, no build step. */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--fg);
  font-size: 15px;
  line-height: 1.6;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection { background: var(--fg); color: var(--bg); }
a { color: var(--acc); text-decoration: none; }
a:hover { color: var(--acc-press); }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.02em; }
code, pre, .mono { font-family: var(--mono); }
svg { display: block; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }

/* smooth color/elevation transitions on interactive surfaces */
.card, .stat, .badge, .btn, input, select, textarea,
.seg a, .chip, .banner, .icon-btn {
  transition: background-color .22s ease, border-color .22s ease, color .22s ease, box-shadow .2s ease;
}

/* ── entrance motion ─────────────────────────────────────── */
@keyframes fadeup { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.content { animation: fadeup .34s cubic-bezier(.22,.61,.36,1) both; }
.grid.kpi .stat { animation: fadeup .42s cubic-bezier(.22,.61,.36,1) both; }
.grid.kpi .stat:nth-child(2){animation-delay:.03s}.grid.kpi .stat:nth-child(3){animation-delay:.06s}
.grid.kpi .stat:nth-child(4){animation-delay:.09s}.grid.kpi .stat:nth-child(5){animation-delay:.12s}
.grid.kpi .stat:nth-child(6){animation-delay:.15s}.grid.kpi .stat:nth-child(7){animation-delay:.18s}
.grid.kpi .stat:nth-child(8){animation-delay:.21s}

/* ── layout ─────────────────────────────────────────────── */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex: 0 0 var(--sidebar-w);
  background: var(--sidebar-bg); border-right: 1px solid var(--line);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
}
.sidebar .brand { display: flex; align-items: center; gap: 11px; padding: 18px 20px 16px; font-weight: 600; font-size: 16px; letter-spacing: -0.02em; }
.sidebar .brand .logo { width: 30px; height: 30px; border-radius: 8px; background: var(--brand-grad); display: grid; place-items: center; color: #fff; }
.sidebar .brand .logo svg { width: 17px; height: 17px; }
.nav { padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; flex: 1; overflow-y: auto; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 9px 12px; border-radius: var(--r-md); color: var(--mut); font-weight: 500; font-size: 14px; position: relative; transition: background .14s, color .14s, transform .12s; }
.nav a svg { width: 18px; height: 18px; stroke-width: 1.9; opacity: .75; flex: 0 0 18px; }
.nav a:hover { background: var(--card-2); color: var(--fg); }
.nav a:hover svg { opacity: 1; }
.nav a.is-active { background: var(--acc-soft); color: var(--acc); font-weight: 600; }
.nav a.is-active svg { color: var(--acc); opacity: 1; }
.nav a.is-active::before { content: ''; position: absolute; left: -12px; top: 50%; transform: translateY(-50%); width: 3px; height: 18px; border-radius: 0 3px 3px 0; background: var(--acc); }
.nav .sep { margin: 14px 12px 6px; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; color: var(--faint); }
.sidebar .foot { padding: 14px 16px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--faint); }
.sidebar .foot .who { color: var(--mut); margin-bottom: 8px; word-break: break-all; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar { min-height: var(--topbar-h); display: flex; align-items: center; gap: 14px; padding: 0 28px; border-bottom: 1px solid var(--line); background: var(--topbar-bg); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 20; }
.topbar .pt-left { flex: 1; min-width: 0; }
.topbar .pt-back { display: inline-flex; align-items: center; gap: 6px; color: var(--mut); font-size: 14px; font-weight: 500; padding: 6px 10px; border-radius: var(--r-md); }
.topbar .pt-back:hover { background: var(--card-2); color: var(--fg); }
.topbar .pt-back svg { width: 15px; height: 15px; stroke-width: 2.2; }
.topbar .pt-right { display: flex; align-items: center; gap: 10px; }
.icon-btn { width: 36px; height: 36px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--card); color: var(--mut); display: grid; place-items: center; cursor: pointer; transition: background .13s, color .13s, border-color .13s; }
.icon-btn:hover { background: var(--card-2); color: var(--fg); border-color: var(--line-strong); }
.icon-btn svg { width: 17px; height: 17px; stroke-width: 2; }

.content { padding: 28px; max-width: 1520px; width: 100%; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 24px; gap: 16px; flex-wrap: wrap; }
.page-head h1 { font-size: 28px; font-weight: 600; letter-spacing: -0.03em; }
.page-head .sub { color: var(--mut); font-size: 14.5px; margin-top: 6px; }

/* ── cards & grid ────────────────────────────────────────── */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-1); }
.card .card-h { padding: 16px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.card .card-h h3 { font-size: 15.5px; font-weight: 600; }
.card .card-b { padding: 20px; }
.grid { display: grid; gap: 16px; }
.grid.kpi { grid-template-columns: repeat(auto-fit, minmax(196px, 1fr)); }
.cols-2 { grid-template-columns: 1.7fr 1fr; }
@media (max-width: 1100px) { .cols-2 { grid-template-columns: 1fr; } }

.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 20px; position: relative; overflow: hidden; box-shadow: var(--sh-1); transition: border-color .15s, transform .15s, box-shadow .15s; }
.stat:hover { border-color: var(--line-strong); transform: translateY(-2px); box-shadow: var(--sh-2); }
.stat .stat-top { display: flex; align-items: center; justify-content: space-between; }
.stat .ic { width: 32px; height: 32px; border-radius: 8px; background: var(--card-3); display: grid; place-items: center; color: var(--fg); }
.stat .ic svg { width: 16px; height: 16px; stroke-width: 1.9; }
.stat .label { font-size: 13px; color: var(--mut); font-weight: 500; }
.stat .value { font-size: 30px; font-weight: 600; margin-top: 12px; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stat .value small { font-size: 14px; color: var(--mut); font-weight: 500; letter-spacing: 0; }
.stat .accent { position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: transparent; }
.stat.ok .accent { background: var(--ok); } .stat.warn .accent { background: var(--warn); }
.stat.bad .accent { background: var(--bad); } .stat.run .accent { background: var(--run); }

/* ── badges / dots ───────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-full); font-family: var(--font); font-size: 12.5px; font-weight: 500; line-height: 1.5; white-space: nowrap; }
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.pending { color: var(--pending); background: var(--pending-soft); }
.badge.running { color: var(--run); background: var(--run-soft); }
.badge.done    { color: var(--ok);  background: var(--ok-soft); }
.badge.failed  { color: var(--bad); background: var(--bad-soft); }
.badge.active  { color: var(--ok);  background: var(--ok-soft); }
.badge.draining{ color: var(--warn); background: var(--warn-soft); }
.badge.dead    { color: var(--bad); background: var(--bad-soft); }
.badge.flag    { color: var(--warn); background: var(--warn-soft); }
.badge.muted   { color: var(--mut); background: var(--pending-soft); }
.dotpulse { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: 0 0 9px; }
.dotpulse.ok { background: var(--ok); box-shadow: 0 0 0 0 var(--ok-soft); animation: pulse 2.4s infinite; }
.dotpulse.warn { background: var(--warn); } .dotpulse.bad { background: var(--bad); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 var(--ok-soft); } 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

/* ── health banner ───────────────────────────────────────── */
.banner { display: flex; align-items: center; gap: 13px; padding: 15px 18px; border-radius: var(--r-lg); border: 1px solid var(--line); margin-bottom: 18px; animation: fadein .3s ease; font-size: 14.5px; }
.banner.ok { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 28%, transparent); }
.banner.warn { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 28%, transparent); }
.banner.bad { background: var(--bad-soft); border-color: color-mix(in srgb, var(--bad) 28%, transparent); }
.banner .b-ic { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 32px; }
.banner.ok .b-ic { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.banner.warn .b-ic { background: color-mix(in srgb, var(--warn) 16%, transparent); color: var(--warn); }
.banner.bad .b-ic { background: color-mix(in srgb, var(--bad) 16%, transparent); color: var(--bad); }
.banner .b-ic svg { width: 17px; height: 17px; stroke-width: 2.2; }
.banner .b-txt { flex: 1; }
.banner .b-txt b { font-weight: 600; }

/* ── tables ──────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: var(--r-lg); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
table.tbl th { text-align: left; padding: 11px 16px; color: var(--mut); font-weight: 600; font-size: 12px; letter-spacing: .01em; border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; background: var(--card); z-index: 1; }
table.tbl td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.tbl tr:last-child td { border-bottom: none; }
table.tbl tbody tr { transition: background .1s; }
table.tbl tbody tr:hover { background: var(--card-2); }
table.tbl.dense td, table.tbl.dense th { padding: 9px 16px; }
.clickable { cursor: pointer; }
.t-mut { color: var(--mut); } .t-faint { color: var(--faint); } .t-mono { font-family: var(--mono); font-size: 13px; }
.t-ok { color: var(--ok); } .t-warn { color: var(--warn); } .t-bad { color: var(--bad); }
.t-num { font-variant-numeric: tabular-nums; }

/* ── buttons ─────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 16px; border-radius: var(--r-md); border: 1px solid var(--line-strong); background: var(--card); color: var(--fg); font-size: 14px; font-weight: 500; cursor: pointer; font-family: var(--font); transition: background .13s, border-color .13s, transform .05s, box-shadow .13s, opacity .13s; white-space: nowrap; }
.btn:hover { background: var(--card-2); border-color: var(--line-strong); }
.btn:active { transform: translateY(1px); }
.btn svg { width: 15px; height: 15px; stroke-width: 2; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.btn.primary:hover { opacity: .85; }
.btn.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 40%, transparent); background: var(--bad-soft); }
.btn.danger:hover { background: color-mix(in srgb, var(--bad) 16%, transparent); }
.btn.ghost { background: transparent; border-color: var(--line); color: var(--mut); }
.btn.ghost:hover { color: var(--fg); border-color: var(--line-strong); background: var(--card-2); }
.btn.sm { padding: 6px 12px; font-size: 13px; border-radius: var(--r-sm); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ── forms ───────────────────────────────────────────────── */
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13.5px; color: var(--fg); margin-bottom: 7px; font-weight: 500; }
.field .hint { font-size: 13px; color: var(--faint); margin-top: 6px; }
input[type=text], input[type=password], input[type=email], input[type=number], input[type=date], select, textarea {
  width: 100%; padding: 10px 13px; background: var(--card); border: 1px solid var(--line-strong); border-radius: var(--r-md); color: var(--fg); font-size: 14.5px; font-family: inherit; outline: none; transition: border-color .13s, box-shadow .13s; }
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, select:focus, textarea:focus { border-color: var(--acc); box-shadow: var(--ring); }
textarea { resize: vertical; min-height: 92px; font-family: var(--mono); font-size: 13px; }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; user-select: none; font-size: 14px; }
.check input { width: auto; accent-color: var(--acc); width: 16px; height: 16px; }
.filters { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 18px; }
.filters .field { margin: 0; min-width: 152px; }
.seg { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--r-md); overflow: hidden; background: var(--card); }
.seg a { padding: 8px 15px; color: var(--mut); font-size: 13.5px; font-weight: 500; border-right: 1px solid var(--line); }
.seg a:last-child { border-right: none; }
.seg a:hover { background: var(--card-2); color: var(--fg); }
.seg a.on { background: var(--acc-soft); color: var(--acc); }

/* ── drawer / modal ──────────────────────────────────────── */
.scrim { position: fixed; inset: 0; background: rgba(17,17,17,.4); z-index: 40; opacity: 0; pointer-events: none; transition: opacity .2s; }
.scrim.open { opacity: 1; pointer-events: auto; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: 600px; max-width: 94vw; background: var(--card); border-left: 1px solid var(--line); box-shadow: var(--sh-drawer); z-index: 41; transform: translateX(100%); transition: transform .26s cubic-bezier(.4,0,.2,1); display: flex; flex-direction: column; }
.drawer.open { transform: translateX(0); }
.drawer .d-h { padding: 17px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.drawer .d-h h3 { font-size: 16px; }
.drawer .d-b { padding: 20px; overflow-y: auto; flex: 1; }
.x-close { cursor: pointer; color: var(--mut); width: 32px; height: 32px; border-radius: var(--r-sm); display: grid; place-items: center; background: none; border: none; transition: background .12s; }
.x-close:hover { background: var(--card-2); color: var(--fg); }
.x-close svg { width: 18px; height: 18px; stroke-width: 2; }
.kv { display: grid; grid-template-columns: 136px 1fr; gap: 11px 16px; font-size: 14px; }
.kv dt { color: var(--mut); } .kv dd { margin: 0; }
pre.json { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px; overflow-x: auto; font-size: 12.5px; color: var(--fg); white-space: pre-wrap; word-break: break-word; }

/* ── toast ───────────────────────────────────────────────── */
#toasts { position: fixed; bottom: 24px; right: 24px; z-index: 60; display: flex; flex-direction: column; gap: 9px; }
.toast { padding: 13px 18px; border-radius: var(--r-md); background: var(--card); border: 1px solid var(--line-strong); box-shadow: var(--sh-2); font-size: 14px; min-width: 240px; animation: slidein .24s cubic-bezier(.22,.61,.36,1); }
.toast.ok { border-left: 3px solid var(--ok); } .toast.err { border-left: 3px solid var(--bad); }
@keyframes slidein { from { transform: translateX(24px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ── logs ────────────────────────────────────────────────── */
.logbox { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-md); height: 60vh; overflow-y: auto; padding: 12px 14px; font-family: var(--mono); font-size: 12.5px; line-height: 1.75; }
.logline { padding: 2px 0; display: flex; gap: 12px; align-items: baseline; animation: fadein .2s ease; }
.logline .ts { color: var(--faint); white-space: nowrap; }
.logline .lv { width: 54px; flex: 0 0 54px; font-weight: 600; font-size: 11.5px; }
.logline .src { color: var(--acc); width: 90px; flex: 0 0 90px; }
.logline.debug .lv { color: var(--faint); } .logline.info .lv { color: var(--ok); }
.logline.warning .lv { color: var(--warn); } .logline.error .lv { color: var(--bad); }
.logline .msg { color: var(--fg); word-break: break-word; }

/* ── misc ────────────────────────────────────────────────── */
.empty { text-align: center; padding: 56px 20px; color: var(--mut); font-size: 14.5px; }
.empty .big { width: 48px; height: 48px; margin: 0 auto 14px; border-radius: 12px; background: var(--card-2); border: 1px solid var(--line); display: grid; place-items: center; color: var(--faint); }
.empty .big svg { width: 22px; height: 22px; }
.bar { height: 8px; border-radius: var(--r-full); background: var(--bg-2); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--acc); border-radius: var(--r-full); transition: width .5s cubic-bezier(.22,.61,.36,1); }
.bar.ok > span { background: var(--ok); } .bar.warn > span { background: var(--warn); } .bar.bad > span { background: var(--bad); }
.pagination { display: flex; gap: 7px; margin-top: 18px; justify-content: center; align-items: center; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 8px 14px; border-radius: var(--r-md); border: 1px solid var(--line); color: var(--mut); font-size: 14px; }
.pagination a:hover { background: var(--card-2); color: var(--fg); }
.pagination .active span { background: var(--acc-soft); color: var(--acc); border-color: color-mix(in srgb, var(--acc) 40%, transparent); }
.row { display: flex; gap: 10px; align-items: center; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.gap-sm { gap: 6px; } .mt { margin-top: 16px; } .mb { margin-bottom: 16px; }
.muted-card { color: var(--mut); font-size: 14px; }
.guest-wrap { min-height: 100vh; display: grid; place-items: center; background:
  radial-gradient(60% 50% at 50% -5%, rgba(121,40,202,.10), transparent 60%),
  radial-gradient(50% 40% at 85% 10%, rgba(0,124,240,.10), transparent 60%),
  radial-gradient(50% 40% at 15% 12%, rgba(255,0,128,.07), transparent 60%),
  var(--bg); }
.guest-card { width: 384px; max-width: 92vw; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 34px; box-shadow: var(--sh-2); animation: fadeup .35s cubic-bezier(.22,.61,.36,1) both; }
.guest-card .brand { display: flex; align-items: center; gap: 11px; margin-bottom: 6px; font-weight: 600; font-size: 19px; letter-spacing: -0.02em; }
.guest-card .logo { width: 38px; height: 38px; border-radius: 10px; background: var(--brand-grad); display: grid; place-items: center; color: #fff; }
.guest-card .logo svg { width: 20px; height: 20px; }
.guest-card .tagline { color: var(--mut); font-size: 14px; margin-bottom: 24px; }
.err-text { color: var(--bad); font-size: 13px; margin-top: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: var(--r-full); background: var(--card); border: 1px solid var(--line); color: var(--mut); font-family: var(--font); font-size: 12.5px; font-weight: 500; }
/* ── public (API hub / docs) ─────────────────────────────── */
.pubnav { height: 60px; display: flex; align-items: center; justify-content: space-between; padding: 0 28px; border-bottom: 1px solid var(--line); background: var(--topbar-bg); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 20; }
.pb-brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 16px; color: var(--fg); letter-spacing: -.02em; }
.pb-brand:hover { color: var(--fg); }
.pb-brand .logo { width: 28px; height: 28px; border-radius: 8px; background: var(--brand-grad); display: grid; place-items: center; color: #fff; }
.pb-brand .logo svg { width: 16px; height: 16px; }
.pb-links { display: flex; align-items: center; gap: 18px; }
.pb-links a { color: var(--mut); font-size: 14px; font-weight: 500; }
.pb-links a:hover { color: var(--fg); }
.pub-main { max-width: 880px; margin: 0 auto; padding: 24px 28px 90px; width: 100%; animation: fadeup .34s cubic-bezier(.22,.61,.36,1) both; }
.pub-foot { border-top: 1px solid var(--line); padding: 24px 28px; text-align: center; color: var(--faint); font-size: 13px; }
.hero { max-width: 940px; margin: 0 auto; padding: 80px 28px 36px; text-align: center; animation: fadeup .4s cubic-bezier(.22,.61,.36,1) both; }
.hero h1 { font-size: 46px; font-weight: 600; letter-spacing: -.045em; line-height: 1.08; }
.hero p { color: var(--mut); font-size: 18px; margin: 18px auto 0; line-height: 1.6; max-width: 620px; }
.hero .btn-row { justify-content: center; margin-top: 28px; }
.hero-grad { height: 4px; width: 130px; margin: 30px auto 0; border-radius: 99px; background: var(--brand-grad); }
.feat { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; max-width: 940px; margin: 16px auto 0; padding: 0 28px; }
.feat .card-b .ic { width: 34px; height: 34px; border-radius: 9px; background: var(--card-3); display: grid; place-items: center; color: var(--acc); margin-bottom: 12px; }
.feat .card-b .ic svg { width: 18px; height: 18px; stroke-width: 2; }
.feat h3 { font-size: 16px; margin-bottom: 6px; }
.feat p { color: var(--mut); font-size: 14px; margin: 0; }
.doc h2 { font-size: 25px; margin: 44px 0 14px; letter-spacing: -.02em; }
.doc h3 { font-size: 17px; margin: 26px 0 10px; }
.doc p, .doc li { color: var(--fg); }
.doc p { margin: 10px 0; line-height: 1.7; }
.doc ul { padding-left: 20px; } .doc li { margin: 7px 0; line-height: 1.6; }
.doc .lead { font-size: 16.5px; color: var(--mut); line-height: 1.7; }
.doc code:not(pre code) { background: var(--card-3); padding: 2px 6px; border-radius: 5px; font-size: 13px; font-family: var(--mono); }
.codeblock { background: #0d0d10; color: #e6e6e6; border-radius: var(--r-md); padding: 16px 18px; overflow-x: auto; font-family: var(--mono); font-size: 13px; line-height: 1.75; margin: 14px 0; border: 1px solid #1e1e22; white-space: pre; }
.codeblock .c { color: #7a7f87; } .codeblock .k { color: #7cc7ff; } .codeblock .s { color: #9ae6a0; }
.method { font-family: var(--mono); font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 5px; }
.method.get { color: var(--run); background: var(--run-soft); } .method.post { color: var(--ok); background: var(--ok-soft); }
.endpoint { display: flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 14px; margin: 30px 0 4px; padding-top: 18px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.endpoint .path { font-weight: 600; }
.callout { border: 1px solid var(--line); border-left: 3px solid var(--acc); background: var(--card-2); border-radius: var(--r-md); padding: 14px 16px; margin: 16px 0; font-size: 14px; }
.callout b { font-weight: 600; }

/* ── docs shell (sidebar + content) ──────────────────────── */
.docs-shell { display: flex; max-width: 1260px; margin: 0 auto; align-items: flex-start; }
.docs-side { width: 250px; flex: 0 0 250px; border-right: 1px solid var(--line); padding: 22px 14px 40px; position: sticky; top: 60px; height: calc(100vh - 60px); overflow-y: auto; }
.docs-side .grp { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--faint); font-weight: 600; margin: 18px 10px 6px; }
.docs-side .grp:first-child { margin-top: 4px; }
.docs-side a { display: block; padding: 7px 10px; border-radius: var(--r-sm); color: var(--mut); font-size: 14px; font-weight: 500; }
.docs-side a:hover { background: var(--card-2); color: var(--fg); }
.docs-side a.on { background: var(--acc-soft); color: var(--acc); font-weight: 600; }
.docs-side a.ch { display: flex; align-items: center; gap: 8px; }
.docs-side a.ch .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ok); flex: 0 0 6px; }
.docs-content { flex: 1; min-width: 0; padding: 30px 44px 90px; max-width: 880px; animation: fadeup .3s cubic-bezier(.22,.61,.36,1) both; }
.docs-content h1 { font-size: 32px; letter-spacing: -.03em; }
@media (max-width: 900px) { .docs-side { display: none; } .docs-content { padding: 24px; } }

/* ── demo console ────────────────────────────────────────── */
.console-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
@media (max-width: 1100px) { .console-grid { grid-template-columns: 1fr; } }
.resp-pane { position: sticky; top: 78px; }
.resp-box { background: #0d0d10; color: #e6e6e6; border: 1px solid #1e1e22; border-radius: var(--r-md); padding: 16px; font-family: var(--mono); font-size: 12.5px; line-height: 1.6; min-height: 160px; max-height: 60vh; overflow: auto; white-space: pre-wrap; word-break: break-word; }
.resp-status { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: var(--r-full); margin-bottom: 10px; }
.resp-status.ok { color: var(--ok); background: var(--ok-soft); } .resp-status.err { color: var(--bad); background: var(--bad-soft); } .resp-status.wait { color: var(--mut); background: var(--pending-soft); }

/* ── modal (top-anchored, overlay scrolls if tall — never clips) ── */
.modal-wrap { position: fixed; inset: 0; z-index: 50; display: none; overflow-y: auto; padding: 24px; background: rgba(17,17,17,.45); }
.modal-wrap.open { display: block; animation: fadein .15s; }
.modal { width: 540px; max-width: 94vw; margin: 24px auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-2); animation: fadeup .2s cubic-bezier(.22,.61,.36,1) both; }
.modal .m-h { padding: 16px 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.modal .m-h h3 { font-size: 16px; }
.modal .m-b { padding: 20px; }
.modal .m-f { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; gap: 8px; justify-content: flex-end; }
.ch-grid { display: flex; flex-wrap: wrap; gap: 10px 14px; }

/* ── section labels (group KPIs / panels) ────────────────── */
.section-label { display: flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 600; letter-spacing: .05em; color: var(--faint); text-transform: uppercase; margin: 26px 2px 12px; }
.section-label:first-of-type { margin-top: 2px; }
.section-label .ln { flex: 1; height: 1px; background: var(--line); }

/* ── clickable stat cards (link to filtered views) ───────── */
a.stat { color: inherit; text-decoration: none; display: block; }
a.stat:hover { color: inherit; }
.stat .sub { font-size: 12px; color: var(--faint); margin-top: 4px; font-weight: 500; }
.stat .go { position: absolute; right: 15px; bottom: 14px; color: var(--faint); opacity: 0; transform: translateX(-3px); transition: opacity .15s, transform .15s; }
.stat:hover .go { opacity: 1; transform: none; }
.stat .go svg { width: 16px; height: 16px; stroke-width: 2; }

/* ── mini live list (dashboard server panel) ─────────────── */
.mini-list { display: flex; flex-direction: column; }
.mini-row { display: flex; align-items: center; gap: 11px; padding: 12px 20px; border-bottom: 1px solid var(--line); transition: background .1s; }
.mini-row:last-child { border-bottom: none; }
a.mini-row { color: inherit; }
.mini-row:hover { background: var(--card-2); }
.mini-row .id { font-family: var(--mono); font-size: 13px; font-weight: 500; color: var(--fg); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-row .meta { color: var(--mut); font-size: 12.5px; white-space: nowrap; }

/* ── count pill inside segmented filter ──────────────────── */
.seg a { display: inline-flex; align-items: center; }
.seg a .cnt { margin-left: 7px; padding: 0 6px; border-radius: var(--r-full); background: var(--card-3); color: var(--mut); font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 17px; min-width: 18px; text-align: center; }
.seg a.on .cnt { background: color-mix(in srgb, var(--acc) 18%, transparent); color: var(--acc); }

/* ── summary strip (worker fleet header) ─────────────────── */
.summary-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 20px; }
.summary-strip .pill { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); box-shadow: var(--sh-1); }
.summary-strip .pill .n { font-size: 26px; font-weight: 600; color: var(--fg); font-variant-numeric: tabular-nums; letter-spacing: -.02em; line-height: 1; }
.summary-strip .pill .lbl { font-size: 13px; color: var(--mut); font-weight: 500; }
.summary-strip .pill.ok .n { color: var(--ok); } .summary-strip .pill.warn .n { color: var(--warn); } .summary-strip .pill.bad .n { color: var(--bad); }

/* ── worker fleet cards ──────────────────────────────────── */
.wk { display: flex; flex-direction: column; }
.wk .wk-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 15px 18px; border-bottom: 1px solid var(--line); }
.wk .wk-id { display: flex; align-items: center; gap: 9px; min-width: 0; }
.wk .wk-id b { font-family: var(--mono); font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wk .wk-job { padding: 13px 18px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.wk .wk-job .jl { font-size: 12.5px; color: var(--faint); font-weight: 500; }
.wk .wk-job .jv { font-size: 14px; font-weight: 500; }
.wk dl.wk-kv { margin: 0; padding: 14px 18px; display: grid; grid-template-columns: 72px 1fr; gap: 9px 14px; font-size: 13.5px; }
.wk dl.wk-kv dt { color: var(--faint); } .wk dl.wk-kv dd { margin: 0; text-align: right; }
.wk .wk-f { padding: 12px 18px; border-top: 1px solid var(--line); display: flex; gap: 8px; margin-top: auto; }
.wk .wk-f .btn { flex: 1; justify-content: center; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
