:root {
  --page: #f3f6fb;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --line: #e7edf5;
  --text: #1f2937;
  --muted: #6b7280;
  --brand: #2563eb;
  --brand-2: #06b6d4;
  --navy: #0f1b2d;
  --navy-2: #13243b;
  --success: #16a34a;
  --warning: #f59e0b;
  --danger: #ef4444;
  --shadow: 0 14px 34px rgba(16, 24, 40, .08);
  --scrollbar-track: rgba(235, 242, 252, .82);
  --scrollbar-thumb: rgba(80, 131, 230, .58);
  --scrollbar-thumb-hover: rgba(37, 99, 235, .78);
}

/* Data management */
.data-management-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.data-hero {
  position: relative;
  min-height: 136px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 30px;
  overflow: hidden;
  background:
    radial-gradient(circle at 72% 28%, rgba(37, 99, 235, .16), transparent 32%),
    linear-gradient(110deg, rgba(255, 255, 255, .96), rgba(239, 248, 255, .78));
  border: 1px solid rgba(207, 222, 246, .9);
  box-shadow: 0 18px 45px rgba(34, 82, 151, .1);
}

.data-hero::after {
  content: "";
  position: absolute;
  right: 110px;
  bottom: -38px;
  width: 260px;
  height: 110px;
  border-radius: 80% 80% 0 0;
  background: linear-gradient(135deg, rgba(37, 99, 235, .12), rgba(6, 182, 212, .06));
  pointer-events: none;
}

.data-hero-copy,
.data-hero-actions,
.data-card-head,
.data-table-actions,
.data-form-actions {
  display: flex;
  align-items: center;
}

.data-hero-copy {
  gap: 18px;
  position: relative;
  z-index: 1;
}

.data-hero-icon {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 22px;
  color: #fff;
  font-size: 32px;
  background: linear-gradient(135deg, #2563eb, #10b7d7);
  box-shadow: 0 16px 32px rgba(37, 99, 235, .24);
}

.data-hero h2,
.data-card h3 {
  margin: 0;
  color: #14233b;
  font-weight: 900;
  letter-spacing: 0;
}

.data-hero h2 {
  font-size: 28px;
}

.data-hero p,
.data-card-head p {
  margin: 8px 0 0;
  color: #687894;
}

.data-hero-actions {
  position: relative;
  z-index: 1;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.data-main-action {
  min-width: 128px;
  border: 0;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  box-shadow: 0 14px 28px rgba(37, 99, 235, .24);
}

.data-main-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(37, 99, 235, .32);
}

.data-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.data-tab {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 22px;
  color: #34425a;
  text-decoration: none;
  font-weight: 800;
  border: 1px solid rgba(207, 222, 246, .95);
  border-radius: 14px;
  background: rgba(255, 255, 255, .84);
  box-shadow: 0 10px 24px rgba(62, 98, 153, .06);
  transition: .2s ease;
}

.data-tab:hover,
.data-tab.active {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #2563eb, #635bff);
  box-shadow: 0 14px 28px rgba(37, 99, 235, .22);
  transform: translateY(-1px);
}

.data-stat-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(320px, 1.4fr);
  gap: 14px;
}

.data-stat-card {
  min-height: 110px;
  padding: 24px;
  border: 1px solid rgba(218, 228, 244, .86);
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 16px 36px rgba(45, 84, 135, .08);
  transition: .2s ease;
}

.data-stat-card:hover,
.data-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 46px rgba(45, 84, 135, .12);
}

.data-stat-card span,
.data-filter-grid span {
  display: block;
  color: #687894;
  font-weight: 700;
}

.data-stat-card strong {
  display: block;
  margin-top: 10px;
  font-size: 28px;
  line-height: 1.1;
  color: #10213b;
}

.data-command-card code {
  display: block;
  margin-top: 12px;
  color: #18243a;
  white-space: normal;
  word-break: break-all;
  font-size: 15px;
  font-weight: 800;
}

.data-card {
  padding: 24px;
  border: 1px solid rgba(218, 228, 244, .86);
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 18px 44px rgba(45, 84, 135, .09);
  transition: .2s ease;
}

.data-card-head {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.data-card h3 {
  font-size: 22px;
}

.data-count {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  color: #315fb7;
  font-weight: 800;
  border-radius: 999px;
  background: rgba(37, 99, 235, .08);
}

.data-table-wrap {
  border: 1px solid #dbe6f6;
  border-radius: 14px;
  overflow: hidden;
}

.data-table {
  margin: 0;
  min-width: 960px;
}

.data-table thead th {
  height: 56px;
  color: #52627a;
  font-weight: 900;
  background: linear-gradient(180deg, #f8fbff, #f1f6fc);
  border-bottom: 1px solid #dce7f5;
}

.data-table tbody td {
  height: 58px;
  vertical-align: middle;
  color: #2d3a4f;
  border-bottom: 1px solid #e8eef7;
}

.data-table tbody tr:hover {
  background: linear-gradient(90deg, rgba(37, 99, 235, .045), rgba(6, 182, 212, .035));
}

.data-table-actions {
  gap: 8px;
  white-space: nowrap;
}

.data-table-actions form {
  margin: 0;
}

.data-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  font-weight: 900;
}

.data-status-success {
  color: #13934b;
  background: #dcfce7;
}

.data-status-danger {
  color: #dc2626;
  background: #fee2e2;
}

.data-export-card {
  background:
    linear-gradient(180deg, rgba(240, 253, 250, .64), rgba(255, 255, 255, .96) 120px),
    rgba(255, 255, 255, .92);
}

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

.data-filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.data-filter-grid .form-control,
.data-filter-grid .form-select {
  min-height: 48px;
  border-color: #d8e3f4;
  border-radius: 10px;
}

.data-form-actions {
  justify-content: space-between;
  margin-top: 18px;
}

@media (max-width: 992px) {
  .data-hero,
  .data-card-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .data-hero-actions,
  .data-form-actions {
    justify-content: flex-start;
  }

  .data-stat-grid,
  .data-filter-grid {
    grid-template-columns: 1fr;
  }

  .data-tab {
    flex: 1 1 160px;
    justify-content: center;
  }
}

html {
  scrollbar-gutter: stable;
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: linear-gradient(180deg, rgba(248, 251, 255, .92), rgba(235, 242, 252, .86));
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb {
  min-height: 44px;
  background: linear-gradient(180deg, rgba(132, 176, 255, .82), rgba(37, 99, 235, .72));
  border: 2px solid rgba(248, 251, 255, .95);
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28);
}

*::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(96, 165, 250, .95), var(--scrollbar-thumb-hover));
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

*::-webkit-scrollbar-button {
  width: 0;
  height: 0;
  display: none;
}

body {
  background: linear-gradient(180deg, #f7faff 0%, #eef3fb 100%);
  color: var(--text);
  font-size: 14px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
}

.app-shell {
  min-height: 100vh;
  display: flex;
}

.sidebar {
  width: 244px;
  flex: 0 0 244px;
  display: flex;
  flex-direction: column;
  background: #fff;
  color: var(--text);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  border-right: 1px solid var(--line);
  box-shadow: 10px 0 30px rgba(15, 23, 42, .05);
}

.sidebar .brand {
  height: 76px;
  padding: 16px 18px;
  border-bottom: 0;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
  background: linear-gradient(135deg, var(--navy), var(--navy-2));
  color: #fff;
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand small {
  display: block;
  color: rgba(255, 255, 255, .72);
  font-size: 11px;
  font-weight: 500;
  margin-top: 2px;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #f59e0b);
  box-shadow: 0 10px 22px rgba(37, 99, 235, .28);
}

.sidebar-nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-gutter: stable;
  padding: 14px 12px 18px;
}

.sidebar a {
  color: #344054;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0;
  padding: 12px 14px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  transition: background .16s ease, color .16s ease, box-shadow .16s ease;
}

.sidebar a i {
  width: 22px;
  color: #475467;
  font-size: 17px;
}

.sidebar a:hover,
.sidebar a.active {
  color: var(--brand);
  background: linear-gradient(135deg, rgba(37, 99, 235, .12), rgba(37, 99, 235, .04));
  box-shadow: none;
}

.sidebar a.active i,
.sidebar a:hover i {
  color: var(--brand);
}

.nav-group {
  margin: 4px 0;
}

.nav-group-title {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  border: 0;
  background: transparent;
  color: #344054;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 800;
  text-align: left;
  transition: background .16s ease, color .16s ease, box-shadow .16s ease;
}

.nav-group-title i {
  width: 22px;
  color: #475467;
  font-size: 17px;
}

.nav-group-title span {
  flex: 1;
}

.nav-group-title:hover,
.nav-group-title.active {
  color: var(--brand);
  background: linear-gradient(135deg, rgba(37, 99, 235, .12), rgba(124, 58, 237, .06));
}

.nav-group-title:hover i,
.nav-group-title.active i {
  color: var(--brand);
}

.nav-chevron {
  margin-left: auto;
  flex: 0 0 auto;
  transition: transform .16s ease;
}

.nav-collapsible .nav-children {
  display: none;
  padding: 2px 0 7px 34px;
}

.nav-collapsible.open .nav-children {
  display: block;
}

.nav-collapsible.open .nav-chevron {
  transform: rotate(180deg);
}

.nav-group a {
  min-height: 38px;
  margin: 3px 0;
  padding: 9px 12px;
  color: #667085;
  font-size: 13px;
  font-weight: 700;
  border-radius: 9px;
}

.nav-group a i {
  width: 18px;
  font-size: 14px;
  color: #98a2b3;
}

.nav-group a:hover,
.nav-group a.active {
  color: var(--brand);
  background: linear-gradient(135deg, rgba(37, 99, 235, .13), rgba(124, 58, 237, .06));
}

.nav-group a.active {
  box-shadow: inset 3px 0 0 rgba(37, 99, 235, .65);
}

.nav-group a:hover i,
.nav-group a.active i {
  color: var(--brand);
}

.sidebar-recycle {
  flex: 0 0 auto;
  padding: 10px 12px 16px;
  border-top: 1px solid #eef2f7;
  background: linear-gradient(180deg, rgba(255, 255, 255, .72), #fff);
}

.sidebar-recycle .recycle-link {
  position: relative;
  min-height: 48px;
  margin: 0;
  color: #667085;
  background: #f8fafc;
  border: 1px solid #e8eef7;
}

.sidebar-recycle .recycle-link:hover,
.sidebar-recycle .recycle-link.active {
  color: #ef4444;
  background: linear-gradient(135deg, rgba(239, 68, 68, .10), rgba(37, 99, 235, .04));
  border-color: rgba(239, 68, 68, .18);
}

.sidebar-recycle .recycle-link:hover i,
.sidebar-recycle .recycle-link.active i {
  color: #ef4444;
}

.sidebar-recycle .recycle-link em {
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  background: #ef4444;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(239, 68, 68, .24);
}

.sidebar-footer {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 26px;
  color: #64748b;
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 12px;
  line-height: 1.4;
}

.main {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.topbar {
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  height: 76px;
  padding: 0 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(14px);
}

.content {
  flex: 1;
  padding: 24px 28px 36px;
}

.topbar-title {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.top-user-menu {
  position: relative;
}

.top-user-pill {
  min-height: 54px;
  min-width: 186px;
  padding: 6px 14px 6px 7px;
  border: 1px solid rgba(211, 224, 245, .95);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #172033;
  background: linear-gradient(135deg, #f3f7ff 0%, #ffffff 100%);
  box-shadow: 0 16px 34px rgba(31, 73, 137, .10);
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.top-user-pill:hover,
.top-user-menu.open .top-user-pill {
  transform: translateY(-1px);
  border-color: rgba(74, 125, 255, .35);
  box-shadow: 0 20px 42px rgba(37, 99, 235, .16);
}

.top-user-avatar {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, #6b5cff 0%, #2563eb 100%);
  box-shadow: 0 10px 22px rgba(79, 70, 229, .28), inset 0 0 0 2px rgba(255, 255, 255, .35);
}

.top-user-avatar-lg {
  width: 48px;
  height: 48px;
  flex-basis: 48px;
  font-size: 20px;
}

.top-user-copy {
  min-width: 0;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.top-user-copy strong {
  max-width: 96px;
  color: #162033;
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-user-copy em {
  max-width: 108px;
  margin-top: 3px;
  color: #75839a;
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.top-user-caret {
  flex: 0 0 auto;
  color: #7b879b;
  font-size: 12px;
  transition: transform .18s ease;
}

.top-user-menu.open .top-user-caret {
  transform: rotate(180deg);
}

.top-user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 80;
  width: 258px;
  padding: 12px;
  border: 1px solid rgba(217, 226, 241, .92);
  border-radius: 16px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 24px 54px rgba(15, 23, 42, .16);
  backdrop-filter: blur(18px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px) scale(.98);
  transform-origin: top right;
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.top-user-menu.open .top-user-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.top-user-dropdown::before {
  content: "";
  position: absolute;
  top: -6px;
  right: 34px;
  width: 12px;
  height: 12px;
  border-left: 1px solid rgba(217, 226, 241, .92);
  border-top: 1px solid rgba(217, 226, 241, .92);
  background: rgba(255, 255, 255, .98);
  transform: rotate(45deg);
}

.top-user-dropdown-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 6px 14px;
}

.top-user-dropdown-head strong {
  display: block;
  color: #162033;
  font-size: 16px;
  font-weight: 900;
}

.top-user-dropdown-head small {
  display: block;
  margin-top: 2px;
  color: #697890;
  font-size: 12px;
}

.top-user-dropdown-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 0 10px;
  border-radius: 10px;
  color: #4f46e5;
  font-weight: 700;
  text-decoration: none;
  transition: background .16s ease, color .16s ease, transform .16s ease;
}

.top-user-dropdown-item i {
  width: 20px;
  color: #8a97aa;
  font-size: 18px;
}

.top-user-dropdown-item:hover {
  color: #1d4ed8;
  background: #f3f7ff;
  transform: translateX(2px);
}

.top-user-dropdown-item-muted {
  color: #aab3c3;
}

.top-user-dropdown-item-muted:hover {
  color: #64748b;
  background: #f7f9fc;
}

.top-user-dropdown-item-danger {
  color: #4f46e5;
}

.top-user-dropdown-item-danger:hover {
  color: #ef4444;
  background: #fff1f2;
}

.top-user-dropdown-divider {
  height: 1px;
  margin: 8px 2px;
  background: #e8eef7;
}

.soft-icon {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #2563eb;
  font-size: 22px;
  background: linear-gradient(135deg, #eff6ff 0%, #f8fbff 100%);
  border: 1px solid rgba(191, 219, 254, .85);
  box-shadow: 0 12px 24px rgba(37, 99, 235, .10);
}

.topbar-title-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 8px;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 20px;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  box-shadow: 0 12px 24px rgba(37, 99, 235, .20);
}

.app-footer {
  padding: 12px 28px 22px;
  color: #7a879a;
  font-size: 14px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  align-items: center;
  line-height: 1.55;
  text-align: center;
}

.app-version-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.app-version {
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: #4f46e5;
  font-weight: 500;
}

.app-footer-dot {
  color: #94a3b8;
}

.app-browser-tip {
  color: #8a94a6;
}

.app-browser-tip span {
  color: #4f46e5;
  font-weight: 500;
}

.panel {
  background: rgba(255, 255, 255, .96);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}

.role-action-group {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.role-action-group form {
  display: inline-flex;
  margin: 0;
}

.permission-page-toolbar {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.permission-page-nav {
  display: inline-flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid #dbe6f5;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 6px 16px rgba(15, 23, 42, .04);
}

.permission-page-nav a {
  min-height: 40px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid #e5edf8;
  color: #344054;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}

.permission-page-nav a:last-child {
  border-right: 0;
}

.permission-page-nav a:hover {
  color: #2563eb;
  background: #f6f9ff;
}

.permission-page-nav a.active {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #10b7d4);
  box-shadow: 0 8px 18px rgba(37, 99, 235, .18);
}

.role-auth-toolbar {
  align-items: flex-end;
  flex-direction: column;
}

.role-auth-btn {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  border: 0;
  box-shadow: 0 10px 20px rgba(37, 99, 235, .20);
}

.role-auth-top,
.role-info-card,
.permission-toolbar,
.permission-module-card {
  border-radius: 12px;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(12px);
}

.role-auth-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
}

.role-auth-heading,
.role-auth-actions,
.permission-module-head,
.permission-module-head > div,
.permission-toolbar,
.permission-quick-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.role-back-btn {
  text-decoration: none;
}

.role-auth-heading .hint {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}

.role-auth-count {
  color: var(--brand);
  font-weight: 800;
}

.role-info-card {
  padding: 22px;
}

.role-super-tip {
  border: 1px solid rgba(37, 99, 235, .18);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(37, 99, 235, .10), rgba(6, 182, 212, .08));
}

.permission-toolbar {
  justify-content: space-between;
  gap: 16px;
}

.permission-search {
  position: relative;
  min-width: min(360px, 100%);
}

.permission-search i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
}

.permission-search .form-control {
  padding-left: 40px;
}

.role-permission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.permission-module-card {
  padding: 18px;
  border: 1px solid rgba(226, 232, 240, .9);
  box-shadow: 0 18px 40px rgba(15, 23, 42, .06);
  transition: transform .2s ease, box-shadow .2s ease;
}

.permission-module-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 54px rgba(37, 99, 235, .10);
}

.permission-module-head {
  justify-content: space-between;
  margin-bottom: 14px;
}

.permission-module-head h3 {
  margin: 0;
  color: #172033;
  font-size: 16px;
  font-weight: 800;
}

.permission-module-head span {
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

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

.permission-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(248, 250, 252, .76);
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}

.permission-item:hover {
  background: #f3f7ff;
  border-color: #dbeafe;
}

.permission-item.is-checked {
  background: linear-gradient(135deg, rgba(37, 99, 235, .12), rgba(6, 182, 212, .08));
  border-color: rgba(37, 99, 235, .22);
}

.permission-item input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.permission-check-ui {
  width: 22px;
  height: 22px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: transparent;
  background: #fff;
  flex: 0 0 22px;
}

.permission-item.is-checked .permission-check-ui {
  color: #fff;
  border-color: #2563eb;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}

.permission-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.permission-copy strong {
  color: #172033;
  font-size: 14px;
}

.permission-copy code {
  color: #667085;
  font-size: 12px;
  white-space: normal;
}

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

.toolbar-card .hint {
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
}

.metric {
  background: linear-gradient(135deg, #fff, #f8fbff);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 17px;
  min-height: 108px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.metric::after {
  content: "";
  position: absolute;
  width: 88px;
  height: 88px;
  right: -28px;
  top: -28px;
  border-radius: 50%;
  background: rgba(37, 99, 235, .12);
}

.metric .label {
  color: var(--muted);
  font-size: 13px;
  position: relative;
  z-index: 1;
}

.metric .value {
  font-size: 24px;
  font-weight: 700;
  margin-top: 6px;
  position: relative;
  z-index: 1;
}

.metric-primary::after { background: rgba(37, 99, 235, .14); }
.metric-success::after { background: rgba(22, 163, 74, .14); }
.metric-warning::after { background: rgba(245, 158, 11, .16); }
.metric-danger::after { background: rgba(239, 68, 68, .12); }
.metric-cyan::after { background: rgba(6, 182, 212, .14); }
.metric-indigo::after { background: rgba(79, 70, 229, .12); }

.page-kicker {
  color: var(--muted);
  font-size: 13px;
}

.section-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
}

.table {
  vertical-align: middle;
  --bs-table-bg: transparent;
  border-collapse: separate;
  border-spacing: 0;
}

.table th,
.table td {
  vertical-align: middle !important;
}

.table thead th {
  color: #667085;
  font-weight: 600;
  background: var(--surface-soft);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.table tbody td {
  border-color: #eef2f7;
}

.table-cell {
  display: flex;
  align-items: center;
  height: 100%;
}

.form-label {
  font-size: 13px;
  color: #495057;
  margin-bottom: 5px;
}

.chart-box {
  height: 320px;
  width: 100%;
}

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

.btn-primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  border: 0;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .22);
}

.btn-outline-primary {
  border-color: rgba(37, 99, 235, .35);
  color: var(--brand);
}

.form-control,
.form-select {
  border-color: #dbe3ef;
  border-radius: 8px;
}

.form-control:focus,
.form-select:focus {
  border-color: rgba(37, 99, 235, .65);
  box-shadow: 0 0 0 .2rem rgba(37, 99, 235, .12);
}

.icon-btn {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #344054;
  display: inline-grid;
  place-items: center;
  position: relative;
}

.icon-btn:hover {
  background: #f2f6fc;
  color: var(--brand);
}

.icon-btn .dot {
  position: absolute;
  top: 3px;
  right: 3px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: #ff4d4f;
  color: #fff;
  font-size: 11px;
  line-height: 17px;
}

.top-actions .form-select {
  min-width: 130px;
}

.hero-profit {
  min-height: 246px;
  color: #fff;
  background:
    linear-gradient(135deg, #2563eb 0%, #1d4ed8 55%, #0ea5e9 100%);
  border: 0;
  overflow: hidden;
}

.hero-profit .label,
.hero-profit .subtle {
  color: rgba(255, 255, 255, .78);
}

.hero-profit .big {
  font-size: 42px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: 0;
}

.trend-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .15);
  color: #d6f8e6;
  font-weight: 700;
}

.kpi-card {
  min-height: 112px;
  display: flex;
  gap: 14px;
  align-items: center;
}

.kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 20px;
}

.kpi-blue { background: #eaf1ff; color: #2563eb; }
.kpi-green { background: #eaf8f0; color: #16a34a; }
.kpi-orange { background: #fff3df; color: #f59e0b; }
.kpi-purple { background: #f1ecff; color: #7c3aed; }

.dashboard-v2 {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.dashboard-v2 .panel {
  border: 1px solid rgba(216, 228, 246, .92);
  border-radius: 8px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 16px 36px rgba(36, 63, 108, .08);
}

.dashboard-profit-card {
  min-height: 260px;
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 78% 35%, rgba(255, 255, 255, .22), transparent 72px),
    linear-gradient(135deg, #2563eb 0%, #1d4ed8 56%, #0ea5e9 100%) !important;
}

.dashboard-profit-card::after {
  content: "";
  position: absolute;
  inset: auto 18px 22px auto;
  width: 185px;
  height: 88px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .10);
  transform: rotate(-12deg);
}

.dashboard-profit-head,
.dashboard-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.dashboard-profit-head {
  position: relative;
  z-index: 1;
  margin-bottom: 22px;
  font-size: 15px;
  font-weight: 800;
}

.dashboard-profit-head i {
  color: rgba(255, 255, 255, .82);
}

.dashboard-profit-amount {
  position: relative;
  z-index: 1;
  font-size: 42px;
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: 0;
}

.dashboard-profit-tags {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.dashboard-profit-tags span {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .13);
  color: rgba(255, 255, 255, .86);
  font-weight: 800;
}

.dashboard-profit-tags strong {
  color: #d6f8e6;
}

.dashboard-hero-chart {
  position: absolute;
  z-index: 1;
  right: 24px;
  bottom: 18px;
  left: 48%;
  height: 92px;
  opacity: .55;
}

.dashboard-kpi-card {
  min-height: 100%;
  display: flex;
  align-items: center;
  gap: 18px;
  transition: transform .18s ease, box-shadow .18s ease;
}

.dashboard-kpi-card:hover,
.dashboard-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 46px rgba(36, 63, 108, .11);
}

.dashboard-kpi-large {
  min-height: 128px;
  padding: 28px 30px;
}

.dashboard-kpi-small {
  min-height: 112px;
  padding: 22px 26px;
}

.dashboard-kpi-icon {
  flex: 0 0 58px;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  font-size: 28px;
}

.dashboard-kpi-icon.is-green { color: #16a34a; background: #e9f9ef; }
.dashboard-kpi-icon.is-orange { color: #f59e0b; background: #fff3de; }
.dashboard-kpi-icon.is-blue { color: #2563eb; background: #eef4ff; }
.dashboard-kpi-icon.is-purple { color: #8b5cf6; background: #f3efff; }

.dashboard-kpi-card span,
.dashboard-transfer-stats span {
  display: block;
  color: #667085;
  font-size: 14px;
  font-weight: 700;
}

.dashboard-kpi-card strong {
  display: block;
  margin-top: 3px;
  color: #172033;
  font-size: 24px;
  line-height: 1.2;
  font-weight: 900;
}

.dashboard-kpi-small strong {
  font-size: 22px;
}

.dashboard-kpi-card small {
  display: block;
  margin-top: 4px;
  font-weight: 800;
}

.dashboard-card {
  min-height: 100%;
  transition: transform .18s ease, box-shadow .18s ease;
}

.dashboard-card-head {
  margin-bottom: 16px;
}

.dashboard-card-head h2 {
  margin: 0;
  color: #172033;
  font-size: 17px;
  font-weight: 900;
}

.dashboard-card-head h2 i {
  margin-right: 8px;
}

.dashboard-card-head p {
  margin: 6px 0 0;
  color: #667085;
  font-size: 13px;
}

.dashboard-card-head a {
  color: #2563eb;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

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

.dashboard-segment {
  display: inline-flex;
  padding: 3px;
  border: 1px solid #dfe8f6;
  border-radius: 7px;
  background: #fff;
}

.dashboard-segment button {
  min-height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #667085;
  font-weight: 800;
}

.dashboard-segment button.active {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  box-shadow: 0 8px 18px rgba(37, 99, 235, .24);
}

.dashboard-chart {
  height: 260px;
}

.dashboard-transfer-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 14px;
}

.dashboard-transfer-stats strong {
  display: block;
  margin-top: 4px;
  font-size: 24px;
  font-weight: 900;
}

.dashboard-table {
  margin-bottom: 0;
  font-size: 14px;
}

.dashboard-table thead th {
  height: 38px;
  color: #344054;
  background: linear-gradient(180deg, #f8fbff, #f1f6fd);
  border-bottom: 1px solid #dfe8f6;
  font-weight: 900;
}

.dashboard-table tbody td {
  height: 38px;
  color: #344054;
  border-bottom: 1px solid #edf2f8;
  vertical-align: middle;
}

.dashboard-table tbody tr:hover td {
  background: #f8fbff;
}

.dashboard-rank-card {
  min-height: 310px;
}

.rank-badge.rank-1 {
  color: #fff;
  background: #f6b100;
}

.rank-badge.rank-2 {
  color: #fff;
  background: #94a3b8;
}

.rank-badge.rank-3 {
  color: #fff;
  background: #f59e72;
}

.dashboard-pill {
  min-width: 28px;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  font-weight: 900;
}

.dashboard-pill.is-in {
  color: #16a34a;
  background: #dcfce7;
}

.dashboard-pill.is-out {
  color: #f59e0b;
  background: #fff7ed;
}

.dashboard-risk-card {
  min-height: 310px;
}

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

.dashboard-risk-item,
.dashboard-risk-empty {
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: linear-gradient(135deg, #fff7f7, #fff);
}

.dashboard-risk-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  padding: 0 16px;
}

.dashboard-risk-item span {
  color: #172033;
  font-weight: 800;
}

.dashboard-risk-item strong {
  color: #ef4444;
  font-weight: 900;
}

.dashboard-risk-empty {
  min-height: 188px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: #172033;
  font-weight: 800;
}

.dashboard-risk-empty div {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  color: #ef4444;
  background: #fee2e2;
  font-size: 36px;
}

.dashboard-empty {
  min-height: 126px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #8a97ab;
  text-align: center;
}

.dashboard-empty-icon {
  width: 74px;
  height: 60px;
  display: grid;
  place-items: center;
  color: #4f8cff;
  border-radius: 20px;
  background: linear-gradient(135deg, #edf5ff, #ffffff);
  font-size: 30px;
}

.dashboard-empty strong {
  color: #172033;
  font-size: 15px;
  font-weight: 900;
}

.dashboard-empty span {
  font-size: 13px;
}

@media (max-width: 1199px) {
  .dashboard-hero-chart {
    left: 52%;
  }
}

@media (max-width: 767px) {
  .dashboard-profit-amount {
    font-size: 34px;
  }

  .dashboard-hero-chart {
    position: relative;
    inset: auto;
    width: 100%;
    margin-top: 10px;
  }

  .dashboard-transfer-stats {
    grid-template-columns: 1fr;
  }

  .dashboard-card-head {
    align-items: flex-start;
    flex-direction: column;
  }
}

.modal-backdrop.show {
  opacity: .58;
  backdrop-filter: blur(2px);
}

.modal-dialog {
  --bs-modal-width: 760px;
}

.modal-lg {
  --bs-modal-width: 860px;
}

.modal-xl {
  --bs-modal-width: 980px;
}

.modal-content {
  border: 1px solid rgba(226, 232, 240, .96);
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 28px 80px rgba(15, 23, 42, .30);
}

.modal-header {
  min-height: 78px;
  padding: 20px 24px;
  border-bottom: 1px solid #e6edf7;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.modal-title {
  color: #1f2a44;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0;
  padding-right: 48px;
  margin: 0;
}

.modal-header .btn-close {
  width: 40px;
  height: 40px;
  margin: 0;
  border-radius: 10px;
  opacity: .62;
  flex: 0 0 40px;
  background-size: 15px;
  transition: background .16s ease, opacity .16s ease, transform .16s ease;
}

.modal-header .btn-close:hover {
  background-color: #eef4ff;
  opacity: .9;
}

.modal-header .btn-close:active {
  transform: scale(.94);
}

.modal-body {
  padding: 24px;
}

.modal-footer {
  min-height: 74px;
  gap: 12px;
  padding: 16px 24px;
  border-top: 1px solid #e6edf7;
  background: #f8fafc;
  justify-content: flex-end;
}

.modal-footer .btn {
  min-width: 92px;
  min-height: 44px;
  border-radius: 9px;
  font-size: 16px;
  font-weight: 600;
}

.modal-footer .btn-light {
  color: #1f2937;
  background: #fff;
  border: 1px solid #dbe3ef;
  box-shadow: 0 4px 12px rgba(15, 23, 42, .04);
}

.modal .form-label {
  color: #3f4a5f;
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 8px;
}

.list-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 14px;
  flex-wrap: wrap;
  color: #344054;
}

.page-btn,
.page-indicator,
.page-total {
  min-width: 48px;
  height: 34px;
  padding: 0 14px;
  border-radius: 7px;
  border: 1px solid #dbe3ef;
  background: #fff;
  color: #344054;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  line-height: 1;
  box-shadow: 0 2px 8px rgba(15, 23, 42, .03);
}

.page-size-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 10px 0 12px;
  border: 1px solid #dbe3ef;
  border-radius: 7px;
  background: #fff;
  color: #667085;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(15, 23, 42, .03);
}

.page-size-select {
  height: 28px;
  min-width: 82px;
  border: 0;
  outline: 0;
  color: #344054;
  background: transparent;
  font-weight: 700;
  cursor: pointer;
}

.page-btn {
  cursor: pointer;
  transition: background .16s ease, color .16s ease, border-color .16s ease, transform .16s ease;
  text-decoration: none;
}

.page-btn:hover:not(:disabled) {
  color: #2563eb;
  border-color: #bcd0ff;
  background: #f7faff;
}

.page-btn:active:not(:disabled) {
  transform: translateY(1px);
}

.page-btn.active {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #6366f1, #2563eb);
  box-shadow: 0 8px 18px rgba(37, 99, 235, .22);
}

.page-btn:disabled {
  cursor: not-allowed;
  opacity: .5;
}

.page-btn.disabled {
  cursor: not-allowed;
  opacity: .5;
  pointer-events: none;
}

.page-indicator {
  min-width: 56px;
  color: #1f2937;
}

.page-total {
  min-width: 70px;
  color: #1f2937;
}

.modal .form-label.required::before {
  content: "*";
  color: #ff4d4f;
  margin-right: 4px;
  font-weight: 700;
}

.modal .form-control,
.modal .form-select,
.modal .input-group-text {
  min-height: 46px;
  border-color: #d8e2f0;
  border-radius: 9px;
  font-size: 16px;
}

.modal textarea.form-control {
  min-height: 118px;
}

.modal .input-group .form-control {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.modal .input-group .input-group-text {
  min-width: 48px;
  justify-content: center;
  color: #98a2b3;
  background: #fff;
  border-left: 0;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.modal-tip {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  color: #475467;
  background: linear-gradient(135deg, #eef5ff, #f7fbff);
  border: 1px solid #d9e8ff;
  border-radius: 9px;
  font-size: 14px;
  line-height: 1.55;
}

.modal-tip i {
  color: var(--brand);
  margin-top: 2px;
}

.action-cell {
  white-space: nowrap;
}

.account-action-group {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.account-sort-form,
.company-sort-form {
  display: inline-flex;
  align-items: center;
  margin: 0;
}

.company-toolbar-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.account-sort-name-cell,
.company-sort-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.account-drag-handle,
.company-drag-handle {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 28px;
  color: #7b8aa0;
  background: #f4f7fb;
  border: 1px solid #dbe5f2;
  border-radius: 8px;
  cursor: grab;
}

.account-drag-handle:active,
.company-drag-handle:active {
  cursor: grabbing;
}

.account-sort-table tbody tr[draggable="true"],
.company-sort-table tbody tr[draggable="true"] {
  cursor: grab;
}

.account-sort-table tbody tr.account-row-dragging,
.company-sort-table tbody tr.company-row-dragging {
  opacity: .46;
}

.account-sort-table tbody tr.account-row-drop-before td,
.company-sort-table tbody tr.company-row-drop-before td {
  border-top: 2px solid #2563eb;
}

.account-flow-page {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.account-flow-filter-panel {
  padding: 20px 22px 18px;
}

.account-flow-filter-head,
.account-flow-filter-actions,
.account-flow-quick-ranges,
.account-flow-year-ranges,
.account-flow-table-head {
  display: flex;
  align-items: center;
}

.account-flow-filter-head,
.account-flow-table-head {
  justify-content: space-between;
  gap: 16px;
}

.account-flow-filter-head {
  padding-bottom: 14px;
  border-bottom: 1px solid #e6edf7;
}

.account-flow-filter-head h3,
.account-flow-table-head h3 {
  margin: 0;
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.account-flow-filter-head h3 i,
.account-flow-table-head h3 i {
  color: #2563eb;
  margin-right: 8px;
}

.account-flow-filter-head p {
  margin: 5px 0 0;
  color: #667085;
  font-size: 13px;
}

.account-flow-filter-actions {
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.account-flow-quick-ranges {
  gap: 10px;
  padding: 16px 0 4px;
}

.account-flow-year-ranges {
  gap: 8px;
  flex-wrap: wrap;
  padding: 4px 0 14px;
}

.account-flow-year-ranges span {
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.account-flow-quick-ranges button,
.account-flow-year-ranges button {
  min-height: 34px;
  padding: 0 14px;
  color: #344054;
  font-weight: 800;
  background: #fff;
  border: 1px solid #dbe6f5;
  border-radius: 999px;
  transition: color .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.account-flow-quick-ranges button:hover,
.account-flow-quick-ranges button.active,
.account-flow-year-ranges button:hover,
.account-flow-year-ranges button.active {
  color: #2563eb;
  border-color: #bcd0ff;
  background: #f6f9ff;
}

.account-flow-quick-ranges button.active,
.account-flow-year-ranges button.active {
  color: #fff;
  border-color: #2563eb;
  background: #2563eb;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .18);
}

.account-flow-filter-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.account-flow-filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: #344054;
  font-size: 13px;
  font-weight: 800;
}

.account-flow-keyword {
  grid-column: span 2;
}

.account-flow-showcase {
  padding-top: 20px;
}

.account-flow-table-head {
  margin-bottom: 14px;
}

.account-flow-table-head span {
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.account-flow-table {
  border-collapse: separate;
  border-spacing: 0 8px;
}

.account-flow-table thead th {
  border-bottom: 0;
}

.account-flow-table tbody td {
  padding: 14px 12px;
  vertical-align: middle;
  background: #fff;
  border-top: 1px solid #e7eef8;
  border-bottom: 1px solid #e7eef8;
}

.account-flow-table tbody tr:not(.empty-row) td:first-child {
  border-left: 1px solid #e7eef8;
  border-radius: 10px 0 0 10px;
}

.account-flow-table tbody tr:not(.empty-row) td:last-child {
  border-right: 1px solid #e7eef8;
  border-radius: 0 10px 10px 0;
}

.account-flow-table tbody tr:not(.empty-row):hover td {
  background: #f8fbff;
}

.account-flow-time {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.account-flow-time strong {
  color: #101828;
  font-size: 14px;
}

.account-flow-time small {
  color: #8a98ad;
  font-size: 12px;
}

.account-flow-type-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
}

.account-flow-type-in {
  color: #14804a;
  background: #ecfdf3;
}

.account-flow-type-out {
  color: #d92d20;
  background: #fff1f3;
}

.account-flow-type-neutral {
  color: #2563eb;
  background: #eef5ff;
}

.account-flow-money {
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.account-flow-money-in {
  color: #14804a;
}

.account-flow-money-out {
  color: #f04438;
}

.account-flow-money-neutral {
  color: #2563eb;
}

.account-flow-source {
  color: #344054;
  font-weight: 800;
}

.account-flow-remark {
  max-width: 780px;
  color: #344054;
  line-height: 1.55;
  word-break: break-word;
}

.account-switch-line {
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid #d8e2f0;
  border-radius: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #344054;
  background: #fff;
  cursor: pointer;
}

.account-switch-line .form-check-input {
  margin: 0;
}

.empty-row {
  height: 78px;
}

.feature-hero {
  min-height: 132px;
  padding: 26px 30px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(110deg, rgba(255, 255, 255, .98) 0%, rgba(255, 255, 255, .98) 55%, rgba(233, 243, 255, .92) 100%);
}

.feature-hero::after {
  content: "";
  position: absolute;
  right: 84px;
  bottom: -2px;
  width: 260px;
  height: 96px;
  opacity: .45;
  background:
    linear-gradient(135deg, transparent 0 34%, rgba(37, 99, 235, .18) 34% 36%, transparent 36%),
    linear-gradient(155deg, transparent 0 56%, rgba(6, 182, 212, .14) 56% 58%, transparent 58%),
    linear-gradient(180deg, transparent 0 68%, rgba(37, 99, 235, .10) 68% 100%);
  clip-path: polygon(0 72%, 18% 48%, 30% 58%, 45% 28%, 62% 46%, 78% 18%, 100% 38%, 100% 100%, 0 100%);
}

.feature-hero > * {
  position: relative;
  z-index: 1;
}

.feature-icon {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: linear-gradient(135deg, #eaf2ff, #f7fbff);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .08);
  font-size: 28px;
}

.data-showcase {
  padding: 24px;
  background: rgba(255, 255, 255, .98);
}

.data-showcase .table {
  margin-bottom: 0;
}

.data-showcase thead th {
  padding-top: 14px;
  padding-bottom: 14px;
  font-size: 15px;
  color: #344054;
}

.empty-illustration,
.soft-empty {
  min-height: 210px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #667085;
}

.soft-empty {
  min-height: 132px;
}

.empty-illustration i,
.soft-empty i {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 36px;
  color: #5b9cff;
  background: #edf5ff;
}

.empty-illustration strong,
.soft-empty strong {
  color: #1f2937;
  font-size: 18px;
}

.text-purple {
  color: #7c3aed !important;
}

.department-group {
  padding: 12px 0;
  border-bottom: 1px solid #eef2f7;
}

.department-group:last-child {
  border-bottom: 0;
}

.department-group-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  color: #344054;
  font-weight: 700;
}

.customer-toolbar,
.staff-hero {
  overflow: visible;
}

.customer-toolbar-actions,
.staff-toolbar-actions,
.staff-hero-stats,
.customer-table-head,
.staff-filter-bar,
.staff-person,
.customer-sync-state {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.customer-toolbar-actions,
.staff-toolbar-actions {
  justify-content: flex-end;
}

.customer-sync-state {
  margin-top: 10px;
  color: #64748b;
  font-size: 13px;
}

.customer-sync-state i {
  color: #2563eb;
}

.customer-table-head {
  justify-content: space-between;
  margin-bottom: 16px;
}

.customer-table-head h3 {
  margin: 0;
  color: #172033;
  font-size: 18px;
  font-weight: 900;
}

.customer-table-head p {
  margin: 4px 0 0;
  color: #667085;
}

.customer-filter-tip {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 12px;
  border-radius: 999px;
  color: #2563eb;
  background: #eef5ff;
  font-weight: 700;
}

.customer-list-table {
  border-collapse: separate;
  border-spacing: 0;
}

.customer-list-table thead th {
  height: 48px;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  vertical-align: middle !important;
  display: table-cell;
  text-align: left;
  line-height: 48px;
  font-weight: 700;
}

.customer-list-table tbody td {
  height: 56px;
  padding-top: 8px;
  padding-bottom: 8px;
  vertical-align: middle !important;
  line-height: 1.4;
}

.customer-list-table th.text-end {
  text-align: right;
}

.customer-list-table thead th i {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  vertical-align: -2px;
}

.customer-list-table .badge,
.customer-list-table .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
}

.customer-list-table .action-cell {
  white-space: nowrap;
}

.customer-cell,
.customer-name-cell,
.customer-provider-cell {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  min-height: 40px;
}

.customer-cell strong,
.customer-name-cell strong,
.customer-provider-cell strong {
  line-height: 1.35;
}

.customer-cell small,
.customer-name-cell small,
.customer-provider-cell small {
  color: #64748b;
  line-height: 1.35;
}

.staff-feature-icon {
  color: #fff;
  background: linear-gradient(135deg, #4f7cff, #2563eb);
  box-shadow: 0 14px 30px rgba(37, 99, 235, .18);
}

.staff-hero {
  min-height: 116px;
  border-radius: 12px;
}

.staff-hero-stats {
  margin-top: 12px;
}

.staff-hero-stats span {
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #64748b;
  background: #f4f8ff;
  font-size: 13px;
  font-weight: 700;
}

.staff-hero-stats strong {
  color: #2563eb;
}

.staff-department-popover {
  position: absolute;
  right: 260px;
  top: calc(100% - 26px);
  z-index: 8;
  width: min(360px, calc(100vw - 60px));
  display: none;
  padding: 18px;
  border: 1px solid #e2eaf6;
  border-radius: 12px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 24px 60px rgba(15, 23, 42, .14);
}

.staff-department-popover.show {
  display: block;
}

.staff-department-popover::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 42px;
  width: 16px;
  height: 16px;
  transform: rotate(45deg);
  border-left: 1px solid #e2eaf6;
  border-top: 1px solid #e2eaf6;
  background: #fff;
}

.staff-department-company + .staff-department-company {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #edf2f8;
}

.staff-department-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  color: #172033;
}

.staff-department-title i {
  color: #344054;
}

.staff-department-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

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

.staff-row-actions form {
  margin: 0;
}

.department-manager .modal-body {
  padding: 22px;
}

.department-manager-grid {
  display: grid;
  grid-template-columns: minmax(260px, 360px) minmax(320px, 1fr);
  gap: 16px;
  margin-bottom: 18px;
}

.department-card {
  padding: 16px;
  border: 1px solid #dbe6f5;
  border-radius: 10px;
  background: linear-gradient(180deg, #fbfdff, #fff);
}

.department-card h6 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  color: #1f2a44;
  font-size: 16px;
  font-weight: 900;
}

.department-card h6 i {
  color: #2563eb;
}

.department-merge-sources {
  min-height: 128px;
}

.department-list-frame {
  border: 1px solid #dbe6f5;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.department-list-title {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 18px;
  border-bottom: 1px solid #e8eef7;
  background: #f8fbff;
}

.department-list-title strong {
  color: #1f2a44;
  font-weight: 900;
}

.department-list-title span {
  color: #667085;
  font-weight: 700;
}

.department-list-table {
  margin-bottom: 0;
}

.staff-workbench {
  padding: 24px;
  border-radius: 12px;
}

.staff-filter-bar {
  padding-bottom: 22px;
}

.staff-search,
.staff-date {
  position: relative;
  margin: 0;
}

.staff-search i,
.staff-date i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #667085;
  z-index: 1;
}

.staff-search .form-control {
  width: 290px;
  height: 42px;
  padding-left: 40px;
}

.staff-filter-bar .form-select {
  width: 190px;
  height: 42px;
}

.staff-date {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.staff-date .form-control {
  width: 150px;
  height: 42px;
  padding-left: 40px;
}

.staff-table-frame {
  overflow: hidden;
  border: 1px solid #dfe8f6;
  border-radius: 12px;
  background: #fff;
}

.staff-table {
  margin-bottom: 0;
}

.staff-table thead th {
  height: 58px;
  padding: 0 18px;
  color: #53627a;
  background: linear-gradient(180deg, #fbfdff, #f4f8fd);
  font-weight: 900;
}

.staff-table tbody td {
  height: 64px;
  padding: 0 18px;
}

.staff-table tbody tr:hover td {
  background: #f8fbff;
}

.staff-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  color: #2563eb;
  background: linear-gradient(135deg, #eaf2ff, #ffffff);
  border: 1px solid #dbeafe;
  font-weight: 900;
}

.staff-empty {
  min-height: 330px;
}

.business-search-field {
  position: relative;
}

.business-suggestions {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  z-index: 1060;
  display: none;
  padding: 8px;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .14);
  max-height: 240px;
  overflow: auto;
}

.business-suggestions.show {
  display: block;
}

.business-suggestion {
  width: 100%;
  display: block;
  padding: 9px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #1f2937;
  text-align: left;
}

.business-suggestion:hover {
  background: #f2f7ff;
}

.business-suggestion span {
  display: block;
  font-weight: 700;
}

.business-suggestion small,
.business-suggestion-empty {
  color: #7a879a;
}

.business-suggestion-empty {
  padding: 10px;
}

.rank-badge {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: #eef4ff;
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}

.tree-indent {
  display: inline-block;
  width: calc(var(--level) * 22px);
}

.category-hero {
  min-height: 154px;
  margin-bottom: 18px;
}

.category-hero .feature-icon {
  width: 74px;
  height: 74px;
  flex-basis: 74px;
  border-radius: 50%;
  color: #2563eb;
  background: rgba(255, 255, 255, .82);
  border: 10px solid rgba(232, 241, 255, .88);
  box-shadow: 0 14px 34px rgba(37, 99, 235, .16);
}

.category-console {
  padding: 24px 26px 22px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .94);
  border: 1px solid rgba(214, 226, 245, .95);
  box-shadow: 0 18px 45px rgba(24, 47, 92, .08);
}

.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 24px;
}

.category-tab {
  min-width: 158px;
  height: 48px;
  padding: 0 18px;
  border: 1px solid #d9e4f5;
  border-radius: 9px;
  background: #fff;
  color: #344054;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, color .18s ease, background .18s ease;
}

.category-tab i {
  color: #50627d;
  font-size: 18px;
}

.category-tab small {
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #667085;
  background: #f2f6fd;
  font-size: 12px;
}

.category-tab:hover {
  transform: translateY(-1px);
  border-color: #bcd0ff;
  box-shadow: 0 10px 22px rgba(37, 99, 235, .10);
}

.category-tab.active {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(135deg, #2563eb 0%, #2563eb 56%, #12b8d7 100%);
  box-shadow: 0 14px 28px rgba(37, 99, 235, .22);
}

.category-tab.active i,
.category-tab.active small {
  color: #fff;
}

.category-tab.active small {
  background: rgba(255, 255, 255, .18);
}

.category-pane {
  display: none;
}

.category-pane.active {
  display: block;
}

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

.category-pane-head h3 {
  margin: 0;
  color: #101828;
  font-size: 20px;
  font-weight: 900;
}

.category-pane-head p {
  margin: 5px 0 0;
  color: #667085;
  font-size: 14px;
}

.category-count {
  padding: 7px 12px;
  border-radius: 999px;
  color: #2563eb;
  background: #eef5ff;
  font-weight: 800;
  white-space: nowrap;
}

.category-table {
  overflow: hidden;
  border: 1px solid #dfe8f6;
  border-radius: 12px;
  border-collapse: separate;
  border-spacing: 0;
}

.category-table thead th {
  height: 58px;
  padding: 0 24px;
  color: #475467;
  background: linear-gradient(180deg, #fbfdff, #f4f8fd);
  border-bottom: 1px solid #dfe8f6;
  font-size: 15px;
  font-weight: 900;
}

.category-table tbody td {
  height: 56px;
  padding: 0 24px;
  vertical-align: middle;
  border-bottom: 1px solid #edf2f8;
}

.category-table tbody tr:hover td {
  background: #f8fbff;
}

.category-action {
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

.category-action i {
  margin-right: 5px;
}

.category-hero-v2 {
  min-height: 142px;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 28px 38px;
  border-radius: 14px;
  background:
    linear-gradient(105deg, rgba(255, 255, 255, .98) 0%, rgba(255, 255, 255, .98) 54%, rgba(232, 243, 255, .92) 100%);
  border: 1px solid rgba(214, 226, 245, .96);
  box-shadow: 0 18px 42px rgba(24, 47, 92, .08);
}

.category-hero-v2::after {
  opacity: .16;
  right: 92px;
  width: 320px;
}

.category-hero-visual {
  width: 130px;
  height: 84px;
  position: relative;
  flex: 0 0 130px;
}

.category-hero-file {
  position: absolute;
  left: 14px;
  top: 8px;
  width: 78px;
  height: 64px;
  border-radius: 8px;
  background: linear-gradient(135deg, #4f8cff, #87b9ff);
  box-shadow: 0 18px 32px rgba(37, 99, 235, .18);
}

.category-hero-file::before,
.category-hero-file::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  height: 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .72);
}

.category-hero-file::before {
  top: 16px;
}

.category-hero-file::after {
  top: 34px;
  width: 34px;
}

.category-hero-leaf {
  position: absolute;
  right: 12px;
  bottom: 3px;
  width: 44px;
  height: 60px;
  border-radius: 44px 44px 10px 44px;
  background: linear-gradient(135deg, rgba(37, 99, 235, .16), rgba(34, 211, 238, .14));
  transform: rotate(18deg);
}

.category-hero-copy {
  flex: 1;
}

.category-hero-copy .section-title {
  font-size: 24px;
  margin-bottom: 8px;
}

.category-hero-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.category-create-btn {
  min-width: 148px;
  height: 54px;
  border-radius: 9px;
  box-shadow: 0 14px 28px rgba(37, 99, 235, .24);
}

.category-merge-btn {
  min-width: 128px;
  height: 48px;
  border-radius: 9px;
  border: 1px solid #cfe0ff;
  color: #2563eb;
  font-weight: 800;
  background: rgba(255, 255, 255, .92);
}

.category-merge-sources {
  min-height: 240px;
}

.category-merge-tip i {
  color: #f59e0b;
}

.category-tabs-shell {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin: 24px 10px -1px;
  position: relative;
  z-index: 2;
}

.category-tabs-shell .category-tabs {
  margin-bottom: 0;
  gap: 10px;
}

.category-tabs-shell .category-tab {
  min-width: 164px;
  height: 58px;
  border-radius: 10px 10px 0 0;
  border-color: #dbe6f5;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 10px 24px rgba(15, 23, 42, .04);
}

.category-tabs-shell .category-tab.active {
  color: #2563eb;
  border-color: #7da2ff;
  border-bottom-color: #fff;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 -1px 0 #fff inset, 0 14px 28px rgba(37, 99, 235, .08);
}

.category-tabs-shell .category-tab.active i {
  color: #2563eb;
}

.category-tabs-shell .category-tab.active small {
  color: #2563eb;
  background: #eef5ff;
}

.category-tabs-tip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #475467;
  font-size: 14px;
  margin-bottom: 16px;
  white-space: nowrap;
}

.category-tabs-tip i {
  color: #2563eb;
}

.category-console-v2 {
  padding: 30px 32px 28px;
  border-radius: 14px;
  border: 1px solid #dbe6f5;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 18px 45px rgba(24, 47, 92, .08);
}

.category-pane-head-v2 {
  margin-bottom: 22px;
}

.category-current-title {
  display: flex;
  align-items: center;
  gap: 18px;
}

.category-current-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  color: #2563eb;
  background: linear-gradient(135deg, #eef5ff, #ffffff);
  box-shadow: 0 14px 28px rgba(37, 99, 235, .10);
  font-size: 26px;
}

.category-current-icon-income { color: #10b981; }
.category-current-icon-expense { color: #ef4444; }
.category-current-icon-project { color: #2563eb; }
.category-current-icon-transfer { color: #0ea5e9; }

.category-current-title h3 {
  margin: 0;
  font-size: 24px;
  color: #101828;
  font-weight: 900;
}

.category-current-title p {
  margin: 6px 0 0;
  color: #475467;
  font-size: 16px;
}

.category-table-wrap {
  border: 1px solid #dbe6f5;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.category-console-v2 .category-table {
  border: 0;
  border-radius: 0;
  margin-bottom: 0;
}

.category-console-v2 .category-table thead th {
  height: 50px;
  padding: 0 28px;
  background: linear-gradient(180deg, #fbfdff, #f5f8fc);
}

.category-console-v2 .category-table tbody td {
  height: 54px;
  padding: 0 28px;
}

.category-tree-mark {
  color: #98a2b3;
  margin-right: 8px;
}

.finance-account-field {
  transition: opacity .18s ease, transform .18s ease;
}

.finance-account-select option {
  font-size: 14px;
}

.account-select-help {
  margin-top: 6px;
  color: #667085;
  font-size: 12px;
}

.finance-flow-label {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #2563eb;
  background: #eef5ff;
  font-weight: 700;
}

.finance-ledger-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.finance-hero {
  min-height: 112px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 28px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, .98) 0%, rgba(247, 251, 255, .96) 62%, rgba(231, 244, 255, .95) 100%),
    radial-gradient(circle at 86% 25%, rgba(37, 99, 235, .16), transparent 28%);
  overflow: hidden;
  position: relative;
}

.finance-hero::after {
  content: "";
  position: absolute;
  right: 72px;
  bottom: -42px;
  width: 260px;
  height: 120px;
  background: linear-gradient(135deg, rgba(37, 99, 235, .10), rgba(14, 165, 233, .05));
  border-radius: 100% 100% 0 0;
  transform: skewX(-18deg);
  pointer-events: none;
}

.finance-hero-copy {
  display: flex;
  align-items: center;
  gap: 18px;
  position: relative;
  z-index: 1;
}

.finance-hero-icon,
.finance-stat-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
}

.finance-hero-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  color: #2563eb;
  background: linear-gradient(135deg, #eef5ff, #ffffff);
  border: 1px solid #d9e8ff;
  box-shadow: 0 14px 28px rgba(37, 99, 235, .12);
  font-size: 28px;
}

.finance-hero h2 {
  margin: 0;
  color: #101828;
  font-size: 24px;
  font-weight: 900;
}

.finance-hero p {
  margin: 8px 0 0;
  color: #667085;
  font-size: 15px;
}

.finance-hero-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex: 0 0 auto;
  position: relative;
  z-index: 1;
}

.finance-hero-actions .btn {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
}

.finance-primary-action {
  min-height: 46px;
  padding: 0 20px;
  position: relative;
  z-index: 1;
  box-shadow: 0 14px 26px rgba(37, 99, 235, .24);
}

.finance-native-select-hidden {
  display: none !important;
}

.finance-search-select {
  position: relative;
}

.finance-search-input {
  padding-right: 42px;
}

.finance-search-caret {
  position: absolute;
  top: 50%;
  right: 14px;
  z-index: 2;
  color: #667085;
  transform: translateY(-50%);
  pointer-events: none;
}

.finance-search-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 1085;
  max-height: 280px;
  overflow-y: auto;
  padding: 6px;
  background: #fff;
  border: 1px solid #cfe0f7;
  border-radius: 10px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, .18);
}

.finance-search-select.open .finance-search-dropdown {
  display: block;
}

.finance-search-option {
  width: 100%;
  display: block;
  padding: 9px 11px;
  color: #101828;
  font-size: 14px;
  line-height: 1.35;
  text-align: left;
  word-break: break-word;
  background: transparent;
  border: 0;
  border-radius: 8px;
}

.finance-search-option:hover,
.finance-search-option.active {
  color: #1d4ed8;
  background: #eef5ff;
}

.finance-search-option.selected {
  color: #fff;
  background: #2563eb;
}

.finance-search-empty {
  padding: 12px;
  color: #8a98ad;
  font-size: 14px;
}

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

.finance-stat-card {
  min-height: 112px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 24px;
  border: 1px solid rgba(219, 230, 245, .88);
  border-radius: 14px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 18px 44px rgba(24, 47, 92, .08);
  backdrop-filter: blur(12px);
  position: relative;
  overflow: hidden;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.finance-stat-card:hover {
  transform: translateY(-3px);
  border-color: rgba(105, 134, 255, .38);
  box-shadow: 0 22px 54px rgba(24, 47, 92, .14);
}

.finance-stat-card::after {
  content: "";
  position: absolute;
  right: -26px;
  top: -30px;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  opacity: .24;
}

.finance-stat-income::after { background: #22c55e; }
.finance-stat-expense::after { background: #ef4444; }
.finance-stat-profit::after { background: #6366f1; }
.finance-stat-count::after { background: #0ea5e9; }

.finance-stat-icon {
  width: 58px;
  height: 58px;
  border-radius: 17px;
  font-size: 24px;
}

.finance-stat-income .finance-stat-icon {
  color: #16a34a;
  background: linear-gradient(135deg, #ecfdf3, #ffffff);
}

.finance-stat-expense .finance-stat-icon {
  color: #ef4444;
  background: linear-gradient(135deg, #fff1f2, #ffffff);
}

.finance-stat-profit .finance-stat-icon {
  color: #4f46e5;
  background: linear-gradient(135deg, #eef2ff, #ffffff);
}

.finance-stat-count .finance-stat-icon {
  color: #0284c7;
  background: linear-gradient(135deg, #e0f2fe, #ffffff);
}

.finance-stat-card small,
.finance-stat-card em {
  display: block;
  color: #667085;
  font-style: normal;
}

.finance-stat-card small {
  font-size: 14px;
  font-weight: 700;
}

.finance-stat-card strong {
  display: block;
  margin-top: 5px;
  font-size: 28px;
  line-height: 1.12;
  color: #101828;
  font-weight: 950;
  letter-spacing: 0;
}

.finance-stat-card em {
  margin-top: 7px;
  font-size: 13px;
}

.finance-filter-panel {
  padding: 24px 28px 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .98), rgba(248, 252, 255, .96));
}

.finance-filter-panel.is-collapsed {
  padding-bottom: 24px;
}

.finance-filter-body {
  max-height: 1400px;
  overflow: hidden;
  opacity: 1;
  transition: max-height .28s ease, opacity .2s ease, margin .2s ease;
}

.finance-filter-panel.is-collapsed .finance-filter-body {
  max-height: 0;
  margin-top: 0;
  opacity: 0;
  pointer-events: none;
}

.finance-filter-panel.is-collapsed .finance-filter-title {
  padding-bottom: 0;
  border-bottom: 0;
}

.finance-filter-title,
.finance-table-head,
.finance-filter-actions,
.finance-quick-ranges,
.finance-year-ranges,
.finance-type-segment,
.finance-pagination {
  display: flex;
  align-items: center;
}

.finance-filter-title {
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e6edf7;
}

.finance-filter-title h3,
.finance-table-head h3 {
  margin: 0;
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.finance-filter-title h3 i,
.finance-table-head h3 i {
  color: #2563eb;
  margin-right: 8px;
}

.finance-filter-title p {
  margin: 5px 0 0;
  color: #667085;
  font-size: 13px;
}

.finance-filter-actions {
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.finance-filter-actions .btn {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  font-weight: 800;
}

.finance-filter-dashboard {
  display: grid;
  grid-template-columns: minmax(360px, .75fr) minmax(0, 1fr);
  gap: 0;
  margin: 18px 0 22px;
  overflow: hidden;
  border: 1px solid #e1eaf6;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(31, 52, 90, .07);
}

.finance-filter-period-card {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 20px;
  border-right: 1px solid #e1eaf6;
}

.finance-quick-ranges {
  gap: 10px;
  padding: 0;
}

.finance-year-ranges {
  gap: 8px;
  flex-wrap: wrap;
  padding: 0;
}

.finance-year-ranges span {
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.finance-quick-ranges button,
.finance-year-ranges button,
.finance-type-segment button,
.finance-pagination button {
  border: 1px solid #dbe6f5;
  background: #fff;
  color: #344054;
  font-weight: 800;
  transition: color .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.finance-quick-ranges button,
.finance-year-ranges button {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 8px;
}

.finance-quick-ranges button:hover,
.finance-quick-ranges button.active,
.finance-year-ranges button:hover,
.finance-year-ranges button.active,
.finance-type-segment button:hover,
.finance-pagination button:hover {
  color: #2563eb;
  border-color: #bcd0ff;
  background: #f6f9ff;
}

.finance-quick-ranges button.active,
.finance-year-ranges button.active {
  color: #fff;
  border-color: #2563eb;
  background: #2563eb;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .18);
}

.finance-filter-mini-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.finance-filter-mini-stats article {
  min-height: 92px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 22px;
  border-right: 1px solid #e1eaf6;
}

.finance-filter-mini-stats article:last-child {
  border-right: 0;
}

.mini-stat-icon {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 40px;
  border-radius: 10px;
  font-size: 18px;
}

.mini-stat-blue {
  color: #2563eb;
  background: #eef5ff;
}

.mini-stat-green {
  color: #16a34a;
  background: #ecfdf3;
}

.mini-stat-red {
  color: #f04438;
  background: #fff1f2;
}

.mini-stat-purple {
  color: #7c3aed;
  background: #f4ebff;
}

.finance-filter-mini-stats small {
  display: block;
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.finance-filter-mini-stats strong {
  display: block;
  margin-top: 4px;
  color: #101828;
  font-size: 18px;
  line-height: 1.15;
  font-weight: 950;
}

.finance-filter-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  align-items: end;
}

.finance-filter-grid-main {
  grid-template-columns: minmax(280px, 1.3fr) minmax(320px, 1.4fr) repeat(3, minmax(180px, 1fr));
}

.finance-filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
}

.finance-filter-grid label > span {
  color: #344054;
  font-size: 13px;
  font-weight: 800;
}

.finance-filter-grid .form-control,
.finance-filter-grid .form-select {
  height: 48px;
  border-radius: 10px;
  border-color: #dbe6f5;
  color: #1d2939;
  font-weight: 600;
}

.finance-filter-grid .finance-multi-select {
  height: auto;
  min-height: 104px;
}

.finance-type-filter {
  grid-column: span 2;
}

.finance-filter-grid-main .finance-type-filter {
  grid-column: span 1;
}

.finance-type-segment {
  min-height: 48px;
  border: 1px solid #dbe6f5;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.finance-type-segment button {
  flex: 1;
  min-width: 72px;
  min-height: 48px;
  border-width: 0 1px 0 0;
  border-radius: 0;
}

.finance-type-segment button:last-child {
  border-right: 0;
}

.finance-type-segment button.active,
.finance-pagination button.active {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #10b7d4);
  border-color: transparent;
  box-shadow: 0 10px 22px rgba(37, 99, 235, .22);
}

.finance-keyword {
  position: relative;
}

.finance-keyword .form-control {
  padding-right: 38px;
}

.finance-keyword i {
  position: absolute;
  right: 13px;
  bottom: 15px;
  color: #98a2b3;
}

.finance-date-range-box,
.finance-amount-range-box {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  background: #fff;
  border: 1px solid #dbe6f5;
  border-radius: 10px;
}

.finance-date-range-box .form-control,
.finance-amount-range-box .form-control {
  height: 44px;
  padding-left: 0;
  padding-right: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}

.finance-date-range-box b,
.finance-amount-range-box b {
  color: #98a2b3;
  font-weight: 800;
}

.finance-more-filters {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height .3s ease, opacity .22s ease, padding .22s ease;
}

.finance-more-filters.open {
  max-height: 520px;
  opacity: 1;
  margin-top: 18px;
  padding: 20px;
  border: 1px solid #dceafe;
  border-radius: 12px;
  background: linear-gradient(180deg, #f5f9ff, #ffffff);
}

.finance-more-toggle {
  margin-top: 16px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #2563eb;
  font-weight: 900;
}

.finance-more-toggle i {
  margin-left: 4px;
}

.finance-table-panel {
  padding: 18px 22px 20px;
}

.finance-table-head {
  justify-content: space-between;
  margin-bottom: 14px;
}

.finance-table-head span {
  color: #667085;
  font-size: 13px;
  font-weight: 700;
}

.finance-ledger-table {
  overflow: hidden;
  border: 1px solid #dbe6f5;
  border-radius: 12px;
}

.finance-ledger-table thead th {
  height: 52px;
  padding: 0 14px;
  color: #475467;
  background: linear-gradient(180deg, #fbfdff, #f4f8fd);
  font-size: 14px;
  font-weight: 900;
  white-space: nowrap;
}

.finance-ledger-table tbody td {
  min-height: 60px;
  padding: 14px;
  vertical-align: middle;
  border-color: #eef2f7;
  color: #1f2937;
  font-size: 14px;
}

.finance-ledger-table tbody tr {
  transition: background .18s ease, box-shadow .18s ease;
}

.finance-ledger-table tbody tr:hover {
  background: linear-gradient(90deg, rgba(239, 246, 255, .72), rgba(255, 255, 255, .95));
}

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

.ledger-book-card {
  min-height: 226px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 18px;
  border: 1px solid #dbe6f5;
  border-radius: 8px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 18px 44px rgba(24, 47, 92, .08);
}

.ledger-book-main {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  color: inherit;
  text-decoration: none;
}

.ledger-book-main:hover h3 {
  color: #2563eb;
}

.ledger-book-cover {
  width: 66px;
  height: 82px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #2563eb;
  background:
    linear-gradient(145deg, rgba(239, 246, 255, .98), rgba(255, 255, 255, .94)),
    linear-gradient(135deg, rgba(37, 99, 235, .16), rgba(14, 165, 233, .12));
  border: 1px solid #cfe0ff;
  font-size: 28px;
}

.ledger-book-copy {
  min-width: 0;
}

.ledger-book-copy h3 {
  margin: 4px 0 6px;
  color: #101828;
  font-size: 20px;
  font-weight: 900;
  transition: color .18s ease;
}

.ledger-book-copy span,
.ledger-book-copy p,
.ledger-section-head p {
  color: #667085;
  font-size: 13px;
}

.ledger-book-copy p {
  margin: 8px 0 0;
}

.ledger-book-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.ledger-book-stats div {
  min-width: 0;
  padding: 10px;
  border-radius: 8px;
  background: #f7faff;
  border: 1px solid #e5edf8;
}

.ledger-book-stats span {
  display: block;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.ledger-book-stats strong {
  display: block;
  margin-top: 4px;
  color: #101828;
  font-size: 14px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.ledger-book-actions,
.ledger-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ledger-book-actions {
  flex-wrap: wrap;
  margin-top: auto;
}

.ledger-book-actions form {
  margin: 0;
}

.ledger-section-head {
  margin-bottom: 14px;
}

.ledger-section-head h3 {
  margin: 0;
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.ledger-section-head p {
  margin: 5px 0 0;
}

.ledger-empty-panel {
  grid-column: 1 / -1;
}

.finance-type-badge,
.finance-direction {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.finance-type-income {
  color: #12803c;
  background: #ecfdf3;
}

.finance-type-expense {
  color: #dc2626;
  background: #fff1f2;
}

.finance-type-transfer {
  color: #2563eb;
  background: #eef5ff;
}

.finance-type-internal {
  color: #7c3aed;
  background: #f5f3ff;
}

.finance-direction-in {
  color: #16a34a;
}

.finance-direction-out {
  color: #ef4444;
}

.finance-direction-transfer {
  color: #2563eb;
}

.finance-money {
  font-weight: 950;
  white-space: nowrap;
}

.finance-money-income {
  color: #16a34a;
}

.finance-money-expense {
  color: #ef4444;
}

.finance-money-transfer {
  color: #2563eb;
}

.finance-remark-cell {
  max-width: 260px;
}

.finance-remark-cell span,
.finance-remark-cell small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.finance-remark-cell small {
  margin-top: 3px;
  color: #98a2b3;
  font-size: 12px;
}

.finance-pagination {
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #eef2f7;
}

.finance-pagination-total {
  margin-right: auto;
  color: #475467;
  font-weight: 800;
}

.finance-pagination .form-select {
  width: 112px;
  height: 36px;
  border-radius: 9px;
}

.finance-pagination button {
  min-width: 42px;
  height: 36px;
  padding: 0 12px;
  border-radius: 9px;
}

.finance-page-buttons {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.finance-page-ratio {
  min-width: 64px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 1px solid #dbe6f5;
  border-radius: 9px;
  color: #344054;
  background: #fff;
  font-weight: 900;
}

.finance-jump {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: #475467;
  font-weight: 800;
}

.finance-jump input {
  width: 64px;
  height: 36px;
  border: 1px solid #dbe6f5;
  border-radius: 9px;
  text-align: center;
}

.finance-empty-state {
  min-height: 230px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #667085;
  text-align: center;
}

.finance-empty-state span {
  width: 82px;
  height: 82px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  color: #2563eb;
  background: linear-gradient(135deg, #eef5ff, #ffffff);
  font-size: 36px;
}

.finance-empty-state strong {
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.finance-empty-state p {
  margin: 0;
}

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

.finance-detail-grid div {
  min-height: 76px;
  padding: 14px 16px;
  border: 1px solid #e6edf7;
  border-radius: 12px;
  background: linear-gradient(180deg, #fbfdff, #ffffff);
}

.finance-detail-grid span {
  display: block;
  color: #667085;
  font-size: 12px;
  font-weight: 800;
}

.finance-detail-grid strong {
  display: block;
  margin-top: 8px;
  color: #101828;
  font-size: 15px;
  word-break: break-all;
}

.finance-detail-full {
  grid-column: 1 / -1;
}

@media (max-width: 1280px) {
  .finance-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .finance-filter-dashboard {
    grid-template-columns: 1fr;
  }

  .finance-filter-period-card {
    border-right: 0;
    border-bottom: 1px solid #e1eaf6;
  }

  .finance-filter-mini-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

  .finance-type-filter {
    grid-column: span 2;
  }
}

@media (max-width: 768px) {
  .finance-hero,
  .finance-filter-title,
  .recycle-hero,
  .recycle-section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .finance-filter-panel {
    padding: 18px;
  }

  .finance-stat-grid,
  .recycle-stat-grid,
  .finance-filter-grid,
  .finance-detail-grid,
  .ledger-book-grid,
  .ledger-book-stats,
  .finance-filter-mini-stats {
    grid-template-columns: 1fr;
  }

  .recycle-hero,
  .recycle-section {
    padding: 18px;
  }

  .finance-filter-mini-stats article,
  .finance-filter-period-card {
    border-right: 0;
  }

  .finance-filter-mini-stats article {
    border-bottom: 1px solid #e1eaf6;
  }

  .finance-date-range-box,
  .finance-amount-range-box {
    align-items: stretch;
    flex-direction: column;
    gap: 4px;
    padding: 8px 12px;
  }

  .finance-hero-actions {
    width: 100%;
    justify-content: stretch;
    flex-direction: column;
  }

  .finance-hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .ledger-book-actions .btn,
  .ledger-book-actions form {
    width: 100%;
  }

  .finance-type-filter {
    grid-column: span 1;
  }

  .finance-type-segment {
    flex-wrap: wrap;
  }

  .finance-type-segment button {
    min-width: 33.333%;
  }
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.status-pill i {
  font-size: 8px;
}

.status-on {
  color: #12803c;
  background: #ecfdf3;
  border: 1px solid #b7ebc6;
}

.status-off {
  color: #667085;
  background: #f2f4f7;
  border: 1px solid #e4e7ec;
}

.payroll-hero {
  min-height: 140px;
}

.payroll-workbench {
  padding: 26px 28px;
  border-radius: 14px;
}

.payroll-workbench-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e6edf7;
}

.payroll-tabs,
.payroll-actions,
.payroll-filter-bar,
.payroll-filter-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.payroll-tab {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: #1f2937;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.payroll-tab i {
  color: #344054;
}

.payroll-tab.active {
  color: #2563eb;
  border-color: #bcd0ff;
  background: linear-gradient(180deg, #f8fbff, #eef5ff);
  box-shadow: 0 8px 18px rgba(37, 99, 235, .12);
}

.payroll-tab.active i {
  color: #2563eb;
}

.payroll-filter-bar {
  padding: 22px 4px 18px;
  justify-content: space-between;
}

.payroll-filter-bar label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #344054;
  font-weight: 700;
  white-space: nowrap;
}

.payroll-filter-bar .form-control,
.payroll-filter-bar .form-select {
  min-width: 170px;
  height: 40px;
  border-radius: 8px;
}

.payroll-keyword span {
  position: relative;
}

.payroll-keyword .form-control {
  min-width: 280px;
  padding-right: 40px;
}

.payroll-keyword i {
  position: absolute;
  right: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: #667085;
}

.payroll-pane {
  display: none;
}

.payroll-pane.active {
  display: block;
}

.payroll-table-wrap {
  border: 1px solid #e6edf7;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.payroll-table {
  margin-bottom: 0;
}

.payroll-table thead th {
  height: 46px;
  color: #344054;
  background: linear-gradient(180deg, #f9fbff, #f2f6fb);
  font-weight: 800;
}

.payroll-table tbody td {
  height: 70px;
  vertical-align: middle;
  color: #344054;
}

.payroll-employee {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.payroll-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #2563eb;
  font-weight: 800;
  background: linear-gradient(135deg, #e8f1ff, #ffffff);
  border: 1px solid #dbeafe;
}

.payroll-employee strong,
.payroll-employee small {
  display: block;
}

.payroll-employee small {
  color: #64748b;
  margin-top: 2px;
}

.payroll-total {
  color: #172033;
  font-weight: 900;
}

.salary-account-field {
  padding: 14px;
  border: 1px solid #d7e3f8;
  border-radius: 10px;
  background: #f8fbff;
}

.salary-account-search {
  margin-bottom: 10px;
}

.salary-account-preview {
  margin-top: 10px;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: #344054;
}

.salary-account-name {
  font-weight: 800;
  color: #172033;
}

.salary-account-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  color: #2563eb;
  background: #eef5ff;
  border: 1px solid #cfe0ff;
  font-size: 12px;
  font-weight: 800;
}

.salary-account-balance {
  margin-left: auto;
  font-weight: 800;
  color: #16a34a;
}

.salary-account-preview.is-danger .salary-account-balance,
.salary-account-preview.is-danger .salary-account-name {
  color: #dc2626;
}

.salary-account-warning {
  display: none;
  margin-top: 8px;
  color: #dc2626;
  font-weight: 700;
  font-size: 13px;
}

.salary-account-warning.show {
  display: block;
}

.salary-auto-calc [data-salary-submit]:disabled,
.payment-account-form [data-payment-submit]:disabled {
  cursor: not-allowed;
  opacity: .58;
}

.payroll-row-actions .btn-link {
  padding: 0 5px;
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

.payroll-row-actions .btn-link:hover {
  color: #06b6d4;
}

.log-page-head,
.log-title,
.log-filter-card {
  display: flex;
  align-items: center;
  gap: 14px;
}

.log-page-head {
  justify-content: space-between;
  border-radius: 12px;
}

.log-title-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #6366f1;
  background: #eef2ff;
  font-size: 20px;
}

.log-count-badge {
  padding: 7px 12px;
  border-radius: 999px;
  color: #64748b;
  background: #f1f5f9;
  font-weight: 700;
}

.log-filter-card {
  flex-wrap: wrap;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .05);
}

.log-filter-card .form-control,
.log-filter-card .form-select {
  width: auto;
  min-width: 180px;
  height: 40px;
  border-radius: 8px;
}

.log-filter-card [data-log-search] {
  min-width: 260px;
}

.recycle-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 24px 28px;
}

.recycle-hero-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  flex: 0 0 58px;
  border-radius: 14px;
  color: #2563eb;
  background: #eef5ff;
  box-shadow: inset 0 0 0 1px #d9e7ff;
  font-size: 26px;
}

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

.recycle-stat-card {
  min-height: 110px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 24px;
  border: 1px solid #dfe9f7;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 38px rgba(31, 52, 90, .07);
}

.recycle-stat-card span {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  flex: 0 0 46px;
  border-radius: 12px;
  color: #2563eb;
  background: #eef5ff;
  font-size: 20px;
}

.recycle-stat-card small {
  display: block;
  color: #667085;
  font-weight: 800;
}

.recycle-stat-card strong {
  display: block;
  margin-top: 4px;
  color: #101828;
  font-size: 26px;
  font-weight: 950;
}

.recycle-section {
  padding: 20px 22px;
}

.recycle-section + .recycle-section {
  margin-top: 18px;
}

.recycle-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.recycle-section-head h3 {
  margin: 0;
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.recycle-section-head h3 i {
  margin-right: 8px;
  color: #2563eb;
}

.recycle-section-head span {
  color: #667085;
  font-size: 13px;
  font-weight: 800;
}

.recycle-table {
  margin-bottom: 0;
}

.recycle-table thead th {
  color: #475467;
  background: #f7faff;
  font-weight: 900;
}

.recycle-table td,
.recycle-table th {
  vertical-align: middle;
  white-space: nowrap;
}

.recycle-table td:last-child {
  white-space: normal;
  min-width: 160px;
}

@media (max-width: 1280px) {
  .recycle-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .recycle-hero,
  .recycle-section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .recycle-stat-grid {
    grid-template-columns: 1fr;
  }

  .recycle-hero,
  .recycle-section {
    padding: 18px;
  }
}

.log-table-card {
  padding: 0;
  border-radius: 12px;
  overflow: hidden;
}

.log-table {
  margin-bottom: 0;
}

.log-table thead th {
  height: 56px;
  color: #344054;
  background: #f8fafc;
  font-weight: 800;
}

.log-table tbody td {
  height: 54px;
  vertical-align: middle;
}

.log-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.log-badge-role {
  color: #64748b;
  background: #eef2f7;
}

.log-badge-action {
  color: #2563eb;
  background: #eaf2ff;
}

.log-badge-target {
  color: #6366f1;
  background: #eef2ff;
}

.log-detail {
  max-width: 360px;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.payroll-hero::before,
.project-hero::before,
.customer-hero::before {
  content: "";
  position: absolute;
  right: 34px;
  bottom: 18px;
  width: 150px;
  height: 86px;
  opacity: .36;
  background:
    linear-gradient(90deg, rgba(37, 99, 235, .14), rgba(37, 99, 235, .04)),
    repeating-linear-gradient(90deg, transparent 0 22px, rgba(37, 99, 235, .16) 22px 28px, transparent 28px 42px);
  clip-path: polygon(0 78%, 14% 58%, 25% 66%, 40% 26%, 54% 44%, 70% 12%, 86% 42%, 100% 22%, 100% 100%, 0 100%);
}

.record-card {
  position: relative;
  overflow: hidden;
  border-color: rgba(226, 232, 240, .92);
}

.record-card .section-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.record-card .section-title i {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: inline-grid;
  place-items: center;
  background: #eef4ff;
  color: #2563eb;
}

.record-card-success .section-title i { color: #10b981; background: #ecfdf5; }
.record-card-purple .section-title i { color: #8b5cf6; background: #f3efff; }
.record-card-warning .section-title i { color: #f59e0b; background: #fff7e8; }

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  padding: 48px 24px;
  background:
    radial-gradient(circle at 3% 30%, rgba(37, 99, 235, .17), transparent 31%),
    radial-gradient(circle at 93% 12%, rgba(6, 182, 212, .16), transparent 27%),
    linear-gradient(135deg, #f8fbff 0%, #e9f3ff 100%);
}

.login-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.login-orbit {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, .82);
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .08);
}

.login-orbit-one {
  width: 560px;
  height: 560px;
  left: -175px;
  top: 70px;
}

.login-orbit-two {
  width: 390px;
  height: 390px;
  right: -135px;
  top: -115px;
}

.login-dots {
  position: absolute;
  width: 220px;
  height: 112px;
  right: 8%;
  top: 2%;
  opacity: .58;
  background-image: radial-gradient(#fff 1.5px, transparent 1.5px);
  background-size: 16px 16px;
}

.login-city {
  position: absolute;
  right: 3%;
  bottom: 8%;
  width: 250px;
  height: 190px;
  opacity: .23;
  background:
    linear-gradient(180deg, transparent 8%, rgba(37, 99, 235, .18) 8% 100%) 0 74px / 44px 116px no-repeat,
    linear-gradient(180deg, transparent 0, rgba(37, 99, 235, .18) 0 100%) 64px 22px / 50px 168px no-repeat,
    linear-gradient(180deg, transparent 0, rgba(37, 99, 235, .18) 0 100%) 138px 58px / 42px 132px no-repeat,
    linear-gradient(180deg, transparent 0, rgba(37, 99, 235, .18) 0 100%) 200px 92px / 38px 98px no-repeat;
}

.login-card {
  width: min(1120px, calc(100vw - 96px));
  min-height: 700px;
  display: grid;
  grid-template-columns: 1.08fr .92fr;
  grid-template-rows: 1fr auto;
  position: relative;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, .92);
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 34px 96px rgba(37, 99, 235, .18);
  backdrop-filter: blur(18px);
}

.login-brand-panel,
.login-form-panel {
  padding: 72px 70px 56px;
}

.login-brand-panel {
  position: relative;
  overflow: hidden;
  text-align: center;
  background:
    linear-gradient(145deg, rgba(250, 253, 255, .84), rgba(229, 242, 255, .78)),
    radial-gradient(circle at 12% 82%, rgba(37, 99, 235, .10), transparent 42%);
}

.login-brand-panel::before,
.login-brand-panel::after {
  content: "";
  position: absolute;
  inset: auto -16% 52px -10%;
  height: 180px;
  border-radius: 50%;
  border-top: 1px solid rgba(255, 255, 255, .9);
  transform: rotate(-7deg);
  opacity: .72;
}

.login-brand-panel::after {
  inset: auto -18% 12px -12%;
  border-top-color: rgba(147, 197, 253, .22);
  transform: rotate(-10deg);
}

.login-illustration {
  height: 220px;
  position: relative;
  z-index: 1;
  margin-bottom: 18px;
}

.chart-window {
  position: absolute;
  left: 50%;
  top: 16px;
  width: 300px;
  height: 152px;
  transform: translateX(-50%) skewY(-8deg);
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(255,255,255,.96), rgba(222,238,255,.94));
  box-shadow: 0 22px 42px rgba(37, 99, 235, .18);
  border: 1px solid rgba(37, 99, 235, .10);
}

.window-bar {
  height: 30px;
  display: flex;
  gap: 8px;
  align-items: center;
  padding-left: 14px;
  background: linear-gradient(90deg, #2f7cf6, #9dcaff);
  border-radius: 10px 10px 0 0;
}

.window-bar span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
}

.chart-line {
  position: absolute;
  left: 50px;
  top: 76px;
  width: 144px;
  height: 50px;
  border-left: 4px solid #3b82f6;
  border-bottom: 4px solid #3b82f6;
  transform: skewY(-15deg);
  opacity: .82;
}

.chart-bars {
  position: absolute;
  left: 64px;
  bottom: 17px;
  display: flex;
  gap: 12px;
  align-items: end;
}

.chart-bars span {
  width: 21px;
  display: block;
  border-radius: 5px 5px 0 0;
  background: linear-gradient(180deg, #67b0ff, #2563eb);
}

.chart-bars span:nth-child(1) { height: 34px; }
.chart-bars span:nth-child(2) { height: 50px; }
.chart-bars span:nth-child(3) { height: 72px; }
.chart-bars span:nth-child(4) { height: 96px; }

.chart-pie {
  position: absolute;
  right: 34px;
  top: 55px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: conic-gradient(#2563eb 0 28%, #93c5fd 28% 100%);
  box-shadow: 0 14px 24px rgba(37,99,235,.18);
}

.coin-stack,
.calculator-grid {
  position: absolute;
  bottom: 14px;
  border-radius: 10px;
  background: linear-gradient(180deg, #dbeafe, #93c5fd);
  box-shadow: 0 13px 28px rgba(37,99,235,.15);
}

.coin-stack-one {
  right: 104px;
  width: 60px;
  height: 76px;
}

.coin-stack-two {
  right: 54px;
  width: 54px;
  height: 48px;
}

.calculator-grid {
  left: 104px;
  width: 126px;
  height: 54px;
  opacity: .70;
  background:
    repeating-linear-gradient(90deg, rgba(37,99,235,.18) 0 13px, transparent 13px 24px),
    repeating-linear-gradient(0deg, rgba(37,99,235,.12) 0 10px, transparent 10px 20px),
    #f8fbff;
}

.login-logo {
  width: 78px;
  height: 78px;
  margin: 0 auto 22px;
  border-radius: 50%;
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 36px;
  background: linear-gradient(135deg, #2563eb, #60a5fa);
  box-shadow: 0 20px 38px rgba(37, 99, 235, .24);
}

.login-brand-panel h1 {
  position: relative;
  z-index: 1;
  color: #10233f;
  font-size: 36px;
  font-weight: 800;
  letter-spacing: 0;
}

.login-brand-panel p {
  position: relative;
  z-index: 1;
  margin: 14px 0 24px;
  color: #60718b;
  font-size: 20px;
  font-weight: 500;
}

.login-mini-line {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 58px;
}

.login-mini-line span {
  height: 5px;
  border-radius: 999px;
  background: #2563eb;
}

.login-mini-line span:first-child { width: 28px; }
.login-mini-line span:last-child {
  width: 42px;
  background: #d9e7ff;
}

.login-assurance {
  position: relative;
  z-index: 1;
  color: #70809b;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 700;
}

.login-assurance i {
  color: #86a2cc;
  font-size: 25px;
}

.login-form-panel {
  background: rgba(255, 255, 255, .98);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.login-welcome {
  width: 100%;
  max-width: 390px;
  margin: 0 auto 28px;
  text-align: center;
}

.login-bubbles {
  height: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.login-bubbles span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #bfdbfe;
  box-shadow: 0 0 18px rgba(37, 99, 235, .26);
}

.login-bubbles span:nth-child(2),
.login-bubbles span:nth-child(3) {
  width: 14px;
  height: 14px;
  background: #93c5fd;
}

.login-welcome h2 {
  margin: 0;
  color: #10233f;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0;
}

.login-welcome p {
  margin: 12px 0 0;
  color: #72829a;
  font-size: 15px;
}

.login-form {
  width: min(390px, 100%);
  margin: 0 auto;
}

.login-form .mb-4 {
  margin-bottom: 20px !important;
}

.login-form .form-label {
  margin-bottom: 9px;
  color: #253957;
  font-weight: 600;
}

.login-input {
  position: relative;
}

.login-input > i {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #7b8aa1;
  font-size: 19px;
  z-index: 2;
}

.login-input .form-control {
  min-height: 58px;
  padding-left: 56px;
  padding-right: 54px;
  font-size: 16px;
  border-radius: 7px;
  border-color: #d6e1f1;
  color: #15233b;
  background: #fff;
  box-shadow: inset 0 1px 1px rgba(15, 23, 42, .02);
}

.login-input .form-control:focus {
  border-color: #7fb0ff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .10);
}

.login-password-toggle {
  position: absolute;
  right: 13px;
  top: 50%;
  width: 36px;
  height: 36px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #7b8aa1;
  display: grid;
  place-items: center;
  transition: background-color .2s ease, color .2s ease;
}

.login-password-toggle:hover {
  color: #2563eb;
  background: #eef5ff;
}

.login-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: -4px 0 18px;
  color: #667085;
  font-size: 14px;
}

.login-remember {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  cursor: pointer;
}

.login-remember input {
  width: 16px;
  height: 16px;
  border-color: #cbd5e1;
}

.login-options a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 600;
}

.login-options a:hover {
  color: #0ea5e9;
}

.login-submit {
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 7px;
  font-size: 18px;
  font-weight: 800;
  background: linear-gradient(100deg, #2468f2, #08afd0);
  box-shadow: 0 16px 30px rgba(37, 99, 235, .23);
}

.login-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(37, 99, 235, .28);
}

.login-alt {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 26px 0 16px;
  color: #677893;
}

.login-alt span {
  flex: 1;
  height: 1px;
  background: #dbe5f2;
}

.login-alt em {
  font-style: normal;
  white-space: nowrap;
  font-size: 14px;
}

.login-sso {
  display: grid;
  justify-items: center;
  gap: 8px;
  width: 100%;
  border: 0;
  background: transparent;
  color: #4f6078;
}

.login-sso span {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #2563eb;
  font-size: 24px;
  background: linear-gradient(180deg, #eaf3ff, #d9eafe);
  box-shadow: 0 10px 22px rgba(37, 99, 235, .12);
}

.login-sso strong {
  font-size: 14px;
  font-weight: 600;
}

.login-helper,
.login-copyright {
  color: #7a879a;
  margin-top: 20px;
  font-weight: 600;
}

.login-copyright {
  margin-top: 14px;
  font-size: 13px;
  font-weight: 500;
}

.login-card-footer {
  grid-column: 1 / -1;
  min-height: 76px;
  padding: 16px 28px 18px;
  text-align: center;
  color: #71829b;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.7;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-top: 1px solid rgba(148, 163, 184, .28);
  background: linear-gradient(90deg, rgba(247, 251, 255, .86), rgba(255, 255, 255, .92));
}

.login-version-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #64748b;
}

.login-version-row span:first-child,
.login-browser-tip span {
  color: #4f46e5;
  font-weight: 500;
}

.login-browser-tip {
  color: #8a94a6;
}

.report-chart-grid {
  margin-bottom: 14px;
}

.report-card {
  padding: 22px;
  overflow: hidden;
}

.report-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  color: #1f2937;
  font-weight: 800;
  font-size: 16px;
}

.report-card-title > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.report-card-title i {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: inline-grid;
  place-items: center;
  background: #eef4ff;
}

.report-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.report-summary-item {
  min-height: 78px;
  border: 1px solid #edf2f8;
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  background: linear-gradient(135deg, #fff, #fbfdff);
}

.report-summary-item i {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #fff;
}

.report-summary-item span {
  display: block;
  color: #667085;
  font-size: 13px;
}

.report-summary-item strong {
  display: block;
  margin-top: 2px;
  color: #1f2937;
  font-size: 17px;
}

.report-summary-income i { background: #2563eb; }
.report-summary-expense i { background: #22c55e; }
.report-summary-transfer-in i { background: #4f7cff; }
.report-summary-transfer-out i { background: #65cc72; }

.report-chart-box {
  height: 240px;
}

.report-project-chart {
  height: 230px;
}

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

.report-rank-card {
  min-height: 68px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid #edf2f8;
  border-radius: 8px;
  background: linear-gradient(135deg, #fff, #f7fbff);
}

.report-rank-card > span {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  background: #94a3b8;
}

.report-rank-card strong,
.report-rank-card small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.report-rank-card small {
  margin-top: 2px;
  color: #1f2937;
  font-weight: 800;
}

.report-rank-card.rank-1 > span { background: #fbbf24; }
.report-rank-card.rank-2 > span { background: #94a3b8; }
.report-rank-card.rank-3 > span { background: #f59e72; }

.report-table thead th {
  color: #53627a;
  font-weight: 800;
}

.report-mini-card {
  min-height: 214px;
}

.report-blue .report-card-title i { background: #eef4ff; }
.report-green .report-card-title i { background: #ecfdf5; }
.report-orange .report-card-title i { background: #fff7e8; }

.report-dashboard {
  display: grid;
  gap: 18px;
}

.report-analysis-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px;
}

.report-analysis-tab {
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid #e3ecf8;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #53627a;
  background: #f8fbff;
  text-decoration: none;
  font-weight: 800;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}

.report-analysis-tab i {
  color: #98a2b3;
}

.report-analysis-tab:hover,
.report-analysis-tab.active {
  color: #2563eb;
  border-color: rgba(37, 99, 235, .24);
  background: linear-gradient(135deg, rgba(37, 99, 235, .12), rgba(37, 99, 235, .04));
}

.report-analysis-tab:hover i,
.report-analysis-tab.active i {
  color: #2563eb;
}

.report-summary-grid-compact {
  grid-template-columns: minmax(220px, 320px);
}

.report-summary-profit i {
  background: #2563eb;
}

.report-chart-box-tall {
  height: 320px;
}

.report-card-v2 {
  padding: 22px 24px;
  border: 1px solid rgba(216, 228, 246, .92);
  border-radius: 8px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 16px 36px rgba(36, 63, 108, .08);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.report-card-v2:hover {
  transform: translateY(-2px);
  border-color: rgba(188, 208, 255, .9);
  box-shadow: 0 22px 46px rgba(36, 63, 108, .11);
}

.report-card-v2 .report-card-title {
  margin-bottom: 18px;
}

.report-card-v2 .report-card-title > div {
  color: #172033;
  font-size: 17px;
  font-weight: 900;
}

.report-card-v2 .report-card-title i {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  font-size: 16px;
}

.report-card-v2 .report-summary-grid {
  gap: 18px;
  margin-bottom: 20px;
}

.report-card-v2 .report-summary-item {
  min-height: 76px;
  border: 1px solid #dfe8f6;
  border-radius: 8px;
  background: linear-gradient(135deg, #ffffff, #f8fbff);
  box-shadow: 0 10px 24px rgba(15, 23, 42, .035);
}

.report-card-v2 .report-summary-item i {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  font-size: 19px;
  box-shadow: 0 10px 22px rgba(37, 99, 235, .20);
}

.report-card-v2 .report-summary-item span {
  color: #667085;
  font-size: 14px;
  font-weight: 700;
}

.report-card-v2 .report-summary-item strong {
  color: #101828;
  font-size: 18px;
  font-weight: 900;
}

.report-card-v2 .report-chart-box {
  height: 270px;
}

.report-rank-panel {
  padding-bottom: 16px;
}

.report-table-v2 {
  margin-bottom: 0;
  border: 1px solid #dfe8f6;
  border-radius: 8px;
  overflow: hidden;
}

.report-table-v2 thead th {
  height: 42px;
  padding: 0 14px;
  color: #344054;
  background: linear-gradient(180deg, #f8fbff, #f1f6fd);
  border-bottom: 1px solid #dfe8f6;
  font-size: 14px;
  font-weight: 900;
}

.report-table-v2 tbody td {
  height: 48px;
  padding: 0 14px;
  color: #344054;
  border-bottom: 1px solid #edf2f8;
  vertical-align: middle;
}

.report-table-v2 tbody tr:hover td {
  background: #f8fbff;
}

.report-mini-card {
  min-height: 246px;
}

.report-empty-state {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #8a97ab;
}

.report-empty-art {
  width: 92px;
  height: 76px;
  display: grid;
  place-items: center;
  color: #4f8cff;
  background:
    radial-gradient(circle at 68% 18%, rgba(37, 99, 235, .16), transparent 16px),
    linear-gradient(135deg, #edf5ff, #ffffff);
  border-radius: 24px 24px 16px 16px;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, .07);
}

.report-empty-art i {
  font-size: 38px;
}

.report-empty-state strong {
  color: #172033;
  font-size: 16px;
  font-weight: 900;
}

.report-empty-state span {
  color: #8a97ab;
  font-size: 13px;
}

.report-direction-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid #dfe8f6;
  background: #f8fbff;
  color: #475467;
}

.report-direction-pill.is-in {
  color: #16a34a;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.report-direction-pill.is-out {
  color: #2563eb;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.chart-tip-title {
  margin-bottom: 8px;
  font-weight: 900;
}

.chart-tip-row {
  min-width: 150px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  line-height: 1.9;
}

.chart-tip-row span,
.chart-tip-row strong {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

@media (max-width: 860px) {
  .app-shell {
    display: block;
  }

  .sidebar {
    width: 100%;
    height: auto;
    position: static;
    overflow: visible;
  }

  .sidebar-nav {
    overflow: visible;
  }

  .sidebar a {
    display: flex;
  }

  .topbar {
    height: auto;
    align-items: flex-start;
    flex-direction: column;
    padding: 16px;
  }

  .topbar form {
    margin-top: 10px;
  }

  .content {
    padding: 18px 14px 28px;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .role-auth-top,
  .permission-toolbar,
  .permission-page-toolbar,
  .payroll-workbench-head,
  .log-page-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .permission-page-nav {
    width: 100%;
  }

  .permission-page-nav a {
    flex: 1;
    padding: 0 10px;
  }

  .role-permission-grid {
    grid-template-columns: 1fr;
  }

  .permission-search,
  .permission-search .form-control,
  .payroll-filter-bar label,
  .payroll-filter-bar .form-control,
  .payroll-filter-bar .form-select,
  .payroll-keyword span,
  .payroll-keyword .form-control,
  .log-filter-card .form-control,
  .log-filter-card .form-select {
    width: 100%;
    min-width: 0;
  }

  .toolbar-card,
  .feature-hero {
    align-items: flex-start;
    flex-direction: column;
    padding: 20px;
  }

  .customer-toolbar-actions,
  .staff-toolbar-actions,
  .staff-filter-bar,
  .staff-search .form-control,
  .staff-filter-bar .form-select,
  .staff-date,
  .staff-date .form-control {
    width: 100%;
  }

  .staff-department-popover {
    position: static;
    width: 100%;
    margin-top: 8px;
  }

  .staff-department-popover::before {
    display: none;
  }

  .department-manager-grid {
    grid-template-columns: 1fr;
  }

  .report-summary-grid,
  .report-rank-strip {
    grid-template-columns: 1fr;
  }

  .login-page {
    padding: 22px 12px;
    place-items: start center;
    overflow: auto;
  }

  .login-card {
    grid-template-columns: 1fr;
    width: min(680px, calc(100vw - 24px));
    min-height: auto;
  }

  .login-brand-panel,
  .login-form-panel {
    padding: 30px 22px;
  }

  .login-illustration {
    display: none;
  }

  .login-mini-line {
    margin-bottom: 24px;
  }

  .login-brand-panel h1,
  .login-welcome h2 {
    font-size: 28px;
  }

  .login-brand-panel p {
    font-size: 16px;
  }

  .login-card-footer {
    font-size: 12px;
  }

  .modal-dialog {
    --bs-modal-width: auto;
    margin: 12px;
  }

  .modal-title {
    font-size: 20px;
  }
}
.legacy-ledger-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.legacy-hero,
.legacy-filter-panel,
.legacy-table-panel {
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.06);
}

.legacy-hero {
  min-height: 128px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 28px 32px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.96), rgba(255, 255, 255, 0.98) 54%, rgba(240, 253, 250, 0.8));
}

.legacy-hero-copy {
  display: flex;
  align-items: center;
  gap: 18px;
}

.legacy-hero-icon {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  font-size: 28px;
}

.legacy-hero h2,
.legacy-filter-head h3,
.legacy-table-head h3 {
  margin: 0;
  color: #172033;
  font-weight: 800;
  letter-spacing: 0;
}

.legacy-hero p,
.legacy-filter-head p,
.legacy-table-head p {
  margin: 6px 0 0;
  color: #64748b;
}

.legacy-readonly-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  border-radius: 999px;
  color: #0f766e;
  background: #ccfbf1;
  border: 1px solid #99f6e4;
  font-weight: 800;
}

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

.legacy-stat-card {
  min-height: 96px;
  padding: 20px 22px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #fff;
}

.legacy-stat-card span {
  display: block;
  color: #64748b;
  font-weight: 700;
  margin-bottom: 10px;
}

.legacy-stat-card strong {
  display: block;
  color: #172033;
  font-size: 28px;
  line-height: 1.1;
}

.legacy-stat-income strong,
.legacy-money-income {
  color: #059669;
}

.legacy-stat-expense strong,
.legacy-money-expense {
  color: #ef4444;
}

.legacy-stat-transfer strong,
.legacy-money-transfer {
  color: #2563eb;
}

.legacy-filter-panel {
  padding: 24px 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 251, 255, 0.96));
}

.legacy-filter-head,
.legacy-table-head,
.legacy-filter-actions,
.legacy-pagination {
  display: flex;
  align-items: center;
}

.legacy-filter-head,
.legacy-table-head {
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e2e8f0;
}

.legacy-filter-head h3 i {
  color: #2563eb;
}

.legacy-filter-actions {
  gap: 10px;
  flex-wrap: wrap;
}

.legacy-filter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 18px;
  padding-top: 20px;
}

.legacy-filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  color: #334155;
  font-weight: 800;
}

.legacy-filter-grid .form-control,
.legacy-filter-grid .form-select {
  min-height: 46px;
  border-color: #dbe6f6;
  border-radius: 8px;
  color: #1f2937;
  font-weight: 600;
}

.legacy-combo-input::-webkit-search-cancel-button {
  cursor: pointer;
}

.legacy-filter-keyword {
  grid-column: span 2;
}

.legacy-table-panel {
  padding: 24px 28px;
  background: #fff;
}

.legacy-table-head {
  margin-bottom: 14px;
}

.legacy-table-head > span {
  color: #64748b;
  font-weight: 700;
}

.legacy-ledger-table {
  min-width: 1180px;
}

.legacy-ledger-table thead th {
  background: #f8fafc;
  color: #334155;
  font-weight: 800;
  border-bottom: 1px solid #e2e8f0;
  white-space: nowrap;
}

.legacy-ledger-table tbody td {
  vertical-align: middle;
  color: #1f2937;
  border-bottom: 1px solid #edf2f7;
}

.legacy-ledger-table td small {
  display: block;
  margin-top: 4px;
  color: #64748b;
}

.legacy-type-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-weight: 800;
}

.legacy-type-income {
  color: #047857;
  background: #d1fae5;
}

.legacy-type-expense {
  color: #dc2626;
  background: #fee2e2;
}

.legacy-type-transfer {
  color: #1d4ed8;
  background: #dbeafe;
}

.legacy-money {
  white-space: nowrap;
}

.legacy-account-cell {
  font-weight: 700;
  color: #172033;
}

.legacy-remark-cell {
  max-width: 420px;
  color: #475569;
}

.legacy-pagination {
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.legacy-page-count {
  padding: 8px 10px;
  color: #64748b;
  font-weight: 800;
}

@media (max-width: 1180px) {
  .legacy-stat-grid,
  .legacy-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .legacy-hero,
  .legacy-filter-head,
  .legacy-table-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .legacy-stat-grid,
  .legacy-filter-grid {
    grid-template-columns: 1fr;
  }

  .legacy-filter-keyword {
    grid-column: auto;
  }

  .legacy-filter-panel,
  .legacy-table-panel,
  .legacy-hero {
    padding: 20px;
  }
}

.loan-center-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.loan-hero,
.loan-filter-head,
.loan-table-head,
.loan-hero-copy,
.loan-filter-actions,
.loan-year-chips {
  display: flex;
  align-items: center;
}

.loan-hero {
  justify-content: space-between;
  min-height: 132px;
  padding: 28px 34px;
  overflow: hidden;
  background: linear-gradient(135deg, #ffffff 0%, #f7fbff 58%, #eefdf9 100%);
}

.loan-hero-copy {
  gap: 18px;
}

.loan-hero-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 62px;
  height: 62px;
  border-radius: 8px;
  color: #2563eb;
  background: #eaf2ff;
  border: 1px solid #cfe0ff;
  font-size: 30px;
}

.loan-hero h2 {
  margin: 0 0 6px;
  color: #172033;
  font-size: 30px;
  font-weight: 900;
}

.loan-hero p,
.loan-filter-head p,
.loan-table-head p {
  margin: 0;
  color: #64748b;
  font-size: 15px;
}

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

.loan-stat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 118px;
  padding: 20px;
  border: 1px solid #dde8f6;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(15, 23, 42, .06);
}

.loan-stat-card > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 8px;
  font-size: 22px;
}

.loan-stat-borrow > span {
  color: #2563eb;
  background: #dbeafe;
}

.loan-stat-repay > span {
  color: #059669;
  background: #d1fae5;
}

.loan-stat-balance > span {
  color: #7c3aed;
  background: #ede9fe;
}

.loan-stat-count > span {
  color: #ea580c;
  background: #ffedd5;
}

.loan-stat-card small,
.loan-stat-card em {
  display: block;
  color: #64748b;
  font-style: normal;
  font-weight: 700;
}

.loan-stat-card strong {
  display: block;
  margin: 4px 0;
  color: #172033;
  font-size: 27px;
  line-height: 1.15;
}

.loan-filter-panel,
.loan-table-panel {
  padding: 26px 30px;
}

.loan-filter-head,
.loan-table-head {
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e5edf8;
}

.loan-filter-head h3,
.loan-table-head h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  color: #172033;
  font-size: 24px;
  font-weight: 900;
}

.loan-filter-head h3 i {
  color: #2563eb;
}

.loan-filter-actions {
  gap: 10px;
}

.loan-year-chips {
  gap: 10px;
  flex-wrap: wrap;
  padding: 18px 0 4px;
}

.loan-year-chips a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 66px;
  height: 38px;
  padding: 0 14px;
  border: 1px solid #d9e5f5;
  border-radius: 999px;
  color: #334155;
  background: #fff;
  font-weight: 800;
  text-decoration: none;
}

.loan-year-chips a:hover,
.loan-year-chips a.active {
  color: #fff;
  border-color: #2563eb;
  background: linear-gradient(135deg, #2563eb, #10b3d6);
  box-shadow: 0 12px 24px rgba(37, 99, 235, .2);
}

.loan-filter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  padding-top: 14px;
}

.loan-filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: #334155;
  font-weight: 800;
}

.loan-filter-grid .form-control,
.loan-filter-grid .form-select {
  height: 44px;
  border-color: #d9e5f5;
  border-radius: 8px;
  font-weight: 700;
}

.loan-filter-keyword {
  grid-column: span 2;
}

.loan-table-head > span {
  color: #64748b;
  font-weight: 800;
}

.loan-pair-table,
.loan-detail-table {
  margin: 18px 0 0;
}

.loan-pair-table thead th,
.loan-detail-table thead th {
  padding: 14px 12px;
  color: #334155;
  background: #f8fbff;
  border-bottom: 1px solid #dfe8f4;
  font-weight: 900;
  white-space: nowrap;
}

.loan-pair-table tbody td,
.loan-detail-table tbody td {
  padding: 15px 12px;
  vertical-align: middle;
  border-bottom: 1px solid #edf2f7;
}

.loan-pair-table tbody tr:hover,
.loan-detail-table tbody tr:hover {
  background: #f8fbff;
}

.loan-pair-table td strong,
.loan-detail-table td strong {
  display: block;
  color: #172033;
  font-weight: 900;
}

.loan-pair-table td small,
.loan-detail-table td small {
  display: block;
  margin-top: 3px;
  color: #64748b;
  font-weight: 700;
}

.loan-money {
  white-space: nowrap;
}

.loan-money-borrow,
.loan-money-warning {
  color: #2563eb !important;
}

.loan-money-repay,
.loan-money-settled {
  color: #059669 !important;
}

.loan-money-overpaid {
  color: #ea580c !important;
}

.loan-kind {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 54px;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-weight: 900;
}

.loan-kind-borrow {
  color: #1d4ed8;
  background: #dbeafe;
}

.loan-kind-repay {
  color: #047857;
  background: #d1fae5;
}

.loan-balance-label,
.loan-serial {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 8px;
  border-radius: 999px;
  color: #64748b;
  background: #f1f5f9;
  font-weight: 800;
  white-space: nowrap;
}

.loan-balance-label {
  margin-right: 8px;
}

.loan-flow-text {
  color: #172033;
  font-weight: 900;
}

.loan-remark-cell {
  max-width: 420px;
  color: #475569;
}

@media (max-width: 1180px) {
  .loan-stat-grid,
  .loan-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .loan-hero,
  .loan-filter-head,
  .loan-table-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .loan-stat-grid,
  .loan-filter-grid {
    grid-template-columns: 1fr;
  }

  .loan-filter-keyword {
    grid-column: auto;
  }

  .loan-filter-panel,
  .loan-table-panel,
  .loan-hero {
    padding: 20px;
  }
}
