:root {
  --brand: #1677ff;
  --brand-dark: #0958d9;
  --brand-soft: #eaf3ff;
  --canvas: #f4f7fb;
  --panel: #ffffff;
  --text: #172033;
  --muted: #6b778c;
  --line: #e6ebf2;
  --success: #13a56b;
  --warning: #f08c2e;
  --danger: #df3f40;
  --purple: #7454d8;
  --cyan: #009bb5;
  --shadow: 0 8px 30px rgba(32, 56, 85, .06);
  --radius: 14px;
}

* { box-sizing: border-box; }
html { font-size: 14px; }
body {
  margin: 0;
  min-width: 1180px;
  color: var(--text);
  background: var(--canvas);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.app-shell { min-height: 100vh; display: flex; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 224px;
  display: flex;
  flex-direction: column;
  color: #d6e5fa;
  background: linear-gradient(180deg, #0c2445 0%, #0a1c35 100%);
  box-shadow: 5px 0 30px rgba(9, 30, 57, .12);
  z-index: 20;
}
.brand {
  height: 88px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 24px;
  color: white;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: white;
  background: var(--brand);
  border-radius: 12px;
  box-shadow: 0 7px 18px rgba(22,119,255,.35);
}
.brand-mark svg { width: 25px; height: 25px; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 17px; letter-spacing: .03em; }
.brand small { margin-top: 3px; color: #9fb4d1; font-size: 11px; }
.side-nav { flex: 1; padding: 22px 14px; }
.side-nav a {
  height: 46px;
  display: flex;
  align-items: center;
  gap: 13px;
  margin: 4px 0;
  padding: 0 15px;
  color: #b8c9df;
  border-radius: 10px;
  transition: .18s ease;
}
.side-nav a:hover { color: white; background: rgba(255,255,255,.06); }
.side-nav a.active {
  color: white;
  background: linear-gradient(90deg, rgba(22,119,255,.9), rgba(22,119,255,.55));
  box-shadow: 0 7px 18px rgba(0,69,166,.25);
}
.side-nav svg { width: 20px; height: 20px; }
.sidebar-footer {
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 22px;
  color: #91a5c1;
  font-size: 12px;
  border-top: 1px solid rgba(255,255,255,.08);
}
.sidebar-footer a { margin-left: auto; color: #d7e4f5; }
.status-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #36d394;
  box-shadow: 0 0 0 4px rgba(54,211,148,.12);
}

.workspace { width: calc(100% - 224px); margin-left: 224px; }
.topbar {
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--line);
}
.topbar h1 { margin: 4px 0 0; font-size: 24px; letter-spacing: -.02em; }
.eyebrow {
  margin: 0;
  color: var(--brand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.topbar-actions { display: flex; align-items: center; gap: 18px; }
.live-state { color: var(--muted); font-size: 12px; }
.live-state i {
  display: inline-block; width: 7px; height: 7px; margin-right: 7px;
  border-radius: 50%; background: var(--success);
}
.live-state.refreshing i { animation: pulse 1s infinite; }
.admin-avatar {
  width: 36px; height: 36px; display: grid; place-items: center;
  color: white; background: linear-gradient(135deg, var(--brand), #5c9dff);
  border-radius: 10px; font-weight: 700;
}
.content { padding: 28px 32px 48px; }
.toast {
  position: fixed; top: 102px; right: 28px; z-index: 50;
  max-width: 420px; padding: 13px 18px;
  color: white; border-radius: 10px; box-shadow: 0 12px 36px rgba(26,43,66,.18);
  animation: toast-in .25s ease;
}
.toast-success { background: #169b69; }
.toast-error { background: #d94748; }

.page-toolbar {
  min-height: 54px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}
.page-toolbar h2 { margin: 0 0 5px; font-size: 20px; }
.page-toolbar p, .panel-header p { margin: 0; color: var(--muted); font-size: 12px; }
.segmented {
  display: inline-flex;
  padding: 3px;
  background: #e9eef5;
  border-radius: 9px;
}
.segmented a {
  min-width: 68px;
  padding: 7px 12px;
  color: var(--muted);
  text-align: center;
  border-radius: 7px;
  font-size: 12px;
}
.segmented a.active { color: var(--brand-dark); background: white; box-shadow: 0 2px 7px rgba(42,62,87,.08); }

.panel {
  margin-bottom: 20px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.panel-header {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 15px 20px;
  border-bottom: 1px solid var(--line);
}
.panel-header h3 { margin: 0 0 5px; font-size: 15px; }
.panel-header-stack { align-items: flex-end; }
.text-link { color: var(--brand); font-size: 12px; font-weight: 600; }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.metric-grid { display: grid; gap: 14px; margin-bottom: 20px; }
.metric-grid-six { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.metric-grid-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric-card {
  min-height: 126px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 18px;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.metric-card p, .metric-card small, .mini-metric span { margin: 0; color: var(--muted); font-size: 12px; }
.metric-card strong { display: block; margin: 6px 0 4px; font-size: 28px; line-height: 1; }
.metric-card small { font-size: 10px; }
.metric-icon {
  flex: 0 0 38px; width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 11px; font-weight: 800;
}
.metric-icon.blue { color: var(--brand); background: var(--brand-soft); }
.metric-icon.orange { color: #e88121; background: #fff3e6; }
.metric-icon.purple { color: var(--purple); background: #f1edff; }
.metric-icon.cyan { color: var(--cyan); background: #e5f8fb; }
.metric-icon.green { color: var(--success); background: #e6f7f0; }
.metric-icon.red { color: var(--danger); background: #fff0f0; }
.mini-metric {
  min-height: 94px; padding: 19px 22px;
  background: white; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
}
.mini-metric strong { display: block; margin-top: 9px; font-size: 25px; }
.mini-metric .success, .success { color: var(--success); }
.mini-metric .danger, .danger { color: var(--danger); }

.provider-banner {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 20px; padding: 16px 20px;
  background: linear-gradient(105deg, #f7fbff, #fff);
  border: 1px solid #dceafd; border-radius: 13px;
}
.provider-logo {
  width: 42px; height: 42px; display: grid; place-items: center;
  color: white; background: linear-gradient(135deg, var(--brand), #6a9cff);
  border-radius: 12px; font-weight: 800;
}
.provider-banner p, .provider-banner h3 { margin: 0; }
.provider-banner p, .provider-meta span { color: var(--muted); font-size: 11px; }
.provider-banner h3 { margin-top: 3px; font-size: 15px; }
.provider-meta { margin-left: auto; padding-right: 15px; text-align: right; border-right: 1px solid var(--line); }
.provider-meta span, .provider-meta strong { display: block; }
.provider-meta strong { margin-top: 3px; font-family: ui-monospace, monospace; font-size: 12px; }

.button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  font-size: 12px;
  transition: .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.button-primary { color: white; background: var(--brand); box-shadow: 0 5px 13px rgba(22,119,255,.2); }
.button-primary:hover { background: var(--brand-dark); }
.button-secondary { color: #33425a; background: white; border-color: #cfd8e5; }
.button-secondary:hover { border-color: var(--brand); color: var(--brand); }
.button-ghost { color: var(--muted); background: #f3f6fa; }
.button-danger { color: white; background: var(--danger); }
.button-block { width: 100%; min-height: 42px; }
.button-small { min-height: 30px; padding: 0 11px; }
.icon-button {
  width: 32px; height: 32px; display: inline-grid; place-items: center;
  color: var(--muted); background: transparent; border: 0; border-radius: 7px; cursor: pointer;
}
.icon-button:hover { background: #f1f4f8; }
.icon-button.danger:hover { color: var(--danger); background: #fff0f0; }
.icon-button svg { width: 18px; height: 18px; }

.table-wrap { width: 100%; overflow: hidden; }
table { width: 100%; border-collapse: collapse; }
th {
  height: 40px; padding: 0 15px;
  color: #748097; background: #fafbfd;
  border-bottom: 1px solid var(--line);
  text-align: left; font-size: 11px; font-weight: 600; white-space: nowrap;
}
td {
  min-height: 54px; padding: 11px 15px;
  border-bottom: 1px solid #edf0f5;
  color: #38445a; font-size: 12px; vertical-align: middle;
}
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fbfdff; }
.align-right { text-align: right; }
.empty-cell { height: 120px; color: var(--muted); text-align: center; }
.table-link { color: var(--brand); font-weight: 600; }
.truncate { display: block; max-width: 180px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.row-error {
  display: block; max-width: 240px; margin-top: 3px;
  overflow: hidden; color: var(--danger); white-space: nowrap; text-overflow: ellipsis;
}
.job-type { display: block; font-weight: 600; }
code {
  padding: 2px 5px; color: #4f5f75; background: #f1f4f8;
  border-radius: 5px; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px;
}
.badge {
  display: inline-flex; align-items: center; min-height: 23px;
  padding: 2px 8px; border-radius: 999px; font-size: 10px; font-weight: 700; white-space: nowrap;
}
.badge-success, .badge-active, .badge-completed, .badge-ai, .badge-resolved { color: #08794d; background: #e4f7ef; }
.badge-pending, .badge-uploaded, .badge-waiting_human { color: #af5f09; background: #fff1df; }
.badge-running, .badge-indexing, .badge-in_progress, .badge-human { color: #5e41b8; background: #efeaff; }
.badge-failed { color: #b72d30; background: #ffebeb; }
.badge-ended, .badge-inactive, .badge-neutral { color: #68758a; background: #edf1f5; }
.count-label { display: inline-grid; place-items: center; min-width: 23px; height: 23px; padding: 0 7px; color: var(--brand); background: var(--brand-soft); border-radius: 20px; font-size: 11px; }

.filter-bar { display: flex; align-items: center; gap: 8px; }
.filter-bar-wide { flex-wrap: wrap; justify-content: flex-end; }
.filter-bar select, .filter-bar input, .inline-upload input[type=file] {
  height: 36px; color: #3e4a5e; background: white; border: 1px solid #d7dee8; border-radius: 8px; outline: none;
}
.filter-bar select { min-width: 120px; padding: 0 29px 0 10px; }
.filter-bar-wide select { min-width: 132px; }
.search-box {
  position: relative; min-width: 210px; display: flex; align-items: center;
}
.search-box svg { position: absolute; left: 11px; width: 16px; height: 16px; color: #8c98aa; }
.search-box input { width: 100%; padding: 0 12px 0 34px; }
.filter-bar input:focus, .filter-bar select:focus, .field input:focus, .field textarea:focus {
  border-color: var(--brand); box-shadow: 0 0 0 3px rgba(22,119,255,.09);
}
.pagination {
  min-height: 58px; display: flex; align-items: center; justify-content: flex-end; gap: 14px;
  padding: 0 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px;
}
.pagination a { color: var(--brand); }

.upload-panel { scroll-margin-top: 20px; }
.file-limit, .privacy-label { color: var(--muted); font-size: 11px; }
.drop-zone {
  margin: 20px; min-height: 174px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  padding: 22px; color: var(--muted);
  background: #fbfdff; border: 1.5px dashed #bdd2ed; border-radius: 12px;
  transition: .18s ease;
}
.drop-zone.dragging { background: var(--brand-soft); border-color: var(--brand); }
.drop-zone label { display: flex; flex-direction: column; align-items: center; gap: 7px; cursor: pointer; text-align: center; }
.drop-zone label strong { color: #31415a; }
.upload-icon {
  width: 48px; height: 48px; display: grid; place-items: center;
  color: var(--brand); background: var(--brand-soft); border-radius: 13px;
}
.upload-icon svg { width: 25px; height: 25px; }
.file-cell { display: flex; align-items: center; gap: 11px; max-width: 320px; }
.file-cell > div { min-width: 0; }
.file-cell strong, .file-cell small { display: block; }
.file-cell strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.file-cell small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.file-icon {
  flex: 0 0 36px; width: 36px; height: 40px; display: grid; place-items: center;
  color: var(--brand); background: var(--brand-soft); border-radius: 7px; font-size: 8px; font-weight: 800;
}

.customer-cell { display: flex; align-items: center; gap: 9px; }
.customer-avatar {
  flex: 0 0 30px; width: 30px; height: 30px; display: grid; place-items: center;
  color: var(--brand); background: var(--brand-soft); border-radius: 9px; font-weight: 700;
}
.customer-avatar.large { width: 46px; height: 46px; border-radius: 12px; font-size: 16px; }
.message-preview { display: block; max-width: 270px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--muted); }
.row-arrow { width: 28px; height: 28px; display: grid; place-items: center; color: var(--brand); background: var(--brand-soft); border-radius: 7px; font-size: 20px; }

.detail-heading { margin-bottom: 20px; }
.back-link { display: inline-block; margin-bottom: 16px; color: var(--brand); font-size: 12px; }
.detail-title { display: flex; align-items: center; gap: 12px; }
.detail-title h2, .detail-title p { margin: 0; }
.detail-title h2 { margin-bottom: 4px; font-size: 19px; }
.detail-title p { color: var(--muted); font-size: 11px; }
.detail-title .badge { margin-left: 6px; }
.conversation-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 20px; align-items: start; }
.conversation-panel {
  position: sticky;
  top: 20px;
  height: calc(100vh - 218px);
  min-height: 540px;
  max-height: 900px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.conversation-panel > .panel-header { flex: 0 0 auto; }
.conversation-aside { min-width: 0; }
.reply-card, .audit-card { overflow: hidden; }
.reply-card form { padding: 18px; }
.field { display: block; margin: 18px 0; }
.field > span { display: block; margin-bottom: 7px; color: #354157; font-size: 12px; font-weight: 600; }
.field input, .field textarea {
  width: 100%; padding: 11px 12px; color: var(--text); background: white;
  border: 1px solid #d7dee8; border-radius: 9px; outline: none; resize: vertical;
}
.field small { display: block; margin-top: 5px; color: var(--muted); text-align: right; }
.ownership-warning, .ended-state {
  margin: 0 0 15px; padding: 12px 13px;
  color: #965009; background: #fff7e9; border: 1px solid #ffe1b1; border-radius: 9px;
}
.ownership-warning strong, .ownership-warning p, .ended-state strong, .ended-state p { margin: 0; font-size: 11px; }
.ownership-warning p, .ended-state p { margin-top: 4px; }
.ended-state { margin: 18px; color: #5e6878; background: #f4f6f9; border-color: var(--line); }
.reply-unavailable { margin: 18px; }
.timeline {
  flex: 1 1 auto;
  min-height: 0;
  padding: 22px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
  scrollbar-color: #b9c7da transparent;
  scrollbar-width: thin;
}
.timeline::-webkit-scrollbar { width: 8px; }
.timeline::-webkit-scrollbar-track { background: transparent; }
.timeline::-webkit-scrollbar-thumb {
  background: #c2cfdf;
  border: 2px solid white;
  border-radius: 999px;
}
.timeline::-webkit-scrollbar-thumb:hover { background: #9eafc4; }
.latest-message-button {
  position: absolute;
  right: 22px;
  bottom: 18px;
  z-index: 3;
  min-height: 34px;
  padding: 0 14px;
  color: white;
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 8px 22px rgba(22,119,255,.28);
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}
.latest-message-button:hover { background: var(--brand-dark); }
.latest-message-button[hidden] { display: none; }
.message { display: flex; gap: 11px; margin-bottom: 22px; }
.message.outgoing { flex-direction: row-reverse; }
.message-avatar {
  flex: 0 0 34px; width: 34px; height: 34px; display: grid; place-items: center;
  color: white; background: #7e8da2; border-radius: 10px; font-size: 10px; font-weight: 700;
}
.message.outgoing .message-avatar { background: var(--brand); }
.message-body { max-width: 76%; }
.message.outgoing .message-body { display: flex; flex-direction: column; align-items: flex-end; }
.message-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; color: var(--muted); font-size: 10px; }
.message-meta strong { color: #445168; }
.message-bubble {
  display: inline-block; padding: 11px 14px;
  color: #334157; background: #f2f5f8; border-radius: 4px 13px 13px 13px;
  line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere;
}
.message.outgoing .message-bubble { color: white; background: var(--brand); border-radius: 13px 4px 13px 13px; }
.message-audit {
  display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 7px;
  color: var(--muted); font-size: 9px;
}
.message-audit code { max-width: 220px; display: inline-block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; vertical-align: middle; }
.evidence-details { width: 100%; margin-top: 9px; color: var(--muted); font-size: 10px; }
.evidence-details summary { cursor: pointer; color: var(--brand); }
.evidence-list { display: grid; gap: 7px; margin-top: 8px; }
.evidence-list article { padding: 10px; background: #f8fafc; border: 1px solid var(--line); border-radius: 8px; }
.evidence-list header { display: flex; justify-content: space-between; gap: 12px; }
.evidence-list p { margin: 7px 0; line-height: 1.5; }
.audit-list { list-style: none; margin: 0; padding: 7px 17px 14px; }
.audit-list li { display: flex; align-items: flex-start; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.audit-list li:last-child { border-bottom: 0; }
.audit-list strong, .audit-list small { display: block; overflow-wrap: anywhere; }
.audit-list strong { font-size: 11px; }
.audit-list small { margin-top: 4px; color: var(--muted); font-size: 9px; line-height: 1.5; }
.empty-mini { color: var(--muted); font-size: 11px; }
.empty-state { padding: 100px 20px; color: var(--muted); text-align: center; }
.empty-state strong { color: #4c596e; }
.empty-state p { margin: 7px 0 0; }

.import-panel { display: grid; grid-template-columns: 1fr auto; align-items: center; }
.import-panel .panel-header { border: 0; }
.inline-upload { display: flex; align-items: center; gap: 9px; padding-right: 18px; }
.inline-upload input[type=file] { max-width: 240px; padding: 6px; }
.bulk-actions { min-height: 52px; display: flex; align-items: center; gap: 9px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.bulk-actions label { margin-right: auto; color: var(--muted); font-size: 11px; }
.evaluation-table td { vertical-align: top; }
.evaluation-question { min-width: 210px; max-width: 320px; }
.evaluation-question strong, .evaluation-question small { display: block; }
.evaluation-question small { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.answer-preview { display: block; max-width: 300px; max-height: 48px; overflow: hidden; line-height: 1.5; }
.attempts { display: block; margin-top: 5px; color: var(--brand); font-size: 9px; }
.evaluation-history { margin-top: 6px; color: var(--muted); font-size: 9px; }
.evaluation-history summary { color: var(--brand); cursor: pointer; }
.evaluation-history > div { position: relative; margin-top: 7px; padding: 8px 8px 8px 34px; background: #f7f9fc; border-radius: 7px; }
.evaluation-history .result-icon { position: absolute; top: 8px; left: 7px; }
.evaluation-history p { margin: 0 0 4px; line-height: 1.45; }
.evaluation-history small { color: var(--muted); }
.result-icon { min-width: 22px; height: 22px; display: inline-grid; place-items: center; border-radius: 50%; font-size: 10px; font-weight: 800; }
.result-icon.pass { color: var(--success); background: #e5f7f0; }
.result-icon.fail { color: var(--danger); background: #ffebeb; }
.result-icon.warn { color: var(--warning); background: #fff1df; }

.confirm-dialog {
  width: 400px; padding: 0; border: 0; border-radius: 15px; box-shadow: 0 24px 80px rgba(19,36,60,.25);
}
.confirm-dialog::backdrop { background: rgba(12,25,43,.45); backdrop-filter: blur(2px); }
.confirm-dialog form { padding: 25px; text-align: center; }
.dialog-icon {
  width: 45px; height: 45px; display: grid; place-items: center; margin: 0 auto 13px;
  color: var(--danger); background: #ffeded; border-radius: 50%; font-size: 20px; font-weight: 800;
}
.confirm-dialog h2 { margin: 0; font-size: 17px; }
.confirm-dialog p { margin: 10px 0 22px; color: var(--muted); line-height: 1.6; }
.dialog-actions { display: flex; justify-content: center; gap: 10px; }

.login-page { min-width: 980px; background: white; }
.login-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(480px, 1.1fr) minmax(420px, .9fr); }
.login-visual {
  position: relative; display: grid; place-items: center; overflow: hidden;
  color: white; background:
    radial-gradient(circle at 18% 18%, rgba(73,151,255,.55), transparent 27%),
    radial-gradient(circle at 84% 78%, rgba(21,101,224,.5), transparent 30%),
    linear-gradient(145deg, #071a35 0%, #0b3975 55%, #0b5ad3 100%);
}
.login-visual::before, .login-visual::after {
  content: ""; position: absolute; border: 1px solid rgba(255,255,255,.1); border-radius: 50%;
}
.login-visual::before { width: 560px; height: 560px; left: -210px; bottom: -260px; }
.login-visual::after { width: 380px; height: 380px; right: -170px; top: -120px; }
.login-visual-content { position: relative; z-index: 1; width: 470px; }
.login-logo { width: 58px; height: 58px; display: grid; place-items: center; margin-bottom: 28px; background: var(--brand); border-radius: 17px; box-shadow: 0 13px 34px rgba(0,75,194,.38); }
.login-logo svg { width: 32px; height: 32px; }
.login-visual-content > p { color: #91b9ee; letter-spacing: .18em; font-size: 11px; }
.login-visual-content h1 { margin: 16px 0 28px; font-size: 38px; line-height: 1.35; letter-spacing: -.02em; }
.login-visual-content ul { list-style: none; padding: 0; }
.login-visual-content li { margin: 15px 0; color: #c2d8f5; }
.login-visual-content li::before { content: "✓"; display: inline-grid; place-items: center; width: 21px; height: 21px; margin-right: 11px; color: #82b8ff; background: rgba(255,255,255,.09); border-radius: 50%; font-size: 10px; }
.login-panel { display: grid; place-items: center; padding: 50px; }
.login-card { width: 360px; }
.login-card h2 { margin: 11px 0 7px; font-size: 28px; }
.login-card .muted { margin: 0 0 30px; }
.login-card .field { margin: 18px 0; }
.login-card input { height: 45px; }
.form-alert { margin: 18px 0; padding: 11px 13px; color: #b62e31; background: #fff0f0; border: 1px solid #ffd1d2; border-radius: 8px; }
.login-note { margin: 15px 0 0; color: #98a3b2; text-align: center; font-size: 10px; }
.mobile-brand { display: none; }
.muted { color: var(--muted); }

@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } }
@keyframes pulse { 50% { opacity: .35; } }
@media (max-width: 1320px) {
  .metric-grid-six { grid-template-columns: repeat(3, 1fr); }
  .metric-card { min-height: 104px; }
  .filter-bar-wide .search-box { min-width: 180px; }
}
