
:root {
  color-scheme: light;
  --bg: #f6f7f9;
  --panel: #ffffff;
  --text: #17202a;
  --muted: #657080;
  --border: #dfe4ea;
  --accent: #2364aa;
  --accent-strong: #174b83;
  --success: #e8f6ef;
  --success-text: #15633f;
  --error: #fff0ee;
  --error-text: #a23425;
}
* { box-sizing: border-box; }
html.is-updating, html.is-updating * { cursor: progress; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
}
.topbar {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
  padding: 10px 28px;
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 80;
}
.topbar span { color: var(--muted); margin-left: 14px; }
.navlinks { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.topbar form { flex: 0 0 auto; }
.navlinks a {
  color: #344052;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  padding: 8px 10px;
  border-radius: 6px;
}
.navlinks a:hover { background: #eef3f8; color: var(--accent); }
.navlinks a.active {
  background: #e8f1fb;
  color: var(--accent);
  box-shadow: inset 0 0 0 1px #d6e6f8;
}
.container { width: min(1180px, calc(100% - 32px)); margin: 24px auto 48px; }
.compliance-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px 20px;
  padding: 20px 16px;
  margin-top: 24px;
  color: #657080;
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}
.compliance-footer a { color: inherit; text-decoration: none; }
.compliance-footer a:hover, .compliance-footer a:focus-visible { color: #245fc3; text-decoration: underline; }
.login-page {
  min-height: 100vh;
  background: #eef2f8;
}
.login-page .container {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 100vh;
  margin: 0;
}
.login-wrap {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(430px, .65fr);
}
.login-visual {
  position: relative;
  min-height: 0;
  overflow: hidden;
  background-color: #e9eef7;
  background-image: url("/static/login-data-workspace-v2.jpg");
  background-position: center;
  background-size: cover;
}
.login-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(239, 243, 250, .16);
}
.login-brand {
  position: absolute;
  z-index: 1;
  top: 34px;
  left: 38px;
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: calc(100% - 76px);
}
.login-brand img {
  display: block;
  width: 248px;
  height: auto;
}
.login-brand span {
  color: #4e5968;
  font-size: 14px;
  font-weight: 700;
}
.login-visual-copy {
  position: absolute;
  z-index: 1;
  left: clamp(38px, 6vw, 96px);
  bottom: clamp(58px, 10vh, 112px);
  max-width: 560px;
  color: #17202a;
}
.login-eyebrow {
  display: block;
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  color: #a7192f;
}
.login-visual-copy h1 {
  font-size: 44px;
  line-height: 1.18;
}
.login-visual-copy p {
  margin: 14px 0 0;
  color: #566273;
  font-size: 20px;
  font-weight: 600;
}
.login-form-area {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
  padding: 42px clamp(28px, 4vw, 72px) 28px;
  background: #eef2f8;
}
.login-mobile-logo { display: none; }
.login-panel {
  width: min(470px, 100%);
  background: var(--panel);
  border: 1px solid #d9e0e8;
  border-radius: 8px;
  padding: 34px;
  box-shadow: 0 18px 42px rgba(24, 33, 44, .10);
}
.login-heading > span {
  display: block;
  margin-bottom: 9px;
  color: #a7192f;
  font-size: 13px;
  font-weight: 800;
}
.login-heading h2 {
  font-size: 26px;
  line-height: 1.3;
}
.login-heading p {
  margin: 8px 0 0;
  color: #657080;
  font-size: 14px;
}
.login-alert {
  margin: 20px 0 0;
}
.login-tabs {
  display: flex;
  gap: 30px;
  margin: 26px 0 22px;
  border-bottom: 1px solid #e1e6ec;
}
.login-tab {
  position: relative;
  min-height: 40px;
  padding: 0 2px 12px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #657080;
  font-weight: 700;
}
.login-tab:hover {
  background: transparent;
  color: #1f2937;
}
.login-tab.active {
  color: #a7192f;
}
.login-tab.active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: #a7192f;
}
.login-tab-panel[hidden] { display: none; }
.login-form {
  display: grid;
  gap: 16px;
}
.login-form label {
  gap: 7px;
  font-size: 13px;
}
.login-form input {
  min-height: 46px;
  border-color: #cfd7e2;
  background: #fff;
}
.login-form input:focus {
  outline: 2px solid rgba(167, 25, 47, .16);
  border-color: #a7192f;
}
.login-form label.login-trust { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13px; }
.login-form .login-trust input { width: 16px; min-height: 16px; height: 16px; margin: 0; padding: 0; accent-color: #b31335; }
.login-verification-title { margin: 24px 0 12px; font-size: 18px; }
.login-verification-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; font-size: 13px; }
.login-verification-actions button { min-width: 120px; }
.login-verification-actions button:disabled { cursor: default; opacity: .6; }
.login-submit {
  width: 100%;
  min-height: 46px;
  margin-top: 4px;
  border-color: #a7192f;
  background: #a7192f;
}
.login-submit:hover {
  border-color: #7f1022;
  background: #7f1022;
}
.login-submit:disabled,
.phone-code-button:disabled {
  border-color: #d8dde4;
  background: #eef1f4;
  color: #98a2af;
  cursor: not-allowed;
}
.phone-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 116px;
  gap: 8px;
}
.phone-code-button {
  min-height: 46px;
  padding: 0 12px;
}
.login-state-note,
.login-account-note {
  margin: 0;
  color: #7a8492;
  font-size: 12px;
  text-align: center;
}
.login-account-note {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid #e6eaf0;
}
.login-page .compliance-footer {
  margin-top: 0;
  color: #7a8492;
  font-size: 12px;
  text-align: center;
}
.hero {
  background: #18212c;
  color: #fff;
  padding: 28px;
  border-radius: 8px;
  margin-bottom: 18px;
}
h1, h2 { margin: 0; letter-spacing: 0; }
h1 { font-size: 28px; line-height: 1.25; }
h2 { font-size: 18px; }
p { color: var(--muted); line-height: 1.65; }
.hero p { color: #d8e0ea; margin-bottom: 0; }
.grid { display: grid; gap: 18px; margin-bottom: 18px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.admin-upload-layout {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
}
.admin-upload-card {
  width: 100%;
}
.admin-upload-card form.stack {
  grid-template-columns: minmax(320px, 1fr) minmax(180px, 260px);
  align-items: end;
}
.admin-upload-card form.stack .hint,
.admin-upload-card form.stack p {
  grid-column: 1 / -1;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 18px;
}
.panel.compact { margin-bottom: 0; }
.inline-note {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid #e2e7ee;
}
.inline-note h2 {
  margin-bottom: 10px;
}
.inline-note p {
  margin: 0 0 8px;
}
.stack { display: grid; gap: 14px; }
label { display: grid; gap: 7px; color: #344052; font-weight: 600; }
input, select, textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid #cfd7e2;
  border-radius: 6px;
  padding: 0 12px;
  font: inherit;
  background: #fff;
}
textarea { padding: 10px 12px; resize: vertical; line-height: 1.45; }
input[type=file] { padding: 9px 12px; }
button, .button {
  min-height: 42px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  padding: 0 15px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
button:hover, .button:hover { background: var(--accent-strong); }
.ghost {
  background: #fff;
  color: var(--accent);
}
.ghost:hover { background: #eef5fc; }
.hint, .muted { color: var(--muted); font-size: 13px; }
.alert {
  padding: 12px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
  border: 1px solid transparent;
}
.alert.success { background: var(--success); color: var(--success-text); border-color: #bde5cf; }
.alert.error { background: var(--error); color: var(--error-text); border-color: #f2beb6; }
.section-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 14px;
}
.section-title span { color: var(--muted); font-size: 13px; }
.filters {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(150px, 220px) auto auto;
  gap: 10px;
  margin-bottom: 14px;
}
.filters.advanced {
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  align-items: end;
}
.filters.advanced label { font-size: 13px; }
.report-filter-form {
  display: grid;
  grid-template-columns: minmax(250px, 1.2fr) minmax(150px, .75fr) minmax(220px, 1fr) auto auto auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 14px;
}
.report-filter-form.with-group {
  grid-template-columns: minmax(230px, 1.2fr) minmax(140px, .7fr) minmax(180px, 1fr) minmax(140px, .7fr) auto auto auto;
}
.report-filter-form.dashboard-dynamic-filters {
  grid-template-columns: minmax(230px, 1.15fr) minmax(140px, .65fr) minmax(130px, .55fr) minmax(180px, 1fr) auto auto auto;
}
.report-filter-form > label {
  min-width: 0;
  font-size: 13px;
}
.report-filter-form > button,
.report-filter-form > .button {
  white-space: nowrap;
}
.report-filter-form.is-loading-options [data-report-filter-value],
.report-filter-form.is-loading-options .report-filter-row input {
  background-color: #f3f6f9;
  cursor: progress;
}
.report-filter-chips {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  flex-wrap: wrap;
}
.report-filter-chips[hidden] {
  display: none;
}
.report-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 5px 10px;
  border: 1px solid #cfe0f5;
  border-radius: 6px;
  background: #eef5fc;
  color: #175ca8;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
.report-filter-chip:hover {
  border-color: #9fc1e8;
  background: #e2effc;
}
.report-filter-chip span {
  font-size: 17px;
  line-height: 1;
}
.filter-export-row {
  display: flex;
  justify-content: flex-end;
  margin: -4px 0 12px;
}
.refund-amount {
  color: #c62828;
  font-weight: 700;
}
.refund-badge {
  display: inline-block;
  margin-right: 6px;
  padding: 1px 5px;
  border: 1px solid #ef9a9a;
  border-radius: 4px;
  background: #ffebee;
  color: #b71c1c;
  font-size: 11px;
  line-height: 1.4;
  vertical-align: 1px;
}
.report-filter-modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, .48);
}
.report-filter-modal[hidden] {
  display: none;
}
body.report-filter-modal-open {
  overflow: hidden;
}
.report-filter-dialog {
  width: min(760px, calc(100vw - 32px));
  max-height: min(720px, calc(100vh - 48px));
  overflow: auto;
  padding: 20px;
  border: 1px solid #d8e0ea;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 60px rgba(15, 23, 42, .24);
}
.report-filter-dialog-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.report-filter-dialog-title h2 {
  margin: 0;
}
.icon-button {
  width: 36px;
  min-width: 36px;
  min-height: 36px;
  padding: 0;
  border-color: transparent;
  background: transparent;
  color: #5b6675;
  font-size: 23px;
}
.icon-button:hover {
  border-color: #d8e0ea;
  background: #f3f6f9;
  color: #1f2937;
}
.icon-button.danger-text {
  color: #c63f32;
}
.report-filter-rows {
  display: grid;
  gap: 10px;
  margin: 18px 0 12px;
}
.report-filter-row {
  display: grid;
  grid-template-columns: minmax(150px, 210px) minmax(220px, 1fr) 36px;
  gap: 10px;
  align-items: center;
}
.report-filter-row datalist {
  display: none;
}
.add-filter-button {
  min-height: 38px;
}
.report-filter-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid #e2e7ee;
}
.spend-filters {
  grid-template-columns: minmax(260px, 360px) minmax(180px, 240px) minmax(180px, 280px) minmax(150px, 220px);
}
.client-filters {
  display: grid;
  grid-template-columns: repeat(6, minmax(130px, 1fr));
  gap: 12px;
  align-items: end;
  padding: 14px;
  margin-bottom: 14px;
  border: 1px solid #d8e0ea;
  border-radius: 8px;
  background: #f8fafc;
}
.client-filters label {
  font-size: 13px;
  color: #405066;
}
.client-filters input,
.client-filters select {
  min-height: 38px;
  background: #fff;
}
.preview-selector {
  display: grid;
  grid-template-columns: minmax(260px, 420px) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 10px;
}
.date-range-field {
  position: relative;
  display: grid;
  gap: 7px;
}
.filter-label {
  color: #344052;
  font-size: 13px;
  font-weight: 600;
}
.date-range-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  padding: 0 11px;
  border-color: #cfd7e2;
  background: #fff;
  color: #263241;
  font-weight: 500;
}
.date-range-display:hover {
  background: #fff;
  border-color: var(--accent);
  color: #263241;
}
.date-range-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.date-range-icon {
  margin-left: auto;
  color: #506176;
  font-size: 15px;
}
.date-range-popover {
  display: none;
  position: absolute;
  left: 0;
  top: calc(100% + 6px);
  z-index: 30;
  width: min(760px, calc(100vw - 48px));
  min-height: 320px;
  padding: 0;
  border: 1px solid #cfd7e2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(20, 32, 50, 0.16);
  grid-template-columns: 116px minmax(0, 1fr);
  overflow: hidden;
}
.date-range-field.open .date-range-popover {
  display: grid;
}
.range-shortcuts {
  display: grid;
  align-content: start;
  border-right: 1px solid #e2e7ee;
  background: #fbfcfe;
}
.range-shortcuts button {
  min-height: 40px;
  justify-content: flex-start;
  border: 0;
  border-radius: 0;
  padding: 0 14px;
  background: transparent;
  color: #405066;
  font-weight: 500;
}
.range-shortcuts button:hover {
  background: #eef5fc;
  color: var(--accent);
}
.range-calendar-panel {
  min-width: 0;
  padding: 12px;
}
.range-calendar-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.range-calendar-toolbar button {
  min-height: 30px;
  border: 0;
  background: transparent;
  color: #344052;
  padding: 0 9px;
  font-size: 18px;
}
.range-calendar-toolbar button:hover {
  background: #eef5fc;
  color: var(--accent);
}
.range-calendars {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.range-month-title {
  text-align: center;
  font-weight: 800;
  margin-bottom: 10px;
}
.range-weekdays,
.range-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.range-weekdays span {
  color: #6b7686;
  font-size: 13px;
  text-align: center;
}
.range-day {
  min-height: 28px;
  border: 0;
  border-radius: 5px;
  padding: 0;
  background: transparent;
  color: #2b3543;
  font-weight: 500;
}
.range-day:hover {
  background: #eaf3ff;
  color: var(--accent);
}
.muted-day {
  color: #b0b8c3;
}
.disabled-day,
.disabled-day:hover,
.range-day:disabled {
  background: transparent;
  color: #cfd6df;
  cursor: not-allowed;
  opacity: 1;
}
.in-range-day {
  background: #eaf3ff;
}
.selected-day {
  background: var(--accent);
  color: #fff;
}
.selected-day:hover {
  background: var(--accent-strong);
  color: #fff;
}
.range-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid #e2e7ee;
}
.range-footer span {
  margin-right: auto;
  color: var(--muted);
  font-size: 13px;
}
.range-footer button {
  min-height: 34px;
}
.client-filters .filter-search {
  grid-column: span 2;
}
.filter-actions {
  grid-column: span 2;
  display: flex;
  gap: 8px;
  align-items: end;
  justify-content: flex-end;
}
.filter-actions button,
.filter-actions .button {
  min-height: 38px;
  white-space: nowrap;
}
.summary-cards {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}
.summary-cards div {
  min-width: 0;
  border: 1px solid #d8e0ea;
  border-radius: 8px;
  padding: 12px;
  background: linear-gradient(#ffffff, #f8fafc);
}
.summary-cards strong {
  display: block;
  color: #17202a;
  font-size: 18px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.summary-cards span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}
.business-summary-cards {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.business-board-table table {
  min-width: 1240px;
}
.status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}
.status-badge.new {
  color: #047857;
  background: #d1fae5;
}
.status-badge.offline {
  color: #b91c1c;
  background: #fee2e2;
}
.status-badge.active {
  color: #1d4ed8;
  background: #dbeafe;
}
.business-new-row td {
  background: #f0fdf4;
}
.business-offline-row td {
  background: #fff1f2;
}
.dashboard-band {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 18px;
}
.dashboard-section-title {
  align-items: center;
}
.title-tools {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.inline-year-form {
  display: inline-flex;
  align-items: center;
  margin: 0;
}
.inline-year-form label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}
.inline-year-form select {
  min-width: 118px;
  height: 34px;
  padding: 0 28px 0 10px;
}
.group-detail-title .title-tools {
  flex-wrap: wrap;
}
.group-year-summary {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.group-year-summary > div {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
}
.group-year-summary span {
  color: #5b6675;
  font-size: 13px;
  font-weight: 800;
}
.group-year-summary strong {
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}
.date-exclude-select {
  min-width: 168px;
}
.date-exclude-select .multi-select-menu {
  left: auto;
  right: 0;
  width: 310px;
}
.exclude-date-item span {
  flex: 1;
  white-space: nowrap;
}
.exclude-date-item small {
  color: #657080;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.multi-select {
  position: relative;
  min-width: 210px;
}
.multi-select summary {
  list-style: none;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid #cfd7e2;
  border-radius: 6px;
  padding: 0 11px;
  background: #fff;
  color: #263241;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.multi-select summary::-webkit-details-marker {
  display: none;
}
.multi-select summary::after {
  content: "⌄";
  color: #657080;
  font-size: 15px;
}
.multi-select[open] summary {
  border-color: var(--accent);
}
.multi-select-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 20;
  width: 260px;
  padding: 10px;
  border: 1px solid #cfd7e2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(20, 32, 50, 0.16);
}
.check-list {
  display: grid;
  gap: 4px;
  max-height: 240px;
  overflow: auto;
  margin-bottom: 10px;
}
.check-item {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 4px 6px;
  border-radius: 6px;
  color: #263241;
  font-size: 13px;
  font-weight: 600;
}
.check-item:hover {
  background: #eef5fc;
}
.check-item input {
  width: 16px;
  min-height: 16px;
  height: 16px;
  padding: 0;
}
.multi-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.multi-actions button,
.multi-actions .button {
  min-height: 34px;
}
.dashboard-table table {
  min-width: 620px;
}
.dashboard-table th {
  background: #fff2c8;
}
.dashboard-table .total-row td {
  background: #ffd43b;
  font-weight: 800;
}
.dashboard-table .subtotal-row td {
  background: #e6f0fa;
  font-weight: 800;
}
.balance-table {
  max-height: min(58vh, 560px);
  overflow: auto;
}
.balance-table table {
  min-width: 1320px;
}
.balance-table th {
  top: 0;
}
.balance-platform-filter {
  display: grid;
  grid-template-columns: minmax(180px, 260px) auto 1fr;
  align-items: end;
  gap: 10px;
  margin: 10px 0 8px;
}
.balance-platform-filter button {
  min-height: 38px;
}
.balance-overview-filters {
  grid-template-columns: minmax(110px, 150px) minmax(160px, 1fr) minmax(150px, 220px) minmax(220px, 1fr) auto;
}
.balance-dynamic-filters {
  grid-template-columns: minmax(145px, 170px) minmax(90px, 110px) minmax(140px, 170px) minmax(200px, 1fr) auto auto auto;
}
.balance-overview-table {
  max-height: min(62vh, 620px);
}
.balance-overview-table table {
  min-width: 1240px;
}
.balance-status {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 2px 9px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
}
.balance-status.danger {
  color: #b91c1c;
  background: #fee2e2;
}
.balance-status.warn {
  color: #9a3412;
  background: #ffedd5;
}
.balance-status.ok {
  color: #047857;
  background: #d1fae5;
}
.balance-status.idle {
  color: #475569;
  background: #e2e8f0;
}
.service-fee-table table {
  min-width: 720px;
}
.service-fee-table input {
  min-height: 34px;
  text-align: right;
}
.service-fee-table button {
  min-height: 34px;
  padding: 0 14px;
}
.seven-day-search {
  margin-left: 0;
}
.seven-day-table table {
  min-width: 980px;
}
.seven-day-table th:first-child,
.seven-day-table td:first-child {
  font-weight: 800;
}
.seven-day-chart {
  position: relative;
  margin-top: 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}
.seven-day-chart h3 {
  margin: 0 0 8px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
}
.seven-day-chart svg {
  display: block;
  width: 100%;
  height: auto;
}
.chart-point-hit {
  cursor: crosshair;
  outline: none;
}
.chart-point-hit:hover .chart-point-dot,
.chart-point-hit:focus .chart-point-dot {
  stroke: #fff;
  stroke-width: 2;
}
.chart-tooltip {
  position: absolute;
  z-index: 12;
  max-width: 240px;
  padding: 7px 10px;
  transform: translate(-50%, -100%);
  border: 1px solid #334155;
  border-radius: 4px;
  background: #17212b;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 5px 14px rgba(15, 23, 42, 0.2);
}
.seven-day-subtitle {
  margin: 22px 0 10px;
  font-size: 17px;
  font-weight: 800;
  color: #111827;
}
.budget-editor-table table {
  min-width: 720px;
}
.budget-editor-table input {
  min-height: 32px;
  max-width: 160px;
  padding: 0 9px;
  text-align: right;
}
.budget-row-form {
  display: inline-grid;
  grid-template-columns: minmax(130px, 160px) auto;
  gap: 8px;
  align-items: center;
}
.budget-row-form button {
  min-height: 32px;
  padding: 0 14px;
}
.recharge-batch-form {
  display: grid;
  gap: 12px;
}
.recharge-entry-title {
  align-items: center;
}
.recharge-entry-title h2 {
  margin-bottom: 4px;
}
.recharge-import-actions,
.recharge-import-form {
  display: flex;
  align-items: center;
  gap: 8px;
}
.recharge-import-actions .button,
.recharge-import-actions button {
  min-height: 36px;
  padding: 0 14px;
  white-space: nowrap;
}
.recharge-file-button {
  cursor: pointer;
}
.recharge-file-button input {
  display: none;
}
.recharge-file-name {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.recharge-entry-table table {
  min-width: 1180px;
}
.recharge-table {
  max-height: 500px;
  overflow: auto;
  box-shadow: inset 0 1px 0 #fff;
}
.recharge-table table {
  min-width: 980px;
  table-layout: fixed;
}
.recharge-table th:nth-child(1) { width: 10%; }
.recharge-table th:nth-child(2) { width: 12%; }
.recharge-table th:nth-child(3) { width: 10%; }
.recharge-table th:nth-child(4) { width: 12%; }
.recharge-table th:nth-child(5) { width: 14%; }
.recharge-table th:nth-child(6) { width: 9%; }
.recharge-table th:nth-child(7) { width: 25%; }
.recharge-table th:nth-child(8) { width: 8%; }
.recharge-table .recharge-note {
  overflow: hidden;
  text-overflow: ellipsis;
}
.recharge-entry-table input,
.recharge-entry-table select {
  min-height: 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0 6px;
}
.recharge-entry-table input:focus,
.recharge-entry-table select:focus {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  background: #fff;
}
.batch-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.batch-actions button {
  min-width: 180px;
}
.balance-mode-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}
.balance-mode-toolbar label {
  width: min(340px, 100%);
}
.balance-mode-table {
  max-height: 440px;
}
.balance-mode-table table {
  min-width: 760px;
}
.balance-mode-table select,
.balance-mode-table input[type="date"] {
  min-height: 34px;
  padding: 4px 8px;
}
.balance-mode-table select {
  min-width: 150px;
}
.balance-mode-table input[type="date"] {
  min-width: 150px;
}
.balance-mode-details {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 42px;
}
.balance-mode-details[hidden] {
  display: none;
}
.balance-mode-details > span {
  white-space: nowrap;
  color: var(--muted);
}
.balance-mode-details > span strong {
  color: #223044;
}
.balance-mode-details label {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  font-size: 13px;
}
.balance-mode-table tr[hidden] {
  display: none;
}
.pivot-compare-stats strong .compare-up,
.pivot-compare-stats strong .compare-down,
.pivot-compare-stats strong .compare-flat {
  font-size: 14px;
  line-height: 1.4;
}
.compare-up {
  color: #c62828;
  font-weight: 700;
  white-space: nowrap;
}
.compare-down {
  color: #087f23;
  font-weight: 700;
  white-space: nowrap;
}
.compare-flat {
  color: var(--muted);
  white-space: nowrap;
}
.pivot-trend-filters {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(180px, 1.2fr) repeat(2, minmax(130px, 0.8fr)) auto;
  align-items: end;
  justify-content: start;
  gap: 12px;
  margin-bottom: 20px;
}
.pivot-customer-field { min-width: 0; }
.pivot-trend-filters .multi-select { min-width: 0; }
.pivot-metric-field { min-width: 0; }
.pivot-metric-field select { width: 100%; min-width: 0; }
.pivot-customer-field > .filter-label { display: block; margin-bottom: 8px; }
.pivot-customer-field summary { min-height: 38px; }
.pivot-customer-field .multi-select-menu { width: 100%; box-sizing: border-box; z-index: 30; }
.pivot-customer-field .check-item span { overflow-wrap: anywhere; }
.pivot-customer-field [hidden], .pivot-trend-selection[hidden] { display: none; }
.pivot-trend-selection { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }
.pivot-customer-chip { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; padding: 2px 6px 2px 10px; border: 1px solid #cfdced; border-radius: 4px; color: #245c9c; background: #f2f7fc; font-size: 13px; }
.pivot-customer-chip > span { overflow-wrap: anywhere; min-width: 0; }
.pivot-customer-chip .icon-button { flex: 0 0 24px; width: 24px; height: 24px; min-height: 24px; padding: 0; color: inherit; background: transparent; border: 0; }
.pivot-trend-block { padding: 22px 0; border-top: 1px solid #e2e8f0; }
.pivot-trend-block:last-child { padding-bottom: 0; }
.pivot-trend-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.pivot-trend-heading h3 { margin: 0; font-size: 16px; }
.pivot-trend-metrics { display: flex; flex-wrap: wrap; gap: 10px 24px; color: #657080; font-size: 13px; }
.pivot-trend-metrics strong { margin-left: 6px; color: #263241; font-variant-numeric: tabular-nums; }
.pivot-trend-legend { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 18px; margin: 16px 0 4px; color: #526274; font-size: 12px; }
.pivot-trend-legend span { display: inline-flex; align-items: center; gap: 6px; }
.pivot-trend-legend i { width: 20px; border-top: 3px solid #2563eb; }
.pivot-trend-legend .pivot-series-2-key { border-top: 3px dashed #087f75; }
.seven-day-chart.pivot-daily-chart { padding: 0; margin: 0; border: 0; border-radius: 0; min-width: 0; }
.pivot-trend-plot { overflow-x: auto; }
.pivot-daily-chart svg { min-width: 620px; }
.pivot-daily-chart .chart-tooltip { transform: translate(-50%, 0); white-space: pre-line; width: max-content; max-width: min(290px, 100%); box-sizing: border-box; overflow-wrap: anywhere; font-weight: 500; line-height: 1.7; }
.pivot-trend-hit { cursor: crosshair; outline: none; }
.pivot-trend-guide { opacity: 0; }
.pivot-trend-hit:hover .pivot-trend-guide, .pivot-trend-hit:focus .pivot-trend-guide { opacity: 1; }
@media (max-width: 1000px) {
  .pivot-trend-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .pivot-trend-filters { grid-template-columns: minmax(0, 1fr); }
  .pivot-trend-filters .multi-select { min-width: 0; }
  .pivot-trend-filters > button { justify-self: start; }
  .pivot-trend-heading { align-items: start; flex-direction: column; }
}
.pivot-comparison-title {
  margin-top: 18px;
}
.pivot-comparison-table {
  max-height: 620px;
}
.pivot-comparison-table table {
  min-width: 1180px;
}
.freeze-first-two th:nth-child(1),
.freeze-first-two td:nth-child(1) {
  position: sticky;
  left: 0;
  width: 120px;
  min-width: 120px;
  max-width: 120px;
  z-index: 6;
}
.freeze-first-two th:nth-child(2),
.freeze-first-two td:nth-child(2) {
  position: sticky;
  left: 120px;
  width: 220px;
  min-width: 220px;
  max-width: 220px;
  z-index: 6;
  box-shadow: 5px 0 7px -6px rgba(37, 50, 68, 0.75);
}
.freeze-first-two td:nth-child(1),
.freeze-first-two td:nth-child(2) {
  overflow: hidden;
  text-overflow: ellipsis;
  background: #fff;
}
.freeze-first-two tbody tr:nth-child(even) td:nth-child(1),
.freeze-first-two tbody tr:nth-child(even) td:nth-child(2) {
  background: #fbfdff;
}
.freeze-first-two tbody tr:hover td:nth-child(1),
.freeze-first-two tbody tr:hover td:nth-child(2) {
  background: #fff7d6;
}
.freeze-first-two th:nth-child(1),
.freeze-first-two th:nth-child(2) {
  z-index: 8;
}
.table-sort-button {
  width: 100%;
  min-height: 24px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  justify-content: flex-start;
  gap: 5px;
  font-size: inherit;
  line-height: 1.2;
  white-space: nowrap;
}
.table-sort-button:hover,
.table-sort-button:focus-visible {
  background: transparent;
  color: var(--accent);
  outline: none;
}
th.num .table-sort-button {
  justify-content: flex-end;
}
.sort-indicator {
  display: inline-block;
  width: 12px;
  color: var(--accent);
  font-size: 13px;
  text-align: center;
}
.budget-editor-form .form-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}
.budget-filter {
  margin-bottom: 12px;
}
.dashboard-table td.pos {
  background: #c9f0d2;
  color: #087f23;
}
.dashboard-table td.neg {
  background: #ffc8d2;
  color: #bd1f36;
}
.dashboard-table td.zero {
  background: #f8fafc;
  color: #4b5563;
}
.task-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.target-form {
  display: grid;
  grid-template-columns: 170px 170px minmax(260px, 1fr) 190px auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 10px;
}
.target-form label {
  font-size: 13px;
}
.inline-form {
  display: inline-flex;
  margin: 0;
}
.inline-form button {
  min-height: 32px;
  padding: 0 10px;
}
.danger {
  border-color: #d55345;
  color: #b2382d;
}
.danger:hover {
  background: #fff0ee;
  color: #8f281f;
}
.task-card {
  border: 1px solid #d8e0ea;
  border-radius: 8px;
  padding: 14px;
  background: #f8fcf7;
}
.task-card.total-task-card {
  background: #f5f9ff;
  border-color: #b9cfee;
}
.task-card h3 {
  margin: 0 0 10px;
  font-size: 17px;
}
.task-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 30px;
  border-top: 1px solid #e2e7ee;
  color: #3a4656;
  font-size: 13px;
}
.task-row:first-of-type {
  border-top: 0;
}
.task-row strong {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.month-over-month-row strong.pos {
  color: #0f8a43;
}
.month-over-month-row strong.neg {
  color: #c92d43;
}
.month-over-month-row strong.zero {
  color: #667085;
}
.progress {
  position: relative;
  height: 24px;
  background: #eaf0f7;
  overflow: hidden;
}
.progress span {
  display: block;
  height: 100%;
  background: #5b8ecb;
}
.progress em {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #102033;
  font-style: normal;
  font-size: 12px;
}
.compact-dashboard {
  max-height: 620px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}
.stats div {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  background: #fbfcfd;
}
.stats strong {
  display: block;
  font-size: 20px;
  line-height: 1.25;
}
.stats span { color: var(--muted); font-size: 13px; }
.account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.account-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}
.account-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.account-head h3 { margin: 0 0 4px; font-size: 17px; }
.account-head p { margin: 0; font-size: 13px; }
.account-head strong { color: var(--accent); white-space: nowrap; }
.account-list-title {
  align-items: center;
}
.account-search {
  display: grid;
  grid-template-columns: minmax(220px, 320px) auto auto;
  gap: 8px;
  align-items: center;
  margin-left: auto;
}
.account-search input,
.account-search button,
.account-search .button {
  min-height: 36px;
}
.account-table table {
  min-width: 1240px;
}
.admin-table-wrap table {
  min-width: 1120px;
}
.account-table th:last-child,
.account-table td:last-child {
  width: 76px;
  text-align: center;
}
.client-permission-form {
  display: grid;
  grid-template-columns: minmax(190px, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 280px;
}
.client-permission-form textarea {
  min-height: 38px;
  height: 38px;
  resize: none;
  overflow: auto;
  white-space: nowrap;
}
.client-permission-form button {
  min-height: 34px;
}
.admin-pages-form {
  display: grid;
  grid-template-columns: minmax(140px, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-width: 250px;
  position: relative;
}
.permission-dropdown {
  position: relative;
}
.permission-dropdown summary {
  list-style: none;
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid #cfd7e2;
  border-radius: 6px;
  padding: 0 11px;
  background: #fff;
  color: #263241;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.permission-dropdown summary::-webkit-details-marker {
  display: none;
}
.permission-dropdown summary::after {
  content: "⌄";
  color: #657080;
  font-size: 15px;
}
.permission-dropdown[open] summary::after {
  content: "⌃";
}
.permission-dropdown-menu {
  position: static;
  z-index: 20;
  width: 100%;
  border: 1px solid #cfd7e2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, .10);
  margin-top: 6px;
  padding: 10px;
}
.permission-checks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px 8px;
}
.permission-check {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: #263241;
  white-space: nowrap;
}
.permission-check input {
  width: 14px;
  height: 14px;
}
.admin-pages-form button {
  min-height: 34px;
}
.reset-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #e2e7ee;
}
.reset-form label {
  font-size: 13px;
}
.table-reset-form {
  display: grid;
  grid-template-columns: minmax(140px, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 240px;
}
.table-reset-form input,
.table-reset-form button {
  min-height: 34px;
}
.table-phone-form {
  display: grid;
  grid-template-columns: minmax(128px, 1fr) auto;
  gap: 8px;
  align-items: center;
  min-width: 205px;
}
.table-phone-form input,
.table-phone-form button {
  min-height: 34px;
}
.admin-table-wrap th:nth-child(3),
.admin-table-wrap td:nth-child(3) {
  width: 285px;
}
.client-account-table th:nth-child(4),
.client-account-table td:nth-child(4) {
  width: 315px;
}
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.tags span {
  border: 1px solid #cfd7e2;
  border-radius: 999px;
  padding: 4px 9px;
  background: #f6f8fa;
  color: #344052;
  font-size: 13px;
}
.tags em { color: var(--muted); font-style: normal; }
.table-wrap {
  overflow: auto;
  border: 1px solid #b9c3cf;
  border-radius: 6px;
  background: #fff;
}
.admin-table-wrap {
  overflow: auto;
}
.excel-wrap {
  max-height: 68vh;
  box-shadow: inset 0 1px 0 #fff;
}
table {
  width: 100%;
  min-width: 760px;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
}
.excel-table { font-size: 13px; }
th, td {
  padding: 7px 9px;
  border-right: 1px solid #d9e0e8;
  border-bottom: 1px solid #d9e0e8;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
  line-height: 1.35;
}
th {
  position: sticky;
  top: 0;
  z-index: 5;
  background: linear-gradient(#eef3f8, #dde6ef);
  color: #253244;
  font-size: 12px;
  font-weight: 700;
  box-shadow: inset 0 -1px 0 #b9c3cf;
}
td { color: #1f2937; background: #fff; }
tbody tr:nth-child(even) td { background: #fbfdff; }
tbody tr:hover td { background: #fff7d6; }
td.num, th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
td.text, th.text { text-align: left; }
.sticky-col {
  position: sticky;
  left: 0;
  z-index: 4;
  background: #f7fafc;
}
th.sticky-col { z-index: 7; }
.action-col {
  min-width: 70px;
  width: 70px;
  text-align: center;
  box-shadow: 1px 0 0 #b9c3cf;
}
.table-action {
  min-height: 28px;
  padding: 0 10px;
  font-size: 12px;
}
.row-id {
  min-width: 72px;
  width: 72px;
  color: #5d6878;
  font-variant-numeric: tabular-nums;
}
.second-col {
  left: 72px;
  min-width: 150px;
  width: 150px;
  box-shadow: 1px 0 0 #b9c3cf;
}
tbody tr:nth-child(even) td.sticky-col { background: #f2f6fa; }
tbody tr:hover td.sticky-col { background: #fff0b8; }
tbody tr:last-child td { border-bottom: 0; }
.record-edit-form {
  display: grid;
  gap: 14px;
}
.record-edit-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid #b9c3cf;
  border-bottom: 0;
  border-right: 0;
  background: #fff;
}
.record-edit-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 8px;
  border-right: 1px solid #d9e0e8;
  border-bottom: 1px solid #d9e0e8;
  color: #253244;
  font-size: 12px;
  font-weight: 700;
}
.record-edit-grid input {
  min-width: 0;
  min-height: 34px;
  border-radius: 4px;
  font-size: 13px;
}
.record-edit-sync {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #e6c978;
  border-radius: 6px;
  background: #fff9e8;
  color: #253244;
  cursor: pointer;
}
.record-edit-sync input {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  margin-top: 2px;
}
.record-edit-sync span {
  display: grid;
  gap: 3px;
}
.record-edit-sync small {
  color: #66758a;
  font-weight: 400;
  line-height: 1.5;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.small table { min-width: 520px; }
.empty {
  border: 1px dashed #c9d2dd;
  border-radius: 8px;
  padding: 24px;
  text-align: center;
  color: var(--muted);
  background: #fbfcfd;
}
.executive-dashboard-page {
  background: #eef2f6;
}
.executive-dashboard-page .container {
  width: min(1480px, calc(100% - 40px));
  max-width: none;
  margin: 24px auto 48px;
}
.executive-dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 104px;
  margin-bottom: 14px;
  padding: 22px 28px;
  border: 1px solid #d4dce6;
  border-left: 4px solid #b91734;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(22, 34, 48, .06);
}
.executive-dashboard-header span,
.executive-module header span {
  display: block;
  margin-bottom: 4px;
  color: #b91734;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
}
.executive-dashboard-header h1 {
  margin: 0;
  color: #17212b;
  font-size: 28px;
  line-height: 1.25;
}
.executive-dashboard-header p {
  margin: 7px 0 0;
  color: #687587;
  font-size: 14px;
}
.executive-freshness {
  min-width: 168px;
  padding-left: 20px;
  border-left: 1px solid #dce3eb;
  text-align: right;
}
.executive-freshness span {
  color: #7b8797;
  font-size: 12px;
}
.executive-freshness strong {
  display: block;
  margin-top: 4px;
  color: #17212b;
  font-size: 18px;
}
.executive-toolbar {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 15px 18px;
  border: 1px solid #d4dce6;
  border-radius: 6px;
  background: #fff;
}
.executive-filters {
  display: grid;
  grid-template-columns: minmax(250px, 1fr) minmax(250px, 1fr) minmax(150px, 190px) minmax(150px, .8fr) minmax(150px, .8fr);
  gap: 10px;
  align-items: end;
  flex: 1;
}
.executive-filters label {
  min-width: 0;
}
.executive-period-note {
  padding-bottom: 0;
  color: #7b8797;
  font-size: 12px;
  text-align: right;
  white-space: nowrap;
}
.executive-kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}
.executive-kpi {
  min-width: 0;
  min-height: 126px;
  padding: 17px 18px;
  border: 1px solid #d4dce6;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 5px 16px rgba(22, 34, 48, .04);
}
.executive-kpi > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.executive-kpi > div > span {
  color: #5d6b7d;
  font-size: 13px;
  font-weight: 700;
}
.executive-kpi strong {
  display: block;
  overflow: hidden;
  margin-top: 14px;
  color: #17212b;
  font-size: 25px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.executive-kpi small {
  display: block;
  margin-top: 8px;
  color: #8a94a3;
  font-size: 11px;
}
.executive-change {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}
.executive-change.up {
  color: #176f4b;
  background: #e5f5ed;
}
.executive-change.down {
  color: #b4233b;
  background: #fdebed;
}
.executive-change.flat {
  color: #677486;
  background: #eef2f6;
}
.executive-main-grid,
.executive-secondary-grid {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}
.executive-main-grid {
  grid-template-columns: minmax(0, 1.9fr) minmax(360px, .8fr);
}
.executive-secondary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.executive-module {
  min-width: 0;
  padding: 18px;
  border: 1px solid #d4dce6;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 5px 16px rgba(22, 34, 48, .04);
}
.executive-module > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  min-height: 42px;
  margin-bottom: 8px;
}
.executive-module header h2 {
  margin: 0;
  color: #17212b;
  font-size: 18px;
  line-height: 1.3;
}
.executive-module header em {
  color: #7b8797;
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
}
.executive-module .seven-day-chart {
  margin-top: 0;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
}
.executive-chart-legend {
  display: flex;
  justify-content: flex-end;
  gap: 18px;
  min-height: 24px;
  color: #637083;
  font-size: 12px;
}
.executive-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.legend-line {
  display: inline-block;
  width: 18px;
  height: 3px;
  border-radius: 2px;
  background: #2f6fed;
}
.legend-line.previous {
  height: 2px;
  background: #8a94a3;
}
.executive-chart-grid {
  stroke: #e5eaf0;
  stroke-width: 1;
}
.executive-axis-label {
  fill: #7b8797;
  font-size: 11px;
}
.executive-trend-area {
  fill: #2f6fed;
  fill-opacity: .07;
}
.executive-trend-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.executive-trend-line.current {
  stroke: #2f6fed;
  stroke-width: 3;
}
.executive-trend-line.previous {
  stroke: #8a94a3;
  stroke-width: 2;
  stroke-dasharray: 7 6;
}
.executive-donut-layout {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  justify-items: center;
  gap: 14px;
  min-height: 298px;
}
.executive-donut-chart svg {
  width: 190px;
  height: 190px;
}
.executive-donut-track,
.executive-donut-segment {
  fill: none;
  stroke-width: 23;
  transform: rotate(-90deg);
  transform-origin: 86px 86px;
}
.executive-donut-track {
  stroke: #edf1f5;
}
.executive-donut-segment {
  cursor: pointer;
  transition: stroke-width .15s ease;
}
.executive-donut-segment:hover,
.executive-donut-segment:focus {
  stroke-width: 27;
  outline: none;
}
.executive-donut-chart text {
  fill: #7b8797;
  font-size: 11px;
}
.executive-donut-chart .donut-total {
  fill: #17212b;
  font-size: 15px;
  font-weight: 800;
}
.executive-donut-legend {
  display: grid;
  width: 100%;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.executive-donut-legend li {
  display: grid;
  grid-template-columns: minmax(78px, 1fr) 48px 80px;
  align-items: center;
  gap: 8px;
  color: #263241;
  font-size: 12px;
}
.executive-donut-legend li > span {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 7px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.executive-donut-legend i {
  flex: 0 0 9px;
  width: 9px;
  height: 9px;
  border-radius: 2px;
}
.executive-donut-legend strong,
.executive-donut-legend em {
  text-align: right;
  font-style: normal;
}
.executive-donut-legend em {
  color: #7b8797;
}
.executive-bars {
  display: grid;
  align-content: center;
  gap: 10px;
  min-height: 270px;
}
.executive-bar-legend {
  display: flex;
  justify-content: flex-end;
  gap: 14px;
  color: #6b7788;
  font-size: 11px;
}
.executive-bar-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.executive-bar-legend i {
  width: 18px;
  height: 5px;
  border-radius: 2px;
  background: #2f6fed;
}
.executive-bar-legend i.previous {
  opacity: 0.28;
}
.executive-bar-row {
  display: grid;
  gap: 4px;
}
.executive-bar-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #344052;
  font-size: 12px;
}
.executive-bar-label strong {
  color: #17212b;
  font-variant-numeric: tabular-nums;
}
.executive-bar-values {
  display: inline-flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 9px;
  white-space: nowrap;
}
.executive-bar-values em {
  color: #8a94a3;
  font-size: 10px;
  font-style: normal;
  font-variant-numeric: tabular-nums;
}
.executive-bar-track {
  height: 8px;
  overflow: hidden;
  border-radius: 3px;
  background: #edf1f5;
}
.executive-bar-track.previous {
  height: 5px;
  background: #f1f3f6;
}
.executive-bar-track > span {
  display: block;
  height: 100%;
  border-radius: 3px;
  background: var(--executive-bar-color, #2f6fed);
  cursor: crosshair;
}
.executive-bar-track.previous > span {
  opacity: 0.28;
}
.executive-empty-chart {
  display: grid;
  min-height: 270px;
  place-items: center;
  color: #8a94a3;
  font-size: 13px;
}
.executive-ranking-module {
  margin-bottom: 14px;
}
.executive-ranking-table {
  max-height: 440px;
}
.executive-ranking-table table {
  min-width: 1120px;
}
.executive-ranking-table th {
  height: 36px;
  background: #edf2f7;
  color: #485568;
}
.executive-ranking-table td {
  height: 43px;
}
.executive-ranking-table td:nth-child(2) strong,
.executive-ranking-table td:nth-child(2) small {
  display: block;
}
.executive-ranking-table td:nth-child(2) small {
  margin-top: 3px;
  color: #8a94a3;
  font-size: 11px;
}
.rank-cell span {
  display: inline-grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 4px;
  background: #edf1f5;
  color: #536174;
  font-size: 12px;
  font-weight: 800;
}
.executive-ranking-table tbody tr:nth-child(-n+3) .rank-cell span {
  color: #fff;
  background: #2f6fed;
}
.executive-delta.up { color: #168052; font-weight: 800; }
.executive-delta.down { color: #c32942; font-weight: 800; }
.executive-delta.flat { color: #7b8797; }
@media (max-width: 1180px) {
  .executive-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .executive-main-grid { grid-template-columns: 1fr; }
  .executive-secondary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .executive-dashboard-page .container { width: min(100% - 24px, 1480px); }
  .executive-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .executive-period-note { padding-bottom: 0; }
  .executive-secondary-grid { grid-template-columns: 1fr; }
  .login-wrap { grid-template-columns: 1fr; }
  .login-visual { display: none; }
  .login-form-area {
    min-height: 0;
    justify-content: center;
    padding: 32px 24px 24px;
  }
  .login-mobile-logo {
    display: block;
    width: 232px;
    height: auto;
  }
}
@media (max-width: 760px) {
  .executive-dashboard-page .container { width: min(100% - 16px, 1480px); margin-top: 12px; }
  .executive-dashboard-header { align-items: flex-start; flex-direction: column; padding: 18px; }
  .executive-freshness { width: 100%; padding: 12px 0 0; border-top: 1px solid #dce3eb; border-left: 0; text-align: left; }
  .executive-filters { grid-template-columns: 1fr; }
  .executive-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .executive-kpi { min-height: 112px; padding: 14px; }
  .executive-kpi strong { font-size: 20px; }
  .executive-module { padding: 14px; }
  .executive-donut-layout { grid-template-columns: 1fr; justify-items: center; }
  .executive-donut-legend { width: 100%; }
  .login-form-area { padding: 24px 16px; }
  .login-panel { padding: 24px 20px; }
  .login-heading h2 { font-size: 24px; }
  .login-tabs { gap: 24px; }
  .phone-code-row { grid-template-columns: minmax(0, 1fr) 104px; }
  .topbar { padding: 0 16px; }
  .topbar span { display: block; margin: 2px 0 0; }
  .navlinks { display: flex; order: 3; width: 100%; margin-left: 0; padding-bottom: 8px; }
  .navlinks a { padding: 7px 8px; font-size: 13px; }
  .grid.two { grid-template-columns: 1fr; }
  .filters, .filters.advanced, .client-filters, .preview-selector, .report-filter-form, .report-filter-form.with-group { grid-template-columns: 1fr; }
  .report-filter-chips { grid-column: auto; }
  .report-filter-modal { padding: 12px; }
  .report-filter-dialog { width: 100%; max-height: calc(100vh - 24px); padding: 16px; }
  .report-filter-row { grid-template-columns: 1fr 36px; }
  .report-filter-row select { grid-column: 1 / -1; }
  .report-filter-dialog-actions { flex-wrap: wrap; }
  .report-filter-dialog-actions button { flex: 1 1 130px; }
  .client-filters .filter-search, .filter-actions, .date-range-field { grid-column: auto; }
  .date-range-popover { width: 100%; grid-template-columns: 1fr; }
  .range-calendars { grid-template-columns: 1fr; }
  .range-shortcuts { grid-template-columns: repeat(2, minmax(0, 1fr)); border-right: 0; border-bottom: 1px solid #e2e7ee; }
  .range-footer { align-items: stretch; flex-wrap: wrap; }
  .range-footer span { flex-basis: 100%; }
  .range-footer button { flex: 1 1 120px; }
  .filter-actions { justify-content: stretch; flex-wrap: wrap; }
  .filter-actions button, .filter-actions .button { flex: 1 1 120px; }
  .summary-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-section-title { align-items: stretch; }
  .title-tools { align-items: stretch; flex-direction: column; gap: 8px; }
  .multi-select { min-width: 0; }
  .multi-select-menu { width: min(260px, calc(100vw - 64px)); }
  .task-grid, .target-form { grid-template-columns: 1fr; }
  .recharge-entry-title, .recharge-import-actions { align-items: stretch; flex-direction: column; }
  .recharge-import-form { flex-wrap: wrap; }
  .recharge-file-name { flex: 1 1 120px; max-width: none; align-self: center; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-grid { grid-template-columns: 1fr; }
  .account-list-title { align-items: stretch; flex-direction: column; }
  .account-search, .client-permission-form, .admin-pages-form, .reset-form, .table-reset-form, .table-phone-form { grid-template-columns: 1fr; }
  .permission-checks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .record-edit-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero, .panel { padding: 16px; }
}
