:root {
  color-scheme: dark;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif;
  color: #e8eef2;
  background: #0b1319;
  --bg: #0b1319;
  --surface: #111e27;
  --surface-2: #172733;
  --line: #263844;
  --text: #e8eef2;
  --muted: #8ca0aa;
  --teal: #35c6b0;
  --teal-deep: #167f7b;
  --amber: #edb85d;
  --red: #ec7777;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
}
button,
input {
  font: inherit;
}
button {
  cursor: pointer;
}
a {
  color: inherit;
  text-decoration: none;
}
.app-shell {
  max-width: 1180px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 0 28px 104px;
}
.topbar {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
}
.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid #3d8f8b;
  border-radius: 8px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
}
.brand b {
  display: block;
  font-size: 16px;
  letter-spacing: 0.03em;
}
.brand small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.14em;
}
.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.network-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
}
.network-pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #65757e;
}
.network-pill.online i {
  background: var(--teal);
  box-shadow: 0 0 0 4px #35c6b01c;
}
.button {
  border: 0;
  border-radius: 6px;
  padding: 11px 16px;
  color: #091418;
  font-weight: 700;
}
.button-primary {
  background: var(--teal);
}
.button-primary:hover {
  background: #5bd8c4;
}
.button-ghost {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
}
.button-small {
  padding: 8px 11px;
  font-size: 12px;
}
.content {
  padding: 38px 0 30px;
}
.eyebrow {
  color: var(--teal);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
h1 {
  margin: 8px 0 8px;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: 0;
}
h2 {
  margin: 0;
  font-size: 18px;
}
h3 {
  margin: 0;
  font-size: 14px;
}
p {
  color: var(--muted);
  line-height: 1.65;
}
.muted {
  color: var(--muted);
}
.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  word-break: break-all;
}
.page-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}
.page-head p {
  margin: 8px 0 0;
  font-size: 14px;
}
.panel {
  background: linear-gradient(145deg, #14232d, #101b23);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
}
.panel + .panel {
  margin-top: 16px;
}
.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.panel-head span {
  color: var(--muted);
  font-size: 12px;
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.stat {
  padding: 16px;
  background: #0d1820;
  border: 1px solid #20313b;
  border-radius: 7px;
}
.stat-label {
  color: var(--muted);
  font-size: 12px;
}
.stat-value {
  display: block;
  margin-top: 8px;
  font-size: 22px;
  font-weight: 750;
}
.stat-value.teal {
  color: var(--teal);
}
.stat-value.amber {
  color: var(--amber);
}
.stat-value.red {
  color: var(--red);
}
.two-col {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 16px;
}
.three-col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid #20313a;
}
.row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.row:first-child {
  padding-top: 0;
}
.row-label {
  color: var(--muted);
  font-size: 13px;
}
.success {
  color: var(--teal);
}
.warning {
  color: var(--amber);
}
.error {
  color: var(--red);
}
.notice {
  margin: 18px 0 0;
  padding: 13px 15px;
  border: 1px solid #83683a;
  border-radius: 7px;
  background: #2c2518;
  color: #f2d397;
  font-size: 13px;
}
.hidden {
  display: none !important;
}
.empty {
  padding: 25px 0 5px;
  color: var(--muted);
  font-size: 14px;
}
.quick-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.quick {
  display: block;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #0d1820;
}
.quick:hover {
  border-color: var(--teal-deep);
}
.quick strong {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
}
.quick span {
  color: var(--muted);
  font-size: 12px;
}
.invite-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding: 16px;
  border: 1px solid #3d6f6e;
  border-radius: 7px;
  background: #102a2d;
}
.invite-callout strong,
.invite-callout small {
  display: block;
}
.invite-callout small {
  margin-top: 5px;
  color: var(--muted);
}
.inventory-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid #20313a;
}
.inventory-row:last-of-type {
  border-bottom: 0;
}
.inventory-row small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}
.inventory-row .form-row {
  min-width: min(290px, 48%);
}
.admin-tools {
  margin-top: 16px;
}
.bottom-nav {
  position: fixed;
  z-index: 10;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  width: min(640px, calc(100% - 36px));
  padding: 6px;
  border: 1px solid #2c414d;
  border-radius: 11px;
  background: #111e27ee;
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 40px #0006;
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 9px 4px;
  border-radius: 7px;
  color: var(--muted);
  font-size: 11px;
}
.nav-item .nav-icon {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 5px;
  font-size: 9px;
  font-weight: 800;
}
.nav-item.active {
  color: var(--teal);
  background: #1b3a3e;
}
.chart-wrap {
  height: 220px;
  position: relative;
  margin: 4px -4px 0;
}
.chart-wrap canvas {
  width: 100%;
  height: 100%;
}
.chart-axis {
  display: flex;
  justify-content: space-between;
  color: #6f838d;
  font-size: 10px;
}
.pool-price {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.pool-price strong {
  font-size: 31px;
}
.pool-price span {
  color: var(--muted);
  font-size: 12px;
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--line);
}
.metric {
  min-height: 88px;
  padding: 14px;
  background: #0f1b23;
}
.metric label {
  display: block;
  color: var(--muted);
  font-size: 11px;
}
.metric b {
  display: block;
  margin-top: 9px;
  font-size: 16px;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 12px;
}
.pagination .button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
.form-row {
  display: flex;
  gap: 10px;
}
.input {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: none;
  background: #0b151c;
  color: var(--text);
}
.input:focus {
  border-color: var(--teal-deep);
}
.table-list {
  display: grid;
  gap: 8px;
}
.list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border: 1px solid #21323c;
  border-radius: 6px;
  background: #0d1820;
}
.list-item small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}
.investment-product {
  align-items: center;
}
.investment-action {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: min(300px, 48%);
}
.investment-quantity {
  width: 96px;
  text-align: right;
}
.investment-action .button:disabled,
.investment-quantity:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.payment-modal-backdrop {
  position: fixed;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: #050b0fcc;
}
.payment-modal {
  width: min(520px, 100%);
  max-height: min(720px, calc(100vh - 40px));
  overflow: auto;
  padding: 22px;
  border: 1px solid #38515d;
  border-radius: 8px;
  background: #14232d;
  box-shadow: 0 24px 80px #0008;
}
.payment-modal-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
}
.payment-modal h2 {
  margin-top: 7px;
}
.payment-total {
  color: var(--text);
}
.payment-options {
  display: grid;
  gap: 9px;
  margin-top: 18px;
}
.payment-option {
  display: block;
  width: 100%;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #0d1820;
  color: var(--text);
  text-align: left;
}
.payment-option:hover,
.payment-option.active {
  border-color: var(--teal);
  background: #123339;
}
.payment-option strong,
.payment-option small {
  display: block;
}
.payment-option small {
  margin-top: 5px;
  color: var(--muted);
}
.payment-mixed-fields {
  margin-top: 15px;
}
.payment-mixed-fields label {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 13px;
}
.payment-mixed-preview {
  display: block;
  margin-top: 6px;
}
.payment-point-b-balance {
  display: block;
  margin-top: 14px;
}
.payment-modal-error {
  min-height: 20px;
  margin: 12px 0 0;
}
.payment-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 12px;
}
.chain-unavailable {
  color: var(--warning, #f5b85c);
}
@media (max-width: 760px) {
  .app-shell {
    padding: 0 16px 104px;
  }
  .topbar {
    height: 68px;
  }
  .network-pill {
    display: none;
  }
  .content {
    padding-top: 28px;
  }
  .page-head {
    align-items: start;
    flex-direction: column;
  }
  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .two-col,
  .three-col {
    grid-template-columns: 1fr;
  }
  .panel {
    padding: 17px;
  }
  .quick-actions {
    grid-template-columns: 1fr;
  }
  .invite-callout,
  .inventory-row {
    align-items: stretch;
    flex-direction: column;
  }
  .investment-product {
    align-items: stretch;
    flex-direction: column;
  }
  .investment-action {
    min-width: 0;
    justify-content: stretch;
  }
  .investment-quantity {
    width: 100%;
  }
  .inventory-row .form-row {
    min-width: 0;
  }
  .pool-price strong {
    font-size: 27px;
  }
  .metric-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
