:root {
  --v1-navy: #0b1c33;
  --v1-navy-2: #12263f;
  --v1-on: #1d4ed8;
  --v1-bg: #f4f7fb;
  --v1-ink: #0f172a;
  --v1-muted: #64748b;
  --v1-line: #e2e8f0;
  --v1-card: #ffffff;
  --v1-side: 248px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  background: var(--v1-bg);
  color: var(--v1-ink);
}
.v1-app {
  min-height: 100%;
  display: grid;
  grid-template-columns: var(--v1-side) 1fr;
}
.v1-side {
  background: var(--v1-navy);
  color: #e2e8f0;
  padding: 18px 14px 28px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.v1-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
  padding: 4px 8px;
}
.v1-brand strong { display: block; font-size: 0.92rem; font-weight: 800; }
.v1-brand small { display: block; color: #93c5fd; font-size: 0.72rem; font-weight: 600; }
.v1-mark {
  width: 36px; height: 36px; border-radius: 10px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
}
.v1-nav { display: flex; flex-direction: column; gap: 4px; }
.v1-nav-label {
  margin: 0 8px 6px;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
  font-weight: 700;
}
.v1-link {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  border: 0;
  background: transparent;
  color: #cbd5e1;
  text-decoration: none;
  text-align: left;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 9px 12px;
  border-radius: 8px;
  cursor: pointer;
}
.v1-link i { width: 18px; text-align: center; opacity: 0.85; }
.v1-link:hover { background: var(--v1-navy-2); color: #fff; }
.v1-link.is-on { background: var(--v1-on); color: #fff; }
.v1-nav-later { margin-top: auto; opacity: 0.85; }
.v1-main { min-width: 0; display: flex; flex-direction: column; }
.v1-top {
  background: var(--v1-card);
  border-bottom: 1px solid var(--v1-line);
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.v1-top h1 { margin: 0; font-size: 1.28rem; font-weight: 800; }
.v1-top p { margin: 4px 0 0; color: var(--v1-muted); font-size: 0.86rem; }
.v1-top-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ci-rep {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--v1-line);
  background: #fff;
  border-radius: 8px;
  padding: 4px 10px 4px 12px;
  color: var(--v1-ink);
  font-size: 0.82rem;
  font-weight: 700;
}
.ci-rep i { color: var(--v1-muted); }
.ci-rep select {
  border: 0;
  background: transparent;
  font: inherit;
  font-weight: 700;
  color: var(--v1-ink);
  max-width: 220px;
  cursor: pointer;
}
.v1-filters, .ci-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: end;
  margin: 12px 0 4px;
  padding: 12px 14px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}
.v1-filters label, .ci-filters label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.v1-filters select,
.v1-filters input[type="date"],
.v1-filters input[type="search"],
.ci-filters select,
.ci-filters input[type="date"] {
  min-width: 140px;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
  color: var(--v1-ink);
  background: #fff;
}
.ci-filters .ci-flt-wide { min-width: 200px; }
.ci-ms-field {
  min-width: 260px;
}
.ci-ms-box {
  position: relative;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--v1-ink);
}
.ci-ms-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-height: 38px;
  padding: 7px 10px;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  background: #fff;
  color: var(--v1-ink);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  cursor: pointer;
}
.ci-ms-trigger.is-open {
  border-color: var(--v1-on);
  box-shadow: 0 0 0 1px var(--v1-on);
}
.ci-ms-summary {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}
.ci-ms-summary .ci-ms-all { color: var(--v1-muted); font-weight: 600; }
.ci-ms-summary .ci-ms-name { overflow: hidden; text-overflow: ellipsis; }
.ci-ms-summary .ci-ms-more {
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  flex-shrink: 0;
}
.ci-ms-caret {
  color: #94a3b8;
  font-size: 0.72rem;
  display: inline-block;
  transition: transform 0.15s ease;
}
.ci-ms-trigger.is-open .ci-ms-caret { transform: rotate(180deg); }
.ci-ms-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 80;
  background: #fff;
  border: 1px solid var(--v1-line);
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
  padding: 8px 8px 6px;
}
.ci-ms-search {
  position: relative;
  margin-bottom: 4px;
}
.ci-ms-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  border-radius: 999px;
  background: #eef2f6;
  padding: 7px 32px 7px 12px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--v1-ink);
  text-transform: none;
  letter-spacing: 0;
}
.ci-ms-search input::placeholder { color: #94a3b8; }
.ci-ms-search i {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.78rem;
  pointer-events: none;
}
.ci-ms-body {
  max-height: 260px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 transparent;
}
.ci-ms-pin {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f8fbff;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  margin-bottom: 4px;
  padding: 2px 4px 4px;
}
.ci-ms-head {
  padding: 6px 6px 2px;
  color: var(--v1-on);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.ci-ms-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.ci-ms-list-pin {
  max-height: 132px;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #93c5fd transparent;
}
.ci-ms-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 6px;
  border-bottom: 1px solid #eef2f6;
  cursor: pointer;
  color: var(--v1-ink);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}
.ci-ms-opt:last-child { border-bottom: 0; }
.ci-ms-check {
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  border: 1.5px solid #94a3b8;
  border-radius: 3px;
  background: #fff;
  position: relative;
}
.ci-ms-opt.is-on { color: var(--v1-on); }
.ci-ms-opt.is-on .ci-ms-check {
  border-color: var(--v1-on);
  background: var(--v1-on);
}
.ci-ms-opt.is-on .ci-ms-check::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.ci-ms-name { flex: 1; min-width: 0; }
.ci-ms-tick { color: var(--v1-on); font-size: 0.78rem; visibility: hidden; }
.ci-ms-opt.is-on .ci-ms-tick { visibility: visible; }
.ci-ms-empty {
  padding: 12px 8px;
  color: var(--v1-muted);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}
.ci-filters .ci-flt-hint {
  display: block;
  margin-top: 4px;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--v1-muted);
  text-transform: none;
  letter-spacing: 0;
}
.v1-filters input[type="search"] { min-width: 220px; }
.v1-filters #rbInsightsSeg { min-width: 280px; }
.rb-filter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
}
.v1-btn {
  border: 1px solid var(--v1-line);
  background: #fff;
  border-radius: 8px;
  padding: 8px 12px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--v1-ink);
}
.v1-btn-primary { background: var(--v1-on); color: #fff; border-color: var(--v1-on); }
.v1-btn-ghost { background: #fff; }
a.v1-btn { text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.v1-body { padding: 20px 24px 40px; }
.v1-subtabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--v1-line);
}
.v1-subtab {
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--v1-muted);
  padding: 10px 16px;
  text-decoration: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.v1-subtab.is-on { color: var(--v1-on); border-bottom-color: var(--v1-on); }
.v1-placeholder {
  background: var(--v1-card);
  border: 1px solid var(--v1-line);
  border-radius: 14px;
  padding: 22px 24px 28px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.v1-placeholder h2 { margin: 12px 0 8px; font-size: 1.05rem; }
.v1-placeholder p, .v1-next { color: var(--v1-muted); font-size: 0.9rem; line-height: 1.5; }
.v1-next { padding-left: 18px; }
.v1-fusion-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 700;
}
.v1-fusion-chip code { font-size: 0.78rem; }
.v1-ghost-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-top: 22px;
}
.v1-ghost-card {
  height: 92px;
  border-radius: 12px;
  background: linear-gradient(90deg, #f1f5f9, #e2e8f0, #f1f5f9);
  background-size: 200% 100%;
}
.v1-toast {
  position: fixed;
  right: 20px;
  bottom: 24px;
  z-index: 4000;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 280px;
  max-width: 400px;
  padding: 14px 16px;
  border-radius: 12px;
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.4;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.28);
  pointer-events: none;
  transform: translateX(120%);
  opacity: 0;
}
.v1-toast[hidden] { display: none !important; }
.v1-toast.is-in {
  animation: v1ToastIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.v1-toast.is-out {
  animation: v1ToastOut 0.28s ease-in forwards;
}
@keyframes v1ToastIn {
  0% { transform: translateX(120%) scale(0.92); opacity: 0; }
  70% { transform: translateX(-8px) scale(1.03); opacity: 1; }
  100% { transform: translateX(0) scale(1); opacity: 1; }
}
@keyframes v1ToastOut {
  to { transform: translateX(120%); opacity: 0; }
}
.v1-toast > i { font-size: 1.15rem; margin-top: 2px; flex-shrink: 0; }
.v1-toast-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.v1-toast-body strong { font-size: 0.78rem; letter-spacing: 0.04em; text-transform: uppercase; }
.v1-toast.is-indev {
  background: #f59e0b;
  color: #431407;
  border: 2px solid #d97706;
  border-left: 8px solid #b45309;
}
.v1-toast.is-indev > i { color: #9a3412; }
.v1-toast.is-ok {
  background: #166534;
  color: #ecfdf5;
  border-left: 8px solid #22c55e;
}
.v1-toast.is-err {
  background: #991b1b;
  color: #fef2f2;
  border-left: 8px solid #f87171;
}
.v1-toast.is-info {
  background: #1d4ed8;
  color: #eff6ff;
  border-left: 8px solid #93c5fd;
}
.v1-stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin: 16px 0;
}
.v1-stat {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  padding: 14px 16px;
  background: #f8fafc;
}
.v1-stat h3 { margin: 0 0 6px; font-size: 0.9rem; }
.v1-stat code { font-size: 0.72rem; color: #1d4ed8; }
.v1-stat-rows { margin: 10px 0 4px; font-size: 1.05rem; }
.v1-stat-when { margin: 0; color: var(--v1-muted); font-size: 0.78rem; }
.v1-sync-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.v1-note { font-size: 0.8rem; color: var(--v1-muted); }
.v1-err { color: #b91c1c; font-weight: 700; }
.v1-health {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid var(--v1-line);
  background: #fff;
}
.v1-health.is-ok { border-color: #86efac; background: #f0fdf4; }
.v1-health.is-bad { border-color: #fca5a5; background: #fef2f2; }
.v1-health strong { display: block; margin-bottom: 6px; }
.v1-health-line { margin: 0 0 6px; font-size: 0.82rem; color: var(--v1-ink); }
.v1-health .v1-note { margin-bottom: 0; }
.pf-defaults {
  margin: 20px 0 24px;
  padding: 14px 16px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
}
.pf-defaults h2 { margin: 0 0 8px; font-size: 1.05rem; }
.pf-defaults-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px 16px;
  margin: 12px 0;
}
.pf-defaults-bar label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.pf-defaults-bar select {
  min-width: 180px;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: none;
  color: var(--v1-ink);
}
.pf-gp {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--v1-muted);
  padding-bottom: 8px;
}
.pf-tree {
  max-height: 380px;
  overflow: auto;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 6px 8px;
  scrollbar-width: thin;
}
.pf-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 4px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 0.82rem;
  font-weight: 600;
}
.pf-row.lv-2 { padding-left: 18px; }
.pf-row.lv-3 { padding-left: 36px; }
.pf-row.lv-4 { padding-left: 54px; }
.pf-row.is-on label { color: var(--v1-on); }
.pf-row label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  cursor: pointer;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 600;
  color: var(--v1-ink);
}
.pf-caret, .pf-caret-sp {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  border: 0;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  line-height: 22px;
  padding: 0;
  text-align: center;
}
.pf-caret-sp { cursor: default; }

.v1-sync-log {
  background: #0f172a;
  color: #93c5fd;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 0.78rem;
  min-height: 72px;
  white-space: pre-wrap;
}
.v1-btn.is-busy { opacity: 0.65; pointer-events: none; }
.v1-dev-banner {
  margin: 0 0 14px;
  padding: 12px 14px;
  background: #fef08a;
  border: 2px solid #eab308;
  border-left: 6px solid #ca8a04;
  border-radius: 8px;
  color: #713f12;
  font-size: 0.88rem;
  line-height: 1.45;
  font-weight: 600;
}
.v1-dev-banner strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.92rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #854d0e;
}
.v1-kt-jump {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 16px;
  padding: 14px 16px;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  background: linear-gradient(135deg, #eff6ff 0%, #fff 55%);
  border: 1px solid #bfdbfe;
  box-shadow: 0 8px 20px rgba(29, 78, 216, 0.06);
}
.v1-kt-jump:hover { border-color: #93c5fd; }
.v1-kt-jump-ico {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  flex-shrink: 0;
}
.v1-kt-jump-copy { min-width: 0; flex: 1; }
.v1-kt-jump-copy strong { display: block; font-size: 0.95rem; color: var(--v1-ink); }
.v1-kt-jump-copy small { display: block; margin-top: 4px; color: var(--v1-muted); font-size: 0.8rem; line-height: 1.4; }
.v1-kt-jump-go {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--v1-on);
  white-space: nowrap;
}
.v1-kt {
  margin: 28px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--v1-line);
  scroll-margin-top: 16px;
}
.v1-kt-hero {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  margin: 0 0 14px;
  padding: 18px 20px;
  border-radius: 14px;
  background: linear-gradient(135deg, #0b1c33 0%, #1d4ed8 100%);
  color: #fff;
}
.v1-kt-kicker {
  margin: 0 0 6px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #93c5fd;
}
.v1-kt-hero h3 { margin: 0 0 6px; font-size: 1.15rem; color: #fff; }
.v1-kt-hero p { margin: 0; color: #dbeafe; font-size: 0.86rem; max-width: 46rem; line-height: 1.45; }
.v1-kt-hero code { background: rgba(255,255,255,0.14); color: #fff; padding: 1px 6px; border-radius: 4px; }
.v1-kt-hero-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.v1-kt-hero-actions .v1-btn { background: #fff; color: #1e3a8a; border-color: transparent; }
.v1-kt-toolbar { margin: 0 0 8px; }
.v1-kt-tabs { margin-bottom: 0; }
.v1-kt-panel { display: none; overflow-x: auto; }
.v1-kt-panel.is-on { display: block; }
.v1-kt-panel .kt-purpose { margin-top: 4px; }
.v1-kt-legend { margin: 10px 0 0; font-size: 0.78rem; color: var(--v1-muted); }
@media (max-width: 760px) {
  .v1-kt-jump { flex-wrap: wrap; }
  .v1-kt-jump-go { width: 100%; }
}
.v1-cron .v1-dev-banner { margin-bottom: 12px; }
.v1-cron {
  margin-top: 18px;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
}
.v1-cron h3 {
  margin: 0 0 8px;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.v1-cron p { margin: 0 0 8px; font-size: 0.82rem; color: var(--v1-muted); }
.v1-cron label {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
  margin: 12px 0 4px;
}
.v1-code {
  background: #090d16;
  color: #38bdf8;
  font-family: ui-monospace, "JetBrains Mono", Menlo, monospace;
  font-size: 0.75rem;
  line-height: 1.45;
  border-radius: 8px;
  padding: 12px 14px;
  overflow-x: auto;
  margin: 0;
  white-space: pre-wrap;
  word-break: break-all;
}
@media (max-width: 900px) {
  .v1-stat-grid { grid-template-columns: 1fr; }
  .v1-land-grid { grid-template-columns: 1fr; }
  .v1-ghost-row { grid-template-columns: 1fr; }
}
.v1-title-home { cursor: pointer; }
.v1-title-home:hover { color: var(--v1-on); }
.is-off { display: none !important; }
.v1-land-lead { color: var(--v1-muted); font-size: 0.95rem; margin: 12px 0 14px; }
.v1-land-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  max-width: 820px;
}
.v1-land-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  text-align: left;
  border: 1px solid var(--v1-line);
  border-radius: 14px;
  background: #fff;
  padding: 22px 20px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
  cursor: pointer;
  font: inherit;
}
.v1-land-card:hover { border-color: #93c5fd; box-shadow: 0 8px 20px rgba(37, 99, 235, 0.1); }
.v1-land-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: #eff6ff; color: #2563eb; font-size: 1.2rem;
}
.v1-land-card strong { font-size: 1.05rem; color: var(--v1-ink); }
.v1-land-card small { color: var(--v1-muted); line-height: 1.4; }
.v1-land-toasts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.v1-report-host { display: none; }
.v1-report-host.is-on { display: block; }
.v1-report-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 8px 0 10px;
}
.v1-report-frame {
  width: 100%;
  height: calc(100vh - 220px);
  min-height: 560px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
}
.rb-page, .rb-manual { display: none; }
.rb-page.is-on, .rb-manual.is-on { display: block; }
.rb-work {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(340px, 1.2fr);
  gap: 16px;
  align-items: start;
}
.rb-prompt, .rb-presets {
  border: 1px solid var(--v1-line);
  border-radius: 14px;
  background: #fff;
  padding: 18px 18px 16px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.rb-prompt { border-left: 4px solid var(--v1-on); }
.rb-kicker {
  margin: 0 0 4px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #2563eb;
}
.rb-prompt-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.rb-prompt-title h3 { margin: 0; font-size: 1.05rem; }
.rb-presets h3, .rb-preview h3 { margin: 0 0 8px; font-size: 1.05rem; }
.rb-latency {
  font-size: 0.72rem;
  font-weight: 800;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  padding: 4px 10px;
}
.rb-sql-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.rb-sql-meta span {
  font-size: 0.78rem;
  color: var(--v1-muted);
}
.rb-sql-box {
  margin: 0;
  max-height: 280px;
  overflow: auto;
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 0.78rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}
.rb-help { margin: 0 0 12px; color: var(--v1-muted); font-size: 0.85rem; line-height: 1.4; }
.rb-prompt textarea {
  width: 100%;
  min-height: 140px;
  resize: vertical;
  border: 1px solid var(--v1-line);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.9rem;
  color: var(--v1-ink);
}
.rb-prompt textarea:focus {
  outline: 2px solid #93c5fd;
  outline-offset: 1px;
  border-color: #60a5fa;
}
.rb-prompt-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 8px; }
.rb-presets-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.rb-cat-grid { display: flex; flex-direction: column; gap: 8px; max-height: 420px; overflow: auto; }
.rb-cat {
  border: 1px solid var(--v1-line);
  border-radius: 10px;
  background: #f8fafc;
}
.rb-cat.is-open { background: #fff; border-color: #93c5fd; }
.rb-cat-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 10px 12px;
  cursor: pointer;
  font: inherit;
  text-align: left;
}
.rb-cat-title { font-size: 0.82rem; font-weight: 700; color: var(--v1-ink); }
.rb-cat-title i { margin-right: 8px; color: #2563eb; width: 16px; text-align: center; }
.rb-cat-chevron { color: var(--v1-muted); font-size: 0.72rem; }
.rb-cat.is-open .rb-cat-chevron { transform: rotate(180deg); }
.rb-cat-body { padding: 0 12px 10px; }
.rb-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.rb-pill {
  border: 1px solid var(--v1-line);
  background: #fff;
  border-radius: 999px;
  padding: 5px 10px;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 650;
  cursor: pointer;
  color: var(--v1-ink);
  text-align: left;
}
.rb-pill:hover { border-color: #93c5fd; background: #f8fafc; }
.rb-pill.is-emph {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
  font-weight: 800;
}
.rb-pill i { margin-right: 5px; color: #2563eb; }
.rb-preview {
  margin-top: 16px;
  border: 0;
  background: transparent;
  padding: 0;
}
.rb-viewer-note {
  margin: 0 0 10px;
  color: var(--v1-muted);
  font-size: 0.82rem;
  line-height: 1.4;
}
.rb-viewer-frame {
  width: 100%;
  height: calc(100vh - 240px);
  min-height: 760px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.rb-report-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  background: linear-gradient(90deg, #eff6ff 0%, #ffffff 72%);
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--v1-on);
  border-radius: 12px;
  padding: 14px 18px;
}
.rb-report-banner h3 { margin: 0 0 4px; font-size: 1.2rem; }
.rb-range { margin: 0; color: var(--v1-muted); font-size: 0.85rem; }
.rb-report-stats {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  min-width: 110px;
}
.rb-report-stats strong { font-size: 1.55rem; font-weight: 800; line-height: 1; color: var(--v1-ink); }
.rb-report-stats span {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.rb-report-stats small { color: var(--v1-muted); font-size: 0.72rem; margin-top: 4px; }
.rb-cmp-periods {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 8px 0 6px;
}
.rb-cmp-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 0.88rem;
  font-weight: 700;
}
.rb-cmp-chip small {
  font-size: 0.65rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.8;
}
.rb-cmp-old { background: #e2e8f0; color: #334155; }
.rb-cmp-new { background: #dbeafe; color: #1d4ed8; }
.rb-cmp-vs { font-size: 0.78rem; font-weight: 800; color: #64748b; letter-spacing: 0.04em; }
.rb-period-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 12px;
}
.rb-chip {
  border: 1px solid var(--v1-line);
  background: #fff;
  border-radius: 999px;
  padding: 6px 12px;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--v1-ink);
}
.rb-chip:hover { border-color: #93c5fd; background: #f8fafc; }
.rb-chip.is-on {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}
.rb-chart-tabs { margin: 4px 0 10px; }
.rb-chart-tabs .v1-subtab i { margin-right: 6px; }
.rb-preview-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.rb-count { font-size: 0.8rem; font-weight: 700; color: var(--v1-muted); }
.rb-filters { margin: 10px 0 4px; }
.rb-extras[hidden], .rb-chart-wrap[hidden], .rb-chart-card[hidden], .rb-sql-details[hidden],
.rb-grid-host[hidden], .rb-preview-empty[hidden], .rb-modal[hidden],
.rb-period-chips[hidden], .rb-chart-tabs[hidden], .rb-cmp-periods[hidden],
.rb-extra-dates[hidden], .rb-extra-cmp[hidden], .rb-extra-seg[hidden], .rb-extra-rep[hidden],
#rbApplyDatesBtn[hidden] { display: none !important; }
.rb-chart-wrap, .rb-chart-card {
  height: 260px;
  margin: 0 0 14px;
  padding: 12px 14px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.rb-grid-host {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  padding: 0 0 12px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
  overflow: hidden;
}
.rb-table-scroll { overflow: auto; max-height: 560px; }
.rb-grid { width: 100%; border-collapse: collapse; font-size: 0.78rem; }
.rb-grid th, .rb-grid td {
  border-bottom: 1px solid var(--v1-line);
  padding: 8px 10px;
  text-align: left;
  white-space: nowrap;
}
.rb-grid thead th {
  position: sticky;
  top: 0;
  background: #0b1c33;
  color: #fff;
  z-index: 1;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.rb-grid tbody tr:hover { background: #f8fafc; }
.rb-grid tfoot td { background: #f1f5f9; font-weight: 800; }
.rb-grid tr.is-total { background: #e2e8f0; font-weight: 800; }
.rb-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 10px 14px 0;
}
.rb-pager label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--v1-muted);
}
.rb-pager select {
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 6px 8px;
  font: inherit;
}
.rb-modal {
  position: fixed; inset: 0; background: rgba(15, 23, 42, 0.45);
  display: grid; place-items: center; z-index: 40;
}
.rb-modal-card {
  width: min(640px, calc(100% - 32px));
  max-height: 80vh;
  overflow: auto;
  background: #fff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
}
.rb-fields-list { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }
.rb-field-row { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; }
.rb-field-row code { min-width: 120px; }
.rb-field-row input[type="text"] { flex: 1; border: 1px solid var(--v1-line); border-radius: 6px; padding: 4px 8px; font: inherit; }
.rb-modal-actions { display: flex; justify-content: flex-end; gap: 8px; }
.rb-sql-details {
  margin: 0 0 12px;
  padding: 12px 14px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}
.rb-preview-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 180px;
  text-align: center;
  color: var(--v1-muted);
  background: #f8fafc;
  border: 1px dashed var(--v1-line);
  border-radius: 12px;
  padding: 24px 16px;
}
.rb-preview-empty i { font-size: 1.6rem; color: #94a3b8; }
.rb-preview-empty strong { color: var(--v1-ink); }
.ci-page { margin-top: 12px; }
.ci-kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 14px 0;
}
.inv-page .ci-kpis.inv-kpis-has-buy {
  grid-template-columns: repeat(6, 1fr);
}
.ci-kpi {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  padding: 14px 16px;
  background: #fff;
  min-height: 118px;
}
.ci-kpi-hit {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.ci-kpi-oos {
  border-color: #fecaca;
  background: #fef2f2;
  padding: 10px 12px;
}
.ci-kpi-oos.is-alert {
  border-color: #f87171;
  box-shadow: 0 0 0 1px #fecaca;
}
.ci-kpi-oos.is-on {
  outline: 2px solid #dc2626;
  outline-offset: 1px;
}
.ci-kpi-oos .ci-kpi-val { color: #991b1b; }
.ci-kpi-oos .ci-kpi-warn { color: #dc2626; margin-right: 4px; }
.ci-kpi-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
  margin-bottom: 6px;
}
.ci-kpi-val { display: block; font-size: 1.45rem; font-weight: 800; color: var(--v1-ink); }
.ci-kpi-val-wait { color: #94a3b8; }
.ci-kpi small { display: block; margin-top: 8px; color: var(--v1-muted); font-size: 0.72rem; }
.ci-kpi-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.ci-pill {
  font-size: 0.68rem;
  font-weight: 800;
  border-radius: 999px;
  padding: 2px 8px;
}
.ci-pill-crit { background: #fee2e2; color: #991b1b; }
.ci-pill-high { background: #ffedd5; color: #9a3412; }
.ci-pill-watch { background: #fef9c3; color: #854d0e; }
.ci-pill-opp { background: #dcfce7; color: #166534; }
.ci-kpi-indev { background: #fffbeb; border-style: dashed; }
.ci-charts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}
.ci-charts.is-one { grid-template-columns: 1fr; }
.ci-chart {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  padding: 12px 14px 16px;
  background: #fff;
}
.ci-chart header { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.ci-chart h3 { margin: 0; font-size: 0.88rem; }
.ci-chart header span { font-size: 0.72rem; color: var(--v1-muted); }
.ci-chart-body { position: relative; height: 160px; }
.ci-chart-body-opp { height: 200px; }
.inv-page .ci-chart-body { height: 200px; }
.ci-chart-explain {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--v1-line);
}
.ci-chart-explain strong {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
  margin-bottom: 4px;
}
.ci-chart-explain p { margin: 0; font-size: 0.78rem; color: #334155; line-height: 1.45; }
.ci-chart-explain em { display: block; margin-top: 4px; font-style: normal; color: var(--v1-muted); }
.ci-chart-ghost {
  height: 140px;
  border-radius: 8px;
  background: linear-gradient(180deg, #fee2e2 0%, #fff 70%);
  opacity: 0.7;
}
.ci-chart-ghost-opp { background: linear-gradient(180deg, #dcfce7 0%, #fff 70%); }
.ci-split {
  align-items: flex-start;
}
.ci-page[data-tab] .ci-split.row,
.inv-page .ci-split.row {
  --bs-gutter-x: 12px;
  --bs-gutter-y: 12px;
}
.ci-page[data-tab] #ciPanel,
.inv-page #invPanel {
  scroll-margin-top: 16px;
}
@media (min-width: 992px) {
  .ci-page[data-tab] .ci-split.row,
  .inv-page .ci-split.row {
    align-items: stretch;
  }
  .ci-page[data-tab] #ciPanel,
  .inv-page #invPanel {
    position: sticky;
    top: 12px;
    max-height: calc(100vh - 24px);
    overflow-y: auto;
  }
}
.ci-page[data-tab] .table-responsive,
.inv-page .table-responsive {
  max-width: 100%;
}
.ci-page[data-tab] #ciGridTable.table,
.inv-page #invGrid.table,
.inv-page #invMoreGrid.table,
.inv-page .inv-sec-grid.table {
  --bs-table-bg: #fff;
  --bs-table-hover-bg: #eff6ff;
  width: 100%;
  margin-bottom: 0;
  font-size: 0.78rem;
}
.ci-page[data-tab] #ciGridTable.table > :not(caption) > * > *,
.inv-page #invGrid.table > :not(caption) > * > *,
.inv-page #invMoreGrid.table > :not(caption) > * > *,
.inv-page .inv-sec-grid.table > :not(caption) > * > * {
  padding: 0.4rem 0.55rem;
  white-space: nowrap;
  width: 1%;
  vertical-align: middle;
}
.ci-page[data-tab] #ciGridTable.table th:first-child,
.ci-page[data-tab] #ciGridTable.table td:first-child,
.inv-page #invGrid.table th:first-child,
.inv-page #invGrid.table td:first-child,
.inv-page #invMoreGrid.table th:first-child,
.inv-page #invMoreGrid.table td:first-child,
.inv-page #invMoreGrid.table th:nth-child(2),
.inv-page #invMoreGrid.table td:nth-child(2),
.inv-page .inv-sec-grid.table th:first-child,
.inv-page .inv-sec-grid.table td:first-child {
  width: auto;
  min-width: 132px;
  white-space: normal;
}
.ci-page[data-tab] #ciGridTable.table .ci-empty,
.inv-page #invGrid.table .ci-empty,
.inv-page #invMoreGrid.table .ci-empty,
.inv-page .inv-sec-grid.table .ci-empty {
  width: auto;
  white-space: normal;
}
.inv-sec-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.inv-sec {
  margin-top: 12px;
}
.inv-sec-inc {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--v1-muted);
  margin: 0 8px 0 0;
  white-space: nowrap;
}
.inv-sec-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  vertical-align: middle;
}
.inv-sec-badge-more,
.inv-sec-badge-regular {
  background: #dcfce7;
  color: #166534;
}
.inv-sec-badge-less {
  background: #fef3c7;
  color: #92400e;
}
.inv-sec-badge-zero {
  background: #e2e8f0;
  color: #475569;
}
.ci-tip {
  cursor: help;
  border-bottom: 1px dotted #94a3b8;
}
.ci-tip-pop {
  position: fixed;
  z-index: 80;
  max-width: min(360px, calc(100vw - 24px));
  padding: 10px 12px;
  border-radius: 8px;
  background: #0f172a;
  color: #f8fafc;
  font-size: 0.75rem;
  line-height: 1.45;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.28);
  pointer-events: none;
  white-space: pre-wrap;
}
.inv-page #invMoreWrap {
  margin-top: 12px;
}
.ci-grid-wrap, .ci-panel {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
}
.ci-grid-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-bottom: 1px solid var(--v1-line);
}
.ci-grid-head h3 { margin: 0; font-size: 0.95rem; }
.ci-grid-meta { margin: 4px 0 0; color: var(--v1-muted); font-size: 0.72rem; }
.ci-grid-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.ci-export {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(15, 23, 42, 0.45);
}
.ci-export[hidden] { display: none; }
.ci-export-card {
  width: min(440px, 100%);
  background: #fff;
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
}
.ci-export-h {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.ci-export-h h4 { margin: 0; font-size: 0.95rem; }
.ci-export-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: end;
  margin: 12px 0 8px;
}
.ci-export-fields label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.ci-export-fields select,
.ci-export-fields input[type="number"] {
  min-width: 96px;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--v1-ink);
  background: #fff;
}
.ci-export-fields label[hidden] { display: none; }
.ci-export-fields input[type="number"] { width: 88px; }
.ci-export-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
}
.ci-table-scroll { overflow-x: auto; }
.ci-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.ci-table th {
  text-align: left;
  padding: 8px 10px;
  background: #f8fafc;
  color: var(--v1-muted);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.ci-table th[data-sort] {
  cursor: pointer;
  user-select: none;
}
.ci-table th[data-sort]::after {
  content: " \2195";
  opacity: 0.35;
  font-size: 0.65rem;
}
.ci-table th[data-sort].is-sorted.is-desc::after {
  content: " \2193";
  opacity: 1;
  color: var(--v1-ink);
}
.ci-table th[data-sort].is-sorted.is-asc::after {
  content: " \2191";
  opacity: 1;
  color: var(--v1-ink);
}
.ci-table th[data-sort].is-sorted {
  color: var(--v1-ink);
}
.ci-table td { padding: 10px; border-top: 1px solid var(--v1-line); vertical-align: middle; }
.ci-table tbody tr { cursor: default; }
.ci-table tbody tr.is-click { cursor: pointer; }
.ci-table tbody tr.is-on { background: #eff6ff; }
.inv-break {
  overflow: auto;
  max-height: min(52vh, 420px);
  margin: 0;
}
.inv-break table { font-size: 0.7rem; margin-bottom: 0; }
.inv-break th { position: sticky; top: 0; background: #f8fafc; z-index: 1; }
.inv-break td, .inv-break th { white-space: nowrap; padding: 6px 8px; }
.inv-break td:last-child, .inv-break th:last-child {
  white-space: normal;
  min-width: 120px;
}
.ci-empty { text-align: center; color: var(--v1-muted); padding: 28px 12px !important; }
.ci-money { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.ci-risk {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.ci-risk-bar {
  width: 42px;
  height: 6px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.ci-risk-bar span { display: block; height: 100%; border-radius: 999px; background: #94a3b8; }
.ci-risk-bar.is-crit span { background: #dc2626; }
.ci-risk-bar.is-high span { background: #ea580c; }
.ci-risk-bar.is-watch span { background: #ca8a04; }
.ci-panel { padding: 14px 16px 18px; }
.ci-panel-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.ci-panel-h h3 { margin: 0; font-size: 1rem; line-height: 1.25; }
.ci-panel-risk { font-size: 0.78rem; font-weight: 800; color: #94a3b8; white-space: nowrap; }
.ci-panel-risk.is-crit { color: #991b1b; }
.ci-panel-risk.is-high { color: #9a3412; }
.ci-panel-risk.is-watch { color: #854d0e; }
.ci-panel-facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
  margin: 12px 0 0;
}
.ci-panel-facts div {
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 8px 10px;
  background: #f8fafc;
}
.ci-panel-facts dt {
  margin: 0;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
}
.ci-panel-facts dd { margin: 4px 0 0; font-size: 0.82rem; font-weight: 700; color: var(--v1-ink); }
.ci-panel-block { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--v1-line); }
.ci-panel-block h4 { margin: 0 0 8px; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--v1-muted); }
.ci-panel-block p { margin: 0; font-size: 0.82rem; color: #334155; line-height: 1.45; }
.ci-panel-block .v1-btn { display: block; width: 100%; margin-bottom: 6px; text-align: left; }
@media (max-width: 1100px) {
  .ci-kpis { grid-template-columns: 1fr 1fr; }
  .inv-page .ci-kpis.inv-kpis-has-buy { grid-template-columns: 1fr 1fr; }
  .ci-charts { grid-template-columns: 1fr; }
}
body {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif !important;
  background: var(--v1-bg) !important;
}
.v1-menu-btn {
  display: none;
  border: 1px solid var(--v1-line);
  background: #fff;
  border-radius: 8px;
  width: 40px;
  height: 40px;
  place-items: center;
  cursor: pointer;
  color: var(--v1-ink);
  flex-shrink: 0;
}
.v1-side-scrim { display: none; }
.v1-report-host { min-width: 0; overflow-x: auto; }
@media (max-width: 991.98px) {
  .v1-app { grid-template-columns: 1fr; }
  .v1-side {
    position: fixed;
    z-index: 40;
    inset: 0 auto 0 0;
    width: min(280px, 88vw);
    transform: translateX(-110%);
    transition: transform 0.2s ease;
  }
  .v1-side.is-open { transform: none; }
  .v1-menu-btn { display: grid; }
  .v1-side-scrim:not([hidden]) {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 35;
  }
  .v1-body { padding: 16px 14px 32px; }
  .v1-top { padding: 12px 14px; }
  .ci-kpis, .ci-charts, .v1-land-grid, .v1-stat-grid { grid-template-columns: 1fr; }
  .rb-work { grid-template-columns: 1fr; }
}
.ci-alert {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px solid #fdba74;
  color: #9a3412;
  font-size: 0.82rem;
  font-weight: 700;
}
.ci-alert.is-red {
  background: #fef2f2;
  border-color: #fca5a5;
  color: #991b1b;
}
.ci-alert.is-green {
  background: #ecfdf5;
  border-color: #6ee7b7;
  color: #065f46;
}
.ci-alert-panel { margin: 8px 0 12px; }
.ci-flt-check .ci-check-line {
  display: flex;
  align-items: center;
  gap: 8px;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 600;
  min-height: 38px;
}
.ci-pref {
  margin: 0 0 16px;
  padding: 14px 16px;
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
}
.ci-pref-h h3 { margin: 0 0 4px; font-size: 1rem; }
.ci-pref-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 10px;
}
.ci-pref-grid h4, .ci-pref-sku h4 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
  margin: 0 0 8px;
}
.ci-pref-sku { margin-top: 14px; }
.cu-page { min-width: 0; }
.cu-split {
  display: grid;
  grid-template-columns: minmax(220px, 280px) 1fr;
  gap: 16px;
  align-items: start;
}
.cu-list {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}
.cu-list-h { padding: 10px; border-bottom: 1px solid var(--v1-line); }
.cu-list-h input {
  width: 100%;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
}
.cu-names {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 70vh;
  overflow: auto;
}
.cu-names button {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 10px 12px;
  font: inherit;
  font-weight: 650;
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
}
.cu-names button small { display: block; color: var(--v1-muted); font-weight: 600; }
.cu-names button.is-on { background: #eff6ff; color: var(--v1-on); }
.cu-detail {
  border: 1px solid var(--v1-line);
  border-radius: 12px;
  background: #fff;
  padding: 16px;
  min-height: 320px;
}
.cu-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 12px;
}
.cu-head h2 { margin: 0; font-size: 1.15rem; }
.cu-cols {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
}
.cu-cols h3 { font-size: 0.85rem; margin: 0 0 8px; }
.cu-cols label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
  margin-bottom: 10px;
}
.cu-cols select {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 650;
  text-transform: none;
  letter-spacing: 0;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid var(--v1-line);
  color: var(--v1-ink);
}
.cu-facts { list-style: none; margin: 0 0 16px; padding: 0; }
.cu-facts li { padding: 6px 0; border-bottom: 1px solid #f1f5f9; font-size: 0.82rem; font-weight: 600; }
.camp-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 20px;
}
.camp-modal[hidden] { display: none; }
.camp-modal-card {
  width: min(640px, 96vw);
  max-height: 90vh;
  overflow: auto;
  background: #fff;
  border-radius: 12px;
  padding: 16px 18px 20px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.2);
}
.camp-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 14px;
}
.camp-form label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
}
.camp-form input, .camp-form select, .camp-form textarea {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 650;
  text-transform: none;
  letter-spacing: 0;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid var(--v1-line);
  color: var(--v1-ink);
}
.camp-form label:nth-child(3),
.camp-form textarea,
.camp-form .camp-form-actions { grid-column: 1 / -1; }
.camp-form-actions { display: flex; justify-content: flex-end; }
.camp-modal-pro { width: min(760px, 96vw); padding: 0 0 18px; }
.camp-pro-h {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 20px 12px;
  border-bottom: 1px solid var(--v1-line);
}
.camp-pro-kicker {
  margin: 0;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #2563eb;
}
.camp-pro-h h4 { margin: 2px 0 0; font-size: 1.15rem; }
.camp-pro-form { padding: 0 20px; }
.camp-pro-sec { margin: 14px 0 0; }
.camp-pro-sec h5 {
  margin: 0 0 8px;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.camp-pro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 14px;
}
.camp-pro-grid label, .pf-modal-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
}
.camp-pro-grid input, .camp-pro-grid select, .camp-pro-grid textarea,
.pf-modal-grid select {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 650;
  text-transform: none;
  letter-spacing: 0;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--v1-line);
  color: var(--v1-ink);
}
.camp-pro-span { grid-column: 1 / -1; }
.camp-co-name {
  display: block;
  margin-top: 6px;
  font-size: 0.92rem;
  color: var(--v1-ink);
}
.camp-filters {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  padding: 12px 14px 14px;
  border-bottom: 1px solid var(--v1-line);
}
.camp-filters label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--v1-muted);
  margin: 0;
}
.camp-filters input, .camp-filters select {
  font: inherit;
  font-size: 0.82rem;
  font-weight: 650;
  text-transform: none;
  letter-spacing: 0;
  padding: 7px 8px;
  border-radius: 8px;
  border: 1px solid var(--v1-line);
  width: 100%;
  min-width: 0;
  background: #fff;
}
.camp-page { min-width: 0; }
.camp-hero-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 4px 0 16px;
}
.camp-stat {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  border-radius: 16px;
  padding: 16px 18px;
  min-height: 118px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  position: relative;
  overflow: hidden;
}
.camp-stat > div { min-width: 0; flex: 1 1 auto; }
.camp-stat-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.camp-stat-val {
  display: block;
  font-size: 1.55rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.camp-stat small {
  display: block;
  margin-top: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.35;
  opacity: 0.88;
}
.camp-stat-ico {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  font-size: 1rem;
}
.camp-stat-trend {
  position: absolute;
  right: 14px;
  top: 16px;
  font-size: 1rem;
  opacity: 0.85;
}
.camp-stat-rec {
  background: linear-gradient(145deg, #f0fdf4 0%, #dcfce7 48%, #bbf7d0 100%);
  color: #14532d;
}
.camp-stat-rec .camp-stat-ico { background: linear-gradient(145deg, #22c55e, #166534); color: #fff; }
.camp-stat-open {
  background: linear-gradient(145deg, #fff7ed 0%, #ffedd5 48%, #fed7aa 100%);
  color: #9a3412;
}
.camp-stat-open .camp-stat-ico { background: linear-gradient(145deg, #fb923c, #c2410c); color: #fff; }
.camp-stat-risk {
  background: linear-gradient(145deg, #fff1f2 0%, #ffe4e6 48%, #fecdd3 100%);
  color: #9f1239;
}
.camp-stat-risk .camp-stat-ico { background: linear-gradient(145deg, #fb7185, #e11d48); color: #fff; }
.camp-stat-opp {
  background: linear-gradient(145deg, #f0fdfa 0%, #ccfbf1 48%, #99f6e4 100%);
  color: #115e59;
}
.camp-stat-opp .camp-stat-ico { background: linear-gradient(145deg, #2dd4bf, #0f766e); color: #fff; }
.camp-stat-sku {
  background: linear-gradient(145deg, #eff6ff 0%, #dbeafe 48%, #bfdbfe 100%);
  color: #1e3a8a;
}
.camp-stat-sku .camp-stat-ico { background: linear-gradient(145deg, #60a5fa, #1d4ed8); color: #fff; }
.camp-stat-closed {
  background: linear-gradient(145deg, #f8fafc 0%, #f1f5f9 48%, #e2e8f0 100%);
  color: #334155;
}
.camp-stat-closed .camp-stat-ico { background: linear-gradient(145deg, #64748b, #475569); color: #fff; }
.camp-stat-chart {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid var(--v1-line);
  color: var(--v1-ink);
  flex-direction: column;
  gap: 8px;
  padding-bottom: 10px;
}
.camp-stat-chart-h .camp-stat-val { font-size: 1.2rem; }
.camp-spark { height: 52px; width: 100%; }
.camp-board { overflow: hidden; }
.camp-filters {
  display: grid;
  grid-template-columns: minmax(160px, 1.4fr) repeat(auto-fill, minmax(132px, 1fr));
  gap: 10px 12px;
  padding: 12px 16px 14px;
  border-bottom: 1px solid var(--v1-line);
  background: #f8fafc;
}
.camp-filt-search { grid-column: span 1; }
.camp-search {
  position: relative;
  display: block;
}
.camp-search i {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.78rem;
  pointer-events: none;
}
.camp-search input { padding-left: 30px; }
.camp-filt-reset {
  display: flex;
  align-items: flex-end;
}
.camp-filt-reset .v1-btn { width: 100%; }
.camp-table-wrap { padding: 0 0 8px; }
.camp-table th, .camp-table td { vertical-align: middle; }
.camp-table td:first-child { font-weight: 700; }
.camp-st {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.camp-st-closed { background: #dcfce7; color: #166534; }
.camp-st-cancelled { background: #e2e8f0; color: #475569; }
.camp-st-open { background: #dbeafe; color: #1d4ed8; }
.camp-st-draft { background: #f1f5f9; color: #64748b; }
.camp-st-in_process, .camp-st-started { background: #ffedd5; color: #c2410c; }
.camp-st-meeting, .camp-st-follow_up { background: #ccfbf1; color: #0f766e; }
.camp-st-on_hold { background: #fef3c7; color: #b45309; }
.camp-progress {
  min-width: 110px;
}
.camp-progress-bar {
  height: 8px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.camp-progress-bar > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #86efac, #22c55e);
  border-radius: 999px;
}
.camp-progress-meta {
  margin-top: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #64748b;
  white-space: nowrap;
}
.camp-row-actions {
  display: flex;
  justify-content: flex-end;
  gap: 4px;
}
.camp-icon-btn {
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  color: #64748b;
  border-radius: 8px;
  cursor: pointer;
}
.camp-icon-btn:hover { background: #eff6ff; color: var(--v1-on); }
.camp-money { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.camp-co { font-weight: 650; }
.camp-co-id { display: block; font-size: 0.7rem; font-weight: 600; color: #94a3b8; }
@media (max-width: 1199.98px) {
  .camp-hero-kpis { grid-template-columns: 1fr 1fr; }
  .camp-col-rep { display: none; }
}
@media (max-width: 767.98px) {
  .camp-hero-kpis { grid-template-columns: 1fr; }
  .camp-filters { grid-template-columns: 1fr 1fr; }
  .camp-filt-search { grid-column: 1 / -1; }
  .camp-filt-reset { grid-column: 1 / -1; }
}
.pf-modal-card { width: min(860px, 96vw); padding: 0 0 16px; }
.pf-modal-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 16px;
  padding: 14px 20px 0;
}
.pf-nest { max-height: 420px; }
.pf-nest-row { margin: 0 0 6px; }
.pf-nest-row.lv-2 { margin-left: 22px; }
.pf-nest-row.lv-3 { margin-left: 44px; }
.pf-nest-row.lv-4 { margin-left: 66px; }
.pf-nest-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 8px 10px;
  min-height: 40px;
}
.pf-nest-row.is-on .pf-nest-bar {
  background: #fff;
  border-color: #cbd5e1;
}
.pf-nest-check { margin: 0; }
.pf-nest-title {
  font-size: 0.86rem;
  font-weight: 700;
  color: #0f172a;
  flex: 1 1 auto;
}
.pf-nest-count, .pf-nest-type {
  font-size: 0.75rem;
  font-style: italic;
  font-weight: 600;
  color: #64748b;
  white-space: nowrap;
}
.pf-nest-caret {
  border: 0;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  width: 22px;
  height: 22px;
  line-height: 22px;
  padding: 0;
}
@media (max-width: 991.98px) {
  .cu-split, .cu-cols, .ci-pref-grid, .camp-form, .camp-pro-grid, .pf-modal-grid { grid-template-columns: 1fr; }
}

/* Customer Intelligence (Churn + Opportunity) — campaigns-matching chrome. Inventory KPIs stay on .ci-kpi. */
.v1-subtab i { margin-right: 6px; }
.ci-page-note {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--v1-muted);
  line-height: 1.45;
}
.ci-page .ci-filter-board {
  border: 1px solid var(--v1-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  overflow: hidden;
  margin: 0 0 16px;
}
.ci-page .ci-filters {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
  gap: 10px 12px;
  margin: 0;
  padding: 12px 16px 14px;
  border: 0;
  border-radius: 0;
  background: #f8fafc;
  box-shadow: none;
  align-items: end;
}
.ci-page .ci-filters label { margin: 0; }
.ci-page .ci-filters select,
.ci-page .ci-filters input[type="date"] {
  width: 100%;
  min-width: 0;
}
.ci-page .ci-filters .ci-flt-wide { min-width: 0; }
.ci-page .camp-stat { min-height: 138px; align-items: flex-start; }
.ci-page .camp-stat .ci-kpi-val-wait { opacity: 0.45; }
.ci-page .camp-stat .ci-kpi-meta { margin-top: 8px; }
.ci-page .camp-stat .ci-pill {
  background: rgba(255, 255, 255, 0.78);
}
.ci-page .camp-stat-opp .ci-pill-opp { color: #115e59; }
.ci-page .ci-chart {
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  padding: 14px 16px 16px;
}
.ci-page .ci-chart h3 i { margin-right: 6px; color: var(--v1-muted); }
.ci-page .ci-alert {
  border-radius: 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}
.ci-page .ci-pref {
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}
.ci-page .ci-grid-wrap {
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}
.ci-page .ci-grid-head { padding: 14px 16px; background: #fff; }
.ci-page .ci-grid-actions .v1-btn i { margin-right: 6px; }
.ci-page .ci-panel {
  padding: 0 0 16px;
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}
.ci-page .ci-panel-h {
  padding: 14px 16px;
  background: #f8fafc;
  border-bottom: 1px solid var(--v1-line);
  margin: 0;
}
.ci-page .ci-panel > .v1-note,
.ci-page .ci-panel > .ci-alert-panel,
.ci-page .ci-panel-facts,
.ci-page .ci-panel-block {
  margin-left: 16px;
  margin-right: 16px;
}
.ci-page .ci-panel > .v1-note { margin-top: 12px; }
.ci-page .ci-panel-block .v1-btn i { margin-right: 8px; width: 1em; text-align: center; }
.ci-page .camp-row-actions { justify-content: flex-start; }
@media (max-width: 767.98px) {
  .ci-page .ci-filters { grid-template-columns: 1fr 1fr; }
  .ci-page .ci-filters .ci-flt-wide { grid-column: 1 / -1; }
}

/* CI tabs — light gradient + restrained hover (Churn, Opportunity, Campaigns) */
.v1-subtabs-ci {
  gap: 6px;
  padding-bottom: 0;
}
.v1-subtabs-ci .v1-subtab {
  border-radius: 10px 10px 0 0;
  border-bottom-width: 2px;
  background: transparent;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.v1-subtabs-ci .v1-subtab:hover {
  color: var(--v1-ink);
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}
.v1-subtabs-ci .v1-subtab.is-on {
  color: var(--v1-on);
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 100%);
}
.v1-subtabs-ci .v1-subtab.is-on:hover {
  background: linear-gradient(180deg, #dbeafe 0%, #eff6ff 100%);
}

/* CI churn / opportunity — lock clicks + soft blur while the report loads */
.ci-page .ci-chart,
.ci-page .ci-grid-wrap,
.ci-page .ci-panel,
.ci-page .ci-filter-board {
  position: relative;
}
.ci-page .camp-stat.is-waiting,
.ci-page .ci-chart.is-waiting,
.ci-page .ci-grid-wrap.is-waiting,
.ci-page .ci-panel.is-waiting,
.ci-page .ci-filter-board.is-waiting {
  overflow: hidden;
}
.ci-page .camp-stat > .dash-wait,
.ci-page .ci-chart > .dash-wait,
.ci-page .ci-grid-wrap > .dash-wait,
.ci-page .ci-panel > .dash-wait,
.ci-page .ci-filter-board > .dash-wait {
  position: absolute;
  inset: 0;
  z-index: 12;
}
.ci-page .camp-stat.is-waiting > *:not(.dash-wait) {
  filter: blur(3px);
}
.ci-page .ci-chart.is-waiting > *:not(.dash-wait),
.ci-page .ci-grid-wrap.is-waiting > *:not(.dash-wait),
.ci-page .ci-panel.is-waiting > *:not(.dash-wait),
.ci-page .ci-filter-board.is-waiting > *:not(.dash-wait) {
  filter: blur(2px);
}
.ci-page .camp-stat .dash-wait-icon { font-size: 1.05rem; }
.ci-page.is-locked { cursor: progress; }
.ci-page.is-locked .ci-filters,
.ci-page.is-locked .ci-grid-actions,
.ci-page.is-locked .ci-table,
.ci-page.is-locked .ci-panel-block {
  pointer-events: none;
}
.v1-subtabs-ci.is-locked a.v1-subtab,
.v1-subtabs-ci.is-locked button.v1-subtab,
.v1-subtabs-inv.is-locked a.v1-subtab,
.v1-subtabs-inv.is-locked button.v1-subtab {
  pointer-events: none;
  opacity: 0.72;
}

.inv-page .ci-kpi,
.inv-page .inv-filter-board {
  position: relative;
}
.inv-page .ci-kpi.is-waiting,
.inv-page .inv-filter-board.is-waiting {
  overflow: hidden;
}
.inv-page .ci-kpi > .dash-wait,
.inv-page .inv-filter-board > .dash-wait {
  position: absolute;
  inset: 0;
  z-index: 12;
}
.inv-page .ci-kpi.is-waiting > *:not(.dash-wait) {
  filter: blur(3px);
}
.inv-page .inv-filter-board.is-waiting > *:not(.dash-wait) {
  filter: blur(2px);
}
.inv-page.is-locked .ci-kpis,
.inv-page.is-locked .ci-charts,
.inv-page.is-locked .ci-split,
.inv-page.is-locked .inv-sec-toolbar {
  pointer-events: none;
}

.ci-page .camp-stat,
.camp-page .camp-stat,
.dash-page .camp-stat {
  isolation: isolate;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.ci-page .camp-stat::after,
.camp-page .camp-stat::after,
.dash-page .camp-stat::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.08) 42%, transparent 70%);
  pointer-events: none;
  opacity: 0.65;
  transition: opacity 0.22s ease;
  z-index: 0;
}
.ci-page .camp-stat > *:not(.camp-stat-trend):not(.dash-wait),
.camp-page .camp-stat > *:not(.camp-stat-trend):not(.dash-wait),
.dash-page .camp-stat > *:not(.camp-stat-trend):not(.dash-kpi-tip):not(.dash-wait) {
  position: relative;
  z-index: 1;
}
.ci-page .camp-stat-trend,
.camp-page .camp-stat-trend,
.dash-page .camp-stat-trend {
  z-index: 1;
}
.ci-page .camp-stat-ico,
.camp-page .camp-stat-ico,
.dash-page .camp-stat-ico {
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
}
.ci-page .camp-stat:hover,
.camp-page .camp-stat:hover,
.dash-page .camp-stat:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.1);
}
.dash-page .camp-stat:hover {
  z-index: 40;
}
.ci-page .camp-stat:hover::after,
.camp-page .camp-stat:hover::after,
.dash-page .camp-stat:hover::after {
  opacity: 1;
}
.ci-page .camp-stat:hover .camp-stat-ico,
.camp-page .camp-stat:hover .camp-stat-ico,
.dash-page .camp-stat:hover .camp-stat-ico {
  transform: translateY(-1px) scale(1.05);
}

.ci-page .ci-filter-board,
.ci-page .ci-chart,
.ci-page .ci-grid-wrap,
.ci-page .ci-pref,
.ci-page .ci-panel,
.camp-page .ci-grid-wrap {
  transition: box-shadow 0.22s ease, border-color 0.22s ease, transform 0.22s ease;
}
.ci-page .ci-filters {
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
}
.camp-page .camp-filters {
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
}
.ci-page .ci-grid-head,
.camp-page .ci-grid-head {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}
.ci-page .ci-panel-h {
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}
.ci-page .ci-chart:hover,
.ci-page .ci-filter-board:hover,
.ci-page .ci-pref:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}
.ci-page .ci-grid-wrap:hover,
.camp-page .ci-grid-wrap:hover,
.ci-page .ci-panel:hover {
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}
.ci-page .ci-table tbody tr.is-click,
.camp-page .camp-table tbody tr {
  transition: background 0.16s ease;
}
.ci-page .ci-table tbody tr.is-click:hover,
.camp-page .camp-table tbody tr:hover {
  background: linear-gradient(90deg, #eff6ff 0%, #f8fafc 55%, #ffffff 100%);
}
.ci-page .ci-panel-block .v1-btn,
.ci-page .ci-grid-actions .v1-btn,
.camp-page .ci-grid-actions .v1-btn {
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}
.ci-page .ci-panel-block .v1-btn:hover,
.ci-page .ci-grid-actions .v1-btn:hover,
.camp-page .ci-grid-actions .v1-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
}
.ci-page .camp-icon-btn,
.camp-page .camp-icon-btn {
  transition: background 0.16s ease, color 0.16s ease, transform 0.16s ease;
}
.ci-page .camp-icon-btn:hover,
.camp-page .camp-icon-btn:hover {
  transform: translateY(-1px);
}

@media (prefers-reduced-motion: reduce) {
  .v1-subtabs-ci .v1-subtab,
  .ci-page .camp-stat,
  .camp-page .camp-stat,
  .dash-page .camp-stat,
  .ci-page .camp-stat::after,
  .camp-page .camp-stat::after,
  .dash-page .camp-stat::after,
  .ci-page .camp-stat-ico,
  .camp-page .camp-stat-ico,
  .dash-page .camp-stat-ico,
  .ci-page .ci-filter-board,
  .ci-page .ci-chart,
  .ci-page .ci-grid-wrap,
  .ci-page .ci-pref,
  .camp-page .ci-grid-wrap,
  .ci-page .ci-table tbody tr.is-click,
  .camp-page .camp-table tbody tr,
  .ci-page .ci-panel-block .v1-btn,
  .ci-page .ci-grid-actions .v1-btn,
  .camp-page .ci-grid-actions .v1-btn,
  .ci-page .camp-icon-btn,
  .camp-page .camp-icon-btn,
  .dash-page .dash-card {
    transition: none;
  }
  .ci-page .camp-stat:hover,
  .camp-page .camp-stat:hover,
  .dash-page .camp-stat:hover,
  .dash-page .dash-card:hover,
  .ci-page .ci-chart:hover,
  .ci-page .ci-filter-board:hover,
  .ci-page .ci-pref:hover,
  .ci-page .ci-panel-block .v1-btn:hover,
  .ci-page .ci-grid-actions .v1-btn:hover,
  .camp-page .ci-grid-actions .v1-btn:hover,
  .ci-page .camp-icon-btn:hover,
  .camp-page .camp-icon-btn:hover {
    transform: none;
  }
}

/* Intelligence dashboard */
.dash-page { margin-top: 0; }
.dash-page .dash-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 16px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--v1-line);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.dash-toolbar-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 12px;
}
.dash-toolbar-side { display: flex; align-items: center; gap: 10px; }
.dash-toolbar label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--v1-muted);
}
.dash-toolbar select,
.dash-toolbar input[type="date"],
.dash-theme select {
  min-width: 132px;
  border: 1px solid var(--v1-line);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--v1-ink);
  text-transform: none;
  letter-spacing: 0;
  background: #f8fafc;
}
.dash-range { font-size: 0.78rem; color: var(--v1-muted); font-weight: 600; }
.dash-intel-btn {
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 12px 0 6px;
  border: 1px solid #1e3a8a; background: #0b1c33; color: #fff;
  border-radius: 10px; cursor: pointer; font: inherit; font-size: 0.78rem; font-weight: 800;
}
.dash-intel-btn img { width: 28px; height: 28px; display: block; }
.dash-intel-btn:hover { background: #1d4ed8; border-color: #1d4ed8; }
.dash-intel-btn:disabled { opacity: 0.65; cursor: wait; }
.dash-sync-confirm {
  position: fixed; inset: 0; z-index: 120;
  background: rgba(15, 23, 42, 0.52);
  display: grid; place-items: center; padding: 20px;
}
.dash-sync-confirm[hidden], .dash-sync-lock[hidden] { display: none !important; }
.dash-sync-confirm-card {
  width: min(520px, 100%);
  background: #fff; border-radius: 16px; padding: 22px 22px 18px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
}
.dash-sync-hero { width: 56px; height: 56px; display: block; margin: 0 auto 10px; }
.dash-sync-hero-sm { width: 36px; height: 36px; margin: 0; }
.dash-sync-confirm-card h3 { margin: 0 0 8px; text-align: center; font-size: 1.05rem; }
.dash-sync-confirm-card p { margin: 0 0 10px; color: #334155; font-size: 0.86rem; line-height: 1.45; }
.dash-sync-confirm-card ul { margin: 0 0 12px; padding-left: 18px; font-size: 0.8rem; color: #0f172a; }
.dash-sync-warn { background: #fff7ed; border: 1px solid #fdba74; border-radius: 10px; padding: 10px 12px; font-weight: 700; }
.dash-sync-modes { display: grid; gap: 8px; margin: 0 0 12px; }
.dash-sync-modes .v1-btn { width: 100%; justify-content: center; }
.dash-sync-modes p { margin: 0 0 6px; color: #64748b; font-size: 0.78rem; line-height: 1.4; }
.dash-sync-confirm-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; }
.dash-sync-lock {
  position: fixed; inset: 0; z-index: 130;
  background: rgba(248, 250, 252, 0.72);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  display: flex; flex-direction: column; justify-content: flex-start;
  padding: 12px 16px 0;
}
.dash-sync-lock-bar {
  display: flex; align-items: center; gap: 12px;
  background: #0b1c33; color: #fff;
  border-radius: 14px; padding: 12px 14px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.2);
}
.dash-sync-lock-copy { flex: 1; min-width: 0; }
.dash-sync-lock-copy strong { display: block; font-size: 0.82rem; }
.dash-sync-lock-copy span { display: block; font-size: 0.75rem; color: #bfdbfe; margin-top: 2px; }
.dash-sync-timer, .dash-sync-pct { font-variant-numeric: tabular-nums; font-weight: 800; }
.dash-sync-pct { min-width: 3.2rem; text-align: right; color: #93c5fd; }
.dash-sync-track {
  height: 8px; margin: 8px 0 6px; background: #e2e8f0; border-radius: 999px; overflow: hidden;
}
.dash-sync-track span {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, #2563eb, #38bdf8, #2563eb);
  background-size: 200% 100%;
  animation: dashWaitMove 1.2s linear infinite;
  border-radius: inherit;
}
.dash-sync-mod { margin: 0; font-size: 0.75rem; color: #334155; font-weight: 700; }
body.v1-sync-lock { overflow: hidden; }
body.v1-sync-lock .v1-side,
body.v1-sync-lock .v1-top,
body.v1-sync-lock .dash-toolbar,
body.v1-sync-lock .dash-kpis,
body.v1-sync-lock .dash-grid,
body.v1-sync-lock .dash-theme,
body.v1-sync-lock .dash-theme-scrim {
  pointer-events: none;
  filter: grayscale(0.15);
}
.dash-theme-btn.is-on, .dash-theme-btn:hover { background: #1d4ed8; border-color: #1d4ed8; }
.dash-theme-scrim {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(15, 23, 42, 0.38);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.dash-page.theme-open .dash-theme-scrim {
  opacity: 1;
  pointer-events: auto;
}
.dash-theme {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 91;
  width: min(380px, 92vw);
  margin: 0;
  background: #fff;
  border: 0;
  border-left: 1px solid var(--v1-line);
  border-radius: 0;
  padding: 18px 18px 24px;
  box-shadow: -12px 0 40px rgba(15, 23, 42, 0.18);
  transform: translateX(100%);
  transition: transform 0.28s ease;
  overflow: auto;
  display: flex;
  flex-direction: column;
  pointer-events: none;
}
.dash-page.theme-open .dash-theme {
  transform: translateX(0);
  pointer-events: auto;
}
body.dash-theme-open { overflow: hidden; }
.dash-theme-h, .dash-layout-h {
  display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px;
}
.dash-theme-h {
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.dash-theme-close {
  width: 34px; height: 34px; flex-shrink: 0;
  border: 1px solid var(--v1-line); background: #f8fafc;
  border-radius: 8px; cursor: pointer; color: #334155;
}
.dash-theme-close:hover { background: #e2e8f0; }
.dash-theme-h strong, .dash-layout-h strong { font-size: 0.9rem; }
.dash-theme-h span, .dash-layout-h span { display: block; font-size: 0.75rem; color: var(--v1-muted); }
.dash-theme-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px;
}
.dash-theme-label {
  font-size: 0.72rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.04em; color: var(--v1-muted); min-width: 140px;
}
.dash-seg { display: flex; gap: 4px; }
.dash-seg button {
  min-width: 40px; border: 1px solid var(--v1-line); background: #f8fafc;
  border-radius: 8px; padding: 6px 10px; font: inherit; font-weight: 800; cursor: pointer;
}
.dash-seg button.is-on { background: #1d4ed8; border-color: #1d4ed8; color: #fff; }
.dash-theme-check {
  display: flex !important; flex-direction: row !important; align-items: center;
  gap: 8px !important; margin: 0 0 14px;
  font-size: 0.82rem !important; font-weight: 600 !important;
  text-transform: none !important; letter-spacing: 0 !important; color: var(--v1-ink) !important;
}
.dash-layout-list {
  list-style: none; margin: 0; padding: 0; display: grid; gap: 6px;
  flex: 1 1 auto; min-height: 0; overflow: auto;
}
.dash-layout-list li {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  border: 1px solid var(--v1-line); border-radius: 8px; padding: 7px 10px;
  font-size: 0.82rem; font-weight: 600; background: #f8fafc;
}
.dash-layout-btns { display: flex; gap: 4px; flex-shrink: 0; }
.dash-layout-btns button {
  border: 1px solid var(--v1-line); background: #fff; border-radius: 6px;
  padding: 4px 8px; font: inherit; font-size: 0.75rem; cursor: pointer;
}
.dash-layout-actions { display: flex; gap: 8px; margin-top: 12px; }
.dash-page .camp-hero-kpis {
  margin: 14px 0 0;
  overflow: visible;
  position: relative;
  z-index: 5;
}
.dash-page .camp-stat {
  overflow: visible;
  z-index: 0;
}
.dash-page .camp-stat.is-waiting {
  overflow: hidden;
}
.dash-page .camp-stat > .dash-wait {
  position: absolute;
  inset: 0;
  z-index: 12;
}
.dash-page .camp-stat.is-waiting > *:not(.dash-wait) {
  filter: blur(3px);
}
.dash-page .camp-stat > .dash-kpi-tip {
  position: absolute;
  left: 10px;
  width: calc(100% - 20px);
  top: calc(100% + 6px);
  margin: 0;
  z-index: 50;
  box-sizing: border-box;
  padding: 8px 10px;
  background: #0b1c33;
  color: #f8fafc;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.45;
  white-space: pre-line;
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.28);
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
}
.dash-page .camp-stat:hover > .dash-kpi-tip:not(:empty) {
  visibility: visible;
  opacity: 1;
}
.dash-page .camp-stat small a { color: inherit; font-weight: 800; text-decoration: underline; }
.dash-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 12px;
}
.dash-grid[data-cols="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dash-grid[data-cols="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.dash-card {
  position: relative; background: #fff; border: 1px solid var(--v1-line);
  border-radius: 14px; padding: 14px 14px 12px; min-width: 0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.22s ease, border-color 0.22s ease, transform 0.22s ease;
}
.dash-page .dash-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}
.dash-card.is-pinned { border-color: #93c5fd; box-shadow: 0 0 0 1px #dbeafe; }
.dash-card-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.dash-card-h h3 { margin: 0; font-size: 0.9rem; font-weight: 800; letter-spacing: -0.01em; }
.dash-card-meta { margin: 3px 0 0; font-size: 0.7rem; color: var(--v1-muted); }
.dash-card-tools { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.dash-badge {
  font-size: 0.62rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em;
  background: #eff6ff; color: #1d4ed8; border-radius: 999px; padding: 2px 8px;
}
.dash-math, .dash-pin, .dash-more, .dash-drag {
  width: 30px; height: 30px; border: 0; background: #f1f5f9; border-radius: 8px; color: #475569; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.dash-drag { cursor: grab; }
.dash-card.is-dragging, .dash-layout-list li.is-dragging { opacity: 0.45; }
.dash-math:hover, .dash-pin:hover, .dash-more:hover, .dash-drag:hover { background: #e2e8f0; color: var(--v1-ink); }
.dash-pin[aria-pressed="true"] { background: #dbeafe; color: #1d4ed8; }
.dash-typebar { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 8px; }
.dash-type {
  border: 1px solid var(--v1-line); background: #fff; border-radius: 999px;
  padding: 3px 9px; font: inherit; font-size: 0.7rem; font-weight: 700; color: var(--v1-muted); cursor: pointer;
}
.dash-type.is-on { background: #0b1c33; border-color: #0b1c33; color: #fff; }
.dash-math-tip {
  margin: 0 0 8px; padding: 8px 10px; background: #f8fafc; border: 1px solid var(--v1-line);
  border-radius: 8px; font-size: 0.75rem; line-height: 1.45; color: #334155;
  white-space: pre-line;
}
.dash-pop {
  position: absolute; z-index: 6; top: 46px; right: 12px;
  width: min(280px, calc(100% - 24px)); background: #fff;
  border: 1px solid var(--v1-line); border-radius: 12px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.14); padding: 12px; display: grid; gap: 8px;
}
.dash-pop label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 0.65rem; font-weight: 800; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--v1-muted);
}
.dash-pop select, .dash-pop input[type="date"] {
  border: 1px solid var(--v1-line); border-radius: 8px; padding: 6px 8px;
  font: inherit; font-size: 0.84rem; font-weight: 600; text-transform: none; letter-spacing: 0;
}
.dash-pop-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.dash-canvas-wrap { height: 250px; position: relative; }
.dash-grid[data-cols="3"] .dash-canvas-wrap,
.dash-grid[data-cols="4"] .dash-canvas-wrap { height: 210px; }
.dash-empty { margin: 0; padding: 36px 12px; text-align: center; color: var(--v1-muted); font-size: 0.84rem; }
.dash-wait {
  position: absolute;
  inset: 0;
  z-index: 8;
  border-radius: inherit;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.16s ease, visibility 0.16s ease;
}
.dash-card.is-waiting .dash-wait,
.dash-page .camp-stat.is-waiting .dash-wait,
.ci-page .is-waiting > .dash-wait {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.dash-wait-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 15%, rgba(255, 255, 255, 0.7) 48%, transparent 78%);
  background-size: 220% 100%;
  animation: dashWaitMove 1.15s ease-in-out infinite;
}
.dash-wait-icon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #1d4ed8;
  font-size: 1.35rem;
  z-index: 1;
}
.dash-page .camp-stat .dash-wait-icon {
  font-size: 1.05rem;
}
@keyframes dashWaitMove {
  0% { background-position: 120% 0; }
  100% { background-position: -120% 0; }
}
@media (prefers-reduced-motion: reduce) {
  .dash-wait-shine { animation: none; }
  .dash-theme, .dash-theme-scrim { transition: none; }
}
@media (max-width: 1200px) {
  .dash-grid[data-cols="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1100px) {
  .dash-grid, .dash-grid[data-cols="3"], .dash-grid[data-cols="4"] { grid-template-columns: 1fr; }
}

/* Staff login — standalone page, does not change module layouts */
.auth-who {
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--v1-muted);
}
body.auth-body {
  min-height: 100%;
  background: var(--v1-bg);
  color: var(--v1-ink);
}
.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(280px, 0.92fr) minmax(380px, 1.08fr);
}
.auth-brand {
  position: relative;
  display: flex;
  align-items: center;
  padding: 56px 48px;
  overflow: hidden;
  background: var(--v1-navy);
  color: #e2e8f0;
}
.auth-brand::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.07) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at 28% 24%, #000 0%, transparent 72%);
  pointer-events: none;
}
.auth-brand-inner {
  position: relative;
  z-index: 1;
  max-width: 460px;
}
.auth-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  color: #fff;
}
.auth-lockup strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1.15;
}
.auth-lockup small {
  display: block;
  margin-top: 2px;
  color: #93c5fd;
  font-size: 0.78rem;
  font-weight: 600;
}
.auth-lockup-card {
  margin-bottom: 18px;
  color: var(--v1-navy);
}
.auth-lockup-card small { color: var(--v1-on); }
.auth-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 1.05rem;
  flex: 0 0 auto;
}
.auth-brand h1 {
  margin: 0;
  font-size: clamp(1.55rem, 2.6vw, 2.1rem);
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
}
.auth-tagline {
  margin: 14px 0 28px;
  font-size: 1.02rem;
  font-weight: 500;
  line-height: 1.5;
  color: #cbd5e1;
}
.auth-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.auth-points li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #cbd5e1;
  font-size: 0.88rem;
  font-weight: 600;
}
.auth-points i {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--v1-navy-2);
  color: #e2e8f0;
  font-size: 0.78rem;
}
.auth-stage {
  position: relative;
  display: grid;
  place-items: center;
  padding: 40px 28px;
  overflow: hidden;
  background: #06141c;
}
.auth-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("img/ai_bg.gif") center / cover no-repeat;
  pointer-events: none;
}
.auth-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6, 20, 28, 0.18) 0%, rgba(6, 20, 28, 0.42) 100%);
  pointer-events: none;
}
.auth-card {
  position: relative;
  z-index: 1;
  width: min(100%, 440px);
  background: var(--v1-card);
  color: var(--v1-ink);
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 20px;
  padding: 28px 28px 22px;
  box-shadow: 0 18px 50px rgba(2, 8, 23, 0.28);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.auth-card:hover {
  transform: translateY(-6px);
  border-color: #bfdbfe;
  box-shadow: 0 28px 64px rgba(2, 8, 23, 0.38);
}
.auth-card-h h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
}
.auth-card-h p {
  margin: 8px 0 0;
  color: var(--v1-muted);
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.45;
}
.auth-error {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 16px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-size: 0.82rem;
  font-weight: 600;
}
.auth-form {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}
.auth-form label {
  display: grid;
  gap: 6px;
}
.auth-form span {
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #475569;
}
.auth-form input {
  width: 100%;
  border: 1px solid var(--v1-line);
  border-radius: 10px;
  padding: 12px 14px;
  font: inherit;
  font-size: 0.95rem;
  color: var(--v1-ink);
  background: #f8fafc;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.auth-form input:hover {
  border-color: #cbd5e1;
  background: #fff;
}
.auth-form input:focus {
  outline: none;
  background: #fff;
  border-color: var(--v1-on);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}
.auth-submit {
  margin-top: 4px;
  width: 100%;
  justify-content: center;
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 0.95rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.auth-submit:hover {
  filter: brightness(1.06);
  box-shadow: 0 10px 24px rgba(29, 78, 216, 0.28);
  transform: translateY(-1px);
}
.auth-demo {
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
}
.auth-demo strong {
  display: block;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--v1-on);
}
.auth-demo p {
  margin: 6px 0 10px;
  color: var(--v1-muted);
  font-size: 0.8rem;
  font-weight: 500;
  line-height: 1.4;
}
.auth-demo dl {
  margin: 0;
  display: grid;
  gap: 8px;
}
.auth-demo dl div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.auth-demo dt {
  font-size: 0.78rem;
  font-weight: 700;
  color: #475569;
}
.auth-demo dd {
  margin: 0;
}
.auth-demo code,
.auth-form code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.8rem;
  background: #eff6ff;
  color: #1d4ed8;
  padding: 3px 7px;
  border-radius: 6px;
}
@media (max-width: 860px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-brand { padding: 36px 24px 12px; }
  .auth-points { grid-template-columns: 1fr 1fr; }
  .auth-stage { padding: 12px 16px 36px; align-items: start; }
  .auth-card:hover { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .auth-card, .auth-submit, .auth-form input { transition: none; }
  .auth-card:hover, .auth-submit:hover { transform: none; }
  .auth-stage::before { background-image: none; background-color: #06141c; }
}
