:root {
  --bg: #eef4f2;
  --surface: #ffffff;
  --surface-2: #f7fbfa;
  --surface-3: #edf5f3;
  --line: #d9e7e2;
  --text: #162923;
  --muted: #6b7f78;
  --brand: #0d9488;
  --brand-2: #0f766e;
  --danger: #df4b4b;
  --warning: #d9911e;
  --success: #0f9f6e;
  --shadow: 0 18px 48px rgba(18, 44, 38, 0.08);
  --topbar: #10231f;
  --sidebar: #eef5f2;
  --sidebar-active: #dff7f1;
  --sidebar-hover: #e6f1ee;
  --tab: #f4f8f7;
  --tab-active: #ffffff;
  --accent-gold: #c8872e;
  --ink: #10231f;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: "Alibaba PuHuiTi", "HarmonyOS Sans SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: var(--bg);
}

button,
input,
select {
  font: inherit;
}

body {
  overflow: hidden;
}

html,
body,
#app {
  width: 100%;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Login */
.login-page {
  overflow: auto;
  background:
    radial-gradient(circle at top, rgba(10, 163, 148, 0.28), transparent 32%),
    linear-gradient(145deg, #13222b 0%, #07141b 48%, #0d2730 100%);
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.login-card {
  width: min(100%, 420px);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
  padding: 38px 34px 32px;
}

.login-banner {
  margin: 0 -34px 20px;
  padding: 16px 18px;
  background: linear-gradient(90deg, var(--brand), #12b79f);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
}

.login-notch {
  width: 22px;
  height: 12px;
  margin: -2px 0 24px -34px;
  background: linear-gradient(180deg, #24343d, #0f2128);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 30% 100%);
}

.login-form {
  display: grid;
  gap: 14px;
}

.login-form input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: none;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.login-form input:focus {
  border-color: rgba(10, 163, 148, 0.8);
  box-shadow: 0 0 0 4px rgba(10, 163, 148, 0.12);
}

.login-form button,
.btn-primary {
  height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 6px;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.2s ease;
}

.login-form button:hover,
.btn-primary:hover {
  background: var(--brand-2);
}

.login-form button:active,
.btn-primary:active,
.btn-secondary:active,
.btn-danger:active,
.btn-teal:active,
.btn-ghost:active,
.topbar-icon:active {
  transform: translateY(1px);
}

.form-message {
  min-height: 20px;
  margin: 0;
  color: var(--danger);
  font-size: 14px;
}

.form-message.success {
  color: var(--success);
}

.login-tips {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px dashed var(--line);
  color: var(--muted);
  font-size: 13px;
}

.login-tips p {
  margin: 6px 0;
}

/* App shell */
.app-shell {
  height: 100vh;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  grid-template-rows: 54px minmax(0, 1fr);
  grid-template-areas:
    "topbar topbar"
    "sidebar workspace";
}

.app-shell.sidebar-hidden {
  grid-template-columns: 0 minmax(0, 1fr);
}

.app-shell.sidebar-hidden .sidebar {
  width: 0;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border-right: 0;
  opacity: 0;
  pointer-events: none;
}

.topbar {
  grid-area: topbar;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 16px;
  background: var(--topbar);
  color: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

.topbar-left,
.topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  font-size: 17px;
  font-weight: 700;
}

.brand-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 0 0 4px rgba(10, 163, 148, 0.18);
}

.topbar-icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  cursor: pointer;
}

.svg-icon {
  width: 18px;
  height: 18px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-chip,
.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 260px;
  padding: 0 12px;
  height: 34px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.project-chip {
  flex: 0 1 auto;
  min-width: 0;
}

.sidebar {
  grid-area: sidebar;
  overflow: auto;
  background: var(--sidebar);
  border-right: 1px solid #dde3e7;
  transition: width 0.18s ease, opacity 0.18s ease, padding 0.18s ease;
}

.sidebar-inner {
  padding: 8px 0 16px;
}

.menu-group {
  border-bottom: 1px solid #dfe5ea;
}

.menu-group-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 46px;
  padding: 10px 16px;
  font-size: 14px;
  color: #24323a;
  cursor: pointer;
  user-select: none;
  background: rgba(255, 255, 255, 0.44);
}

.menu-group-title:hover {
  background: var(--sidebar-hover);
}

.menu-group-title .label {
  display: flex;
  align-items: center;
  gap: 10px;
}

.menu-icon {
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #33434d;
  opacity: 0.88;
}

.menu-icon .svg-icon {
  width: 16px;
  height: 16px;
}

.menu-text {
  letter-spacing: 0.01em;
}

.menu-meta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #7c8b95;
  font-size: 12px;
}

.menu-fold {
  color: #80909a;
}

.menu-group-title .indicator {
  color: #7c8b95;
  font-size: 12px;
}

.menu-items {
  display: none;
  background: rgba(255, 255, 255, 0.75);
}

.menu-group.is-open .menu-items {
  display: block;
}

.menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 8px 18px 8px 28px;
  color: #30414a;
  border-top: 1px solid #e8edf1;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.94);
  font-size: 12px;
  line-height: 1.2;
}

.menu-item:hover {
  background: #f7fafb;
}

.menu-item.is-active {
  background: var(--sidebar-active);
  color: #08796d;
  font-weight: 600;
}

.menu-item-arrow {
  display: inline-flex;
  width: 8px;
  color: #8a98a3;
  font-size: 12px;
  line-height: 1;
}

.menu-item.is-active .menu-item-arrow {
  color: #0f9a8a;
}

.menu-item-text {
  flex: 1 1 auto;
  font-size: 12px;
  letter-spacing: 0;
}

.menu-item small {
  color: var(--muted);
  font-weight: 400;
}

.workspace {
  grid-area: workspace;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-width: 0;
  overflow: hidden;
  background: #fff;
}

.tabs-bar {
  display: flex;
  align-items: stretch;
  gap: 1px;
  overflow: auto;
  border-bottom: 1px solid var(--line);
  background: #f0f1f2;
}

.tab {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 110px;
  max-width: 200px;
  padding: 0 14px;
  height: 40px;
  border: 0;
  background: var(--tab);
  color: #2e3c44;
  cursor: pointer;
  white-space: nowrap;
}

.tab.is-active {
  background: var(--tab-active);
  color: #0b786d;
  border-bottom: 2px solid var(--brand);
}

.tab .close {
  margin-left: auto;
  color: #8b9aa3;
  font-weight: 700;
}

.workspace-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 16px 7px;
  border-bottom: 1px solid #edf1f4;
  background: #fff;
}

.breadcrumbs {
  color: #87939b;
  font-size: 13px;
  margin-bottom: 6px;
}
.workspace-head > .title-block {
  min-width: 0;
  display: grid;
  grid-template-columns: max-content max-content;
  align-items: end;
  column-gap: clamp(36px, 6vw, 120px);
}

.workspace-head > .title-block .breadcrumbs {
  grid-column: 1 / -1;
}

.page-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
}
.verifier-limit-inline {
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  column-gap: 24px;
  row-gap: 4px;
  min-height: 26px;
  color: var(--text);
  font-size: 16px;
  line-height: 1.3;
}

.verifier-limit-inline > span {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  white-space: nowrap;
}

.verifier-limit-inline strong {
  font-size: 18px;
  font-weight: 800;
}

.workspace-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-ghost,
.btn-secondary,
.btn-danger,
.btn-teal,
.btn-inline {
  height: 34px;
  padding: 0 12px;
  border-radius: 4px;
  border: 1px solid var(--line);
  background: #fff;
  color: #2d3a42;
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.12s ease;
}

.btn-secondary {
  background: #fafcfd;
}

.btn-secondary:hover,
.btn-inline:hover,
.btn-ghost:hover {
  background: #f2f6f8;
  border-color: #cfd8df;
}

.btn-danger {
  border-color: #f3b2b2;
  background: #ff4d4f;
  color: #fff;
}

.btn-green {
  border-color: #9dd8bf;
  background: #13a563;
  color: #fff;
}

.btn-blue {
  border-color: #9dc5ff;
  background: #2d8cff;
  color: #fff;
}

.btn-teal {
  border-color: #8dd9d2;
  background: #0aa394;
  color: #fff;
}

.btn-teal:hover {
  border-color: #0d9488;
  background: #0d9488;
}

.btn-yellow {
  border-color: #ffd58a;
  background: #f6b21a;
  color: #fff;
}

.btn-icon {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #0aa394;
  color: #fff;
  cursor: pointer;
}

.btn-icon .svg-icon,
.topbar-icon .svg-icon {
  pointer-events: none;
}

.btn-inline {
  height: 24px;
  padding: 0 7px;
  font-size: 12px;
  line-height: 22px;
}

.btn-inline:disabled {
  cursor: wait;
  opacity: 0.82;
}

.btn-inline.is-loading {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.btn-inline.is-loading::before {
  content: "";
  width: 10px;
  height: 10px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.btn-group {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
}

.page {
  min-width: 0;
  overflow: auto;
  padding: 14px 16px 20px;
  background: #fff;
}

.card {
  background: #fff;
  border: 1px solid #ebeff2;
  border-radius: 4px;
  box-shadow: var(--shadow);
}

.card + .card {
  margin-top: 14px;
}

.page-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.page-top .title-block {
  min-width: 0;
}

.page-top .title-block h2 {
  margin: 0;
  font-size: 16px;
}

.page-top .title-block p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.summary-strip {
  padding: 11px 13px;
  border-radius: 4px;
  background: #f6f8fa;
  color: #41535e;
  font-size: 12px;
  line-height: 1.7;
}

.summary-strip strong {
  color: #0a7f72;
}

.filter-panel {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 4px;
  background: #fff;
  border: 1px solid #edf1f4;
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
  align-items: end;
}

.field {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.field label {
  font-size: 11px;
  color: var(--muted);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 38px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.modal-panel .field input,
.modal-panel .field select,
.modal-panel .field textarea {
  min-height: 36px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(10, 163, 148, 0.7);
  box-shadow: 0 0 0 3px rgba(10, 163, 148, 0.08);
}

.field.span-2 {
  grid-column: span 2;
}

.field.span-3 {
  grid-column: span 3;
}

.filter-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.table-card {
  margin-top: 10px;
  overflow: hidden;
}

.account-card .table-wrap table {
  min-width: 1260px;
  table-layout: fixed;
}

.account-card th,
.account-card td {
  white-space: nowrap;
}

.account-card th:nth-child(1),
.account-card td:nth-child(1) {
  width: 62px;
}

.account-card th:nth-child(2),
.account-card td:nth-child(2) {
  width: 150px;
}

.account-card th:nth-child(3),
.account-card td:nth-child(3) {
  width: 74px;
}

.account-card th:nth-child(4),
.account-card td:nth-child(4) {
  width: 74px;
}

.account-card th:nth-child(5),
.account-card td:nth-child(5),
.account-card th:nth-child(6),
.account-card td:nth-child(6) {
  width: 150px;
}

.account-card th:nth-child(7),
.account-card td:nth-child(7),
.account-card th:nth-child(8),
.account-card td:nth-child(8) {
  width: 76px;
  text-align: center;
}

.account-card th:nth-child(9),
.account-card td:nth-child(9) {
  width: 150px;
}

.account-card th:nth-child(10),
.account-card td:nth-child(10) {
  width: 360px;
}

.account-card th,
.account-card td {
  padding: 7px 8px;
}

.recharge-card .table-wrap table {
  min-width: 1720px;
}

.recharge-card th,
.recharge-card td {
  white-space: nowrap;
}

.recharge-card th:nth-child(1),
.recharge-card td:nth-child(1) {
  width: 260px;
}

.recharge-card th:nth-child(13),
.recharge-card td:nth-child(13) {
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cashier-card .table-wrap table {
  min-width: 1320px;
  table-layout: fixed;
}

.cashier-card th,
.cashier-card td {
  padding: 9px 12px;
}

.cashier-card th {
  white-space: normal;
  line-height: 1.25;
}

.cashier-card th:nth-child(1),
.cashier-card td:nth-child(1) {
  width: 44px;
}

.cashier-card th:nth-child(2),
.cashier-card td:nth-child(2) {
  width: 150px;
}

.cashier-card th:nth-child(3),
.cashier-card td:nth-child(3) {
  width: 90px;
}

.cashier-card th:nth-child(4),
.cashier-card td:nth-child(4) {
  width: 84px;
}

.cashier-card th:nth-child(5),
.cashier-card td:nth-child(5) {
  width: 106px;
}

.cashier-card th:nth-child(6),
.cashier-card td:nth-child(6) {
  width: 92px;
}

.cashier-card th:nth-child(7),
.cashier-card td:nth-child(7),
.cashier-card th:nth-child(8),
.cashier-card td:nth-child(8) {
  width: 70px;
  text-align: center;
}

.cashier-card th:nth-child(9),
.cashier-card td:nth-child(9) {
  width: 340px;
}

.cashier-card th:nth-child(10),
.cashier-card td:nth-child(10) {
  width: 132px;
}

.cashier-card th:nth-child(11),
.cashier-card td:nth-child(11) {
  width: 210px;
}

.cashier-card td:nth-child(5) code {
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.3;
}

.cashier-card td:nth-child(9) .type-link {
  display: inline-block;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.cashier-card .table-actions {
  gap: 5px;
}

.table-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid #edf1f4;
  background: #fafbfd;
}

.table-toolbar .toolbar-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.table-wrap {
  overflow: auto;
  max-width: 100%;
}

table {
  width: 100%;
  min-width: 1080px;
  border-collapse: collapse;
}

th,
td {
  padding: 10px 10px;
  border-bottom: 1px solid #eef2f4;
  font-size: 12px;
  text-align: left;
  vertical-align: middle;
}

thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #fafbfd;
  color: #60707a;
  font-weight: 500;
}

tbody tr:hover {
  background: #fafcfd;
}

.muted {
  color: var(--muted);
}

.tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #eef3f6;
  color: #51626d;
  font-size: 11px;
}

.tag.success {
  background: rgba(19, 165, 99, 0.12);
  color: var(--success);
}

.tag.danger {
  background: rgba(255, 91, 91, 0.12);
  color: var(--danger);
}

.tag.warning {
  background: rgba(240, 173, 78, 0.14);
  color: #b9770f;
}

.tag.brand {
  background: rgba(10, 163, 148, 0.14);
  color: var(--brand-2);
}

.tag.gray {
  background: #eef2f4;
  color: #596973;
}

.type-link {
  color: #2d8cff;
  font-weight: 600;
}

.table-text-button {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  color: #0f766e;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.table-text-button:hover {
  text-decoration: underline;
}

.table-actions {
  display: flex;
  gap: 6px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.page-top-compact .btn-group {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-top: 1px solid #edf1f4;
  background: #fff;
}

.pager-info {
  color: var(--muted);
  font-size: 13px;
}

.pager-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pager-controls button,
.pager-controls select,
.pager-controls input {
  height: 34px;
}

.pager-controls input {
  width: 66px;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 8px;
}

.empty-state {
  padding: 42px 16px;
  text-align: center;
  color: var(--muted);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 14px;
}

.dashboard-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric {
  padding: 16px;
  border-radius: 6px;
  background: linear-gradient(180deg, #fff, #f6f9fb);
  border: 1px solid #ecf1f4;
}

.metric span {
  color: var(--muted);
  font-size: 13px;
}

.metric strong {
  display: block;
  margin-top: 10px;
  font-size: 28px;
  line-height: 1;
}

.metric em {
  display: block;
  margin-top: 8px;
  color: var(--brand-2);
  font-style: normal;
  font-size: 12px;
}

.notice-list {
  padding: 14px;
  line-height: 1.7;
  color: #eaf7f5;
  background: linear-gradient(180deg, #18343b, #11262b);
  border-radius: 6px;
}

.notice-list p {
  margin: 0 0 8px;
}

.doc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.doc-box {
  padding: 16px;
  border: 1px solid #e6ecef;
  border-radius: 6px;
  background: #fff;
}

.doc-box pre {
  margin: 0;
  padding: 14px;
  overflow: auto;
  border-radius: 6px;
  background: #0c1620;
  color: #d6e4ed;
  font-size: 12px;
}

.toast {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 80;
  min-width: 240px;
  max-width: min(92vw, 380px);
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.94);
  color: #fff;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: translate(-50%, calc(-50% + 12px));
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.toast.is-showing {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.toast.is-sticky {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  max-width: min(92vw, 520px);
  pointer-events: auto;
}

.toast-close {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.toast-close:hover {
  background: rgba(255, 255, 255, 0.24);
}

.modal-host {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
}

.modal-mask {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 23, 42, 0.45);
  pointer-events: auto;
}

.modal-panel {
  width: min(100%, 980px);
  max-height: min(88vh, 920px);
  overflow: auto;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 22px 56px rgba(0, 0, 0, 0.18);
}

.modal-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid #e7edf2;
  background: #fff;
}

.modal-close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: #eef2f6;
  color: #334155;
  font-size: 20px;
  cursor: pointer;
}

.modal-form {
  padding: 12px 14px 14px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.modal-actions .btn-primary,
.modal-actions .btn-secondary {
  height: 36px;
}

.modal-tip {
  margin-bottom: 12px;
  padding: 9px 11px;
  border-radius: 6px;
  background: #f5f9fb;
  color: #51606d;
  font-size: 12px;
  line-height: 1.7;
}

.form-section-title {
  margin: 12px 0 8px;
  color: #014d4b;
  font-size: 13px;
  font-weight: 800;
}

.modal-form > .form-section-title:first-child {
  margin-top: 0;
}

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

.ck-account-list {
  display: grid;
  gap: 10px;
  max-height: 58vh;
  overflow: auto;
  padding-right: 2px;
}

.ck-account-row {
  display: grid;
  grid-template-columns: 128px minmax(180px, 1fr) 120px 120px;
  gap: 10px;
  align-items: end;
  padding: 10px;
  border: 1px solid #d9ece9;
  border-radius: 8px;
  background: #fbfdfc;
}

.ck-account-meta {
  display: grid;
  gap: 4px;
  align-self: center;
  min-width: 0;
}

.ck-account-meta strong {
  font-size: 16px;
  color: #0f766e;
}

.ck-account-meta span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #51606d;
  font-size: 12px;
}

.field-block {
  display: block;
}

.field-block textarea {
  min-height: 200px;
  resize: vertical;
}

.modal-panel .form-grid {
  align-items: start;
}

.modal-panel .field span {
  font-size: 12px;
}

.quick-menu {
  display: grid;
  gap: 10px;
}

.quick-card {
  width: 100%;
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid #e3eaee;
  border-radius: 6px;
  background: #fafcfd;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, transform 0.12s ease, box-shadow 0.16s ease;
}

.quick-card:hover {
  border-color: #bfd3d8;
  background: #f5faf9;
  box-shadow: 0 8px 18px rgba(15, 154, 138, 0.06);
}

.quick-card strong {
  font-size: 15px;
  color: #1f2d35;
}

.quick-card span {
  color: #5f717c;
  font-size: 13px;
}

.apk-dropzone {
  display: grid;
  gap: 8px;
  padding: 22px;
  margin-top: 10px;
  border: 1px dashed #b6c7d1;
  background: linear-gradient(180deg, #fbfdfe, #f3f8fb);
  cursor: pointer;
}

.apk-dropzone.is-dragging {
  border-color: var(--brand);
  background: linear-gradient(180deg, #f3fffd, #eafbf8);
}

.apk-dropzone-title {
  font-size: 16px;
  font-weight: 700;
  color: #20323b;
}

.apk-dropzone-meta {
  color: #61707a;
}

.apk-summary {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.apk-kv {
  display: grid;
  gap: 4px;
}

.apk-kv span,
.apk-section-title {
  color: #6a7a84;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.apk-kv strong {
  color: #18252c;
  font-size: 14px;
  word-break: break-all;
}

.apk-hash {
  font-family: Consolas, "SFMono-Regular", Menlo, monospace;
}

.apk-section {
  display: grid;
  gap: 8px;
  margin-top: 2px;
}

.apk-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.apk-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef7f6;
  color: #0f6f64;
  font-size: 12px;
}

.apk-searchbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 0 4px;
}

.apk-searchbar input[type="text"] {
  flex: 1;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 4px;
  outline: none;
}

.apk-searchbar input[type="text"]:focus {
  border-color: rgba(10, 163, 148, 0.7);
  box-shadow: 0 0 0 4px rgba(10, 163, 148, 0.08);
}

.apk-search-flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #51606d;
  font-size: 13px;
  white-space: nowrap;
}

.apk-search-results {
  display: grid;
  gap: 10px;
  max-height: 360px;
  overflow: auto;
  padding: 8px 0 14px;
}

.apk-hit {
  display: grid;
  gap: 4px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #e5edf1;
  border-radius: 6px;
  background: #fbfdfe;
  text-align: left;
  cursor: pointer;
}

.apk-hit:hover {
  border-color: rgba(10, 163, 148, 0.35);
  background: #f5fbfa;
}

.apk-hit strong {
  color: #1d2a32;
  font-size: 13px;
  font-family: Consolas, "SFMono-Regular", Menlo, monospace;
  word-break: break-all;
}

.apk-hit span {
  color: #0f6f64;
  font-size: 12px;
}

.apk-hit em {
  color: #53636e;
  font-style: normal;
  font-size: 12px;
  word-break: break-word;
}

.apk-tree {
  display: grid;
  max-height: 520px;
  overflow: auto;
  padding: 8px 0;
}

.apk-file {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px 12px;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  border-bottom: 1px solid #eef2f4;
}

.apk-file:hover {
  background: #f7fbfc;
}

.apk-file.dir {
  color: #0e7d70;
}

.apk-file.file {
  color: #26343d;
}

.apk-file-icon {
  width: 20px;
  flex: 0 0 20px;
}

.apk-file-path {
  flex: 1;
  min-width: 0;
  font-family: Consolas, "SFMono-Regular", Menlo, monospace;
  font-size: 12px;
  word-break: break-all;
}

.apk-pre {
  margin: 0;
  min-height: 240px;
  max-height: 540px;
  overflow: auto;
  padding: 14px;
  border-top: 1px solid #eef2f4;
  background: #fbfcfd;
  font-family: Consolas, "SFMono-Regular", Menlo, monospace;
  font-size: 12px;
  line-height: 1.6;
  white-space: normal;
  word-break: normal;
}

.apk-code-view {
  padding: 0;
}

.apk-code {
  display: grid;
  min-width: 100%;
  font-family: Consolas, "SFMono-Regular", Menlo, monospace;
}

.apk-code-empty {
  padding: 14px;
  color: #65747d;
}

.apk-line {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  align-items: stretch;
  border-bottom: 1px solid #edf2f5;
}

.apk-line:hover {
  background: #f5fbfa;
}

.apk-line.is-focus {
  background: #eefaf8;
}

.apk-line-no {
  position: sticky;
  left: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 12px 0 10px;
  color: #7a8790;
  background: #f7fafb;
  border-right: 1px solid #eef2f4;
  font-size: 12px;
  user-select: none;
}

.apk-line.is-focus .apk-line-no {
  color: #0b7469;
  background: #e6f6f4;
  font-weight: 700;
}

.apk-line-code {
  min-width: 0;
  padding: 0 12px;
  white-space: pre;
  overflow-x: auto;
}

.apk-line-code mark,
.apk-hit mark {
  padding: 0 2px;
  border-radius: 2px;
  background: #fff1a8;
  color: inherit;
}

.apk-line.is-focus .apk-line-code {
  background: #f8fdfd;
}

/* Visual refinement */
.login-page {
  background:
    radial-gradient(circle at 20% 14%, rgba(30, 190, 165, 0.28), transparent 28%),
    radial-gradient(circle at 84% 82%, rgba(200, 135, 46, 0.2), transparent 26%),
    linear-gradient(145deg, #081714 0%, #10231f 48%, #183b35 100%);
}

.login-shell::before {
  content: "";
  position: fixed;
  inset: 24px;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
}

.login-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
}

.login-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 8px;
  background: linear-gradient(90deg, var(--brand), #49d6bd, var(--accent-gold));
}

.login-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: #48645c;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.login-brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, #0d9488, #d4a049);
  color: #fff;
  letter-spacing: 0;
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.22);
}

.login-banner {
  margin: 0 0 18px;
  padding: 8px 0 0;
  background: transparent;
  color: var(--ink);
  font-size: 22px;
}

.login-banner p {
  margin: 10px 0 0;
  color: #697d76;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.7;
}

.login-notch {
  display: none;
}

.login-form {
  gap: 16px;
}

.login-form input {
  height: 50px;
  border-radius: 14px;
  background: #f8fbfa;
}

.login-form button,
.btn-primary {
  border-radius: 12px;
  background: linear-gradient(135deg, #0d9488, #0f766e);
  box-shadow: 0 12px 24px rgba(13, 148, 136, 0.2);
}

.login-assurance {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.login-assurance span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(13, 148, 136, 0.12);
  border-radius: 999px;
  background: #f4fbf9;
  color: #0f766e;
  font-size: 12px;
  font-weight: 700;
}

.app-shell {
  background:
    radial-gradient(circle at 18% 0%, rgba(21, 184, 157, 0.13), transparent 28%),
    linear-gradient(180deg, #f6faf8 0%, #edf4f1 100%);
}

.topbar {
  height: 54px;
  padding: 0 20px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.08), transparent 28%),
    linear-gradient(135deg, #0b1f1b, #143b34);
  box-shadow: 0 16px 30px rgba(8, 23, 20, 0.12);
}

.brand-mark {
  font-size: 18px;
  letter-spacing: 0.04em;
}

.brand-dot {
  width: 12px;
  height: 12px;
  background: linear-gradient(135deg, #54e2c7, #d7a450);
  box-shadow: 0 0 0 6px rgba(84, 226, 199, 0.14);
}

.topbar-icon,
.project-chip,
.user-chip {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(10px);
}

.sidebar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(239, 247, 244, 0.94)),
    radial-gradient(circle at 20% 0%, rgba(13, 148, 136, 0.1), transparent 32%);
  border-right: 1px solid rgba(17, 67, 58, 0.1);
}

.menu-group {
  margin: 8px 10px;
  overflow: hidden;
  border: 1px solid rgba(19, 87, 76, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.58);
}

.menu-group-title {
  min-height: 44px;
  border-radius: 14px;
  background: transparent;
  color: #1b332d;
  font-weight: 700;
}

.menu-group-title:hover {
  background: rgba(13, 148, 136, 0.08);
}

.menu-items,
.menu-item {
  background: transparent;
}

.menu-item {
  margin: 2px 8px 8px;
  min-height: 36px;
  border: 0;
  border-radius: 12px;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.78);
}

.menu-item.is-active {
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.16), rgba(200, 135, 46, 0.1));
  color: #075e55;
  box-shadow: inset 3px 0 0 var(--brand);
}

.workspace {
  background:
    radial-gradient(circle at 88% 8%, rgba(200, 135, 46, 0.08), transparent 26%),
    linear-gradient(180deg, #f8fbfa 0%, #eef5f2 100%);
}

.tabs-bar {
  padding: 8px 12px 0;
  gap: 8px;
  border-bottom: 0;
  background: transparent;
}

.tab {
  min-width: 116px;
  height: 38px;
  border: 1px solid rgba(20, 68, 60, 0.08);
  border-radius: 13px 13px 0 0;
  background: rgba(255, 255, 255, 0.62);
}

.tab.is-active {
  border-bottom-color: #fff;
  background: #fff;
  box-shadow: 0 -8px 22px rgba(12, 47, 40, 0.06);
}

.workspace-head {
  margin: 0 12px;
  padding: 12px 16px;
  border: 1px solid rgba(16, 78, 68, 0.08);
  border-radius: 0 16px 16px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 12px 34px rgba(16, 44, 38, 0.05);
}

.page {
  padding: 16px 18px 24px;
  background: transparent;
}

.card {
  overflow: hidden;
  border-color: rgba(16, 78, 68, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  animation: riseIn 0.34s ease both;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.home-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 14px;
  padding: 24px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 88% 20%, rgba(255, 255, 255, 0.24), transparent 24%),
    linear-gradient(135deg, #10231f 0%, #176055 64%, #c8872e 140%);
  color: #fff;
  box-shadow: 0 24px 56px rgba(16, 44, 38, 0.18);
  animation: riseIn 0.36s ease both;
}

.home-hero h2 {
  margin: 4px 0 8px;
  font-size: 28px;
  letter-spacing: 0.03em;
}

.home-hero p {
  margin: 0;
  max-width: 620px;
  color: rgba(255, 255, 255, 0.76);
}

.eyebrow {
  margin: 0;
  color: rgba(255, 255, 255, 0.62) !important;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.btn-light {
  height: 40px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s ease, transform 0.12s ease;
}

.btn-light:hover {
  background: rgba(255, 255, 255, 0.22);
}

.btn-light:active {
  transform: translateY(1px);
}

.dashboard-cards {
  gap: 14px;
}

.metric {
  position: relative;
  overflow: hidden;
  min-height: 142px;
  padding: 18px;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(16, 44, 38, 0.07);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.metric:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 46px rgba(16, 44, 38, 0.1);
}

.metric::after {
  content: "";
  position: absolute;
  right: -34px;
  top: -34px;
  width: 120px;
  height: 120px;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.12);
}

.metric.tone-2::after {
  background: rgba(200, 135, 46, 0.16);
}

.metric.tone-3::after {
  background: rgba(45, 140, 255, 0.13);
}

.metric.tone-4::after {
  background: rgba(223, 75, 75, 0.11);
}

.metric span {
  position: relative;
  z-index: 1;
  color: #60756e;
  font-weight: 700;
}

.metric strong {
  position: relative;
  z-index: 1;
  margin-top: 14px;
  color: var(--ink);
  font-size: clamp(24px, 2vw, 34px);
}

.metric em {
  position: relative;
  z-index: 1;
  color: var(--brand-2);
}

.summary-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  background: transparent;
}

.summary-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(13, 148, 136, 0.12);
  border-radius: 999px;
  background: #f6fbfa;
}

.notice-list {
  min-height: 98px;
  border-radius: 14px;
  background:
    radial-gradient(circle at 100% 0%, rgba(84, 226, 199, 0.16), transparent 36%),
    linear-gradient(145deg, #10231f, #163832);
}

.filter-panel {
  position: relative;
  padding: 14px;
  border-color: rgba(13, 148, 136, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 28px rgba(16, 44, 38, 0.04);
}

.filter-panel::before {
  content: "筛选条件";
  display: inline-flex;
  margin-bottom: 10px;
  color: #0f766e;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.field input,
.field select,
.field textarea {
  border-radius: 12px;
  background: #fbfdfc;
}

.filter-panel .field input,
.filter-panel .field select,
.filter-panel .field textarea {
  inline-size: 100%;
  max-inline-size: 100%;
  min-inline-size: 0;
  min-height: 34px;
  padding: 0 9px;
  border-radius: 8px;
  font-size: 12px;
}

.filter-panel .field input[type="date"] {
  appearance: none;
  -webkit-appearance: none;
}

.filter-panel .btn-primary,
.filter-panel .btn-secondary {
  height: 34px;
  padding: 0 13px;
  font-size: 12px;
}

.btn-ghost,
.btn-secondary,
.btn-danger,
.btn-teal,
.btn-inline,
.btn-icon {
  border-radius: 999px;
}

.btn-secondary,
.btn-ghost {
  background: #fff;
}

.btn-icon {
  border-color: rgba(13, 148, 136, 0.14);
  background: linear-gradient(135deg, #0d9488, #0f766e);
  box-shadow: 0 10px 22px rgba(13, 148, 136, 0.16);
}

.stats-card {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.stats-card > span {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 8px;
  min-height: 78px;
  padding: 14px;
  border: 1px solid rgba(13, 148, 136, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 28px rgba(16, 44, 38, 0.05);
}

.stats-card > span::after {
  content: "";
  position: absolute;
  right: -26px;
  top: -32px;
  width: 92px;
  height: 92px;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.08);
}

.stats-card > span.is-loading strong,
.stats-card > span.is-loading small {
  width: fit-content;
  border-radius: 8px;
  color: transparent;
  background: linear-gradient(90deg, #edf5f2 0%, #f8fbfa 45%, #edf5f2 100%);
  background-size: 220% 100%;
  animation: shimmer 1.2s ease-in-out infinite;
}

@keyframes shimmer {
  to {
    background-position: -220% 0;
  }
}

.stats-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.stats-card strong {
  color: var(--ink);
  font-size: 20px;
}

.table-toolbar {
  align-items: center;
  padding: 13px 16px;
  border-bottom-color: rgba(16, 78, 68, 0.08);
  background: linear-gradient(180deg, #fff, #f8fbfa);
}

.table-toolbar strong {
  color: var(--ink);
  font-size: 15px;
}

.table-wrap {
  background: #fff;
}

table {
  border-collapse: separate;
  border-spacing: 0;
}

th,
td {
  border-bottom-color: #edf4f1;
}

thead th {
  background: #f7fbfa;
  color: #506a62;
  font-weight: 800;
}

tbody tr {
  transition: background 0.16s ease, box-shadow 0.16s ease;
}

tbody tr:hover {
  background: #f4fbf8;
}

tbody tr:nth-child(even) {
  background-image: linear-gradient(90deg, rgba(13, 148, 136, 0.018), transparent);
}

.tag {
  min-width: 52px;
  height: 24px;
  font-weight: 700;
}

.pager {
  border-top-color: rgba(16, 78, 68, 0.08);
  background: linear-gradient(180deg, #fff, #fbfdfc);
}

.empty-state {
  color: #7b8c85;
}

.empty-illustration {
  display: grid;
  place-items: center;
  gap: 10px;
  min-height: 110px;
  color: #7b8c85;
  font-weight: 700;
}

.empty-illustration::before {
  content: "";
  width: 48px;
  height: 48px;
  border-radius: 18px;
  background:
    linear-gradient(#dff0eb 0 0) 14px 15px / 20px 3px no-repeat,
    linear-gradient(#dff0eb 0 0) 14px 24px / 20px 3px no-repeat,
    linear-gradient(#dff0eb 0 0) 14px 33px / 14px 3px no-repeat,
    linear-gradient(135deg, #f7fbfa, #eaf5f1);
  border: 1px solid #dcebe6;
  box-shadow: 0 12px 24px rgba(16, 44, 38, 0.08);
}

* {
  scrollbar-width: thin;
  scrollbar-color: rgba(13, 148, 136, 0.36) transparent;
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  border: 3px solid transparent;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.34);
  background-clip: content-box;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(13, 148, 136, 0.52);
  background-clip: content-box;
}
}

.modal-mask {
  background: rgba(8, 23, 20, 0.56);
  backdrop-filter: blur(4px);
}

.modal-panel {
  border-radius: 20px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.24);
}

.modal-head {
  padding: 14px 18px;
  background: linear-gradient(180deg, #fff, #f8fbfa);
}

@media (max-width: 1200px) {
  .dashboard-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stats-card {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 960px) {
  body.dashboard-page {
    overflow: hidden;
  }

  .app-shell {
    position: relative;
    height: 100dvh;
    min-height: 100dvh;
    grid-template-columns: 1fr;
    grid-template-rows: 54px minmax(0, 1fr);
    grid-template-areas:
      "topbar"
      "workspace";
  }

  .app-shell.sidebar-hidden {
    grid-template-columns: 1fr;
  }

  .app-shell:not(.sidebar-hidden)::after {
    content: "";
    position: fixed;
    inset: 54px 0 0;
    z-index: 35;
    background: rgba(8, 23, 20, 0.36);
    backdrop-filter: blur(3px);
  }

  .topbar {
    position: sticky;
    top: 0;
    z-index: 45;
  }

  .sidebar {
    position: fixed;
    z-index: 40;
    top: 54px;
    bottom: 0;
    left: 0;
    width: min(84vw, 310px);
    max-height: none;
    transform: translateX(0);
    border-right: 1px solid rgba(17, 67, 58, 0.12);
    box-shadow: 24px 0 60px rgba(8, 23, 20, 0.24);
    transition: transform 0.22s ease, opacity 0.18s ease;
  }

  .app-shell.sidebar-hidden .sidebar {
    width: min(84vw, 310px);
    min-width: auto;
    padding: initial;
    transform: translateX(-108%);
    border-right: 1px solid rgba(17, 67, 58, 0.12);
    opacity: 0;
    pointer-events: none;
  }

  .sidebar-inner {
    padding-bottom: 40px;
  }

  .workspace {
    min-height: 0;
    grid-template-rows: auto auto minmax(0, 1fr);
    overflow: hidden;
  }

  .tabs-bar {
    padding-inline: 8px;
  }

  .tab {
    min-width: 96px;
    max-width: 152px;
    padding: 0 10px;
  }

  .workspace-head {
    margin: 0 8px;
    border-radius: 0 14px 14px;
  }

  .page {
    min-height: 0;
    padding: 12px 10px 18px;
  }
}

@media (max-width: 720px) {
  .topbar {
    gap: 8px;
    padding: 0 10px;
  }

  .topbar-left,
  .topbar-right {
    gap: 8px;
  }

  .brand-mark {
    font-size: 15px;
  }

  .brand-dot {
    width: 10px;
    height: 10px;
  }

  .project-chip {
    display: none;
  }

  .user-chip {
    max-width: min(62vw, 220px);
    padding: 0 10px;
    font-size: 13px;
  }

  .topbar-icon {
    width: 34px;
    min-width: 34px;
  }

  .login-card {
    padding: 28px 20px 24px;
  }

  .login-banner {
    margin: 0 0 18px;
  }

  .dashboard-cards,
  .doc-grid {
    grid-template-columns: 1fr;
  }

  .workspace-head,
  .table-toolbar,
  .pager {
    flex-direction: column;
    align-items: stretch;
  }

  .workspace-head > .title-block {
    grid-template-columns: 1fr;
    row-gap: 6px;
  }

  .verifier-limit-inline {
    white-space: normal;
  }

  .verifier-limit-inline > span {
    white-space: normal;
  }
  .workspace-head {
    gap: 10px;
    padding: 12px;
  }

  .workspace-actions {
    justify-content: flex-start;
  }

  .home-hero {
    align-items: flex-start;
    flex-direction: column;
    padding: 18px;
    border-radius: 20px;
  }

  .home-hero h2 {
    font-size: 24px;
  }

  .metric {
    min-height: 124px;
  }

  .stats-card {
    grid-template-columns: 1fr;
  }

  .filter-panel {
    margin-top: 8px;
    padding: 8px;
    border-radius: 12px;
    overflow: hidden;
  }

  .filter-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    margin: -5px;
  }

  .field {
    min-width: 0;
    gap: 4px;
  }

  .filter-grid > .field {
    flex: 0 0 50%;
    max-width: 50%;
    padding: 5px;
  }

  .field label {
    font-size: 11px;
    line-height: 1.2;
  }

  .field input,
  .field select,
  .field textarea {
    min-width: 0;
    min-height: 32px;
    padding: 0 8px;
    font-size: 12px;
    border-radius: 8px;
  }

  .filter-panel .btn-primary,
  .filter-panel .btn-secondary {
    height: 32px;
    padding: 0 10px;
  }

  .filter-actions,
  .pager-controls {
    width: 100%;
  }

  .filter-grid > .field:last-child {
    flex-basis: 100%;
    max-width: 100%;
  }

  .ck-account-row {
    grid-template-columns: 1fr;
  }

  .filter-actions .btn-primary,
  .filter-actions .btn-secondary {
    flex: 1;
  }

  .table-card {
    border-radius: 16px;
  }

  .table-wrap {
    max-width: calc(100vw - 20px);
    -webkit-overflow-scrolling: touch;
  }

  table {
    min-width: 920px;
  }

  .account-card .table-wrap table {
    min-width: 1280px;
  }

  th,
  td {
    padding: 9px 10px;
  }

  .pager {
    gap: 10px;
  }

  .pager-controls {
    justify-content: flex-start;
  }

  .pager-controls button,
  .pager-controls select {
    flex: 1 1 auto;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .field.span-2,
  .field.span-3 {
    grid-column: auto;
  }
}
