:root {
  --bg: #edf0f4;
  --sidebar-bg: #0f1c2e;
  --sidebar-text: #d9e2ec;
  --sidebar-muted: #8b9cb0;
  --panel: #ffffff;
  --line: #d0d7e0;
  --line-soft: #e6ebf0;
  --text: #0f1c2e;
  --muted: #5a6b7d;
  --accent: #1a4f7a;
  --accent-hover: #143d5e;
  --teal: #1f8a7a;
  --gold: #c4921a;
  --coral: #c96a3a;
  --sky: #3d6f9c;
  --ok: #1b6548;
  --ok-bg: #e6f2eb;
  --warn: #7a6214;
  --warn-bg: #f5efd9;
  --err: #8f2a2a;
  --err-bg: #f5e6e6;
  --sidebar: 230px;
  --radius: 8px;
  --radius-sm: 6px;
  --font: "Source Sans 3", "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
}

/* ========== LOGIN: dolu 50/50 ========== */
.login-body {
  margin: 0;
  min-height: 100vh;
  background: var(--sidebar-bg);
}
.login-split {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.login-brand {
  background:
    linear-gradient(160deg, rgba(31, 138, 122, 0.18), transparent 42%),
    linear-gradient(20deg, #0f1c2e 0%, #16304d 100%);
  color: #e8eef5;
  padding: 48px 56px;
  display: flex;
  align-items: stretch;
}
.login-brand-inner {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.login-logo {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 36px;
}
.login-logo strong {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
}
.login-logo em {
  display: block;
  font-style: normal;
  color: #9eb0c3;
  font-size: 0.84rem;
  margin-top: 2px;
}
.login-brand h1 {
  margin: 0;
  font-size: clamp(1.85rem, 3vw, 2.45rem);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: #fff;
}
.login-lead {
  margin: 16px 0 28px;
  color: #b7c5d4;
  line-height: 1.6;
  font-size: 1.02rem;
  max-width: 48ch;
}
.login-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.login-points li {
  display: grid;
  grid-template-columns: 148px 1fr;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.12);
  align-items: baseline;
}
.login-points b {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
}
.login-points span {
  color: #9eb0c3;
  font-size: 0.9rem;
}
.login-brand-foot {
  margin-top: 28px;
  color: #7f91a6;
  font-size: 0.8rem;
}

.login-form-pane {
  background: #f4f6f9;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
}
.login-form-box {
  width: min(400px, 100%);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 28px 24px;
  box-shadow: 0 1px 2px rgba(15, 28, 46, 0.04);
}
.login-stripe {
  height: 4px;
  margin: 0 -28px 22px;
  background: linear-gradient(90deg, var(--teal) 0 25%, var(--gold) 25% 50%, var(--coral) 50% 75%, var(--sky) 75% 100%);
}
.login-form-box h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
}
.login-sub {
  margin: 6px 0 18px;
  color: var(--muted);
  font-size: 0.92rem;
}
.login-form-box form { display: grid; gap: 12px; }
.login-form-box label {
  display: grid;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}
.login-form-box input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  font: inherit;
  font-weight: 500;
  color: var(--text);
  background: #fff;
}
.login-form-box input:focus {
  outline: 2px solid rgba(26, 79, 122, 0.22);
  border-color: var(--accent);
}
.pass-row { display: flex; gap: 8px; }
.pass-row input { flex: 1; }
.show-pass {
  border: 1px solid var(--line);
  background: #f7f9fb;
  border-radius: var(--radius-sm);
  padding: 0 12px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}
.login-submit {
  margin-top: 4px;
  width: 100%;
  padding: 12px 14px !important;
}
.login-error {
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--err-bg);
  color: var(--err);
  border: 1px solid #e0b8b8;
  font-size: 0.9rem;
}
.login-secure {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.45;
}
.login-forgot-wrap {
  margin: 12px 0 0;
  text-align: center;
}
.linkish {
  background: none;
  border: none;
  color: var(--accent, #0b6e4f);
  cursor: pointer;
  font: inherit;
  text-decoration: underline;
  padding: 0;
}
.forgot-box {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: var(--radius-sm, 8px);
  display: grid;
  gap: 8px;
}
.forgot-box label {
  display: grid;
  gap: 4px;
  font-size: 0.9rem;
}

/* ========== APP ========== */
.shell {
  display: grid;
  grid-template-columns: var(--sidebar) 1fr;
  min-height: 100vh;
}
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 18px 12px;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.brand-block {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 4px 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.8rem;
  background: var(--sky);
  color: #fff;
  flex-shrink: 0;
}
.brand-name {
  font-size: 1.08rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.1;
}
.brand-tag {
  color: var(--sidebar-muted);
  font-size: 0.72rem;
  margin-top: 3px;
}
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-item {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--sidebar-muted);
  text-align: left;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
}
.nav-item:hover { background: rgba(255,255,255,0.05); color: #eef3f8; }
.nav-item.active {
  background: rgba(61, 111, 156, 0.35);
  color: #fff;
}
.sidebar-foot {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.session-card {
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(0,0,0,0.18);
}
.session-label { font-size: 0.84rem; color: #fff; font-weight: 600; margin-bottom: 4px; }
.live-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.78rem;
  color: #8fbf9f;
  margin-bottom: 8px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: #5ea87a; }
.btn-logout {
  width: 100%;
  appearance: none;
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--sidebar-muted);
  font: inherit;
  font-weight: 600;
  font-size: 0.82rem;
  padding: 8px 10px;
  cursor: pointer;
}
.btn-logout:hover { color: #f0c4c4; border-color: rgba(200,100,100,0.45); }
.guide-teaser {
  appearance: none;
  width: 100%;
  text-align: left;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--sidebar-text);
  padding: 11px;
  cursor: pointer;
  font: inherit;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.guide-teaser strong { font-size: 0.84rem; color: #fff; }
.guide-teaser span { color: var(--sidebar-muted); font-size: 0.74rem; line-height: 1.35; }
.guide-teaser:hover { border-color: var(--sky); }

.main {
  padding: 22px 28px 36px;
  width: 100%;
  min-width: 0;
}
.main-inner {
  width: 100%;
  max-width: none;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.topbar h1 {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 700;
}
.top-sub { margin: 4px 0 0; color: var(--muted); font-size: 0.9rem; }
.tenant-pick label {
  display: block;
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: 4px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.tenant-pick select { min-width: 220px; }
.view { display: none; }
.view.active { display: block; }

.hero-strip {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 12px;
}
.hero-strip > div:first-child {
  padding: 20px 22px;
  border-right: 1px solid var(--line-soft);
}
.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.hero-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
}
.hero-copy {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
  font-size: 0.92rem;
  max-width: 60ch;
}
.hero-meta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding: 18px 20px;
  background: #f3f6f9;
  font-size: 0.88rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}
.stat {
  padding: 14px;
  border-radius: var(--radius);
  background: var(--panel);
  border: 1px solid var(--line);
}
.stat .label {
  color: var(--muted);
  font-size: 0.7rem;
  margin-bottom: 6px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.stat .value {
  font-size: 1.4rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 12px;
}
.panel h3 {
  margin: 0 0 12px;
  font-size: 0.95rem;
  font-weight: 700;
}
.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.panel-head h3 { margin: 0; }

.split {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 12px;
  align-items: start;
}

.overview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: start;
}
.hint.tight { margin: 4px 0 10px; }

.settings-page { display: grid; gap: 12px; }
.settings-shell { padding-top: 12px; }
.settings-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-soft);
}
.settings-tab {
  border: 1px solid var(--line);
  background: #f3f6f9;
  color: var(--text);
  border-radius: 999px;
  padding: 7px 14px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
}
.settings-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.settings-pane { display: none; }
.settings-pane.active { display: block; }
.settings-title {
  margin: 0 0 8px;
  font-size: 1rem;
  font-weight: 700;
}
.settings-form { max-width: 640px; }
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.logs-layout { display: grid; gap: 12px; }
.logs-actions { margin: 4px 0 8px; }
.compact-table { max-height: 280px; overflow: auto; }
.panel-head .pagination {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.kv-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px 12px;
}
.kv {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: #f3f6f9;
  border: 1px solid var(--line-soft);
}
.kv .k {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  margin-bottom: 3px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.kv .v { font-weight: 600; word-break: break-all; font-size: 0.9rem; }

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: end;
  margin-bottom: 12px;
}
.filters { margin-top: -2px; }
label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
}
input, select, textarea, button, .btn { font: inherit; }
input, select, textarea {
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  padding: 9px 11px;
  min-width: 0;
  font-weight: 500;
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid rgba(26, 79, 122, 0.2);
  border-color: var(--accent);
}
.btn, button.btn {
  appearance: none;
  border: 1px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 9px 14px;
  background: var(--accent);
  color: #fff;
  font-weight: 650;
  cursor: pointer;
}
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.ghost {
  background: #fff;
  color: var(--text);
  border-color: var(--line);
}
.btn.ghost:hover { background: #f3f6f9; }
.btn:disabled { opacity: 0.5; cursor: default; }
.form-stack { display: grid; gap: 10px; }
.form-block {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin: 0;
  display: grid;
  gap: 10px;
}
.form-block legend {
  padding: 0 6px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
}
.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.adv-box {
  border: 1px dashed var(--line);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
}
.adv-box summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--muted);
}
.adv-box[open] summary { margin-bottom: 8px; }
.adv-box label { display: grid; gap: 4px; margin-top: 8px; }
.create-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}
.create-tab {
  appearance: none;
  flex: 1;
  border: 1px solid var(--line);
  background: #f4f7fa;
  border-radius: 6px;
  padding: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  font-family: inherit;
  color: var(--muted);
}
.create-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.create-pane { display: none; }
.create-pane.active { display: block; }
.check-inline {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 8px;
}
.check-inline input { width: auto; }
.tenants-layout { align-items: start; }
.muted { color: var(--muted); font-size: 0.75rem; }
@media (max-width: 900px) {
  .form-row-2 { grid-template-columns: 1fr; }
}
.hint { color: var(--muted); font-size: 0.86rem; line-height: 1.45; margin: 0 0 12px; font-weight: 400; }
.mt { margin-top: 18px !important; }

.table-wrap { overflow: auto; }
.table-wrap.tall {
  max-height: 52vh;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
}
table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
th, td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  white-space: nowrap;
}
th {
  color: var(--muted);
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  position: sticky;
  top: 0;
  background: #f3f6f9;
}
.placeholder {
  color: var(--muted);
  text-align: center !important;
  padding: 28px !important;
}

.banner {
  margin: 8px 0 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--ok-bg);
  color: var(--ok);
  font-size: 0.9rem;
  border: 1px solid #c5d9cc;
}
.banner.warn { background: var(--warn-bg); color: var(--warn); border-color: #e2d6a8; }
.banner.error { background: var(--err-bg); color: var(--err); border-color: #e0bcbc; }
.banner.ok { background: var(--ok-bg); color: var(--ok); border-color: #c5d9cc; }
.hidden, .is-hidden { display: none !important; }
.pagination { display: flex; gap: 10px; align-items: center; margin-top: 12px; }
.key-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.key-row code {
  flex: 1;
  min-width: 180px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: #f3f6f9;
  border: 1px solid var(--line);
  font-size: 0.84rem;
  word-break: break-all;
  font-family: var(--mono);
}
.code-block {
  margin: 0;
  padding: 12px;
  border-radius: var(--radius-sm);
  background: var(--sidebar-bg);
  color: #d5dde6;
  font-size: 0.8rem;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow: auto;
  font-family: var(--mono);
}
.vendor-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 10px;
  padding: 8px;
  background: #f3f6f9;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
}
.vendor-tab {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  font-size: 0.76rem;
  font-weight: 650;
  cursor: pointer;
  font-family: inherit;
  outline: none;
  box-shadow: none;
  white-space: nowrap;
}
.vendor-tab:hover { background: #e8eef4; color: var(--text); }
.vendor-tab:focus-visible {
  outline: 2px solid rgba(26, 79, 122, 0.35);
  outline-offset: 1px;
}
.vendor-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}
.badge.active { background: var(--ok-bg); color: var(--ok); }
.badge.suspended { background: var(--warn-bg); color: var(--warn); }
.badge.terminated { background: var(--err-bg); color: var(--err); }
.warn-row td { background: var(--warn-bg); }
.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.panel-head h3 { margin: 0; }

/* GUIDE */
.guide-shell {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.guide-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 10px;
  background: #f3f6f9;
  border-bottom: 1px solid var(--line-soft);
}
.guide-tab {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 650;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.guide-tab:hover { background: #e8eef4; color: var(--text); }
.guide-tab.active {
  background: var(--accent);
  color: #fff;
}
.guide-panels { padding: 22px 24px 26px; max-width: 820px; }
.guide-panel { display: none; }
.guide-panel.active { display: block; }
.guide-panel h3 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  font-weight: 700;
}
.guide-panel .lead {
  margin: 0 0 16px;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.98rem;
}
.example-box {
  background: #eef7f5;
  border: 1px solid #c9e0da;
  border-left: 4px solid var(--teal);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 0 0 14px;
}
.example-box.warn {
  background: var(--warn-bg);
  border-color: #e2d6a8;
  border-left-color: var(--gold);
}
.example-box strong {
  display: block;
  margin-bottom: 6px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.example-box p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.92rem;
}
.example-box code, .guide-panel code {
  font-family: var(--mono);
  background: rgba(15, 28, 46, 0.06);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 0.88em;
}
.step-list { display: grid; gap: 10px; margin-bottom: 16px; }
.step {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 12px;
  align-items: start;
}
.step > span {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #e4eef6;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
}
.step b { display: block; margin-bottom: 2px; }
.step p { margin: 0; color: var(--muted); font-size: 0.9rem; }
.pill-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 8px;
}
.pill-row > div {
  background: #f3f6f9;
  border-radius: var(--radius-sm);
  padding: 12px;
  border: 1px solid var(--line-soft);
}
.pill-row b { display: block; margin-bottom: 4px; }
.pill-row code { display: block; margin-bottom: 4px; font-weight: 600; }
.pill-row small { color: var(--muted); font-size: 0.78rem; }
.easy-ol {
  margin: 0 0 16px;
  padding-left: 1.2rem;
  color: var(--muted);
  line-height: 1.55;
}
.easy-ol li { margin-bottom: 8px; }
.easy-ol b { color: var(--text); }
.check-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}
.check-grid.vendors-grid {
  grid-template-columns: repeat(3, 1fr);
}
.check-grid > div {
  background: #f3f6f9;
  border-radius: var(--radius-sm);
  padding: 12px;
  border: 1px solid var(--line-soft);
}
.check-grid b { display: block; margin-bottom: 4px; }
.check-grid p { margin: 0; color: var(--muted); font-size: 0.88rem; }

/* ========== MODAL ========== */
.tre-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 20px;
}
.tre-modal.hidden { display: none; }
.tre-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 32, 0.48);
}
.tre-modal-card {
  position: relative;
  width: min(440px, 100%);
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--line-soft, #e5e7eb);
  box-shadow: 0 18px 50px rgba(15, 23, 32, 0.22);
  overflow: hidden;
}
.tre-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-soft, #e5e7eb);
  background: #f7f9fb;
}
.tre-modal-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 650;
}
.tre-modal-x {
  border: none;
  background: transparent;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: var(--muted, #6b7280);
  padding: 0 4px;
}
.tre-modal-body {
  padding: 16px;
  color: var(--text);
  line-height: 1.5;
}
.tre-modal-body .cred-box {
  margin-top: 10px;
  padding: 12px;
  background: #f3f6f9;
  border: 1px solid var(--line-soft, #e5e7eb);
  border-radius: 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92rem;
  word-break: break-all;
}
.tre-modal-body .cred-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0;
}
.tre-modal-body .muted { color: var(--muted, #6b7280); font-size: 0.9rem; }
.tre-modal-body .warn-note {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #fff7e8;
  border: 1px solid #f0d7a3;
  color: #7a5a12;
  font-size: 0.88rem;
}
.tre-modal-body .ok-note {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #eaf7ef;
  border: 1px solid #b7e0c4;
  color: #1a7f4b;
  font-size: 0.88rem;
}
.tre-modal-body .err-note {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: var(--err-bg, #fdecec);
  border: 1px solid #e0b8b8;
  color: var(--err, #a33);
  font-size: 0.88rem;
}
.tre-modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line-soft, #e5e7eb);
}

@media (max-width: 980px) {
  .login-split { grid-template-columns: 1fr; }
  .login-brand { min-height: auto; padding: 32px 24px; }
  .login-points li { grid-template-columns: 1fr; gap: 4px; }
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: relative; height: auto; }
  .nav { flex-direction: row; flex-wrap: wrap; }
  .stat-grid, .hero-strip, .split, .kv-grid, .pill-row, .check-grid, .overview-grid, .check-grid.vendors-grid { grid-template-columns: 1fr; }
  .hero-strip > div:first-child { border-right: 0; border-bottom: 1px solid var(--line-soft); }
  .main { padding: 16px 14px 28px; }
  .topbar { flex-direction: column; align-items: stretch; }
}
