:root {
  color-scheme: light;
  --bg: #f6f8fc;
  --surface: #ffffff;
  --surface-soft: #f9fbff;
  --ink: #172033;
  --muted: #667085;
  --soft: #98a2b3;
  --line: #e4e9f2;
  --line-strong: #d5ddea;
  --accent: #2563eb;
  --accent-dark: #1e40af;
  --accent-light: #eff6ff;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --shadow: 0 10px 28px rgba(31, 41, 55, 0.08);
  --shadow-soft: 0 6px 18px rgba(31, 41, 55, 0.05);
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(37, 99, 235, 0.08), rgba(37, 99, 235, 0) 330px),
    var(--bg);
  color: var(--ink);
  font-family:
    "PingFang SC", "Microsoft YaHei", Inter, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.app {
  min-height: 100vh;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
}

.login-panel {
  width: min(1040px, 100%);
  display: grid;
  grid-template-columns: 1.08fr 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.login-brand {
  min-height: 560px;
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.26), transparent 28%),
    linear-gradient(135deg, #1e73f8 0%, #2563eb 48%, #163ea9 100%);
  color: #fff;
}

.brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.login-copy h1 {
  margin: 0;
  max-width: 460px;
  font-size: 44px;
  line-height: 1.12;
  font-weight: 700;
}

.login-subtitle {
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 20px;
}

.login-benefits {
  display: grid;
  gap: 14px;
}

.benefit {
  width: fit-content;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  padding: 0 16px;
  color: rgba(255, 255, 255, 0.94);
}

.benefit svg {
  width: 18px;
  height: 18px;
}

.login-form {
  padding: 46px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
}

.login-form-head h2 {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
}

.login-form-head span,
.role-hint,
.security-note {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.role-hint {
  margin: -6px 0 0;
}

.security-note {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.security-note svg {
  width: 16px;
  height: 16px;
}

.role-switch,
.dimension-tabs,
.quick-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.role-switch button,
.dimension-tabs button,
.quick-filter-row button,
.nav-item,
.ghost-button,
.secondary-button,
.icon-button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  transition:
    transform 0.16s ease,
    border-color 0.16s ease,
    background 0.16s ease,
    color 0.16s ease;
}

.role-switch button,
.dimension-tabs button,
.quick-filter-row button {
  padding: 0 15px;
}

.role-switch button {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.role-switch button.active,
.dimension-tabs button.active,
.quick-filter-row button.active,
.nav-item.active {
  border-color: rgba(37, 99, 235, 0.18);
  background: var(--accent-light);
  color: var(--accent);
}

.dimension-tabs button,
.quick-filter-row button {
  border-radius: 999px;
}

.form-stack {
  display: grid;
  gap: 16px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span,
.field label {
  font-size: 13px;
  color: var(--muted);
}

.field input,
.field select,
.field textarea,
.filter-bar input,
.filter-bar select,
.search-field input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  padding: 0 13px;
  outline: none;
}

.field input[readonly] {
  background: #f7f9fd;
  color: #475467;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.filter-bar input:focus,
.filter-bar select:focus,
.search-field input:focus {
  border-color: rgba(37, 99, 235, 0.7);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.primary-button,
.export-button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  padding: 0 18px;
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
}

.primary-button:hover,
.export-button:hover {
  background: var(--accent-dark);
}

.primary-button.full {
  width: 100%;
}

.secondary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  background: #fff;
  color: #344054;
}

.secondary-button:hover,
.ghost-button:hover,
.nav-item:hover {
  transform: translateY(-1px);
  border-color: #c9d4e5;
}

.workspace {
  min-height: 100vh;
  display: grid;
  grid-template-rows: 60px 1fr;
  grid-template-columns: 260px 1fr;
}

.sidebar {
  position: sticky;
  top: 60px;
  height: calc(100vh - 60px);
  padding: 18px 20px;
  border-right: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.top-nav {
  grid-column: 1 / -1;
  position: sticky;
  top: 0;
  z-index: 30;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
  padding: 0 24px;
}

.top-nav-brand {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.top-nav-brand .brand-mark {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #1e73f8, #2563eb);
  font-size: 13px;
}

.top-nav-brand strong {
  display: block;
  overflow: hidden;
  color: var(--ink);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-nav-brand strong span {
  display: inline;
  color: inherit;
  font-size: inherit;
  line-height: inherit;
}

.top-nav-brand .mobile-title {
  display: none;
}

.top-nav-brand > div > span,
.top-user span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
}

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

.top-user {
  margin-right: 4px;
  padding-right: 12px;
  border-right: 1px solid var(--line);
  text-align: right;
}

.top-user strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
}

.side-brand {
  display: none;
  align-items: center;
  gap: 12px;
}

.side-brand .brand-mark {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #1e73f8, #2563eb);
}

.side-title {
  display: grid;
  gap: 2px;
}

.side-title strong {
  font-size: 15px;
}

.side-title span {
  color: var(--muted);
  font-size: 12px;
}

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

.nav-item {
  width: 100%;
  padding: 0 13px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
}

.nav-item svg,
.primary-button svg,
.export-button svg,
.secondary-button svg,
.ghost-button svg,
.icon-button svg,
.empty-state svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.sidebar-footer {
  margin-top: auto;
  display: grid;
  gap: 12px;
}

.profile-chip {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: #fff;
}

.profile-chip strong {
  display: block;
  margin-bottom: 5px;
}

.profile-chip span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.main {
  min-width: 0;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 22px 24px 32px;
}

.top-nav-button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  padding: 0 10px;
  font-size: 14px;
  font-weight: 600;
}

.top-nav-button:hover {
  background: var(--accent-light);
  color: var(--accent);
}

.top-nav-button.logout {
  color: var(--muted);
}

.top-nav-button.logout:hover {
  background: #f8fafc;
  color: var(--danger);
}

.top-nav-button svg {
  width: 18px;
  height: 18px;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.page-head h1 {
  margin: 0;
  font-size: clamp(24px, 3vw, 28px);
  line-height: 1.14;
  font-weight: 700;
}

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

.admin-priority-screen {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.admin-priority-screen .page-head {
  margin-bottom: 0;
}

.head-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.panel,
.today-card,
.metric {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-soft);
}

.panel + .panel {
  margin-top: 18px;
}

.panel-header {
  min-height: 54px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}

.panel-header h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
}

.panel-header span {
  color: var(--muted);
  font-size: 13px;
}

.panel-body {
  padding: 16px 18px 18px;
}

.employee-mobile-hero {
  display: none;
}

.today-card {
  position: relative;
  margin-bottom: 14px;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}

.today-card::before,
.metric.accent::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 4px;
  height: 100%;
  background: var(--accent);
}

.today-card.submitted::before {
  background: var(--success);
}

.today-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--accent-light);
  color: var(--accent);
}

.today-card.submitted .today-icon {
  background: var(--success-light);
  color: var(--success);
}

.today-card strong {
  display: inline;
  margin: 0 8px 0 0;
  font-size: 16px;
}

.today-card p {
  display: inline;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.eyebrow {
  display: none;
  color: var(--muted);
  font-size: 13px;
}

.text-button {
  min-height: 34px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--accent);
  padding: 0 10px;
  font-weight: 700;
}

.text-button:hover {
  background: var(--accent-light);
}

.text-button.danger {
  color: var(--danger);
}

.text-button.danger:hover {
  background: var(--danger-light);
}

.entry-form {
  display: grid;
  gap: 12px;
}

.form-section {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
  padding: 14px;
}

.form-section.compact {
  max-width: 520px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.section-title svg {
  width: 19px;
  height: 19px;
  color: var(--accent);
}

.section-title strong {
  display: block;
  font-size: 16px;
}

.section-title span {
  color: var(--muted);
  font-size: 12px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.form-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

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

.metric {
  position: relative;
  min-height: 108px;
  padding: 14px 16px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  overflow: hidden;
}

.metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.metric-top span {
  color: var(--muted);
  font-size: 13px;
}

.metric-top svg {
  width: 20px;
  height: 20px;
  color: var(--accent);
}

.metric strong {
  display: block;
  font-size: 30px;
  line-height: 1;
  font-weight: 760;
}

.metric small {
  color: var(--soft);
  font-size: 12px;
}

.metric.accent {
  border-color: rgba(37, 99, 235, 0.18);
  background: linear-gradient(180deg, #fff, #f8fbff);
}

.secondary-metrics .metric,
.employee-metrics .metric {
  min-height: 92px;
}

.secondary-metrics .metric strong,
.employee-metrics .metric strong {
  font-size: 26px;
}

.metric.success .metric-top svg,
.metric.success strong {
  color: var(--success);
}

.metric.danger .metric-top svg,
.metric.danger strong {
  color: var(--danger);
}

.progress-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #edf2fb;
}

.progress-fill {
  height: 100%;
  min-width: 4px;
  border-radius: inherit;
  background: linear-gradient(90deg, #60a5fa, var(--accent));
}

.progress-fill.danger {
  background: linear-gradient(90deg, #fb7185, var(--danger));
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  gap: 14px;
  margin-top: 14px;
}

.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 14px;
}

.account-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.72fr) minmax(0, 1.28fr);
  gap: 14px;
  margin-top: 14px;
  align-items: start;
}

.account-toolbar .panel-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.account-tabs {
  display: inline-flex;
  gap: 6px;
  border-radius: 999px;
  background: #eef3fb;
  padding: 4px;
}

.account-tabs button {
  min-height: 34px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  padding: 0 14px;
  font-weight: 700;
}

.account-tabs button.active {
  background: #fff;
  color: var(--accent);
  box-shadow: var(--shadow-soft);
}

.account-form {
  display: grid;
  gap: 12px;
}

.account-actions {
  position: static;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.row-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

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

.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 12px;
  padding: 10px;
  background: #f9fbff;
}

.rank-row.top {
  background: #f2f7ff;
}

.rank-main {
  min-width: 0;
  flex: 1;
  display: grid;
  gap: 8px;
}

.rank-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.rank-line strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-line span,
.bar-value {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.rank-main small {
  color: var(--soft);
  font-size: 12px;
}

.rank-badge {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 10px;
  background: #eef2f7;
  color: #475467;
  font-size: 12px;
  font-weight: 700;
}

.rank-badge.top {
  background: var(--accent);
  color: #fff;
}

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

.bar-fill {
  height: 100%;
  min-width: 4px;
  border-radius: inherit;
  background: var(--accent);
}

.trend {
  min-height: 230px;
  display: grid;
  align-items: end;
  grid-template-columns: repeat(7, minmax(32px, 1fr));
  gap: 11px;
  padding-top: 12px;
}

.trend-col {
  min-width: 0;
  display: grid;
  align-items: end;
  gap: 9px;
}

.trend-bar {
  height: var(--h);
  min-height: 18px;
  border-radius: 12px 12px 4px 4px;
  background: linear-gradient(180deg, #60a5fa, var(--accent));
}

.trend-col span {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-trend {
  display: grid;
  gap: 11px;
}

.mini-trend-item {
  display: grid;
  grid-template-columns: 1fr 54px 36px;
  align-items: center;
  gap: 12px;
}

.mini-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #eaf0f9;
}

.mini-track div {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #60a5fa, var(--accent));
}

.mini-trend-item span {
  color: var(--muted);
  font-size: 12px;
}

.mini-trend-item strong {
  text-align: right;
}

.insight-list {
  display: grid;
  gap: 9px;
}

.insight-item {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 10px;
  border-left: 4px solid var(--accent);
  border-radius: 12px;
  background: #fff;
  padding: 10px 11px;
}

.insight-item svg {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  padding: 7px;
  background: var(--accent-light);
  color: var(--accent);
}

.insight-item.success {
  border-left-color: var(--success);
}

.insight-item.success svg {
  background: var(--success-light);
  color: var(--success);
}

.insight-item.danger {
  border-left-color: var(--danger);
}

.insight-item.danger svg {
  background: var(--danger-light);
  color: var(--danger);
}

.insight-item.amber {
  border-left-color: var(--warning);
}

.insight-item.amber svg {
  background: var(--warning-light);
  color: var(--warning);
}

.insight-item.green {
  border-left-color: var(--success);
}

.insight-item.green svg {
  background: var(--success-light);
  color: var(--success);
}

.insight-item strong {
  display: block;
  margin-bottom: 4px;
}

.insight-item span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.filter-panel {
  margin-bottom: 14px;
}

.filter-bar {
  display: grid;
  grid-template-columns: repeat(6, minmax(120px, 1fr));
  gap: 10px;
}

.filter-bar .wide {
  grid-column: span 2;
}

.quick-filter-row {
  margin: 0 0 10px;
}

.quick-filter-row button {
  min-height: 34px;
  background: #fff;
  font-size: 13px;
  padding: 0 12px;
}

.analysis-header {
  align-items: flex-start;
}

.analysis-grid {
  align-items: start;
}

.section-caption {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.table-card {
  min-width: 0;
}

.table-wrap {
  width: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
}

table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 11px 12px;
  text-align: left;
  vertical-align: middle;
  font-size: 14px;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f8fbff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

td {
  color: var(--ink);
}

tbody tr:hover {
  background: rgba(37, 99, 235, 0.045);
}

.warn-row {
  background: var(--warning-light);
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 999px;
  background: var(--accent-light);
  color: var(--accent);
  padding: 0 8px;
  font-size: 11px;
  white-space: nowrap;
}

.tag.product {
  border-color: rgba(37, 99, 235, 0.2);
  background: var(--accent-light);
  color: var(--accent);
}

.tag.success {
  border-color: rgba(16, 185, 129, 0.24);
  background: var(--success-light);
  color: #047857;
}

.tag.warning,
.tag.amber {
  border-color: rgba(245, 158, 11, 0.25);
  background: var(--warning-light);
  color: #b45309;
}

.tag.danger,
.tag.coral {
  border-color: rgba(239, 68, 68, 0.22);
  background: var(--danger-light);
  color: #b91c1c;
}

.tag.soft,
.tag.muted {
  border-color: #e5e7eb;
  background: #f7f9fc;
  color: #667085;
}

.search-header {
  align-items: center;
}

.search-field {
  width: min(330px, 100%);
  position: relative;
  display: flex;
  align-items: center;
}

.search-field svg {
  position: absolute;
  left: 13px;
  width: 17px;
  height: 17px;
  color: var(--soft);
}

.search-field input {
  padding-left: 40px;
}

.record-card-list {
  display: none;
  gap: 12px;
}

.record-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  padding: 15px;
}

.record-card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

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

.record-card-head strong {
  font-size: 15px;
}

.record-card-top strong {
  font-size: 15px;
}

.record-card-head span,
.record-card p {
  color: var(--muted);
  font-size: 13px;
}

.record-card p {
  margin: 8px 0 12px;
}

.record-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.record-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.people-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.people-chip {
  border-radius: 999px;
  background: var(--danger-light);
  color: #b91c1c;
  padding: 7px 10px;
  font-size: 12px;
}

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

.alert-item {
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 12px;
  background: var(--warning-light);
  padding: 10px 11px;
}

.alert-item strong {
  display: block;
  margin-bottom: 4px;
}

.alert-item span {
  color: #92400e;
  font-size: 13px;
}

.inline-progress {
  min-width: 170px;
  display: grid;
  grid-template-columns: 1fr 42px;
  align-items: center;
  gap: 10px;
}

.inline-progress span {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.empty-state {
  min-height: 220px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: var(--muted);
  text-align: center;
}

.empty-state svg {
  width: 38px;
  height: 38px;
  color: var(--soft);
}

.empty-state strong {
  color: var(--ink);
}

.empty-state span {
  max-width: 360px;
  line-height: 1.6;
}

.dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(15, 23, 42, 0.22);
  backdrop-filter: blur(5px);
}

.success-dialog {
  width: min(420px, 100%);
  border-radius: 22px;
  background: #fff;
  padding: 30px;
  text-align: center;
  box-shadow: var(--shadow);
}

.success-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  border-radius: 18px;
  background: var(--success-light);
  color: var(--success);
}

.success-dialog h2 {
  margin: 0;
}

.success-dialog p {
  margin: 10px 0 22px;
  color: var(--muted);
}

.dialog-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 40;
  max-width: min(360px, calc(100vw - 44px));
  transform: translateY(16px);
  border-radius: 14px;
  background: #101828;
  color: #fff;
  padding: 13px 15px;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
  box-shadow: var(--shadow);
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.mobile-bottom-nav {
  display: none;
}

@media (max-width: 1080px) {
  .login-panel,
  .dashboard-grid,
  .split-grid,
  .account-layout {
    grid-template-columns: 1fr;
  }

  .login-brand {
    min-height: 340px;
  }

  .sidebar {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .nav-list {
    grid-template-columns: 1fr;
  }

  .sidebar-footer {
    grid-template-columns: 1fr auto;
    align-items: center;
  }

  .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-bar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  body {
    background: var(--bg);
  }

  .login-shell {
    padding: 14px;
  }

  .login-panel {
    border-radius: 20px;
  }

  .login-brand,
  .login-form {
    padding: 26px;
  }

  .login-copy h1 {
    font-size: 32px;
  }

  .login-subtitle {
    font-size: 16px;
  }

  .sidebar {
    display: none;
  }

  .workspace {
    grid-template-rows: 52px 1fr;
    grid-template-columns: 1fr;
  }

  .main {
    max-width: none;
    padding: 12px 12px 88px;
  }

  .top-nav {
    height: 52px;
    min-height: 52px;
    padding: 0 12px;
  }

  .top-nav-button {
    min-height: 36px;
    padding: 0 8px;
    font-size: 13px;
  }

  .top-nav-button:not(.logout),
  .top-user,
  .top-nav-brand > div > span,
  .top-nav-brand .desktop-title {
    display: none !important;
  }

  .top-nav-brand .mobile-title {
    display: inline !important;
  }

  .top-nav-brand .brand-mark {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
    font-size: 12px;
  }

  .top-nav-brand strong {
    font-size: 16px;
  }

  .employee-head {
    display: flex;
  }

  .page-head,
  .panel-header {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .head-actions {
    justify-content: flex-start;
  }

  .today-card {
    grid-template-columns: 30px 1fr auto;
    align-items: center;
    padding: 10px 12px;
    gap: 9px;
  }

  .today-card > button {
    grid-column: auto;
    width: auto;
    padding: 0 6px;
    font-size: 12px;
  }

  .today-icon {
    width: 30px;
    height: 30px;
  }

  .today-card strong {
    display: block;
    font-size: 15px;
  }

  .today-card p {
    display: block;
    font-size: 12px;
  }

  .form-grid,
  .form-grid.two,
  .filter-bar,
  .filter-bar .wide,
  .sidebar-footer {
    grid-template-columns: 1fr;
  }

  .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .metric,
  .secondary-metrics .metric,
  .employee-metrics .metric {
    min-height: 88px;
    padding: 12px;
  }

  .metric strong,
  .secondary-metrics .metric strong,
  .employee-metrics .metric strong {
    font-size: 25px;
  }

  .admin-priority-screen {
    min-height: min(840px, calc(100svh - 76px));
    align-content: start;
  }

  .form-section {
    padding: 12px;
  }

  .panel-body,
  .panel-header {
    padding: 12px;
  }

  .form-actions {
    position: sticky;
    right: 0;
    bottom: 66px;
    z-index: 10;
    display: grid;
    grid-template-columns: 94px 1fr;
    gap: 10px;
    margin: 0 -12px -12px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
  }

  .submit-button,
  .form-actions .secondary-button {
    width: 100%;
  }

  .trend {
    grid-template-columns: repeat(7, minmax(24px, 1fr));
    gap: 7px;
    min-height: 220px;
  }

  .desktop-table {
    display: none;
  }

  .record-card-list {
    display: grid;
  }

  .dialog-actions,
  .mobile-quick-actions {
    grid-template-columns: 1fr;
  }

  .search-field {
    width: 100%;
  }

  .mobile-bottom-nav {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 25;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(14px);
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
  }

  .admin-mobile-nav {
    grid-template-columns: repeat(5, 1fr);
  }

  .admin-mobile-nav button {
    min-height: 46px;
    border-radius: 12px;
    font-size: 11px;
  }

  .account-toolbar .panel-body {
    align-items: stretch;
    flex-direction: column;
  }

  .account-tabs {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .account-tabs button {
    padding: 0 8px;
  }

  .account-actions {
    position: static;
    display: grid;
    grid-template-columns: 1fr;
    margin: 0;
    padding: 0;
  }

  .mobile-bottom-nav button {
    min-height: 48px;
    border: 0;
    border-radius: 14px;
    background: transparent;
    color: var(--muted);
    display: grid;
    place-items: center;
    gap: 2px;
    font-size: 12px;
  }

  .mobile-bottom-nav button.active {
    background: var(--accent-light);
    color: var(--accent);
  }

  .admin-mobile-nav button {
    min-height: 46px;
    font-size: 11px;
  }

  .mobile-bottom-nav svg {
    width: 19px;
    height: 19px;
  }
}
