@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&family=Manrope:wght@400;500;600;700&display=swap");

:root {
  --canvas: #f4f5f7;
  --surface: #ffffff;
  --surface-raised: #f0f1f3;
  --surface-inset: #ffffff;
  --surface-hover: rgba(17, 24, 39, .05);
  --surface-active: rgba(37, 99, 235, .09);
  --fg: #17181a;
  --fg-muted: #555a62;
  --fg-subtle: #7a8089;
  --border: #dfe1e5;
  --border-strong: #bec2c8;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-fg: #1d4ed8;
  --accent-dim: rgba(37, 99, 235, .10);
  --success: #16a34a;
  --success-fg: #15803d;
  --success-dim: rgba(22, 163, 74, .10);
  --danger: #dc2626;
  --danger-fg: #b91c1c;
  --danger-dim: rgba(220, 38, 38, .09);
  --warning: #d97706;
  --warning-fg: #a16207;
  --warning-dim: rgba(217, 119, 6, .10);
  --violet: #7c3aed;
  --radius: 6px;
  --radius-lg: 8px;
  --radius-pill: 999px;
  --sidebar-w: 240px;
  --header-h: 48px;
  --content-max: 1120px;
  --font: "Manrope", ui-sans-serif, system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: 120ms ease;

  /* compatibility aliases */
  --bg: var(--canvas);
  --bg-elevated: var(--canvas);
  --bg-sidebar: var(--surface-inset);
  --bg-card: var(--surface);
  --bg-card-2: var(--surface-raised);
  --bg-hover: var(--surface-hover);
  --bg-input: var(--canvas);
  --bg-header: var(--surface-inset);
  --bg-active: var(--surface-active);
  --bg-sunken: var(--surface-inset);
  --text: var(--fg);
  --text-secondary: var(--fg-muted);
  --text-dim: var(--fg-muted);
  --text-mute: var(--fg-subtle);
  --sep: var(--border);
  --sep-strong: var(--border-strong);
  --blue: var(--accent);
  --blue-hover: var(--accent-hover);
  --blue-soft: var(--accent-dim);
  --blue-text: var(--accent-fg);
  --green: var(--success);
  --green-hover: #3fb950;
  --green-soft: var(--success-dim);
  --green-text: var(--success-fg);
  --red: var(--danger);
  --red-hover: #f85149;
  --red-soft: var(--danger-dim);
  --red-text: var(--danger-fg);
  --warn: var(--warning);
  --warn-soft: var(--warning-dim);
  --warn-text: var(--warning-fg);
  --control-h: 32px;
  --control-h-sm: 28px;
  color-scheme: light;
}

html[data-theme="dark"] {
  --canvas: #0f1115;
  --surface: #171a21;
  --surface-raised: #1e232c;
  --surface-inset: #14171d;
  --surface-hover: rgba(255, 255, 255, .05);
  --surface-active: rgba(96, 165, 250, .14);
  --fg: #e8eaed;
  --fg-muted: #9aa3af;
  --fg-subtle: #6b7280;
  --border: #2a303a;
  --border-strong: #3d4654;
  --accent: #3b82f6;
  --accent-hover: #2563eb;
  --accent-fg: #60a5fa;
  --accent-dim: rgba(59, 130, 246, .16);
  --success: #22c55e;
  --success-fg: #4ade80;
  --success-dim: rgba(34, 197, 94, .14);
  --danger: #ef4444;
  --danger-fg: #f87171;
  --danger-dim: rgba(239, 68, 68, .14);
  --warning: #f59e0b;
  --warning-fg: #fbbf24;
  --warning-dim: rgba(245, 158, 11, .14);
  --violet: #a78bfa;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
html { background: var(--canvas); }
body {
  background: var(--canvas);
  color: var(--fg);
  font: 500 14px/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--accent-fg); text-decoration: none; }
a:hover { color: var(--accent-hover); }
button, input, textarea, select { color: inherit; font: inherit; }
button { cursor: pointer; }
svg { display: block; }
code, .mono {
  color: var(--fg-muted);
  font: 12px/1.5 var(--mono);
}
.i-star, .i-ton {
  display: inline-block;
  width: 1.05em;
  height: 1.05em;
  margin: 0 .04em;
  object-fit: contain;
  vertical-align: -.18em;
  border-radius: 50%;
}
.money { white-space: nowrap; }
.money-ton { font-variant-numeric: tabular-nums; }
.money-stars {
  color: var(--fg-muted);
  font-size: .86em;
  font-weight: 500;
  white-space: nowrap;
}
.money-stars .i-star { width: .95em; height: .95em; vertical-align: -.15em; }

/* shell */
.app { display: flex; min-height: 100vh; }
.sidebar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex: 0 0 var(--sidebar-w);
  flex-direction: column;
  width: var(--sidebar-w);
  height: 100vh;
  background: var(--surface-inset);
  border-right: 1px solid var(--border);
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 10px 14px;
  color: var(--fg);
  border-bottom: 1px solid var(--border);
}
.sidebar-brand:hover { color: var(--fg); }
.brand-mark {
  display: grid;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  color: var(--fg);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  place-items: center;
}
.brand-mark svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}
.brand-text {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.2;
}
.brand-text span {
  display: block;
  margin-top: 2px;
  color: var(--fg-subtle);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.nav {
  flex: 1;
  min-height: 0;
  padding: 10px 8px 18px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--surface-raised) transparent;
}
.nav-group {
  margin: 16px 9px 6px;
  color: var(--fg-subtle);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.nav-group:first-child { margin-top: 4px; }
.nav-group-worker {
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  margin: 1px 0;
  padding: 7px 9px;
  color: var(--fg-muted);
  border-radius: var(--radius);
  transition: color var(--ease), background var(--ease);
}
.nav a:hover { color: var(--fg); background: var(--surface-hover); }
.nav a.active { color: var(--fg); background: var(--surface-active); }
.nav a.active::before {
  position: absolute;
  top: 7px;
  bottom: 7px;
  left: -8px;
  width: 2px;
  background: var(--accent-fg);
  border-radius: 0 2px 2px 0;
  content: "";
}
.nav-icon { display: grid; flex: 0 0 16px; width: 16px; place-items: center; }
.nav-icon svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}
.nav-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  font-size: 14px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  background: var(--danger);
  border-radius: var(--radius-pill);
}
.sidebar-foot { padding: 10px; border-top: 1px solid var(--border); display: grid; gap: 8px; }
.news-channel-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 8px 12px;
  color: var(--fg);
  text-decoration: none;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: background var(--ease), border-color var(--ease);
}
.news-channel-btn:hover { color: var(--fg); background: var(--surface-hover); border-color: var(--border-strong); }
.news-channel-ico {
  display: grid;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  overflow: hidden;
  border-radius: 8px;
  place-items: center;
}
.news-channel-ico img {
  display: block;
  width: 28px;
  height: 28px;
  object-fit: cover;
}
.news-channel-ico svg { width: 16px; height: 16px; }
.news-channel-text {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
}
.theme-toggle {
  width: 34px;
  min-width: 34px;
  padding: 0;
  justify-content: center;
}
.theme-toggle .theme-ico { display: none; width: 16px; height: 16px; }
.theme-toggle .theme-ico svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}
html[data-theme="light"] .theme-toggle .theme-ico-moon { display: block; }
html[data-theme="dark"] .theme-toggle .theme-ico-sun { display: block; }
.workspace { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 15;
  display: flex;
  flex: 0 0 var(--header-h);
  align-items: center;
  gap: 16px;
  min-height: var(--header-h);
  padding: 0 20px;
  background: var(--surface-inset);
  border-bottom: 1px solid var(--border);
}
.topbar-left { min-width: 120px; }
.topbar-crumb {
  color: var(--fg-subtle);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.topbar-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.topbar-logout { display: none; margin: 0; }
.profile-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 210px;
  padding: 3px 9px 3px 3px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.profile-avatar {
  display: grid;
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  color: var(--fg-muted);
  font-size: 10px;
  font-weight: 700;
  background: var(--surface-raised);
  border-radius: 4px;
  place-items: center;
}
.profile-meta { min-width: 0; line-height: 1.25; }
.profile-meta .name { overflow: hidden; font-size: 12px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.profile-meta .role { color: var(--fg-subtle); font-size: 10px; font-weight: 700; text-transform: uppercase; }
.main { display: flex; flex: 1; justify-content: center; padding: 24px 28px 48px; }
.main-inner { width: 100%; max-width: var(--content-max); }

/* headers and layout */
.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.page-head-text { flex: 1; min-width: 0; }
.page-title { margin: 0; font-size: 22px; font-weight: 700; letter-spacing: -.025em; line-height: 1.25; }
.page-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  max-width: 68ch;
  margin: 6px 0 0;
  color: var(--fg-muted);
  font-size: 13px;
  font-weight: 600;
}
.page-actions, .actions, .toolbar, .filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.toolbar { justify-content: space-between; }
.filter-bar { align-items: flex-end; margin-bottom: 12px; }
.filter-bar .view-tabs { flex: 1 0 100%; margin-bottom: 2px; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; }
.crumb, .eyebrow {
  display: inline-flex;
  margin-bottom: 6px;
  color: var(--fg-subtle);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin-bottom: 12px; }
.grid.cols-1, .grid-cols-1 { grid-template-columns: 1fr; }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }
.cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)) !important; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.row.between { justify-content: space-between; }
.row.end { justify-content: flex-end; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.grow { flex: 1; min-width: 0; }
.section-gap, .mt-4 { margin-top: 16px; }
.mt-3 { margin-top: 12px; }
.mb-3 { margin-bottom: 12px; }
.muted, .user-meta { color: var(--fg-muted); font-size: 13px; font-weight: 600; }
.title { color: var(--fg); font-size: 13px; font-weight: 600; }
.sub { margin-top: 2px; color: var(--fg-muted); font-size: 13px; }

/* controls */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: var(--control-h);
  padding: 0 12px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  background: var(--accent);
  border: 1px solid rgba(240, 246, 252, .1);
  border-radius: var(--radius);
  transition: background var(--ease), border-color var(--ease);
}
.btn:hover { color: #fff; background: var(--accent-hover); }
.btn:focus-visible { outline: 2px solid var(--accent-fg); outline-offset: 2px; }
.btn:disabled, .btn.is-disabled { cursor: not-allowed; opacity: .5; }
.btn.secondary { color: var(--fg); background: var(--surface-raised); border-color: var(--border); }
.btn.secondary:hover { color: var(--fg); background: var(--surface-raised); border-color: var(--border-strong); }
.btn.ghost { color: var(--fg-muted); background: transparent; border-color: transparent; }
.btn.ghost:hover { color: var(--fg); background: var(--surface-hover); }
.btn.success { background: var(--success); }
.btn.success:hover { background: #3fb950; }
.btn.danger { background: var(--danger); }
.btn.danger:hover { background: #f85149; }
.btn.info { background: var(--accent); }
.btn.sm { min-height: 30px; padding: 0 10px; font-size: 12px; }
.btn.block { width: 100%; }
.btn.is-loading { color: transparent !important; }
.btn.is-loading::after {
  position: absolute;
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, .3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  content: "";
}
@keyframes spin { to { transform: rotate(360deg); } }

label.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
  color: var(--fg-muted);
  font-size: 13px;
  font-weight: 700;
}
.field-hint {
  font-size: 12px;
  font-weight: 500;
  color: var(--fg-subtle);
}
.field-label {
  display: block;
  margin-bottom: 5px;
  color: var(--fg-muted);
  font-size: 13px;
  font-weight: 700;
}
input[type="text"], input[type="password"], input[type="number"], input[type="search"], input[type="tel"], input[type="time"], textarea, select {
  width: 100%;
  min-height: 38px;
  padding: 7px 10px;
  color: var(--fg);
  font-size: 14px;
  font-weight: 600;
  background: var(--canvas);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
textarea { min-height: 88px; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--fg-subtle); }
input:focus, textarea:focus, select:focus {
  border-color: var(--accent-fg);
  outline: 2px solid var(--accent-dim);
  outline-offset: 0;
}
input:disabled, textarea:disabled, select:disabled { cursor: not-allowed; opacity: .55; }

/* cards */
.card, .section-card, .form-card, .metric-panel, .queue-card, .queue-item, .finance-big, .wallet-summary {
  margin-bottom: 12px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.card-title, .section-card h3 {
  margin: 0 0 10px;
  color: var(--fg);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.01em;
}
.card-hint { margin: -4px 0 12px; color: var(--fg-muted); font-size: 13px; font-weight: 600; line-height: 1.5; }
.card-hint.err-hint { color: var(--danger-fg); margin-top: 0; }

/* Gift pricing catalog */
.gift-price-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.gift-price-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 12px 12px;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(59, 130, 246, .12), transparent 55%),
    var(--surface-inset);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 280px;
}
.gift-price-card.is-owned {
  border-color: rgba(34, 197, 94, .45);
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, .12);
}
.gift-price-card.is-seen:not(.is-owned) {
  border-color: rgba(59, 130, 246, .35);
}
.gift-price-media {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 120px;
  margin-top: 4px;
}
.gift-price-icon {
  width: 108px;
  height: 108px;
  object-fit: contain;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .25));
}
.gift-price-icon-fallback {
  display: grid;
  place-items: center;
  border-radius: 28px;
  background: rgba(255, 255, 255, .04);
  color: var(--fg-muted);
  font-size: 36px;
  font-weight: 800;
}
.gift-price-title {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  min-height: 2.5em;
}
.gift-price-ribbon {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .02em;
  text-transform: lowercase;
  color: #fff;
  background: #3b82f6;
}
.gift-price-ribbon.mute { background: var(--fg-muted); }
.gift-price-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 800;
  color: #b45309;
  background: linear-gradient(180deg, #fef3c7, #fde68a);
  border: 1px solid rgba(180, 83, 9, .25);
}
.gift-price-pill .i-star { width: 16px; height: 16px; }
.gift-price-worker {
  font-size: 12px;
  font-weight: 600;
  text-align: center;
}
.gift-price-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.gift-price-stat-val {
  margin-top: 2px;
  font-size: 18px;
  font-weight: 800;
}
.gift-price-stat-val.ok { color: #16a34a; }
.gift-price-slug {
  font-size: 11px;
  word-break: break-all;
}
.card-flush, .section-card.flush { padding: 0; overflow: hidden; }
.card-head, .section-head, .metric-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface-inset);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.card-head-text, .card-head > div:first-child {
  flex: 1 1 180px;
  min-width: 0;
}
.card-head .btn, .card-head .status {
  flex: 0 0 auto;
  margin-top: 2px;
}
.card-head .card-title, .section-head h3, .metric-panel-head h3 { margin: 0 0 4px; font-size: 15px; font-weight: 700; }
.card-body, .section-body { padding: 14px; }
.hero-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.hero-banner h2 { margin: 0 0 4px; font-size: 21px; font-weight: 700; }
.hero-banner p { max-width: 58ch; margin: 0; color: var(--fg-muted); font-size: 14px; font-weight: 600; }
.hero-chip {
  flex: 0 0 150px;
  padding: 10px 12px;
  background: var(--surface-inset);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.hero-chip .k { margin-bottom: 3px; color: var(--fg-subtle); font-size: 9px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.hero-chip .v { font-size: 12px; font-weight: 600; }

/* metrics */
.kpi-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.kpi {
  min-width: 0;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 2px solid var(--kpi-accent, var(--accent-fg));
  border-radius: var(--radius-lg);
}
.kpi-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 24px; margin-bottom: 8px; }
.kpi-label, .stat .k { color: var(--fg-muted); font-size: 12px; font-weight: 700; letter-spacing: .01em; }
.kpi-ico, .stat-ico {
  display: grid;
  width: 24px;
  height: 24px;
  color: var(--kpi-accent, var(--accent-fg));
  background: var(--surface-raised);
  border-radius: 4px;
  place-items: center;
}
.kpi-ico svg, .stat-ico svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.kpi-val, .stat .v { overflow: hidden; color: var(--fg); font-size: 24px; font-weight: 600; letter-spacing: -.03em; line-height: 1.15; text-overflow: ellipsis; }
.accent-blue { --kpi-accent: var(--accent-fg); }
.accent-green { --kpi-accent: var(--success-fg); }
.accent-amber { --kpi-accent: var(--warning-fg); }
.accent-red { --kpi-accent: var(--danger-fg); }
.accent-violet { --kpi-accent: var(--violet); }
.accent-cyan { --kpi-accent: #39d353; }
.stat {
  min-width: 0;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.stat .k { margin-bottom: 6px; }
.stat .v { font-size: 19px; }
.stat-lg .v { font-size: 24px; }
.metric-board { display: grid; gap: 10px; }
.metric-panel { margin: 0; padding: 0; overflow: hidden; }
.metric-panel-head .tone {
  padding: 2px 6px;
  color: var(--accent-fg);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  background: var(--accent-dim);
  border-radius: var(--radius-pill);
}
.tone-acc .tone { color: var(--warning-fg); background: var(--warning-dim); }
.tone-money .tone { color: var(--success-fg); background: var(--success-dim); }
.tone-fail .tone { color: var(--danger-fg); background: var(--danger-dim); }
.metric-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
}
.metric-row:last-child { border-bottom: 0; }
.metric-row .label { color: var(--fg-muted); font-size: 13px; font-weight: 600; }
.metric-row .value { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }

/* tables and lists */
.table-wrap, .table-scroll {
  max-width: 100%;
  overflow: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.table-flush, .table-wrap.table-flush, .card-flush .table-wrap {
  max-height: none;
  margin: 0;
  border: 0;
  border-radius: 0;
}
.table, .panel-table, .data-table { width: 100%; border-collapse: collapse; }
.table th, .table td, .panel-table th, .panel-table td, .data-table th, .data-table td {
  padding: 10px 12px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--border);
}
.table th, .panel-table th, .data-table th {
  color: var(--fg-subtle);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
  background: var(--surface-inset);
}
.table tr:last-child td, .panel-table tr:last-child td, .data-table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td, .panel-table tbody tr:hover td, .data-table tbody tr:hover td { background: var(--surface-hover); }
.cell-main { color: var(--fg); font-size: 14px; font-weight: 700; overflow-wrap: anywhere; word-break: break-word; }
.cell-sub { margin-top: 2px; color: var(--fg-subtle); font: 500 12px/1.45 var(--mono); }
.cell-actions { text-align: right !important; white-space: nowrap; }
.num { text-align: right !important; font-variant-numeric: tabular-nums; }
.list { overflow: hidden; margin-bottom: 12px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.list--flush, .list-flush { margin: 0; border: 0; border-radius: 0; }
.list-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 9px 12px;
  color: inherit;
  border-bottom: 1px solid var(--border);
}
.list-item:last-child { border-bottom: 0; }
a.list-item:hover { color: inherit; background: rgba(177, 186, 196, .03); }

/* detail and specialized layouts */
.detail-shell { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 12px; align-items: start; }
.detail-aside { position: sticky; top: calc(var(--header-h) + 16px); }
.detail-main { min-width: 0; display: grid; gap: 0; }
.bot-overview-stack { display: grid; gap: 0; min-width: 0; }
.bot-overview-stack > .alert { margin-bottom: 12px; }
.detail-list { display: grid; gap: 0; }
.detail-list .detail-row {
  display: grid;
  grid-template-columns: minmax(100px, .7fr) 1.3fr;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}
.detail-row:last-child { border-bottom: 0; }
.detail-row .key { color: var(--fg-muted); font-size: 12px; font-weight: 600; }
.detail-row .val { min-width: 0; color: var(--fg); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.detail-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}
.detail-field:last-child { border-bottom: 0; }
.view-tabs {
  display: flex;
  gap: 2px;
  margin-bottom: 12px;
  padding: 3px;
  overflow-x: auto;
  background: var(--surface-inset);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.view-tabs a, .view-tabs button {
  min-height: 32px;
  padding: 0 10px;
  color: var(--fg-muted);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  background: transparent;
  border: 0;
  border-radius: 4px;
}
.view-tabs a:hover, .view-tabs button:hover { color: var(--fg); background: var(--surface-hover); }
.view-tabs a.active, .view-tabs button.active { color: var(--fg); background: var(--surface-raised); }
.tab-panel[hidden] { display: none !important; }
.home-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(240px, .6fr); gap: 12px; }
.home-links { display: flex; flex-direction: column; }
.home-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 2px;
  color: inherit;
  border-bottom: 1px solid var(--border);
}
.home-link:last-child { border-bottom: 0; }
.home-link:hover { color: inherit; }
.home-link .t { font-size: 14px; font-weight: 700; }
.home-link .d { margin-top: 2px; color: var(--fg-muted); font-size: 12px; font-weight: 600; }
.home-link .go { color: var(--fg-subtle); font-size: 12px; font-weight: 700; white-space: nowrap; }
.finance-layout, .wallet-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(260px, .85fr); gap: 12px; align-items: start; }
.finance-big, .wallet-summary { margin: 0; border-left: 3px solid var(--success-fg); }
.finance-big .amount, .wallet-summary .amount { margin: 7px 0; font-size: 34px; font-weight: 600; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.finance-side, .wallet-metrics { display: grid; gap: 8px; }
.wallet-metrics { margin: 0; padding: 0; }
.wallet-metrics .kpi { margin: 0; }
.wallet-metrics dt, .wallet-metrics dd { margin: 0; }
.finance-side .mini, .wallet-metrics .mini {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.finance-side .mini .k, .wallet-metrics .mini .k { color: var(--fg-muted); font-size: 11px; }
.finance-side .mini .v, .wallet-metrics .mini .v { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.queue-list { display: grid; gap: 8px; }
.setup-steps {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.setup-steps li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fg-muted);
  font-size: 13px;
}
.setup-steps li b {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--surface-raised, var(--surface));
  border: 1px solid var(--border);
  font-size: 11px;
}
.setup-steps li.on { color: var(--fg); font-weight: 600; }
.setup-steps li.on b {
  background: var(--accent, #2563eb);
  border-color: transparent;
  color: #fff;
}
.setup-card { border-left: 3px solid var(--warning-fg, #d97706); }
.setup-url {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 14px 0;
  padding: 12px;
  background: var(--surface-raised, var(--surface));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  position: relative;
  z-index: 1;
}
.setup-url code { flex: 1; min-width: 180px; word-break: break-all; }
.setup-url .btn { position: relative; z-index: 2; flex-shrink: 0; cursor: pointer; }
.stars-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 8px;
}
.setup-howto {
  margin: 0 0 16px;
  padding-left: 18px;
  color: var(--fg-muted);
  font-size: 13px;
  line-height: 1.55;
}
.setup-howto li { margin: 4px 0; }
.notif-list { display: grid; gap: 8px; }
.notif-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  border-left: 3px solid transparent;
}
.notif-item.is-unread {
  border-left-color: var(--accent, #2563eb);
  background: var(--surface-raised, var(--surface));
}
.notif-main { min-width: 0; flex: 1; }
.notif-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.notif-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}
@media (max-width: 720px) {
  .notif-item { flex-direction: column; }
}
.queue-card, .queue-item { margin: 0; border-left: 3px solid var(--warning); }
.queue-card .amount, .queue-item .amount, .payout-amount { font-size: 18px; font-weight: 600; letter-spacing: -.02em; }
.queue-card-main { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.queue-actions, .payout-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
.stepper { display: flex; gap: 0; margin: 0 0 12px; padding: 0; list-style: none; }
.step {
  position: relative;
  flex: 1;
  padding: 9px 12px 9px 30px;
  color: var(--fg-subtle);
  font-size: 10px;
  font-weight: 600;
  background: var(--surface);
  border: 1px solid var(--border);
  border-right: 0;
}
.step:first-child { padding-left: 12px; border-radius: var(--radius) 0 0 var(--radius); }
.step:last-child { border-right: 1px solid var(--border); border-radius: 0 var(--radius) var(--radius) 0; }
.step.active { color: var(--accent-fg); background: var(--accent-dim); }
.step.complete { color: var(--success-fg); }
.timeline { position: relative; padding: 14px 14px 14px 32px; }
.timeline::before { position: absolute; top: 18px; bottom: 18px; left: 18px; width: 1px; background: var(--border); content: ""; }
.timeline-item { position: relative; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 0 0 13px 10px; color: var(--fg-muted); font-size: 13px; font-weight: 600; white-space: pre-wrap; overflow-wrap: anywhere; }
.timeline-item::before { position: absolute; top: 4px; left: -17px; width: 7px; height: 7px; background: var(--surface-raised); border: 1px solid var(--border-strong); border-radius: 50%; content: ""; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item strong { color: var(--fg); flex-shrink: 0; }
.timeline-meta { display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.timeline-content { color: var(--fg-muted); line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }

/* receiver connection */
.connect-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 0 0 18px;
  padding: 0;
  overflow: hidden;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.connect-step {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 68px;
  padding: 12px 18px;
  color: var(--fg-subtle);
  border-right: 1px solid var(--border);
}
.connect-step:last-child { border-right: 0; }
.connect-step strong, .connect-step small { display: block; }
.connect-step strong { color: var(--fg-muted); font-size: 14px; font-weight: 700; }
.connect-step small { margin-top: 2px; font-size: 11px; font-weight: 600; }
.connect-index {
  display: grid;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  color: var(--fg-muted);
  font-size: 13px;
  font-weight: 800;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 50%;
  place-items: center;
}
.connect-step.active { background: var(--accent-dim); }
.connect-step.active strong { color: var(--accent-fg); }
.connect-step.active .connect-index { color: #fff; background: var(--accent); border-color: var(--accent); }
.connect-step.complete .connect-index { color: #fff; background: var(--success); border-color: var(--success); }
.profile-summary-main { display: grid; gap: 3px; margin-bottom: 10px; }
.profile-summary-main strong { font-size: 17px; font-weight: 800; }
.receiver-actions { margin-top: 14px; }
.form-grid { display: grid; gap: 12px; }
.offer-form { display: flex; align-items: flex-end; gap: 10px; }
.offer-form .field { flex: 1; margin: 0; }
body.modal-open { overflow: hidden; }
.connect-modal {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: none;
  place-items: center;
  padding: 20px;
}
.connect-modal.open { display: grid; }
.connect-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  background: rgba(17, 24, 39, .45);
  border: 0;
  cursor: default;
}
.connect-dialog {
  position: relative;
  z-index: 1;
  width: min(430px, 100%);
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 24px 70px rgba(17, 24, 39, .18);
}
.connect-close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  color: var(--fg-muted);
  font-size: 22px;
  background: var(--surface-raised);
  border: 0;
  border-radius: 50%;
  place-items: center;
}
.connect-panel[hidden] { display: none; }
.connect-panel-index {
  margin-bottom: 8px;
  color: var(--accent-fg);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.connect-panel h2 { margin: 0 36px 6px 0; font-size: 24px; font-weight: 800; letter-spacing: -.03em; }
.connect-panel > p { margin: 0 0 20px; color: var(--fg-muted); font-size: 14px; font-weight: 600; }
.connect-success { text-align: center; }
.connect-success-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  color: #fff;
  font-size: 25px;
  font-weight: 800;
  background: var(--success);
  border-radius: 50%;
  place-items: center;
}

/* status and feedback */
.status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 7px;
  color: var(--fg-muted);
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
}
.status .dot { width: 5px; height: 5px; background: var(--fg-subtle); border-radius: 50%; }
.status.ok { color: var(--success-fg); background: var(--success-dim); border-color: transparent; }
.status.ok .dot { background: var(--success-fg); }
.status.warn { color: var(--warning-fg); background: var(--warning-dim); border-color: transparent; }
.status.warn .dot { background: var(--warning-fg); }
.status.bad { color: var(--danger-fg); background: var(--danger-dim); border-color: transparent; }
.status.bad .dot { background: var(--danger-fg); }
.status.info { color: var(--accent-fg); background: var(--accent-dim); border-color: transparent; }
.status.info .dot { background: var(--accent-fg); }
.status.mute { color: var(--fg-muted); }
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  color: var(--fg-muted);
  font-size: 9px;
  font-weight: 700;
  background: var(--surface-raised);
  border-radius: var(--radius-pill);
}
.badge.ok { color: var(--success-fg); background: var(--success-dim); }
.badge.warn { color: var(--warning-fg); background: var(--warning-dim); }
.badge.bad { color: var(--danger-fg); background: var(--danger-dim); }
.badge.info { color: var(--accent-fg); background: var(--accent-dim); }
.alert {
  margin-bottom: 12px;
  padding: 9px 11px;
  color: var(--fg-muted);
  font-size: 11px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.alert.info { color: var(--accent-fg); background: var(--accent-dim); border-color: rgba(56, 139, 253, .24); }
.alert.warn { color: var(--warning-fg); background: var(--warning-dim); border-color: rgba(210, 153, 34, .24); }
.alert.bad { color: var(--danger-fg); background: var(--danger-dim); border-color: rgba(248, 81, 73, .24); }
.alert a { color: inherit; font-weight: 600; text-decoration: underline; }
.empty, .empty-state {
  padding: 42px 18px;
  text-align: center;
  color: var(--fg-muted);
}
.empty-state .ico {
  display: grid;
  width: 36px;
  height: 36px;
  margin: 0 auto 10px;
  color: var(--fg-subtle);
  background: var(--surface-raised);
  border-radius: var(--radius);
  place-items: center;
}
.empty-state .ico svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.empty-state h4 { margin: 0 0 4px; color: var(--fg); font-size: 15px; font-weight: 700; }
.empty-state p { margin: 0; font-size: 13px; font-weight: 600; }
.log-list { display: flex; flex-direction: column; }
.log-row {
  display: grid;
  grid-template-columns: minmax(120px, 160px) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}
.log-row:last-child { border-bottom: 0; }
.log-time {
  color: var(--fg);
  font-size: 13px;
  font-weight: 700;
  overflow-wrap: anywhere;
  min-width: 0;
}
.log-msg { min-width: 0; color: var(--fg-muted); font-size: 12px; overflow-wrap: anywhere; }
.log-msg b { color: var(--fg); font-weight: 600; }
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  z-index: 200;
  max-width: min(380px, calc(100vw - 24px));
  padding: 9px 13px;
  color: var(--fg);
  font-size: 11px;
  background: var(--surface-raised);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition: opacity var(--ease), transform var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { color: var(--danger-fg); border-color: rgba(248, 81, 73, .4); }

.mailing-layout { grid-template-columns: minmax(280px, 340px) minmax(0, 1fr); }
.mailing-notes {
  margin: 0;
  padding: 0 0 0 16px;
  color: var(--fg-muted);
  font-size: 12px;
  line-height: 1.45;
}
.mailing-notes li { margin: 0 0 8px; }
.mailing-notes li:last-child { margin-bottom: 0; }
.day-picks { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 4px; }
.day-picks label {
  position: relative;
  margin: 0;
  cursor: pointer;
}
.day-picks input[type="hidden"] { display: none; }
.day-picks input[type="checkbox"] {
  position: absolute;
  inset: 0;
  z-index: 1;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.day-picks span {
  display: grid;
  min-width: 38px;
  height: 32px;
  padding: 0 8px;
  color: var(--fg-muted);
  font-size: 12px;
  font-weight: 700;
  background: var(--surface-inset);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  place-items: center;
}
.day-picks input[type="checkbox"]:checked + span {
  color: var(--accent-fg);
  background: var(--accent-dim);
  border-color: transparent;
}
.day-picks input[type="checkbox"]:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.mail-progress {
  height: 6px;
  margin: 0 0 12px;
  overflow: hidden;
  background: var(--surface-inset);
  border-radius: 99px;
}
.mail-progress > i {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: inherit;
}
.mailing-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 0 4px;
}
.mail-row.is-running td { background: var(--accent-dim); }
.mail-row.is-queued td { color: var(--fg-muted); }
.mail-row.is-sent td { box-shadow: inset 3px 0 0 var(--success); }
.mail-row.is-fail td { box-shadow: inset 3px 0 0 var(--warning); }
.mail-row.is-dead td { box-shadow: inset 3px 0 0 var(--danger); }
.mailing-run .card-head { margin-bottom: 0; }

/* toggles and misc */
.switch { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.switch:last-child { border-bottom: 0; }
.switch .label { font-size: 12px; font-weight: 500; }
.share-edit { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.worker-card { padding: 12px; background: var(--surface-inset); border: 1px solid var(--border); border-radius: var(--radius); }
.divider { height: 1px; margin: 4px 0; background: var(--border); }
.th-stack { line-height: 1.25; text-transform: none; }
.is-hidden { display: none !important; }

/* login */
.login-wrap { display: grid; min-height: 100vh; padding: 20px; background: var(--canvas); place-items: center; }
.login-card {
  width: min(360px, 100%);
  padding: 24px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.login-brand { display: flex; justify-content: center; margin-bottom: 12px; }
.login-brand .brand-mark { width: 36px; height: 36px; }
.login-card h1 { margin: 0 0 4px; font-size: 18px; font-weight: 600; }
.login-sub { margin: 0 0 18px; color: var(--fg-muted); font-size: 11px; }
.login-widget { display: flex; justify-content: center; min-height: 44px; }
.login-other { margin-top: 12px; }
.err-banner {
  margin-bottom: 12px;
  padding: 9px 10px;
  color: var(--danger-fg);
  text-align: left;
  background: var(--danger-dim);
  border: 1px solid rgba(248, 81, 73, .3);
  border-radius: var(--radius);
}

@media (max-width: 960px) {
  .app { flex-direction: column; }
  .sidebar { position: relative; flex: none; width: 100%; height: auto; border-right: 0; border-bottom: 1px solid var(--border); }
  .sidebar-brand { min-height: 48px; }
  .brand-text span { display: none; }
  .nav { display: flex; gap: 3px; padding: 6px 8px; overflow-x: auto; }
  .nav-group { display: none; }
  .sidebar-foot {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-top: 0;
    border-left: 1px solid var(--border);
  }
  .sidebar-foot form { display: none; }
  .news-channel-btn { min-height: 36px; padding: 6px 10px; }
  .news-channel-text { font-size: 11px; white-space: nowrap; }
  .nav a { flex: 0 0 auto; white-space: nowrap; }
  .nav a.active::before { display: none; }
  .topbar { padding: 0 12px; }
  .topbar-left { display: none; }
  .topbar-logout { display: block; }
  .profile-meta { display: none; }
  .profile-btn { padding: 2px; border: 0; background: transparent; }
  .main { padding: 20px 14px 36px; }
  .detail-shell, .finance-layout, .wallet-layout, .home-grid { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
  .kpi-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cols-5, .cols-6 { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}
@media (max-width: 620px) {
  .page-head { align-items: stretch; flex-direction: column; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1; }
  .topbar-search { max-width: none; }
  .search-kbd { display: none; }
  .profile-btn { display: none; }
  .hero-banner { align-items: stretch; flex-direction: column; }
  .hero-chip { flex-basis: auto; }
  .cols-2, .cols-3, .cols-4, .cols-5, .cols-6, .share-edit, .people-forms { grid-template-columns: 1fr !important; }
  .log-row { grid-template-columns: 1fr auto; }
  .log-msg { grid-column: 1 / -1; grid-row: 2; }
  .table-wrap, .table-scroll { border-radius: var(--radius); }
  .connect-step { justify-content: center; gap: 7px; min-height: 56px; padding: 8px; }
  .connect-step small { display: none; }
  .connect-step strong { font-size: 12px; }
  .connect-index { flex-basis: 27px; width: 27px; height: 27px; }
  .offer-form { align-items: stretch; flex-direction: column; }
  .connect-dialog { padding: 24px 18px; }
}
@media (max-width: 420px) {
  .kpi-strip { grid-template-columns: 1fr; }
  .main { padding-right: 10px; padding-left: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
