:root {
  --sdm-color-primary: #1677ff;
  --sdm-color-primary-hover: #4096ff;
  --sdm-color-success: #52c41a;
  --sdm-color-warning: #faad14;
  --sdm-color-error: #ff4d4f;
  --sdm-color-text: #1f2329;
  --sdm-color-text-secondary: #646a73;
  --sdm-color-border: #d9d9d9;
  --sdm-color-fill: #f5f6f7;
  --sdm-height-sm: 24px;
  --sdm-height: 32px;
  --sdm-height-lg: 40px;
  --sdm-font-size: 14px;
  --sdm-font-size-help: 12px;
  --sdm-radius-control: 6px;
  --sdm-radius-surface: 8px;
  --sdm-space-1: 4px;
  --sdm-space-2: 8px;
  --sdm-space-3: 12px;
  --sdm-space-4: 16px;
  --sdm-space-6: 24px;
}

*, *::before, *::after { box-sizing: border-box; }
body { color: var(--sdm-color-text); font-size: var(--sdm-font-size); }
.main { padding: 0 var(--sdm-space-6) var(--sdm-space-6); }
.btn,
.control:not(textarea),
.sdm-select-trigger,
.pager-size,
.account-switch select,
.side-store-switch select {
  height: var(--sdm-height);
  min-height: var(--sdm-height);
  border-radius: var(--sdm-radius-control);
  font-size: var(--sdm-font-size);
  line-height: 1;
}
.btn { padding: 0 15px; }
.btn-primary { background: var(--sdm-color-primary); border-color: var(--sdm-color-primary); }
.btn-primary:hover { background: var(--sdm-color-primary-hover); border-color: var(--sdm-color-primary-hover); }
textarea.control { min-height: 64px; border-radius: var(--sdm-radius-control); }
.panel,
.modal,
.drawer,
.settings-card,
.auth-card { border-radius: var(--sdm-radius-surface); }
.panel { margin-bottom: var(--sdm-space-4); }
.panel-body,
.modal-body { padding: var(--sdm-space-4); }
.toolbar { min-height: 48px; padding: var(--sdm-space-2) var(--sdm-space-4); gap: var(--sdm-space-2); }
.list-table thead th { height: 40px; padding: 8px 12px; font-size: 13px; }
.list-table tbody td { min-height: 44px; padding: 10px 12px; }
.field { gap: var(--sdm-space-1); }
.field > label { font-size: var(--sdm-font-size); line-height: 20px; }
.field-help, .meta, .selected-hint { font-size: var(--sdm-font-size-help); color: var(--sdm-color-text-secondary); }
.status { min-height: var(--sdm-height-sm); padding: 2px 8px; border-radius: 999px; }
.nav-symbol {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 1px solid currentColor;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 700;
}
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.metric-card { padding: 16px; background: #fff; border: 1px solid #edf0f2; border-radius: var(--sdm-radius-surface); }
.metric-card small { color: var(--sdm-color-text-secondary); }
.metric-card strong { display: block; margin-top: 8px; font-size: 24px; }
.account-level { display: inline-flex; align-items: center; min-height: 24px; padding: 2px 8px; color: #0958d9; background: #e6f4ff; border-radius: 999px; }
.center-empty { padding: 48px 24px; text-align: center; color: var(--sdm-color-text-secondary); }
.component-playground { display: grid; gap: 16px; }
.component-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
@media (max-width: 1100px) { .metric-grid { grid-template-columns: repeat(2, minmax(160px, 1fr)); } }

/* Keep settings controls aligned with the Arco large (36px) component size. */
.settings-grid .control:not(textarea),
.settings-grid .sdm-select,
.settings-grid .sdm-select-trigger {
  height: 36px !important;
  min-height: 36px !important;
}

/* Keep account rows and all three parts of each workspace tab on one visual baseline. */
.account-table tbody tr {
  height: 48px;
}
.account-table tbody td {
  height: 48px;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  vertical-align: middle !important;
  line-height: normal;
}
.account-table .account-cell {
  display: flex;
  align-items: center;
  width: 100%;
  height: 48px;
  min-width: 0;
  overflow: hidden;
  line-height: 20px;
}
.account-table .account-cell-text {
  display: block;
  height: 20px;
  min-width: 0;
  overflow: hidden;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-table .account-name {
  font-weight: 600;
}
.account-table .account-perm-cell {
  height: 48px;
  overflow: hidden;
}
.account-table .account-cell-tags {
  gap: 3px;
}
.account-table .tag,
.account-table .status {
  height: 24px;
  min-height: 24px;
  margin-top: 0;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
  line-height: 22px;
}
.account-table .row-actions {
  height: 24px;
  align-items: center;
}
.account-table .account-cell-actions {
  overflow: visible;
}
.account-table .row-actions .link-btn {
  display: inline-flex;
  align-items: center;
  height: 24px;
  margin: 0;
  line-height: 20px;
}

.workspace-tab {
  display: inline-flex !important;
  align-items: center !important;
  height: 36px !important;
  line-height: 20px;
}
.workspace-tab > .workspace-tab-icon,
.workspace-tab > i {
  display: inline-grid !important;
  place-items: center !important;
  flex: 0 0 18px;
  width: 18px !important;
  height: 18px !important;
  padding: 0 !important;
  line-height: 18px !important;
}
.workspace-tab > .workspace-tab-icon {
  margin: 0 !important;
  font-size: 12px;
}
.workspace-tab > .workspace-tab-label {
  display: inline-flex;
  align-items: center;
  height: 20px;
  margin: 0;
  line-height: 20px;
}
.workspace-tab > i {
  margin: 0 0 0 2px !important;
  font-size: 14px;
  font-style: normal;
}
.workspace-tab-arrow {
  display: inline-grid;
  place-items: center;
  padding: 0;
}
