/* Cleaned app.css
   - removed exact duplicate rules/declarations
   - removed contradictory login-logo overrides
   - kept one deterministic login section at the end
*/
:root {
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface2: #f8fbff;
  --text: #13213a;
  --muted: #667594;
  --border: #e4eaf3;
  --blue: #2f6bff;
  --blue2: #1f55da;
  --green: #22c55e;
  --green2: #15803d;
  --red: #ef4444;
  --red2: #b91c1c;
  --yellow: #f59e0b;
  --purple: #8b5cf6;
  --cyan: #06b6d4;
  --nav: #0d1b33;
  --nav2: #111d35;
  --shadow: 0 16px 40px rgba(25,42,70,.08);
  --soft-shadow: 0 8px 20px rgba(31,85,218,.10);
  --radius: 9px;
  --radius2: 9px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
  line-height: 1.45;
}

.app-shell {
  display: grid;
  grid-template-columns: 300px 1fr;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: radial-gradient(circle at 40% 0%,#243a68 0,#111d35 32%,#0b172b 100%);
  padding: 28px 18px;
  color: #eaf1ff;
  display: flex;
  flex-direction: column;
}

.brand {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 30px;
  padding: 0 6px;
}

.brand-icon {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  background: linear-gradient(145deg,#4778ff,#2b55db);
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 900;
  box-shadow: 0 12px 30px rgba(47,107,255,.35);
}

.brand b {
  display: block;
  font-size: 21px;
  letter-spacing: -.02em;
}

.brand small {
  display: block;
  color: #9fb0d5;
  margin-top: 2px;
}

.side-nav {
  display: grid;
  gap: 8px;
}

.side-nav a {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 15px 16px;
  border-radius: 9px;
  color: #c8d4ef;
  text-decoration: none;
  font-weight: 700;
}

.side-nav a span {
  width: 24px;
  text-align: center;
  font-size: 19px;
  opacity: .95;
}

.side-nav a em {
  font-style: normal;
}

.side-nav a:hover {
  background: rgba(255,255,255,.08);
  color: white;
}

.side-nav a.active {
  background: linear-gradient(135deg,#3f72ff,#244ed7);
  color: white;
  box-shadow: 0 16px 30px rgba(47,107,255,.28);
}

.side-help {
  margin-top: auto;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 9px;
  padding: 18px;
  text-align: center;
}

.help-icon {
  width: 64px;
  height: 64px;
  border-radius: 9px;
  background: rgba(139,92,246,.28);
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  font-size: 28px;
  color: white;
}

.side-help b {
  display: block;
}

.side-help p {
  margin: 8px 0 0;
  color: #bdc9e2;
  font-size: 14px;
}

.theme-pill {
  margin-top: 18px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 9px;
  padding: 13px 14px;
  color: #dbe7ff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.theme-pill i {
  margin-left: auto;
  width: 42px;
  height: 24px;
  border-radius: 9px;
  background: #3154dc;
  position: relative;
}

.theme-pill i:after {
  content: "";
  position: absolute;
  right: 3px;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 9px;
  background: white;
}

.main {
  min-width: 0;
}

.app-topbar {
  height: 78px;
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 34px;
  position: sticky;
  top: 0;
  z-index: 20;
}

.search-box {
  height: 46px;
  min-width: 460px;
  max-width: 620px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 6px 20px rgba(25,42,70,.04);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  color: #98a5bd;
}

.search-box kbd {
  margin-left: auto;
  border: 1px solid var(--border);
  background: #f8fafc;
  color: #697791;
  border-radius: 9px;
  padding: 2px 8px;
  font-size: 12px;
}

.top-user {
  display: flex;
  align-items: center;
  gap: 18px;
}

.bell {
  position: relative;
  color: #344766;
  font-size: 21px;
}

.bell sup {
  position: absolute;
  top: -10px;
  right: -13px;
  background: #2f6bff;
  color: white;
  border-radius: 9px;
  min-width: 19px;
  height: 19px;
  line-height: 19px;
  text-align: center;
  font-size: 11px;
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  background: linear-gradient(135deg,#fee2c7,#c084fc);
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #12213a;
}

.user-text b {
  display: block;
}

.user-text small {
  display: block;
  color: var(--muted);
}

.page-head {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: flex-start;
  padding: 34px 34px 20px;
}

.page-head h1 {
  margin: 0;
  font-size: 32px;
  letter-spacing: -.04em;
}

.page-head p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.page-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0,1fr) 300px;
  gap: 18px;
  padding: 0 34px 28px;
}

.full-width {
  padding: 0 34px 28px;
}

.card,.panel,.hero-card,.action-card {
  background: rgba(255,255,255,.92);
  border: 1px solid var(--border);
  border-radius: 9px;
  box-shadow: var(--shadow);
}

.card,.panel {
  padding: 22px;
}

.hero-card {
  padding: 25px;
}

.card-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.card-head h2,.panel h2,.hero-card h2 {
  margin: 0 0 7px;
  font-size: 20px;
  letter-spacing: -.02em;
}

.card-head p,.panel p,.hero-card p {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-weight: 900;
  color: var(--blue);
}

.muted {
  color: var(--muted);
}

.btn {
  border: 1px solid var(--border);
  background: #fff;
  color: #12213a;
  border-radius: 9px;
  padding: 11px 16px;
  text-decoration: none;
  cursor: pointer;
  font-weight: 850;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  white-space: nowrap;
  box-shadow: 0 5px 14px rgba(25,42,70,.04);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(25,42,70,.08);
}

.btn.primary {
  background: linear-gradient(135deg,#3d72ff,#2452db);
  border-color: #2f6bff;
  color: white;
  box-shadow: 0 12px 24px rgba(47,107,255,.26);
}

.btn.success {
  background: linear-gradient(135deg,#31c56a,#16a34a);
  border-color: #16a34a;
  color: white;
}

.btn.danger {
  background: linear-gradient(135deg,#ff6b6b,#e11d48);
  border-color: #e11d48;
  color: white;
}

.btn.ghost {
  background: #f8fbff;
}

.link-btn {
  font-weight: 850;
  color: var(--blue);
  text-decoration: none;
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(5,minmax(0,1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.kpi-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.kpi-icon {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 23px;
  font-weight: 900;
}

.kpi-icon.blue {
  background: #eaf1ff;
  color: var(--blue);
}

.kpi-icon.green {
  background: #dcfce7;
  color: var(--green2);
}

.kpi-icon.yellow {
  background: #fff4dd;
  color: #b45309;
}

.kpi-icon.red {
  background: #fee2e2;
  color: var(--red2);
}

.kpi-icon.purple {
  background: #f0e7ff;
  color: #7c3aed;
}

.kpi-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.kpi-card strong {
  display: block;
  font-size: 28px;
  line-height: 1.1;
  margin-top: 4px;
  letter-spacing: -.04em;
}

.delta {
  font-size: 12px;
  color: var(--green2);
  font-weight: 800;
  margin-top: 7px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 18px;
}

.quick-stack {
  display: grid;
  gap: 11px;
}

.quick-stack form {
  margin: 0;
}

.quick-stack button {
  width: 100%;
  border: 0;
  text-align: left;
  cursor: pointer;
}

.quick-action {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border-radius: 9px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  background: linear-gradient(135deg,#fff,#f7fbff);
}

.quick-action span {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: white;
  font-weight: 900;
}

.quick-action b {
  display: block;
}

.quick-action small {
  display: block;
  color: var(--muted);
}

.blue-bg {
  background: #3b70ff;
}

.green-bg {
  background: #22c55e;
}

.purple-bg {
  background: #8b5cf6;
}

.orange-bg {
  background: #f59e0b;
}

.cyan-bg {
  background: #06b6d4;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th,td {
  border-bottom: 1px solid var(--border);
  padding: 13px 10px;
  text-align: left;
  vertical-align: top;
}

th {
  color: #667594;
  text-transform: uppercase;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: .04em;
}

tbody tr:hover {
  background: #f8fbff;
}

.badge,.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  padding: 6px 10px;
  font-weight: 900;
  font-size: 12px;
}

.badge.success,.status-pill.success {
  background: #dcfce7;
  color: #166534;
}

.badge.warning,.status-pill.warning {
  background: #fff4dd;
  color: #92400e;
}

.badge.danger,.status-pill.danger {
  background: #fee2e2;
  color: #991b1b;
}

.badge.neutral,.status-pill.neutral {
  background: #eef2f7;
  color: #475569;
}

.status-pill {
  font-size: 14px;
  padding: 10px 15px;
}

.chart-card {
  min-height: 310px;
}

.line-chart {
  height: 220px;
  position: relative;
  background: linear-gradient(#fff,#fff) padding-box;
  border-radius: 9px;
  margin-top: 20px;
}

.line-chart:before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(to bottom,transparent 0 43px,#edf2f7 44px),repeating-linear-gradient(to right,transparent 0 100px,#f6f8fb 101px);
  border-radius: 9px;
}

.line-svg {
  position: absolute;
  inset: 18px;
}

.legend {
  display: flex;
  gap: 18px;
  justify-content: center;
  color: var(--muted);
  font-size: 13px;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 9px;
  display: inline-block;
  margin-right: 6px;
}

.donut-row {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 20px;
  align-items: center;
  margin-top: 16px;
}

.donut {
  width: 170px;
  height: 170px;
  border-radius: 9px;
  background: conic-gradient(#22c55e 0 32%,#3b82f6 32% 70%,#f59e0b 70% 88%,#ef4444 88% 100%);
  position: relative;
  margin: auto;
}

.donut:after {
  content: "";
  position: absolute;
  inset: 43px;
  background: white;
  border-radius: 9px;
  box-shadow: inset 0 0 0 1px #eef2f7;
}

.score-list {
  display: grid;
  gap: 14px;
}

.score-list div {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  gap: 10px;
  align-items: center;
  color: var(--muted);
}

.notification-list {
  display: grid;
  gap: 14px;
}

.notice {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}

.notice:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.notice-icon {
  font-size: 23px;
}

.notice b {
  display: block;
}

.notice small {
  display: block;
  color: var(--muted);
  margin-top: 3px;
}

.system-row {
  display: flex;
  justify-content: space-between;
  margin-top: 14px;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(5,minmax(190px,1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.action-card {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.action-card .action-ico {
  width: 48px;
  height: 48px;
  border-radius: 9px;
  color: white;
  display: grid;
  place-items: center;
  font-size: 21px;
  font-weight: 900;
}

.action-card h2 {
  font-size: 18px;
  margin: 0;
}

.action-card p {
  margin: 0;
  color: var(--muted);
  min-height: 42px;
}

.run-grid {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  gap: 14px;
}

.run-hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  background: linear-gradient(135deg,#fff 0%,#eef6ff 100%);
}

.run-hero.is-running {
  background: linear-gradient(135deg,#fff 0%,#eef6ff 65%,#ecfeff 100%);
}

.progress-card {
  overflow: hidden;
}

.progress-title {
  font-weight: 900;
  margin-bottom: 12px;
}

.progress-bar {
  height: 14px;
  border-radius: 9px;
  background: #e5e7eb;
  overflow: hidden;
}

.progress-bar span {
  display: block;
  height: 100%;
  width: 35%;
  border-radius: 9px;
  background: linear-gradient(90deg,#60a5fa,#2563eb);
  animation: progress 1.3s infinite alternate ease-in-out;
}

@keyframes progress {
  from {
    transform: translateX(-80%);
  }
  to {
    transform: translateX(250%);
  }
}

.friendly-log {
  display: grid;
  gap: 8px;
}

.friendly-log div {
  border-left: 4px solid #93c5fd;
  background: #f8fafc;
  border-radius: 9px;
  padding: 10px 12px;
  font-family: ui-monospace,SFMono-Regular,Menlo,monospace;
  font-size: 13px;
}

details summary {
  cursor: pointer;
  color: var(--blue);
  /* font-weight: 900; */
}

.log-card pre,pre {
  white-space: pre-wrap;
  word-break: break-word;
  background: #0b1020;
  color: #dbeafe;
  padding: 16px;
  border-radius: 9px;
  overflow: auto;
}

.settings-form {
  display: grid;
  gap: 18px;
}

.settings-section {
  padding: 0;
  overflow: hidden;
}

.settings-section .section-title {
  padding: 22px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg,#fff,#f8fbff);
}

.setting-row {
  display: grid;
  grid-template-columns: minmax(280px,430px) 1fr;
  gap: 22px;
  align-items: start;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
}

.setting-row:last-child {
  border-bottom: 0;
}

.friendly-setting span {
  display: block;
  font-weight: 900;
  font-size: 15px;
  margin-bottom: 6px;
}

.friendly-setting code {
  display: inline-flex;
  background: #eef2ff;
  color: #3449a8;
  border: 1px solid #dbe4ff;
  border-radius: 9px;
  padding: 3px 7px;
  font-size: 12px;
}

.friendly-setting p {
  margin: 9px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.friendly-setting textarea {
  min-height: 100px;
}

.savebar {
  position: sticky;
  bottom: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 14px;
  box-shadow: var(--shadow);
}

select,input,textarea {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 11px 12px;
  font: inherit;
  background: #fff;
  outline: none;
  width: 100%;
}

select:focus,input:focus,textarea:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(47,107,255,.12);
}

.mapping-hero {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: flex-start;
  background: linear-gradient(135deg,#fff 0%,#f2f8ff 100%);
}

.map-card code {
  background: #eef2ff;
  border: 1px solid #dbe4ff;
  border-radius: 9px;
  padding: 2px 6px;
}

.copybox {
  width: 100%;
  font-family: ui-monospace,SFMono-Regular,Menlo,monospace;
  line-height: 1.55;
  background: #f8fafc;
}

.hint-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.empty-state {
  text-align: center;
  padding: 42px;
}

.match-list {
  display: grid;
  gap: 12px;
}

.match-card {
  display: grid;
  grid-template-columns: 1fr 48px 1fr 190px;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 16px;
  background: #fff;
}

.match-card.high {
  border-color: #bbf7d0;
  background: linear-gradient(135deg,#fff 0%,#f0fdf4 100%);
}

.match-card.medium {
  border-color: #fed7aa;
  background: linear-gradient(135deg,#fff 0%,#fff7ed 100%);
}

.match-card.low {
  border-color: #fecaca;
  background: linear-gradient(135deg,#fff 0%,#fef2f2 100%);
}

.match-side {
  display: grid;
  gap: 5px;
}

.match-side strong {
  font-size: 16px;
}

.match-side small {
  color: var(--muted);
}

.match-side code {
  width: max-content;
  background: #eef2ff;
  color: #3730a3;
  border: 1px solid #c7d2fe;
  border-radius: 9px;
  padding: 4px 8px;
  font-weight: 900;
}

.source-label {
  width: max-content;
  background: #eff6ff;
  color: #1d4ed8;
  border-radius: 9px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 900;
}

.source-label.mango {
  background: #f5f3ff;
  color: #6d28d9;
}

.match-arrow {
  text-align: center;
  color: var(--blue);
  font-size: 24px;
  font-weight: 900;
}

.match-status {
  text-align: right;
}

.simple-list {
  display: grid;
  gap: 9px;
  margin-top: 12px;
  max-height: 420px;
  overflow: auto;
}

.simple-list div {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 11px;
  background: #fafafa;
}

.simple-list strong {
  display: block;
}

.simple-list small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}

.ok-text {
  background: #ecfdf3;
  color: #166534;
  border-radius: 9px;
  padding: 12px;
  font-weight: 800;
}

.raw-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

.compact-table {
  font-size: 12px;
}

.compact-table th,.compact-table td {
  padding: 8px 6px;
}

.wide-table {
  overflow: auto;
}

.wide-table table {
  min-width: 1300px;
}

.department-list {
  display: grid;
  gap: 14px;
}

.dept-card {
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fff;
  padding: 0;
  overflow: hidden;
}

.dept-card summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 17px 19px;
  list-style: none;
  border-bottom: 1px solid var(--border);
}

.dept-card summary::-webkit-details-marker {
  display: none;
}

.dept-card summary strong {
  display: block;
  font-size: 17px;
}

.dept-card summary small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}

.dept-card[open] summary {
  background: #f8fbff;
}

.dept-card>p,.dept-card>.note,.dept-card>.comment-preview {
  margin: 16px 18px;
}

.comment-preview h3 {
  margin: 0;
  font-size: 16px;
}

.comment-preview pre {
  background: #f8fafc;
  color: #172033;
  border: 1px solid var(--border);
  max-height: 420px;
}

.warning-note {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 9px;
  padding: 12px;
  color: #9a3412;
}

.footer {
  padding: 10px 34px 28px;
  color: #7a89a4;
}

.mini-bar {
  height: 7px;
  background: #e8eef7;
  border-radius: 9px;
  overflow: hidden;
}

.mini-bar i {
  display: block;
  height: 100%;
  border-radius: 9px;
  background: linear-gradient(90deg,#ef4444,#f59e0b);
}

.manager-list {
  display: grid;
  gap: 14px;
}

.manager-row {
  display: grid;
  grid-template-columns: 46px 1fr 54px minmax(90px,160px) 145px;
  gap: 14px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.manager-row:last-child {
  border-bottom: 0;
}

.face {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  background: linear-gradient(135deg,#e0e7ff,#bfdbfe);
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #244ed7;
}

.score-badge {
  border-radius: 9px;
  padding: 7px 9px;
  text-align: center;
  font-weight: 900;
}

.score-badge.low {
  background: #fee2e2;
  color: #991b1b;
}

.score-badge.mid {
  background: #fff4dd;
  color: #92400e;
}

.score-badge.good {
  background: #dcfce7;
  color: #166534;
}

.filters .inline-form {
  display: flex;
  align-items: end;
  gap: 14px;
  flex-wrap: wrap;
}

.filters label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  min-width: 170px;
}

.distribution-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: start;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 16px;
  background: #fff;
  margin-bottom: 12px;
}

.distribution-card .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.json-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 10px;
  margin-top: 12px;
}

.json-box {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px;
}

.json-box summary {
  font-size: 13px;
}

.json-box pre {
  max-height: 240px;
  font-size: 12px;
  margin-top: 9px;
}

@media (max-width:1400px) {
  .content-grid {
    grid-template-columns: 1fr;
  }
  .kpi-row {
    grid-template-columns: repeat(3,1fr);
  }
  .action-grid {
    grid-template-columns: repeat(3,1fr);
  }
}

@media (max-width:1100px) {
  .app-shell {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: relative;
    height: auto;
  }
  .side-help,.theme-pill {
    display: none;
  }
  .app-topbar {
    position: relative;
  }
  .search-box {
    min-width: 0;
    flex: 1;
  }
  .grid-2,.grid-3,.raw-grid,.donut-row {
    grid-template-columns: 1fr;
  }
  .match-card {
    grid-template-columns: 1fr;
  }
  .match-arrow {
    text-align: left;
    transform: rotate(90deg);
    width: 20px;
  }
  .match-status {
    text-align: left;
  }
  .setting-row {
    grid-template-columns: 1fr;
  }
  .run-grid {
    grid-template-columns: 1fr 1fr;
  }
  .action-grid {
    grid-template-columns: 1fr 1fr;
  }
  .kpi-row {
    grid-template-columns: 1fr 1fr;
  }
  .json-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width:760px) {
  .app-topbar {
    padding: 16px;
    height: auto;
    gap: 12px;
  }
  .top-user .user-text {
    display: none;
  }
  .page-head,.full-width,.content-grid {
    padding-left: 16px;
    padding-right: 16px;
  }
  .page-head {
    display: block;
  }
  .page-actions {
    margin-top: 16px;
  }
  .kpi-row,.run-grid,.action-grid {
    grid-template-columns: 1fr;
  }
  .manager-row {
    grid-template-columns: 42px 1fr;
  }
  .manager-row .score-badge,.manager-row .mini-bar,.manager-row .muted:last-child {
    grid-column: 2;
  }
  .sidebar {
    padding: 18px;
  }
  .side-nav {
    grid-template-columns: 1fr 1fr;
  }
  .side-nav a em {
    font-size: 13px;
  }
}

.compact-shell {
  grid-template-columns: 220px 1fr;
  background: #f5f7fb;
}

.compact-sidebar {
  padding: 18px 12px;
  width: 220px;
}

.compact-brand {
  margin-bottom: 18px;
  padding: 0 6px;
}

.compact-brand .brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  font-size: 17px;
}

.compact-brand b {
  font-size: 17px;
}

.compact-brand small {
  font-size: 12px;
  color: #9fb0d4;
}

.compact-nav {
  gap: 5px;
}

.compact-nav a {
  padding: 11px 12px;
  border-radius: 9px;
}

.compact-nav a span {
  width: 22px;
  font-size: 17px;
}

.compact-nav a em {
  font-size: 14px;
}

.admin-card {
  margin-top: auto;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 9px;
  text-decoration: none;
  color: #fff;
  background: rgba(255,255,255,.06);
}

.admin-card:hover {
  background: rgba(255,255,255,.10);
}

.admin-card b {
  font-size: 13px;
  display: block;
}

.admin-card small {
  font-size: 12px;
  color: #9fb0d4;
  display: block;
  margin-top: 2px;
}

.avatar.small {
  width: 34px;
  height: 34px;
  font-size: 14px;
}

.compact-main {
  min-width: 0;
}

.compact-page-head {
  padding: 26px 30px 14px;
  min-height: auto;
  align-items: flex-end;
}

.compact-page-head h1 {
  font-size: 28px;
  margin-bottom: 6px;
}

.compact-page-head p {
  font-size: 14px;
  max-width: 740px;
}

.compact-page-head .page-actions:empty {
  display: none;
}

.full-width {
  padding: 16px 30px 30px;
}

.compact-dashboard {
  max-width: 1180px;
}

.compact-kpi-row {
  grid-template-columns: repeat(5,minmax(150px,1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.compact-kpi {
  min-height: 86px;
  padding: 16px;
  text-decoration: none;
  color: inherit;
}

.compact-kpi .kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  font-size: 18px;
}

.compact-kpi span {
  font-size: 12px;
}

.compact-kpi strong {
  font-size: 26px;
  line-height: 1.1;
}

.compact-kpi .delta {
  font-size: 12px;
  margin-top: 4px;
}

.compact-main-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 14px;
}

.compact-card {
  padding: 18px;
  border-radius: 9px;
}

.compact-card-head {
  margin-bottom: 14px;
}

.compact-card-head h2 {
  font-size: 18px;
}

.compact-card-head p {
  font-size: 13px;
  line-height: 1.45;
}

.clean-progress {
  margin-top: 6px;
}

.clean-progress-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 9px;
  color: #172033;
}

.clean-progress-top span {
  font-weight: 900;
  color: #ef4444;
}

.clean-progress-bar {
  height: 11px;
  border-radius: 9px;
  background: #edf2f7;
  overflow: hidden;
}

.clean-progress-bar i {
  display: block;
  height: 100%;
  border-radius: 9px;
  background: linear-gradient(90deg,#f59e0b,#ef4444);
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 10px;
  margin-top: 16px;
}

.mini-stats div {
  border: 1px solid #e7edf5;
  background: #fafcff;
  border-radius: 9px;
  padding: 12px;
}

.mini-stats b {
  display: block;
  font-size: 22px;
}

.mini-stats span {
  color: #64748b;
  font-size: 12px;
}

.section-links {
  display: grid;
  gap: 8px;
}

.section-links a {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  border: 1px solid #e7edf5;
  border-radius: 9px;
  padding: 12px 13px;
  text-decoration: none;
  color: #172033;
  background: #fff;
}

.section-links a:hover {
  border-color: #bfdbfe;
  background: #f8fbff;
}

.section-links b {
  font-size: 14px;
}

.section-links span {
  font-size: 12px;
  color: #64748b;
  text-align: right;
}

.card {
  border-radius: 9px;
}

.card h2 {
  font-size: 18px;
}

.btn {
  padding: 10px 14px;
  border-radius: 9px;
}

.page-head {
  padding-top: 26px;
  padding-bottom: 14px;
}

.kpi-row {
  gap: 12px;
}

.table-wrap table {
  font-size: 13px;
}

th,td {
  padding: 12px 10px;
}

.panel {
  border-radius: 9px;
}

.settings-section .section-title {
  padding: 18px;
}

.setting-row {
  padding: 14px 18px;
}

.distribution-card {
  border-radius: 9px;
  padding: 14px;
}

.match-card {
  border-radius: 9px;
  padding: 14px;
}

.run-hero {
  border-radius: 9px;
}

.action-grid {
  gap: 12px;
}

.action-card {
  padding: 16px;
  border-radius: 9px;
}

.raw-grid {
  gap: 12px;
}

@media (max-width:1300px) {
  .compact-kpi-row {
    grid-template-columns: repeat(3,1fr);
  }
  .compact-main-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width:900px) {
  .compact-shell {
    grid-template-columns: 1fr;
  }
  .compact-sidebar {
    position: relative;
    width: auto;
    height: auto;
  }
  .admin-card {
    margin-top: 12px;
  }
  .full-width,.compact-page-head {
    padding-left: 18px;
    padding-right: 18px;
  }
  .compact-kpi-row {
    grid-template-columns: repeat(2,1fr);
  }
}

@media (max-width:620px) {
  .compact-kpi-row,.mini-stats {
    grid-template-columns: 1fr;
  }
  .section-links a {
    display: block;
  }
  .section-links span {
    text-align: left;
    display: block;
    margin-top: 4px;
  }
  .compact-page-head h1 {
    font-size: 24px;
  }
}

:root {
  --v9-bg: #f6f8fc;
  --v9-card: #ffffff;
  --v9-text: #0f1f3d;
  --v9-muted: #64728f;
  --v9-border: #e3e9f3;
  --v9-blue: #2f6bff;
  --v9-blue-soft: #eaf2ff;
  --v9-green: #22c55e;
  --v9-green-soft: #eaf9ef;
  --v9-yellow: #f59e0b;
  --v9-yellow-soft: #fff3df;
  --v9-red: #ef4444;
  --v9-red-soft: #ffe9ec;
  --v9-purple: #7c3aed;
  --v9-purple-soft: #f0eaff;
  --v9-nav: #0b162b;
  --v9-nav2: #111f39;
  --v9-shadow: 0 10px 28px rgba(15,31,61,.07);
}

body {
  background: var(--v9-bg);
  color: var(--v9-text);
  font-size: 14px;
}

.minimal-shell {
  display: grid;
  grid-template-columns: 232px 1fr;
  min-height: 100vh;
  background: var(--v9-bg);
}

.minimal-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  width: 232px;
  padding: 22px 14px;
  background: linear-gradient(180deg,#101f3a 0%,#081325 100%);
  display: flex;
  flex-direction: column;
  color: #d9e5ff;
  box-shadow: inset -1px 0 rgba(255,255,255,.05);
}

.minimal-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #fff;
  margin: 0 4px 28px;
}

.minimal-brand .brand-icon {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  background: rgba(47,107,255,.14);
  border: 1px solid rgba(82,132,255,.55);
  box-shadow: none;
  display: grid;
  place-items: center;
  color: #5d8cff;
}

.minimal-brand .brand-icon svg {
  width: 24px;
  height: 24px;
}

.minimal-brand b {
  font-size: 16px;
  letter-spacing: .01em;
}

.minimal-brand small {
  font-size: 12px;
  color: #aebcdf;
}

.minimal-nav {
  display: grid;
  gap: 8px;
}

.minimal-nav a {
  display: flex;
  align-items: center;
  gap: 13px;
  height: 44px;
  padding: 0 13px;
  border-radius: 9px;
  color: #cad6ee;
  text-decoration: none;
  font-weight: 650;
  transition: .15s ease;
}

.minimal-nav a svg {
  width: 20px;
  height: 20px;
  color: #9fb2d6;
}

.minimal-nav a em {
  font-style: normal;
  font-size: 14px;
}

.minimal-nav a:hover {
  background: rgba(255,255,255,.06);
  color: #fff;
}

.minimal-nav a.active {
  background: rgba(47,107,255,.95);
  color: #fff;
  box-shadow: 0 10px 22px rgba(47,107,255,.24);
}

.minimal-nav a.active svg {
  color: #fff;
}

.minimal-admin {
  margin-top: auto;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px;
  align-items: center;
  padding: 13px 6px 0;
  border-top: 1px solid rgba(255,255,255,.13);
  text-decoration: none;
  color: #fff;
  background: transparent;
  border-radius: 9px;
}

.minimal-admin:hover {
  background: transparent;
}

.minimal-admin .avatar {
  width: 40px;
  height: 40px;
  border-radius: 9px;
  background: #fff;
  color: #0d1b33;
}

.minimal-admin .avatar svg {
  width: 20px;
  height: 20px;
}

.minimal-admin b {
  font-size: 14px;
}

.minimal-admin small {
  font-size: 12px;
  color: #aebcdf;
}

.minimal-main {
  min-width: 0;
  padding: 0;
}

.minimal-page-head {
  padding: 32px 34px 18px;
  min-height: auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.minimal-page-head h1 {
  font-size: 30px;
  line-height: 1.1;
  margin: 0;
  letter-spacing: -.035em;
  color: var(--v9-text);
}

.minimal-page-head p {
  margin: 8px 0 0;
  color: var(--v9-muted);
  font-size: 15px;
}

.minimal-page-head .page-actions:empty {
  display: none;
}

.full-width {
  padding: 12px 34px 34px;
}

.minimal-dashboard {
  max-width: 1220px;
}

.minimal-kpi-row {
  display: grid;
  grid-template-columns: repeat(4,minmax(170px,1fr));
  gap: 18px;
  margin: 0 0 22px;
}

.minimal-kpi {
  min-height: 94px;
  padding: 18px 22px;
  border-radius: 9px;
  background: var(--v9-card);
  border: 1px solid var(--v9-border);
  box-shadow: var(--v9-shadow);
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  color: var(--v9-text);
  transition: .15s ease;
}

.minimal-kpi:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(15,31,61,.10);
}

.minimal-kpi .kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 0;
  flex: 0 0 auto;
}

.minimal-kpi .kpi-icon svg {
  width: 26px;
  height: 26px;
}

.minimal-kpi .kpi-icon.blue {
  background: var(--v9-blue-soft);
  color: var(--v9-blue);
}

.minimal-kpi .kpi-icon.green {
  background: var(--v9-green-soft);
  color: var(--v9-green);
}

.minimal-kpi .kpi-icon.yellow {
  background: var(--v9-yellow-soft);
  color: var(--v9-yellow);
}

.minimal-kpi .kpi-icon.red {
  background: var(--v9-red-soft);
  color: var(--v9-red);
}

.minimal-kpi .kpi-icon.purple {
  background: var(--v9-purple-soft);
  color: var(--v9-purple);
}

.minimal-kpi span {
  display: block;
  color: var(--v9-muted);
  font-size: 13px;
  margin-bottom: 2px;
}

.minimal-kpi strong {
  display: block;
  font-size: 28px;
  line-height: 1.05;
  letter-spacing: -.035em;
  color: var(--v9-text);
}

.minimal-kpi .delta {
  font-size: 12px;
  color: #7a88a4;
  margin-top: 5px;
}

.minimal-grid {
  display: grid;
  grid-template-columns: minmax(0,1.15fr) minmax(360px,.85fr);
  gap: 20px;
  margin-bottom: 20px;
}

.minimal-card,.card.minimal-card {
  border-radius: 9px;
  background: var(--v9-card);
  border: 1px solid var(--v9-border);
  box-shadow: var(--v9-shadow);
  padding: 22px;
}

.minimal-card-head,.card-head.minimal-card-head {
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.minimal-card-head h2 {
  font-size: 18px;
  margin: 0 0 6px;
  letter-spacing: -.02em;
}

.minimal-card-head p {
  margin: 0;
  color: var(--v9-muted);
  font-size: 13px;
  line-height: 1.45;
}

.link-clean {
  font-size: 13px;
  color: var(--v9-blue);
  text-decoration: none;
  font-weight: 700;
}

.link-clean:hover {
  text-decoration: underline;
}

.clean-table-wrap {
  border: 0;
  box-shadow: none;
  border-radius: 9px;
  overflow: auto;
}

.clean-table {
  width: 100%;
  border-collapse: collapse;
  background: transparent;
}

.clean-table th {
  font-size: 12px;
  color: #71809c;
  text-transform: none;
  letter-spacing: 0;
  background: transparent;
  border-bottom: 1px solid var(--v9-border);
  padding: 14px 10px;
  text-align: left;
}

.clean-table td {
  font-size: 14px;
  border-bottom: 1px solid var(--v9-border);
  padding: 15px 10px;
  vertical-align: middle;
}

.clean-table tr:last-child td {
  border-bottom: 0;
}

.clean-table small {
  color: var(--v9-muted);
}

.accent-number {
  color: #ea580c;
  font-weight: 800;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.pill.success {
  background: var(--v9-green-soft);
  color: #16803b;
}

.pill.warning {
  background: var(--v9-yellow-soft);
  color: #b45309;
}

.pill.danger {
  background: var(--v9-red-soft);
  color: #b91c1c;
}

.pill.neutral {
  background: #f0f3f8;
  color: #59677f;
}

.status-list {
  display: grid;
  gap: 0;
}

.status-row {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--v9-border);
  text-decoration: none;
  color: var(--v9-text);
}

.status-row:last-child {
  border-bottom: 0;
}

.status-avatar {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #f0f4fb;
  color: #6b7a95;
  display: grid;
  place-items: center;
}

.status-avatar svg {
  width: 18px;
  height: 18px;
}

.status-main b {
  display: block;
  font-size: 14px;
}

.status-main small {
  display: block;
  color: var(--v9-muted);
  font-size: 12px;
  margin-top: 2px;
}

.empty-mini {
  display: flex;
  gap: 9px;
  align-items: center;
  color: var(--v9-muted);
  padding: 18px 0;
}

.empty-mini svg {
  width: 18px;
  height: 18px;
}

.report-card {
  margin-top: 0;
}

.report-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px 28px;
}

.report-list div {
  display: grid;
  grid-template-columns: 22px 190px 1fr;
  align-items: center;
  gap: 8px;
  color: var(--v9-muted);
}

.report-list svg {
  width: 17px;
  height: 17px;
  color: var(--v9-blue);
}

.report-list b {
  color: var(--v9-text);
  font-weight: 700;
}

.report-list span {
  color: #55647e;
}

.small-btn {
  height: 34px;
  padding: 8px 12px;
  border-radius: 9px;
}

.btn.secondary {
  background: #fff;
  border: 1px solid var(--v9-border);
  color: var(--v9-text);
}

.btn.secondary:hover {
  background: #f8fbff;
  border-color: #cbd7ea;
}

.app-topbar,.side-help,.theme-pill,.footer {
  display: none !important;
}

.brand {
  margin-bottom: 0;
}

.sidebar {
  background: linear-gradient(180deg,#101f3a 0%,#081325 100%);
}

.side-nav a span {
  display: none;
}

.side-nav a svg {
  display: block;
}

.kpi-row {
  gap: 18px;
}

.kpi-card {
  border-radius: 9px;
}

.card,.panel,.hero-card,.action-card {
  border-radius: 9px;
  box-shadow: var(--v9-shadow);
  border-color: var(--v9-border);
}

.card {
  padding: 22px;
}

.card-head h2,.panel h2,.hero-card h2 {
  font-size: 18px;
}

.table-wrap {
  border-radius: 9px;
  box-shadow: none;
}

.badge {
  border-radius: 9px;
}

.btn {
  border-radius: 9px;
}

.page-head {
  padding: 32px 34px 18px;
}

.page-head h1 {
  font-size: 30px;
}

.page-head p {
  font-size: 15px;
}

@media (max-width:1180px) {
  .minimal-dashboard {
    max-width: none;
  }
}

@media (max-width:860px) {
  .minimal-sidebar {
    position: relative;
    width: auto;
    height: auto;
  }
  .minimal-nav {
    grid-template-columns: 1fr 1fr;
  }
  .minimal-admin {
    margin-top: 14px;
  }
  .minimal-page-head,.full-width {
    padding-left: 18px;
    padding-right: 18px;
  }
  .report-list {
    grid-template-columns: 1fr;
  }
  .report-list div {
    grid-template-columns: 22px 170px 1fr;
  }
}

@media (max-width:520px) {
  .minimal-nav {
    grid-template-columns: 1fr;
  }
  .status-row {
    grid-template-columns: 34px 1fr;
  }
  .status-row .pill {
    grid-column: 2;
    width: max-content;
  }
  .report-list div {
    grid-template-columns: 20px 1fr;
  }
  .report-list span {
    grid-column: 2;
  }
  .minimal-page-head h1 {
    font-size: 25px;
  }
}

.minimal-shell {
  grid-template-columns: 220px minmax(0,1fr);
}

.minimal-sidebar {
  width: 220px;
  padding: 18px 12px;
}

.minimal-brand {
  margin-bottom: 22px;
}

.minimal-brand .brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
}

.minimal-brand b {
  font-size: 15px;
}

.minimal-brand small {
  font-size: 11px;
}

.minimal-nav {
  gap: 6px;
}

.minimal-nav a {
  height: 42px;
  border-radius: 9px;
  padding: 0 12px;
}

.minimal-nav a em {
  font-size: 13px;
}

.minimal-nav a svg {
  width: 18px;
  height: 18px;
}

.minimal-admin {
  padding: 12px 4px 0;
}

.minimal-admin .avatar {
  width: 36px;
  height: 36px;
}

.minimal-admin b {
  font-size: 13px;
}

.minimal-admin small {
  font-size: 11px;
}

.minimal-main {
  width: 100%;
  max-width: none;
}

.minimal-page-head {
  padding: 28px 28px 14px;
}

.minimal-page-head h1 {
  font-size: 28px;
}

.minimal-page-head p {
  font-size: 14px;
  margin-top: 6px;
}

.full-width {
  padding: 10px 28px 28px;
  width: 100%;
  box-sizing: border-box;
}

.minimal-dashboard {
  max-width: none;
  width: 100%;
  box-sizing: border-box;
}

.minimal-kpi-row {
  grid-template-columns: repeat(4,minmax(180px,1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.minimal-kpi {
  min-height: 82px;
  padding: 15px 18px;
  border-radius: 9px;
}

.minimal-kpi .kpi-icon {
  width: 44px;
  height: 44px;
  border-radius: 9px;
}

.minimal-kpi strong {
  font-size: 26px;
}

.minimal-grid {
  grid-template-columns: minmax(0,1.05fr) minmax(360px,.75fr);
  gap: 16px;
  margin-bottom: 0;
}

.minimal-card,.card.minimal-card {
  padding: 18px;
  border-radius: 9px;
}

.minimal-card-head {
  margin-bottom: 10px;
}

.minimal-card-head h2 {
  font-size: 17px;
}

.minimal-card-head p {
  font-size: 12px;
}

.clean-table th {
  padding: 11px 9px;
  font-size: 11px;
}

.clean-table td {
  padding: 12px 9px;
  font-size: 13px;
}

.status-row {
  padding: 9px 0;
  grid-template-columns: 38px 1fr auto;
}

.status-avatar {
  width: 32px;
  height: 32px;
}

.pill {
  min-height: 24px;
  font-size: 11px;
  padding: 3px 9px;
}

.clickable-row {
  cursor: pointer;
}

.clickable-row:hover {
  background: #f8fbff;
}

.dept-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.dept-link:hover b {
  color: var(--v9-blue);
}

.report-card {
  display: none !important;
}

.card,.panel,.hero-card,.action-card,.table-wrap {
  border-radius: 9px;
}

.page-head {
  padding: 28px 28px 14px;
}

.page-head h1 {
  font-size: 28px;
}

.page-head p {
  font-size: 14px;
}

.card {
  padding: 18px;
}

.card-head h2,.panel h2,.hero-card h2 {
  font-size: 17px;
}

th,td {
  padding: 11px 9px;
}

.distribution-card {
  padding: 14px;
  border-radius: 9px;
}

.dept-card {
  scroll-margin-top: 18px;
}

.dept-card[open] {
  border-color: #bfdbfe;
  background: #fbfdff;
}

@media (max-width:1180px) {
  .minimal-grid {
    grid-template-columns: 1fr;
  }
  .minimal-kpi-row {
    grid-template-columns: repeat(2,1fr);
  }
}

@media (max-width:860px) {
  .minimal-shell {
    grid-template-columns: 1fr;
  }
  .minimal-sidebar {
    width: auto;
    height: auto;
    position: relative;
  }
  .minimal-page-head,.full-width {
    padding-left: 16px;
    padding-right: 16px;
  }
  .minimal-kpi-row {
    grid-template-columns: 1fr;
  }
  .minimal-grid {
    gap: 14px;
  }
}

.runs-page {
  padding-top: 8px;
}

.runs-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4,minmax(180px,1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.run-kpi-card {
  min-height: 86px;
  border-radius: 9px;
  padding: 16px 18px;
  box-shadow: var(--v9-shadow);
}

.run-kpi-card .kpi-icon {
  width: 46px;
  height: 46px;
  border-radius: 9px;
}

.run-kpi-card .kpi-icon svg {
  width: 23px;
  height: 23px;
}

.run-kpi-card strong {
  font-size: 26px;
}

.run-kpi-card .small-strong {
  font-size: 18px;
  line-height: 1.2;
}

.kpi-icon.red {
  background: var(--v9-red-soft);
  color: var(--v9-red);
}

.runs-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding: 16px 18px;
}

.run-actions-tabs {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  overflow: hidden;
  background: #fff;
}

.run-actions-tabs form {
  margin: 0;
}

.run-tab {
  height: 42px;
  border: 0;
  border-right: 1px solid var(--v9-border);
  background: #fff;
  color: #273957;
  font-weight: 750;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.run-actions-tabs form:last-child .run-tab {
  border-right: 0;
}

.run-tab svg {
  width: 17px;
  height: 17px;
}

.run-tab:hover {
  background: #f8fbff;
}

.run-tab.is-primary {
  background: linear-gradient(135deg,#3f72ff,#2452db);
  color: #fff;
  box-shadow: 0 10px 18px rgba(47,107,255,.18);
}

.runs-filter {
  display: flex;
  align-items: end;
  gap: 12px;
  flex-wrap: wrap;
}

.runs-filter label {
  display: grid;
  gap: 6px;
  min-width: 154px;
}

.runs-filter label span {
  font-size: 12px;
  color: var(--v9-muted);
  font-weight: 800;
}

.runs-filter select {
  height: 42px;
  border-radius: 9px;
  padding: 8px 34px 8px 12px;
}

.runs-table-card {
  padding: 18px;
  margin-bottom: 18px;
}

.runs-table th {
  font-size: 11px;
  text-transform: none;
  letter-spacing: 0;
  color: #71809c;
}

.runs-table td {
  vertical-align: middle;
}

.run-type-cell {
  display: flex;
  gap: 12px;
  align-items: center;
  min-width: 250px;
}

.run-type-cell strong {
  display: block;
  font-size: 14px;
}

.run-type-cell small {
  display: block;
  color: var(--v9-muted);
  font-size: 12px;
  margin-top: 2px;
}

.run-type-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.run-type-icon svg {
  width: 19px;
  height: 19px;
}

.blue-soft {
  background: var(--v9-blue-soft);
  color: var(--v9-blue);
}

.green-soft {
  background: var(--v9-green-soft);
  color: var(--v9-green);
}

.purple-soft {
  background: var(--v9-purple-soft);
  color: var(--v9-purple);
}

.orange-soft {
  background: var(--v9-yellow-soft);
  color: var(--v9-yellow);
}

.cyan-soft {
  background: #ecfeff;
  color: #0891b2;
}

.red-soft {
  background: var(--v9-red-soft);
  color: var(--v9-red);
}

.align-right {
  text-align: right;
}

.row-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
}

.mini-btn {
  min-height: 32px;
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  background: #f8fbff;
  color: #1b2d4a;
  text-decoration: none;
  font-weight: 750;
  font-size: 13px;
  padding: 7px 11px;
  display: inline-flex;
  align-items: center;
}

.mini-btn:hover {
  background: #eff6ff;
  border-color: #c8d8f0;
}

.mini-btn.ghost {
  background: #fff;
}

.empty-row {
  text-align: center;
  padding: 32px !important;
}

.run-help-card {
  padding: 18px;
}

.run-help-card h2 {
  font-size: 17px;
  margin: 0 0 14px;
}

.run-help-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 14px;
}

.run-help-grid div {
  display: grid;
  grid-template-columns: 40px 1fr;
  grid-template-rows: auto auto;
  gap: 2px 12px;
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  padding: 13px;
  background: #fff;
}

.run-help-grid svg {
  grid-row: 1/3;
  width: 22px;
  height: 22px;
  color: var(--v9-blue);
  align-self: center;
}

.run-help-grid strong {
  font-size: 14px;
}

.run-help-grid span {
  font-size: 12px;
  color: var(--v9-muted);
}

.run-detail-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.run-detail-title {
  display: flex;
  align-items: center;
  gap: 14px;
}

.run-detail-title .run-type-icon {
  width: 52px;
  height: 52px;
  border-radius: 9px;
}

.run-detail-title .run-type-icon svg {
  width: 25px;
  height: 25px;
}

.run-detail-hero h2 {
  font-size: 21px;
  margin: 3px 0 4px;
}

.run-detail-hero p {
  margin: 0;
  color: var(--v9-muted);
}

.success-soft-bg {
  background: linear-gradient(135deg,#fff 0%,#f0fdf4 100%);
}

.running-soft-bg {
  background: linear-gradient(135deg,#fff 0%,#eff6ff 68%,#ecfeff 100%);
}

.error-soft-bg {
  background: linear-gradient(135deg,#fff 0%,#fef2f2 100%);
}

.detail-kpis {
  margin-bottom: 18px;
}

.compact-progress-card {
  padding: 16px 18px;
  margin-bottom: 18px;
}

.compact-progress-card .progress-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.compact-progress-card .progress-title svg {
  width: 18px;
  height: 18px;
  color: var(--v9-blue);
  animation: spin 1s linear infinite;
}

.compact-progress-card p {
  margin: 10px 0 0;
}

.important-lines-card {
  margin-bottom: 18px;
}

.compact-head {
  margin-bottom: 12px;
}

.compact-head h2 {
  font-size: 17px;
}

.compact-head p {
  font-size: 12px;
}

.compact-friendly-log {
  gap: 7px;
}

.compact-friendly-log div {
  font-size: 12px;
  border-left-width: 3px;
  padding: 9px 11px;
}

.compact-log-card summary {
  display: flex;
  align-items: center;
  gap: 8px;
}

.compact-log-card summary svg {
  width: 18px;
  height: 18px;
}

.compact-log-card pre {
  max-height: 460px;
  font-size: 12px;
}

.accent-number {
  color: #ea580c;
  font-weight: 850;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width:1180px) {
  .runs-kpi-grid {
    grid-template-columns: repeat(2,1fr);
  }
  .runs-toolbar {
    align-items: stretch;
    flex-direction: column;
  }
  .runs-filter {
    justify-content: flex-start;
  }
  .run-actions-tabs {
    width: max-content;
    max-width: 100%;
  }
}

@media (max-width:760px) {
  .runs-kpi-grid {
    grid-template-columns: 1fr;
  }
  .run-actions-tabs {
    display: grid;
    width: 100%;
    border-radius: 9px;
  }
  .run-tab {
    width: 100%;
    justify-content: flex-start;
    border-right: 0;
    border-bottom: 1px solid var(--v9-border);
  }
  .run-actions-tabs form:last-child .run-tab {
    border-bottom: 0;
  }
  .runs-filter label {
    min-width: 100%;
    width: 100%;
  }
  .run-help-grid {
    grid-template-columns: 1fr;
  }
  .run-detail-hero {
    align-items: flex-start;
    flex-direction: column;
  }
  .row-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
  }
  .align-right {
    text-align: left;
  }
  .run-type-cell {
    min-width: 220px;
  }
}

.stats-page,.stats-detail-page {
  padding-top: 8px;
}

.stats-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4,minmax(180px,1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.stat-kpi {
  min-height: 86px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px 18px;
  border-radius: 9px;
}

.stat-kpi .kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.stat-kpi .kpi-icon svg {
  width: 23px;
  height: 23px;
}

.stat-kpi span {
  display: block;
  color: var(--v9-muted);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.stat-kpi strong {
  display: block;
  font-size: 28px;
  line-height: 1;
  color: var(--v9-text);
}

.stats-top-grid {
  display: grid;
  grid-template-columns: minmax(0,1.2fr) minmax(360px,.85fr);
  gap: 16px;
  margin-bottom: 18px;
}

.stats-mid-grid {
  display: grid;
  grid-template-columns: minmax(0,1.05fr) minmax(360px,.75fr);
  gap: 16px;
  margin-bottom: 18px;
}

.stats-chart-card,.stats-donut-card {
  padding: 20px;
}

.soft-select {
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 12px;
  color: #667792;
  background: #fff;
}

.simple-line-chart {
  height: 220px;
  padding: 18px 8px 4px;
  display: flex;
  align-items: end;
  gap: 20px;
  border-bottom: 1px solid var(--v9-border);
  background: linear-gradient(to bottom,transparent 0,transparent 24%,rgba(226,232,240,.65) 25%,transparent 26%,transparent 49%,rgba(226,232,240,.65) 50%,transparent 51%,transparent 74%,rgba(226,232,240,.65) 75%,transparent 76%);
}

.line-point {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 38px;
}

.line-point b {
  font-size: 12px;
  color: #102046;
}

.line-point span {
  width: 100%;
  max-width: 42px;
  height: var(--h);
  min-height: 6px;
  border-radius: 9px;
  background: linear-gradient(180deg,#3472ff,#79a7ff);
  box-shadow: 0 10px 24px rgba(47,107,255,.16);
}

.line-point small {
  font-size: 11px;
  color: var(--v9-muted);
  white-space: nowrap;
}

.donut-layout {
  display: grid;
  grid-template-columns: 190px 1fr;
  align-items: center;
  gap: 20px;
  min-height: 220px;
}

.css-donut {
  --a: 42%;
  --b: 31%;
  --c: 16%;
  width: 164px;
  height: 164px;
  border-radius: 9px;
  background: conic-gradient(#3472ff 0 var(--a),#ff9f1a var(--a) calc(var(--a) + var(--b)),#8b5cf6 calc(var(--a) + var(--b)) calc(var(--a) + var(--b) + var(--c)),#22a35a 0);
  position: relative;
  display: grid;
  place-items: center;
}

.css-donut:after {
  content: "";
  position: absolute;
  inset: 42px;
  background: #fff;
  border-radius: 9px;
  box-shadow: inset 0 0 0 1px var(--v9-border);
}

.css-donut strong,.css-donut small {
  position: relative;
  z-index: 1;
  text-align: center;
}

.css-donut strong {
  display: block;
  font-size: 28px;
  color: var(--v9-text);
  line-height: 1;
}

.css-donut small {
  display: block;
  margin-top: 30px;
  color: var(--v9-muted);
  font-weight: 700;
}

.legend-list {
  display: grid;
  gap: 14px;
}

.legend-list div,.status-bar-row,.reason-row {
  display: grid;
  grid-template-columns: minmax(160px,1fr) minmax(140px,220px) 82px;
  align-items: center;
  gap: 16px;
}

.legend-list b,.bar-label b {
  font-size: 13px;
  color: #243553;
}

.legend-list em,.status-bar-row em,.reason-row em {
  font-style: normal;
  text-align: right;
  color: #52627b;
  font-weight: 750;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 9px;
  display: inline-block;
}

.dot.blue {
  background: #3472ff;
}

.dot.orange {
  background: #ff9f1a;
}

.dot.purple {
  background: #8b5cf6;
}

.dot.green {
  background: #22a35a;
}

.dot.yellow {
  background: #f59e0b;
}

.dot.red {
  background: #ef4444;
}

.dot.gray {
  background: #94a3b8;
}

.bar-label {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bar-track {
  height: 7px;
  background: #e9eef6;
  border-radius: 9px;
  overflow: hidden;
}

.bar-track span {
  display: block;
  height: 100%;
  border-radius: 9px;
}

.bar-track .blue {
  background: #3472ff;
}

.bar-track .orange {
  background: #ff9f1a;
}

.bar-track .purple {
  background: #8b5cf6;
}

.bar-track .green {
  background: #22a35a;
}

.bar-track .gray {
  background: #94a3b8;
}

.status-bars,.reason-bars {
  display: grid;
  gap: 20px;
  padding: 6px 0;
}

.stats-table .chev {
  text-align: right;
  color: #71809c;
}

.stats-table .chev svg {
  width: 17px;
  height: 17px;
}

.score-link {
  color: var(--v9-blue);
  font-weight: 850;
}

.reports-card {
  padding: 20px;
}

.reports-table td svg {
  width: 15px;
  height: 15px;
  vertical-align: -3px;
  margin-right: 8px;
}

.reports-table .mini-btn svg {
  margin-left: 5px;
  margin-right: 0;
  width: 14px;
  height: 14px;
}

.report-main-grid {
  display: grid;
  grid-template-columns: minmax(0,1.05fr) minmax(360px,.75fr);
  gap: 16px;
  margin-bottom: 18px;
}

.side-stack {
  display: grid;
  gap: 16px;
  align-content: start;
}

.dept-detail-box {
  margin-top: 12px;
  border: 1px solid var(--v9-border);
  background: #fbfdff;
  border-radius: 9px;
  padding: 12px;
}

.detail-box-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.detail-box-head h3 {
  font-size: 15px;
  margin: 0;
}

.soft-icon {
  width: 28px;
  height: 28px;
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: #fff;
  color: #52627b;
}

.soft-icon svg {
  width: 16px;
  height: 16px;
}

.compact-table th,.compact-table td {
  padding: 9px 12px;
}

.clickable-row.is-selected {
  background: #f4f8ff;
}

.params-list {
  display: grid;
}

.params-list div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  padding: 11px 0;
  border-bottom: 1px solid var(--v9-border);
}

.params-list div:last-child {
  border-bottom: 0;
}

.params-list span {
  color: var(--v9-muted);
  font-weight: 700;
}

.params-list b {
  font-weight: 800;
  color: #263753;
  text-align: right;
}

.problem-leads-card {
  padding: 20px;
}

.pill.danger {
  background: #fee2e2;
  color: #b91c1c;
}

.pill.warning {
  background: #eaf2ff;
  color: #2563eb;
}

.pill.success {
  background: #dcfce7;
  color: #166534;
}

@media (max-width:1180px) {
  .stats-kpi-grid {
    grid-template-columns: repeat(2,1fr);
  }
  .stats-top-grid,.stats-mid-grid,.report-main-grid {
    grid-template-columns: 1fr;
  }
  .donut-layout {
    grid-template-columns: 170px 1fr;
  }
  .simple-line-chart {
    gap: 10px;
  }
}

@media (max-width:760px) {
  .stats-kpi-grid {
    grid-template-columns: 1fr;
  }
  .donut-layout {
    grid-template-columns: 1fr;
    justify-items: center;
  }
  .legend-list div,.status-bar-row,.reason-row {
    grid-template-columns: 1fr;
  }
  .legend-list em,.status-bar-row em,.reason-row em {
    text-align: left;
  }
  .params-list div {
    grid-template-columns: 1fr;
  }
  .params-list b {
    text-align: left;
  }
  .simple-line-chart {
    overflow-x: auto;
    justify-content: flex-start;
  }
  .line-point {
    flex: 0 0 56px;
  }
}

.stats-status-only {
  margin-top: 16px;
}

.compact-status-bars {
  max-width: 900px;
}

.stats-detail-page .side-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.stats-page .reports-card {
  margin-top: 0;
}

.report-main-grid {
  grid-template-columns: 1fr;
}

.compact-dept-table th:nth-child(2),.compact-dept-table td:nth-child(2) {
  text-align: center;
  width: 180px;
}

.employee-table td small {
  display: block;
  margin-top: 3px;
  color: var(--v9-muted);
  font-size: 11px;
  font-weight: 700;
}

.manager-leads-card {
  margin-top: 18px;
  padding: 20px;
}

.manager-leads-card .minimal-card-head {
  align-items: flex-start;
}

.lead-card-list {
  display: grid;
  gap: 12px;
}

.bad-lead-card {
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  background: #fff;
  padding: 14px;
}

.bad-lead-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
}

.lead-title {
  color: var(--v9-text);
  font-weight: 850;
  text-decoration: none;
}

.lead-title:hover {
  color: var(--v9-blue);
}

.reason-list-full {
  display: grid;
  gap: 8px;
}

.reason-list-full div {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid #edf2f7;
  border-radius: 9px;
  padding: 9px 10px;
  color: #334155;
  font-size: 13px;
  line-height: 1.35;
}

.reason-list-full svg {
  width: 15px;
  height: 15px;
  color: #f59e0b;
  flex: 0 0 auto;
  margin-top: 1px;
}

.empty-manager-state {
  display: flex;
  gap: 14px;
  align-items: center;
  background: #fbfdff;
}

.empty-manager-state>svg {
  width: 32px;
  height: 32px;
  color: var(--v9-blue);
}

.ux-report-page {
  padding-top: 6px;
}

.compact-kpis {
  gap: 12px;
  margin-bottom: 14px;
}

.compact-kpis .stat-kpi {
  min-height: 74px;
  padding: 13px 15px;
}

.compact-kpis .stat-kpi .kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 9px;
}

.compact-kpis .stat-kpi strong {
  font-size: 24px;
}

.report-workspace {
  display: grid;
  grid-template-columns: 340px minmax(0,1fr);
  gap: 14px;
  align-items: start;
}

.report-sidebar-card {
  padding: 16px;
  position: sticky;
  top: 18px;
}

.tight-head {
  margin-bottom: 10px;
}

.tight-head h2 {
  margin: 0;
  font-size: 17px;
}

.tight-head p {
  margin: 4px 0 0;
}

.department-list {
  display: grid;
  gap: 8px;
}

.department-item {
  display: block;
  text-decoration: none;
  color: var(--v9-text);
  border: 1px solid var(--v9-border);
  background: #fff;
  border-radius: 9px;
  padding: 12px;
  transition: .15s ease;
}

.department-item:hover {
  border-color: #b7c8f5;
  box-shadow: 0 8px 20px rgba(15,35,70,.06);
  transform: translateY(-1px);
}

.department-item.active {
  background: #f4f8ff;
  border-color: #3472ff;
  box-shadow: 0 0 0 3px rgba(52,114,255,.08);
}

.department-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.department-title-row strong {
  font-size: 14px;
  line-height: 1.25;
}

.department-title-row svg {
  width: 16px;
  height: 16px;
  color: #72809b;
  flex: 0 0 auto;
}

.department-metrics-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.department-metrics-row span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 7px;
  border-radius: 9px;
  background: #f1f5f9;
  color: #58677f;
  font-size: 11px;
  font-weight: 750;
}

.department-metrics-row b {
  color: #0f1f3c;
}

.report-detail-area {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.dept-overview-card {
  padding: 16px;
}

.dept-overview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.eyebrow {
  margin: 0 0 5px;
  color: #71809c;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-size: 11px;
  font-weight: 850;
}

.dept-overview-head h2,.manager-panel-head h2 {
  margin: 0;
  font-size: 20px;
}

.dept-summary-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.dept-summary-pills span {
  padding: 7px 10px;
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  background: #fff;
  color: #58677f;
  font-size: 12px;
  font-weight: 750;
}

.dept-summary-pills b {
  color: #0f1f3c;
}

.report-drilldown-grid {
  display: grid;
  grid-template-columns: minmax(330px,.62fr) minmax(0,1.38fr);
  gap: 14px;
  align-items: start;
}

.employees-panel,.leads-panel {
  padding: 16px;
}

.employee-list-cards {
  display: grid;
  gap: 8px;
}

.employee-item {
  display: grid;
  grid-template-columns: 38px minmax(0,1fr) 52px 46px;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--v9-text);
  border: 1px solid var(--v9-border);
  border-radius: 9px;
  background: #fff;
  padding: 10px;
  transition: .15s ease;
}

.employee-item:hover {
  border-color: #b7c8f5;
  background: #fbfdff;
}

.employee-item.active {
  background: #f4f8ff;
  border-color: #3472ff;
  box-shadow: 0 0 0 3px rgba(52,114,255,.08);
}

.employee-avatar {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg,#eaf2ff,#f3e8ff);
  color: #2f6bff;
  font-weight: 900;
}

.employee-main {
  min-width: 0;
}

.employee-main strong {
  display: block;
  font-size: 13px;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.employee-main small {
  display: block;
  margin-top: 3px;
  color: #71809c;
  font-size: 11px;
  font-weight: 750;
}

.employee-stats-mini {
  text-align: center;
}

.employee-stats-mini .lead-count {
  display: block;
  font-size: 16px;
  font-weight: 900;
  color: #ff5a00;
  line-height: 1;
}

.employee-stats-mini small {
  display: block;
  margin-top: 2px;
  color: #71809c;
  font-size: 10px;
  font-weight: 750;
}

.score-chip {
  height: 30px;
  min-width: 40px;
  border-radius: 9px;
  display: inline-grid;
  place-items: center;
  font-size: 12px;
  font-weight: 900;
}

.score-chip.bad {
  background: #fee2e2;
  color: #b91c1c;
}

.score-chip.warn {
  background: #fff1d6;
  color: #c45a00;
}

.score-chip.ok {
  background: #dcfce7;
  color: #166534;
}

.manager-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.manager-panel-head p.muted {
  margin: 5px 0 0;
}

.compact-lead-list {
  max-height: 680px;
  overflow: auto;
  padding-right: 3px;
}

.improved-lead-card {
  padding: 12px;
  border-radius: 9px;
  background: #fff;
}

.improved-lead-card+.improved-lead-card {
  margin-top: 0;
}

.compact-reasons {
  gap: 6px;
}

.compact-reasons div {
  padding: 8px 9px;
  font-size: 12.5px;
  background: #f8fafc;
}

.bad-lead-main {
  margin-bottom: 9px;
}

.bad-lead-main .lead-title {
  font-size: 14px;
}

.empty-small {
  border: 1px dashed var(--v9-border);
  border-radius: 9px;
  padding: 14px;
  color: #71809c;
  font-weight: 750;
  text-align: center;
}

.empty-state-clean {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #71809c;
  padding: 28px;
}

.empty-state-clean.tall {
  min-height: 420px;
}

.empty-state-clean svg {
  width: 42px;
  height: 42px;
  color: #3472ff;
  margin-bottom: 12px;
}

.empty-state-clean h3 {
  margin: 0 0 6px;
  color: var(--v9-text);
  font-size: 18px;
}

.empty-state-clean p {
  max-width: 420px;
  margin: 0;
  line-height: 1.45;
}

@media (max-width:1180px) {
  .report-workspace {
    grid-template-columns: 1fr;
  }
  .report-sidebar-card {
    position: static;
  }
  .report-drilldown-grid {
    grid-template-columns: 1fr;
  }
  .compact-lead-list {
    max-height: none;
  }
}

@media (max-width:760px) {
  .dept-overview-head,.manager-panel-head {
    display: block;
  }
  .dept-summary-pills {
    justify-content: flex-start;
    margin-top: 12px;
  }
  .employee-item {
    grid-template-columns: 36px minmax(0,1fr) 48px;
  }
  .employee-item .score-chip {
    grid-column: 2 / span 2;
    justify-self: start;
  }
  .stats-kpi-grid.compact-kpis {
    grid-template-columns: 1fr 1fr;
  }
  .report-sidebar-card,.employees-panel,.leads-panel,.dept-overview-card {
    padding: 13px;
  }
}

.human-report-page {
  padding-top: 4px;
}

.human-card {
  border-radius: 9px;
}

.human-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.human-card-head h2 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -.02em;
}

.human-card-head p {
  margin: 4px 0 0;
  color: #667594;
  font-size: 13px;
}

.human-card-head.compact-head {
  margin-bottom: 12px;
}

.dept-summary-card {
  padding: 18px;
  margin-bottom: 14px;
}

.dept-summary-grid {
  display: grid;
  grid-template-columns: repeat(4,minmax(220px,1fr));
  gap: 10px;
}

.dept-summary-tile {
  display: block;
  color: var(--v9-text);
  text-decoration: none;
  border: 1px solid #e1e8f2;
  background: #fff;
  border-radius: 9px;
  padding: 14px;
  transition: .15s ease;
}

.dept-summary-tile:hover {
  border-color: #b8c9f5;
  background: #fbfdff;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(15,35,70,.07);
}

.dept-summary-tile.active {
  border-color: #3472ff;
  background: #f4f8ff;
  box-shadow: 0 0 0 3px rgba(52,114,255,.08);
}

.dept-summary-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.dept-summary-main strong {
  font-size: 15px;
  line-height: 1.25;
}

.dept-summary-main svg {
  width: 16px;
  height: 16px;
  color: #71809c;
}

.dept-summary-stats {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 7px;
}

.dept-summary-stats span {
  background: #f5f8fc;
  border: 1px solid #edf2f7;
  border-radius: 9px;
  padding: 8px 7px;
}

.dept-summary-stats b {
  display: block;
  font-size: 16px;
  line-height: 1;
  color: #0f1f3c;
}

.dept-summary-stats small {
  display: block;
  margin-top: 4px;
  color: #667594;
  font-size: 10.5px;
  font-weight: 750;
  line-height: 1.15;
}

.human-drilldown-grid {
  display: grid;
  grid-template-columns: minmax(360px,.55fr) minmax(0,1.45fr);
  gap: 14px;
  align-items: start;
}

.managers-list-card {
  padding: 16px;
  position: sticky;
  top: 92px;
}

.human-manager-list {
  display: grid;
  gap: 8px;
}

.human-manager-row {
  display: grid;
  grid-template-columns: 42px minmax(0,1fr) 58px 62px;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 9px;
  border: 1px solid #e1e8f2;
  background: #fff;
  color: var(--v9-text);
  text-decoration: none;
  transition: .15s ease;
}

.human-manager-row:hover {
  border-color: #b8c9f5;
  background: #fbfdff;
}

.human-manager-row.active {
  border-color: #3472ff;
  background: #f4f8ff;
  box-shadow: 0 0 0 3px rgba(52,114,255,.08);
}

.human-avatar {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg,#eaf2ff,#f3e8ff);
  color: #2f6bff;
  font-weight: 900;
}

.human-manager-name {
  min-width: 0;
}

.human-manager-name strong {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 14px;
  line-height: 1.2;
}

.human-manager-name small {
  display: block;
  margin-top: 4px;
  color: #71809c;
  font-size: 11px;
  font-weight: 750;
}

.human-manager-metric {
  text-align: center;
}

.human-manager-metric b {
  display: block;
  color: #ff5a00;
  font-size: 18px;
  line-height: 1;
}

.human-manager-metric small {
  display: block;
  color: #71809c;
  font-size: 10.5px;
  font-weight: 800;
  margin-top: 2px;
}

.human-rating {
  height: 42px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  align-content: center;
}

.human-rating span {
  font-weight: 900;
  line-height: 1;
  font-size: 15px;
}

.human-rating small {
  font-size: 9.5px;
  font-weight: 800;
  margin-top: 3px;
}

.human-rating.bad {
  background: #fee2e2;
  color: #b91c1c;
}

.human-rating.warn {
  background: #fff1d6;
  color: #c45a00;
}

.human-rating.ok {
  background: #dcfce7;
  color: #166534;
}

.leads-review-card {
  padding: 16px;
}

.leads-review-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 12px;
}

.leads-review-head h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -.02em;
}

.leads-review-head p {
  margin: 5px 0 0;
  color: #667594;
  font-size: 13px;
}

.human-lead-list {
  display: grid;
  gap: 10px;
}

.human-lead-card {
  border: 1px solid #dfe7f2;
  background: #fff;
  border-radius: 9px;
  padding: 14px;
}

.human-lead-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
}

.human-lead-title-wrap {
  min-width: 0;
}

.human-lead-title {
  font-weight: 900;
  color: #0f1f3c;
  text-decoration: none;
  font-size: 15px;
  line-height: 1.25;
}

.human-lead-title:hover {
  color: #2f6bff;
}

.human-lead-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
  color: #667594;
  font-size: 12px;
  font-weight: 750;
}

.severity-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 9px;
  padding: 5px 9px;
  font-size: 11px;
  font-weight: 900;
}

.severity-pill.critical {
  background: #fee2e2;
  color: #b91c1c;
}

.severity-pill.high {
  background: #fff1d6;
  color: #c45a00;
}

.severity-pill.medium {
  background: #eaf2ff;
  color: #1f55da;
}

.severity-pill.low {
  background: #ecfdf5;
  color: #15803d;
}

.human-reasons {
  display: grid;
  gap: 6px;
}

.human-reasons-title {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #31425f;
  font-weight: 900;
  font-size: 12px;
  margin-bottom: 2px;
}

.human-reasons-title svg {
  width: 15px;
  height: 15px;
  color: #2f6bff;
}

.human-reason-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  background: #f8fafc;
  border: 1px solid #edf2f7;
  border-radius: 9px;
  padding: 9px 10px;
  color: #283952;
  font-size: 13px;
  line-height: 1.35;
}

.human-reason-row svg {
  width: 15px;
  height: 15px;
  color: #f59e0b;
  flex: 0 0 auto;
  margin-top: 1px;
}

.human-lead-top .mini-btn {
  white-space: nowrap;
}

.human-report-page .compact-kpis {
  margin-bottom: 14px;
}

@media (max-width:1380px) {
  .dept-summary-grid {
    grid-template-columns: repeat(2,minmax(220px,1fr));
  }
  .human-drilldown-grid {
    grid-template-columns: 1fr;
  }
  .managers-list-card {
    position: static;
  }
  .human-manager-list {
    grid-template-columns: repeat(2,minmax(280px,1fr));
  }
}

@media (max-width:820px) {
  .dept-summary-grid,.human-manager-list {
    grid-template-columns: 1fr;
  }
  .human-drilldown-grid {
    grid-template-columns: 1fr;
  }
  .human-lead-top,.leads-review-head {
    display: block;
  }
  .human-lead-top .mini-btn {
    margin-top: 10px;
  }
  .dept-summary-stats {
    grid-template-columns: 1fr 1fr 1fr;
  }
  .human-manager-row {
    grid-template-columns: 42px minmax(0,1fr) 54px;
  }
  .human-rating {
    grid-column: 2 / span 2;
    justify-self: start;
    min-width: 62px;
  }
  .stats-kpi-grid.compact-kpis {
    grid-template-columns: 1fr;
  }
}

body {
  font-weight: 400;
  color: #14213a;
}

.brand b {
  font-weight: 700;
}

.brand small {
  font-weight: 400;
}

.side-nav a {
  font-weight: 600;
}

.side-nav a.active {
  font-weight: 650;
}

.side-nav a em {
  font-weight: inherit;
}

.user-text b,.side-help b {
  font-weight: 600;
}

.page-head h1 {
  font-weight: 700;
  letter-spacing: -.025em;
}

.page-head p {
  font-weight: 400;
}

.card-head h2,.panel h2,.hero-card h2,.human-card-head h2,.leads-review-head h2,.dept-overview-head h2,.manager-panel-head h2 {
  font-weight: 650;
  letter-spacing: -.015em;
}

.eyebrow {
  font-weight: 650;
  letter-spacing: .07em;
}

.btn,.link-btn {
  font-weight: 600;
}

.badge,.status-pill {
  font-weight: 600;
}

.table-actions .mini-btn,.mini-btn {
  font-weight: 600;
}

th {
  font-weight: 650;
  color: #687897;
  letter-spacing: .035em;
}

td {
  font-weight: 400;
}

tbody tr strong,td strong {
  font-weight: 600;
}

.kpi-card span {
  font-weight: 400;
}

.kpi-card strong {
  font-weight: 650;
  letter-spacing: -.025em;
}

.kpi-icon {
  font-weight: 600;
}

.delta {
  font-weight: 600;
}

.dept-summary-main strong {
  font-weight: 600;
}

.dept-summary-stats b {
  font-weight: 650;
}

.dept-summary-stats small {
  font-weight: 500;
}

.dept-summary-stats span {
  font-weight: 400;
}

.human-manager-name strong {
  font-weight: 600;
}

.human-manager-name small {
  font-weight: 500;
}

.human-manager-metric b {
  font-weight: 650;
}

.human-manager-metric small {
  font-weight: 500;
}

.human-rating span {
  font-weight: 650;
}

.human-rating small {
  font-weight: 500;
}

.human-avatar {
  font-weight: 600;
}

.human-lead-title {
  font-weight: 600;
}

.human-lead-meta {
  font-weight: 500;
}

.severity-pill {
  font-weight: 600;
}

.human-reasons-title {
  font-weight: 600;
}

.human-reason-row {
  font-weight: 400;
  color: #334155;
}

.human-lead-card {
  box-shadow: none;
}

.employee-main strong,.department-title-row strong,.run-title,.report-title {
  font-weight: 600;
}

.employee-main small,.department-metrics-row span,.employee-stats-mini small {
  font-weight: 500;
}

.score-chip {
  font-weight: 650;
}

.settings-form label,.form-label {
  font-weight: 600;
}

.setting-description,.help-text,.muted {
  font-weight: 400;
}

.quick-action b,.action-card h2 {
  font-weight: 600;
}

.quick-action small,.action-card p {
  font-weight: 400;
}

/* Slightly quieter numbers in report cards */

.stats-kpi-grid .kpi-card strong,.compact-kpis .kpi-card strong {
  font-size: 26px;
  font-weight: 650;
}

/* Remove excessive visual pressure in selected rows */

.human-manager-row.active,.dept-summary-tile.active {
  box-shadow: 0 0 0 2px rgba(52,114,255,.07);
}

.distribution-page {
  display: grid;
  gap: 14px;
}

.distribution-kpis {
  grid-template-columns: repeat(3,minmax(220px,1fr));
  margin-bottom: 0;
}

.notice-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 9px;
  padding: 12px 14px;
  border: 1px solid #dfe7f2;
  background: #fff;
  font-size: 14px;
}

.notice-banner svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.notice-banner.success {
  background: #ecfdf5;
  border-color: #bbf7d0;
  color: #166534;
}

.notice-banner.danger {
  background: #fef2f2;
  border-color: #fecaca;
  color: #991b1b;
}

.distribution-manual-card {
  padding: 18px;
}

.manual-remove-form {
  display: grid;
  grid-template-columns: minmax(360px,1fr) minmax(260px,.8fr) auto;
  gap: 12px;
  align-items: end;
}

.manual-remove-form label {
  display: grid;
  gap: 6px;
  color: #667594;
  font-size: 12px;
}

.manual-remove-form label span {
  font-weight: 500;
}

.manual-remove-form select,.manual-remove-form input {
  height: 42px;
  border: 1px solid #dfe7f2;
  border-radius: 9px;
  background: #fff;
  color: #0f1f3c;
  padding: 0 12px;
  font: inherit;
  font-size: 14px;
}

.manual-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.removal-list {
  display: grid;
  gap: 10px;
}

.removal-item {
  border: 1px solid #dfe7f2;
  background: #fff;
  border-radius: 9px;
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 12px;
  align-items: start;
}

.removal-main {
  display: grid;
  grid-template-columns: 42px minmax(0,1fr);
  gap: 12px;
}

.removal-avatar {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  background: #fff1d6;
  color: #c45a00;
  display: grid;
  place-items: center;
}

.removal-avatar svg {
  width: 20px;
  height: 20px;
}

.removal-item h3 {
  margin: 0 0 5px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -.01em;
}

.removal-item p {
  margin: 0;
  color: #42516b;
  font-size: 13.5px;
  line-height: 1.4;
}

.removal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.removal-meta span {
  background: #f5f8fc;
  border: 1px solid #edf2f7;
  border-radius: 9px;
  padding: 5px 8px;
  color: #667594;
  font-size: 11.5px;
}

.removal-state {
  display: grid;
  justify-items: end;
  gap: 5px;
}

.removal-state small {
  color: #71809c;
  font-size: 11.5px;
}

.tech-details {
  grid-column: 1 / -1;
  margin-top: 2px;
}

.tech-details summary {
  cursor: pointer;
  color: #667594;
  font-size: 12.5px;
}

.compact-json {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 10px;
  margin-top: 10px;
}

.compact-json>div {
  border: 1px solid #edf2f7;
  background: #f8fafc;
  border-radius: 9px;
  padding: 10px;
  min-width: 0;
}

.compact-json b {
  display: block;
  margin-bottom: 6px;
  color: #42516b;
  font-size: 12px;
  font-weight: 600;
}

.compact-json pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 220px;
  overflow: auto;
  color: #42516b;
  font-size: 12px;
}

.btn.danger {
  background: #fff;
  border-color: #fecaca;
  color: #b91c1c;
}

.btn.danger:hover {
  background: #fef2f2;
}

@media (max-width:1180px) {
  .manual-remove-form {
    grid-template-columns: 1fr;
  }
  .manual-actions {
    justify-content: flex-start;
  }
  .distribution-kpis {
    grid-template-columns: 1fr;
  }
  .removal-item {
    grid-template-columns: 1fr;
  }
  .removal-state {
    justify-items: start;
  }
  .compact-json {
    grid-template-columns: 1fr;
  }
}

.distribution-page {
  gap: 12px;
}

.distribution-manual-card {
  padding: 16px;
}

.distribution-manual-card .human-card-head {
  margin-bottom: 12px;
}

.distribution-manual-card .human-card-head p {
  max-width: 860px;
}

.removal-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 5px;
}

.removal-title-row h3 {
  margin: 0;
  font-weight: 520;
}

.removal-date {
  flex: 0 0 auto;
  color: #71809c;
  font-size: 12px;
  white-space: nowrap;
}

.removal-meta span {
  font-weight: 450;
}

.removal-item {
  grid-template-columns: minmax(0,1fr) auto;
  padding: 13px;
}

.removal-item p {
  font-weight: 400;
}

.removal-state .status-pill {
  font-weight: 520;
}

.manual-remove-form label span {
  font-weight: 450;
}

.manual-remove-form select,.manual-remove-form input {
  font-weight: 400;
}

.manual-actions .btn {
  font-weight: 520;
}

.tech-details,.compact-json {
  display: none !important;
}

@media (max-width:760px) {
  .removal-title-row {
    display: block;
  }
  .removal-date {
    display: block;
    margin-top: 4px;
  }
  .manual-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .manual-actions .btn {
    width: 100%;
  }
}

.distribution-clean-page {
  display: grid;
  gap: 18px;
}

.pretty-manual-panel {
  display: grid;
  grid-template-columns: minmax(260px,.75fr) minmax(520px,1.25fr);
  gap: 22px;
  align-items: start;
  padding: 22px;
}

.manual-panel-left {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.soft-icon {
  width: 48px;
  height: 48px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.soft-icon svg {
  width: 23px;
  height: 23px;
}

.manual-panel-left h2 {
  margin: 1px 0 6px;
  font-size: 19px;
  font-weight: 650;
  letter-spacing: -.01em;
  color: #0f2344;
}

.manual-panel-left p {
  margin: 0;
  color: #667796;
  font-size: 13px;
  line-height: 1.5;
  max-width: 420px;
}

.pretty-manual-form {
  display: grid;
  grid-template-columns: minmax(240px,1fr) minmax(260px,1fr);
  gap: 14px;
  align-items: end;
}

.pretty-manual-form label {
  display: grid;
  gap: 7px;
}

.pretty-manual-form label span {
  font-size: 12px;
  color: #6b7a95;
  font-weight: 600;
}

.pretty-manual-form select,.pretty-manual-form input {
  height: 42px;
  border-radius: 9px;
  border: 1px solid #dbe4f2;
  background: #fff;
  color: #0f2344;
  padding: 9px 12px;
  font-size: 13px;
  outline: none;
}

.pretty-manual-form select:focus,.pretty-manual-form input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,.10);
}

.split-actions {
  grid-column: 1/-1;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.btn.soft-blue {
  background: #eff6ff;
  border: 1px solid #cfe0ff;
  color: #2452db;
}

.btn.soft-blue:hover {
  background: #e8f1ff;
}

.btn.soft-purple {
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
  color: #6d28d9;
}

.btn.soft-purple:hover {
  background: #ede9fe;
}

.distribution-board {
  background: #fff;
  border: 1px solid #dfe7f3;
  border-radius: 9px;
  padding: 20px;
  box-shadow: 0 12px 34px rgba(16,32,64,.05);
}

.distribution-board-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 15px;
}

.distribution-board-head h2 {
  margin: 0 0 5px;
  font-size: 19px;
  font-weight: 650;
  color: #0f2344;
}

.distribution-board-head p {
  margin: 0;
  color: #6b7a95;
  font-size: 13px;
}

.pretty-removal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(360px,1fr));
  gap: 14px;
}

.pretty-removal-card {
  border: 1px solid #dfe7f3;
  background: linear-gradient(180deg,#fff 0%,#fbfdff 100%);
  border-radius: 9px;
  padding: 16px;
  display: grid;
  gap: 13px;
  box-shadow: 0 8px 22px rgba(16,32,64,.04);
  transition: .16s ease;
}

.pretty-removal-card:hover {
  border-color: #c7d8f4;
  box-shadow: 0 12px 28px rgba(24,63,133,.08);
  transform: translateY(-1px);
}

.pretty-removal-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.removal-person {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.person-bubble {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  background: #fff7ed;
  color: #ea580c;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.person-bubble svg {
  width: 22px;
  height: 22px;
}

.removal-person h3 {
  margin: 0 0 3px;
  font-size: 16px;
  font-weight: 650;
  color: #10203c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 300px;
}

.muted-line {
  font-size: 12px;
  color: #71809c;
}

.decision-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  border-radius: 9px;
  padding: 5px 11px;
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
}

.decision-chip.warning {
  background: #fff7ed;
  color: #c2410c;
}

.decision-chip.success {
  background: #dcfce7;
  color: #166534;
}

.decision-chip.danger {
  background: #fee2e2;
  color: #991b1b;
}

.decision-chip.neutral {
  background: #eef2f7;
  color: #40516d;
}

.reason-box {
  border: 1px solid #e5ebf5;
  background: #f8fbff;
  border-radius: 9px;
  padding: 12px;
}

.reason-label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #64748b;
  font-size: 12px;
  font-weight: 650;
  margin-bottom: 6px;
}

.reason-label svg {
  width: 15px;
  height: 15px;
  color: #f97316;
}

.reason-box p {
  margin: 0;
  color: #1f334f;
  font-size: 13px;
  line-height: 1.48;
}

.removal-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.small-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  border-radius: 9px;
  background: #f1f5f9;
  color: #42526b;
  font-size: 12px;
  padding: 4px 9px;
}

.small-pill svg {
  width: 14px;
  height: 14px;
  color: #64748b;
}

.small-pill.warn {
  background: #fff7ed;
  color: #9a3412;
}

.small-pill.warn svg {
  color: #f97316;
}

.small-note {
  margin-left: auto;
  color: #7b8aa5;
  font-size: 12px;
}

.card-actions-split {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 3px;
}

.mini-action {
  height: 32px;
  border-radius: 9px;
  border: 1px solid #dbe4f2;
  background: #fff;
  color: #1f334f;
  font-size: 12px;
  font-weight: 650;
  padding: 0 11px;
  cursor: pointer;
}

.mini-action:hover {
  background: #f8fbff;
  border-color: #c8d8f0;
}

.danger-mini {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #be123c;
}

.danger-mini:hover {
  background: #ffe4e6;
}

.wide-empty {
  grid-column: 1/-1;
  min-height: 220px;
}

.notice-banner {
  border-radius: 9px;
}

.distribution-page .human-card,.distribution-page .removal-item {
  display: none !important;
}

@media (max-width:1100px) {
  .pretty-manual-panel {
    grid-template-columns: 1fr;
  }
  .pretty-manual-form {
    grid-template-columns: 1fr;
  }
  .split-actions {
    justify-content: flex-start;
  }
  .pretty-removal-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width:560px) {
  .pretty-manual-panel,.distribution-board {
    padding: 15px;
  }
  .pretty-removal-card {
    padding: 14px;
  }
  .pretty-removal-top {
    flex-direction: column;
  }
  .small-note {
    margin-left: 0;
    width: 100%;
  }
  .card-actions-split {
    flex-wrap: wrap;
  }
  .mini-action {
    flex: 1;
  }
  .removal-person h3 {
    max-width: 220px;
  }
}

.distribution-table-page {
  display: grid;
  gap: 16px;
}

.dist-manual-compact {
  display: grid;
  grid-template-columns: minmax(270px,.65fr) minmax(720px,1.35fr);
  gap: 24px;
  align-items: center;
  padding: 18px 20px;
}

.dist-manual-info {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.manual-icon-min {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  border: 1px solid #dbe4f2;
  background: #fff;
  display: grid;
  place-items: center;
  color: #53647f;
  flex: 0 0 auto;
}

.manual-icon-min svg {
  width: 21px;
  height: 21px;
}

.dist-manual-info h2 {
  margin: 0 0 5px;
  font-size: 17px;
  font-weight: 560;
  color: #10203c;
  letter-spacing: -.01em;
}

.dist-manual-info p {
  margin: 0;
  color: #667594;
  font-size: 13px;
  line-height: 1.42;
}

.dist-manual-row {
  display: grid;
  grid-template-columns: minmax(240px,1fr) minmax(220px,.85fr) auto;
  gap: 12px;
  align-items: end;
}

.dist-manual-row label {
  display: grid;
  gap: 6px;
}

.dist-manual-row label span {
  font-size: 12px;
  color: #667594;
  font-weight: 500;
}

.dist-manual-row select,.dist-manual-row input {
  height: 40px;
  border: 1px solid #dbe4f2;
  border-radius: 9px;
  background: #fff;
  color: #13233f;
  padding: 0 12px;
  font-size: 13px;
  outline: none;
}

.dist-manual-row select:focus,.dist-manual-row input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,.10);
}

.manual-table-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}

.dist-action-btn,.row-action {
  height: 40px;
  border-radius: 9px;
  border: 1px solid #dbe4f2;
  background: #fff;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 560;
  cursor: pointer;
  white-space: nowrap;
}

.dist-action-btn svg {
  width: 17px;
  height: 17px;
}

.dist-action-btn.mango,.row-action.mango {
  border-color: #bfdbfe;
  color: #1d4ed8;
  background: #f8fbff;
}

.dist-action-btn.bitrix,.row-action.bitrix {
  border-color: #ddd6fe;
  color: #6d28d9;
  background: #fbfaff;
}

.dist-action-btn.all,.row-action.all {
  border-color: #fecaca;
  color: #b91c1c;
  background: #fffafa;
}

.dist-action-btn:hover,.row-action:hover {
  filter: brightness(.985);
  transform: translateY(-1px);
}

.dist-table-card {
  padding: 20px;
}

.dist-table-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 14px;
  margin-bottom: 16px;
}

.dist-table-head h2 {
  margin: 0 0 5px;
  font-size: 18px;
  font-weight: 560;
  color: #10203c;
}

.dist-table-head p {
  margin: 0;
  color: #667594;
  font-size: 13px;
}

.dist-table-wrap {
  overflow: auto;
}

.dist-clean-table {
  min-width: 1040px;
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
}

.dist-clean-table th {
  padding: 13px 12px;
  border-bottom: 1px solid #dfe7f3;
  color: #6a7892;
  font-size: 11px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  text-align: left;
}

.dist-clean-table td {
  padding: 15px 12px;
  border-bottom: 1px solid #edf2f7;
  font-size: 13px;
  vertical-align: middle;
  color: #1c2f4d;
}

.dist-clean-table tbody tr:hover {
  background: #fbfdff;
}

.dist-clean-table tbody tr:last-child td {
  border-bottom: 0;
}

.dist-person-mini {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.dist-avatar-mini {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  border: 1px solid #dfe7f3;
  background: #f8fbff;
  color: #667594;
  flex: 0 0 auto;
}

.dist-avatar-mini svg {
  width: 17px;
  height: 17px;
}

.dist-person-name {
  font-weight: 540;
  color: #10203c;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 230px;
}

.dist-person-note {
  font-size: 12px;
  color: #b45309;
  margin-top: 2px;
}

.dist-date-cell {
  white-space: nowrap;
  color: #53647f;
}

.dist-reason-cell {
  max-width: 390px;
  color: #42516b;
  line-height: 1.45;
}

.dist-count-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 26px;
  border-radius: 9px;
  background: #f1f5f9;
  color: #42516b;
  font-weight: 540;
  padding: 0 10px;
}

.dist-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  border-radius: 9px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}

.dist-status-pill.candidate {
  background: #f1f5f9;
  color: #53647f;
}

.dist-status-pill.removed {
  background: #dcfce7;
  color: #166534;
}

.dist-row-actions {
  display: flex;
  gap: 7px;
  align-items: center;
}

.row-action {
  height: 32px;
  border-radius: 9px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 540;
}

.distribution-table-page .pretty-removal-grid,.distribution-table-page .pretty-removal-card,.distribution-table-page .distribution-board,.distribution-table-page .pretty-manual-panel,.distribution-table-page .distribution-clean-page {
  display: none !important;
}

@media (max-width:1250px) {
  .dist-manual-compact {
    grid-template-columns: 1fr;
  }
  .dist-manual-row {
    grid-template-columns: 1fr;
  }
  .manual-table-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
  }
}

@media (max-width:720px) {
  .dist-manual-compact,.dist-table-card {
    padding: 15px;
  }
  .manual-table-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
  .dist-action-btn {
    width: 100%;
  }
}

.removed-people-card {
  margin-top: 16px;
}

.dist-avatar-mini.removed {
  background: #ecfdf5;
  color: #15803d;
  border-color: #bbf7d0;
}

.removed-clean-table {
  min-width: 980px;
}

.removed-clean-table .dist-reason-cell {
  max-width: 460px;
}

body {
  font-weight: 400;
}

.page-head h1 {
  font-weight: 650 !important;
}

.page-head p {
  font-weight: 400 !important;
}

.card-head h2,.panel h2,.hero-card h2,.run-detail-title h2,.dist-table-head h2,.dist-manual-info h2 {
  font-weight: 560 !important;
}

.eyebrow {
  font-weight: 600 !important;
  letter-spacing: .08em;
}

.btn,.link-btn,.side-nav a,.badge,.status-pill,.small-pill,.dist-status-pill,.dist-count-pill,.row-action,.dist-action-btn {
  font-weight: 520 !important;
}

.kpi-card strong,.small-strong,.run-kpi-card strong {
  font-weight: 560 !important;
}

.kpi-card span,.run-kpi-card span,.muted,.card-head p,.hero-card p,.panel p {
  font-weight: 400 !important;
}

.table th,.dist-clean-table th {
  font-weight: 500 !important;
}

.table td,.dist-clean-table td {
  font-weight: 400 !important;
}

.dist-person-name,.human-person-name,.manager-name,.lead-title,.removal-person h3 {
  font-weight: 520 !important;
}

.brand-icon,.avatar {
  font-weight: 650 !important;
}

.brand b,.user-text b {
  font-weight: 560 !important;
}

.progress-title {
  font-weight: 520 !important;
}

.log-card summary {
  font-weight: 520 !important;
}

.run-detail-hero .badge {
  font-weight: 500 !important;
}

.dist-spoiler-card {
  padding: 0;
  overflow: hidden;
}

.dist-spoiler-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
  cursor: pointer;
  list-style: none;
}

.dist-spoiler-summary::-webkit-details-marker {
  display: none;
}

.dist-spoiler-summary h2 {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 600;
}

.dist-spoiler-summary p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.dist-spoiler-summary::after {
  content: "Показать";
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.dist-spoiler-card[open] .dist-spoiler-summary::after {
  content: "Скрыть";
}

.spoiler-count {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 30px;
  padding: 0 10px;
  border-radius: 9px;
  background: #eef4ff;
  color: #2563eb;
  font-weight: 600;
  font-size: 13px;
}

.dist-spoiler-body {
  border-top: 1px solid var(--border);
  padding: 0 22px 20px;
}

.dist-spoiler-body .dist-table-wrap {
  margin-top: 16px;
}

.dist-spoiler-summary.dist-table-head {
  margin: 0;
  padding: 18px 20px;
  align-items: flex-end;
}

.dist-spoiler-summary.dist-table-head h2 {
  margin: 0 0 5px;
  font-size: 18px;
  font-weight: 560;
  color: #10203c;
  letter-spacing: 0;
}

.dist-spoiler-summary.dist-table-head p {
  margin: 0;
  color: #667594;
  font-size: 13px;
  line-height: 1.4;
}

.dist-spoiler-summary.dist-table-head::after {
  order: 3;
  height: 32px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 520;
  box-shadow: none;
}

.dist-spoiler-summary.dist-table-head .spoiler-count {
  order: 2;
  margin-left: auto;
  height: 28px;
  min-width: 28px;
  padding: 0 9px;
  font-weight: 520;
  font-size: 12px;
  background: #f1f5f9;
  color: #42516b;
}

.dist-spoiler-body {
  padding: 0 20px 18px;
}

.dist-spoiler-summary.dist-table-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 14px;
  margin: 0;
  padding: 20px;
  cursor: pointer;
}

.dist-spoiler-summary.dist-table-head h2 {
  margin: 0 0 5px !important;
  font-size: 18px !important;
  line-height: 1.25;
  font-weight: 560 !important;
  color: #10203c !important;
}

.dist-spoiler-summary.dist-table-head p {
  margin: 0 !important;
  color: #667594 !important;
  font-size: 13px !important;
  line-height: 1.4 !important;
  font-weight: 400 !important;
}

.dist-spoiler-summary.dist-table-head .spoiler-count {
  margin-left: auto;
  height: 28px;
  min-width: 28px;
  padding: 0 10px;
  border-radius: 9px;
  background: #f1f5f9;
  color: #42516b;
  font-size: 12px;
  font-weight: 500 !important;
}

.dist-spoiler-summary.dist-table-head::after {
  content: 'Показать';
  height: 32px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #dbe4f2;
  background: #fff;
  color: #10203c;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 500 !important;
  box-shadow: none;
}

.dist-spoiler-card[open] .dist-spoiler-summary.dist-table-head::after {
  content: 'Скрыть';
}

.removed-clean-table {
  min-width: 820px;
}

.users-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 20px 22px;
}

.users-topbar-text p,
.block-head-row p {
  margin: 5px 0 0;
  color: var(--v9-muted, #64748b);
  font-size: 14px;
  line-height: 1.45;
  font-weight: 400;
}

.section-title-clean {
  color: var(--v9-text, #071b3a);
  font-size: 18px;
  font-weight: 600;
}

.users-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.users-summary-card {
  background: #fff;
  border: 1px solid var(--v9-border, #dbe5f4);
  border-radius: 9px;
  padding: 16px 18px;
  box-shadow: 0 12px 32px rgba(15,35,70,.04);
}

.users-summary-card span {
  display: block;
  color: var(--v9-muted, #64748b);
  font-size: 13px;
  margin-bottom: 6px;
  font-weight: 400;
}

.users-summary-card strong {
  font-size: 26px;
  font-weight: 650;
  color: var(--v9-text, #071b3a);
}

.block-head-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.block-head-row h2 {
  margin: 0;
  color: var(--v9-text, #071b3a);
  font-size: 19px;
  font-weight: 600;
}

.manual-match-card {
  padding: 20px 22px;
}

.manual-match-form {
  display: grid;
  grid-template-columns: minmax(240px,1.1fr) minmax(240px,1fr) auto;
  gap: 12px;
  align-items: end;
}

.manual-match-form label {
  display: grid;
  gap: 7px;
  color: var(--v9-muted, #64748b);
  font-size: 12px;
  font-weight: 500;
}

.manual-match-form select {
  width: 100%;
  height: 44px;
  border: 1px solid var(--v9-border, #dbe5f4);
  border-radius: 9px;
  background: #fff;
  padding: 0 12px;
  color: var(--v9-text, #071b3a);
  font: inherit;
  font-weight: 400;
}

.mapping-table-card {
  padding: 20px 22px;
}

.clean-users-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.clean-users-table th {
  color: #667996;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  padding: 11px 12px;
  border-bottom: 1px solid var(--v9-border, #dbe5f4);
}

.clean-users-table td {
  padding: 13px 12px;
  border-bottom: 1px solid #edf2f8;
  vertical-align: middle;
  font-weight: 400;
}

.clean-users-table tr:last-child td {
  border-bottom: 0;
}

.clean-users-table strong {
  display: block;
  font-weight: 550;
  color: var(--v9-text, #071b3a);
  line-height: 1.25;
}

.clean-users-table small {
  display: block;
  margin-top: 4px;
  color: var(--v9-muted, #64748b);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.35;
}

.user-cell {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 220px;
}

.user-avatar-mini {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: #eef5ff;
  color: #2563eb;
  border: 1px solid #dbe8ff;
  font-size: 12px;
  font-weight: 600;
  flex: 0 0 auto;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--v9-border, #dbe5f4);
  background: #fff;
  color: #64748b;
  cursor: pointer;
}

.icon-btn:hover {
  background: #f8fafc;
}

.icon-btn.danger:hover {
  color: #dc2626;
  border-color: #fecaca;
  background: #fff7f7;
}

.btn.mini {
  padding: 7px 10px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 500;
}

.empty-inline {
  border: 1px dashed var(--v9-border, #dbe5f4);
  border-radius: 9px;
  padding: 18px;
  color: var(--v9-muted, #64748b);
  background: #fbfdff;
}

.users-secondary-grid {
  align-items: start;
}

.slim-details {
  padding: 0;
}

.slim-details > summary,
.slim-details details > summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--v9-text, #071b3a);
  font-size: 17px;
  font-weight: 600;
}

.slim-details > summary::-webkit-details-marker,
.slim-details details > summary::-webkit-details-marker {
  display: none;
}

.slim-details summary span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 26px;
  border-radius: 9px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 12px;
  font-weight: 500;
}

.simple-list.compact {
  padding: 0 20px 18px;
}

.simple-list.compact div {
  padding: 10px 0;
  border-top: 1px solid #edf2f8;
}

.simple-list.compact strong {
  font-weight: 550;
}

@media (max-width:1100px) {
  .users-summary-grid {
    grid-template-columns: repeat(2,1fr);
  }
  .manual-match-form {
    grid-template-columns: 1fr;
  }
  .users-topbar,.block-head-row {
    display: block;
  }
  .users-topbar form,.block-head-row form {
    margin-top: 12px;
  }
}

@media (max-width:720px) {
  .users-summary-grid {
    grid-template-columns: 1fr;
  }
  .clean-users-table {
    overflow: auto;
  }
}

.users-page-v31 {
  display: grid;
  gap: 16px;
}

.users-refresh-btn {
  height: 44px;
}

.users-kpi-row-v31 {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 14px;
}

.users-kpi-v31 {
  background: #fff;
  border: 1px solid #dfe7f2;
  border-radius: 9px;
  box-shadow: 0 10px 28px rgba(25,42,70,.045);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.users-kpi-icon-v31 {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.users-kpi-icon-v31 svg {
  width: 23px;
  height: 23px;
}

.users-kpi-icon-v31.green {
  background: #dcfce7;
  color: #16a34a;
}

.users-kpi-icon-v31.orange {
  background: #fff4dd;
  color: #f59e0b;
}

.users-kpi-icon-v31.blue {
  background: #eaf1ff;
  color: #2563eb;
}

.users-kpi-icon-v31.purple {
  background: #f0e7ff;
  color: #7c3aed;
}

.users-kpi-v31 small {
  display: block;
  color: #667594;
  font-weight: 500;
  font-size: 14px;
}

.users-kpi-v31 strong {
  display: block;
  color: #071b3a;
  font-size: 28px;
  font-weight: 650;
  line-height: 1.08;
  margin: 4px 0 3px;
  letter-spacing: -.03em;
}

.users-kpi-v31 em {
  display: block;
  color: #71809c;
  font-style: normal;
  font-size: 13px;
}

.users-manual-v31 {
  padding: 20px 22px;
  display: grid;
  grid-template-columns: minmax(230px,.7fr) minmax(0,1.8fr);
  gap: 22px;
  align-items: center;
}

.users-manual-head-v31 h2 {
  font-size: 18px;
  font-weight: 620;
  margin: 0 0 7px;
  color: #071b3a;
}

.users-manual-head-v31 p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  max-width: 520px;
}

.users-manual-form-v31 {
  display: grid;
  grid-template-columns: minmax(220px,1fr) minmax(220px,1fr) auto;
  gap: 12px;
  align-items: end;
}

.users-manual-form-v31 label {
  display: grid;
  gap: 7px;
}

.users-manual-form-v31 label span {
  font-size: 12px;
  color: #667594;
  font-weight: 500;
}

.users-manual-form-v31 select {
  height: 44px;
  border: 1px solid #dbe5f2;
  background: #fff;
  border-radius: 9px;
  color: #0f1f3c;
  padding: 0 12px;
  font: inherit;
  font-size: 14px;
}

.users-manual-form-v31 .btn {
  height: 44px;
}

.users-filter-v31 {
  padding: 14px 16px;
  display: grid;
  grid-template-columns: minmax(320px,1fr) 220px auto;
  gap: 12px;
  align-items: center;
}

.users-search-v31 {
  height: 42px;
  border: 1px solid #dbe5f2;
  background: #fff;
  border-radius: 9px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
  color: #71809c;
}

.users-search-v31 svg {
  width: 18px;
  height: 18px;
}

.users-search-v31 input {
  border: 0;
  outline: 0;
  background: transparent;
  width: 100%;
  font: inherit;
  color: #0f1f3c;
}

.users-filter-v31 select {
  height: 42px;
  border: 1px solid #dbe5f2;
  background: #fff;
  border-radius: 9px;
  color: #0f1f3c;
  padding: 0 12px;
  font: inherit;
  font-size: 14px;
}

.users-main-table-card-v31 {
  padding: 0;
  overflow: hidden;
}

.users-tabs-v31 {
  display: flex;
  gap: 0;
  border-bottom: 1px solid #dfe7f2;
  padding: 0 18px;
}

.users-tabs-v31 button {
  height: 58px;
  border: 0;
  background: transparent;
  color: #566987;
  font: inherit;
  font-weight: 520;
  padding: 0 18px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.users-tabs-v31 button.active {
  color: #2563eb;
  border-bottom-color: #2563eb;
}

.users-tabs-v31 span {
  margin-left: 6px;
  background: #eef3fb;
  color: #52627c;
  border-radius: 9px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 520;
}

.users-table-v31 table {
  font-size: 14px;
}

.users-table-v31 th {
  font-size: 12px;
  color: #667594;
  font-weight: 620;
  text-transform: none;
  letter-spacing: 0;
  background: #fbfcfe;
}

.users-table-v31 td,.users-table-v31 th {
  padding: 14px 18px;
}

.users-table-v31 tbody tr {
  transition: background .15s ease;
}

.users-table-v31 tbody tr:hover {
  background: #f8fbff;
}

.users-person-v31 {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.users-person-v31 strong,.users-person-plain-v31 strong {
  display: block;
  color: #10213d;
  font-weight: 560;
  line-height: 1.25;
}

.users-person-v31 small,.users-person-plain-v31 small {
  display: block;
  color: #71809c;
  margin-top: 3px;
  font-size: 12.5px;
}

.users-avatar-v31 {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: #eef4ff;
  color: #2563eb;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  font-weight: 620;
  font-size: 12px;
  text-transform: uppercase;
}

.users-avatar-v31.purple {
  background: #f0e7ff;
  color: #7c3aed;
}

.users-avatar-v31.muted {
  background: #f4f7fb;
  color: #667594;
}

.users-person-plain-v31 {
  min-width: 180px;
}

.users-status-v31 {
  display: inline-flex;
  align-items: center;
  border-radius: 9px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 520;
  white-space: nowrap;
}

.users-status-v31.success {
  background: #dcfce7;
  color: #15803d;
}

.users-status-v31.blue {
  background: #eaf1ff;
  color: #2563eb;
}

.users-status-v31.warning {
  background: #fff4dd;
  color: #c45a00;
}

.users-status-v31.danger {
  background: #fee2e2;
  color: #b91c1c;
}

.users-status-v31.neutral {
  background: #f1f5f9;
  color: #475569;
}

.users-empty-v31 {
  color: #9aa7bc;
  display: grid;
  gap: 2px;
}

.users-empty-v31 small {
  font-size: 12.5px;
  color: #71809c;
}

.users-actions-v31 {
  white-space: nowrap;
}

.users-actions-v31 form {
  display: inline-flex;
  margin: 0;
}

.users-table-foot-v31 {
  border-top: 1px solid #dfe7f2;
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  color: #71809c;
  font-size: 13px;
}

.users-env-spoiler-v31 {
  padding: 16px 18px;
}

.users-env-spoiler-v31 summary {
  cursor: pointer;
  color: #42516b;
  font-weight: 520;
}

.users-env-spoiler-v31 textarea {
  margin-top: 12px;
}

.btn.mini {
  padding: 8px 12px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 520;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  border: 1px solid #dbe5f2;
  background: #fff;
  color: #42516b;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.icon-btn:hover {
  background: #f8fbff;
  color: #2563eb;
}

.icon-btn svg {
  width: 17px;
  height: 17px;
}

.right {
  text-align: right;
}

@media (max-width:1280px) {
  .users-kpi-row-v31 {
    grid-template-columns: repeat(2,1fr);
  }
  .users-manual-v31 {
    grid-template-columns: 1fr;
  }
  .users-manual-form-v31 {
    grid-template-columns: 1fr 1fr;
  }
  .users-manual-form-v31 .btn {
    grid-column: 1 / -1;
  }
  .users-filter-v31 {
    grid-template-columns: 1fr 220px;
  }
  .users-filter-v31 .btn {
    grid-column: 1 / -1;
    justify-self: start;
  }
}

@media (max-width:780px) {
  .users-kpi-row-v31,.users-manual-form-v31,.users-filter-v31 {
    grid-template-columns: 1fr;
  }
  .users-tabs-v31 {
    overflow: auto;
  }
  .users-table-foot-v31 {
    display: block;
  }
  .users-table-foot-v31 form {
    margin-top: 12px;
  }
  .users-person-v31 {
    min-width: 190px;
  }
}

.users-manual-spoiler-v31 {
  display: block !important;
  padding: 0 !important;
  overflow: hidden;
}

.users-manual-summary-v31 {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
}

.users-manual-summary-v31::-webkit-details-marker {
  display: none;
}

.users-manual-summary-v31 h2 {
  margin: 0 0 5px;
  color: #071b3a;
  font-size: 18px;
  font-weight: 560;
  letter-spacing: -.01em;
}

.users-manual-summary-v31 p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.users-spoiler-action-v31 {
  border: 1px solid #dbe5f2;
  background: #f8fbff;
  color: #42516b;
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 520;
  white-space: nowrap;
}

.users-manual-spoiler-v31[open] .users-spoiler-action-v31 {
  font-size: 0;
}

.users-manual-spoiler-v31[open] .users-spoiler-action-v31::after {
  content: 'Скрыть';
  font-size: 13px;
}

.users-manual-spoiler-v31 .users-manual-form-v31 {
  border-top: 1px solid #dfe7f2;
  padding: 18px 22px 20px;
}

.qc-dashboard {
  display: grid;
  gap: 18px;
}

.qc-alert {
  display: grid;
  grid-template-columns: 56px minmax(0,1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 24px 26px;
  border-color: #fed7aa;
  background: linear-gradient(135deg,#fff7ed 0%,#fff 62%);
  box-shadow: 0 12px 30px rgba(234,88,12,.07);
}

.qc-alert-icon {
  width: 48px;
  height: 48px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg,#fb923c,#f97316);
  color: #fff;
  box-shadow: 0 10px 22px rgba(249,115,22,.24);
}

.qc-alert-icon svg {
  width: 26px;
  height: 26px;
}

.qc-alert-date {
  font-size: 13px;
  font-weight: 520;
  color: #17233d;
  margin-bottom: 7px;
}

.qc-alert-copy h2 {
  margin: 0 0 6px;
  font-size: 21px;
  line-height: 1.25;
  letter-spacing: -.025em;
  color: #10203c;
}

.qc-alert-copy p {
  margin: 0;
  color: #31425f;
  font-size: 14px;
}

.qc-alert-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.qc-alert-actions .btn {
  height: 44px;
}

.qc-kpi-row {
  margin-bottom: 0;
}

.qc-kpi-row .minimal-kpi {
  min-height: 104px;
}

.qc-kpi-row .minimal-kpi strong {
  font-size: 29px;
}

.delta-good {
  color: #16a34a !important;
}

.delta-bad {
  color: #e11d48 !important;
}

.qc-main-grid {
  grid-template-columns: minmax(0,1.02fr) minmax(430px,.98fr);
  margin-bottom: 0;
}

.qc-risk-grid {
  grid-template-columns: minmax(0,1.08fr) minmax(360px,.92fr);
  align-items: stretch;
}

.qc-bottom-grid {
  grid-template-columns: 1fr;
  margin-bottom: 0;
}

.link-clean {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.link-clean svg {
  width: 15px;
  height: 15px;
}

.risk-table th:nth-child(2),.risk-table td:nth-child(2) {
  text-align: center;
  width: 150px;
}

.risk-table th:nth-child(3),.risk-table td:nth-child(3) {
  width: 210px;
}

.risk-cell {
  display: grid;
  grid-template-columns: 10px auto;
  gap: 7px;
  align-items: center;
  color: #44536d;
  font-size: 13px;
}

.risk-dot {
  width: 8px;
  height: 8px;
  border-radius: 9px;
  display: inline-block;
}

.risk-dot.high {
  background: #ef4444;
}

.risk-dot.medium {
  background: #f59e0b;
}

.risk-dot.low {
  background: #22c55e;
}

.risk-bar {
  grid-column: 2;
  height: 7px;
  border-radius: 9px;
  background: #edf2f7;
  overflow: hidden;
  width: 100%;
  max-width: 160px;
}

.risk-bar i {
  display: block;
  height: 100%;
  border-radius: 9px;
}

.risk-bar i.high {
  background: #ef4444;
}

.risk-bar i.medium {
  background: #f59e0b;
}

.risk-bar i.low {
  background: #22c55e;
}

.reason-list {
  display: grid;
  gap: 13px;
  margin-top: 4px;
}

.reason-row {
  display: grid;
  grid-template-columns: 10px minmax(0,1fr) auto;
  gap: 12px;
  align-items: center;
}

.reason-marker {
  width: 8px;
  height: 8px;
  border-radius: 9px;
  display: block;
}

.reason-marker.blue,.reason-bar i.blue {
  background: #3b82f6;
}

.reason-marker.orange,.reason-bar i.orange {
  background: #f97316;
}

.reason-marker.purple,.reason-bar i.purple {
  background: #8b5cf6;
}

.reason-marker.green,.reason-bar i.green {
  background: #22c55e;
}

.reason-marker.yellow,.reason-bar i.yellow {
  background: #f59e0b;
}

.reason-marker.red,.reason-bar i.red {
  background: #ef4444;
}

.reason-main b {
  display: block;
  font-size: 14px;
  font-weight: 520;
  color: #1c2f4d;
  margin-bottom: 7px;
}

.reason-bar {
  height: 8px;
  border-radius: 9px;
  background: #edf2f7;
  overflow: hidden;
}

.reason-bar i {
  display: block;
  height: 100%;
  border-radius: 9px;
}

.reason-row>strong {
  font-size: 13px;
  font-weight: 560;
  color: #233553;
  white-space: nowrap;
}

.reason-row>strong small {
  color: #6b7a95;
  font-weight: 400;
}

.qc-system-card .report-list {
  grid-template-columns: 1fr;
  gap: 11px;
}

.qc-system-card .report-list div {
  grid-template-columns: 22px 180px 1fr;
  padding-bottom: 11px;
  border-bottom: 1px solid var(--v9-border);
}

.qc-system-card .report-list div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

@media (max-width:1180px) {
  .qc-alert {
    grid-template-columns: 48px 1fr;
  }
  .qc-alert-actions {
    grid-column: 1/-1;
    justify-content: flex-start;
  }
  .qc-main-grid,.qc-risk-grid,.qc-bottom-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width:680px) {
  .qc-alert {
    grid-template-columns: 1fr;
    padding: 18px;
  }
  .qc-alert-icon {
    width: 44px;
    height: 44px;
  }
  .qc-alert-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
  .qc-alert-actions .btn {
    width: 100%;
  }
  .risk-table {
    min-width: 620px;
  }
  .qc-system-card .report-list div {
    grid-template-columns: 20px 1fr;
  }
  .qc-system-card .report-list span {
    grid-column: 2;
  }
  .qc-alert-copy h2 {
    font-size: 18px;
  }
}

.scheduler-card {
  margin-bottom: 18px;
}

.scheduler-form {
  display: grid;
  grid-template-columns: 1.4fr repeat(5, minmax(110px, 1fr)) auto;
  gap: 12px;
  align-items: end;
}

.scheduler-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--muted, #64748b);
}

.scheduler-form input, .scheduler-form select {
  min-height: 38px;
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 9px;
  padding: 0 12px;
  background: #fff;
  color: var(--text, #0f172a);
}

.scheduler-form .toggle-line {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  padding-bottom: 10px;
  font-size: 14px;
  color: var(--text, #0f172a);
}

.scheduler-form .toggle-line input {
  min-height: auto;
  width: 18px;
  height: 18px;
  padding: 0;
}

.scheduler-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 14px;
  color: var(--muted, #64748b);
  font-size: 13px;
}

.inline-form {
  margin-top: 10px;
}

@media (max-width: 1180px) {
  .scheduler-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .scheduler-form {
    grid-template-columns: 1fr;
  }
}

/* polished scheduler spoiler */

.scheduler-spoiler {
  padding: 0;
  overflow: hidden;
  margin-bottom: 18px;
  border: 1px solid #dfe7f2;
  background: #fff;
  box-shadow: 0 14px 38px rgba(15,23,42,.05);
}

.scheduler-spoiler>summary {
  list-style: none;
}

.scheduler-spoiler>summary::-webkit-details-marker {
  display: none;
}

.scheduler-summary {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  background: linear-gradient(135deg,#f8fbff 0%,#fff 62%);
  border-radius: 9px;
}

.scheduler-summary-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.scheduler-summary-icon {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  background: #eaf1ff;
  color: #2563eb;
  display: grid;
  place-items: center;
  box-shadow: inset 0 0 0 1px rgba(37,99,235,.08);
}

.scheduler-summary-icon svg {
  width: 21px;
  height: 21px;
}

.scheduler-summary h2 {
  margin: 0 0 3px;
  font-size: 18px;
  letter-spacing: -.02em;
  color: #071b3a;
}

.scheduler-summary p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.scheduler-summary p b {
  color: #0f1f3c;
}

.scheduler-summary-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.scheduler-state {
  display: inline-flex;
  align-items: center;
  border-radius: 9px;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 650;
}

.scheduler-state.on {
  background: #dcfce7;
  color: #15803d;
}

.scheduler-state.off {
  background: #eef3fb;
  color: #64748b;
}

.scheduler-chevron {
  width: 34px;
  height: 34px;
  border: 1px solid #dbe5f2;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: #64748b;
  background: #fff;
  transition: .18s ease;
}

.scheduler-chevron svg {
  width: 17px;
  height: 17px;
}

.scheduler-spoiler[open] .scheduler-chevron {
  transform: rotate(180deg);
  color: #2563eb;
  border-color: #bfdbfe;
}

.scheduler-body {
  border-top: 1px solid #e6edf7;
  padding: 18px 20px 20px;
  background: #fff;
}

.scheduler-note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid #e6edf7;
  border-radius: 9px;
  background: #fbfdff;
}

.scheduler-note strong {
  display: block;
  color: #10213d;
  font-size: 14px;
  margin-bottom: 3px;
}

.scheduler-note span {
  display: block;
  color: #71809c;
  font-size: 13px;
}

.scheduler-form.scheduler-form-card {
  display: grid;
  grid-template-columns: minmax(260px,.82fr) minmax(0,1.8fr) auto;
  gap: 14px;
  align-items: stretch;
  padding: 0;
}

.scheduler-toggle-card {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 14px 16px;
  border: 1px solid #dfe7f2;
  border-radius: 9px;
  background: #f8fbff;
  color: #10213d !important;
}

.scheduler-toggle-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.scheduler-toggle-card b {
  display: block;
  font-size: 14px;
  font-weight: 650;
}

.scheduler-toggle-card small {
  display: block;
  color: #71809c;
  font-size: 12px;
  margin-top: 2px;
}

.toggle-ui {
  width: 46px;
  height: 26px;
  border-radius: 9px;
  background: #cbd5e1;
  position: relative;
  flex: 0 0 auto;
  transition: .18s ease;
}

.toggle-ui:after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(15,23,42,.18);
  transition: .18s ease;
}

.scheduler-toggle-card input:checked+.toggle-ui {
  background: #2563eb;
}

.scheduler-toggle-card input:checked+.toggle-ui:after {
  transform: translateX(20px);
}

.scheduler-fields-grid {
  display: grid;
  grid-template-columns: .65fr 1fr 1fr .75fr .75fr;
  gap: 12px;
}

.scheduler-form label:not(.scheduler-toggle-card) {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: #667594;
  font-weight: 520;
}

.scheduler-form input,.scheduler-form select {
  height: 44px;
  min-height: 44px;
  border: 1px solid #dbe5f2;
  border-radius: 9px;
  background: #fff;
  color: #0f1f3c;
  padding: 0 12px;
  font: inherit;
  font-size: 14px;
  outline: 0;
  transition: border-color .15s ease,box-shadow .15s ease;
}

.scheduler-form input:focus,.scheduler-form select:focus {
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(37,99,235,.08);
}

.scheduler-actions-row {
  display: flex;
  align-items: end;
}

.scheduler-actions-row .btn {
  height: 44px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.scheduler-actions-row svg {
  width: 17px;
  height: 17px;
}

.scheduler-meta-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(2,minmax(180px,1fr)) auto;
  gap: 12px;
  align-items: center;
}

.scheduler-meta-grid>div {
  padding: 13px 14px;
  border: 1px solid #e6edf7;
  border-radius: 9px;
  background: #fff;
}

.scheduler-meta-grid span {
  display: block;
  color: #71809c;
  font-size: 12px;
  margin-bottom: 3px;
}

.scheduler-meta-grid b {
  display: block;
  color: #10213d;
  font-size: 14px;
}

.scheduler-meta-grid form {
  justify-self: end;
}

.scheduler-meta-grid .mini-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 42px;
}

.scheduler-meta-grid svg {
  width: 15px;
  height: 15px;
}

@media (max-width:1180px) {
  .scheduler-form.scheduler-form-card {
    grid-template-columns: 1fr;
  }
  .scheduler-fields-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  .scheduler-actions-row {
    justify-content: flex-start;
  }
  .scheduler-meta-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width:720px) {
  .scheduler-summary {
    align-items: flex-start;
  }
  .scheduler-summary-right {
    align-self: center;
  }
  .scheduler-fields-grid {
    grid-template-columns: 1fr;
  }
  .scheduler-note {
    display: block;
  }
  .scheduler-summary p {
    font-size: 13px;
  }
  .scheduler-state {
    display: none;
  }
}

.login-body {
  min-height: 100vh;
  background: radial-gradient(circle at 12% 10%,#dbeafe 0,#eef4ff 28%,#f6f8fc 58%,#ffffff 100%);
  color: #081936;
  font-family: Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
}

.login-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px,480px);
  justify-content: center;
  align-items: center;
  max-width: 760px;
  margin: 0 auto;
  padding: 44px;
}

.login-hero {
  min-height: 560px;
  border-radius: 9px;
  padding: 36px;
  background: linear-gradient(145deg,#101f3a 0%,#0a1730 54%,#16346e 100%);
  color: #fff;
  box-shadow: 0 26px 70px rgba(15,31,61,.22);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.login-hero:before {
  content: "";
  position: absolute;
  inset: -120px -160px auto auto;
  width: 360px;
  height: 360px;
  border-radius: 9px;
  background: rgba(59,112,255,.35);
  filter: blur(6px);
}

.login-hero:after {
  content: "";
  position: absolute;
  left: -80px;
  bottom: -110px;
  width: 310px;
  height: 310px;
  border-radius: 9px;
  background: rgba(34,197,94,.16);
  filter: blur(3px);
}

.login-brand,.login-hero-copy,.login-facts {
  position: relative;
  z-index: 1;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.login-brand-icon {
  width: 52px;
  height: 52px;
  border-radius: 9px;
  background: rgba(255,255,255,.09);
  border: 1px solid rgba(255,255,255,.18);
  display: grid;
  place-items: center;
  color: #8fb3ff;
}

.login-brand-icon svg {
  width: 28px;
  height: 28px;
}

.login-brand b {
  display: block;
  font-size: 18px;
  letter-spacing: -.02em;
}

.login-brand small {
  display: block;
  margin-top: 2px;
  color: #aebcdf;
}

.login-hero-copy span {
  display: inline-flex;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.08);
  border-radius: 9px;
  padding: 7px 12px;
  color: #cfe0ff;
  font-size: 13px;
  font-weight: 700;
}

.login-hero-copy h1 {
  margin: 22px 0 14px;
  font-size: 48px;
  line-height: 1.02;
  letter-spacing: -.055em;
  max-width: 620px;
}

.login-hero-copy p {
  margin: 0;
  color: #bdc9e2;
  font-size: 16px;
  line-height: 1.65;
  max-width: 570px;
}

.login-facts {
  display: grid;
  gap: 10px;
}

.login-facts div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #dbe7ff;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 9px;
  padding: 12px 14px;
}

.login-facts svg {
  width: 18px;
  height: 18px;
  color: #8fb3ff;
}

.login-card {
  background: rgba(255,255,255,.92);
  border: 1px solid #dfe7f2;
  border-radius: 9px;
  box-shadow: 0 22px 60px rgba(15,31,61,.13);
  padding: 34px;
}

.login-card-head {
  text-align: center;
  margin-bottom: 24px;
}

.login-card-icon {
  width: 62px;
  height: 62px;
  border-radius: 9px;
  background: #eaf1ff;
  color: #2563eb;
  display: grid;
  place-items: center;
  margin: 0 auto 16px;
}

.login-card-icon svg {
  width: 29px;
  height: 29px;
}

.login-card-head h2 {
  margin: 0 0 8px;
  color: #071b3a;
  font-size: 28px;
  letter-spacing: -.035em;
}

.login-card-head p {
  margin: 0 auto;
  color: #64748b;
  line-height: 1.5;
  max-width: 330px;
}

.login-form {
  display: grid;
  gap: 16px;
}

.login-form label {
  display: grid;
  gap: 8px;
}

.login-form label>span {
  font-size: 13px;
  font-weight: 650;
  color: #42516b;
}

.login-input {
  height: 52px;
  border: 1px solid #dbe5f2;
  background: #fff;
  border-radius: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  transition: .15s ease;
}

.login-input svg {
  width: 19px;
  height: 19px;
  color: #71809c;
}

.login-input input {
  border: 0;
  outline: 0;
  background: transparent;
  width: 100%;
  height: 100%;
  font: inherit;
  color: #0f1f3c;
}

.login-submit {
  height: 54px;
  border: 0;
  border-radius: 9px;
  background: linear-gradient(135deg,#3d72ff,#2452db);
  color: #fff;
  font: inherit;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 16px 30px rgba(47,107,255,.28);
  margin-top: 4px;
}

.login-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 36px rgba(47,107,255,.32);
}

.login-submit svg {
  width: 20px;
  height: 20px;
}

.login-error {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #fecaca;
  background: #fff1f2;
  color: #b91c1c;
  border-radius: 9px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-weight: 650;
}

.login-error svg {
  width: 18px;
  height: 18px;
}

.admin-menu.minimal-admin {
  position: relative;
  display: block;
  margin-top: auto;
  padding: 12px 4px 0;
  border-top: 1px solid rgba(255,255,255,.13);
}

.admin-menu summary {
  list-style: none;
}

.admin-menu summary::-webkit-details-marker {
  display: none;
}

.admin-menu .admin-card {
  margin: 0;
  display: grid;
  grid-template-columns: 36px minmax(0,1fr) 18px;
  gap: 10px;
  align-items: center;
  padding: 8px 6px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #fff;
  cursor: pointer;
  text-decoration: none;
}

.admin-menu .admin-card:hover {
  background: rgba(255,255,255,.06);
}

.admin-card-text {
  min-width: 0;
}

.admin-card-text b,.admin-card-text small {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-chevron {
  width: 16px;
  height: 16px;
  color: #90a1c3;
  transition: .15s ease;
}

.admin-menu[open] .admin-chevron {
  transform: rotate(180deg);
}

.admin-menu-popover {
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 62px;
  background: #fff;
  color: #10213d;
  border: 1px solid #dbe5f2;
  border-radius: 9px;
  box-shadow: 0 18px 45px rgba(0,0,0,.24);
  padding: 7px;
  z-index: 40;
}

.admin-menu-popover:after {
  content: "";
  position: absolute;
  left: 24px;
  bottom: -7px;
  width: 12px;
  height: 12px;
  background: #fff;
  border-right: 1px solid #dbe5f2;
  border-bottom: 1px solid #dbe5f2;
  transform: rotate(45deg);
}

.admin-menu-popover a,.admin-menu-popover button {
  width: 100%;
  height: 40px;
  border: 0;
  background: transparent;
  border-radius: 9px;
  color: #13233f;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 11px;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  text-align: left;
}

.admin-menu-popover a:hover,.admin-menu-popover button:hover {
  background: #f5f8fd;
}

.admin-menu-popover form {
  margin: 0;
}

.admin-menu-popover svg {
  width: 17px;
  height: 17px;
  color: #667594;
}

@media (max-width:860px) {
  .admin-menu.minimal-admin {
    margin-top: 14px;
  }
  .admin-menu-popover {
    position: static;
    margin-top: 8px;
  }
  .admin-menu-popover:after {
    display: none;
  }
}

@media (max-width:900px) {
  .login-page {
    grid-template-columns: 1fr;
    padding: 22px;
  }
  .login-hero {
    min-height: auto;
    gap: 44px;
  }
  .login-hero-copy h1 {
    font-size: 38px;
  }
  .login-card {
    padding: 26px;
  }
}

@media (max-width:540px) {
  .login-page {
    padding: 14px;
  }
  .login-hero {
    border-radius: 9px;
    padding: 24px;
  }
  .login-hero-copy h1 {
    font-size: 31px;
  }
  .login-card {
    border-radius: 9px;
    padding: 22px;
  }
}

.score-tuning-section {
  overflow: hidden;
  padding: 0;
}

.score-tuning-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.score-formula {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 560;
  white-space: nowrap;
}

.score-tuning-body {
  display: grid;
  gap: 16px;
  padding: 18px;
  background: #fbfdff;
}

.score-tuning-card {
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fff;
  overflow: hidden;
}

.score-tuning-card-head {
  padding: 17px 18px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg,#fff,#f8fbff);
}

.score-tuning-card-head h3 {
  margin: 0 0 5px;
  font-size: 17px;
  font-weight: 560;
  color: #10203c;
}

.score-tuning-card-head p {
  margin: 0;
  color: #667594;
  font-size: 13px;
  line-height: 1.4;
}

.score-tuning-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 0;
}

.score-setting-control {
  display: grid;
  gap: 8px;
  padding: 16px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  min-height: 166px;
}

.score-setting-control:nth-child(6n) {
  border-right: 0;
}

.score-setting-control span {
  font-size: 14px;
  font-weight: 560;
  color: #10203c;
  line-height: 1.25;
}

.score-setting-control small {
  color: #667594;
  font-size: 12px;
  line-height: 1.38;
}

.score-setting-control code {
  width: max-content;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  background: #f1f5ff;
  color: #3449a8;
  border: 1px solid #dbe4ff;
  border-radius: 9px;
  padding: 3px 7px;
  font-size: 11px;
}

.score-setting-control input {
  height: 40px;
  border-radius: 9px;
  font-size: 14px;
}

@media (max-width:1280px) {
  .score-tuning-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  .score-setting-control:nth-child(6n) {
    border-right: 1px solid var(--border);
  }
  .score-setting-control:nth-child(4n) {
    border-right: 0;
  }
}

@media (max-width:760px) {
  .score-tuning-head {
    display: block;
  }
  .score-formula {
    margin-top: 12px;
  }
  .score-tuning-grid {
    grid-template-columns: 1fr;
  }
  .score-setting-control,.score-setting-control:nth-child(4n),.score-setting-control:nth-child(6n) {
    border-right: 0;
  }
  .score-tuning-body {
    padding: 12px;
  }
  .score-setting-control {
    min-height: auto;
  }
}

.settings-spoiler {
  padding: 0;
  overflow: hidden;
  border-radius: 9px;
}

.settings-spoiler summary {
  list-style: none;
  color: inherit;
}

.settings-spoiler summary::-webkit-details-marker {
  display: none;
}

.settings-spoiler-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 22px;
  background: linear-gradient(135deg,#fff,#f8fbff);
  cursor: pointer;
  border-bottom: 1px solid transparent;
  transition: .16s ease;
}

.settings-spoiler-summary:hover {
  background: linear-gradient(135deg,#fff,#f3f8ff);
}

.settings-spoiler-title h2 {
  margin: 0 0 5px;
  font-size: 19px;
  letter-spacing: -.02em;
  color: #10213d;
}

.settings-spoiler-title p {
  margin: 0;
  color: #667594;
  line-height: 1.45;
}

.settings-spoiler-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.settings-spoiler-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #dbe5f2;
  background: #fff;
  color: #667594;
  border-radius: 9px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.settings-spoiler-chevron {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #eff6ff;
  border: 1px solid #dbeafe;
  color: #2452db;
  display: grid;
  place-items: center;
  font-size: 21px;
  font-weight: 900;
  transition: .18s ease;
}

.settings-spoiler[open] .settings-spoiler-summary {
  border-bottom-color: var(--border);
}

.settings-spoiler[open] .settings-spoiler-chevron {
  transform: rotate(180deg);
  background: #2563eb;
  color: #fff;
  border-color: #2563eb;
}

.settings-spoiler-body {
  background: #fff;
}

.settings-spoiler.score-tuning-section {
  overflow: hidden;
}

.settings-spoiler.score-tuning-section .score-tuning-head {
  padding: 20px 22px;
}

.settings-spoiler.score-tuning-section .score-tuning-body {
  padding: 18px;
  background: #fbfdff;
}

.settings-spoiler.score-tuning-section .score-formula {
  margin-left: auto;
}

.settings-spoiler:not([open]) {
  box-shadow: 0 10px 28px rgba(25,42,70,.045);
}

.settings-spoiler:not([open]) .settings-spoiler-summary {
  border-bottom: 0;
}

@media (max-width:760px) {
  .settings-spoiler-summary {
    align-items: flex-start;
    padding: 17px;
    flex-direction: column;
  }
  .settings-spoiler-right {
    width: 100%;
    justify-content: space-between;
  }
  .settings-spoiler.score-tuning-section .score-formula {
    margin-left: 0;
  }
  .settings-spoiler-title h2 {
    font-size: 18px;
  }
}

.settings-form-clean {
  display: grid;
  gap: 14px;
}

.settings-spoiler-clean {
  border: 1px solid #e3eaf4;
  box-shadow: 0 10px 26px rgba(15,23,42,.035);
}

.settings-spoiler-clean .settings-spoiler-summary {
  padding: 18px 20px;
  background: #fff;
}

.settings-spoiler-clean .settings-spoiler-summary:hover {
  background: #f9fbff;
}

.settings-spoiler-clean .settings-spoiler-title h2 {
  font-size: 18px;
  font-weight: 560;
  letter-spacing: -.015em;
  color: #12213a;
}

.settings-spoiler-clean .settings-spoiler-title p {
  font-size: 13px;
  font-weight: 400;
  color: #71809a;
}

.settings-spoiler-clean .settings-spoiler-count {
  font-weight: 450;
  padding: 6px 10px;
}

.settings-spoiler-clean .settings-spoiler-chevron {
  font-weight: 500;
  background: #fff;
  color: #71809a;
}

.settings-spoiler-clean[open] .settings-spoiler-chevron {
  background: #f1f6ff;
  color: #2452db;
  border-color: #cfe0ff;
}

.settings-rows-clean {
  display: grid;
  gap: 0;
}

.setting-row-clean {
  grid-template-columns: minmax(260px,420px) minmax(260px,1fr);
  padding: 15px 18px;
  gap: 18px;
}

.setting-row-clean div span {
  font-weight: 520;
  font-size: 14px;
  color: #16243a;
}

.setting-row-clean div p {
  font-size: 13px;
  line-height: 1.42;
  margin-top: 8px;
}

.setting-row-clean code {
  font-weight: 450;
}

.setting-row-clean input,.setting-row-clean select,.setting-row-clean textarea {
  font-weight: 400;
  border-radius: 9px;
}

.score-real-body {
  padding: 14px;
  background: #fbfdff;
}

.score-real-block {
  border: 1px solid #e5edf6;
  border-radius: 9px;
  background: #fff;
  overflow: hidden;
  margin-bottom: 12px;
}

.score-real-block:last-child {
  margin-bottom: 0;
}

.score-real-block h3 {
  margin: 0;
  padding: 13px 16px;
  border-bottom: 1px solid #e5edf6;
  background: #f8fbff;
  font-size: 15px;
  font-weight: 560;
  color: #13233d;
}

.score-real-block .setting-row-clean:last-child {
  border-bottom: 0;
}

.savebar-clean .btn {
  font-weight: 560;
}

.friendly-setting span,.source-label,.match-side code,.ok-text,.face,.score-badge,.login-submit,.login-error {
  font-weight: 560;
}

.card h2,.action-card h2,.quick-action b,.admin-menu-popover a,.admin-menu-popover button {
  font-weight: 560;
}

.top-user b,.sidebar b,.brand-text b,.kpi-card b,.metric strong,th {
  font-weight: 560;
}

@media (max-width:900px) {
  .setting-row-clean {
    grid-template-columns: 1fr;
  }
}

/* settings values visibility + lighter typography */

.settings-form-clean, .settings-form-clean * {
  font-weight: 400;
}

.settings-spoiler-clean .settings-spoiler-title h2 {
  font-weight: 500;
}

.settings-spoiler-clean .settings-spoiler-title p,.setting-row-clean div p {
  font-weight: 400;
}

.setting-row-clean div span {
  font-weight: 500;
}

.setting-row-clean code {
  font-weight: 400;
}

.setting-row-clean input,.setting-row-clean select,.setting-row-clean textarea {
  font-weight: 400;
  color: #14213d;
  background: #fff;
}

.score-real-block h3 {
  font-weight: 500;
}

.settings-spoiler-count,.settings-spoiler-chevron {
  font-weight: 400;
}

.settings-saved-note {
  margin: 0 0 14px;
  padding: 12px 14px;
  border: 1px solid #bbf7d0;
  background: #f0fdf4;
  color: #166534;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 400;
}

.settings-rows-clean .setting-row-clean {
  border-bottom: 1px solid #edf2f7;
}

.settings-rows-clean .setting-row-clean:last-child {
  border-bottom: 0;
}

/* Settings cleanup: lighter typography and proper spoiler arrow */

.settings-spoiler-clean .settings-spoiler-title h2,
.score-real-block h3,
.setting-row-clean div span,
.settings-spoiler-count,
.settings-spoiler-clean .settings-spoiler-count,
.card h2,
.action-card h2,
.quick-action b,
.admin-menu-popover a,
.admin-menu-popover button,
.top-user b,
.sidebar b,
.brand-text b,
.kpi-card b,
.metric strong,
th {
  font-weight: 500 !important;
}

.settings-spoiler-clean .settings-spoiler-title p,
.setting-row-clean div p,
.setting-row-clean code,
.setting-row-clean input,
.setting-row-clean select,
.setting-row-clean textarea,
.settings-saved-note,
.savebar-clean .muted {
  font-weight: 400 !important;
}

.settings-spoiler-chevron {
  position: relative;
  font-size: 0 !important;
  line-height: 0;
}

.settings-spoiler-chevron::before {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-top: -4px;
  display: block;
  transition: transform .18s ease, margin .18s ease;
}

.settings-spoiler[open] .settings-spoiler-chevron {
  transform: none !important;
}

.settings-spoiler[open] .settings-spoiler-chevron::before {
  transform: rotate(225deg);
  margin-top: 4px;
}

.score-real-body {
  padding: 16px !important;
}

.score-real-block h3 {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 12px 16px !important;
  background: #f8fbff !important;
}

.setting-row-clean {
  align-items: center;
}

.setting-row-clean input,
.setting-row-clean select,
.setting-row-clean textarea {
  max-width: 520px;
  width: 100%;
}

/* Score settings: beginner-friendly grouping */

.score-guide {
  display: grid;
  grid-template-columns: minmax(260px,1fr) minmax(260px,420px);
  gap: 14px;
  margin: 0 0 14px;
}

.score-guide>div {
  border: 1px solid #e1e9f5;
  background: #fff;
  border-radius: 9px;
  padding: 16px 18px;
}

.score-guide h3 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 500;
  color: #10213d;
}

.score-guide p {
  margin: 0;
  color: #60708d;
  font-size: 13px;
  line-height: 1.55;
  font-weight: 400;
}

.score-example span {
  display: inline-flex;
  margin-bottom: 8px;
  color: #2452db;
  background: #eef4ff;
  border: 1px solid #dbe8ff;
  border-radius: 9px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 400;
}

.score-subspoiler {
  padding: 0;
}

.score-subspoiler summary {
  list-style: none;
}

.score-subspoiler summary::-webkit-details-marker {
  display: none;
}

.score-subsummary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  padding: 0 4px 0 0;
  background: #f8fbff;
  border-bottom: 1px solid transparent;
}

.score-subspoiler[open] .score-subsummary {
  border-bottom-color: #e5edf6;
}

.score-subsummary h3 {
  border-bottom: 0 !important;
  background: transparent !important;
  flex: 1;
}

.score-subsummary .settings-spoiler-chevron {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  margin-right: 10px;
  background: #fff;
  border-color: #dbe5f2;
  color: #60708d;
}

.score-subspoiler[open] .settings-spoiler-chevron::before {
  transform: rotate(225deg);
  margin-top: 4px;
}

.score-subspoiler:not([open]) .settings-spoiler-chevron::before {
  transform: rotate(45deg);
  margin-top: -4px;
}

.score-rows-friendly {
  background: #fff;
}

.score-setting-row {
  grid-template-columns: minmax(340px,1fr) minmax(180px,320px);
}

.score-setting-row div span {
  font-size: 14px;
  font-weight: 500 !important;
}

.score-setting-row div p {
  max-width: 760px;
  margin: 6px 0 6px;
  color: #63718a;
}

.score-setting-row code {
  opacity: .62;
  font-size: 11px;
}

.score-setting-row input,
.score-setting-row select {
  justify-self: end;
  max-width: 320px;
}

.score-real-body .score-real-block {
  margin-bottom: 10px;
}

.score-real-body .score-real-block:last-child {
  margin-bottom: 0;
}

@media (max-width:900px) {
  .score-guide {
    grid-template-columns: 1fr;
  }
  .score-setting-row {
    grid-template-columns: 1fr;
  }
  .score-setting-row input,.score-setting-row select {
    justify-self: stretch;
    max-width: 100%;
  }
}

.dept-summary-spoiler {
  padding: 0;
  overflow: hidden;
}

.dept-summary-spoiler-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  cursor: pointer;
  list-style: none;
}

.dept-summary-spoiler-summary::-webkit-details-marker {
  display: none;
}

.dept-summary-spoiler-summary h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 560;
  color: #10203c;
}

.dept-summary-spoiler-count {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  height: 30px;
  padding: 0 10px;
  border-radius: 9px;
  background: #eef4ff;
  color: #2563eb;
  font-size: 13px;
  font-weight: 560;
}

.dept-summary-spoiler-body {
  border-top: 1px solid var(--border);
  padding: 18px 20px 20px;
}

/* Login inputs: remove browser autofill blue background */

.login-input input,
.login-input input:-webkit-autofill,
.login-input input:-webkit-autofill:hover,
.login-input input:-webkit-autofill:focus,
.login-input input:-webkit-autofill:active {
  background: #fff !important;
  -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
  box-shadow: 0 0 0 1000px #fff inset !important;
  -webkit-text-fill-color: #0f1f3c !important;
  caret-color: #0f1f3c;
  border-radius: 9px;
}

:root {
  --radius: 9px;
  --radius2: 9px;
}

button,input,select,textarea,.btn,.card,.panel,.hero-card,.action-card,.badge,.status-pill,.mini-btn,.admin-card,.admin-menu-popover,.side-nav a,.brand-icon,.kpi-card,.kpi-icon,.table-wrap,.human-card,.human-lead-card,.human-manager-row,.dept-summary-tile,.dept-summary-stats span,.settings-spoiler,.settings-spoiler-count,.settings-spoiler-chevron {
  border-radius: 9px !important;
}

.admin-menu-popover {
  padding: 6px;
}

.admin-menu-popover button {
  border-radius: 9px;
}

/* fix: tabs should have a clean straight underline, not a rounded button border */

.users-tabs-v31 button {
  border-radius: 0 !important;
  border-left: 0 !important;
  border-right: 0 !important;
  border-top: 0 !important;
  box-shadow: none !important;
}

.users-tabs-v31 button.active {
  border-bottom: 2px solid #2563eb !important;
}

/* Lazy lead reveal in report detail */

.lead-scroll-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 10px;
  border: 1px dashed #cfd9e8;
  border-radius: 9px;
  background: #f8fbff;
  color: #667594;
  font-size: 13px;
  font-weight: 500;
}

.lead-scroll-loader.is-done {
  border-style: solid;
  background: #fff;
  color: #8a96aa;
}

.human-lead-card[hidden] {
  display: none !important;
}

.run-actions-scheduler-spoiler {
  margin-bottom: 18px;
}

.run-actions-scheduler-spoiler .scheduler-summary-icon {
  background: #eef4ff;
  color: #2563eb;
}

.run-actions-scheduler-spoiler .scheduler-body {
  padding: 18px 20px 20px;
}

.run-actions-scheduler-spoiler .run-actions-body {
  border-top: 1px solid #e6edf7;
  background: #fff;
}

.run-actions-scheduler-spoiler .run-actions-tabs {
  width: max-content;
  max-width: 100%;
}

.runs-filter-toolbar {
  justify-content: flex-start;
}

@media (max-width:1180px) {
  .run-actions-scheduler-spoiler .run-actions-tabs {
    width: 100%;
  }
}

.run-actions-help-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 12px;
  color: #65728a;
  font-size: 13px;
  line-height: 1.35;
}

.run-actions-help-inline span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.run-actions-help-inline b {
  color: #1b2d4a;
  font-weight: 850;
}

.run-actions-scheduler-spoiler .run-actions-tabs,
.run-actions-tabs {
  gap: 0 !important;
  border-radius: 0 !important;
}

.run-actions-tabs form {
  display: flex !important;
  margin: 0 !important;
  padding: 0 !important;
}

.run-actions-tabs .run-tab,
.run-tab {
  border-radius: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
}

.run-actions-tabs form:first-child .run-tab,
.run-actions-tabs form:last-child .run-tab {
  border-radius: 0 !important;
}

.run-actions-scheduler-spoiler .run-actions-description {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(180px,1fr));
  gap: 8px;
  margin: 0 0 14px;
}

.run-actions-scheduler-spoiler .run-actions-description div {
  border: 1px solid #e4ebf5;
  background: #f8fbff;
  padding: 9px 11px;
  display: grid;
  gap: 2px;
  border-radius: 0 !important;
}

.run-actions-scheduler-spoiler .run-actions-description b {
  color: #11233f;
  font-size: 13px;
  font-weight: 700;
}

.run-actions-scheduler-spoiler .run-actions-description span {
  color: #65728a;
  font-size: 12px;
  line-height: 1.25;
}

.run-actions-scheduler-spoiler .run-actions-help-inline {
  display: none !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs {
  display: flex !important;
  align-items: stretch !important;
  gap: 0 !important;
  width: max-content !important;
  max-width: 100% !important;
  overflow: hidden !important;
  border: 1px solid #dbe5f2 !important;
  border-radius: 0 !important;
  background: #fff !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs form {
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs .run-tab {
  height: 42px !important;
  margin: 0 !important;
  border-radius: 0 !important;
  border-top: 0 !important;
  border-bottom: 0 !important;
  border-left: 0 !important;
  border-right: 1px solid #dbe5f2 !important;
  box-shadow: none !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs form:last-child .run-tab {
  border-right: 0 !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs .run-tab.is-primary {
  border-radius: 0 !important;
  box-shadow: none !important;
}

@media (max-width:760px) {
  .run-actions-scheduler-spoiler .run-actions-tabs {
    width: 100% !important;
    display: grid !important;
  }
  .run-actions-scheduler-spoiler .run-actions-tabs form {
    width: 100% !important;
  }
  .run-actions-scheduler-spoiler .run-actions-tabs .run-tab {
    width: 100% !important;
    border-right: 0 !important;
    border-bottom: 1px solid #dbe5f2 !important;
    justify-content: flex-start !important;
  }
  .run-actions-scheduler-spoiler .run-actions-tabs form:last-child .run-tab {
    border-bottom: 0 !important;
  }
}

.run-actions-scheduler-spoiler .run-actions-tabs,
.run-actions-scheduler-spoiler .run-actions-tabs form,
.run-actions-scheduler-spoiler .run-actions-tabs button.run-tab,
.run-actions-scheduler-spoiler .run-actions-tabs .run-tab,
.run-actions-scheduler-spoiler .run-actions-tabs .run-tab.is-primary {
  border-radius: 0 !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs button.run-tab::before,
.run-actions-scheduler-spoiler .run-actions-tabs button.run-tab::after {
  border-radius: 0 !important;
}

.run-actions-scheduler-spoiler .run-actions-description {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
  margin: 0 0 14px !important;
}

.run-actions-scheduler-spoiler .run-actions-description div {
  display: block !important;
  border: 1px solid #e4ebf5 !important;
  background: #f8fbff !important;
  padding: 9px 11px !important;
  border-radius: 0 !important;
  line-height: 1.35 !important;
}

.run-actions-scheduler-spoiler .run-actions-description b {
  display: inline !important;
  margin-right: 4px !important;
  color: #11233f !important;
  font-size: 13px !important;
  font-weight: 800 !important;
}

.run-actions-scheduler-spoiler .run-actions-description span {
  display: inline !important;
  color: #65728a !important;
  font-size: 13px !important;
  line-height: 1.35 !important;
}

.run-actions-scheduler-spoiler .run-actions-tabs,
.run-actions-scheduler-spoiler .run-actions-tabs *,
.run-actions-scheduler-spoiler .run-actions-tabs button,
.run-actions-scheduler-spoiler .run-actions-tabs .run-tab {
  border-radius: 0 !important;
}

.runs-filter-toolbar {
  display: none !important;
}

.runs-table-card {
  padding: 0 0 18px !important;
  overflow: hidden;
}

.runs-table-head {
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 18px 28px 14px;
  border-bottom: 1px solid var(--v9-border);
  background: #fff;
}

.runs-filter-inline {
  margin: 0;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.runs-filter-inline label {
  min-width: 168px;
}

.runs-filter-inline select {
  height: 40px;
  border-radius: 0 !important;
  background: #fff;
}

.runs-filter-reset {
  height: 40px;
  align-items: center;
}

.runs-table-card .table-wrap {
  padding: 0 28px;
}

@media (max-width:760px) {
  .runs-table-head {
    padding: 14px;
  }
  .runs-filter-inline {
    width: 100%;
  }
  .runs-filter-inline label {
    min-width: 100%;
    width: 100%;
  }
  .runs-filter-reset {
    width: 100%;
    justify-content: center;
  }
  .runs-table-card .table-wrap {
    padding: 0 14px;
  }
}

@media (max-width: 1180px) {
  .app-shell,.minimal-shell {
    display: block !important;
    min-height: 100vh !important;
  }
  .sidebar,.minimal-sidebar {
    position: sticky !important;
    top: 0 !important;
    z-index: 60 !important;
    height: auto !important;
    min-height: 0 !important;
    width: 100% !important;
    padding: 10px 12px !important;
    display: grid !important;
    grid-template-columns: auto minmax(0,1fr) auto !important;
    gap: 10px !important;
    align-items: center !important;
    background: linear-gradient(135deg,#111d35,#0b172b) !important;
    border-bottom: 1px solid rgba(255,255,255,.08) !important;
  }
  .brand,.minimal-brand {
    margin: 0 !important;
    padding: 0 !important;
    min-width: max-content !important;
    gap: 10px !important;
    text-decoration: none !important;
  }
  .brand-icon {
    width: 38px !important;
    height: 38px !important;
    font-size: 18px !important;
    flex: 0 0 auto !important;
  }
  .brand b {
    font-size: 16px !important;
    color: #fff !important;
    line-height: 1.1 !important;
  }
  .brand small {
    font-size: 11px !important;
    line-height: 1.1 !important;
  }
  .side-nav,.minimal-nav {
    display: flex !important;
    gap: 6px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    white-space: nowrap !important;
    padding: 2px 2px 4px !important;
    scrollbar-width: thin !important;
    -webkit-overflow-scrolling: touch !important;
  }
  .side-nav a {
    flex: 0 0 auto !important;
    padding: 9px 11px !important;
    border-radius: 9px !important;
    gap: 7px !important;
    font-size: 13px !important;
  }
  .side-nav a span,.side-nav a i,.side-nav a svg {
    width: 17px !important;
    height: 17px !important;
    font-size: 16px !important;
    flex: 0 0 auto !important;
  }
  .side-help,.theme-pill {
    display: none !important;
  }
  .admin-menu,.minimal-admin {
    margin: 0 !important;
    align-self: center !important;
    position: relative !important;
  }
  .admin-card {
    padding: 7px !important;
    min-width: auto !important;
    gap: 6px !important;
  }
  .admin-card .avatar,.avatar.small {
    width: 32px !important;
    height: 32px !important;
  }
  .admin-card-text,.admin-chevron {
    display: none !important;
  }
  .admin-menu-popover {
    right: 0 !important;
    left: auto !important;
    top: 44px !important;
    min-width: 150px !important;
  }
  .main,.minimal-main {
    width: 100% !important;
    min-width: 0 !important;
  }
  .page-head,.minimal-page-head {
    padding: 18px 16px 12px !important;
    gap: 12px !important;
    align-items: flex-start !important;
    flex-wrap: wrap !important;
  }
  .page-head h1 {
    font-size: 26px !important;
    line-height: 1.12 !important;
  }
  .page-head p {
    font-size: 14px !important;
    line-height: 1.35 !important;
  }
  .page-actions {
    width: 100% !important;
    justify-content: flex-start !important;
  }
  .page-actions .btn,.page-actions form,.page-actions button {
    max-width: 100% !important;
  }
  .full-width,.content-grid {
    padding: 0 16px 22px !important;
  }
  .content-grid,.minimal-grid,.qc-main-grid,.qc-bottom-grid,.qc-risk-grid,.grid-2,.grid-3,.run-grid,.run-help-grid,.users-secondary-grid,.human-drilldown-grid {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }
  .kpi-row,.minimal-kpi-row,.qc-kpi-row,.runs-kpi-grid,.users-kpi-row-v31,.action-grid {
    grid-template-columns: repeat(2,minmax(0,1fr)) !important;
    gap: 10px !important;
  }
  .card,.panel,.hero-card,.action-card,.minimal-card {
    padding: 16px !important;
  }
  .card-head,.minimal-card-head,.dist-table-head,.users-topbar,.runs-table-head {
    gap: 10px !important;
    flex-wrap: wrap !important;
    align-items: flex-start !important;
  }
  .table-wrap,.dist-table-wrap,.clean-table-wrap {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    max-width: 100% !important;
  }
  table,.clean-table,.dist-clean-table,.runs-table,.users-table-v31 {
    font-size: 13px !important;
  }
  th,td,.dist-clean-table th,.dist-clean-table td {
    padding: 11px 9px !important;
  }
}

@media (max-width: 720px) {
  body {
    font-size: 14px !important;
    overflow-x: hidden !important;
  }
  .sidebar,.minimal-sidebar {
    grid-template-columns: 1fr auto !important;
    padding: 9px 10px !important;
    gap: 8px !important;
  }
  .brand,.minimal-brand {
    grid-column: 1/2 !important;
    max-width: 100% !important;
    overflow: hidden !important;
  }
  .brand div:last-child {
    min-width: 0 !important;
  }
  .side-nav,.minimal-nav {
    grid-column: 1 / -1 !important;
    order: 3 !important;
    margin-top: 2px !important;
    padding-bottom: 5px !important;
  }
  .side-nav a {
    padding: 8px 10px !important;
    font-size: 12px !important;
    gap: 6px !important;
  }
  .admin-menu,.minimal-admin {
    grid-column: 2/3 !important;
    grid-row: 1 !important;
  }
  .page-head,.minimal-page-head {
    padding: 16px 12px 10px !important;
  }
  .page-head h1 {
    font-size: 23px !important;
  }
  .full-width,.content-grid {
    padding: 0 12px 18px !important;
  }
  .kpi-row,.minimal-kpi-row,.qc-kpi-row,.runs-kpi-grid,.users-kpi-row-v31,.action-grid {
    grid-template-columns: 1fr !important;
  }
  .kpi-card,.minimal-kpi {
    padding: 14px !important;
    min-height: auto !important;
  }
  .kpi-icon {
    width: 42px !important;
    height: 42px !important;
    font-size: 19px !important;
  }
  .kpi-card strong {
    font-size: 24px !important;
  }
  .qc-alert {
    display: grid !important;
    grid-template-columns: 42px 1fr !important;
    gap: 12px !important;
    align-items: start !important;
  }
  .qc-alert-icon {
    width: 42px !important;
    height: 42px !important;
  }
  .qc-alert-copy h2 {
    font-size: 18px !important;
    line-height: 1.25 !important;
  }
  .qc-alert-actions {
    grid-column: 1 / -1 !important;
    width: 100% !important;
  }
  .qc-alert-actions .btn {
    width: 100% !important;
  }
  .btn {
    width: auto;
    max-width: 100%;
    padding: 10px 12px !important;
    font-size: 13px !important;
  }
  .page-actions .btn,.page-actions button,.page-actions form {
    width: 100% !important;
  }
  .dist-manual-compact {
    padding: 14px !important;
  }
  .dist-manual-info {
    align-items: flex-start !important;
    gap: 10px !important;
  }
  .dist-manual-row {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }
  .manual-table-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    width: 100% !important;
    gap: 8px !important;
  }
  .dist-action-btn,.row-action {
    width: 100% !important;
    height: 40px !important;
  }
  .dist-table-card {
    padding: 14px !important;
  }
  .dist-table-head h2,.dist-spoiler-summary h2 {
    font-size: 17px !important;
  }
  .dist-table-head p,.dist-spoiler-summary p {
    font-size: 12px !important;
  }
  .dist-spoiler-summary.dist-table-head {
    padding: 14px !important;
    align-items: flex-start !important;
  }
  .dist-spoiler-summary.dist-table-head::after {
    width: 100% !important;
    justify-content: center !important;
    order: 4 !important;
    margin-top: 8px !important;
  }
  .dist-spoiler-summary.dist-table-head .spoiler-count {
    margin-left: 0 !important;
    order: 3 !important;
  }
  .dist-spoiler-body {
    padding: 0 14px 14px !important;
  }
  .dist-person-name {
    max-width: 170px !important;
    white-space: normal !important;
  }
  .dist-reason-cell {
    max-width: 240px !important;
  }
  .dist-row-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 6px !important;
    min-width: 110px !important;
  }
  .runs-table-card .table-wrap {
    padding: 0 12px !important;
  }
  .users-topbar,.users-actions-v31,.users-filter-v31,.users-manual-form-v31,.settings-form-clean,.settings-rows-clean,.runs-filter-inline {
    display: grid !important;
    grid-template-columns: 1fr !important;
    width: 100% !important;
  }
  .users-search-v31,.users-filter-v31 input,.users-filter-v31 select,.users-actions-v31 .btn,.settings-form-clean input,.settings-form-clean select,.settings-form-clean textarea {
    width: 100% !important;
    max-width: 100% !important;
  }
  .users-tabs-v31 {
    overflow-x: auto !important;
    white-space: nowrap !important;
    -webkit-overflow-scrolling: touch !important;
  }
  .human-manager-row,.human-lead-top,.report-list div,.reason-row {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }
  .human-lead-meta {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 6px !important;
  }
}

@media (max-width: 540px) {
  .login-page {
    min-height: 100vh !important;
    padding: 16px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
  .login-card {
    width: 100% !important;
    max-width: 420px !important;
    padding: 22px 18px !important;
    border-radius: 9px !important;
  }
  .login-card-head h2 {
    font-size: 22px !important;
    line-height: 1.15 !important;
  }
  .login-card-head p {
    font-size: 13px !important;
  }
  .login-input {
    height: 52px !important;
  }
  .login-submit {
    height: 52px !important;
    width: 100% !important;
  }
  .side-nav a em {
    display: inline !important;
  }
  .card,.panel,.hero-card,.action-card,.minimal-card {
    padding: 14px !important;
  }
  .clean-table,.dist-clean-table,.removed-clean-table,.runs-table,.users-table-v31 {
    min-width: 760px !important;
  }
  .risk-table {
    min-width: 620px !important;
  }
  .page-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
  }
  .notice-banner {
    align-items: flex-start !important;
    font-size: 13px !important;
  }
}

@media (max-width: 380px) {
  .side-nav a {
    padding: 8px 9px !important;
  }
  .side-nav a em {
    font-size: 11px !important;
  }
  .brand b {
    font-size: 15px !important;
  }
  .page-head h1 {
    font-size: 21px !important;
  }
  .login-page {
    padding: 10px !important;
  }
}

.login-card-head {
  margin-bottom: 28px !important;
}

.login-input {
  transition: none !important;
}

@media (max-width:540px) {
  .login-card-head {
    margin-bottom: 24px !important;
  }
}

/* Login screen cleanup */

.login-card-head {
  margin-bottom: 30px !important;
}

.login-input {
  transition: .15s ease !important;
}

.login-input input:-webkit-autofill,
.login-input input:-webkit-autofill:hover,
.login-input input:-webkit-autofill:focus,
.login-input input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
  box-shadow: 0 0 0 1000px #fff inset !important;
  -webkit-text-fill-color: #0f1f3c !important;
}

@media (max-width:540px) {
  .login-card-head {
    margin-bottom: 26px !important;
  }
}

/* Login form tweaks */

/* Login screen */

.login-card-logo {
  width: 350px !important;
  max-width: 100% !important;
  height: 140px !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  margin: 0 auto 34px !important;
  padding: 0 !important;
  overflow: visible !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.login-card-logo img {
  display: block !important;
  width: 350px !important;
  max-width: 100% !important;
  height: auto !important;
  max-height: 140px !important;
  object-fit: contain !important;
}

.login-card-head {
  margin-bottom: 30px !important;
}

.login-card-head h2,
.login-card-head p {
  display: none !important;
}

.login-input {
  transition: .15s ease !important;
}

.login-input:focus-within {
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, .10) !important;
  outline: 0 !important;
}

.login-input input:focus,
.login-input input:focus-visible {
  outline: none !important;
}

.login-input input::placeholder {
  color: rgba(100, 116, 139, .48) !important;
}

.login-input input:-webkit-autofill,
.login-input input:-webkit-autofill:hover,
.login-input input:-webkit-autofill:focus,
.login-input input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
  box-shadow: 0 0 0 1000px #fff inset !important;
  -webkit-text-fill-color: #0f1f3c !important;
}

@media (max-width: 420px) {
  .login-card-logo,
  .login-card-logo img {
    width: 300px !important;
    max-width: 100% !important;
  }
}
