* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  color: #0f172a;
  background: #f4f4f5;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
button, input, textarea, select { min-width: 0; font: inherit; }
button {
  height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  background: #050505;
  cursor: pointer;
  font-weight: 800;
}
button.ghost {
  color: #334155;
  border: 1px solid #dbe4ef;
  background: #fff;
}
button:disabled {
  cursor: not-allowed;
  opacity: .48;
}
input, textarea, select {
  width: 100%;
  border: 1px solid #dbe4ef;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
}
input, select { height: 38px; padding: 0 11px; }
textarea { min-height: 110px; padding: 11px; resize: vertical; }
pre {
  max-width: 100%;
  overflow: auto;
  padding: 12px;
  border-radius: 8px;
  background: #0f172a;
  color: #e2e8f0;
  font-size: 12px;
  line-height: 1.55;
}
pre:empty { display: none; }
.shell {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  min-height: 100vh;
}
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 18px 18px;
  border-right: 1px solid #e7e7e7;
  background: #f4f4f5;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}
.brand span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  color: #050505;
  border: 2px solid #050505;
  background: #f7d23e;
  font-weight: 950;
}
.brand strong { font-size: 15px; }
nav { display: grid; gap: 6px; }
.nav-section {
  margin: 18px 10px 6px;
  color: #8a8f98;
  font-size: 12px;
  font-weight: 900;
}
nav button {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  color: #18181b;
  background: transparent;
  text-align: left;
  font-size: 15px;
}
nav button.active {
  color: #050505;
  background: #dedede;
}
.nav-ico {
  display: inline-grid;
  place-items: center;
  width: 18px;
  color: #111;
}
.content { min-width: 0; padding: 0 12px 18px; }
.app-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  min-height: 64px;
  padding: 8px 0;
  background: #f4f4f5;
}
.top-links {
  display: flex;
  justify-content: center;
  gap: 8px;
}
.top-link {
  width: auto;
  color: #52525b;
  background: transparent;
  font-size: 14px;
}
.top-link.active {
  color: #050505;
}
.header-tools {
  display: flex;
  gap: 10px;
  align-items: center;
}
.search-box {
  display: flex;
  align-items: center;
  width: min(360px, 32vw);
  height: 38px;
  padding: 0 14px;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  background: #fafafa;
  color: #8a8f98;
  font-weight: 700;
}
input.search-box::placeholder {
  color: #8a8f98;
}
.icon-btn {
  width: auto;
  min-width: 56px;
  color: #111;
  border: 1px solid #e4e4e7;
  background: #fff;
  white-space: nowrap;
}
.page-shell {
  min-height: calc(100vh - 82px);
  padding: 20px;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, .06);
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 18px;
}
.page-heading-tools {
  display: flex;
  flex: 1 1 560px;
  justify-content: center;
  min-width: 260px;
}
.page-heading-tools[hidden] {
  display: none;
}
.page-heading h1 {
  margin: 0 0 6px;
  font-size: 22px;
}
.auth-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 26px;
  align-items: start;
  max-width: 980px;
}
.auth-view {
  background: #f5f5f4;
}
.auth-view .shell {
  display: block;
  min-height: 100vh;
}
.auth-view .sidebar {
  display: none;
}
.auth-view .content {
  display: grid;
  min-height: 100vh;
  padding: 28px;
  place-items: center;
}
.auth-view .auth-panel {
  width: min(760px, 100%);
  max-width: none;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
  align-items: center;
}
.auth-copy {
  min-width: 0;
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  color: #111827;
  font-weight: 900;
}
.auth-brand span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 2px solid #050505;
  border-radius: 8px;
  background: #f7d23e;
  font-weight: 950;
}
.auth-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.auth-meta span {
  padding: 5px 8px;
  border: 1px solid #e4e4e7;
  border-radius: 999px;
  color: #475569;
  background: #fff;
  font-size: 12px;
  font-weight: 800;
}
h1, h2, p { margin-top: 0; }
.auth-panel h1 { font-size: 34px; }
.auth-panel p, .topbar p, .hint { color: #64748b; }
.auth-card, .panel, .stats div {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}
.auth-card {
  display: grid;
  gap: 10px;
  padding: 16px;
}
.auth-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 2px;
}
.auth-tabs button {
  width: 100%;
}
.actions, .inline {
  display: flex;
  gap: 10px;
  align-items: center;
}
.inline button {
  flex: 0 0 auto;
  min-width: 88px;
  white-space: nowrap;
}
.scope-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 10px 0;
}
.scope-grid label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #475569;
  font-size: 13px;
  font-weight: 800;
}
.scope-grid input {
  width: auto;
  height: auto;
}
.compact-textarea {
  min-height: 64px;
  margin-top: 8px;
  font-size: 13px;
}
.spaced-input {
  margin-top: 8px;
}
.key-limit-grid {
  display: grid;
  grid-template-columns: 130px 160px;
  gap: 8px;
  margin-top: 8px;
  max-width: 320px;
}
.key-limit-grid.wide {
  grid-template-columns: 160px 100px minmax(190px, 1fr) 110px 140px;
  max-width: 860px;
}
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-bottom: 18px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.compact-stats strong { font-size: 24px; }
.analytics-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.analytics-stats div {
  min-height: 74px;
  padding: 14px 16px;
}
.stats div {
  padding: 20px 24px;
  border: 0;
  border-right: 1px solid #ececec;
  border-radius: 0;
}
.stats div:last-child { border-right: 0; }
.stats span {
  display: block;
  color: #64748b;
  font-size: 13px;
}
.stats strong {
  display: block;
  margin-top: 8px;
  font-size: 30px;
  letter-spacing: 0;
}
.panel {
  min-width: 0;
  padding: 18px;
  margin-bottom: 16px;
}
.setup-strip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 72px;
  padding: 14px 18px;
  margin-bottom: 18px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.setup-check {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  color: #059669;
  font-weight: 950;
}
.setup-strip strong,
.setup-strip small {
  display: block;
}
.setup-strip small {
  margin-top: 4px;
  color: #71717a;
}
.setup-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}
.dashboard-guide-strip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  margin-bottom: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(15, 23, 42, .045);
}
.dashboard-guide-strip strong,
.dashboard-guide-strip small {
  display: block;
}
.dashboard-guide-strip small {
  margin-top: 3px;
  color: #64748b;
}
.dashboard-usage-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  overflow: hidden;
  margin-bottom: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.dashboard-usage-main {
  padding: 16px;
}
.dashboard-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.usage-metric-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.usage-metric-card span,
.usage-metric-card strong,
.usage-metric-card small {
  display: block;
}
.usage-metric-card span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}
.usage-metric-card strong {
  margin: 8px 0 4px;
  color: #050505;
  font-size: 28px;
  line-height: 1;
}
.usage-metric-card small {
  color: #9ca3af;
  font-size: 12px;
}
.metric-spark {
  display: flex;
  align-items: end;
  gap: 4px;
  height: 30px;
  margin-top: 9px;
  overflow: hidden;
}
.metric-spark i {
  flex: 1;
  min-width: 0;
  min-height: 3px;
  border-radius: 999px;
  background: #111827;
}
.metric-spark i:nth-child(1) { height: 16%; }
.metric-spark i:nth-child(2) { height: 24%; }
.metric-spark i:nth-child(3) { height: 52%; }
.metric-spark i:nth-child(4) { height: 76%; }
.metric-spark i:nth-child(5) { height: 42%; }
.metric-spark.amber i { background: #d08a00; }
.metric-spark.slate i { background: #64748b; }
.balance-card {
  display: grid;
  align-content: space-between;
  gap: 14px;
  padding: 18px;
  border-left: 1px solid #e5e7eb;
  background: #fff8e8;
}
.balance-card-head {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  color: #64748b;
  font-weight: 900;
}
.balance-card-head small {
  color: #d08a00;
}
.balance-card > strong {
  display: block;
  color: #050505;
  font-size: 34px;
  line-height: 1;
}
.balance-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.balance-mini-grid div {
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, .72);
}
.balance-mini-grid span,
.balance-mini-grid b {
  display: block;
}
.balance-mini-grid span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}
.balance-mini-grid b {
  margin-top: 4px;
  font-size: 15px;
}
.balance-card button {
  width: 100%;
  color: #fff;
  background: #050505;
}
.dashboard-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.dashboard-card-head {
  margin-bottom: 10px;
}
.empty-state {
  display: grid;
  min-height: 128px;
  place-items: center;
  color: #9ca3af;
  font-weight: 900;
}
.onboarding-guide {
  margin-top: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.onboarding-guide > summary {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  cursor: pointer;
  font-weight: 950;
}
.onboarding-guide > summary small {
  color: #64748b;
  font-weight: 800;
}
.onboarding-guide[open] {
  padding-bottom: 12px;
}
.onboarding-guide[open] > .overview-grid,
.onboarding-guide[open] > .panel {
  margin: 0 12px 10px;
}
.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, .85fr);
  gap: 16px;
}
.quickstart-list {
  display: grid;
  gap: 8px;
}
.quickstart-step {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.quickstart-step > span {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid #dbe4ef;
  border-radius: 999px;
  color: #64748b;
  background: #fff;
  font-weight: 950;
}
.quickstart-step.done > span {
  color: #047857;
  border-color: #b7ebd0;
  background: #dff8ec;
}
.quickstart-step strong,
.quickstart-step small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.quickstart-step small {
  margin-top: 3px;
  color: #64748b;
}
.config-stack {
  display: grid;
  gap: 8px;
}
.config-stack div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.config-stack span,
.config-stack strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.config-stack span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.config-stack strong {
  margin-top: 5px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13px;
}
.wallet-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.wallet-summary div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.wallet-summary span,
.wallet-summary strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wallet-summary span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.wallet-summary strong {
  margin-top: 5px;
  font-size: 15px;
}
.test-lab-grid {
  display: grid;
  grid-template-columns: minmax(220px, 1.2fr) minmax(180px, .8fr);
  gap: 10px;
  margin-bottom: 10px;
}
.test-lab-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.test-lab-grid label:first-child,
.test-lab-grid label:nth-child(4) {
  grid-column: span 1;
}
.test-lab-grid span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}
.test-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 10px;
}
.test-summary div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.test-summary span,
.test-summary strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.test-summary span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.test-summary strong {
  margin-top: 5px;
  font-size: 13px;
}
.test-summary div:first-child strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
.code-input {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
.test-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
}
.test-actions button {
  min-width: 104px;
  white-space: nowrap;
}
.new-key-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: -6px 0 12px;
}
.new-key-actions button {
  height: 34px;
  font-size: 12px;
}
.key-list-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(520px, 1.25fr);
  gap: 12px;
  align-items: center;
  margin: 12px 0;
  padding-top: 12px;
  border-top: 1px solid #edf2f7;
}
.key-list-stats,
.key-list-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.key-list-stats span {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  color: #64748b;
  background: #fbfdff;
  font-size: 12px;
  font-weight: 900;
}
.key-list-stats strong {
  color: #111827;
}
.key-list-filters {
  justify-content: flex-end;
}
.key-list-filters input {
  flex: 1 1 220px;
  max-width: 360px;
}
.key-list-filters select {
  flex: 0 0 118px;
}
.key-list-filters button {
  height: 34px;
  font-size: 12px;
}
.log-list-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(520px, 1.25fr);
  gap: 12px;
  align-items: center;
  margin: 12px 0;
  padding-top: 12px;
  border-top: 1px solid #edf2f7;
}
.log-list-stats,
.log-list-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.log-list-stats span {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  color: #64748b;
  background: #fbfdff;
  font-size: 12px;
  font-weight: 900;
}
.log-list-stats strong {
  color: #111827;
}
.log-list-filters {
  justify-content: flex-end;
}
.log-list-filters input {
  flex: 1 1 240px;
  max-width: 380px;
}
.log-list-filters select {
  flex: 0 0 132px;
}
.log-list-filters button {
  height: 34px;
  font-size: 12px;
}
.pagination-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #edf2f7;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.pagination-bar:empty {
  display: none;
}
.pagination-bar select {
  width: auto;
  min-width: 104px;
  height: 34px;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 800;
}
.pagination-bar button {
  height: 34px;
  min-width: 70px;
  padding: 0 10px;
  font-size: 12px;
}
.pagination-bar strong {
  min-width: 54px;
  color: #111827;
  text-align: center;
}
.usage-log-table-wrap {
  overflow-x: auto;
  margin-top: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.usage-log-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
  table-layout: fixed;
}
.usage-log-table th,
.usage-log-table td {
  padding: 13px 16px;
  border-bottom: 1px solid #edf2f7;
  text-align: left;
  vertical-align: middle;
}
.usage-log-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #111827;
  background: #fafafa;
  font-size: 13px;
  font-weight: 900;
}
.usage-log-table tbody tr:hover {
  background: #fcfcfd;
}
.usage-log-table tbody tr:last-child td {
  border-bottom: 0;
}
.usage-log-table strong {
  display: block;
  color: #111827;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}
.usage-log-table small {
  display: block;
  overflow: hidden;
  margin-top: 5px;
  color: #9ca3af;
  font-size: 12px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.usage-log-table th:nth-child(1) { width: 16%; }
.usage-log-table th:nth-child(2) { width: 16%; }
.usage-log-table th:nth-child(3) { width: 24%; }
.usage-log-table th:nth-child(4) { width: 19%; }
.usage-log-table th:nth-child(5) { width: 12%; }
.usage-log-table th:nth-child(6) { width: 13%; }
.usage-time strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 999px;
  background: #9ca3af;
}
.dot.success { background: #10b981; }
.dot.warning { background: #f59e0b; }
.dot.danger { background: #ef4444; }
.api-key-head {
  align-items: flex-start;
}
.api-key-head button {
  white-space: nowrap;
}
#tab-keys .key-list-tools {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.api-key-table-wrap {
  overflow-x: auto;
  margin-top: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.api-key-table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
  table-layout: fixed;
}
.api-key-table th,
.api-key-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #edf2f7;
  line-height: 1.22;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}
.api-key-table th {
  color: #475569;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 950;
}
.api-key-table tbody tr:hover {
  background: #fcfcfd;
}
.api-key-table tbody tr:last-child td {
  border-bottom: 0;
}
.api-key-table strong,
.api-key-table small {
  display: block;
}
.api-key-table strong {
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.api-key-table small {
  max-width: 180px;
  overflow: hidden;
  margin-top: 3px;
  color: #64748b;
  font-size: 11px;
  text-overflow: ellipsis;
}
.api-key-table code {
  display: inline-flex;
  max-width: 100%;
  min-height: 24px;
  align-items: center;
  overflow: hidden;
  padding: 0 7px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: #0f172a;
  background: #f8fafc;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 11px;
  font-weight: 850;
  text-overflow: ellipsis;
}
.api-key-table th:nth-child(1) { width: 13%; }
.api-key-table th:nth-child(2) { width: 5%; }
.api-key-table th:nth-child(3) { width: 13%; }
.api-key-table th:nth-child(4) { width: 14%; }
.api-key-table th:nth-child(5) { width: 10%; }
.api-key-table th:nth-child(6) { width: 10%; }
.api-key-table th:nth-child(7) { width: 7%; }
.api-key-table th:nth-child(8) { width: 11%; }
.api-key-table th:nth-child(9) { width: 9%; }
.api-key-table th:nth-child(10) { width: 8%; }
.api-key-table .table-actions {
  min-width: 0;
  justify-content: flex-start;
}
.status-pill {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: #eef2f7;
  color: #475569;
  font-size: 11px;
  font-weight: 900;
}
.status-pill.success {
  background: #dff8ec;
  color: #047857;
}
.key-group-pill,
.duration-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 11px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #fff;
  color: #111827;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}
.key-group-pill {
  gap: 6px;
}
.key-group-pill::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #111827;
}
.duration-pill.success {
  border-color: #bbf7d0;
  background: #ecfdf5;
  color: #059669;
}
.duration-pill.warning {
  border-color: #fde68a;
  background: #fffbeb;
  color: #d97706;
}
.duration-pill.danger {
  border-color: #fecaca;
  background: #fef2f2;
  color: #dc2626;
}
.table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 190px;
}
.table-actions button {
  height: 28px;
  padding: 0 9px;
  font-size: 12px;
}
.task-record-table-wrap {
  overflow-x: auto;
  margin-top: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.task-record-table {
  width: 100%;
  min-width: 1240px;
  border-collapse: collapse;
}
.task-record-table th,
.task-record-table td {
  padding: 6px 8px;
  border-bottom: 1px solid #edf2f7;
  line-height: 1.2;
  text-align: left;
  vertical-align: middle;
  white-space: nowrap;
}
.task-record-table th {
  color: #475569;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 950;
  white-space: nowrap;
}
.task-record-table tbody tr:hover {
  background: #fcfcfd;
}
.task-record-table tbody tr:last-child td {
  border-bottom: 0;
}
.task-record-table strong,
.line-ellipsis {
  display: block;
  max-width: 150px;
  overflow: hidden;
  color: #334155;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mode-pill {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 12px;
  font-weight: 950;
  white-space: nowrap;
}
.task-progress {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 100px;
}
.task-progress span {
  display: block;
  flex: 1;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5e7eb;
}
.task-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #22c55e;
}
.task-progress b {
  min-width: 34px;
  color: #475569;
  font-size: 11px;
}
.task-no {
  display: inline-block;
  max-width: 120px;
  overflow: hidden;
  padding: 2px 6px;
  border-radius: 999px;
  background: #f8fafc;
  color: #334155;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.task-prompt-cell {
  display: block;
  max-width: 190px;
  overflow: hidden;
  color: #334155;
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.task-record-table .badge {
  min-height: 22px;
  padding: 0 7px;
  font-size: 11px;
  line-height: 1;
}
.task-record-table .duration-pill {
  min-height: 22px;
  padding: 0 7px;
  font-size: 11px;
  line-height: 1;
}
.task-record-table .table-actions {
  flex-wrap: nowrap;
  min-width: 136px;
  gap: 4px;
}
.task-record-table .table-actions button,
.task-record-table button.ghost {
  height: 22px;
  padding: 0 6px;
  font-size: 11px;
  line-height: 1;
}
.prompt-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  margin-top: 12px;
}
.prompt-admin-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.prompt-admin-card strong {
  display: block;
  color: #111827;
  font-weight: 950;
}
.prompt-admin-card small {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
}
.prompt-admin-card p {
  display: -webkit-box;
  overflow: hidden;
  min-height: 58px;
  margin: 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}
.prompt-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.prompt-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
}
.list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.provider-config {
  display: grid;
  gap: 8px;
  margin: 0 0 12px;
}
.provider-config > div {
  padding: 10px 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.provider-config strong {
  display: block;
  margin-bottom: 4px;
}
.provider-config small {
  display: block;
  color: #64748b;
  line-height: 1.55;
}
.panel-title-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}
.panel-title-row h2 {
  margin: 0;
}
.finance-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}
.finance-summary div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.finance-summary span {
  display: block;
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.finance-summary strong {
  display: block;
  margin-top: 5px;
  font-size: 18px;
}
.report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.report-grid h3 {
  margin: 0 0 8px;
  font-size: 14px;
}
.admin-stats {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.admin-stats div {
  min-height: 60px;
  padding: 10px 12px;
}
.admin-command-center {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 10px;
  margin-bottom: 10px;
}
.admin-command-main,
.admin-command-side {
  min-width: 0;
}
.admin-command-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}
.admin-command-metrics div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.admin-command-metrics span,
.admin-command-metrics small {
  display: block;
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-command-metrics strong {
  display: block;
  margin: 5px 0 3px;
  color: #050505;
  font-size: 22px;
  line-height: 1;
}
.admin-command-metrics b {
  font: inherit;
}
.admin-todo-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.admin-todo-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  align-content: center;
  height: auto;
  min-height: 64px;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  text-align: left;
}
.admin-todo-item span,
.admin-todo-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-todo-item span {
  font-weight: 900;
}
.admin-todo-item strong {
  color: #0f7bff;
}
.admin-todo-item small {
  grid-column: 1 / -1;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}
.admin-todo-item.danger {
  border-color: #fecaca;
  background: #fff7f7;
}
.admin-todo-item.danger strong {
  color: #b42318;
}
.admin-empty-todo {
  grid-column: 1 / -1;
  padding: 12px;
  border: 1px dashed #d9e1ec;
  border-radius: 8px;
  color: #64748b;
  background: #fbfdff;
  font-weight: 800;
}
.admin-shortcut-grid {
  display: grid;
  gap: 8px;
}
.admin-shortcut-grid button {
  justify-content: space-between;
  width: 100%;
}
.admin-module-nav {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
  padding: 8px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.admin-module-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.admin-module-links button {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}
.admin-module-links button.active {
  color: #0f172a;
  border-color: #bfd7ff;
  background: #eff6ff;
  box-shadow: inset 0 0 0 1px #dbeafe;
}
.admin-filter-scope {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.admin-filter-scope span {
  overflow: hidden;
  max-width: 360px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-filter-scope button {
  height: 28px;
  padding: 0 8px;
  font-size: 11px;
}
.admin-user-lookup {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
}
.admin-user-lookup input {
  height: 34px;
}
.admin-user-quick-result {
  display: grid;
  gap: 6px;
}
.admin-selected-user {
  display: grid;
  gap: 3px;
  padding: 8px;
  border: 1px solid #b8d9ff;
  border-radius: 8px;
  background: #eef6ff;
}
.admin-selected-user span {
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
}
.admin-selected-user strong {
  overflow: hidden;
  color: #0f7bff;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-selected-user small {
  overflow: hidden;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-selected-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}
.admin-selected-metrics b {
  overflow: hidden;
  padding: 4px 5px;
  border: 1px solid #dbeafe;
  border-radius: 6px;
  background: #fff;
  color: #334155;
  font-size: 11px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-selected-actions {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 5px;
}
.admin-selected-actions button {
  min-width: 0;
  height: 26px;
  padding: 0 5px;
  font-size: 11px;
}
.admin-user-hit {
  display: grid;
  justify-items: start;
  gap: 2px;
  height: auto;
  min-height: 42px;
  padding: 7px 8px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  text-align: left;
}
.admin-user-hit.active {
  border-color: #b8d9ff;
  background: #f8fbff;
}
.admin-user-hit span,
.admin-user-hit small {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-user-hit span {
  font-weight: 900;
}
.admin-user-hit small {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}
.admin-user-filter-link {
  display: grid;
  justify-items: start;
  gap: 1px;
  width: 100%;
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: #0f7bff;
  text-align: left;
}
.admin-user-filter-link:hover {
  color: #075fbf;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.admin-user-filter-link.disabled {
  color: #64748b;
}
.admin-user-filter-link strong,
.admin-user-filter-link small {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-user-filter-link strong {
  font-size: 12px;
  font-weight: 900;
}
.admin-user-filter-link small {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}
.mini-list {
  display: grid;
  gap: 8px;
}
.mini-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 10px;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.mini-row span {
  overflow: hidden;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 850;
}
.mini-row strong {
  color: #0f7bff;
}
.mini-row small {
  grid-column: 1 / -1;
  overflow: hidden;
  color: #64748b;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.alert-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.balance-alert-tools {
  display: grid;
  grid-template-columns: 180px auto;
  gap: 8px;
  margin-bottom: 10px;
  max-width: 320px;
}
.alert-summary button {
  height: 34px;
  padding: 0 10px;
  font-size: 12px;
}
.summary-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
  color: #475569;
  font-size: 12px;
  font-weight: 850;
}
.alert-row small { overflow-wrap: anywhere; white-space: normal; }
.mini-actions {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-self: end;
}
.mini-action {
  height: 30px;
  padding: 0 10px;
  font-size: 12px;
}
.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
}
.category-tabs button {
  height: 34px;
  color: #475569;
  border: 1px solid #dbe4ef;
  background: #fff;
}
.category-tabs button.active {
  color: #0f7bff;
  border-color: #b8d9ff;
  background: #eef6ff;
}
.product-market-hero {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 44px 18px 36px;
  margin: -6px -4px 18px;
  text-align: center;
}
.product-market-hero span {
  color: #71717a;
  font-weight: 900;
}
.product-market-hero h2 {
  margin: 0;
  font-size: 44px;
  line-height: 1.05;
}
.product-market-hero p {
  max-width: 620px;
  color: #71717a;
  font-weight: 700;
}
.market-summary {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.market-summary span {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  color: #52525b;
  background: #fff;
  font-size: 12px;
  font-weight: 900;
}
.market-summary strong {
  color: #111827;
}
.market-search {
  display: flex;
  align-items: center;
  width: min(660px, 100%);
  height: 46px;
  padding: 0 18px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  color: #a1a1aa;
  background: #fff;
  text-align: left;
  font-weight: 800;
}
.market-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 16px;
}
.market-filter,
.market-results {
  min-width: 0;
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.vertical-tabs {
  display: grid;
  gap: 8px;
}
.vertical-tabs button {
  justify-content: space-between;
  width: 100%;
  cursor: pointer;
  user-select: none;
  touch-action: manipulation;
}
.vertical-tabs button span,
.vertical-tabs button b {
  pointer-events: none;
}
.vertical-tabs button b {
  color: inherit;
  font-size: 12px;
}
.market-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 42px;
  padding-bottom: 12px;
  border-bottom: 1px solid #ececec;
}
.market-sort {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.market-sort span {
  padding: 6px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  color: #52525b;
  font-size: 12px;
  font-weight: 900;
}
.product-market-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}
.market-card {
  display: grid;
  gap: 16px;
  min-height: 210px;
  padding: 18px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.market-card-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.market-card-head strong,
.market-card-head small {
  display: block;
}
.market-card-head strong {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  font-size: 18px;
  overflow-wrap: anywhere;
}
.market-model-count {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  color: #0f766e;
  background: #f0fdfa;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}
.market-card-head small {
  margin-top: 4px;
  color: #71717a;
  font-weight: 700;
}
.product-mark {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  color: #047857;
  background: #dff8ec;
  font-size: 13px;
  font-weight: 950;
}
.market-price span,
.market-price small {
  display: block;
  color: #71717a;
  font-weight: 800;
}
.market-price strong {
  display: block;
  margin: 4px 0;
  font-size: 28px;
}
.market-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: end;
  margin-top: auto;
}
.market-meta span {
  padding: 4px 8px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  color: #52525b;
  font-size: 12px;
  font-weight: 900;
}
.market-meta span.success {
  border-color: #bbf7d0;
  color: #047857;
  background: #f0fdf4;
}
.market-meta span.muted {
  color: #71717a;
  background: #f4f4f5;
}
.market-endpoint {
  overflow: hidden;
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  color: #334155;
  background: #fafafa;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.market-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.market-actions button {
  flex: 1 1 0;
  min-width: 0;
  height: 34px;
  padding: 0 12px;
  font-size: 12px;
  white-space: nowrap;
}
.analytics-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}
.analytics-toolbar h2,
.analytics-toolbar p {
  margin: 0;
}
.analytics-toolbar p {
  margin-top: 6px;
}
.usage-bars {
  display: flex;
  gap: 18px;
  align-items: end;
  min-height: 250px;
  overflow-x: auto;
  padding: 16px 10px 4px;
  border-top: 1px solid #ececec;
}
.usage-bar {
  display: grid;
  justify-items: center;
  gap: 7px;
  min-width: 92px;
}
.usage-bar-track {
  display: flex;
  align-items: end;
  justify-content: center;
  width: 52px;
  height: 190px;
  border-bottom: 1px solid #d4d4d8;
}
.usage-bar-track span {
  display: block;
  width: 38px;
  border-radius: 4px 4px 0 0;
  background: #0f9f8f;
}
.usage-bar strong {
  color: #111827;
}
.usage-bar small {
  overflow: hidden;
  max-width: 90px;
  color: #71717a;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 800;
}
.docs-layout {
  display: grid;
  grid-template-columns: minmax(280px, .9fr) minmax(0, 1.1fr);
  gap: 16px;
  align-items: start;
}
.docs-compact-layout {
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
}
.docs-compact-layout .examples-panel,
.docs-compact-layout .sdk-panel {
  grid-column: 1 / -1;
}
.docs-compact-layout .docs-notes {
  grid-column: auto;
}
.docs-layout .docs-notes {
  grid-column: 1 / -1;
}
.docs-layout.docs-compact-layout .docs-notes {
  grid-column: auto;
}
.docs-layout .sdk-panel {
  grid-column: 1 / -1;
}
.docs-intro {
  display: grid;
  gap: 14px;
}
.docs-overview-grid {
  display: grid;
  grid-template-columns: minmax(260px, .85fr) minmax(340px, 1.15fr);
  gap: 8px;
  align-items: start;
}
.docs-overview-grid .doc-detail-grid {
  grid-column: 1 / -1;
}
.endpoint-strip {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  align-items: center;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fafafa;
}
.endpoint-strip span,
.endpoint-strip strong {
  min-height: 42px;
  padding: 11px 12px;
}
.endpoint-strip span {
  color: #047857;
  border-right: 1px solid #e5e7eb;
  font-weight: 950;
  text-align: center;
}
.endpoint-strip strong {
  overflow: hidden;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.doc-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.doc-detail-grid div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.doc-detail-grid span,
.doc-detail-grid strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.doc-detail-grid span {
  color: #64748b;
  font-size: 12px;
  font-weight: 850;
}
.doc-detail-grid strong {
  margin-top: 5px;
  font-size: 14px;
}
.sdk-grid,
.docs-reference-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.sdk-grid > div {
  min-width: 0;
}
.sdk-grid span {
  display: block;
  margin-bottom: 8px;
  color: #475569;
  font-size: 12px;
  font-weight: 900;
}
.sdk-grid pre,
.docs-reference-grid pre {
  min-height: 260px;
  margin: 0;
}
.sdk-grid pre {
  min-height: 190px;
  max-height: 220px;
  overflow: auto;
}
.docs-reference-grid h3 {
  margin: 0 0 8px;
  font-size: 14px;
}
.mode-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.mode-grid div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.mode-grid span,
.mode-grid strong,
.mode-grid small,
.doc-code-card > span {
  display: block;
}
.mode-grid span,
.doc-code-card > span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}
.mode-grid strong {
  margin: 4px 0;
  color: #111827;
  font-size: 14px;
}
.mode-grid small {
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
}
.doc-code-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.doc-code-card {
  min-width: 0;
}
.doc-code-card > span {
  margin-bottom: 6px;
}
.doc-code-card pre {
  min-height: 166px;
  max-height: 230px;
  margin: 0;
  overflow: auto;
}
.doc-code-card.wide {
  grid-column: 1 / -1;
}
.doc-code-card.wide pre {
  min-height: 150px;
  max-height: 220px;
}
.create-product {
  display: grid;
  grid-template-columns: 1fr 1fr .85fr .75fr .75fr .75fr 1fr 92px;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.create-user {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr .7fr .8fr .8fr 86px;
  gap: 8px;
  margin-bottom: 8px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.create-user-options {
  display: grid;
  grid-template-columns: 220px minmax(180px, 1fr) minmax(220px, 1.1fr) minmax(140px, .7fr);
  gap: 8px;
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fcfcfd;
}
.create-user-options .switch-line {
  min-height: 34px;
  margin: 0;
}
.recharge-form {
  display: grid;
  grid-template-columns: .65fr .75fr .9fr 1.05fr 1.1fr 92px;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.admin-key-create-form {
  display: grid;
  grid-template-columns: .65fr 1fr .95fr 1.1fr .7fr .75fr 110px;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.pricing-form {
  display: grid;
  grid-template-columns: .65fr 1.35fr .85fr .65fr 1fr 1fr 92px;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.access-form {
  display: grid;
  grid-template-columns: .65fr 1.35fr .65fr 1fr 1fr 92px;
  gap: 8px;
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.secret-grid, .filter-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}
.filter-bar {
  grid-template-columns: minmax(180px, 1fr) minmax(100px, .6fr) minmax(130px, .7fr) minmax(140px, .7fr) auto auto;
  margin-bottom: 10px;
}
.row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fbfdff;
}
.api-key-row {
  grid-template-columns: minmax(0, 1fr);
}
.api-key-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr .7fr 1.15fr .8fr 1.1fr .75fr;
  gap: 8px;
  align-items: end;
}
.api-key-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.api-key-grid label span {
  color: #71717a;
  font-size: 12px;
  font-weight: 900;
}
.api-key-grid label strong {
  display: flex;
  align-items: center;
  min-height: 38px;
  overflow: hidden;
  padding: 0 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.api-key-detail {
  display: grid;
  grid-template-columns: minmax(220px, .7fr) minmax(260px, 1fr) minmax(220px, 1fr);
  gap: 8px;
  align-items: start;
  margin-top: 8px;
}
.api-key-detail small {
  margin-top: 0;
}
.api-key-row .row-actions {
  justify-content: flex-start;
  padding-top: 8px;
  border-top: 1px solid #edf2f7;
}
.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(15, 23, 42, .38);
}
.modal-layer[hidden] {
  display: none;
}
.admin-modal-backdrop {
  z-index: 24;
}
.admin-title-actions,
.admin-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.admin-form-modal {
  display: none !important;
}
.admin-form-modal.is-open {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 25;
  display: grid !important;
  width: min(760px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow: auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 60px rgba(15, 23, 42, .24);
  transform: translate(-50%, -50%);
}
.admin-form-modal.is-open .admin-modal-head,
.admin-form-modal.is-open .modal-actions,
.admin-form-modal.is-open .admin-advanced-field,
.admin-form-modal.is-open .admin-scope-field,
.admin-form-modal.is-open .admin-key-group-presets,
.admin-form-modal.is-open .create-user,
.admin-form-modal.is-open .create-user-options,
.admin-form-modal.is-open .inline {
  grid-column: 1 / -1;
}
.admin-form-modal.is-open .create-user,
.admin-form-modal.is-open .create-user-options,
.admin-form-modal.is-open .inline {
  display: grid;
  gap: 8px;
}
.admin-form-modal.is-open .create-user {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.admin-form-modal.is-open .create-user-options {
  grid-template-columns: minmax(190px, 1fr) repeat(3, minmax(0, 1fr));
}
.admin-form-modal.is-open .create-user-options .admin-scope-field {
  grid-column: 1 / -1;
}
.admin-form-modal.is-open .inline {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.admin-form-modal.is-open label {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.admin-form-modal.is-open label span {
  color: #475569;
  font-size: 11px;
  font-weight: 900;
}
.admin-advanced-field {
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 7px;
  background: #f8fafc;
}
.admin-advanced-field summary {
  cursor: pointer;
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.admin-advanced-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.admin-preset-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.admin-preset-actions button {
  height: 28px;
  padding: 0 9px;
  border-radius: 7px;
  font-size: 12px;
}
.admin-scope-field {
  display: grid;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 7px;
  background: #f8fafc;
}
.admin-scope-field > span {
  color: #475569;
  font-size: 11px;
  font-weight: 900;
}
.admin-form-modal.is-open .modal-scope-grid label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}
.admin-form-modal.is-open .modal-scope-grid input[type="checkbox"] {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
}
.admin-advanced-field textarea,
.admin-advanced-field > label {
  margin-top: 8px;
}
.admin-form-modal.is-open.admin-api-key-edit {
  width: min(820px, calc(100vw - 32px));
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.admin-form-modal.is-open.admin-filter-modal {
  width: min(860px, calc(100vw - 32px));
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.admin-form-modal.is-open.admin-action-modal {
  width: min(560px, calc(100vw - 32px));
  grid-template-columns: 1fr;
}
.admin-form-modal.is-open input,
.admin-form-modal.is-open select,
.admin-form-modal.is-open textarea {
  width: 100%;
}
.admin-modal-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 2px;
}
.admin-action-summary {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 7px;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
}
.admin-action-summary strong {
  color: #0f172a;
  font-size: 14px;
}
.admin-action-summary small {
  color: #64748b;
  line-height: 1.45;
}
.admin-action-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.admin-action-grid button {
  width: 100%;
  min-height: 34px;
  white-space: normal;
}
.admin-form-modal.is-open button.danger,
.admin-form-modal.is-open .ghost.danger {
  border-color: #fecaca;
  background: #fff5f5;
  color: #b42318;
}
.admin-modal-head h2 {
  margin: 0 0 3px;
  font-size: 16px;
}
.admin-filter-open-btn {
  height: 30px;
  padding: 0 10px;
  border-radius: 7px;
  font-size: 12px;
}
.modal-card {
  width: min(760px, 100%);
  max-height: calc(100vh - 36px);
  overflow: auto;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 60px rgba(15, 23, 42, .22);
}
.modal-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 10px;
}
.modal-head h2 {
  margin-bottom: 4px;
}
.modal-close {
  flex: 0 0 auto;
}
.key-modal-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.key-modal-form.single {
  grid-template-columns: minmax(0, 1fr);
}
.key-modal-form label,
.modal-section {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.key-modal-form label span,
.modal-section > span {
  color: #475569;
  font-size: 11px;
  font-weight: 900;
}
.switch-line {
  min-height: 32px;
  grid-auto-flow: column;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  padding: 0 8px;
  border: 1px solid #e5e7eb;
  border-radius: 7px;
  background: #fbfdff;
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}
.switch-line input {
  width: 15px;
  height: 15px;
}
.modal-section {
  margin: 10px 0 8px;
}
.modal-scope-grid {
  margin: 0;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #edf2f7;
}
.profile-hero {
  display: flex;
  gap: 18px;
  align-items: center;
  padding: 22px;
  margin-bottom: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.profile-avatar {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: #e4e4e7;
  color: #111;
  font-weight: 950;
}
.profile-hero h2,
.profile-hero p {
  margin: 0;
}
.profile-hero p {
  margin-top: 8px;
  color: #71717a;
  font-weight: 700;
}
.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 16px;
}
.profile-summary-card {
  overflow: hidden;
  margin-bottom: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.profile-identity {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid #ececec;
}
.profile-name-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.profile-name-line h2,
.profile-card-title h2 {
  margin: 0;
}
.profile-name-line span {
  color: #52525b;
  font-size: 12px;
  font-weight: 900;
}
.profile-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.profile-metrics div {
  padding: 14px 16px;
  border-right: 1px solid #ececec;
}
.profile-metrics div:last-child {
  border-right: 0;
}
.profile-metrics span,
.profile-metrics small,
.profile-setting-row small,
.profile-security-item small {
  display: block;
  color: #71717a;
  font-weight: 700;
}
.profile-metrics span {
  font-size: 12px;
}
.profile-metrics strong {
  display: block;
  margin: 5px 0 3px;
  color: #050505;
  font-size: 26px;
  line-height: 1;
}
.profile-metrics b {
  font: inherit;
}
.profile-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, .95fr);
  gap: 10px;
  margin-bottom: 10px;
}
.profile-card-title {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}
.profile-card-icon,
.profile-row-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 8px;
  background: #f4f4f5;
  color: #111;
  font-weight: 950;
}
.profile-card-icon {
  width: 34px;
  height: 34px;
}
.profile-row-icon {
  width: 36px;
  height: 36px;
}
.profile-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  margin-bottom: 12px;
  border-radius: 8px;
  background: #f4f4f5;
}
.profile-tabs button {
  height: 34px;
  border: 0;
  color: #52525b;
  background: transparent;
  font-weight: 900;
}
.profile-tabs button.active {
  border: 1px solid #e5e7eb;
  color: #111827;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
}
.profile-pane {
  display: grid;
  gap: 8px;
}
.profile-setting-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 58px;
  padding: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fcfcfd;
}
.profile-setting-row strong,
.profile-security-item strong {
  display: block;
  color: #111827;
}
.profile-setting-row select {
  width: 140px;
  height: 32px;
}
.status-dot {
  color: #52525b;
  font-size: 12px;
}
.status-dot.success {
  color: #059669;
}
.profile-shortcuts {
  display: grid;
  gap: 8px;
}
.profile-shortcuts button {
  justify-content: space-between;
  width: 100%;
}
.profile-security-card {
  margin-top: 0;
}
.profile-security-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(160px, 1fr));
  gap: 10px;
}
.profile-security-item {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  min-height: 118px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  text-align: center;
}
button.profile-security-item {
  height: auto;
}
.profile-security-item.disabled {
  color: #71717a;
  background: #fafafa;
  opacity: 1;
}
.password-item {
  grid-template-columns: 36px minmax(0, 1fr);
  justify-items: stretch;
  align-content: start;
  text-align: left;
}
.profile-password-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 76px;
  gap: 8px;
  margin-top: 10px;
}
.profile-password-form input,
.profile-password-form button {
  height: 34px;
}
.profile-password-open {
  width: fit-content;
  height: 30px;
  margin-top: 10px;
  padding: 0 12px;
  border-radius: 7px;
  font-size: 12px;
}
.profile-password-form.admin-form-modal.is-open {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: min(520px, calc(100vw - 32px));
  margin-top: 0;
}
.row strong { overflow-wrap: anywhere; }
.row small { display: block; color: #64748b; margin-top: 4px; overflow-wrap: anywhere; }
.row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  align-items: center;
}
.row-actions button {
  height: 32px;
  padding: 0 10px;
  font-size: 12px;
}
.product-row {
  grid-template-columns: minmax(0, 1fr) 90px;
}
.product-row > small {
  grid-column: 1 / -1;
  margin-top: -4px;
}
.product-row .compact-actions {
  grid-column: 1 / -1;
  justify-content: flex-start;
  gap: 6px;
  margin-top: -2px;
}
.route-list {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid #edf2f7;
}
.route-row {
  display: grid;
  grid-template-columns: minmax(150px, 1.1fr) minmax(100px, .7fr) minmax(140px, 1fr) repeat(4, minmax(92px, .62fr)) minmax(180px, 1.2fr) 88px;
  gap: 8px;
  align-items: end;
  padding: 8px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
}
.route-row label {
  display: grid;
  gap: 4px;
  min-width: 0;
}
.route-row label span {
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
}
.route-row .route-config-field textarea {
  min-height: 30px;
  resize: vertical;
}
.route-row-actions {
  display: flex;
  align-items: end;
}
.product-edit-grid {
  display: grid;
  grid-template-columns: 1.3fr .75fr .75fr .7fr .7fr .7fr;
  gap: 8px;
}
.product-edit-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.product-edit-grid label span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}
.price-edit-grid {
  display: grid;
  grid-template-columns: 110px 88px 165px minmax(160px, 1fr) 72px;
  gap: 8px;
  margin-top: 8px;
  max-width: 820px;
}
.access-edit-grid {
  display: grid;
  grid-template-columns: 100px 165px minmax(160px, 1fr) 72px;
  gap: 8px;
  margin-top: 8px;
  max-width: 700px;
}
.recharge-edit-grid {
  display: grid;
  grid-template-columns: 110px minmax(120px, 150px) minmax(160px, 1fr) minmax(160px, 1fr) 86px;
  gap: 8px;
  margin-top: 8px;
  max-width: 820px;
}
.danger-text { color: #b42318 !important; }
.success-text { color: #047857 !important; }
.warning-text { color: #b7791f !important; }
.user-actions {
  display: grid;
  grid-template-columns: auto 64px 90px 84px 72px 90px;
  gap: 8px;
  align-items: center;
}
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 999px;
  color: #0f7bff;
  background: #eef6ff;
  font-size: 12px;
  font-weight: 900;
}
.badge.muted {
  margin-right: 6px;
  color: #475569;
  background: #eef2f7;
}
.badge.success {
  color: #047857;
  background: #dff8ec;
}
.badge.warning {
  color: #9a5b00;
  background: #fff4d6;
}
.badge.danger {
  color: #b42318;
  background: #ffe4e2;
}

/* Compact density pass */
body {
  font-size: 13px;
}
button,
input,
select {
  height: 32px;
  border-radius: 7px;
  font-size: 12px;
}
button {
  padding: 0 10px;
}
input,
select {
  padding: 0 9px;
}
textarea {
  min-height: 72px;
  padding: 8px 9px;
  border-radius: 7px;
  font-size: 12px;
}
pre {
  padding: 9px;
  border-radius: 7px;
  font-size: 11px;
  line-height: 1.45;
}
.shell {
  grid-template-columns: 204px minmax(0, 1fr);
}
.sidebar {
  padding: 12px 12px;
}
.brand {
  gap: 8px;
  margin-bottom: 16px;
}
.brand span {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  font-size: 12px;
}
.brand strong {
  font-size: 14px;
}
nav {
  gap: 3px;
}
.nav-section {
  margin: 12px 8px 4px;
  font-size: 11px;
}
nav button {
  height: 32px;
  gap: 8px;
  padding: 0 10px;
  border-radius: 7px;
  font-size: 13px;
}
.content {
  padding: 0 8px 12px;
}
.app-header {
  min-height: 48px;
  gap: 10px;
  padding: 4px 0;
}
.top-links {
  gap: 4px;
}
.top-link {
  height: 30px;
  padding: 0 9px;
  font-size: 12px;
}
.header-tools {
  gap: 6px;
}
.search-box {
  width: min(300px, 28vw);
  height: 32px;
  padding: 0 10px;
  font-size: 12px;
}
.icon-btn {
  min-width: 48px;
}
.page-shell {
  min-height: calc(100vh - 58px);
  padding: 12px;
  border-radius: 7px;
  box-shadow: 0 6px 16px rgba(15, 23, 42, .045);
}
.page-heading {
  gap: 10px;
  margin-bottom: 10px;
}
.page-heading h1 {
  margin-bottom: 3px;
  font-size: 18px;
}
h2 {
  margin-bottom: 10px;
  font-size: 16px;
}
h3 {
  font-size: 13px;
}
.auth-panel {
  gap: 16px;
}
.auth-view .auth-panel {
  gap: 24px;
}
.auth-view .content {
  padding: 24px;
}
.auth-panel h1 {
  font-size: 26px;
}
.auth-copy .auth-brand {
  margin-bottom: 14px;
}
.auth-meta {
  gap: 6px;
  margin-top: 12px;
}
.auth-meta span {
  padding: 4px 7px;
  font-size: 11px;
}
.auth-card,
.panel {
  border-radius: 7px;
}
.auth-card,
.panel {
  padding: 12px;
}
.panel {
  margin-bottom: 10px;
}
.actions,
.inline {
  gap: 6px;
}
.inline button {
  min-width: 72px;
}
.scope-grid {
  gap: 6px;
  margin: 6px 0;
}
.compact-textarea,
.spaced-input {
  margin-top: 6px;
}
.topbar {
  gap: 10px;
  margin-bottom: 10px;
}
.stats {
  margin-bottom: 10px;
  border-radius: 7px;
}
.stats div {
  padding: 12px 14px;
}
.stats span {
  font-size: 11px;
}
.stats strong {
  margin-top: 4px;
  font-size: 22px;
}
.compact-stats strong {
  font-size: 18px;
}
.analytics-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.analytics-stats div {
  min-height: 60px;
  padding: 10px 14px;
}
.setup-strip {
  min-height: 54px;
  gap: 10px;
  padding: 10px 12px;
  margin-bottom: 10px;
}
.dashboard-guide-strip {
  gap: 10px;
  padding: 10px 12px;
  margin-bottom: 10px;
  border-radius: 7px;
}
.dashboard-usage-panel {
  margin-bottom: 10px;
  border-radius: 7px;
}
.dashboard-usage-main {
  padding: 12px;
}
.dashboard-metric-grid,
.dashboard-card-grid {
  gap: 8px;
}
.usage-metric-card {
  padding: 10px;
  border-radius: 7px;
}
.usage-metric-card strong {
  font-size: 24px;
}
.balance-card {
  gap: 10px;
  padding: 14px;
}
.balance-card > strong {
  font-size: 30px;
}
.empty-state {
  min-height: 94px;
}
.onboarding-guide {
  margin-top: 10px;
  border-radius: 7px;
}
.onboarding-guide > summary {
  padding: 10px 12px;
}
.setup-check {
  width: 30px;
  height: 30px;
}
.setup-strip small,
.quickstart-step small,
.config-stack small,
.row small {
  margin-top: 2px;
  font-size: 11px;
}
.overview-grid,
.profile-grid,
.docs-layout,
.market-layout {
  gap: 10px;
}
.quickstart-list,
.config-stack,
.list,
.provider-config,
.route-list {
  gap: 6px;
}
.quickstart-step,
.config-stack div,
.mini-row,
.row,
.provider-config > div,
.doc-detail-grid div,
.finance-summary div,
.wallet-summary div {
  padding: 8px;
  border-radius: 7px;
}
.quickstart-step {
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px;
}
.quickstart-step > span {
  width: 24px;
  height: 24px;
}
.wallet-summary,
.test-summary,
.finance-summary,
.admin-command-metrics,
.admin-todo-list,
.doc-detail-grid,
.sdk-grid,
.docs-reference-grid,
.product-market-grid,
.prompt-admin-grid {
  gap: 8px;
}
.admin-command-metrics div,
.admin-todo-item {
  padding: 8px;
  border-radius: 7px;
}
.admin-command-metrics strong {
  font-size: 18px;
}
.admin-todo-item {
  min-height: 56px;
}
.wallet-summary strong,
.test-summary strong {
  font-size: 13px;
}
.test-summary {
  margin-bottom: 8px;
}
.test-summary div {
  padding: 8px;
}
.test-actions,
.new-key-actions {
  gap: 6px;
  margin: -4px 0 8px;
}
.test-actions button,
.new-key-actions button,
.key-list-filters button,
.log-list-filters button,
.market-actions button,
.row-actions button,
.mini-actions button,
.pagination-bar button {
  height: 28px;
  padding: 0 8px;
  font-size: 11px;
}
.key-list-tools,
.log-list-tools {
  gap: 8px;
  margin: 8px 0;
  padding-top: 8px;
}
.key-list-stats,
.key-list-filters,
.log-list-stats,
.log-list-filters {
  gap: 6px;
}
.key-list-stats span,
.log-list-stats span,
.market-summary span,
.pagination-bar,
.pagination-bar select {
  min-height: 28px;
  font-size: 11px;
}
.key-list-stats span,
.log-list-stats span,
.market-summary span {
  padding: 0 8px;
  border-radius: 7px;
}
.pagination-bar {
  gap: 6px;
  min-height: 34px;
  margin-top: 8px;
  padding-top: 8px;
}
.pagination-bar select {
  height: 28px;
  min-width: 92px;
}
.usage-log-table th,
.usage-log-table td {
  padding: 8px 10px;
}
.usage-log-table strong {
  font-size: 12px;
}
.usage-log-table small {
  margin-top: 3px;
  font-size: 11px;
}
.key-group-pill,
.duration-pill {
  min-height: 24px;
  padding: 0 8px;
  font-size: 12px;
}
.table-actions {
  gap: 4px;
}
.table-actions button {
  height: 24px;
  padding: 0 7px;
  font-size: 11px;
}
.api-key-table th,
.api-key-table td {
  padding: 7px 8px;
}
.api-key-table code,
.status-pill {
  min-height: 22px;
  font-size: 11px;
}
.modal-card {
  padding: 12px;
}
.key-modal-form {
  gap: 6px;
}
.modal-section {
  margin: 8px 0 6px;
}
.modal-actions {
  gap: 6px;
  margin-top: 8px;
  padding-top: 8px;
}
.prompt-admin-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.prompt-admin-card {
  gap: 7px;
  padding: 10px;
  border-radius: 7px;
}
.prompt-admin-card p {
  min-height: 44px;
  font-size: 12px;
  line-height: 1.4;
}
.prompt-tags {
  gap: 4px;
}
.prompt-tags span {
  min-height: 20px;
  padding: 0 7px;
  font-size: 11px;
}
.panel-title-row {
  gap: 8px;
  margin-bottom: 6px;
}
.balance-alert-tools button,
.alert-actions button {
  height: 28px;
  font-size: 11px;
}
.product-market-hero {
  gap: 8px;
  padding: 22px 14px 18px;
  margin: -2px 0 10px;
}
.product-market-hero h2 {
  font-size: 30px;
}
.product-market-hero p {
  max-width: 620px;
  font-size: 13px;
}
.market-search {
  height: 34px;
  padding: 0 12px;
}
.market-filter,
.market-results {
  padding: 10px;
}
.market-toolbar {
  gap: 8px;
  min-height: 32px;
}
.market-sort span,
.market-meta span,
.market-endpoint {
  padding: 3px 7px;
  font-size: 11px;
}
.market-card {
  gap: 10px;
  min-height: 158px;
  padding: 12px;
}
.market-card-head {
  gap: 8px;
}
.market-card-head strong {
  font-size: 15px;
}
.market-card-head small,
.market-price span,
.market-price small {
  font-size: 11px;
}
.market-price strong {
  margin: 2px 0;
  font-size: 20px;
}
.product-mark {
  width: 34px;
  height: 34px;
  font-size: 12px;
}
.analytics-toolbar {
  gap: 10px;
}
.usage-bars {
  min-height: 190px;
  padding: 10px 8px 2px;
}
.usage-bar-track {
  height: 145px;
}
.docs-layout {
  grid-template-columns: minmax(250px, .85fr) minmax(0, 1.15fr);
}
.docs-layout.docs-compact-layout {
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
}
.docs-intro {
  gap: 10px;
}
.endpoint-strip {
  min-height: 34px;
  padding: 8px 10px;
}
.doc-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.docs-reference-grid pre {
  min-height: 180px;
}
.sdk-grid pre,
.docs-reference-grid pre {
  max-height: 220px;
}
.doc-code-grid,
.mode-grid,
.docs-overview-grid {
  gap: 6px;
}
.mode-grid div {
  padding: 8px;
  border-radius: 7px;
}
.doc-code-card pre {
  min-height: 138px;
  max-height: 190px;
}
.doc-code-card.wide pre {
  min-height: 132px;
  max-height: 180px;
}
.create-product,
.create-user,
.recharge-form,
.pricing-form,
.access-form,
.price-edit-grid,
.access-edit-grid,
.recharge-edit-grid {
  gap: 6px;
  padding: 8px;
}
.filter-bar {
  gap: 6px;
  margin-bottom: 8px;
}
.row {
  gap: 8px;
}
.row strong {
  font-size: 13px;
}
.row-actions {
  gap: 5px;
}
.api-key-grid {
  gap: 6px;
}
.api-key-grid label {
  gap: 3px;
}
.api-key-grid label span {
  font-size: 11px;
}
.api-key-grid label strong {
  min-height: 32px;
  padding: 0 8px;
  border-radius: 7px;
}
.api-key-detail {
  gap: 6px;
  margin-top: 6px;
}
.api-key-row .row-actions {
  padding-top: 6px;
}
.profile-hero {
  gap: 12px;
  padding: 14px;
  margin-bottom: 10px;
}
.profile-avatar {
  width: 50px;
  height: 50px;
}
.profile-hero h2 {
  font-size: 18px;
}
.profile-summary-card,
.profile-settings-card,
.profile-quick-card,
.profile-security-card {
  border-radius: 7px;
}
.profile-identity {
  padding: 12px;
}
.profile-metrics div {
  padding: 10px 12px;
}
.profile-metrics strong {
  font-size: 22px;
}
.profile-main-grid {
  gap: 8px;
}
.profile-card-title {
  margin-bottom: 8px;
}
.profile-tabs {
  margin-bottom: 8px;
}
.profile-setting-row {
  min-height: 50px;
  padding: 8px;
}
.profile-security-grid {
  gap: 8px;
}
.profile-security-item {
  min-height: 100px;
  padding: 10px;
}
.profile-password-form input,
.profile-password-form button {
  height: 30px;
}
.route-row,
.product-edit-grid,
.user-actions {
  gap: 6px;
}

#tab-admin {
  --admin-line: #e7edf3;
  --admin-soft: #f8fafc;
  --admin-muted: #64748b;
}
#tab-admin .panel {
  scroll-margin-top: 126px;
  padding: 10px 12px;
  border-color: var(--admin-line);
  background: #fff;
}
#tab-admin .panel > h2,
#tab-admin .panel-title-row h2 {
  margin-bottom: 8px;
  color: #0f172a;
  font-size: 15px;
  line-height: 1.2;
}
#tab-admin .panel-title-row {
  margin-bottom: 8px;
}
#tab-admin .admin-module-nav {
  position: sticky;
  top: 64px;
  z-index: 4;
  margin-bottom: 8px;
  border-color: var(--admin-line);
  box-shadow: 0 6px 18px rgba(15, 23, 42, .04);
}
#tab-admin .admin-command-main,
#tab-admin .admin-command-side {
  padding: 10px;
}
#tab-admin .filter-bar,
#tab-admin .create-product,
#tab-admin .create-user,
#tab-admin .create-user-options,
#tab-admin .recharge-form,
#tab-admin .admin-key-create-form,
#tab-admin .pricing-form,
#tab-admin .access-form {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  padding: 7px;
  margin-bottom: 8px;
  border-color: var(--admin-line);
  background: var(--admin-soft);
}
#tab-admin .filter-bar input,
#tab-admin .filter-bar select,
#tab-admin .create-product input,
#tab-admin .create-product select,
#tab-admin .create-user input,
#tab-admin .create-user select,
#tab-admin .create-user-options input,
#tab-admin .create-user-options select,
#tab-admin .recharge-form input,
#tab-admin .recharge-form select,
#tab-admin .admin-key-create-form input,
#tab-admin .admin-key-create-form select,
#tab-admin .pricing-form input,
#tab-admin .pricing-form select,
#tab-admin .access-form input,
#tab-admin .access-form select {
  flex: 1 1 150px;
  width: auto;
  height: 30px;
  padding: 0 9px;
  border-radius: 7px;
  font-size: 12px;
}
#tab-admin .filter-bar input:first-child,
#tab-admin .create-product input:first-child,
#tab-admin .create-user input:first-child,
#tab-admin .admin-key-create-form input:first-child,
#tab-admin .pricing-form input:first-child,
#tab-admin .access-form input:first-child {
  flex-basis: 220px;
}
#tab-admin .filter-bar button,
#tab-admin .create-product button,
#tab-admin .create-user button,
#tab-admin .recharge-form button,
#tab-admin .admin-key-create-form button,
#tab-admin .pricing-form button,
#tab-admin .access-form button {
  flex: 0 0 auto;
  height: 30px;
  padding: 0 12px;
  border-radius: 7px;
  font-size: 12px;
}
#tab-admin .alert-summary {
  gap: 6px;
  margin-bottom: 8px;
}
#tab-admin .summary-pill {
  min-height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  background: #fff;
  font-size: 12px;
}
#tab-admin .list {
  display: grid;
  gap: 6px;
}
#tab-admin .row {
  gap: 8px;
  padding: 8px 10px;
  border-color: var(--admin-line);
  border-radius: 7px;
  background: #fff;
}
#tab-admin .row:hover {
  background: #fbfdff;
}
#tab-admin .row strong {
  color: #111827;
  font-size: 13px;
}
#tab-admin .row small {
  margin-top: 3px;
  color: var(--admin-muted);
  font-size: 12px;
  line-height: 1.35;
}
#tab-admin .row-actions {
  gap: 5px;
}
#tab-admin .row-actions button {
  height: 28px;
  padding: 0 9px;
  border-radius: 7px;
}
#tab-admin .product-row {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}
#tab-admin .product-row-main {
  min-width: 0;
}
#tab-admin .product-row-main strong {
  display: flex;
  gap: 6px;
  align-items: center;
}
#tab-admin .product-row .compact-actions {
  grid-column: auto;
  justify-content: flex-end;
  min-width: max-content;
  padding-top: 0;
  border-top: 0;
}
#tab-admin .product-edit-grid {
  grid-template-columns: minmax(180px, 1.3fr) repeat(5, minmax(110px, .7fr));
  gap: 6px;
}
#tab-admin .product-edit-grid.admin-form-modal.is-open {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
#tab-admin .product-edit-grid label {
  gap: 3px;
}
#tab-admin .product-edit-grid label span,
#tab-admin .api-key-grid label span {
  color: #71717a;
  font-size: 11px;
}
#tab-admin .product-edit-grid input,
#tab-admin .product-edit-grid select,
#tab-admin .route-row input,
#tab-admin .route-row select,
#tab-admin .route-row textarea {
  height: 30px;
  padding: 0 8px;
  border-radius: 7px;
  font-size: 12px;
}
#tab-admin .route-editor-panel {
  grid-column: 1 / -1;
  border-top: 1px solid var(--admin-line);
}
#tab-admin .route-editor-panel.admin-form-modal.is-open {
  width: min(1100px, calc(100vw - 32px));
  grid-template-columns: 1fr;
  border-top: 0;
}
#tab-admin .route-editor-panel.admin-form-modal.is-open .route-list {
  display: grid;
  gap: 8px;
}
#tab-admin .route-editor-panel summary {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  min-height: 30px;
  padding: 7px 2px 0;
  color: #334155;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
  list-style: none;
}
#tab-admin .route-editor-panel summary::-webkit-details-marker {
  display: none;
}
#tab-admin .route-editor-panel summary::before {
  content: "展开";
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border: 1px solid var(--admin-line);
  border-radius: 999px;
  color: #475569;
  background: #fff;
  font-size: 11px;
}
#tab-admin .route-editor-panel[open] summary::before {
  content: "收起";
}
#tab-admin .route-editor-panel summary span {
  flex: 1 1 auto;
}
#tab-admin .route-editor-panel summary small {
  flex: 0 0 auto;
  margin: 0;
  color: var(--admin-muted);
  font-size: 11px;
  font-weight: 800;
}
#tab-admin .route-list {
  gap: 6px;
  padding-top: 7px;
  border-top: 0;
}
#tab-admin .route-row {
  grid-template-columns: minmax(150px, 1fr) minmax(96px, .65fr) minmax(130px, 1fr) repeat(4, minmax(88px, .58fr)) minmax(170px, 1.1fr) auto;
  gap: 6px;
}
#tab-admin .api-key-row {
  padding: 8px;
}
#tab-admin .api-key-grid {
  gap: 6px;
}
#tab-admin .api-key-detail {
  margin-top: 6px;
}
#tab-admin .mini-list,
#tab-admin .admin-user-quick-result {
  gap: 6px;
}
#tab-admin .mini-row {
  min-height: 42px;
  padding: 7px 9px;
  border-color: var(--admin-line);
  border-radius: 7px;
  background: #fff;
}
#tab-admin .mini-row span,
#tab-admin .mini-row strong {
  font-size: 12px;
  line-height: 1.25;
}
#tab-admin .mini-row small {
  margin-top: 0;
  color: var(--admin-muted);
  font-size: 11px;
  line-height: 1.35;
}
#tab-admin .alert-row small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#tab-admin .mini-actions {
  align-self: center;
  gap: 5px;
}
#tab-admin .mini-action,
#tab-admin .mini-actions button {
  height: 26px;
  padding: 0 8px;
  border-radius: 7px;
  font-size: 11px;
}
#tab-admin .hint {
  margin: 0;
  padding: 8px 9px;
  border: 1px dashed var(--admin-line);
  border-radius: 7px;
  background: #fbfdff;
  font-size: 12px;
}
#tab-admin .usage-log-table-wrap {
  margin-top: 8px;
  border-color: var(--admin-line);
  border-radius: 7px;
}
#tab-admin .usage-log-table {
  min-width: 1040px;
}
#tab-admin .usage-log-table th,
#tab-admin .usage-log-table td {
  padding: 8px 10px;
}
#tab-admin .usage-log-table th {
  font-size: 12px;
}
#tab-admin .usage-log-table small {
  margin-top: 3px;
}
#tab-admin .admin-request-table th:nth-child(1) { width: 18%; }
#tab-admin .admin-request-table th:nth-child(2) { width: 24%; }
#tab-admin .admin-request-table th:nth-child(3) { width: 14%; }
#tab-admin .admin-request-table th:nth-child(4) { width: 15%; }
#tab-admin .admin-request-table th:nth-child(5) { width: 17%; }
#tab-admin .admin-request-table th:nth-child(6) { width: 12%; }
#tab-admin .admin-provider-table th:nth-child(1),
#tab-admin .admin-webhook-table th:nth-child(1) { width: 18%; }
#tab-admin .admin-provider-table th:nth-child(2),
#tab-admin .admin-webhook-table th:nth-child(2) { width: 18%; }
#tab-admin .admin-provider-table th:nth-child(3),
#tab-admin .admin-webhook-table th:nth-child(3) { width: 20%; }
#tab-admin .admin-provider-table th:nth-child(4),
#tab-admin .admin-webhook-table th:nth-child(4) { width: 14%; }
#tab-admin .admin-provider-table th:nth-child(5),
#tab-admin .admin-webhook-table th:nth-child(5) { width: 20%; }
#tab-admin .admin-provider-table th:nth-child(6),
#tab-admin .admin-webhook-table th:nth-child(6) { width: 10%; }
#tab-admin .admin-task-table th:nth-child(1) { width: 18%; }
#tab-admin .admin-task-table th:nth-child(2) { width: 24%; }
#tab-admin .admin-task-table th:nth-child(3) { width: 17%; }
#tab-admin .admin-task-table th:nth-child(4) { width: 17%; }
#tab-admin .admin-task-table th:nth-child(5) { width: 14%; }
#tab-admin .admin-task-table th:nth-child(6) { width: 10%; }
#tab-admin .admin-route-table th:nth-child(1) { width: 24%; }
#tab-admin .admin-route-table th:nth-child(2) { width: 20%; }
#tab-admin .admin-route-table th:nth-child(3) { width: 15%; }
#tab-admin .admin-route-table th:nth-child(4) { width: 14%; }
#tab-admin .admin-route-table th:nth-child(5) { width: 18%; }
#tab-admin .admin-route-table th:nth-child(6) { width: 9%; }
#tab-admin .admin-user-table th:nth-child(1) { width: 22%; }
#tab-admin .admin-user-table th:nth-child(2) { width: 16%; }
#tab-admin .admin-user-table th:nth-child(3) { width: 15%; }
#tab-admin .admin-user-table th:nth-child(4) { width: 17%; }
#tab-admin .admin-user-table th:nth-child(5) { width: 16%; }
#tab-admin .admin-user-table th:nth-child(6) { width: 14%; }
#tab-admin .admin-recharge-table th:nth-child(1) { width: 28%; }
#tab-admin .admin-recharge-table th:nth-child(2) { width: 14%; }
#tab-admin .admin-recharge-table th:nth-child(3) { width: 22%; }
#tab-admin .admin-recharge-table th:nth-child(4) { width: 24%; }
#tab-admin .admin-recharge-table th:nth-child(5) { width: 12%; }
#tab-admin .admin-ledger-table th:nth-child(1) { width: 24%; }
#tab-admin .admin-ledger-table th:nth-child(2) { width: 12%; }
#tab-admin .admin-ledger-table th:nth-child(3) { width: 12%; }
#tab-admin .admin-ledger-table th:nth-child(4) { width: 17%; }
#tab-admin .admin-ledger-table th:nth-child(5) { width: 13%; }
#tab-admin .admin-ledger-table th:nth-child(6) { width: 22%; }
#tab-admin .admin-product-access-table th:nth-child(1),
#tab-admin .admin-user-price-table th:nth-child(1) { width: 20%; }
#tab-admin .admin-product-access-table th:nth-child(2),
#tab-admin .admin-user-price-table th:nth-child(2) { width: 20%; }
#tab-admin .admin-product-access-table th:nth-child(3),
#tab-admin .admin-user-price-table th:nth-child(4) { width: 22%; }
#tab-admin .admin-product-access-table th:nth-child(4) { width: 12%; }
#tab-admin .admin-product-access-table th:nth-child(5) { width: 18%; }
#tab-admin .admin-product-access-table th:nth-child(6) { width: 8%; }
#tab-admin .admin-user-price-table th:nth-child(3) { width: 12%; }
#tab-admin .admin-user-price-table th:nth-child(5) { width: 18%; }
#tab-admin .admin-user-price-table th:nth-child(6) { width: 8%; }
#tab-admin .admin-api-key-table {
  min-width: 1160px;
}
#tab-admin .admin-api-key-table th:nth-child(1) { width: 17%; }
#tab-admin .admin-api-key-table th:nth-child(2) { width: 13%; }
#tab-admin .admin-api-key-table th:nth-child(3) { width: 13%; }
#tab-admin .admin-api-key-table th:nth-child(4) { width: 12%; }
#tab-admin .admin-api-key-table th:nth-child(5) { width: 12%; }
#tab-admin .admin-api-key-table th:nth-child(6) { width: 15%; }
#tab-admin .admin-api-key-table th:nth-child(7) { width: 10%; }
#tab-admin .admin-api-key-table th:nth-child(8) { width: 8%; }
#tab-admin .admin-api-key-table strong,
#tab-admin .admin-api-key-table small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#tab-admin .admin-audit-table th:nth-child(1) { width: 19%; }
#tab-admin .admin-audit-table th:nth-child(2) { width: 14%; }
#tab-admin .admin-audit-table th:nth-child(3) { width: 15%; }
#tab-admin .admin-audit-table th:nth-child(4) { width: 27%; }
#tab-admin .admin-audit-table th:nth-child(5) { width: 15%; }
#tab-admin .admin-audit-table th:nth-child(6) { width: 10%; }
#tab-admin .admin-user-table select,
#tab-admin .admin-user-table input,
#tab-admin .table-edit-grid input,
#tab-admin .admin-product-access-table input,
#tab-admin .admin-product-access-table select,
#tab-admin .admin-user-price-table input,
#tab-admin .admin-user-price-table select,
#tab-admin .admin-api-key-table input,
#tab-admin .admin-api-key-table select,
#tab-admin .admin-api-key-table textarea {
  height: 28px;
  padding: 0 8px;
  border-radius: 7px;
  font-size: 12px;
}
#tab-admin .admin-user-table input {
  margin-top: 5px;
}
#tab-admin .table-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}
#tab-admin .admin-product-access-table input,
#tab-admin .admin-user-price-table input,
#tab-admin .admin-user-price-table select,
#tab-admin .admin-api-key-table input + input,
#tab-admin .admin-api-key-table input + select,
#tab-admin .admin-api-key-table input + textarea {
  margin-top: 5px;
}
#tab-admin .admin-api-key-table textarea {
  min-height: 28px;
  padding-top: 5px;
  resize: vertical;
}
#tab-admin .admin-api-key-table .modal-scope-grid input[type="checkbox"] {
  width: 16px;
  height: 16px;
  padding: 0;
}
#tab-admin .usage-log-table .table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
#tab-admin .usage-log-table .table-actions button {
  height: 24px;
  padding: 0 7px;
  border-radius: 7px;
  font-size: 11px;
}
#tab-admin .provider-config {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 8px;
}
#tab-admin .provider-config > div {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 2px 8px;
  align-items: center;
  padding: 7px 9px;
  border-color: var(--admin-line);
  background: #fff;
}
#tab-admin .provider-config strong {
  grid-row: 1 / 3;
  margin: 0;
  font-size: 12px;
}
#tab-admin .provider-config small {
  overflow: hidden;
  color: var(--admin-muted);
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.badge {
  padding: 3px 7px;
  font-size: 11px;
}
#toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  display: none;
  max-width: 360px;
  padding: 12px 14px;
  border-radius: 8px;
  color: #fff;
  background: #0f172a;
}
@media (max-width: 780px) {
  .shell, .auth-panel { grid-template-columns: 1fr; }
  .auth-view .auth-panel { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; padding: 10px; }
  nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav-section { grid-column: 1 / -1; }
  .app-header { grid-template-columns: 1fr; }
  .top-links { justify-content: flex-start; overflow-x: auto; }
  .header-tools { align-items: stretch; }
  .search-box { width: 100%; }
  .page-shell { padding: 8px; }
  .stats { grid-template-columns: 1fr; }
  .stats.analytics-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats div { border-right: 0; border-bottom: 1px solid #ececec; }
  .stats div:last-child { border-bottom: 0; }
  .content { padding: 8px; }
  .setup-strip { grid-template-columns: 1fr; }
  .setup-actions { justify-content: flex-start; }
  .finance-summary { grid-template-columns: 1fr; }
  .report-grid { grid-template-columns: 1fr; }
  .market-layout, .profile-grid, .profile-main-grid, .profile-security-grid, .admin-command-center, .admin-command-metrics, .docs-layout, .overview-grid, .sdk-grid, .docs-reference-grid, .test-lab-grid, .test-summary, .key-list-tools, .log-list-tools, .wallet-summary, .dashboard-guide-strip, .dashboard-usage-panel, .dashboard-metric-grid, .dashboard-card-grid { grid-template-columns: 1fr; }
  .admin-stats,
  .admin-todo-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-module-nav { align-items: stretch; flex-direction: column; }
  .admin-filter-scope { justify-content: space-between; }
  .admin-filter-scope span { max-width: none; }
  .profile-metrics { grid-template-columns: 1fr; }
  .profile-metrics div { border-right: 0; border-bottom: 1px solid #ececec; }
  .profile-metrics div:last-child { border-bottom: 0; }
  .profile-password-form { grid-template-columns: 1fr; }
  .balance-card { border-left: 0; border-top: 1px solid #e5e7eb; }
  .setup-actions { justify-content: flex-start; }
  .product-market-grid { grid-template-columns: 1fr; }
  .product-market-hero h2 { font-size: 26px; }
  .doc-detail-grid { grid-template-columns: 1fr; }
  .docs-overview-grid,
  .mode-grid,
  .doc-code-grid { grid-template-columns: 1fr; }
  .doc-code-card.wide { grid-column: auto; }
  .endpoint-strip { grid-template-columns: 58px minmax(0, 1fr); }
  .analytics-toolbar { flex-direction: column; }
  .usage-bars { gap: 10px; }
  .usage-bar { min-width: 78px; }
  .market-actions { flex-direction: column; align-items: stretch; }
  .inline, .actions, .test-actions { flex-direction: column; align-items: stretch; }
  .create-product, .create-user, .create-user-options, .recharge-form, .admin-key-create-form, .pricing-form, .access-form, .secret-grid, .filter-bar, .price-edit-grid, .access-edit-grid, .recharge-edit-grid { grid-template-columns: 1fr; }
  .balance-alert-tools { grid-template-columns: 1fr; max-width: none; }
  .mini-actions { grid-column: 1 / -1; justify-self: start; }
  .product-row { grid-template-columns: 1fr; }
  .product-edit-grid { grid-template-columns: 1fr; }
  .route-row { grid-template-columns: 1fr; }
  .user-actions { grid-template-columns: 1fr; }
  .api-key-grid, .api-key-detail { grid-template-columns: 1fr; }
  .api-key-head { align-items: stretch; }
  .api-key-head > button { width: 100%; }
  .key-limit-grid, .key-limit-grid.wide { grid-template-columns: 1fr; max-width: none; }
  .row-actions { justify-content: flex-start; }
  .key-list-filters { justify-content: stretch; }
  .key-list-filters input,
  .key-list-filters select,
  .key-list-filters button,
  .log-list-filters input,
  .log-list-filters select,
  .log-list-filters button {
    flex: 1 1 100%;
    max-width: none;
  }
  .log-list-filters { justify-content: stretch; }
  .modal-layer { align-items: start; padding: 10px; }
  .modal-card { max-height: calc(100vh - 20px); }
  .modal-head { align-items: stretch; }
  .admin-form-modal.is-open,
  .admin-form-modal.is-open.admin-filter-modal,
  .admin-form-modal.is-open.admin-api-key-edit,
  .admin-action-grid,
  .admin-advanced-grid,
  .admin-form-modal.is-open .create-user,
  .admin-form-modal.is-open .create-user-options,
  .admin-form-modal.is-open .inline,
  #tab-admin .product-edit-grid.admin-form-modal.is-open {
    grid-template-columns: 1fr;
  }
  .admin-form-modal.is-open {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
  }
  .admin-modal-head { align-items: stretch; }
  .key-modal-form { grid-template-columns: 1fr; }
  .modal-actions { justify-content: stretch; }
  .modal-actions button { flex: 1 1 0; }
  .pagination-bar {
    justify-content: flex-start;
  }
  .pagination-bar select,
  .pagination-bar button {
    flex: 1 1 120px;
    width: auto;
  }
}

@media (max-width: 780px) {
  #tab-admin .filter-bar,
  #tab-admin .create-product,
  #tab-admin .create-user,
  #tab-admin .create-user-options,
  #tab-admin .recharge-form,
  #tab-admin .admin-key-create-form,
  #tab-admin .pricing-form,
  #tab-admin .access-form {
    display: grid;
    grid-template-columns: 1fr;
  }
  #tab-admin .filter-bar input,
  #tab-admin .filter-bar select,
  #tab-admin .filter-bar button,
  #tab-admin .create-product input,
  #tab-admin .create-product select,
  #tab-admin .create-product button,
  #tab-admin .create-user input,
  #tab-admin .create-user select,
  #tab-admin .create-user button,
  #tab-admin .recharge-form input,
  #tab-admin .recharge-form select,
  #tab-admin .recharge-form button,
  #tab-admin .admin-key-create-form input,
  #tab-admin .admin-key-create-form select,
  #tab-admin .admin-key-create-form button,
  #tab-admin .pricing-form input,
  #tab-admin .pricing-form select,
  #tab-admin .pricing-form button,
  #tab-admin .access-form input,
  #tab-admin .access-form select,
  #tab-admin .access-form button {
    width: 100%;
  }
  #tab-admin .product-edit-grid,
  #tab-admin .route-row,
  #tab-admin .api-key-grid,
  #tab-admin .api-key-detail,
  #tab-admin .provider-config,
  #tab-admin .user-actions {
    grid-template-columns: 1fr;
  }
  #tab-admin .row-actions {
    justify-content: flex-start;
  }
  #tab-admin .admin-module-nav {
    position: static;
  }
}
