/* ── Admin Console (panel-aligned) ─────────────────────── */

/* Stats — inside panel-card, 4 columns like pricing/topup pattern */
.admin-card .admin-stats.panel-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 20px;
  gap: 10px;
}

.admin-stats[hidden] {
  display: none !important;
}

#panelChannels .channels-manage-stats {
  margin: 0 0 16px;
}

#panelChannels .channels-manage-toolbar {
  margin-bottom: 14px;
}

.admin-stat-muted {
  color: var(--text) !important;
  font-size: 0.95rem !important;
}

/* Section tabs — premium inset segmented rail */
.admin-tabs-shell {
  --admin-tabs-fade: rgba(8, 14, 22, 0.72);
  --admin-tabs-rail: linear-gradient(180deg, rgba(255, 255, 255, 0.045) 0%, rgba(0, 0, 0, 0.18) 100%);
  --admin-tabs-rail-border: rgba(255, 255, 255, 0.08);
  --admin-tabs-ink: rgba(226, 232, 240, 0.58);
  --admin-tabs-ink-strong: #f8fafc;
  --admin-tabs-hover: rgba(255, 255, 255, 0.045);
  --admin-tabs-active-line: #67e8f9;
  --admin-tabs-focus: rgba(103, 232, 249, 0.42);
  --admin-tabs-divider: transparent;
  position: relative;
  display: block;
  margin-bottom: 22px;
  min-width: 0;
}

.admin-tabs-shell::before,
.admin-tabs-shell::after {
  content: "";
  position: absolute;
  top: 2px;
  bottom: 2px;
  width: 40px;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.22s ease;
}

.admin-tabs-shell::before {
  left: 1px;
  border-radius: 13px 0 0 13px;
  background: linear-gradient(to right, var(--admin-tabs-fade) 12%, transparent);
}

.admin-tabs-shell::after {
  right: 1px;
  border-radius: 0 13px 13px 0;
  background: linear-gradient(to left, var(--admin-tabs-fade) 12%, transparent);
}

.admin-tabs-shell.is-overflow-start::before,
.admin-tabs-shell.is-overflow-end::after {
  opacity: 1;
}

.admin-tabs {
  position: relative;
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 2px;
  margin-bottom: 0;
  padding: 4px;
  border-radius: 14px;
  border: 1px solid var(--admin-tabs-rail-border, var(--border));
  background: var(--admin-tabs-rail);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.18);
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  scroll-padding-inline: 10px;
}

.admin-tabs::-webkit-scrollbar {
  display: none;
}

/* Root-group breathing gap only — no pipe / hairline glyph */
.admin-tabs-divider {
  flex: 0 0 10px;
  align-self: stretch;
  width: 10px;
  min-height: 1rem;
  margin: 0 2px;
  border: 0;
  background: transparent;
  opacity: 1;
  pointer-events: none;
}

.admin-tabs-divider[hidden] {
  display: none !important;
}

.admin-tab.admin-section-link {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  min-width: 0;
  min-height: 42px;
  padding: 10px 15px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--admin-tabs-ink);
  font-family: var(--font);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.015em;
  line-height: 1.25;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  scroll-snap-align: start;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    transform 0.18s ease;
}

.admin-tab.admin-section-link:hover {
  color: var(--admin-tabs-ink-strong);
  background: var(--admin-tabs-hover);
}

.admin-tab.admin-section-link:active {
  transform: translateY(0.5px);
}

.admin-tab.admin-section-link.active {
  color: var(--admin-tabs-ink-strong);
  background: transparent;
  font-weight: 700;
  letter-spacing: 0.01em;
}

/* Active chrome comes from .admin-tab-indicator (sliding pill) */
.admin-tab.admin-section-link.active::after {
  content: none;
}

.admin-tab.admin-section-link:focus:not(:focus-visible) {
  outline: none;
}

.admin-tab.admin-section-link:focus-visible {
  outline: 2px solid var(--admin-tabs-focus);
  outline-offset: -2px;
  border-radius: 10px;
}

.admin-tab.admin-section-link[hidden],
.admin-tab.admin-section-link.admin-tab--root-only:not(.is-root-admin-visible),
.admin-tab.admin-section-link.admin-tab--channels-gated:not(.is-channel-access-visible),
.panel-nav-link.panel-nav-link--root-only:not(.is-root-admin-visible),
.admin-root-only-block:not(.is-root-admin-visible) {
  display: none !important;
}

.admin-tabs .admin-tab-root-tag,
.admin-tab-root-tag {
  display: none !important;
}

/* Legacy More dropdown — fully retired */
.admin-tabs-more,
.admin-tabs-group,
.admin-tabs-root-label {
  display: none !important;
}

.adm-apiusage-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: flex-end;
  margin: 0.85rem 0 0.55rem;
}

.adm-apiusage-field {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  font-size: 0.78rem;
  opacity: 0.9;
}

.adm-apiusage-field input[type="date"],
.adm-apiusage-toolbar .adm-search,
.adm-apiusage-toolbar .adm-select {
  min-width: 8.5rem;
}

.adm-apiusage-field input[type="date"] {
  height: 2.1rem;
  padding: 0 0.55rem;
  border-radius: 0.65rem;
  border: 1px solid var(--border-strong, rgba(0, 0, 0, 0.12));
  background: var(--surface-2, #fff);
  color: inherit;
  font: inherit;
}

.adm-apiusage-toolbar .adm-search {
  flex: 1 1 9rem;
}

.adm-apiusage-meta {
  margin: 0 0 0.55rem;
  font-size: 0.78rem;
  opacity: 0.72;
}

.adm-apiusage-summary {
  margin-top: 0.75rem;
}

.adm-apiusage-user {
  margin-top: 0.15rem;
  font-size: 0.75rem;
  opacity: 0.72;
}

.adm-apiusage-day {
  margin-top: 0.15rem;
  font-size: 0.72rem;
  opacity: 0.65;
}

.adm-apiusage-source {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.adm-apiusage-source--personal {
  color: #3f6212;
  background: rgba(163, 230, 53, 0.18);
  border: 1px solid rgba(132, 204, 22, 0.35);
}

.adm-apiusage-source--shared {
  color: #166534;
  background: rgba(134, 239, 172, 0.22);
  border: 1px solid rgba(34, 197, 94, 0.28);
}

.adm-apiusage-source--vibi {
  color: #075985;
  background: rgba(56, 189, 248, 0.18);
  border: 1px solid rgba(14, 165, 233, 0.32);
}

html[data-theme="dark"] .adm-apiusage-source--personal {
  color: #d9f99d;
  background: rgba(163, 230, 53, 0.12);
}

html[data-theme="dark"] .adm-apiusage-source--shared {
  color: #86efac;
  background: rgba(34, 197, 94, 0.14);
}

html[data-theme="dark"] .adm-apiusage-source--vibi {
  color: #7dd3fc;
  background: rgba(14, 165, 233, 0.14);
}

.adm-table--apiusage td {
  vertical-align: top;
}

.adm-extlogs-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin: 0.75rem 0 0.5rem;
}

.adm-extlogs-toolbar .adm-search,
.adm-extlogs-toolbar .adm-select {
  min-width: 9rem;
  flex: 1 1 9rem;
}

.adm-extlogs-auto {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  opacity: 0.9;
  white-space: nowrap;
}

.adm-extlogs-meta {
  margin: 0 0 0.55rem;
  font-size: 0.78rem;
  opacity: 0.72;
}

.adm-table--extlogs td {
  vertical-align: top;
  font-size: 0.78rem;
}

.adm-extlogs-level {
  display: inline-block;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.adm-extlogs-level--error {
  color: #fecaca;
  background: rgba(239, 68, 68, 0.18);
}

.adm-extlogs-level--warn {
  color: #fde68a;
  background: rgba(245, 158, 11, 0.16);
}

.adm-extlogs-level--info {
  color: #a5f3fc;
  background: rgba(6, 182, 212, 0.14);
}

.adm-extlogs-level--debug {
  color: #d4d4d8;
  background: rgba(113, 113, 122, 0.2);
}

.adm-extlogs-msg {
  max-width: 28rem;
  word-break: break-word;
  white-space: pre-wrap;
}

.adm-extlogs-url {
  max-width: 14rem;
  word-break: break-all;
  opacity: 0.75;
}

.adm-extlogs-clear {
  color: #fca5a5 !important;
}

.adm-extlogs-ver {
  margin-top: 0.15rem;
  font-size: 0.68rem;
  opacity: 0.65;
}


/* Main card */
.admin-card.panel-card {
  padding: 0;
}

.admin-card-head.panel-card-head {
  padding-bottom: 16px;
  margin-bottom: 4px;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 88%, transparent);
}

.admin-card-head__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 20px;
}

.admin-card-head__copy {
  min-width: min(100%, 280px);
  max-width: 54ch;
}

.admin-card-kicker {
  margin: 0 0 8px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--text-secondary) 78%, transparent);
}

.admin-card-head__row h1 {
  margin: 0 0 8px;
  font-size: clamp(1.55rem, 1.25rem + 1.1vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.admin-card-head__row .panel-lead {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-tertiary, var(--text-secondary));
  opacity: 0.88;
}

.admin-card-cta {
  flex: 0 0 auto;
  align-self: flex-start;
  min-height: 40px;
  padding-inline: 16px;
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(40, 90, 55, 0.18);
}

.admin-card-body.panel-card-body {
  padding-top: 18px;
}

/* Tab panels — shared content width (matches panel-card-body 28px inset) */
.admin-tab-panel {
  width: 100%;
  min-width: 0;
}

.admin-tab-panel .adm-toolbar {
  width: 100%;
}

.adm-cap-matrix {
  min-width: 0;
}

.adm-cap-layout {
  display: grid;
  grid-template-columns: minmax(220px, 27%) minmax(0, 1fr);
  min-height: 520px;
  overflow: hidden;
  border: 1px solid var(--panel-border, rgba(255, 255, 255, .12));
  border-radius: 14px;
  background: rgba(255, 255, 255, .018);
}

.adm-cap-admins {
  min-width: 0;
  border-right: 1px solid var(--border);
  background: rgba(8, 13, 24, .32);
}

.adm-cap-search {
  position: relative;
  padding: 12px;
  border-bottom: 1px solid var(--border);
}

.adm-cap-search > span {
  position: absolute;
  top: 50%;
  left: 23px;
  color: var(--text-tertiary);
  font-size: 1rem;
  transform: translateY(-50%);
  pointer-events: none;
}

.adm-cap-search input {
  width: 100%;
  height: 36px;
  padding: 0 12px 0 32px;
  border: 1px solid var(--border);
  border-radius: 9px;
  outline: 0;
  color: var(--text-primary);
  background: rgba(255, 255, 255, .04);
  font: inherit;
  font-size: .72rem;
}

.adm-cap-search input:focus {
  border-color: rgba(103, 232, 249, .4);
  box-shadow: 0 0 0 3px rgba(103, 232, 249, .08);
}

.adm-cap-admin-list {
  max-height: 620px;
  padding: 7px;
  overflow-y: auto;
  scrollbar-width: thin;
}

.adm-cap-admin-item {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 9px;
  border: 1px solid transparent;
  border-radius: 9px;
  color: var(--text-secondary);
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, color .16s ease;
}

.adm-cap-admin-item:hover {
  background: rgba(103, 232, 249, .045);
}

.adm-cap-admin-item.is-selected {
  border-color: rgba(103, 232, 249, .22);
  color: var(--text-primary);
  background: rgba(103, 232, 249, .08);
}

.adm-cap-admin-avatar {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(103, 232, 249, .16);
  border-radius: 9px;
  color: var(--accent);
  background: rgba(103, 232, 249, .08);
  font-size: .7rem;
  font-weight: 800;
}

.adm-cap-admin-copy {
  min-width: 0;
}

.adm-cap-admin-copy strong,
.adm-cap-admin-copy small,
.adm-cap-detail__identity strong,
.adm-cap-detail__identity small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-cap-admin-copy strong,
.adm-cap-detail__identity strong {
  color: var(--text-primary);
  font-size: .72rem;
  font-weight: 700;
}

.adm-cap-admin-copy small,
.adm-cap-detail__identity small {
  margin-top: 2px;
  color: var(--text-tertiary);
  font-size: .625rem;
}

.adm-cap-admin-count,
.adm-cap-detail__count,
.adm-cap-group__head span {
  color: var(--text-tertiary);
  font-size: .625rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.adm-cap-no-results {
  margin: 18px 8px;
  font-size: .72rem;
}

.adm-cap-detail {
  min-width: 0;
}

.adm-cap-detail__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 61px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, .018);
}

.adm-cap-detail__identity {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
}

.adm-cap-detail__identity > div {
  min-width: 0;
}

.adm-cap-detail__count {
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, .025);
}

.adm-cap-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
}

.adm-cap-group {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: rgba(8, 13, 24, .25);
}

.adm-cap-group__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 35px;
  padding: 8px 11px;
  border-bottom: 1px solid var(--border);
  background: rgba(103, 232, 249, .04);
}

.adm-cap-group__head h3 {
  margin: 0;
  color: var(--text-secondary);
  font-size: .625rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.adm-cap-permission {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 40px;
  padding: 7px 11px;
  border-bottom: 1px solid var(--border);
}

.adm-cap-permission:last-child {
  border-bottom: 0;
}

.adm-cap-permission label {
  color: var(--text-secondary);
  font-size: .69rem;
  line-height: 1.35;
  cursor: pointer;
}

.adm-cap-toggle.perm-toggle {
  flex: 0 0 auto;
  width: 36px;
  height: 20px;
  vertical-align: middle;
}

.adm-cap-toggle.perm-toggle::after {
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
}

.adm-cap-toggle.perm-toggle.on::after {
  transform: translateX(16px);
}

@media (max-width: 820px) {
  .adm-cap-groups {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .adm-cap-layout {
    display: block;
  }

  .adm-cap-admins {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .adm-cap-admin-list {
    display: flex;
    gap: 7px;
    max-height: none;
    padding: 8px;
    overflow-x: auto;
  }

  .adm-cap-admin-item {
    flex: 0 0 210px;
  }

  .adm-cap-groups {
    padding: 10px;
  }
}

.adm-table--users,
.adm-table--revenue {
  table-layout: fixed;
  width: 100%;
}

.adm-table--users col.adm-col-select { width: 0; }
/* Shrink account whitespace so GÓI sits closer left; plan wide enough for SUPER ADMIN */
.adm-table--users col.adm-col-account { width: 22%; }
.adm-table--users col.adm-col-plan { width: 118px; }
.adm-table--users col.adm-col-balance { width: 13%; }
.adm-table--users col.adm-col-credits { width: 11%; }
.adm-table--users col.adm-col-expiry { width: 10%; }
.adm-table--users col.adm-col-last-tool { width: 16%; }
.adm-table--users col.adm-col-devices { width: 11%; }
.adm-table--users col.adm-col-actions { width: 56px; }

.adm-table--users .adm-th-select,
.adm-table--users .adm-td-select,
.adm-table--users col.adm-col-select {
  display: none;
}

.adm-table--users.is-selecting col.adm-col-select { display: table-column; width: 44px; }
.adm-table--users.is-selecting .adm-th-select,
.adm-table--users.is-selecting .adm-td-select {
  display: table-cell;
}

.adm-table--users.is-selecting col.adm-col-account { width: 20%; }
.adm-table--users.is-selecting col.adm-col-plan { width: 110px; }

.adm-th-select,
.adm-td-select {
  width: 44px;
  text-align: center;
  vertical-align: middle;
  padding-left: 8px;
  padding-right: 4px;
}

.adm-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  cursor: pointer;
}

.adm-check input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--accent, #3d7a4a);
  cursor: pointer;
}

.adm-table--users tr.is-selected {
  background: rgba(61, 122, 74, 0.08);
}

html[data-theme="dark"] .adm-table--users tr.is-selected,
:root:not([data-theme="light"]) .adm-table--users tr.is-selected {
  background: rgba(103, 232, 249, 0.08);
}

.adm-bulk-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface-2, rgba(176, 212, 184, 0.16));
}

.adm-bulk-bar[hidden] { display: none !important; }

.adm-bulk-bar__count {
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-primary);
}

.adm-bulk-bar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-left: auto;
}

.adm-bulk-bar__danger {
  color: #b91c1c !important;
}

#usersBulkModeBtn.is-active {
  border-color: rgba(61, 122, 74, 0.45);
  background: rgba(176, 212, 184, 0.28);
  color: var(--text-primary);
}

.adm-table--revenue col.adm-col-account { width: auto; }
.adm-table--revenue col.adm-col-toggle { width: 88px; }
.adm-table--revenue col.adm-col-actions { width: 108px; }

.adm-td-account {
  overflow: hidden;
  min-width: 0;
}

.adm-table--users tbody td {
  vertical-align: middle;
}

.adm-table--users .adm-th-plan,
.adm-table--users .adm-td-plan {
  white-space: nowrap;
  padding-left: 4px;
  padding-right: 10px;
  overflow: hidden;
  text-align: left;
  vertical-align: middle;
}

.adm-table--users .adm-td-plan .role-pill {
  max-width: 100%;
}

.adm-table--users .adm-td-balance,
.adm-table--users .adm-td-credits,
.adm-table--users .adm-td-expiry,
.adm-table--users .adm-td-last-tool,
.adm-table--users .adm-td-devices {
  white-space: nowrap;
}

.adm-table--users .adm-td-credits {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--text-primary, #1f3d2a);
}

.adm-table--users .adm-td-last-tool {
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem;
  color: var(--text-secondary, #4d735c);
}

.adm-table--users .adm-td-actions {
  width: 56px;
  padding-left: 4px;
  padding-right: 0;
}

.adm-table--users .adm-td-actions .adm-row-actions {
  align-items: center;
  min-height: 34px;
}

.adm-table--users .adm-user-cell,
.adm-table--revenue .adm-user-cell {
  min-width: 0;
  max-width: 100%;
  width: 100%;
}

.adm-table--users .adm-user-cell > div:last-child,
.adm-table--revenue .adm-user-cell > div:last-child {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
}

.adm-table--users .adm-user-cell strong,
.adm-table--users .adm-user-cell small,
.adm-table--revenue .adm-user-cell strong,
.adm-table--revenue .adm-user-cell small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-table--users .adm-avatar,
.adm-table--revenue .adm-avatar {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  font-size: 0.76rem;
}

.adm-th-center {
  text-align: center;
}

.adm-table--users th.adm-th-plan {
  padding-left: 6px;
  padding-right: 6px;
}

.adm-th-actions {
  text-align: right;
  width: 56px;
}

.adm-table--users td:last-child,
.adm-table--revenue td:last-child {
  text-align: right;
  white-space: nowrap;
}

/* Sections inside panel-card */
.adm-section + .adm-section {
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
}

.adm-section[hidden] {
  display: none;
}

.adm-section__head {
  margin: 2px 0 16px;
  padding-top: 2px;
}

.adm-section__head h2 {
  margin: 0 0 6px;
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.25;
  color: var(--text);
}

.adm-section__sub {
  margin: 0 0 14px;
  max-width: 70ch;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-tertiary);
  line-height: 1.55;
  opacity: 0.92;
}

.adm-perm-actions.panel-form-actions {
  margin: 16px 0 0;
  padding-left: 0;
  padding-right: 0;
  border-radius: var(--radius-md);
}

/* Toolbar */
.adm-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.adm-search-wrap {
  flex: 1 1 220px;
  position: relative;
  min-width: 0;
}

.adm-search-icon {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  font-size: 0.85rem;
  pointer-events: none;
}

.adm-search {
  width: 100%;
  padding: 10px 14px 10px 34px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.3);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.86rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.adm-search:focus {
  outline: none;
  border-color: rgba(103, 232, 249, 0.45);
  box-shadow: 0 0 0 3px rgba(103, 232, 249, 0.1);
}

/* Native select fallback — enhanced by JrSelect (dropdown.js) */
.adm-select:not(.jr-select-native) {
  padding: 10px 32px 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.3) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394a3b8' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 10px center;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.84rem;
  appearance: none;
  cursor: pointer;
}

.adm-select--full { width: 100%; }

/* Table — full height, page scroll (no nested scrollbar) */
.adm-table-wrap,
.adm-table-wrap--tall {
  overflow: visible;
}

@media (max-width: 900px) {
  .adm-table-wrap,
  .adm-table-wrap--tall {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-inline: -4px;
    padding-inline: 4px;
  }

  .adm-table {
    min-width: 640px;
  }
}

.adm-revenue-col .adm-table-wrap {
  padding: 0 16px 12px;
}

.adm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.adm-table th,
.adm-table td {
  padding: 11px 8px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.adm-table th:first-child,
.adm-table td:first-child { padding-left: 0; }

.adm-table th:last-child,
.adm-table td:last-child { padding-right: 0; }

.adm-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding-top: 8px;
  padding-bottom: 8px;
  font-size: 0.6875rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  background: rgba(8, 13, 24, 0.98);
  box-shadow: 0 1px 0 var(--border);
}

.adm-table tbody tr {
  transition: background 0.15s;
}

.adm-table tbody tr:hover td {
  background: rgba(103, 232, 249, 0.03);
}

.adm-table tr:last-child td { border-bottom: none; }

.adm-empty {
  text-align: center;
  color: var(--text-tertiary);
  padding: 32px !important;
}

.adm-empty--error {
  color: #f87171;
  font-weight: 500;
}

.adm-load-error[hidden] {
  display: none !important;
}

.adm-load-error {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin: 0 20px 16px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(248, 113, 113, 0.35);
  background: rgba(248, 113, 113, 0.08);
  color: #fecaca;
}

.adm-load-error__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.adm-load-error__text strong {
  color: #fca5a5;
  font-size: 0.9rem;
}

.adm-load-error__text p {
  margin: 0;
  font-size: 0.82rem;
  color: #fecaca;
  line-height: 1.45;
}

.adm-user-cell {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.adm-user-cell__text {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
}

.adm-avatar {
  width: 38px;
  height: 38px;
  min-width: 38px;
  min-height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--accent-cyan);
  background: rgba(103, 232, 249, 0.1);
  border: 1px solid rgba(103, 232, 249, 0.22);
  flex-shrink: 0;
  text-transform: uppercase;
  overflow: hidden;
}

.adm-avatar--has-img {
  padding: 0;
  background: rgba(8, 12, 22, 0.5);
}

.adm-avatar--has-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.adm-avatar__fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
}

.adm-table--users .adm-user-cell strong,
.adm-table--revenue .adm-user-cell strong {
  display: block;
  font-weight: 700;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-table--users .adm-user-cell small,
.adm-table--revenue .adm-user-cell small {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
  font-size: 0.74rem;
  color: var(--text-tertiary);
  margin-top: 2px;
  line-height: 1.35;
}

.role-pill {
  --plan-c1: var(--plan-user-c1, #5eead4);
  --plan-c2: var(--plan-user-c2, #10b981);
  --plan-c3: var(--plan-user-c3, #065f46);
  --plan-glow: var(--plan-user-glow, rgba(16, 185, 129, 0.55));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 24px;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-family: var(--font);
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  text-transform: none;
  letter-spacing: 0.045em;
  vertical-align: middle;
  color: #fff;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
  border: 1px solid color-mix(in srgb, var(--plan-c3) 55%, #fff);
  background: linear-gradient(180deg, var(--plan-c1) 0%, var(--plan-c2) 48%, var(--plan-c3) 100%);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.18) inset,
    0 1px 0 rgba(255, 255, 255, 0.28) inset;
}

.role-pill--user,
.role-pill--pro,
.role-pill--ultra,
.role-pill--admin {
  color: #fff;
}

.role-pill--user {
  --plan-c1: var(--plan-user-c1, #34d399);
  --plan-c2: var(--plan-user-c2, #10b981);
  --plan-c3: var(--plan-user-c3, #059669);
  --plan-glow: var(--plan-user-glow, rgba(16, 185, 129, 0.18));
}
.role-pill--pro {
  --plan-c1: var(--plan-pro-c1, #38bdf8);
  --plan-c2: var(--plan-pro-c2, #2563eb);
  --plan-c3: var(--plan-pro-c3, #1d4ed8);
  --plan-glow: var(--plan-pro-glow, rgba(37, 99, 235, 0.18));
}
.role-pill--ultra {
  --plan-c1: var(--plan-ultra-c1, #fbbf24);
  --plan-c2: var(--plan-ultra-c2, #f59e0b);
  --plan-c3: var(--plan-ultra-c3, #d97706);
  --plan-glow: var(--plan-ultra-glow, rgba(245, 158, 11, 0.18));
}
.role-pill--admin {
  --plan-c1: var(--plan-admin-c1, #f43f5e);
  --plan-c2: var(--plan-admin-c2, #e11d48);
  --plan-c3: var(--plan-admin-c3, #be123c);
  --plan-glow: var(--plan-admin-glow, rgba(225, 29, 72, 0.18));
}

.role-pill--user::before,
.role-pill--pro::before,
.role-pill--ultra::before,
.role-pill--admin::before {
  content: none;
  display: none;
  animation: none;
}

@property --plan-orbit {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@keyframes planBadgeOrbit {
  to { --plan-orbit: 360deg; }
}

.role-pill--user::after,
.role-pill--pro::after,
.role-pill--ultra::after,
.role-pill--admin::after {
  content: "";
  display: block;
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-sizing: border-box;
  padding: 1.5px;
  pointer-events: none;
  z-index: 3;
  --plan-orbit: 0deg;
  background: conic-gradient(
    from var(--plan-orbit),
    transparent 0deg,
    transparent 292deg,
    rgba(255, 255, 255, 0.08) 308deg,
    rgba(255, 255, 255, 0.55) 328deg,
    #fff 338deg,
    rgba(255, 255, 255, 0.55) 348deg,
    rgba(255, 255, 255, 0.08) 358deg,
    transparent 360deg
  );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask-composite: exclude;
  opacity: 1;
  animation: planBadgeOrbit 2.4s linear infinite alternate;
}

@keyframes planBadgeShine {
  0%, 100% { opacity: 0; }
}

@keyframes planBadgeSpec {
  0%, 100% { opacity: 0; }
}

html.is-bg-paused .role-pill--user::before,
html.is-bg-paused .role-pill--pro::before,
html.is-bg-paused .role-pill--ultra::before,
html.is-bg-paused .role-pill--admin::before,
html.is-bg-paused .role-pill--user::after,
html.is-bg-paused .role-pill--pro::after,
html.is-bg-paused .role-pill--ultra::after,
html.is-bg-paused .role-pill--admin::after {
  animation-play-state: paused !important;
}

/* Lite: keep rim orbit visible, just slower — do not kill to animation:none */
html.jr-perf-lite .role-pill--user::before,
html.jr-perf-lite .role-pill--pro::before,
html.jr-perf-lite .role-pill--ultra::before,
html.jr-perf-lite .role-pill--admin::before {
  content: none !important;
  display: none !important;
  animation: none !important;
}
html.jr-perf-lite .role-pill--user::after,
html.jr-perf-lite .role-pill--pro::after,
html.jr-perf-lite .role-pill--ultra::after,
html.jr-perf-lite .role-pill--admin::after {
  animation: planBadgeOrbit 4.8s linear infinite alternate !important;
}

@media (prefers-reduced-motion: reduce) {
  .role-pill--user::before,
  .role-pill--pro::before,
  .role-pill--ultra::before,
  .role-pill--admin::before,
  .role-pill--user::after,
  .role-pill--pro::after,
  .role-pill--ultra::after,
  .role-pill--admin::after {
    animation: none !important;
  }
}
/* Super Admin — quiet facets + continuous moving light regions. */
@keyframes saSparkRegions {
  0% {
    background-position: 140% 50%, -30% 0%, 120% 100%;
  }
  100% {
    background-position: -40% 50%, 130% 0%, -20% 100%;
  }
}

@keyframes saFacetPulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 0.62; }
}

.role-pill--super-admin {
  --sa-fill: linear-gradient(145deg, #BE123C 0%, #9F1239 35%, #7F1D1D 70%, #4C0519 100%);
  --sa-gem-fill: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27160%27%20height%3D%2748%27%20viewBox%3D%270%200%20160%2048%27%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2080.0%2C18.0%2088.1%2C18.4%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2088.1%2C18.4%2095.0%2C19.7%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C18.4%2080.0%2C18.0%2080.0%2C12.2%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C18.4%2080.0%2C12.2%2096.0%2C13.1%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C18.4%2096.0%2C13.1%20109.6%2C15.6%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C18.4%20109.6%2C15.6%2095.0%2C19.7%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C13.1%2080.0%2C12.2%2080.0%2C7.2%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C13.1%2080.0%2C7.2%20102.7%2C8.5%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C13.1%20102.7%2C8.5%20121.9%2C12.1%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C13.1%20121.9%2C12.1%20109.6%2C15.6%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C8.5%2080.0%2C7.2%2080.0%2C2.5%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C8.5%2080.0%2C2.5%20109.1%2C4.1%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C8.5%20109.1%2C4.1%20133.7%2C8.8%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C8.5%20133.7%2C8.8%20121.9%2C12.1%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2095.0%2C19.7%2099.7%2C21.7%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2099.7%2C21.7%20101.3%2C24.0%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C21.7%2095.0%2C19.7%20109.6%2C15.6%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C21.7%20109.6%2C15.6%20118.6%2C19.5%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C21.7%20118.6%2C19.5%20121.8%2C24.0%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C21.7%20121.8%2C24.0%20101.3%2C24.0%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C19.5%20109.6%2C15.6%20121.9%2C12.1%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C19.5%20121.9%2C12.1%20134.8%2C17.6%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C19.5%20134.8%2C17.6%20139.3%2C24.0%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C19.5%20139.3%2C24.0%20121.8%2C24.0%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C17.6%20121.9%2C12.1%20133.7%2C8.8%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C17.6%20133.7%2C8.8%20150.2%2C15.8%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C17.6%20150.2%2C15.8%20156.0%2C24.0%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C17.6%20156.0%2C24.0%20139.3%2C24.0%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%20101.3%2C24.0%2099.7%2C26.3%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2099.7%2C26.3%2095.0%2C28.3%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C26.3%20101.3%2C24.0%20121.8%2C24.0%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C26.3%20121.8%2C24.0%20118.6%2C28.5%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C26.3%20118.6%2C28.5%20109.6%2C32.4%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2799.7%2C26.3%20109.6%2C32.4%2095.0%2C28.3%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C28.5%20121.8%2C24.0%20139.3%2C24.0%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C28.5%20139.3%2C24.0%20134.8%2C30.4%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C28.5%20134.8%2C30.4%20121.9%2C35.9%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%27118.6%2C28.5%20121.9%2C35.9%20109.6%2C32.4%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C30.4%20139.3%2C24.0%20156.0%2C24.0%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C30.4%20156.0%2C24.0%20150.2%2C32.2%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C30.4%20150.2%2C32.2%20133.7%2C39.2%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%27134.8%2C30.4%20133.7%2C39.2%20121.9%2C35.9%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2095.0%2C28.3%2088.1%2C29.6%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2088.1%2C29.6%2080.0%2C30.0%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C29.6%2095.0%2C28.3%20109.6%2C32.4%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C29.6%20109.6%2C32.4%2096.0%2C34.9%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C29.6%2096.0%2C34.9%2080.0%2C35.8%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2788.1%2C29.6%2080.0%2C35.8%2080.0%2C30.0%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C34.9%20109.6%2C32.4%20121.9%2C35.9%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C34.9%20121.9%2C35.9%20102.7%2C39.5%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C34.9%20102.7%2C39.5%2080.0%2C40.8%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2796.0%2C34.9%2080.0%2C40.8%2080.0%2C35.8%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C39.5%20121.9%2C35.9%20133.7%2C39.2%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C39.5%20133.7%2C39.2%20109.1%2C43.9%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C39.5%20109.1%2C43.9%2080.0%2C45.5%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%27102.7%2C39.5%2080.0%2C45.5%2080.0%2C40.8%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2080.0%2C30.0%2071.9%2C29.6%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2071.9%2C29.6%2065.0%2C28.3%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C29.6%2080.0%2C30.0%2080.0%2C35.8%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C29.6%2080.0%2C35.8%2064.0%2C34.9%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C29.6%2064.0%2C34.9%2050.4%2C32.4%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C29.6%2050.4%2C32.4%2065.0%2C28.3%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C34.9%2080.0%2C35.8%2080.0%2C40.8%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C34.9%2080.0%2C40.8%2057.3%2C39.5%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C34.9%2057.3%2C39.5%2038.1%2C35.9%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C34.9%2038.1%2C35.9%2050.4%2C32.4%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C39.5%2080.0%2C40.8%2080.0%2C45.5%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C39.5%2080.0%2C45.5%2050.9%2C43.9%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C39.5%2050.9%2C43.9%2026.3%2C39.2%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C39.5%2026.3%2C39.2%2038.1%2C35.9%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2065.0%2C28.3%2060.3%2C26.3%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2060.3%2C26.3%2058.7%2C24.0%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C26.3%2065.0%2C28.3%2050.4%2C32.4%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C26.3%2050.4%2C32.4%2041.4%2C28.5%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C26.3%2041.4%2C28.5%2038.2%2C24.0%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C26.3%2038.2%2C24.0%2058.7%2C24.0%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C28.5%2050.4%2C32.4%2038.1%2C35.9%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C28.5%2038.1%2C35.9%2025.2%2C30.4%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C28.5%2025.2%2C30.4%2020.7%2C24.0%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C28.5%2020.7%2C24.0%2038.2%2C24.0%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C30.4%2038.1%2C35.9%2026.3%2C39.2%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C30.4%2026.3%2C39.2%209.8%2C32.2%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C30.4%209.8%2C32.2%204.0%2C24.0%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C30.4%204.0%2C24.0%2020.7%2C24.0%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2058.7%2C24.0%2060.3%2C21.7%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2060.3%2C21.7%2065.0%2C19.7%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C21.7%2058.7%2C24.0%2038.2%2C24.0%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C21.7%2038.2%2C24.0%2041.4%2C19.5%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C21.7%2041.4%2C19.5%2050.4%2C15.6%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2760.3%2C21.7%2050.4%2C15.6%2065.0%2C19.7%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C19.5%2038.2%2C24.0%2020.7%2C24.0%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C19.5%2020.7%2C24.0%2025.2%2C17.6%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C19.5%2025.2%2C17.6%2038.1%2C12.1%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2741.4%2C19.5%2038.1%2C12.1%2050.4%2C15.6%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C17.6%2020.7%2C24.0%204.0%2C24.0%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C17.6%204.0%2C24.0%209.8%2C15.8%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C17.6%209.8%2C15.8%2026.3%2C8.8%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2725.2%2C17.6%2026.3%2C8.8%2038.1%2C12.1%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2065.0%2C19.7%2071.9%2C18.4%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2780.0%2C24.0%2071.9%2C18.4%2080.0%2C18.0%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C18.4%2065.0%2C19.7%2050.4%2C15.6%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C18.4%2050.4%2C15.6%2064.0%2C13.1%27%20fill%3D%27%233f0a12%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C18.4%2064.0%2C13.1%2080.0%2C12.2%27%20fill%3D%27%234c0519%27%2F%3E%3Cpolygon%20points%3D%2771.9%2C18.4%2080.0%2C12.2%2080.0%2C18.0%27%20fill%3D%27%237f1d1d%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C13.1%2050.4%2C15.6%2038.1%2C12.1%27%20fill%3D%27%239f1239%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C13.1%2038.1%2C12.1%2057.3%2C8.5%27%20fill%3D%27%23be123c%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C13.1%2057.3%2C8.5%2080.0%2C7.2%27%20fill%3D%27%23e11d48%27%2F%3E%3Cpolygon%20points%3D%2764.0%2C13.1%2080.0%2C7.2%2080.0%2C12.2%27%20fill%3D%27%23881337%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C8.5%2038.1%2C12.1%2026.3%2C8.8%27%20fill%3D%27%236b0f1a%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C8.5%2026.3%2C8.8%2050.9%2C4.1%27%20fill%3D%27%23450a0a%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C8.5%2050.9%2C4.1%2080.0%2C2.5%27%20fill%3D%27%232a0610%27%2F%3E%3Cpolygon%20points%3D%2757.3%2C8.5%2080.0%2C2.5%2080.0%2C7.2%27%20fill%3D%27%233f0a12%27%2F%3E%3Cellipse%20cx%3D%2780.0%27%20cy%3D%2724.0%27%20rx%3D%2758%27%20ry%3D%2711%27%20fill%3D%27%234c0519%27%20fill-opacity%3D%270.55%27%2F%3E%3Cpath%20d%3D%27M80.0%2012.2L109.6%2015.6L121.8%2024.0L109.6%2032.4L80.0%2035.8L50.4%2032.4L38.2%2024.0L50.4%2015.6L80.0%2012.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M80.0%202.5L133.7%208.8L156.0%2024.0L133.7%2039.2L80.0%2045.5L26.3%2039.2L4.0%2024.0L26.3%208.8L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M80.0%2022.3L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M84.3%2022.8L133.7%208.8%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M86.1%2024.0L156.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M84.3%2025.2L133.7%2039.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M80.0%2025.7L80.0%2045.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M75.7%2025.2L26.3%2039.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M73.9%2024.0L4.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M75.7%2022.8L26.3%208.8%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3Cpath%20d%3D%27M80.0%207.2L109.1%204.1L121.9%2012.1L150.2%2015.8L139.3%2024.0L150.2%2032.2L121.9%2035.9L109.1%2043.9L80.0%2040.8L50.9%2043.9L38.1%2035.9L9.8%2032.2L20.7%2024.0L9.8%2015.8L38.1%2012.1L50.9%204.1L80.0%207.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.18%29%27%20stroke-width%3D%27.4%27%2F%3E%3C%2Fsvg%3E");
  --sa-gem-mask: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27160%27%20height%3D%2748%27%20viewBox%3D%270%200%20160%2048%27%3E%3Cpath%20d%3D%27M80.0%2012.2L109.6%2015.6L121.8%2024.0L109.6%2032.4L80.0%2035.8L50.4%2032.4L38.2%2024.0L50.4%2015.6L80.0%2012.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M80.0%202.5L133.7%208.8L156.0%2024.0L133.7%2039.2L80.0%2045.5L26.3%2039.2L4.0%2024.0L26.3%208.8L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M80.0%2022.3L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M84.3%2022.8L133.7%208.8%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M86.1%2024.0L156.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M84.3%2025.2L133.7%2039.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M80.0%2025.7L80.0%2045.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M75.7%2025.2L26.3%2039.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M73.9%2024.0L4.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M75.7%2022.8L26.3%208.8%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Cpath%20d%3D%27M80.0%207.2L109.1%204.1L121.9%2012.1L150.2%2015.8L139.3%2024.0L150.2%2032.2L121.9%2035.9L109.1%2043.9L80.0%2040.8L50.9%2043.9L38.1%2035.9L9.8%2032.2L20.7%2024.0L9.8%2015.8L38.1%2012.1L50.9%204.1L80.0%207.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.1%27%20stroke-linecap%3D%27round%27%2F%3E%3Crect%20x%3D%2722%27%20y%3D%2714%27%20width%3D%27116%27%20height%3D%2720%27%20fill%3D%27%23000%27%2F%3E%3C%2Fsvg%3E");
  --sa-gem-chase: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27160%27%20height%3D%2748%27%20viewBox%3D%270%200%20160%2048%27%3E%3Cpath%20d%3D%27M80.0%2012.2L109.6%2015.6L121.8%2024.0L109.6%2032.4L80.0%2035.8L50.4%2032.4L38.2%2024.0L50.4%2015.6L80.0%2012.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M80.0%202.5L133.7%208.8L156.0%2024.0L133.7%2039.2L80.0%2045.5L26.3%2039.2L4.0%2024.0L26.3%208.8L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M80.0%2022.3L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M84.3%2022.8L133.7%208.8%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M86.1%2024.0L156.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M84.3%2025.2L133.7%2039.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M80.0%2025.7L80.0%2045.5%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M75.7%2025.2L26.3%2039.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M73.9%2024.0L4.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M75.7%2022.8L26.3%208.8%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M80.0%207.2L109.1%204.1L121.9%2012.1L150.2%2015.8L139.3%2024.0L150.2%2032.2L121.9%2035.9L109.1%2043.9L80.0%2040.8L50.9%2043.9L38.1%2035.9L9.8%2032.2L20.7%2024.0L9.8%2015.8L38.1%2012.1L50.9%204.1L80.0%207.2%27%20fill%3D%27none%27%20stroke%3D%27rgba%28255%2C200%2C210%2C.15%29%27%20stroke-width%3D%27.55%27%2F%3E%3Cpath%20d%3D%27M80.0%2012.2L109.6%2015.6L121.8%2024.0L109.6%2032.4L80.0%2035.8L50.4%2032.4L38.2%2024.0L50.4%2015.6L80.0%2012.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%276%2042%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-48%27%20dur%3D%273.2s%27%20begin%3D%270.0s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M80.0%202.5L133.7%208.8L156.0%2024.0L133.7%2039.2L80.0%2045.5L26.3%2039.2L4.0%2024.0L26.3%208.8L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%278%2048%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-56%27%20dur%3D%274.0s%27%20begin%3D%270.55s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M80.0%2022.3L80.0%202.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%2710%2054%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-64%27%20dur%3D%273.6s%27%20begin%3D%271.1s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M84.3%2022.8L133.7%208.8%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%276%2060%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-66%27%20dur%3D%274.5s%27%20begin%3D%271.65s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M86.1%2024.0L156.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%278%2042%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-50%27%20dur%3D%273.8s%27%20begin%3D%272.2s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M84.3%2025.2L133.7%2039.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%2710%2048%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-58%27%20dur%3D%274.2s%27%20begin%3D%272.75s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M80.0%2025.7L80.0%2045.5%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%276%2054%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-60%27%20dur%3D%273.4s%27%20begin%3D%273.3s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M75.7%2025.2L26.3%2039.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%278%2060%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-68%27%20dur%3D%274.8s%27%20begin%3D%270.35s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M73.9%2024.0L4.0%2024.0%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%2710%2042%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-52%27%20dur%3D%273.9s%27%20begin%3D%270.9s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M75.7%2022.8L26.3%208.8%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%276%2048%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-54%27%20dur%3D%274.1s%27%20begin%3D%271.45s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Cpath%20d%3D%27M80.0%207.2L109.1%204.1L121.9%2012.1L150.2%2015.8L139.3%2024.0L150.2%2032.2L121.9%2035.9L109.1%2043.9L80.0%2040.8L50.9%2043.9L38.1%2035.9L9.8%2032.2L20.7%2024.0L9.8%2015.8L38.1%2012.1L50.9%204.1L80.0%207.2%27%20fill%3D%27none%27%20stroke%3D%27%23fff%27%20stroke-width%3D%271.2%27%20stroke-linecap%3D%27round%27%20stroke-dasharray%3D%278%2054%27%20stroke-opacity%3D%27.55%27%3E%3Canimate%20attributeName%3D%27stroke-dashoffset%27%20values%3D%270%3B-62%27%20dur%3D%273.5s%27%20begin%3D%272.0s%27%20repeatCount%3D%27indefinite%27%2F%3E%3C%2Fpath%3E%3Crect%20x%3D%2722%27%20y%3D%2714%27%20width%3D%27116%27%20height%3D%2720%27%20fill%3D%27%234c0519%27%20fill-opacity%3D%270.35%27%2F%3E%3C%2Fsvg%3E");
  position: relative;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  color: #FFFFFF;
  border: none;
  padding: 4px 10px;
  text-shadow:
    0 0 1px rgba(0, 0, 0, 0.95),
    0 1px 2px rgba(0, 0, 0, 0.95),
    0 0 8px rgba(0, 0, 0, 0.75),
    0 2px 6px rgba(0, 0, 0, 0.85);
  background: var(--sa-fill);
  box-shadow:
    0 0 0 1px rgba(255, 200, 200, 0.18) inset,
    0 1px 0 rgba(255, 255, 255, 0.2) inset;
  font-weight: 800;
  letter-spacing: 0.05em;
  max-width: 100%;
  animation: none;
  filter: none;
}

.role-pill--super-admin::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 1;
  mix-blend-mode: soft-light;
  opacity: 0.55;
  background-image: var(--sa-gem-fill);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  animation: saFacetPulse 7s ease-in-out infinite;
}

.role-pill--super-admin::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 2;
  mix-blend-mode: screen;
  opacity: 1;
  transform: none;
  background-color: transparent;
  background-image:
    linear-gradient(
      105deg,
      transparent 0%,
      transparent 38%,
      rgba(255, 255, 255, 0.25) 44%,
      rgba(255, 255, 255, 1) 49%,
      rgba(255, 240, 245, 1) 51%,
      rgba(255, 255, 255, 0.25) 56%,
      transparent 62%,
      transparent 100%
    ),
    linear-gradient(
      90deg,
      transparent 0%,
      rgba(255, 255, 255, 0.55) 50%,
      transparent 100%
    ),
    linear-gradient(
      90deg,
      transparent 0%,
      rgba(255, 200, 210, 0.45) 50%,
      transparent 100%
    );
  background-size: 220% 100%, 35% 28%, 40% 28%;
  background-repeat: no-repeat;
  background-position: 140% 50%, -30% 0%, 120% 100%;
  -webkit-mask-image: linear-gradient(
    to bottom,
    #fff 0%,
    #fff 16%,
    rgba(255, 255, 255, 0.45) 36%,
    rgba(255, 255, 255, 0.45) 64%,
    #fff 84%,
    #fff 100%
  );
  mask-image: linear-gradient(
    to bottom,
    #fff 0%,
    #fff 16%,
    rgba(255, 255, 255, 0.45) 36%,
    rgba(255, 255, 255, 0.45) 64%,
    #fff 84%,
    #fff 100%
  );
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  animation: saSparkRegions 2.6s linear infinite alternate;
}




@media (prefers-reduced-motion: reduce) {
  .role-pill--super-admin::before,
  .role-pill--super-admin::after {
    animation: none !important;
    opacity: 0.35;
  }
}

html.is-bg-paused .role-pill--super-admin::before,
html.is-bg-paused .role-pill--super-admin::after {
  animation-play-state: paused !important;
}

/* Compact table variant — fits GÓI without covering SỐ DƯ VÍ */
.adm-td-plan .role-pill--super-admin,
.adm-table--users .role-pill--super-admin {
  padding: 2px 7px;
  font-size: 0.62rem;
  letter-spacing: 0.03em;
  box-shadow: none;
  filter: none;
  max-width: 100%;
}
.role-pill--ops { color: #38bdf8; background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.35); }
.role-pill--moderator { color: #a78bfa; background: rgba(167, 139, 250, 0.12); border: 1px solid rgba(167, 139, 250, 0.35); }
.role-pill--support { color: #34d399; background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.32); }
.role-pill--finance { color: #fb923c; background: rgba(251, 146, 60, 0.12); border: 1px solid rgba(251, 146, 60, 0.35); }

.adm-role-picker__internal {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 4px;
  padding-top: 10px;
  border-top: 1px dashed rgba(148, 163, 184, 0.28);
}
.adm-role-picker__hint {
  grid-column: 1 / -1;
  margin: 0 0 2px;
  font-size: 0.72rem;
  color: var(--text-tertiary);
  letter-spacing: 0.02em;
}

.adm-device-count {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.adm-device-count em {
  font-style: normal;
  color: var(--text-tertiary);
}

.adm-device-stack {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.adm-device-line {
  display: flex;
  align-items: baseline;
  gap: 6px;
  line-height: 1.25;
}

.adm-device-k {
  flex: 0 0 auto;
  min-width: 1.6rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.adm-empty-inline {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-tertiary);
}

.adm-section__sub--tight {
  margin: 0 0 0.65rem;
  font-size: 0.78rem;
  color: var(--text-tertiary);
}

.adm-pr-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.adm-pr-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.adm-pr-row__main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.adm-pr-row__main strong {
  font-size: 0.88rem;
  font-weight: 650;
  color: var(--text-primary);
}

.adm-pr-row__main small {
  font-size: 0.72rem;
  color: var(--text-tertiary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-pr-revoke {
  flex: 0 0 auto;
}

/* Action menu */
.adm-row-actions {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
}

.adm-menu-btn {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.adm-menu-btn:hover,
.adm-menu-btn.is-open {
  background: rgba(103, 232, 249, 0.08);
  border-color: rgba(103, 232, 249, 0.35);
  color: var(--text);
}

.adm-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 20;
  min-width: 168px;
  padding: 6px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-strong);
  background: rgba(8, 13, 24, 0.98);
  box-shadow: var(--shadow-lg);
  animation: adm-drop-in 0.18s ease;
}

@keyframes adm-drop-in {
  from { opacity: 0; transform: translateY(-6px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.adm-dropdown[hidden] { display: none; }

/* Portaled to <body> so it escapes the card's overflow:hidden / backdrop-filter clip */
.adm-dropdown--portal {
  position: fixed;
  right: auto;
  top: auto;
  margin: 0;
  z-index: 10050;
}

.adm-dropdown button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 9px 12px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.adm-dropdown button:hover { background: var(--surface-2); color: var(--text); }
.adm-dropdown button.danger { color: #fca5a5; }
.adm-dropdown button.danger:hover { background: rgba(248, 113, 113, 0.12); color: #fecaca; }

/* Permission matrix */
#panelPerms.adm-perms-console {
  --perm-green: #4d9b68;
  --perm-green-strong: #33794c;
  --perm-green-soft: rgba(77, 155, 104, .12);
}

.adm-perms-hero {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 108px;
  margin-bottom: 18px;
  padding: 22px 24px;
  overflow: hidden;
  border: 1px solid rgba(77, 155, 104, .2);
  border-radius: 18px;
  background:
    radial-gradient(circle at 91% 12%, rgba(77, 155, 104, .18), transparent 32%),
    linear-gradient(135deg, rgba(77, 155, 104, .09), rgba(77, 155, 104, .025));
}

.adm-perms-hero::after {
  content: "";
  position: absolute;
  right: -45px;
  bottom: -70px;
  width: 190px;
  height: 190px;
  border: 1px solid rgba(77, 155, 104, .12);
  border-radius: 50%;
}

.adm-perms-hero__icon {
  display: grid;
  place-items: center;
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  border: 1px solid rgba(77, 155, 104, .28);
  border-radius: 15px;
  color: #75bf8b;
  background: rgba(77, 155, 104, .13);
  box-shadow: inset 0 1px rgba(255, 255, 255, .08);
}

.adm-perms-hero__icon svg { width: 27px; height: 27px; }
.adm-perms-hero .adm-section__head { flex: 1; margin: 0; }
.adm-perms-hero .adm-section__head h2 { margin-bottom: 5px; font-size: 1.16rem; }

.adm-perms-hero__plans {
  z-index: 1;
  display: flex;
  padding-right: 8px;
}

.adm-perms-plan-dot {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-left: -7px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  color: #fff;
  font-size: .66rem;
  font-weight: 850;
  box-shadow: 0 4px 13px rgba(0, 0, 0, .2);
}

.adm-perms-plan-dot--user { background: #657183; }
.adm-perms-plan-dot--pro { background: #3e8b60; }
.adm-perms-plan-dot--ultra { color: #5d4404; background: #eac75d; }

.perm-matrix-wrap {
  position: relative;
  max-height: min(68vh, 760px);
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, .018);
  box-shadow: 0 14px 38px rgba(0, 0, 0, .12);
  scrollbar-color: rgba(77, 155, 104, .42) transparent;
  scrollbar-width: thin;
}

.perm-matrix {
  width: 100%;
  min-width: 680px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  font-size: 0.8rem;
}

.perm-matrix > thead > tr > th {
  position: sticky;
  top: 0;
  z-index: 8;
  height: 74px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-strong);
  background: rgba(13, 22, 18, .97);
  color: var(--text-tertiary);
  text-align: center;
  box-shadow: 0 7px 16px rgba(0, 0, 0, .08);
}

.perm-matrix > thead > tr > th:first-child {
  left: 0;
  z-index: 10;
  width: 47%;
  padding-left: 20px;
  text-align: left;
}

.perm-matrix > thead > tr > th:not(:first-child) { width: 17.666%; }

.perm-feature-heading {
  font-size: .67rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.perm-plan-head {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 92px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, .035);
}

.perm-plan-head__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-family: var(--font);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .045em;
  text-transform: none;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.35) inset,
    0 0 10px currentColor;
}

.perm-plan-head--user .perm-plan-head__badge {
  background: linear-gradient(180deg, var(--plan-user-c1, #5eead4), var(--plan-user-c3, #065f46));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 0 10px var(--plan-user-glow, rgba(16, 185, 129, 0.5));
}
.perm-plan-head--pro .perm-plan-head__badge {
  background: linear-gradient(180deg, var(--plan-pro-c1, #67e8f9), var(--plan-pro-c3, #1e3a8a));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 0 10px var(--plan-pro-glow, rgba(37, 99, 235, 0.5));
}
.perm-plan-head--ultra .perm-plan-head__badge {
  background: linear-gradient(180deg, var(--plan-ultra-c1, #fde68a), var(--plan-ultra-c3, #b45309));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 0 10px var(--plan-ultra-glow, rgba(245, 158, 11, 0.55));
}

.perm-plan-head strong {
  padding-left: 8px;
  border-left: 1px solid currentColor;
  font-size: .64rem;
  font-variant-numeric: tabular-nums;
  opacity: .68;
}

.perm-plan-head--user { color: #aab4c1; }
.perm-plan-head--pro { color: #72c58e; border-color: rgba(77, 155, 104, .3); background: rgba(77, 155, 104, .1); }
.perm-plan-head--ultra { color: #efcf6c; border-color: rgba(225, 187, 75, .3); background: rgba(225, 187, 75, .09); }

.perm-group-row th {
  padding: 10px 18px 8px;
  border-bottom: 1px solid rgba(77, 155, 104, .18);
  background: linear-gradient(90deg, rgba(77, 155, 104, .12), rgba(77, 155, 104, .025));
  color: #79bd8d;
  font-size: .68rem;
  font-weight: 850;
  letter-spacing: .08em;
  text-align: left;
  text-transform: uppercase;
}

.perm-group-row th small {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  margin-left: 8px;
  padding-inline: 5px;
  border-radius: 6px;
  color: var(--text-tertiary);
  background: rgba(255, 255, 255, .06);
  font-size: .61rem;
  letter-spacing: 0;
}

.perm-group-icon {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 9px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(77, 155, 104, .09);
  vertical-align: 1px;
}

.perm-feature-row td {
  height: 49px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  transition: background .15s ease;
}

.perm-feature-row:hover td { background: rgba(77, 155, 104, .055); }

.perm-feature-row td:first-child {
  position: sticky;
  left: 0;
  z-index: 3;
  padding-left: 20px;
  color: var(--text-secondary);
  background: var(--surface);
  box-shadow: 12px 0 18px -18px rgba(0, 0, 0, .7);
}

.perm-feature-row:hover td:first-child { background: color-mix(in srgb, var(--surface) 94%, var(--perm-green)); }
.perm-feature-row td:not(:first-child) { text-align: center; }

.perm-feature-name {
  display: block;
  overflow: hidden;
  color: var(--text);
  font-size: .79rem;
  font-weight: 650;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.perm-feature-row code {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--text-tertiary);
  font-family: var(--font-mono, monospace);
  font-size: .58rem;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
  opacity: .65;
}

.tier-label {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  font-size: 0.68rem;
}

.tier-label--user { color: #94a3b8; background: rgba(148, 163, 184, 0.1); }
.tier-label--pro { color: #72c58e; background: rgba(77, 155, 104, .12); }
.tier-label--ultra {
  color: var(--ultra-gold-text);
  background: var(--ultra-gold-soft);
  border: 1px solid var(--ultra-gold-border);
}
.tier-label--ops { color: #38bdf8; background: rgba(56, 189, 248, 0.12); border: 1px solid rgba(56, 189, 248, 0.3); }
.tier-label--moderator { color: #a78bfa; background: rgba(167, 139, 250, 0.12); border: 1px solid rgba(167, 139, 250, 0.3); }
.tier-label--support { color: #34d399; background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.28); }
.tier-label--finance { color: #fb923c; background: rgba(251, 146, 60, 0.12); border: 1px solid rgba(251, 146, 60, 0.3); }

.adm-perms-internal-head {
  margin-top: 1.5rem;
}

.perm-matrix--staff-caps {
  margin-bottom: 1rem;
}

.perm-toggle {
  width: 40px;
  height: 23px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.055);
  position: relative;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, box-shadow .2s, transform .15s;
}

.perm-toggle::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #7c8795;
  transition: transform 0.22s cubic-bezier(0.34, 1.4, 0.64, 1), background 0.2s;
}

.perm-toggle:hover { border-color: rgba(77, 155, 104, .5); transform: translateY(-1px); }
.perm-toggle:focus-visible { outline: 2px solid rgba(77, 155, 104, .55); outline-offset: 3px; }

.perm-toggle.on {
  background: rgba(77, 155, 104, .2);
  border-color: rgba(77, 155, 104, .52);
}

.perm-toggle.on::after {
  transform: translateX(17px);
  background: #64b47e;
  box-shadow: 0 0 7px rgba(77, 155, 104, .42);
}

#panelPerms .adm-perm-actions {
  position: sticky;
  bottom: 10px;
  z-index: 12;
  width: max-content;
  margin: 16px 0 0 auto;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
  backdrop-filter: blur(14px);
}

@media (max-width: 720px) {
  .adm-perms-hero { min-height: 92px; padding: 18px; }
  .adm-perms-hero__icon { width: 44px; height: 44px; flex-basis: 44px; }
  .adm-perms-hero__plans { display: none; }
  .perm-matrix-wrap { max-height: 66vh; border-radius: 13px; }
  .perm-matrix { min-width: 620px; }
  .perm-matrix > thead > tr > th:first-child { width: 43%; padding-left: 14px; }
  .perm-matrix > thead > tr > th:not(:first-child) { width: 19%; }
  .perm-feature-row td:first-child { padding-left: 14px; }
  .perm-plan-head { min-width: 80px; padding: 7px 8px; gap: 6px; }
  .perm-plan-head strong { padding-left: 6px; }
  #panelPerms .adm-perm-actions { bottom: 6px; width: 100%; justify-content: flex-end; }
}

/* ── Overlays & dialogs ─────────────────────────────────── */

.adm-overlay,
.adm-drawer-wrap {
  position: fixed;
  inset: 0;
  /* Above currency/settings FAB (~1150) so modal footers stay clickable */
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 20px;
}

/* Confirm must sit above portaled row menus (z-index 10050) and other overlays */
#confirmOverlay {
  z-index: 11000;
}

/* Step-up must appear ON TOP of change-plan / other admin modals during sensitive saves */
#stepUpOverlay.adm-overlay--stepup,
#stepUpOverlay {
  z-index: 12000;
}

/* Hide floating FABs while any admin overlay/drawer is open */
body:has(.adm-overlay:not([hidden])) .currency-fab,
body:has(.adm-drawer-wrap:not([hidden])) .currency-fab {
  visibility: hidden !important;
  pointer-events: none !important;
}

.adm-stepup-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 4px 4px;
}

.adm-stepup-google {
  width: 100%;
  justify-content: center;
}

.adm-stepup-or {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--adm-muted, #6b8f7a);
  font-size: 0.78rem;
  text-transform: lowercase;
}

.adm-stepup-or::before,
.adm-stepup-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: color-mix(in srgb, currentColor 28%, transparent);
}

.adm-field-hint {
  margin: 0 4px 8px;
  font-size: 0.82rem;
  color: #c45c5c;
}

.adm-field-hint[hidden] {
  display: none;
}

.adm-overlay[hidden],
.adm-drawer-wrap[hidden] { display: none; }

.adm-overlay__backdrop,
.adm-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  animation: adm-fade-in 0.22s ease;
}

@keyframes adm-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.adm-dialog {
  position: relative;
  width: min(400px, 100%);
  padding: 28px 26px 22px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-strong);
  background: rgba(8, 13, 24, 0.97);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  text-align: center;
  animation: adm-dialog-in 0.28s cubic-bezier(0.34, 1.3, 0.64, 1);
}

@keyframes adm-dialog-in {
  from { opacity: 0; transform: scale(0.92) translateY(12px); }
  to { opacity: 1; transform: none; }
}

.adm-dialog__glow {
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(167, 139, 250, 0.2), transparent 70%);
}

.adm-dialog--danger .adm-dialog__glow {
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(248, 113, 113, 0.18), transparent 70%);
}

.adm-dialog--success .adm-dialog__glow {
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(110, 231, 183, 0.18), transparent 70%);
}

.adm-dialog__icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 14px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  background: rgba(103, 232, 249, 0.12);
  border: 1px solid rgba(103, 232, 249, 0.28);
}

.adm-dialog--danger .adm-dialog__icon {
  background: rgba(248, 113, 113, 0.12);
  border-color: rgba(248, 113, 113, 0.35);
}

.adm-dialog--warn .adm-dialog__icon {
  background: rgba(251, 191, 36, 0.12);
  border-color: rgba(251, 191, 36, 0.35);
}

.adm-dialog__title {
  margin: 0 0 8px;
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.adm-dialog__message {
  margin: 0 0 22px;
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.adm-dialog__actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.adm-dialog__actions .btn { min-width: 110px; }

.adm-dialog--danger #confirmOkBtn {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  border-color: transparent;
}

.adm-modal {
  position: relative;
  width: min(460px, 100%);
  max-height: min(90vh, 680px);
  overflow: auto;
  padding: 22px 24px 20px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-strong);
  background: rgba(8, 13, 24, 0.98);
  box-shadow: var(--shadow-lg);
  animation: adm-dialog-in 0.28s cubic-bezier(0.34, 1.3, 0.64, 1);
}

.adm-modal--wide { width: min(540px, 100%); }
.adm-modal--sm { width: min(380px, 100%); }
.adm-modal--devices { width: min(680px, 100%); }

.adm-modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.adm-modal__head h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 800;
}

.adm-modal__close {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.adm-modal__close:hover {
  background: rgba(248, 113, 113, 0.12);
  color: #fecaca;
  border-color: rgba(248, 113, 113, 0.3);
}

.adm-modal__user {
  margin: 0 0 16px;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

.adm-modal__foot {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.adm-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.adm-preset {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.adm-preset:hover,
.adm-preset.active {
  border-color: rgba(103, 232, 249, 0.45);
  color: var(--accent-cyan);
  background: rgba(103, 232, 249, 0.08);
}

.adm-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.adm-field span {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.adm-field span em {
  color: #fca5a5;
  font-style: normal;
}

.adm-field input,
.adm-field select {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.32);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.86rem;
}

.adm-field input:focus {
  outline: none;
  border-color: rgba(103, 232, 249, 0.45);
  box-shadow: 0 0 0 3px rgba(103, 232, 249, 0.08);
}

.adm-form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 14px;
}

.adm-form__grid .adm-field:only-child,
#fieldUsername { grid-column: 1 / -1; }

.adm-field--avatar { grid-column: 1 / -1; }

.adm-avatar-edit {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.adm-avatar--lg {
  width: 72px;
  height: 72px;
  min-width: 72px;
  min-height: 72px;
  border-radius: 16px;
  font-size: 1.4rem;
}

.adm-avatar-edit__body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.adm-avatar-edit__btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.adm-avatar-edit__hint {
  margin: 0;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.adm-prices-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 8px;
}

.adm-prices-card {
  padding: 18px 20px;
  border-radius: var(--radius-md);
}

.adm-prices-plan {
  margin: 0 0 14px;
  font-size: 1rem;
}

.adm-prices-preview {
  margin: -4px 0 12px;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.adm-prices-preview strong {
  color: var(--text);
}

.adm-smm-markup {
  padding: 18px 20px;
  border-radius: var(--radius-md);
  max-width: 420px;
}

.adm-smm-markup .adm-field {
  margin-bottom: 8px;
}

.adm-smm-markup .adm-field input {
  max-width: 160px;
}

.adm-smm-markup .panel-form-actions {
  margin-top: 12px;
  margin-bottom: 0;
}

.adm-security-metrics {
  margin: 0;
  padding: 12px 14px;
  max-width: 100%;
  overflow: auto;
  font-size: 0.78rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text-secondary);
  background: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
}

#sectionSecurityMetrics .adm-smm-markup {
  max-width: 640px;
}

@media (max-width: 820px) {
  .adm-prices-grid { grid-template-columns: 1fr; }
}

.adm-role-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 8px;
}

.adm-role-opt {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
}

.adm-role-opt:hover { background: rgba(255, 255, 255, 0.06); }

.adm-role-opt.selected {
  border-color: rgba(103, 232, 249, 0.65);
  background: rgba(103, 232, 249, 0.14);
  box-shadow: 0 0 0 3px rgba(103, 232, 249, 0.18);
  transform: translateY(-1px);
}

.adm-expiry-current {
  margin: 0 0 12px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.adm-expiry-presets { margin-bottom: 10px; }

.adm-expiry-clear-wrap {
  margin: 4px 0 8px;
}

.adm-expiry-clear {
  color: #fca5a5;
  border-color: rgba(252, 165, 165, 0.25);
}

.adm-expiry-clear:hover {
  color: #fecaca;
  border-color: rgba(252, 165, 165, 0.45);
  background: rgba(252, 165, 165, 0.08);
}

.adm-expiry-clear.is-active {
  border-color: rgba(252, 165, 165, 0.55);
  background: rgba(252, 165, 165, 0.12);
  color: #fecaca;
}

/* Drawer */
.adm-drawer-wrap {
  place-items: stretch;
  justify-items: end;
  padding: 0;
}

.adm-drawer {
  position: relative;
  width: min(420px, 100vw);
  height: 100%;
  max-height: 100dvh;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  border-left: 1px solid var(--border-strong);
  background: rgba(6, 10, 20, 0.98);
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.45);
  animation: adm-drawer-in 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes adm-drawer-in {
  from { transform: translateX(100%); }
  to { transform: none; }
}

.adm-drawer__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 22px 20px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.adm-drawer__user {
  display: flex;
  gap: 14px;
  align-items: center;
}

.adm-drawer__user h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
}

.adm-drawer__user p {
  margin: 4px 0 0;
  font-size: 0.8rem;
  color: var(--text-tertiary);
}

.adm-drawer__close {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
}

.adm-drawer__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 18px 20px;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) transparent;
}

.adm-drawer__body::-webkit-scrollbar {
  width: 8px;
}

.adm-drawer__body::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 999px;
}

.adm-drawer__body::-webkit-scrollbar-thumb:hover {
  background: var(--scrollbar-thumb-hover);
}

.adm-drawer__foot {
  display: flex;
  flex-wrap: wrap;
  flex-shrink: 0;
  gap: 8px;
  padding: 14px 20px 18px;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

.adm-drawer__loading {
  text-align: center;
  color: var(--text-tertiary);
  padding: 40px 0;
}

.adm-drawer-skel {
  padding: 24px 0 32px;
}

.adm-detail-section {
  margin-bottom: 20px;
}

.adm-detail-section h3 {
  margin: 0 0 10px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
}

.adm-kv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.adm-kv {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.22);
}

.adm-kv span {
  display: block;
  font-size: 0.66rem;
  color: var(--text-tertiary);
  margin-bottom: 4px;
}

.adm-kv strong {
  font-size: 0.84rem;
  font-weight: 600;
}

.adm-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.adm-history-list li {
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.18);
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.adm-history-list li strong {
  color: var(--text);
  font-weight: 600;
}

.adm-device-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.adm-device-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
  font-size: 0.78rem;
  font-family: monospace;
  color: var(--text-secondary);
}

/* ── Revenue & Leader ───────────────────────────────────── */

.adm-section--revenue > .adm-section__head {
  margin-bottom: 14px;
}

.adm-section--revenue > .adm-section__head h2 {
  margin-bottom: 5px;
  font-size: 1.08rem;
  letter-spacing: -0.025em;
}

.adm-section--revenue > .adm-section__head .adm-section__sub {
  max-width: 720px;
  font-size: 0.76rem;
}

.adm-revenue-lock {
  padding: 32px 24px;
  text-align: center;
  border-radius: var(--radius-md);
  border: 1px dashed rgba(240, 171, 252, 0.35);
  background: rgba(240, 171, 252, 0.06);
}

.adm-revenue-lock__icon {
  font-size: 2rem;
  margin-bottom: 10px;
}

.adm-revenue-lock p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
  max-width: 480px;
  margin-inline: auto;
  line-height: 1.55;
}

.adm-revenue-grid {
  display: grid;
  grid-template-columns: minmax(620px, 1.42fr) minmax(360px, 0.88fr);
  gap: 14px;
  width: 100%;
  align-items: stretch;
}

.adm-revenue-col {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(8, 13, 24, 0.38);
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
}

.adm-revenue-col--users,
.adm-revenue-col--teams {
  height: min(68vh, 660px);
  min-height: 480px;
}

.adm-revenue-col--users {
  display: flex;
  flex-direction: column;
}

.adm-revenue-table-viewport {
  flex: 1;
  min-height: 0;
  overflow: auto !important;
  padding: 0 !important;
  scrollbar-gutter: stable;
}

.adm-leaders-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  height: calc(100% - 59px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
}

.adm-revenue-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding: 10px 12px 10px 14px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.018);
}

.adm-revenue-card-title {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.adm-revenue-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.035);
}

.adm-revenue-card-icon svg,
.adm-revenue-search > svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.adm-revenue-card-head h3 {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.adm-revenue-hint {
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.68rem;
  color: var(--text-secondary);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  background: rgba(255, 255, 255, 0.025);
}

.adm-revenue-search {
  position: relative;
  display: flex;
  align-items: center;
  width: min(210px, 42%);
}

.adm-revenue-search > svg {
  position: absolute;
  z-index: 1;
  left: 10px;
  color: var(--text-tertiary);
  pointer-events: none;
}

.adm-search--compact {
  width: 100%;
  height: 34px;
  padding: 7px 10px 7px 31px;
  border-radius: 8px;
  font-size: 0.76rem;
}

.adm-table--revenue th,
.adm-table--revenue td {
  padding-top: 8px;
  padding-bottom: 8px;
}

.adm-table--revenue th {
  top: 0;
  background: rgba(8, 13, 24, 0.98);
}

.adm-table--revenue tbody tr.is-leader td:first-child {
  box-shadow: inset 2px 0 0 var(--accent-cyan);
}

.adm-table--revenue .adm-switch-cell {
  text-align: center;
  padding-left: 4px;
  padding-right: 4px;
  overflow: visible;
  white-space: nowrap;
}

.adm-table--revenue .adm-switch-cell .perm-toggle {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.adm-leader-card {
  padding: 11px 12px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.018);
  transition: border-color 0.18s, background 0.18s, transform 0.18s;
}

.adm-leader-card:hover {
  border-color: rgba(103, 232, 249, 0.25);
  background: rgba(103, 232, 249, 0.025);
  transform: translateY(-1px);
}

.adm-leader-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.adm-leader-card__identity {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.adm-leader-card__identity .adm-avatar {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  flex: 0 0 32px;
}

.adm-leader-card__identity-text {
  min-width: 0;
}

.adm-leader-card__name {
  font-weight: 700;
  font-size: 0.8rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-leader-card__user {
  margin-top: 1px;
  font-size: 0.67rem;
  color: var(--text-tertiary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-leader-card__meta {
  margin: 9px 0 6px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  color: var(--text-tertiary);
  font-size: 0.64rem;
  font-weight: 650;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}

.adm-member-tags {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.adm-member-row {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 7px;
  padding: 5px 2px;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 68%, transparent);
}

.adm-member-row:nth-last-child(-n + 2) {
  border-bottom-color: transparent;
}

.adm-member-row__mark {
  width: 5px;
  height: 5px;
  flex: 0 0 5px;
  border-radius: 50%;
  background: var(--text-tertiary);
}

.adm-member-row__identity {
  display: block;
  min-width: 0;
}

.adm-member-row__identity strong,
.adm-member-row__identity small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-member-row__identity strong {
  color: var(--text-secondary);
  font-size: 0.7rem;
  font-weight: 600;
}

.adm-member-row__identity small {
  margin-top: 1px;
  color: var(--text-tertiary);
  font-size: 0.61rem;
}

.adm-member-row--more {
  justify-content: center;
  color: var(--text-tertiary);
  font-size: 0.68rem;
  font-weight: 700;
}

.adm-edit-team-btn {
  min-height: 28px;
  padding: 5px 9px;
  border-radius: 7px;
  font-size: 0.68rem;
}

.adm-member-tag--empty {
  color: var(--text-tertiary);
  font-style: italic;
  grid-column: 1 / -1;
  border-bottom: 0;
  font-size: 0.7rem;
}

.adm-team-checklist {
  max-height: min(50vh, 400px);
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.adm-team-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.15s;
}

.adm-team-row:hover { background: var(--surface-2); }
.adm-team-row.is-selected { background: rgba(103, 232, 249, 0.08); }
.adm-team-row.is-hidden { display: none; }

.adm-team-row input { accent-color: var(--accent-cyan); flex-shrink: 0; }

.adm-team-row-main strong {
  display: block;
  font-size: 0.84rem;
}

.adm-team-row-main small {
  font-size: 0.72rem;
  color: var(--text-tertiary);
}

.adm-team-selected {
  margin: 10px 0 0;
  font-size: 0.78rem;
  color: var(--text-tertiary);
  font-weight: 600;
}

.adm-team-name-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 12px;
}

.adm-team-name-field > span {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-secondary);
}

.adm-team-name-field .adm-search {
  margin: 0;
}

@media (max-width: 1180px) {
  .adm-revenue-grid { grid-template-columns: 1fr; }
  .adm-revenue-col--users,
  .adm-revenue-col--teams {
    height: auto;
    min-height: 0;
  }
  .adm-revenue-table-viewport { max-height: 580px; }
  .adm-leaders-grid {
    height: auto;
    max-height: 520px;
  }
}

@media (max-width: 900px) {
  .admin-card .admin-stats.panel-stats {
    grid-template-columns: repeat(2, 1fr);
    margin-inline: 18px;
  }
  .admin-tab.admin-section-link {
    min-height: 42px;
    font-size: 0.78rem;
    padding: 10px 13px;
  }
  .admin-card-head__row { flex-direction: column; align-items: stretch; }
}

@media (max-width: 640px) {
  .admin-card .admin-stats.panel-stats { grid-template-columns: 1fr; }
  .admin-card-head.panel-card-head {
    padding-bottom: 12px;
  }
  .admin-card-kicker {
    margin-bottom: 6px;
  }
  .admin-card-cta {
    width: 100%;
    justify-content: center;
  }
  .admin-tabs-shell {
    margin-bottom: 14px;
  }
  .admin-tabs {
    padding: 3px;
    border-radius: 12px;
    gap: 1px;
  }
  .admin-tab.admin-section-link {
    min-height: 42px;
    padding: 9px 12px;
    font-size: 0.76rem;
    border-radius: 9px;
  }
  .admin-tabs-divider {
    flex-basis: 8px;
    width: 8px;
    margin: 0 1px;
  }
  .adm-form__grid { grid-template-columns: 1fr; }
  .adm-kv-grid { grid-template-columns: 1fr; }
  .adm-role-picker { grid-template-columns: 1fr; }
  .adm-table--users th.adm-th-last-tool,
  .adm-table--users td.adm-td-last-tool,
  .adm-table--users col.adm-col-last-tool { display: none; }
  .adm-table--users col.adm-col-devices { width: 0; }
  .adm-table--users col.adm-col-account { width: 40%; }
  .adm-table--users.is-selecting col.adm-col-account { width: 36%; }
  .adm-table--users col.adm-col-plan { width: 64px; }
  .adm-table--users .adm-td-plan { width: 64px; }
  .adm-bulk-bar__actions { margin-left: 0; width: 100%; }
  .adm-table--revenue col.adm-col-toggle { width: 72px; }
  .adm-table--revenue col.adm-col-actions { width: 92px; }
  .adm-table--revenue th:last-child,
  .adm-table--revenue td:last-child .btn { font-size: 0.74rem; padding-inline: 8px; }
  .adm-revenue-card-head {
    align-items: stretch;
    flex-direction: column;
  }
  .adm-revenue-col--teams .adm-revenue-card-head {
    align-items: center;
    flex-direction: row;
  }
  .adm-revenue-search { width: 100%; }
  .adm-revenue-search .adm-search--compact {
    min-height: 36px;
    padding-left: 31px;
  }
  .adm-member-tags { grid-template-columns: 1fr; }
  .adm-member-row { border-bottom-color: var(--border); }
  .adm-member-row:last-child { border-bottom-color: transparent; }
}

/* ── Admin console — compact mobile (≤768px) ─────────────────── */
@media (max-width: 768px) {
  .admin-tabs-shell {
    margin-bottom: 14px;
  }

  .admin-tabs {
    margin-bottom: 0;
    gap: 1px;
    padding: 3px;
  }

  .admin-tab.admin-section-link {
    min-height: 42px;
    padding: 9px 11px;
    font-size: 0.74rem;
  }

  .admin-card .admin-stats.panel-stats {
    margin: 0 14px 12px;
    gap: 8px;
  }

  .admin-card-head.panel-card-head {
    padding: 14px 14px 0;
  }

  .admin-card-body.panel-card-body {
    padding: 12px 14px 14px;
  }

  .admin-card-head__row {
    gap: 10px;
  }

  .admin-card-head__row h1,
  .admin-card .panel-card-head h1 {
    font-size: 1.1rem;
  }

  .admin-card .panel-lead {
    font-size: 0.82rem;
  }

  .admin-stat-muted {
    font-size: 0.88rem !important;
  }

  .panel-stat {
    padding: 8px 10px;
  }

  .panel-stat span {
    font-size: 0.65rem;
    margin-bottom: 4px;
  }

  .panel-stat strong {
    font-size: 0.9rem;
  }

  .adm-toolbar {
    gap: 8px;
  }

  .adm-search {
    min-height: 40px;
    padding: 8px 12px 8px 32px;
    font-size: 0.84rem;
  }

  .adm-select {
    min-height: 40px;
    padding: 8px 32px 8px 10px;
    font-size: 0.82rem;
  }

  .adm-table th,
  .adm-table td {
    padding: 9px 6px;
  }

  .adm-empty {
    padding: 24px !important;
  }

  .adm-deposit-summary {
    margin-bottom: 14px;
    padding: 14px 14px 12px;
  }

  .adm-deposit-summary__head {
    margin-bottom: 10px;
  }

  .adm-deposit-summary__head h3 {
    font-size: 0.88rem;
  }

  #navVisibilityWrap .adm-deposit-toggle {
    padding: 8px 0;
    gap: 12px;
  }

  .adm-deposit-kpi-grid {
    gap: 8px;
  }

  .adm-deposit-kpi {
    padding: 10px 12px;
  }

  .adm-deposit-kpi__label {
    font-size: 0.68rem;
  }

  .adm-deposit-kpi__value {
    font-size: 0.95rem;
  }

  .adm-prices-card {
    padding: 14px;
  }

  .adm-prices-plan {
    margin-bottom: 10px;
    font-size: 0.92rem;
  }

  .adm-prices-preview {
    font-size: 0.82rem;
  }

  .adm-role-opt {
    padding: 12px;
  }

  .adm-drawer__head {
    padding: 16px 14px 12px;
  }

  .adm-drawer__user h2 {
    font-size: 0.98rem;
  }

  #panelChannels .channels-manage-stats {
    margin: 0 0 10px;
  }

  #panelChannels .channels-manage-toolbar {
    margin-bottom: 10px;
  }
}

/* ── Light theme — admin console (forest sage) ── */
html[data-theme="light"] .admin-tabs-shell {
  --admin-tabs-fade: #f3f7f2;
  --admin-tabs-rail: linear-gradient(180deg, #f7faf6 0%, #eef3ee 100%);
  --admin-tabs-rail-border: rgba(61, 122, 74, 0.14);
  --admin-tabs-ink: rgba(31, 61, 40, 0.64);
  --admin-tabs-ink-strong: #143022;
  --admin-tabs-hover: rgba(61, 122, 74, 0.07);
  --admin-tabs-active-line: #2f6b3c;
  --admin-tabs-focus: rgba(61, 122, 74, 0.4);
  --admin-tabs-divider: transparent;
}

html[data-theme="light"] .admin-tabs {
  background: var(--admin-tabs-rail);
  border-color: var(--admin-tabs-rail-border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(40, 70, 48, 0.04),
    0 1px 2px rgba(40, 70, 48, 0.04);
}

html[data-theme="light"] .admin-tabs-divider {
  background: transparent;
}

html[data-theme="light"] .admin-tab.admin-section-link:hover {
  background: var(--admin-tabs-hover);
}

html[data-theme="light"] .admin-tab.admin-section-link.active {
  color: #143022;
  background: transparent;
}

html[data-theme="light"] .admin-tab.admin-section-link:focus-visible {
  outline-color: var(--admin-tabs-focus);
}

html[data-theme="light"] .admin-card-head.panel-card-head {
  border-bottom-color: rgba(61, 122, 74, 0.12);
}

html[data-theme="light"] .admin-card-kicker {
  color: rgba(61, 122, 74, 0.72);
}

html[data-theme="light"] .admin-card-head__row h1 {
  color: #143022;
}

html[data-theme="light"] .admin-card-head__row .panel-lead {
  color: rgba(31, 61, 40, 0.56);
}

html[data-theme="light"] .adm-section__head h2 {
  color: #1f3d28;
  font-weight: 700;
}

html[data-theme="light"] .adm-search,
html[data-theme="light"] .adm-select,
html[data-theme="light"] .adm-field input,
html[data-theme="light"] .adm-field select {
  background: var(--surface-2);
  border-color: var(--border-strong);
}

html[data-theme="light"] .adm-search:focus,
html[data-theme="light"] .adm-field input:focus {
  border-color: rgba(61, 122, 74, 0.45);
  box-shadow: 0 0 0 3px rgba(176, 212, 184, 0.35);
}

html[data-theme="light"] .adm-select {
  background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23547398' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 10px center;
}

html[data-theme="light"] .adm-table th {
  background: var(--surface-2);
  box-shadow: 0 1px 0 var(--border);
}

html[data-theme="light"] .adm-table tbody tr:hover td {
  background: rgba(176, 212, 184, 0.14);
}

html[data-theme="light"] .adm-cap-layout {
  background: rgba(255, 255, 255, .5);
}

html[data-theme="light"] .adm-cap-admins {
  background: rgba(242, 248, 240, .66);
}

html[data-theme="light"] .adm-cap-search input,
html[data-theme="light"] .adm-cap-detail__head,
html[data-theme="light"] .adm-cap-group {
  background: rgba(255, 255, 255, .78);
}

html[data-theme="light"] .adm-cap-admin-item.is-selected,
html[data-theme="light"] .adm-cap-group__head {
  color: #456950;
  background: rgba(176, 212, 184, .2);
}

html[data-theme="light"] .adm-cap-admin-item:hover {
  background: rgba(176, 212, 184, .16);
}

html[data-theme="light"] .adm-cap-admin-avatar {
  color: #3d7a4a;
  border-color: rgba(61, 122, 74, .18);
  background: rgba(176, 212, 184, .22);
}

html[data-theme="light"] .adm-avatar {
  color: #3d7a4a;
  background: rgba(176, 212, 184, 0.22);
  border-color: rgba(139, 191, 149, 0.45);
}

html[data-theme="light"] .adm-avatar--has-img {
  background: var(--surface-3);
}

html[data-theme="light"] .role-pill--user,
html[data-theme="light"] .role-pill--pro,
html[data-theme="light"] .role-pill--ultra,
html[data-theme="light"] .role-pill--admin {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.5);
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.28);
}

html[data-theme="light"] .tier-label--ultra {
  color: var(--ultra-gold-text);
  background: var(--ultra-gold-soft);
  border-color: var(--ultra-gold-border);
}

html[data-theme="light"] .role-pill--super-admin {
  --sa-fill: linear-gradient(145deg, #E11D48 0%, #BE123C 40%, #9F1239 75%, #7F1D1D 100%);
  color: #FFFFFF;
  border: none;
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.65),
    0 0 5px rgba(0, 0, 0, 0.3);
  background: var(--sa-fill);
  box-shadow:
    0 0 0 1px rgba(255, 200, 200, 0.18) inset,
    0 1px 0 rgba(255, 255, 255, 0.2) inset;
  animation: none;
  filter: none;
}
html[data-theme="light"] .role-pill--ops {
  color: #0369a1;
  background: rgba(2, 132, 199, 0.1);
  border-color: rgba(2, 132, 199, 0.28);
}
html[data-theme="light"] .role-pill--moderator {
  color: #6d28d9;
  background: rgba(124, 58, 237, 0.1);
  border-color: rgba(124, 58, 237, 0.28);
}
html[data-theme="light"] .role-pill--support {
  color: #047857;
  background: rgba(5, 150, 105, 0.1);
  border-color: rgba(5, 150, 105, 0.28);
}
html[data-theme="light"] .role-pill--finance {
  color: #c2410c;
  background: rgba(194, 65, 12, 0.1);
  border-color: rgba(194, 65, 12, 0.28);
}

html[data-theme="light"] .adm-menu-btn {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-menu-btn:hover,
html[data-theme="light"] .adm-menu-btn.is-open {
  background: rgba(176, 212, 184, 0.22);
  border-color: rgba(61, 122, 74, 0.32);
}

html[data-theme="light"] .adm-dropdown {
  background: var(--bg-elevated);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

html[data-theme="light"] .adm-dropdown button.danger {
  color: #bf4a4a;
}

html[data-theme="light"] .adm-dropdown button.danger:hover {
  background: rgba(191, 74, 74, 0.08);
  color: #a33f3f;
}

html[data-theme="light"] .perm-matrix th {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-perms-hero {
  border-color: rgba(61, 122, 74, .22);
  background:
    radial-gradient(circle at 91% 12%, rgba(92, 156, 107, .17), transparent 32%),
    linear-gradient(135deg, rgba(176, 212, 184, .18), rgba(255, 255, 255, .48));
}

html[data-theme="light"] .adm-perms-hero__icon {
  color: #397c4d;
  background: rgba(176, 212, 184, .24);
}

html[data-theme="light"] .perm-matrix-wrap {
  background: rgba(255, 255, 255, .52);
  box-shadow: 0 12px 30px rgba(50, 88, 59, .08);
}

html[data-theme="light"] .perm-matrix > thead > tr > th {
  background: rgba(239, 247, 238, .98);
}

html[data-theme="light"] .perm-group-row th {
  color: #397c4d;
  background: linear-gradient(90deg, rgba(176, 212, 184, .26), rgba(239, 247, 238, .8));
}

html[data-theme="light"] .perm-feature-row td:first-child {
  background: #f7fbf5;
}

html[data-theme="light"] .perm-feature-row:hover td,
html[data-theme="light"] .perm-feature-row:hover td:first-child {
  background: #edf6eb;
}

html[data-theme="light"] .perm-plan-head {
  background: rgba(255, 255, 255, .68);
}

html[data-theme="light"] .perm-toggle {
  background: var(--surface-3);
}

html[data-theme="light"] .perm-toggle.on {
  background: rgba(176, 212, 184, 0.35);
  border-color: rgba(61, 122, 74, 0.38);
}

html[data-theme="light"] .perm-toggle.on::after {
  background: #3d7a4a;
  box-shadow: none;
}

html[data-theme="light"] .adm-overlay__backdrop,
html[data-theme="light"] .adm-drawer__backdrop {
  background: rgba(45, 90, 76, 0.35);
}

html[data-theme="light"] .adm-dialog,
html[data-theme="light"] .adm-modal {
  background: var(--bg-elevated);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

html[data-theme="light"] .adm-dialog__glow {
  opacity: 0.35;
}

html[data-theme="light"] .adm-dialog__icon {
  background: rgba(176, 212, 184, 0.22);
  border-color: rgba(139, 191, 149, 0.45);
}

html[data-theme="light"] .adm-modal__close {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-modal__close:hover {
  background: rgba(191, 74, 74, 0.08);
  color: #bf4a4a;
  border-color: rgba(191, 74, 74, 0.2);
}

html[data-theme="light"] .adm-preset {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-preset:hover,
html[data-theme="light"] .adm-preset.active {
  border-color: rgba(61, 122, 74, 0.38);
  color: #3d7a4a;
  background: rgba(176, 212, 184, 0.22);
}

html[data-theme="light"] .adm-role-opt {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-role-opt:hover {
  background: var(--surface-3);
}

html[data-theme="light"] .adm-role-opt.selected {
  border-color: rgba(61, 122, 74, 0.72);
  background: rgba(176, 212, 184, 0.42);
  box-shadow: 0 0 0 3px rgba(61, 122, 74, 0.16);
}

html[data-theme="light"] .adm-drawer {
  background: var(--bg-elevated);
  box-shadow: -12px 0 40px rgba(40, 80, 50, 0.1);
}

html[data-theme="light"] .adm-drawer__foot {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-kv,
html[data-theme="light"] .adm-history-list li,
html[data-theme="light"] .adm-device-chip {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-revenue-lock {
  border-color: rgba(191, 74, 74, 0.22);
  background: rgba(191, 74, 74, 0.05);
}

html[data-theme="light"] .adm-revenue-col {
  border-color: rgba(67, 92, 73, 0.16);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 38px rgba(55, 83, 62, 0.075);
}

html[data-theme="light"] .adm-revenue-card-head {
  background: rgba(243, 247, 241, 0.78);
}

html[data-theme="light"] .adm-revenue-card-icon,
html[data-theme="light"] .adm-revenue-hint {
  border-color: rgba(67, 92, 73, 0.14);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .adm-table--revenue th {
  background: rgba(246, 249, 245, 0.98);
}

html[data-theme="light"] .adm-table--revenue tbody tr.is-leader td:first-child {
  box-shadow: inset 2px 0 0 #3d7a4a;
}

html[data-theme="light"] .adm-leader-card {
  border-color: rgba(67, 92, 73, 0.14);
  background: rgba(255, 255, 255, 0.72);
}

html[data-theme="light"] .adm-leader-card:hover {
  border-color: rgba(61, 122, 74, 0.32);
  background: rgba(176, 212, 184, 0.12);
}

html[data-theme="light"] .adm-member-row__mark {
  background: #77907d;
}

html[data-theme="light"] .adm-prices-preview {
  color: var(--text-secondary);
}

html[data-theme="light"] .adm-prices-preview strong {
  color: var(--text);
}

html[data-theme="light"] .tier-label--pro {
  color: #3d7a4a;
  background: rgba(176, 212, 184, 0.22);
}


/* ── Deposit Summary (Phân quyền gói tab, root admin only) ── */

.adm-deposit-summary {
  margin-bottom: 20px;
  padding: 18px 20px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(var(--sage-rgb, 61,122,74), 0.04);
}

.adm-deposit-summary__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.adm-deposit-summary__head h3 {
  margin: 0;
  font-size: 0.93rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

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

.adm-deposit-kpi {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
  min-width: 0;
}

.adm-deposit-kpi--total {
  border-color: rgba(var(--sage-rgb, 61,122,74), 0.3);
  background: rgba(var(--sage-rgb, 61,122,74), 0.06);
}

.adm-deposit-kpi__icon {
  font-size: 1.1rem;
  line-height: 1;
  margin-bottom: 2px;
}

.adm-deposit-kpi__label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 500;
  line-height: 1.35;
}

.adm-deposit-kpi__value {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.adm-deposit-kpi--total .adm-deposit-kpi__value {
  color: var(--accent, #3d7a4a);
}

.adm-deposit-note {
  margin: 12px 0 0;
  font-size: 0.72rem;
  color: var(--text-tertiary);
  line-height: 1.5;
}

.adm-deposit-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle, rgba(255,255,255,.08));
  background: rgba(255,255,255,.02);
}

.adm-deposit-toggle__text strong {
  display: block;
  font-size: .92rem;
  margin-bottom: 4px;
}

.adm-deposit-toggle__text p {
  margin: 0;
  font-size: .78rem;
  color: var(--text-tertiary);
  line-height: 1.45;
}

/* Compact nav-visibility toggle list: dividers instead of large gaps */
#navVisibilityWrap .adm-deposit-toggle {
  margin-top: 0;
  padding: 9px 2px;
  border: none;
  border-radius: 0;
  background: transparent;
}

#navVisibilityWrap .adm-deposit-toggle + .adm-deposit-toggle {
  border-top: 1px solid var(--border);
}

#navVisibilityWrap .adm-deposit-toggle__text strong {
  margin-bottom: 2px;
}

#navVisibilityWrap.adm-collapsible {
  padding-top: 12px;
  padding-bottom: 10px;
}

.adm-collapsible__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin: 0;
  padding: 2px 0 8px;
  border: none;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.adm-collapsible__title {
  font-size: 0.93rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}

.adm-collapsible__caret {
  width: 10px;
  height: 10px;
  flex-shrink: 0;
  border-right: 2px solid var(--text-secondary, #94a3b8);
  border-bottom: 2px solid var(--text-secondary, #94a3b8);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  margin-right: 4px;
}

.adm-collapsible[data-collapsed="true"] .adm-collapsible__caret {
  transform: rotate(-135deg);
  margin-top: 4px;
}

.adm-collapsible__body {
  overflow: hidden;
  transition: opacity 0.18s ease;
}

.adm-collapsible[data-collapsed="true"] .adm-collapsible__body {
  display: none;
}

.adm-collapsible[data-collapsed="true"] {
  padding-bottom: 8px;
}

.deposit-locked {
  text-align: center;
  padding: 28px 16px 12px;
}

.deposit-locked__icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

.deposit-locked h2 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.deposit-locked p {
  margin: 0 0 8px;
  color: var(--text-secondary);
  font-size: .88rem;
  line-height: 1.5;
}

.deposit-locked__admin {
  color: var(--accent, #67e8f9) !important;
  font-size: .82rem !important;
}

.purchase-deposit-disabled {
  margin: 0;
  width: 100%;
  font-size: .84rem;
  color: var(--warn, #fbbf24);
  line-height: 1.45;
}

@media (max-width: 720px) {
  .adm-deposit-kpi-grid { grid-template-columns: 1fr; }
}

html[data-theme="light"] .adm-deposit-summary {
  background: rgba(176, 212, 184, 0.07);
}

html[data-theme="light"] .adm-deposit-kpi {
  background: var(--surface);
}

html[data-theme="light"] .adm-deposit-kpi--total {
  background: rgba(176, 212, 184, 0.14);
}

/* ── Admin loading skeletons ─────────────────────────────── */

@keyframes adm-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@keyframes adm-content-fade-in {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: none; }
}

.adm-skel {
  border-radius: 6px;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.035) 0%,
    rgba(255, 255, 255, 0.035) 38%,
    rgba(120, 220, 200, 0.14) 48%,
    rgba(160, 240, 220, 0.22) 50%,
    rgba(120, 220, 200, 0.14) 52%,
    rgba(255, 255, 255, 0.035) 62%,
    rgba(255, 255, 255, 0.035) 100%
  );
  background-size: 220% 100%;
  animation: adm-shimmer 1.65s ease-in-out infinite;
  animation-delay: var(--adm-skel-delay, 0ms);
}

.adm-skel-tr td {
  padding: 11px 14px !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: middle;
}

.adm-skel-cell-center {
  text-align: center;
}

.adm-skel-cell-center .adm-skel {
  margin-inline: auto;
}

.adm-skel-table-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
}

.adm-skel--circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  flex-shrink: 0;
}

.adm-skel-lines {
  flex: 0 1 180px;
  min-width: 100px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.adm-skel--line { height: 10px; border-radius: 5px; }
.adm-skel--line-lg { width: 88%; max-width: 140px; }
.adm-skel--line-md { width: 72%; max-width: 100px; }
.adm-skel--line-sm { width: 52%; max-width: 80px; height: 8px; }
.adm-skel--line-xs { width: 48%; max-width: 64px; height: 7px; }

.adm-skel--pill {
  width: 38px;
  height: 22px;
  border-radius: 999px;
}

.adm-skel--chip {
  width: 54px;
  height: 22px;
  border-radius: 999px;
}

.adm-skel--chip-sm {
  width: 38px;
  height: 18px;
  border-radius: 6px;
}

.adm-skel--btn {
  width: 76px;
  height: 28px;
  border-radius: 8px;
  flex-shrink: 0;
}

.adm-skel--btn-sm {
  width: 64px;
  height: 26px;
}

.adm-skel-cells {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex-shrink: 0;
}

.adm-skel-cells--users .adm-skel--line-md { width: 68px; }
.adm-skel-cells--users .adm-skel--line-sm { width: 52px; }

.adm-skel-toggles {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-left: auto;
  padding-right: 6%;
}

.adm-skel-leaders {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.adm-skel-leader-card {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.18);
}

.adm-skel-leader-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.adm-skel-leader-card__head .adm-skel-lines {
  flex: 1;
}

.adm-skel-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.adm-skel--tag {
  height: 24px;
  width: 76px;
  border-radius: 999px;
}

.adm-skel--tag-short { width: 52px; }

.adm-skel-value {
  display: inline-block;
  min-width: 88px;
  height: 1.15em;
  border-radius: 6px;
  color: transparent !important;
  vertical-align: middle;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.035) 0%,
    rgba(255, 255, 255, 0.035) 38%,
    rgba(120, 220, 200, 0.14) 48%,
    rgba(160, 240, 220, 0.22) 50%,
    rgba(120, 220, 200, 0.14) 52%,
    rgba(255, 255, 255, 0.035) 62%,
    rgba(255, 255, 255, 0.035) 100%
  );
  background-size: 220% 100%;
  animation: adm-shimmer 1.65s ease-in-out infinite;
}

.adm-drawer-skel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  padding: 28px 0 36px;
}

.adm-drawer-skel__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  width: 100%;
  max-width: 360px;
}

.adm-skel-kv {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.18);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.adm-content-in {
  animation: adm-content-fade-in 0.38s ease forwards;
}

html[data-theme="light"] .adm-skel {
  background: linear-gradient(
    90deg,
    rgba(45, 90, 76, 0.06) 0%,
    rgba(45, 90, 76, 0.06) 38%,
    rgba(120, 200, 160, 0.18) 48%,
    rgba(140, 220, 180, 0.28) 50%,
    rgba(120, 200, 160, 0.18) 52%,
    rgba(45, 90, 76, 0.06) 62%,
    rgba(45, 90, 76, 0.06) 100%
  );
  background-size: 220% 100%;
}

html[data-theme="light"] .adm-skel-tr td {
  border-bottom-color: rgba(45, 90, 76, 0.08);
}

html[data-theme="light"] .adm-skel-leader-card,
html[data-theme="light"] .adm-skel-kv {
  background: var(--surface-2);
}

html[data-theme="light"] .adm-skel-value {
  background: linear-gradient(
    90deg,
    rgba(45, 90, 76, 0.06) 0%,
    rgba(45, 90, 76, 0.06) 38%,
    rgba(120, 200, 160, 0.18) 48%,
    rgba(140, 220, 180, 0.28) 50%,
    rgba(120, 200, 160, 0.18) 52%,
    rgba(45, 90, 76, 0.06) 62%,
    rgba(45, 90, 76, 0.06) 100%
  );
  background-size: 220% 100%;
}

@media (prefers-reduced-motion: reduce) {
  .adm-skel,
  .adm-skel-value {
    animation: none;
    background: rgba(120, 220, 200, 0.1);
  }

  html[data-theme="light"] .adm-skel,
  html[data-theme="light"] .adm-skel-value {
    background: rgba(120, 200, 160, 0.14);
  }

  .adm-content-in {
    animation: none;
  }
}

/* ── Avatar crop modal (shared cropper; must sit above edit-user modal) ── */
.avatar-cropper-overlay {
  z-index: 9100;
}

.avatar-cropper-dialog {
  width: min(400px, 100%);
  padding: 22px 20px 20px;
}

.avatar-cropper__hint {
  margin: 0 0 14px;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.avatar-cropper__viewport {
  position: relative;
  width: 280px;
  max-width: 100%;
  aspect-ratio: 1;
  margin: 0 auto 16px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--border);
  touch-action: none;
  cursor: grab;
  user-select: none;
}

.avatar-cropper__viewport.is-dragging {
  cursor: grabbing;
}

.avatar-cropper__img {
  position: absolute;
  top: 0;
  left: 0;
  max-width: none;
  pointer-events: none;
  will-change: transform;
}

.avatar-cropper__mask {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: 50%;
  box-shadow: 0 0 0 9999px rgba(2, 6, 14, 0.62);
  border: 2px solid var(--accent-cyan);
}

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

.avatar-cropper__zoom-label {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.avatar-cropper__zoom-label input[type="range"] {
  width: 100%;
  accent-color: var(--accent-cyan);
}

.avatar-cropper__preview-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.avatar-cropper__preview-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.avatar-cropper__preview {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  background: rgba(0, 0, 0, 0.35);
}

@media (max-width: 480px) {
  .avatar-cropper-dialog {
    padding: 18px 14px 14px;
  }

  .avatar-cropper__viewport {
    width: min(280px, calc(100vw - 56px));
  }
}

.admin-page--channels-only .admin-tabs-shell,
.admin-page--channels-only .admin-tabs {
  display: none;
}

.admin-page--channels-only #panelChannels .adm-section__head {
  display: none;
}

.admin-page--channels-only #adminStats,
.admin-page--channels-only #openCreateUserBtn,
.admin-page--channels-only #adminLoadError {
  display: none !important;
}

/* ── Thống kê dashboard (redesign) ───────────────────────── */

.adm-stats-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.adm-stats-dash {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.adm-stats-chips {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
  gap: 8px;
}

.adm-stats-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.72);
  min-height: 0;
}

html[data-theme="dark"] .adm-stats-chip,
html:not([data-theme="light"]) .adm-stats-chip {
  background: rgba(15, 23, 42, 0.35);
  border-color: rgba(148, 163, 184, 0.16);
}

.adm-stats-chip span {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #64748b;
  line-height: 1.25;
}

.adm-stats-chip strong {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  line-height: 1.2;
  word-break: break-word;
}

html[data-theme="dark"] .adm-stats-chip strong,
html:not([data-theme="light"]) .adm-stats-chip strong {
  color: #f8fafc;
}

.adm-stats-chip--user { border-left: 3px solid #64748b; }
.adm-stats-chip--pro { border-left: 3px solid #2563eb; }
.adm-stats-chip--ultra { border-left: 3px solid #ca8a04; }
.adm-stats-chip--money strong { font-size: 0.92rem; }

.adm-stats-smm {
  display: block;
  grid-column: auto;
  margin: 0.85rem 0 1rem;
  padding: 1rem 1.1rem;
}
.adm-stats-chips--smm {
  margin-top: 0.65rem;
}

.adm-stats-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.adm-sc {
  grid-column: span 2;
  padding: 12px 14px 14px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #fff;
  min-height: 0;
}

html[data-theme="dark"] .adm-sc,
html:not([data-theme="light"]) .adm-sc {
  background: rgba(15, 23, 42, 0.4);
  border-color: rgba(148, 163, 184, 0.14);
}

.adm-sc--wide {
  grid-column: span 3;
}

.adm-sc--full {
  grid-column: 1 / -1;
}

@media (max-width: 1100px) {
  .adm-stats-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .adm-sc,
  .adm-sc--wide {
    grid-column: span 1;
  }
  .adm-sc--full {
    grid-column: 1 / -1;
  }
}

@media (max-width: 700px) {
  .adm-stats-board {
    grid-template-columns: 1fr;
  }
}

.adm-sc__head {
  margin-bottom: 10px;
}

.adm-sc__head h3 {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 750;
  color: #0f172a;
}

html[data-theme="dark"] .adm-sc__head h3,
html:not([data-theme="light"]) .adm-sc__head h3 {
  color: #f1f5f9;
}

.adm-sc__head p {
  margin: 2px 0 0;
  font-size: 0.72rem;
  color: #94a3b8;
}

.adm-stats-donut-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 0;
}

.adm-stats-donut {
  width: 108px;
  height: 108px;
  flex-shrink: 0;
}

.adm-stats-donut-total {
  font-size: 18px;
  font-weight: 800;
  fill: currentColor;
}

.adm-stats-donut-sub {
  font-size: 8px;
  font-weight: 700;
  fill: #94a3b8;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.adm-stats-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.adm-stats-legend li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.78rem;
  color: #334155;
}

html[data-theme="dark"] .adm-stats-legend li,
html:not([data-theme="light"]) .adm-stats-legend li {
  color: #cbd5e1;
}

.adm-stats-legend__left {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.adm-stats-swatch {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  flex-shrink: 0;
}

.adm-stats-legend strong {
  font-weight: 750;
  color: #0f172a;
  white-space: nowrap;
}

html[data-theme="dark"] .adm-stats-legend strong,
html:not([data-theme="light"]) .adm-stats-legend strong {
  color: #f8fafc;
}

.adm-stats-legend em {
  font-style: normal;
  opacity: 0.6;
  font-weight: 600;
}

/* Compact meters */
.adm-meter-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.adm-meter {
  display: grid;
  grid-template-columns: minmax(72px, 28%) 1fr auto;
  gap: 8px;
  align-items: center;
}

.adm-meter__label {
  font-size: 0.78rem;
  font-weight: 650;
  color: #475569;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html[data-theme="dark"] .adm-meter__label,
html:not([data-theme="light"]) .adm-meter__label {
  color: #94a3b8;
}

.adm-meter__track {
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.2);
  overflow: hidden;
}

.adm-meter__fill {
  height: 100%;
  border-radius: inherit;
  min-width: 0;
}

.adm-meter__value {
  font-size: 0.76rem;
  font-weight: 750;
  color: #0f172a;
  text-align: right;
  white-space: nowrap;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
}

html[data-theme="dark"] .adm-meter__value,
html:not([data-theme="light"]) .adm-meter__value {
  color: #f8fafc;
}

.adm-meter-list--compact .adm-meter {
  grid-template-columns: minmax(88px, 32%) 1fr auto;
}

/* Money as tiles (avoid absurd bar scale) */
.adm-money-tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.adm-money-tile {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(61, 122, 74, 0.06);
  border: 1px solid rgba(61, 122, 74, 0.12);
}

.adm-money-tile--blue {
  background: rgba(37, 99, 235, 0.06);
  border-color: rgba(37, 99, 235, 0.14);
}

.adm-money-tile span {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 4px;
}

.adm-money-tile strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 800;
  color: #0f172a;
  word-break: break-word;
  line-height: 1.25;
}

html[data-theme="dark"] .adm-money-tile strong,
html:not([data-theme="light"]) .adm-money-tile strong {
  color: #f8fafc;
}

/* Column charts */
.adm-col-chart {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  align-items: end;
  height: 120px;
  padding-top: 4px;
}

.adm-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  height: 100%;
  min-width: 0;
}

.adm-col__val {
  font-size: 0.68rem;
  font-weight: 750;
  color: #334155;
  line-height: 1;
}

html[data-theme="dark"] .adm-col__val,
html:not([data-theme="light"]) .adm-col__val {
  color: #cbd5e1;
}

.adm-col__bar-wrap {
  flex: 1;
  width: 100%;
  max-width: 28px;
  display: flex;
  align-items: flex-end;
  min-height: 0;
}

.adm-col__bar {
  width: 100%;
  border-radius: 5px 5px 2px 2px;
  min-height: 0;
  background: linear-gradient(180deg, #5ea86c, #3d7a4a);
}

.adm-col__bar--teal {
  background: linear-gradient(180deg, #2dd4bf, #0f766e);
}

.adm-col__label {
  font-size: 0.66rem;
  font-weight: 700;
  color: #94a3b8;
}

.adm-stats-empty {
  margin: 0;
  padding: 12px 6px;
  text-align: center;
  font-size: 0.8rem;
  color: #94a3b8;
}

.adm-stats-top-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 200px;
  overflow: auto;
}

.adm-stats-top-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) minmax(48px, 0.9fr) 32px;
  gap: 6px;
  align-items: center;
}

.adm-stats-top-rank {
  width: 20px;
  height: 20px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.65rem;
  font-weight: 800;
  background: rgba(61, 122, 74, 0.12);
  color: #166534;
}

.adm-stats-top-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: #0f172a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html[data-theme="dark"] .adm-stats-top-name,
html:not([data-theme="light"]) .adm-stats-top-name {
  color: #f8fafc;
}

.adm-stats-top-track {
  height: 5px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.2);
  overflow: hidden;
}

.adm-stats-top-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0f766e, #2dd4bf);
}

.adm-stats-top-row strong {
  text-align: right;
  font-size: 0.76rem;
  color: #0f172a;
}

html[data-theme="dark"] .adm-stats-top-row strong,
html:not([data-theme="light"]) .adm-stats-top-row strong {
  color: #f8fafc;
}

.adm-stats-free-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #475569;
}

.adm-stats-free-table-wrap {
  overflow: auto;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  max-height: 260px;
}

.adm-stats-free-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.adm-stats-free-table th,
.adm-stats-free-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  color: #0f172a;
}

html[data-theme="dark"] .adm-stats-free-table th,
html[data-theme="dark"] .adm-stats-free-table td,
html:not([data-theme="light"]) .adm-stats-free-table th,
html:not([data-theme="light"]) .adm-stats-free-table td {
  color: #e2e8f0;
}

.adm-stats-free-table th {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b !important;
  background: rgba(148, 163, 184, 0.08);
  position: sticky;
  top: 0;
}

.adm-stats-free-table td strong {
  display: block;
}

.adm-stats-free-table td small {
  display: block;
  margin-top: 1px;
  color: #94a3b8;
  font-size: 0.72rem;
}

/* Users-tab mini stats denser when 6 cols */
.admin-card .admin-stats.panel-stats {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

@media (max-width: 1100px) {
  .admin-card .admin-stats.panel-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.adm-stats-user-feat {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.adm-uf-card {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(148, 163, 184, 0.06);
}

.adm-uf-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.adm-uf-card__head strong {
  font-size: 0.82rem;
  color: #0f172a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html[data-theme="dark"] .adm-uf-card__head strong,
html:not([data-theme="light"]) .adm-uf-card__head strong {
  color: #f8fafc;
}

.adm-uf-card__head span {
  font-size: 0.78rem;
  font-weight: 800;
  color: #0f766e;
}

.adm-uf-card__feats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.adm-uf-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(61, 122, 74, 0.1);
  font-size: 0.7rem;
}

.adm-uf-chip em {
  font-style: normal;
  color: #475569;
}

html[data-theme="dark"] .adm-uf-chip em,
html:not([data-theme="light"]) .adm-uf-chip em {
  color: #94a3b8;
}

.adm-uf-chip strong {
  color: #0f172a;
  font-weight: 800;
}

html[data-theme="dark"] .adm-uf-chip strong,
html:not([data-theme="light"]) .adm-uf-chip strong {
  color: #f8fafc;
}

/* Software management — twin of Users table (scoped to #panelSoftware) */
#panelSoftware .adm-section__head {
  margin-bottom: 16px;
}

#panelSoftware .adm-section__head h2 {
  margin: 0 0 6px;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

#panelSoftware .adm-section__sub {
  margin: 0 0 12px;
  font-size: 0.82rem;
  color: var(--text-tertiary);
  line-height: 1.5;
}

#panelSoftware .adm-toolbar {
  width: 100%;
}

.adm-table--software {
  table-layout: fixed;
  width: 100%;
}

.adm-table--software col.adm-col-account { width: 34%; }
.adm-table--software col.adm-col-plan { width: 72px; }
.adm-table--software col.adm-col-pr-seats { width: 7.5rem; }
.adm-table--software col.adm-col-pr-devices { width: auto; }
.adm-table--software col.adm-col-actions { width: 56px; }

.adm-table--software tbody td {
  vertical-align: middle;
}

.adm-table--software .adm-td-plan {
  white-space: nowrap;
  width: 72px;
  padding-left: 6px;
  padding-right: 6px;
}

.adm-table--software th.adm-th-plan {
  padding-left: 6px;
  padding-right: 6px;
}

.adm-table--software .adm-td-seats,
.adm-table--software .adm-td-devices {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.adm-table--software .adm-td-devices {
  min-width: 0;
  white-space: normal;
}

.adm-table--software .adm-td-actions {
  width: 56px;
  padding-left: 4px;
  padding-right: 0;
  text-align: right;
  white-space: nowrap;
}

.adm-table--software .adm-td-actions .adm-row-actions {
  align-items: center;
  min-height: 34px;
}

.adm-table--software td:last-child {
  text-align: right;
  white-space: nowrap;
}

.adm-table--software .adm-user-cell {
  min-width: 0;
  max-width: 100%;
  width: 100%;
}

.adm-table--software .adm-user-cell > div:last-child,
.adm-table--software .adm-user-cell__text {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
}

.adm-table--software .adm-user-cell strong,
.adm-table--software .adm-user-cell small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
}

.adm-table--software .adm-user-cell strong {
  font-weight: 700;
  color: var(--text);
}

.adm-table--software .adm-user-cell small {
  font-size: 0.74rem;
  color: var(--text-tertiary);
  margin-top: 2px;
  line-height: 1.35;
}

.adm-table--software .adm-avatar {
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
  border-radius: 10px;
  font-size: 0.76rem;
  flex: 0 0 auto;
}

.adm-pr-devices-cell {
  min-width: 0;
}

.adm-pr-devices-summary {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  max-width: 100%;
  min-width: 0;
  margin: 0;
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.adm-pr-devices-summary:hover,
.adm-pr-devices-summary:focus-visible {
  background: rgba(176, 212, 184, 0.16);
  border-color: rgba(139, 191, 149, 0.4);
  outline: none;
}

.adm-pr-devices-summary strong {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--text-secondary, #4d735c);
}

.adm-pr-devices-summary small {
  font-size: 0.72rem;
  color: var(--text-tertiary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.adm-pr-devices-summary--empty {
  cursor: default;
  padding: 0;
  border: none;
  background: transparent;
}

.adm-software-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  flex-wrap: nowrap;
}

.adm-software-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.adm-software-showing {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-secondary, #4d735c);
}

.adm-software-pager {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.adm-software-page {
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-secondary);
  min-width: 2.5rem;
  text-align: center;
}

.adm-software-devices-body {
  margin: 0;
}

.adm-software-devices-table-wrap {
  overflow: auto;
  max-height: min(52vh, 420px);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm, 10px);
  background: var(--surface, #fff);
}

.adm-table--pr-devices {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  margin: 0;
}

.adm-table--pr-devices thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 8px 12px;
  font-size: 0.6875rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  text-align: left;
  white-space: nowrap;
}

.adm-table--pr-devices tbody td {
  padding: 11px 12px;
  font-size: 0.84rem;
  vertical-align: middle;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.adm-table--pr-devices tbody tr:last-child td {
  border-bottom: none;
}

.adm-table--pr-devices .adm-pr-dev-name {
  width: 36%;
}

.adm-table--pr-devices .adm-pr-dev-name strong {
  font-weight: 700;
  font-size: 0.84rem;
  color: var(--text);
}

.adm-table--pr-devices .adm-pr-dev-id {
  width: 28%;
}

.adm-table--pr-devices .adm-pr-dev-id code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  padding: 0;
}

.adm-table--pr-devices .adm-pr-dev-seen {
  width: 22%;
  color: var(--text-secondary);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem;
}

.adm-table--pr-devices .adm-pr-dev-action {
  width: 14%;
  text-align: right;
  white-space: nowrap;
}

html[data-theme="light"] #panelSoftware .adm-pr-devices-summary:hover,
html[data-theme="light"] #panelSoftware .adm-pr-devices-summary:focus-visible {
  background: rgba(176, 212, 184, 0.18);
  border-color: rgba(139, 191, 149, 0.45);
}

html[data-theme="light"] #panelSoftware .adm-pr-devices-summary strong {
  color: #3d7a4a;
}

html[data-theme="light"] #panelSoftware .adm-software-showing {
  color: #4d735c;
}

html[data-theme="light"] .adm-modal--devices {
  background: var(--bg-elevated, #fff);
  border-color: var(--border-strong, var(--border));
  box-shadow: var(--shadow-lg, 0 16px 40px rgba(15, 23, 42, 0.12));
}

html[data-theme="light"] .adm-software-devices-table-wrap {
  background: var(--surface, #fff);
  border-color: var(--border);
}

html[data-theme="light"] .adm-table--pr-devices thead th {
  background: var(--surface-2);
  color: var(--text-tertiary);
  box-shadow: 0 1px 0 var(--border);
}

html[data-theme="dark"] .adm-pr-devices-summary:hover,
html[data-theme="dark"] .adm-pr-devices-summary:focus-visible,
html:not([data-theme="light"]) .adm-pr-devices-summary:hover,
html:not([data-theme="light"]) .adm-pr-devices-summary:focus-visible {
  background: rgba(103, 232, 249, 0.08);
  border-color: rgba(103, 232, 249, 0.28);
}

@media (max-width: 900px) {
  .adm-table--software col.adm-col-pr-devices { width: 28%; }
  .adm-table--pr-devices .adm-pr-dev-id { display: none; }
}

@media (max-width: 640px) {
  .adm-table--software col.adm-col-plan,
  .adm-table--software th.adm-th-plan,
  .adm-table--software td.adm-td-plan { display: none; }
  .adm-table--software col.adm-col-pr-seats { width: 5.5rem; }
  .adm-table--software col.adm-col-account { width: 42%; }
  .adm-modal--devices { width: min(100%, calc(100vw - 24px)); padding: 16px; }
}

/* ── Revenue console v2 — premium green admin surface ───────── */
#panelRevenue {
  --rev-accent: #3d7a4a;
  --rev-accent-rgb: 61, 122, 74;
  --rev-line: rgba(116, 146, 123, .2);
}

#panelRevenue > .adm-revenue-hero {
  position: relative;
  min-height: 112px;
  margin: 0 0 14px;
  padding: 24px 104px 22px 84px;
  overflow: hidden;
  border: 1px solid var(--rev-line);
  border-radius: 16px;
  background:
    linear-gradient(110deg, rgba(var(--rev-accent-rgb), .13), rgba(var(--rev-accent-rgb), .035) 58%, transparent),
    var(--surface-2, rgba(255, 255, 255, .025));
  box-shadow: 0 12px 32px rgba(10, 24, 14, .07);
}

#panelRevenue > .adm-revenue-hero::before {
  content: "";
  position: absolute;
  top: 25px;
  left: 26px;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(var(--rev-accent-rgb), .28);
  border-radius: 12px;
  background:
    linear-gradient(var(--rev-accent), var(--rev-accent)) 12px 12px / 16px 2px no-repeat,
    linear-gradient(var(--rev-accent), var(--rev-accent)) 12px 19px / 11px 2px no-repeat,
    linear-gradient(var(--rev-accent), var(--rev-accent)) 12px 26px / 16px 2px no-repeat,
    rgba(var(--rev-accent-rgb), .1);
  box-shadow: 0 8px 20px rgba(var(--rev-accent-rgb), .13);
}

#panelRevenue > .adm-revenue-hero::after {
  content: "ROOT";
  position: absolute;
  top: 24px;
  right: 24px;
  padding: 4px 8px;
  border: 1px solid rgba(var(--rev-accent-rgb), .22);
  border-radius: 999px;
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .08);
  font-size: .58rem;
  font-weight: 800;
  letter-spacing: .1em;
}

#panelRevenue > .adm-revenue-hero h2 {
  margin: 0 0 7px;
  font-size: 1.18rem;
  font-weight: 780;
  letter-spacing: -.03em;
}

#panelRevenue > .adm-revenue-hero .adm-section__sub {
  max-width: 660px;
  margin: 0;
  font-size: .76rem;
  line-height: 1.6;
}

.adm-revenue-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 14px;
}

.adm-revenue-metric {
  position: relative;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 64px;
  padding: 11px 14px;
  overflow: hidden;
  border: 1px solid var(--rev-line);
  border-radius: 13px;
  background: var(--surface-2, rgba(255, 255, 255, .025));
  box-shadow: 0 8px 22px rgba(10, 24, 14, .045);
}

.adm-revenue-metric::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 2px;
  background: linear-gradient(90deg, var(--rev-accent), transparent 72%);
  opacity: .55;
}

.adm-revenue-metric__icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(var(--rev-accent-rgb), .18);
  border-radius: 9px;
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .08);
}

.adm-revenue-metric__icon svg,
.adm-inline-team-btn svg,
.adm-edit-team-btn svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.adm-revenue-metric__copy {
  display: contents;
}

.adm-revenue-metric__copy small {
  color: var(--text-tertiary);
  font-size: .67rem;
  font-weight: 650;
}

.adm-revenue-metric__copy strong {
  padding-left: 12px;
  color: var(--text);
  font-size: 1.12rem;
  font-weight: 780;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
}

#panelRevenue .adm-revenue-grid {
  grid-template-columns: minmax(640px, 1.55fr) minmax(340px, .82fr);
  gap: 14px;
}

#panelRevenue .adm-revenue-col {
  border-color: var(--rev-line);
  border-radius: 15px;
  background: var(--surface-2, rgba(255, 255, 255, .025));
  box-shadow: 0 12px 34px rgba(10, 24, 14, .065);
}

#panelRevenue .adm-revenue-col--users,
#panelRevenue .adm-revenue-col--teams {
  height: min(64vh, 640px);
  min-height: 470px;
}

#panelRevenue .adm-revenue-card-head {
  min-height: 62px;
  padding: 11px 13px 11px 15px;
  border-color: var(--rev-line);
  background:
    linear-gradient(90deg, rgba(var(--rev-accent-rgb), .055), transparent 55%),
    rgba(255, 255, 255, .012);
}

#panelRevenue .adm-revenue-card-icon {
  width: 32px;
  height: 32px;
  flex-basis: 32px;
  border-color: rgba(var(--rev-accent-rgb), .18);
  border-radius: 10px;
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .075);
}

#panelRevenue .adm-revenue-card-head h3 {
  font-size: .8rem;
  font-weight: 750;
}

#panelRevenue .adm-revenue-hint {
  border-color: rgba(var(--rev-accent-rgb), .18);
  border-radius: 999px;
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .07);
}

#panelRevenue .adm-revenue-search {
  width: min(240px, 43%);
}

#panelRevenue .adm-search--compact {
  height: 36px;
  padding-left: 34px;
  border-color: var(--rev-line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .04);
  transition: border-color .18s, background .18s, box-shadow .18s;
}

#panelRevenue .adm-search--compact:focus {
  border-color: rgba(var(--rev-accent-rgb), .48);
  background: rgba(var(--rev-accent-rgb), .045);
  box-shadow: 0 0 0 3px rgba(var(--rev-accent-rgb), .09);
}

#panelRevenue .adm-table--revenue col.adm-col-account { width: auto; }
#panelRevenue .adm-table--revenue col.adm-col-toggle { width: 88px; }

#panelRevenue .adm-table--revenue th {
  z-index: 3;
  height: 38px;
  padding: 7px 9px;
  border-color: var(--rev-line);
  color: var(--text-tertiary);
  background: color-mix(in srgb, var(--surface-2) 96%, var(--rev-accent) 4%);
  font-size: .6rem;
  font-weight: 750;
  letter-spacing: .055em;
}

#panelRevenue .adm-table--revenue th:first-child {
  position: sticky;
  left: 0;
  z-index: 4;
  padding-left: 15px;
}

#panelRevenue .adm-table--revenue td {
  height: 58px;
  padding: 7px 9px;
  border-color: color-mix(in srgb, var(--rev-line) 74%, transparent);
  background: transparent;
  transition: background .16s, box-shadow .16s;
}

#panelRevenue .adm-table--revenue td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  padding-left: 14px;
  background: color-mix(in srgb, var(--surface-2) 97%, transparent);
}

#panelRevenue .adm-table--revenue tbody tr:nth-child(even) td {
  background: rgba(var(--rev-accent-rgb), .018);
}

#panelRevenue .adm-table--revenue tbody tr:hover td {
  background: rgba(var(--rev-accent-rgb), .065);
}

#panelRevenue .adm-table--revenue tbody tr:hover td:first-child {
  background: color-mix(in srgb, var(--surface-2) 88%, var(--rev-accent) 12%);
}

#panelRevenue .adm-table--revenue tbody tr.is-leader td:first-child {
  box-shadow: inset 3px 0 0 var(--rev-accent);
}

#panelRevenue .adm-user-cell {
  gap: 10px;
}

#panelRevenue .adm-user-cell .adm-avatar {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border: 1px solid rgba(var(--rev-accent-rgb), .2);
  border-radius: 10px;
  box-shadow: 0 3px 9px rgba(10, 24, 14, .08);
}

#panelRevenue .adm-user-cell__text {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 2px;
}

#panelRevenue .adm-user-cell__top,
#panelRevenue .adm-user-cell__meta {
  display: flex;
  align-items: center;
  min-width: 0;
}

#panelRevenue .adm-user-cell__top {
  gap: 6px;
}

#panelRevenue .adm-user-cell__top strong {
  overflow: hidden;
  font-size: .76rem;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#panelRevenue .adm-user-cell__meta {
  gap: 8px;
}

#panelRevenue .adm-user-cell__meta > small {
  flex: 0 1 auto;
  overflow: hidden;
  color: var(--text-tertiary);
  font-size: .63rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.adm-inline-team-btn {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  color: var(--text-tertiary);
  background: transparent;
  cursor: pointer;
  opacity: 0;
  transform: translateX(-3px);
  transition: color .16s, background .16s, opacity .16s, transform .16s;
}

#panelRevenue tr:hover .adm-inline-team-btn,
.adm-inline-team-btn:focus-visible {
  opacity: 1;
  transform: none;
}

.adm-inline-team-btn:hover {
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .09);
}

.adm-user-statuses {
  display: flex;
  min-width: 0;
  gap: 4px;
  overflow: hidden;
}

.adm-user-status {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  max-width: 82px;
  padding: 2px 5px;
  overflow: hidden;
  border: 1px solid rgba(var(--rev-accent-rgb), .13);
  border-radius: 999px;
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .055);
  font-size: .51rem;
  font-weight: 700;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#panelRevenue .adm-table--revenue .perm-toggle {
  width: 38px;
  height: 22px;
  border-color: rgba(104, 125, 109, .24);
  background: rgba(104, 125, 109, .1);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .07);
}

#panelRevenue .adm-table--revenue .perm-toggle::after {
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  background: #718078;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .18);
}

#panelRevenue .adm-table--revenue .perm-toggle.on {
  border-color: rgba(var(--rev-accent-rgb), .34);
  background: rgba(var(--rev-accent-rgb), .17);
}

#panelRevenue .adm-table--revenue .perm-toggle.on::after {
  transform: translateX(16px);
  background: var(--rev-accent);
  box-shadow: 0 2px 5px rgba(var(--rev-accent-rgb), .28);
}

#panelRevenue .adm-table--revenue .perm-toggle:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(var(--rev-accent-rgb), .13);
}

#panelRevenue .adm-leaders-grid {
  gap: 10px;
  padding: 11px;
  height: calc(100% - 62px);
}

#panelRevenue .adm-leader-card {
  position: relative;
  padding: 13px 13px 12px;
  overflow: hidden;
  border-color: var(--rev-line);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(var(--rev-accent-rgb), .055), transparent 46%),
    rgba(255, 255, 255, .018);
  box-shadow: 0 7px 18px rgba(10, 24, 14, .04);
  transition: border-color .18s, background .18s, box-shadow .18s, transform .18s;
}

#panelRevenue .adm-leader-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: linear-gradient(180deg, var(--rev-accent), rgba(var(--rev-accent-rgb), .05));
}

#panelRevenue .adm-leader-card:hover {
  border-color: rgba(var(--rev-accent-rgb), .32);
  background:
    linear-gradient(135deg, rgba(var(--rev-accent-rgb), .085), transparent 50%),
    rgba(255, 255, 255, .025);
  box-shadow: 0 12px 26px rgba(10, 24, 14, .075);
  transform: translateY(-2px);
}

#panelRevenue .adm-leader-card__identity {
  gap: 10px;
}

#panelRevenue .adm-leader-card__identity .adm-avatar {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  border: 1px solid rgba(var(--rev-accent-rgb), .22);
  border-radius: 11px;
  box-shadow: 0 4px 10px rgba(10, 24, 14, .1);
}

.adm-leader-card__eyebrow {
  margin-bottom: 2px;
  color: var(--rev-accent);
  font-size: .52rem;
  font-weight: 800;
  letter-spacing: .075em;
  text-transform: uppercase;
}

#panelRevenue .adm-leader-card__name {
  font-size: .78rem;
  font-weight: 750;
}

#panelRevenue .adm-edit-team-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 5px 8px;
  border-color: rgba(var(--rev-accent-rgb), .15);
  color: var(--text-secondary);
  background: rgba(255, 255, 255, .025);
}

#panelRevenue .adm-edit-team-btn:hover {
  border-color: rgba(var(--rev-accent-rgb), .3);
  color: var(--rev-accent);
  background: rgba(var(--rev-accent-rgb), .075);
}

#panelRevenue .adm-edit-team-btn svg {
  width: 13px;
  height: 13px;
}

#panelRevenue .adm-leader-card__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 11px 0 5px;
  padding-top: 9px;
  border-color: var(--rev-line);
  color: var(--text-tertiary);
  font-size: .58rem;
  letter-spacing: .065em;
}

#panelRevenue .adm-leader-card__meta i {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, var(--rev-line), transparent);
}

#panelRevenue .adm-member-tags {
  gap: 2px 8px;
}

#panelRevenue .adm-member-row {
  gap: 7px;
  padding: 5px 6px;
  border-bottom: 0;
  border-radius: 7px;
  background: rgba(var(--rev-accent-rgb), .035);
}

#panelRevenue .adm-member-row__mark {
  width: 6px;
  height: 6px;
  flex-basis: 6px;
  border: 2px solid rgba(var(--rev-accent-rgb), .16);
  background: var(--rev-accent);
  box-sizing: content-box;
}

#panelRevenue .adm-member-row__identity strong {
  font-size: .66rem;
  font-weight: 650;
}

#panelRevenue .adm-member-row__identity small {
  font-size: .57rem;
}

html[data-theme="light"] #panelRevenue .adm-revenue-col,
html[data-theme="light"] #panelRevenue .adm-revenue-metric {
  background: rgba(255, 255, 255, .82);
}

html[data-theme="light"] #panelRevenue .adm-revenue-card-head {
  background:
    linear-gradient(90deg, rgba(var(--rev-accent-rgb), .075), transparent 58%),
    rgba(247, 250, 246, .92);
}

html[data-theme="light"] #panelRevenue .adm-search--compact {
  background: rgba(255, 255, 255, .8);
}

html[data-theme="light"] #panelRevenue .adm-leader-card {
  background:
    linear-gradient(135deg, rgba(var(--rev-accent-rgb), .07), transparent 46%),
    rgba(255, 255, 255, .82);
}

@media (max-width: 1180px) {
  #panelRevenue .adm-revenue-grid { grid-template-columns: 1fr; }
  #panelRevenue .adm-revenue-col--users,
  #panelRevenue .adm-revenue-col--teams { height: auto; min-height: 0; }
  #panelRevenue .adm-leaders-grid { max-height: 520px; }
}

@media (max-width: 700px) {
  #panelRevenue > .adm-revenue-hero {
    min-height: 104px;
    padding: 20px 62px 18px 68px;
  }
  #panelRevenue > .adm-revenue-hero::before {
    top: 20px;
    left: 18px;
    transform: scale(.88);
    transform-origin: top left;
  }
  #panelRevenue > .adm-revenue-hero::after {
    top: 18px;
    right: 16px;
  }
  .adm-revenue-metrics { grid-template-columns: 1fr; gap: 7px; }
  .adm-revenue-metric { min-height: 54px; }
  #panelRevenue .adm-table--revenue { min-width: 610px; }
  #panelRevenue .adm-revenue-search { width: 100%; }
  #panelRevenue .adm-user-statuses { display: none; }
  #panelRevenue .adm-inline-team-btn { opacity: 1; transform: none; }
  #panelRevenue .adm-member-tags { grid-template-columns: 1fr; }
}
/* build 4.16.307-plan-badge-orbit */

/* Shared API / shared channels (root admin tab) */
.adm-shared-api-grid {
  margin-top: 1rem;
}
.adm-shared-channel-title {
  margin-left: 0.35rem;
  opacity: 0.75;
  font-size: 0.9em;
}
