:root {
  color-scheme: light;
  --bg: #f5f7fb;
  --panel: rgba(255, 255, 255, 0.78);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --line: rgba(119, 134, 158, 0.18);
  --line-strong: rgba(119, 134, 158, 0.28);
  --text: #121a2a;
  --muted: #64728a;
  --faint: #8a96aa;
  --orange: #ff5a1f;
  --orange-soft: #fff0e8;
  --blue: #2f7df6;
  --green: #16a34a;
  --red: #ef4444;
  --violet: #7c3aed;
  --shadow: 0 18px 54px rgba(22, 34, 55, 0.1);
  --shadow-soft: 0 10px 32px rgba(22, 34, 55, 0.08);
  --radius: 22px;
  --radius-sm: 15px;
  --blur: blur(26px) saturate(145%);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  min-width: 1180px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Inter", "Segoe UI", sans-serif;
  color: var(--text);
  background: linear-gradient(135deg, #fbfcfe 0%, var(--bg) 54%, #edf2f8 100%);
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 278px minmax(920px, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 27px 18px 22px;
  background: rgba(255, 255, 255, 0.56);
  border-right: 1px solid var(--line);
  box-shadow: 16px 0 46px rgba(38, 52, 76, 0.08);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 0 12px 32px;
}

.brand-logo {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  object-fit: cover;
  border: 1px solid rgba(18, 26, 42, 0.08);
  box-shadow: 0 9px 24px rgba(18, 26, 42, 0.1);
}

.brand strong {
  display: block;
  font-size: 24px;
  font-weight: 760;
  line-height: 1.05;
}

.brand span {
  display: block;
  margin-top: 3px;
  color: #8f98a8;
  font-size: 12px;
  font-weight: 760;
}

.side-nav {
  display: grid;
  gap: 13px;
}

.nav-item {
  width: 100%;
  height: 54px;
  display: flex;
  align-items: center;
  gap: 17px;
  border: 1px solid transparent;
  border-radius: 14px;
  padding: 0 18px;
  background: transparent;
  color: #263653;
  font-size: 15px;
  font-weight: 650;
  text-align: left;
  transition: background 160ms ease, color 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.64);
}

.nav-item.active {
  color: var(--orange);
  background: linear-gradient(90deg, rgba(255, 90, 31, 0.17), rgba(255, 255, 255, 0.48));
  border-color: rgba(255, 90, 31, 0.22);
  box-shadow: 0 12px 30px rgba(255, 90, 31, 0.11);
}

.nav-item svg,
.soft-button svg,
.support-icon svg,
.icon-button svg,
.api-pill svg,
.tiny-button svg,
.link-button svg,
.chip-button svg,
.more-button svg,
.drag-handle svg,
.account svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.1;
}

.plan-card {
  margin-top: auto;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 17px 15px 13px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow-soft);
}

.plan-card > span,
.plan-card dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 660;
}

.plan-card > strong {
  display: block;
  margin-top: 7px;
  color: var(--orange);
  font-size: 16px;
}

.plan-card dl {
  display: grid;
  gap: 17px;
  margin: 24px 0 16px;
}

.plan-card div {
  display: grid;
  gap: 6px;
}

.plan-card dd {
  margin: 0;
  font-size: 14px;
  font-weight: 680;
}

.soft-button {
  width: 100%;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 13px;
  background: rgba(247, 249, 253, 0.8);
  color: #30405d;
  font-size: 13px;
  font-weight: 680;
}

.support-card {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 38px;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 17px 15px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow-soft);
}

.support-icon,
.metric-icon,
.server-icon,
.user-dot {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
}

.support-icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  color: #3b56b0;
  background: #eef2ff;
}

.support-card strong {
  display: block;
  font-size: 13px;
}

.support-card span {
  color: var(--muted);
  font-size: 12px;
}

.main {
  min-width: 0;
  padding: 12px 18px 18px 24px;
}

.topbar {
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
}

.tab-view {
  display: none;
}

.tab-view.active {
  display: block;
}

.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.page-head h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.12;
  font-weight: 760;
}

.page-head p,
.quiet-copy {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
  font-weight: 560;
}

.search {
  width: min(450px, 44vw);
  height: 45px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 0 15px 0 17px;
  background: rgba(255, 255, 255, 0.66);
  box-shadow: var(--shadow-soft);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.search svg {
  width: 17px;
  color: #40516e;
}

.search input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 14px;
}

.search input::placeholder {
  color: #6f7b8e;
}

.search kbd {
  color: #8b95a6;
  font-size: 12px;
  font-weight: 650;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 13px;
}

.api-pill,
.icon-button,
.account {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-soft);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.api-pill {
  min-width: 150px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 20px;
  padding: 0 18px;
  color: #151c2b;
  font-size: 14px;
  font-weight: 720;
  line-height: 1;
  white-space: nowrap;
}

.api-pill span,
.live-dot,
.status-text i {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(22, 163, 74, 0.11);
}

.api-pill.warning span {
  background: #f59e0b;
  box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.12);
}

.api-pill.error span {
  background: var(--red);
  box-shadow: 0 0 0 5px rgba(239, 68, 68, 0.12);
}

.icon-button {
  position: relative;
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: 16px;
  color: #283954;
}

.icon-button b {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 17px;
  height: 17px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 10px;
}

.account {
  height: 50px;
  display: flex;
  align-items: center;
  gap: 11px;
  border-radius: 17px;
  padding: 6px 13px 6px 9px;
  color: var(--text);
}

.account img {
  width: 37px;
  height: 37px;
  border-radius: 13px;
  object-fit: cover;
}

.account span {
  display: grid;
  gap: 2px;
  min-width: 126px;
  text-align: left;
}

.account strong {
  font-size: 13px;
}

.account small {
  color: var(--muted);
  font-size: 12px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.metric,
.panel {
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.metric {
  min-height: 106px;
  display: grid;
  grid-template-columns: 42px 1fr;
  grid-template-rows: auto auto auto;
  column-gap: 14px;
  align-items: center;
  border-radius: 20px;
  padding: 18px 20px;
}

.metric-icon {
  grid-row: 1 / span 3;
  width: 42px;
  height: 42px;
  border-radius: 16px;
}

.metric-icon svg {
  width: 20px;
  height: 20px;
}

.metric-icon.orange {
  color: var(--orange);
  background: var(--orange-soft);
}

.metric-icon.orange-soft {
  color: #f97316;
  background: #fff3e7;
}

.metric-icon.blue {
  color: var(--blue);
  background: #edf5ff;
}

.metric-icon.violet {
  color: var(--violet);
  background: #f3efff;
}

.metric-icon.red {
  color: var(--red);
  background: #fff1f1;
}

.metric span {
  color: #5e6b80;
  font-size: 13px;
  font-weight: 640;
  white-space: nowrap;
}

.metric strong {
  margin-top: 4px;
  font-size: 26px;
  line-height: 1;
  font-weight: 760;
}

.metric small {
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.metric small.positive {
  color: #16944b;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(620px, 1.45fr) minmax(360px, 0.95fr);
  gap: 14px;
  align-items: stretch;
}

.panel {
  border-radius: 21px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px 10px;
}

.panel-head.compact {
  padding-bottom: 10px;
}

.panel-head h1,
.panel-head h2 {
  margin: 0;
  color: #141d2d;
}

.panel-head h1 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 17px;
  font-weight: 760;
}

.panel-head h2 {
  font-size: 17px;
  font-weight: 760;
}

.panel-head em {
  color: var(--muted);
  font-style: normal;
  font-weight: 560;
}

.panel-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--faint);
  font-size: 12px;
}

.tiny-button,
.chip-button,
.link-button,
.more-button,
.drag-handle {
  border: 0;
  background: transparent;
  color: #41516d;
}

.tiny-button {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 9px;
}

.tiny-button:hover,
.more-button:hover,
.drag-handle:hover {
  background: rgba(233, 239, 248, 0.9);
}

.server-groups {
  display: grid;
  gap: 9px;
  padding: 6px 10px 0;
}

.server-group {
  display: grid;
  grid-template-columns: minmax(250px, 1fr) auto;
  gap: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 22px 12px;
  background: rgba(255, 255, 255, 0.72);
}

.server-info {
  display: flex;
  align-items: center;
  gap: 13px;
}

.server-icon {
  width: 33px;
  height: 33px;
  border-radius: 13px;
  color: #3952a8;
  background: #eef5ff;
}

.server-icon svg {
  width: 18px;
  height: 18px;
}

.server-info h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 760;
}

.server-info h3 span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.server-info small {
  display: inline-block;
  margin-top: 8px;
  border-radius: 999px;
  padding: 5px 11px;
  background: #f1f4f8;
  color: #1f2937;
  font-size: 11px;
  font-weight: 760;
}

.server-counts {
  display: flex;
  align-items: center;
  gap: 24px;
  justify-content: flex-end;
  font-size: 13px;
}

.server-counts strong {
  color: #13883f;
}

.server-counts b {
  color: var(--red);
}

.server-dots {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(13, 38px);
  gap: 9px;
}

.server-dot {
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid #dfe7f0;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff, #f7fafc);
}

.server-dot i {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(22, 163, 74, 0.1);
}

.server-dot.warn i {
  background: #f59e0b;
  box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.12);
}

.server-dot.bad i {
  background: var(--red);
  box-shadow: 0 0 0 5px rgba(239, 68, 68, 0.12);
}

.server-dot.idle i {
  background: #c7cdd6;
  box-shadow: none;
}

.server-group p {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.server-group p strong {
  color: #16823f;
}

.link-button {
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 4px auto 8px;
  color: #31519d;
  font-size: 13px;
  font-weight: 680;
}

.right-stack {
  display: grid;
  gap: 14px;
}

.side-panel {
  min-height: 222px;
}

.chip-button {
  height: 32px;
  border-radius: 13px;
  padding: 0 15px;
  background: rgba(242, 245, 250, 0.88);
  color: #192337;
  font-size: 12px;
  font-weight: 650;
}

.chip-button.accent {
  height: 40px;
  color: #fff;
  background: linear-gradient(90deg, #ff7a18, #ff4b1f);
  box-shadow: 0 14px 28px rgba(255, 90, 31, 0.18);
}

.chip-button:hover {
  background: #edf2f8;
}

.api-list,
.subscription-list {
  display: grid;
  gap: 4px;
  padding: 0 14px 14px;
}

.api-row,
.subscription-row {
  width: 100%;
  min-height: 36px;
  display: grid;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.api-row {
  grid-template-columns: 46px minmax(0, 1fr) 58px 42px;
}

.subscription-row {
  grid-template-columns: 28px minmax(112px, 1fr) 54px minmax(132px, 1.3fr) 24px;
}

.api-row:hover,
.subscription-row:hover {
  background: rgba(244, 247, 252, 0.86);
}

.api-row strong,
.subscription-row strong {
  overflow: hidden;
  color: #1f2b42;
  font-size: 13px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.api-row time,
.subscription-row time,
.subscription-row small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.method,
.api-row em {
  justify-self: start;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 11px;
  font-style: normal;
  font-weight: 780;
}

.method.post {
  color: #6d38d9;
  background: #efe9ff;
}

.method.get {
  color: #16823f;
  background: #e8f8ef;
}

.api-row em {
  color: #16823f;
  background: #dff7e9;
}

.empty-state {
  border: 1px dashed rgba(119, 134, 158, 0.28);
  border-radius: 12px;
  padding: 16px;
  background: rgba(247, 249, 253, 0.68);
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
  text-align: center;
}

.table-empty {
  margin: 8px;
}

.user-dot {
  width: 24px;
  height: 24px;
  border-radius: 999px;
}

.user-dot svg {
  width: 14px;
  height: 14px;
  color: #fff;
}

.user-dot.blue {
  background: #5b8cff;
}

.user-dot.cyan {
  background: #38bdf8;
}

.user-dot.green {
  background: #22c55e;
}

.user-dot.orange {
  background: #ff7a18;
}

.user-dot.violet {
  background: #8b5cf6;
}

.subscription-row > svg {
  width: 15px;
  height: 15px;
  color: #8390a3;
}

.nodes-panel {
  margin-top: 12px;
}

.summary-grid,
.health-grid,
.api-doc-grid {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.summary-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.summary-card,
.endpoint-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  background: var(--panel);
  box-shadow: var(--shadow-soft);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.summary-card span,
.endpoint-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 680;
}

.summary-card strong {
  display: block;
  margin-top: 8px;
  font-size: 27px;
  line-height: 1;
}

.summary-card small,
.endpoint-card small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 620;
}

.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 14px;
  align-items: start;
}

.detail-panel,
.brand-editor,
.landing-preview {
  min-height: 260px;
}

.profile-preview {
  display: grid;
  gap: 10px;
  padding: 0 18px 16px;
}

.profile-preview strong,
.profile-preview span {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 13px;
  background: rgba(247, 249, 253, 0.78);
}

.profile-preview strong {
  color: var(--orange);
}

.profile-preview em {
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  padding: 12px 13px;
  color: var(--muted);
  background: rgba(247, 249, 253, 0.58);
  font-size: 13px;
  font-style: normal;
  font-weight: 680;
}

.quiet-copy {
  padding: 0 18px 18px;
}

.health-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.health-card {
  min-height: 138px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 20px;
}

.health-card svg {
  width: 24px;
  height: 24px;
}

.health-card.good svg,
.health-card.good strong {
  color: var(--green);
}

.health-card.warn svg,
.health-card.warn strong {
  color: #e47f00;
}

.health-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 680;
}

.health-card strong {
  font-size: 28px;
  line-height: 1;
}

.health-card small {
  color: var(--muted);
  font-size: 12px;
}

.check-list,
.flow-list,
.audit-list {
  display: grid;
  gap: 1px;
  padding: 0 14px 14px;
}

.check-list div,
.audit-list div {
  min-height: 54px;
  display: grid;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(119, 134, 158, 0.14);
  padding: 9px 6px;
}

.check-list div {
  grid-template-columns: 18px minmax(170px, 0.6fr) minmax(0, 1fr) 58px;
}

.check-list div:last-child,
.audit-list div:last-child {
  border-bottom: 0;
}

.check-list small,
.audit-list span {
  color: var(--muted);
  font-size: 13px;
}

.check-list time,
.audit-list time {
  color: var(--faint);
  font-size: 12px;
  font-weight: 650;
}

.warn-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #f59e0b;
  box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.12);
}

.api-doc-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.api-connect-card {
  margin-bottom: 14px;
}

.api-settings {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 0 18px 4px;
}

.api-settings label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 680;
}

.api-settings-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 1px;
}

.home-only.hidden {
  display: none;
}

.endpoint-card code {
  display: block;
  overflow: hidden;
  margin-top: 10px;
  color: #172033;
  font-size: 14px;
  font-weight: 760;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.flow-list {
  padding: 0 18px 18px;
}

.flow-list div {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid rgba(119, 134, 158, 0.14);
  padding: 13px 0;
}

.flow-list div:last-child {
  border-bottom: 0;
}

.flow-list b {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--orange-soft);
  color: var(--orange);
}

.flow-list span {
  color: #263653;
  font-size: 14px;
  line-height: 1.45;
}

.brand-editor {
  padding-bottom: 18px;
}

.brand-editor label {
  display: grid;
  gap: 8px;
  padding: 0 18px 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 680;
}

.field-input {
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 13px;
  outline: 0;
  background: rgba(247, 249, 253, 0.78);
  color: var(--text);
  font-weight: 650;
}

.color-row {
  display: flex;
  gap: 10px;
  padding: 4px 18px 0;
}

.swatch {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.swatch.orange {
  background: linear-gradient(135deg, #ff7a18, #ff4b1f);
}

.swatch.dark {
  background: #121a2a;
}

.swatch.blue {
  background: #2f7df6;
}

.swatch.green {
  background: #16a34a;
}

.landing-preview {
  display: grid;
  place-items: center;
  padding: 18px;
}

.landing-card {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 246, 241, 0.8));
}

.landing-card img {
  width: 62px;
  height: 62px;
  border-radius: 16px;
  object-fit: cover;
}

.landing-card h2 {
  margin: 14px 0 10px;
  font-size: 28px;
}

.landing-card strong {
  display: block;
  color: #202938;
  font-size: 14px;
}

.landing-card p {
  color: var(--muted);
  line-height: 1.45;
}

.landing-card button {
  width: 100%;
  height: 44px;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(90deg, #ff7a18, #ff4b1f);
  color: #fff;
  font-weight: 760;
}

.audit-list div {
  grid-template-columns: 62px minmax(110px, 0.4fr) minmax(0, 1fr) 78px;
}

.audit-list em {
  justify-self: start;
  border-radius: 999px;
  padding: 4px 9px;
  background: #eef6ff;
  color: #31519d;
  font-size: 11px;
  font-style: normal;
  font-weight: 760;
}

.status-text.muted-dot i {
  background: #c7cdd6;
}

.status-text.warn-status i {
  background: #f59e0b;
}

.status-text.danger-status i {
  background: var(--red);
}

.table-wrap {
  overflow: auto;
  margin: 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

#tab-nodes .table-wrap {
  max-height: 620px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  height: 39px;
  border-bottom: 1px solid rgba(119, 134, 158, 0.16);
  padding: 0 12px;
  text-align: left;
  white-space: nowrap;
}

th {
  background: rgba(247, 249, 253, 0.9);
  color: #768296;
  font-size: 12px;
  font-weight: 680;
}

td {
  color: #1f2b42;
  font-size: 13px;
  font-weight: 560;
}

tr:last-child td {
  border-bottom: 0;
}

.drag-handle,
.more-button {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border-radius: 9px;
}

.node-actions {
  display: inline-flex;
  gap: 4px;
}

.node-actions .drag-handle {
  width: 26px;
  height: 26px;
}

.node-group-chip,
.white-list-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 4px 9px;
  background: #eef3fa;
  color: #30405d;
  font-size: 12px;
  font-weight: 760;
}

.white-list-chip {
  background: linear-gradient(90deg, rgba(255, 90, 31, 0.15), rgba(255, 240, 232, 0.9));
  color: #d64717;
}

.node-flag {
  font-size: 17px;
}

.node-row-hidden {
  opacity: 0.54;
}

.node-name {
  width: 100%;
  min-width: 220px;
  border: 0;
  outline: 0;
  border-radius: 9px;
  padding: 7px 9px;
  background: transparent;
  color: var(--text);
  font-size: 13px;
  font-weight: 640;
}

.node-name:focus {
  background: #f6f9fd;
  box-shadow: inset 0 0 0 1px rgba(47, 125, 246, 0.22);
}

.toggle {
  width: 34px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  border: 0;
  border-radius: 999px;
  padding: 2px;
  background: #c8d0dc;
  transition: background 160ms ease;
}

.toggle span {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
  transform: translateX(0);
  transition: transform 160ms ease;
}

.toggle.on {
  background: linear-gradient(90deg, #ff7a18, #ff4b1f);
}

.toggle.on span {
  transform: translateX(14px);
}

.status-text {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #1f2b42;
}

.status-text i {
  width: 7px;
  height: 7px;
  box-shadow: none;
}

.latency.good {
  color: #13883f;
}

.latency.warn {
  color: #e47f00;
}

.latency.danger {
  color: #ef5b2a;
}

.bottom-link {
  display: flex;
  margin: 7px auto 8px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 20;
  transform: translate(-50%, 18px);
  opacity: 0;
  pointer-events: none;
  border: 1px solid rgba(255, 90, 31, 0.18);
  border-radius: 15px;
  padding: 12px 16px;
  background: rgba(18, 26, 42, 0.88);
  color: #fff;
  box-shadow: 0 18px 48px rgba(18, 26, 42, 0.22);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  font-size: 13px;
  font-weight: 650;
  transition: opacity 160ms ease, transform 160ms ease;
}

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

@media (max-width: 1180px) {
  body {
    min-width: 980px;
  }

  .app-shell {
    grid-template-columns: 238px minmax(740px, 1fr);
  }

  .sidebar {
    padding-inline: 14px;
  }

  .metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .content-grid {
    grid-template-columns: 1fr;
  }

  .api-settings {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 980px) {
  body {
    min-width: 0;
  }

  .app-shell {
    display: block;
  }

  .sidebar {
    position: relative;
    height: auto;
    padding: 16px;
  }

  .side-nav {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .nav-item {
    justify-content: center;
    gap: 8px;
    padding: 0 10px;
  }

  .plan-card,
  .support-card {
    display: none;
  }

  .main {
    padding: 16px;
  }

  .topbar {
    height: auto;
    flex-wrap: wrap;
  }

  .search {
    width: 100%;
  }

  .metrics,
  .right-stack {
    grid-template-columns: 1fr;
  }

  .api-settings-actions {
    flex-wrap: wrap;
  }

  .metric {
    min-height: 100px;
  }

  .server-dots {
    grid-template-columns: repeat(7, 38px);
  }

  .table-wrap {
    overflow-x: auto;
  }
}
