:root {
  --bg: #101114;
  --sidebar: #0a0b0e;
  --panel: #16181d;
  --ink: #f2f3f5;
  --muted: #8a8f9a;
  --line: #3a3e48;
  --blue: #2563eb;
  --green: #16a34a;
  --yellow: #ca8a04;
  --red: #dc2626;
  --orange: #ea580c;
  --r: 0;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--ink); font-family: "Segoe UI", system-ui, sans-serif; font-size: 14px; }
a { color: var(--blue); }
.shell { display: grid; grid-template-columns: 228px 1fr; min-height: 100vh; }
.shell.finder-shell { height: 100vh; overflow: hidden; }
.shell.finder-shell .nav { overflow: auto; }
main.finder-main { padding: 0 !important; overflow: hidden; min-height: 0; height: 100vh; }
.finder-frame { width: 100%; height: 100%; border: 0; display: block; background: #0b1020; }
.nav { background: var(--sidebar); padding: 18px 12px 28px; border-right: 1px solid var(--line); }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 16px; margin: 0 8px 22px; color: #fff; letter-spacing: .02em; }
.logo img { width: 38px; height: 38px; object-fit: contain; display: block; background: transparent; border: 0; border-radius: 10px; flex: none; }
.logo-bare { margin: 0 auto 18px; justify-content: center; }
.login .logo { margin: 0 auto 18px; font-size: 20px; justify-content: center; }
.login .logo img { width: 52px; height: 52px; }
.login-bare { gap: 12px; text-align: center; }
.login-bare input { width: 100%; box-sizing: border-box; }
.login-bare button { width: 100%; font-size: 20px; letter-spacing: .08em; }
.nav-sec { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: #6b7280; padding: 14px 12px 6px; }
.nav a { display: flex; align-items: center; gap: 10px; color: #c5c9d4; text-decoration: none; padding: 9px 12px; border-radius: 0; margin-bottom: 0; border-left: 3px solid transparent; }
.nav a svg { width: 16px; height: 16px; opacity: .85; flex: none; }
.nav a.active, .nav a:hover { background: #1d4ed8; color: #fff; border-left-color: #93c5fd; }
.nav .out { margin-top: 20px; color: var(--muted); font-size: 13px; }
.nav .out:hover { background: #252833; color: #fff; }
main { padding: 20px 22px 48px; min-width: 0; }
h1 { font-size: 22px; margin: 0 0 8px; }
.lead { color: var(--muted); margin: 0 0 18px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }
.stats.pair { grid-template-columns: 1fr 1fr; }
.day-summary.stats.pair { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) {
  .day-summary.stats.pair { grid-template-columns: 1fr 1fr; }
}
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 0; padding: 12px 14px 14px; border-top: 3px solid var(--blue); }
.stat.g { border-top-color: var(--green); }
.stat.y { border-top-color: var(--yellow); }
.stat.r { border-top-color: var(--red); }
.stat small { display: block; color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.stat b { font-size: 28px; font-weight: 700; }
.load-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.load-bar { height: 8px; background: #1c1f28; border: 1px solid var(--line); margin-top: 8px; overflow: hidden; }
.load-bar > i { display: block; height: 100%; background: var(--green); }
.stat.y .load-bar > i { background: var(--yellow); }
.stat.r .load-bar > i { background: var(--red); }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.toolbar .grow { flex: 1; min-width: 140px; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tab { background: #252833; color: #d1d5db; border: 1px solid var(--line); border-radius: 0; padding: 8px 12px; cursor: pointer; font: inherit; }
.tab.on { background: #1d4ed8; color: #fff; }
.btn, button {
  background: var(--green); color: #052e16; border: 1px solid #14532d; border-radius: 0;
  padding: 8px 12px; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; font: inherit;
}
.btn.ghost, button.ghost { background: #252833; color: var(--ink); border-color: var(--line); }
.btn.blue, button.blue { background: var(--blue); color: #fff; border-color: #1e40af; }
.btn.red, button.red, button.danger { background: var(--red); color: #fff; border-color: #991b1b; }
.btn.yellow { background: var(--yellow); color: #1c1403; border-color: #854d0e; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 0; padding: 16px; }
.card h3 { margin: 0 0 6px; font-size: 16px; }
.muted { color: var(--muted); font-size: 13px; }
.blog-admin-card {
  border: 1px solid #3a3e48;
  border-radius: 0;
  padding: 14px;
  margin: 0 0 10px;
  background: #1c1f28;
  color: #eef0f4;
}
.blog-admin-card .blog-admin-title {
  display: block;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}
.blog-admin-card .blog-admin-meta {
  font-size: 12px;
  margin: 6px 0 8px;
  color: #a8b0bd;
}
.blog-admin-card .blog-admin-excerpt {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.5;
  color: #d5dae3;
}
.blog-admin-card .blog-admin-actions { gap: 6px; flex-wrap: wrap; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
form.stack { display: grid; gap: 12px; max-width: 760px; }
.seo-form { max-width: none; display: block; }
.seo-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.seo-head h1 { margin: 0; font-size: 20px; }
.seo-grid { display: grid; grid-template-columns: 1fr 280px; gap: 14px; align-items: start; }
.sec { background: var(--panel); border: 1px solid var(--line); border-radius: 0; margin-bottom: 12px; overflow: hidden; }
.sec > summary, .sec-h { list-style: none; cursor: pointer; background: #161922; padding: 10px 14px; font-size: 13px; font-weight: 700; border-bottom: 1px solid var(--line); }
.sec > summary::-webkit-details-marker { display: none; }
.sec .body { padding: 14px; display: grid; gap: 10px; }
.shift-h { font-size: 15px; margin: 18px 0 8px; }
.shift-pane > summary::after { content: "▾"; color: var(--muted); font-weight: 400; transition: transform .2s ease; }
.shift-pane[open] > summary::after { transform: rotate(-180deg); }
.shift-pane > summary .shift-title { display: flex; align-items: center; gap: 8px; }
.shift-pane .shift-meta { font-weight: 500; color: var(--muted); font-size: 12px; letter-spacing: 0; text-transform: none; }
.shift-live { color: #86efac; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; border: 1px solid #166534; padding: 2px 6px; }
.shift-pane .shift-slide { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .28s ease; }
.shift-pane[open] .shift-slide { grid-template-rows: 1fr; }
.shift-pane .shift-slide > .body { overflow: hidden; min-height: 0; }
.cats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px 10px; }
.cats label { display: flex; align-items: center; gap: 6px; color: var(--ink); font-size: 12px; }
.city-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px 8px; max-height: 240px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 0; background: #12141a; }
.city-grid label { display: flex; align-items: center; gap: 6px; color: var(--ink); font-size: 12px; }
.loc-block { display: grid; gap: 8px; }
.loc-picker { display: grid; gap: 8px; }
.loc-h { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--muted); }
.loc-picked { color: var(--ink); }
.loc-filter { max-width: 260px; }
.loc-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(108px, 1fr)); gap: 6px; max-height: 220px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 0; background: #12141a; }
.loc-card { background: #1c1f28; color: var(--ink); border: 1px solid var(--line); border-radius: 0; padding: 9px 6px; font-size: 12px; font-weight: 600; cursor: pointer; text-align: center; line-height: 1.2; }
.loc-card.on { background: #1d4ed8; color: #fff; border-color: #3b82f6; }
.loc-semt { display: flex; flex-wrap: wrap; gap: 6px; max-height: 140px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 0; background: #12141a; }
.loc-chip { background: #252833; color: var(--ink); border: 1px solid var(--line); border-radius: 0; padding: 4px 8px; font-size: 11px; font-weight: 600; }
.pool-block { display: grid; gap: 8px; }
.pool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 6px; max-height: 260px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: 0; background: #12141a; }
.pool-item { background: #1c1f28; color: var(--ink); border: 1px solid var(--line); border-radius: 0; padding: 10px 8px; font-size: 12px; font-weight: 600; cursor: pointer; text-align: left; line-height: 1.3; word-break: break-all; }
.pool-item.on { background: #1d4ed8; color: #fff; border-color: #3b82f6; }
.pool-empty { margin: 8px; }
.field-ai { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: start; position: relative; }
.field-ai.has-marks { grid-template-columns: 1fr auto; }
.field-ai.has-marks.with-ai { grid-template-columns: 1fr auto auto; }
.field-ai.has-marks.with-var { grid-template-columns: 1fr auto auto; }
.field-ai.has-marks.with-ai.with-var { grid-template-columns: 1fr auto auto auto; }
.field-ai.with-var { grid-template-columns: 1fr auto; }
.field-ai.with-ai.with-var { grid-template-columns: 1fr auto auto; }
.field-ai button { white-space: nowrap; font-size: 12px; }
.field-ai .js-title-var,
.field-ai .js-desc-var { padding: 8px 10px; }
.field-ai .js-marks { width: 38px; min-height: 38px; font-size: 16px; padding: 0; }
.mark-pop {
  position: absolute;
  left: 0;
  top: calc(100% + 6px);
  z-index: 24;
  display: grid;
  grid-template-columns: repeat(8, 34px);
  gap: 4px;
  width: max-content;
  max-width: calc(100vw - 48px);
  padding: 8px;
  background: #0f1218;
  border: 1px solid var(--line);
  box-shadow: 0 10px 28px rgba(0,0,0,.45);
}
.mark-pop[hidden] { display: none; }
.mark-pop .mark-i {
  width: 34px;
  height: 34px;
  padding: 0;
  justify-content: center;
  background: #1c1f28;
  color: var(--ink);
  border: 1px solid var(--line);
  font-size: 15px;
  line-height: 1;
}
.mark-pop .mark-i:hover { background: #1d4ed8; color: #fff; }
.ribbon { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.ribbon .btn, .ribbon button, .ribbon a.btn { font-size: 12px; border-radius: 0; padding: 8px 10px; }
.rail { background: var(--panel); border: 1px solid var(--line); border-radius: 0; padding: 14px; display: grid; gap: 12px; position: sticky; top: 16px; }
.rail h3 { margin: 0; font-size: 13px; }
.rail .rail-deploy { width: 100%; display: block; text-align: center; font-weight: 700; letter-spacing: .04em; padding: 12px 14px; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--ink); font-size: 13px; }
.switch input { width: 18px; height: 18px; }
@media (max-width: 1100px) {
  .seo-grid { grid-template-columns: 1fr; }
  .cats { grid-template-columns: repeat(2, 1fr); }
  .city-grid { grid-template-columns: repeat(2, 1fr); }
  .rail { position: static; }
}
label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
input, textarea, select {
  background: #12141a; border: 1px solid var(--line); color: var(--ink);
  border-radius: 0; padding: 9px 11px; font: inherit;
}
textarea { min-height: 140px; resize: vertical; }
.plain-intro { min-height: 420px; font-size: 15px; line-height: 1.65; font-family: inherit; }
.h1-field { font-size: 20px !important; font-weight: 800 !important; color: #fff !important; }
.article-tools { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 8px; }
.article-tools .ghost { padding: 6px 10px; font-size: 12px; }
.article-edit {
  min-height: 420px;
  max-height: 70vh;
  overflow: auto;
  background: #0f1116;
  border: 1px solid var(--line);
  padding: 16px 18px 28px;
  line-height: 1.65;
  color: #e8eaed;
  font-size: 15px;
}
.article-edit:focus { outline: 1px solid #2563eb; }
.article-edit h1, .article-edit h2 {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.25;
  margin: 22px 0 10px;
  color: #fff;
}
.article-edit h3 {
  font-size: 17px;
  font-weight: 700;
  margin: 16px 0 8px;
  color: #fbbf24;
}
.article-edit p { margin: 0 0 12px; }
.article-edit ul { margin: 0 0 12px; padding-left: 18px; }
.article-edit .kw-cloud,
.article-edit .seo-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 20px 0 12px;
}
.article-edit .kw-pill {
  display: inline-block;
  padding: 5px 10px;
  border: 1px solid #3a4254;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.2;
  color: #c9c3b6;
  background: #141822;
  white-space: nowrap;
}
.article-edit .seo-toplinks { margin: 0 0 14px; font-size: 13px; color: #9aa3b2; }
.article-edit .seo-toplinks a { color: #93c5fd; }
.article-edit .hood-links { font-size: 13px; color: #9aa3b2; margin: 0 0 14px; }
.article-edit .hood-links a { color: #93c5fd; }
.ai-thumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; margin: 8px 0 12px; }
.ai-thumbs img { width: 92px; height: 128px; object-fit: cover; object-position: top; border-radius: 8px; background: #111; }
.ai-thumbs .muted { flex: 1 1 100%; margin: 0; }
.flash { padding: 10px 12px; border-radius: 0; background: #1e3a2f; margin: 12px 0; white-space: pre-wrap; }
.flash.err { background: #3a1e1a; }
.badge { display: inline-block; font-size: 11px; padding: 3px 8px; border-radius: 0; border: 1px solid var(--line); background: #252833; color: var(--muted); }
button.badge { font: inherit; cursor: pointer; }
.badge.on { background: #14532d; color: #86efac; }
.badge.off { background: #3f1d1d; color: #fca5a5; }
.badge.ready { color: #86efac; background: #14532d; }
.badge.deployed { color: #86efac; background: #14532d; }
.badge.draft { color: #e5e7eb; }
.badge.paused { color: #fcd34d; background: #3b2f0a; }
#toasts {
  position: fixed;
  top: 62px;
  right: 16px;
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(380px, calc(100vw - 24px));
  pointer-events: none;
}
#saved-pop {
  position: fixed;
  top: 14px;
  right: 16px;
  z-index: 10000;
  pointer-events: none;
}
.saved-pop {
  background: #14532d;
  border: 1px solid #22c55e;
  color: #ecfdf5;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .02em;
  box-shadow: 0 8px 28px rgba(0,0,0,.55);
  animation: toast-in .14s ease-out;
}
.saved-pop.out {
  opacity: 0;
  transform: translateX(16px);
  transition: opacity .18s, transform .18s;
}
.toast {
  background: #1e3a2f;
  border: 1px solid #14532d;
  color: var(--ink);
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  white-space: pre-wrap;
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
  animation: toast-in .14s ease-out;
}
.toast.err { background: #3a1e1a; border-color: #991b1b; }
.toast.out { opacity: 0; transform: translateX(16px); transition: opacity .18s, transform .18s; }
@keyframes toast-in {
  from { opacity: 0; transform: translateX(16px); }
  to { opacity: 1; transform: none; }
}
.pool-saved {
  display: inline-block;
  margin-left: 8px;
  background: #14532d;
  color: #86efac;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .03em;
  vertical-align: middle;
  animation: pool-flash .45s ease;
}
.pool-saved.ok { background: #14532d; color: #86efac; }
.pool-saved.err { background: #3f1d1d; color: #fca5a5; animation: none; }
.pool-saved[hidden] { display: none !important; }
@keyframes pool-flash {
  0% { transform: scale(.92); opacity: .4; }
  60% { transform: scale(1.04); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
.pill { display: inline-block; background: #1d4ed8; color: #fff; border-radius: 0; padding: 3px 10px; font-size: 12px; font-weight: 600; }
.pill.ok { background: #14532d; color: #86efac; }
.pill.bad { background: #7f1d1d; color: #fca5a5; }
.pill.warn { background: #3f2f05; color: #fde68a; }
.log-box { max-height: 160px; overflow: auto; background: #0a0b0e; border: 1px solid var(--line); padding: 10px; font-family: Consolas, monospace; font-size: 12px; color: var(--muted); margin: 10px 0; white-space: pre-wrap; }
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 0; background: var(--panel); }
table.dom { width: 100%; border-collapse: collapse; min-width: 760px; }
table.dom td:last-child, table.dom th:last-child { position: sticky; right: 0; background: var(--panel); }
.table-wrap.slim { overflow-x: auto; }
.table-wrap.slim table.dom { min-width: 0; table-layout: fixed; width: 100%; }
.table-wrap.slim table.dom td:last-child,
.table-wrap.slim table.dom th:last-child { position: static; }
.table-wrap.slim table.dom th,
.table-wrap.slim table.dom td { text-align: left; }
.table-wrap.slim table.dom th.col-i,
.table-wrap.slim table.dom td.col-i { width: 36px; text-align: right; color: var(--muted); white-space: nowrap; }
.table-wrap.slim table.dom th.col-name,
.table-wrap.slim table.dom td.col-name { width: auto; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.table-wrap.slim table.dom th.col-num,
.table-wrap.slim table.dom td.col-num { width: 72px; text-align: right; white-space: nowrap; }
.table-wrap.slim table.dom td.col-name .dom-meta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-bars { display: flex; flex-direction: column; gap: 8px; margin: 0 0 8px; }
.rank-row { display: flex; gap: 10px; align-items: flex-start; }
.rank-i { width: 22px; flex: 0 0 22px; font-size: 12px; color: var(--muted); padding-top: 2px; text-align: right; }
.rank-main { flex: 1; min-width: 0; }
.rank-label { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; justify-content: space-between; margin-bottom: 4px; font-size: 13px; }
.rank-label .dom-name { flex: 1 1 auto; min-width: 0; max-width: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-meta { flex: 0 0 auto; color: var(--muted); font-size: 11px; white-space: nowrap; }
.rank-track { height: 8px; background: #1a1e28; border: 1px solid var(--line); }
.rank-track > i { display: block; height: 100%; background: var(--green); max-width: 100%; }
.day-chart { margin: 0 0 8px; }
.day-summary { margin: 0 0 12px; }
.day-summary .stat-sub { display: block; font-size: 11px; color: var(--muted); font-weight: 500; margin-top: 2px; }
.day-chart-plot { display: flex; gap: 8px; align-items: stretch; border: 1px solid var(--line); background: #12151c; padding: 10px 8px 6px; }
.day-yscale { display: flex; flex-direction: column; justify-content: space-between; width: 36px; flex: 0 0 36px; font-size: 10px; color: var(--muted); text-align: right; padding: 2px 0 22px; line-height: 1; }
.day-bars { display: flex; align-items: flex-end; gap: 6px; height: 168px; flex: 1; min-width: 0; overflow-x: auto; padding: 0; border: 0; background: transparent; }
.day-bars.compact { height: 88px; gap: 4px; border: 1px solid var(--line); background: #12151c; padding: 8px 4px 0; }
.day-col { flex: 1 1 0; min-width: 28px; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; gap: 3px; position: relative; }
.day-col.peak .day-open { box-shadow: 0 0 0 1px #86efac; }
.day-val { font-size: 9px; color: #c8d0dc; line-height: 1; font-style: normal; font-variant-numeric: tabular-nums; }
.day-stack { display: flex; align-items: flex-end; justify-content: center; gap: 2px; width: 100%; height: calc(100% - 28px); }
.day-stack > span { display: block; width: 42%; min-width: 4px; max-width: 14px; border-radius: 2px 2px 0 0; }
.day-open { background: var(--green); }
.day-wa { background: var(--yellow); }
.day-col small { font-size: 10px; color: var(--muted); line-height: 1; white-space: nowrap; }
.day-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 8px 0 0; font-size: 12px; }
.day-legend .lg-open, .day-legend .lg-wa { width: 10px; height: 10px; display: inline-block; }
.day-legend .lg-open { background: var(--green); }
.day-legend .lg-wa { background: var(--yellow); }
.table-wrap.slim table.dom tr.on td { background: #1a2420; }
.mini-chart .day-bars { height: 88px; margin-top: 8px; }
.mini-chart .day-val { display: none; }
.mini-chart .day-col small { display: none; }
.mini-chart .day-legend { font-size: 11px; }
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 12px; }
.pager-meta { font-size: 12px; }
.pager .tabs { margin: 0; }
.pager .tab[disabled] { opacity: 0.35; pointer-events: none; }
table.dom th { text-align: left; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); font-weight: 600; }
table.dom td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.dom tr:hover td { background: #22262f; }
input.js-wa { width: 168px; max-width: 34vw; font: inherit; font-size: 13px; color: inherit; background: #16181e; border: 1px solid var(--line); padding: 7px 8px; }
table.dom tr:hover input.js-wa { background: #22262f; }
input.js-wa:focus { outline: 1px solid #3b82f6; border-color: #3b82f6; }
.dom-name { font-weight: 700; color: #fff; }
.dom-meta { color: var(--muted); font-size: 12px; margin-top: 3px; max-width: 360px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vit-cell { display: flex; flex-direction: row; align-items: center; gap: 8px; flex-wrap: nowrap; white-space: nowrap; }
.vit-cell .vit-state { font-size: 12px; font-weight: 700; letter-spacing: .01em; padding: 3px 8px; border-radius: 4px; }
.vit-cell .vit-state.on { background: #14532d; color: #bbf7d0; }
.vit-cell .vit-state.off { background: #3f1d1d; color: #fecaca; }
.vit-cell .btn.vit-tog { padding: 4px 10px; font-size: 12px; line-height: 1.2; white-space: nowrap; flex-shrink: 0; }
.btn.vit-tog:not(.red) { background: #14532d; color: #86efac; border: 1px solid #166534; }
.btn.vit-tog:not(.red):hover { background: #166534; }
.btn.vit-tog.red { background: #3f1d1d; color: #fca5a5; border: 1px solid #7f1d1d; }
.ico-btn { width: 28px; height: 28px; padding: 0; justify-content: center; background: #252833; color: #d1d5db; border-radius: 0; border: 1px solid var(--line); }
.ico-btn:hover { background: #1d4ed8; color: #fff; }
.ico-btn.danger { background: #3f1d1d; color: #fca5a5; }
.ico-btn.cf { background: #f97316; color: #fff; }
.ico-btn.cp { background: #c2410c; color: #fff; }
.ico-btn.idx { background: #0f766e; color: #fff; }
.ico-btn.cf:hover { background: #fb923c; color: #fff; }
.ico-btn.cp:hover { background: #ea580c; color: #fff; }
.ico-btn.idx:hover { background: #14b8a6; color: #fff; }
.btn.idx { background: #0f766e; color: #fff; }
.ico-btn.busy { opacity: .55; }
.btn.cf { background: #f97316; color: #fff; }
.btn.cp { background: #c2410c; color: #fff; }
.acts { display: flex; gap: 4px; flex-wrap: nowrap; }
table.dom td:nth-child(2) svg { width: 18px; height: 18px; color: var(--blue); display: block; }
.acts .ico-btn svg, .row .ico-btn svg, .rail .ico-btn svg { width: 15px; height: 15px; color: currentColor; display: block; }
.search { width: 220px; }
.steps { list-style: none; padding: 0; }
.steps li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.ok { color: var(--green); }
.no { color: var(--red); }
.login { min-height: 100vh; display: grid; place-items: center; }
.login .card { width: min(420px, 92vw); }
.site { min-height: 100vh; display: flex; flex-direction: column; }
.site-bar { display: flex; justify-content: space-between; align-items: center; padding: 16px 28px; border-bottom: 1px solid var(--line); background: var(--sidebar); }
.site-bar .logo { margin: 0; }
.site-hero { flex: 1; max-width: 980px; margin: 0 auto; padding: 56px 24px 40px; }
.site-hero h1 { font-size: clamp(32px, 5vw, 48px); line-height: 1.15; margin: 0 0 14px; letter-spacing: -0.02em; }
.site-hero-uf { display: flex; align-items: stretch; justify-content: center; max-width: none; width: 100%; padding: 0; overflow: hidden; min-height: calc(100vh - 72px); }
.site-hero-uf h1 { font-size: clamp(64px, 18vw, 220px); line-height: 0.9; margin: 0; letter-spacing: -0.06em; text-align: center; font-weight: 800; white-space: nowrap; }
.site-hero-photo { width: 100%; height: 100%; min-height: calc(100vh - 72px); object-fit: cover; object-position: center; display: block; }
.site-hero .lead { font-size: 16px; max-width: 560px; }
.site-hero .row { margin-top: 22px; }
.site-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 40px; }
.site-grid .card { min-height: 140px; }
.site-grid h3 { margin: 0 0 8px; font-size: 15px; }
.site-foot { border-top: 1px solid var(--line); padding: 16px 28px; color: var(--muted); font-size: 12px; }
@media (max-width: 800px) { .site-grid { grid-template-columns: 1fr; } .site-bar { padding: 14px 16px; } .site-hero-uf h1 { white-space: normal; } }
.login .card { width: min(420px, 92vw); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.selcount { color: var(--muted); font-size: 13px; min-width: 70px; }
.crumb { color: var(--muted); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 6px; }
.alert-bar { background: #3a1717; border: 1px solid #7f1d1d; padding: 12px 14px; border-radius: 0; display: flex; justify-content: space-between; gap: 12px; align-items: center; margin: 12px 0; }
.chip { border: 1px solid var(--line); background: #12141a; color: #d1d5db; padding: 8px 12px; border-radius: 0; cursor: pointer; font: inherit; }
.chip.on { background: #1d4ed8; color: #fff; border-color: #1d4ed8; }
.drop { border: 1px dashed var(--line); padding: 28px; text-align: center; border-radius: 0; color: var(--muted); }
.thumbs { display: flex; gap: 8px; flex-wrap: wrap; }
.thumbs .ph { position: relative; border: 2px solid transparent; }
.thumbs .ph.vitrin-on { border-color: #c9a227; }
.thumbs img { width: 88px; height: 88px; object-fit: cover; border-radius: 0; display: block; }
.thumbs button.del { position: absolute; top: 2px; right: 2px; width: 22px; height: 22px; padding: 0; background: #7f1d1d; color: #fff; }
.thumbs button.pick { position: absolute; left: 2px; bottom: 2px; top: auto; right: auto; width: auto; height: 20px; padding: 0 6px; font-size: 10px; background: #252833; color: #e5e7eb; }
.thumbs .ph.vitrin-on .pick { background: #c9a227; color: #1a1408; }
.progress { height: 6px; background: #252833; border-radius: 0; overflow: hidden; margin-top: 6px; }
.progress > span { display: block; height: 100%; background: #3b82f6; }
.boost-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.thumb-name { display: flex; gap: 10px; align-items: center; }
.thumb-name .sq { width: 36px; height: 36px; border-radius: 0; background: #1d4ed8; display: grid; place-items: center; font-weight: 700; overflow: hidden; }
.thumb-name img { width: 36px; height: 36px; object-fit: cover; }
.level-platin { background: #134e4a; color: #5eead4; }
.level-gold { background: #3b2f0a; color: #fcd34d; }
.level-silver { background: #1f2937; color: #d1d5db; }
.three { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
@media (max-width: 980px) {
  .boost-grid, .three { grid-template-columns: 1fr; }
}
@media (max-width: 980px) {
  .shell { grid-template-columns: 1fr; }
  .nav { display: block; }
  .stats { grid-template-columns: 1fr 1fr; }
  .two { grid-template-columns: 1fr; }
}
.api-sec { max-width: none; margin-bottom: 22px; }
.api-hd { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.api-hd h2 { margin: 0; font-size: 18px; }
.srv { background: #161922; border: 1px solid var(--line); border-radius: 0; padding: 14px; margin: 12px 0; }
.srv-top { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.srv-top strong { font-size: 15px; }
.sw { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.sw input { width: 16px; height: 16px; }
.hint { background: #3b2f0a; border: 1px solid #854d0e; color: #fde68a; padding: 10px 12px; border-radius: 0; font-size: 13px; line-height: 1.45; }
.flow { color: var(--muted); font-size: 13px; padding-left: 18px; margin: 10px 0 0; }
.flow li { margin: 6px 0; }
.flow code { color: var(--ink); font-size: 12px; }
.modal-bg { position: fixed; inset: 0; background: rgba(0,0,0,.55); display: grid; place-items: center; z-index: 40; padding: 16px; }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: 0; padding: 18px; width: min(460px, 100%); }
.modal h3 { margin: 0 0 8px; }
.pick { display: grid; gap: 8px; margin: 12px 0; }
.pick label { display: flex; align-items: center; gap: 8px; background: #12141a; border: 1px solid var(--line); border-radius: 0; padding: 10px 12px; color: var(--ink); }
.settings-wide { max-width: none; }
.chat-split { display: grid; grid-template-columns: 280px 1fr; gap: 0; border: 1px solid var(--line); min-height: 420px; background: var(--panel); }
.chat-list { border-right: 1px solid var(--line); overflow-y: auto; max-height: 70vh; }
.chat-list button { display: block; width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); color: inherit; padding: 12px 14px; cursor: pointer; font: inherit; }
.chat-list button.on, .chat-list button:hover { background: #1d2129; }
.chat-list button.wait { box-shadow: inset 3px 0 0 #1d4ed8; }
.chat-list button.wait small { color: #93c5fd; }
.chat-list small { display: block; color: var(--muted); font-size: 12px; margin-top: 4px; }
.chat-pane { display: flex; flex-direction: column; min-width: 0; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; min-height: 280px; max-height: 55vh; }
.chat-log .b { max-width: 80%; padding: 8px 10px; font-size: 13px; line-height: 1.4; white-space: pre-wrap; }
.chat-log .me { align-self: flex-end; background: #1d4ed8; color: #fff; }
.chat-log .them { align-self: flex-start; background: #232833; }
.chat-log .ai { align-self: flex-start; background: #1f2937; color: #cbd5e1; }
.chat-send { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.chat-send input { flex: 1; }
.chat-send .js-photo { min-width: 42px; font-size: 22px; line-height: 1; padding: 8px 0; }
.chat-log .b.pics, .qbox-m .b.pics { max-width: 92%; }
.chat-log .b img, .qbox-m .b img { display: block; width: 100%; max-width: 280px; height: auto; margin-top: 6px; cursor: zoom-in; background: #0c0e14; }
.chat-pick { position: fixed; inset: 0; background: rgba(0,0,0,.62); z-index: 80; display: grid; place-items: center; padding: 16px; }
.chat-pick[hidden] { display: none !important; }
.chat-pick-box { width: min(720px, 100%); max-height: 88vh; overflow: auto; background: var(--panel); border: 1px solid var(--line); padding: 14px; }
.chat-pick-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.chat-pick-g { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; margin: 12px 0; }
.chat-pick-card { display: grid; grid-template-columns: 18px 56px 1fr auto; gap: 8px; align-items: center; background: #12141a; border: 1px solid var(--line); padding: 8px; cursor: pointer; }
.chat-pick-card b, .chat-pick-card small { display: block; }
.chat-pick-card small { color: var(--muted); font-size: 12px; }
.chat-pick-card .sq { width: 56px; height: 56px; overflow: hidden; background: #1c1f28; display: grid; place-items: center; font-weight: 700; }
.chat-pick-card .sq img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
@media (max-width: 860px) { .chat-split { grid-template-columns: 1fr; } }


.lang-switch { display: flex; gap: 6px; margin: 10px 12px 4px; }
.lang-switch button { border: 1px solid #3a3f4b; background: #1b1e27; color: #cbd5e1; border-radius: 8px; padding: 4px 10px; font-size: 12px; font-weight: 700; letter-spacing: .04em; cursor: pointer; }
.lang-switch button.on { background: #f5c16c; color: #1a1408; border-color: #f5c16c; }
.login .lang-switch { margin: 0 0 8px; justify-content: flex-end; }
