﻿:root {
  color-scheme: light;
  --bg: #f5f7fa;
  --surface: #ffffff;
  --text: #1b2430;
  --muted: #657184;
  --line: #dbe1ea;
  --accent: #0f7a66;
  --accent-soft: #e1f3ef;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
}

.shell {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
}

h1 {
  font-size: 32px;
}

h2 {
  font-size: 18px;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-size: 14px;
}

.status span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.metrics {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  margin-bottom: 16px;
}

.metrics article,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.metrics article {
  padding: 18px;
}

.metrics strong {
  display: block;
  font-size: 28px;
  line-height: 1;
}

.metrics span,
.empty,
.item span,
.muted {
  color: var(--muted);
}

.metrics span {
  display: block;
  margin-top: 8px;
  font-size: 14px;
}

.panel {
  padding: 18px;
  margin-bottom: 16px;
}

.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

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

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

th,
td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.item {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.item + .item {
  margin-top: 10px;
}

.item strong,
.item span,
.item code {
  display: block;
}

.item code {
  overflow: hidden;
  color: var(--accent);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empty {
  margin: 0;
}

.chain-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.chain-strip > div {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.chain-strip span,
.chain-strip strong,
.chain-strip code {
  display: block;
}

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

.chain-strip strong {
  margin-top: 4px;
  font-size: 20px;
}

.chain-strip code {
  overflow: hidden;
  margin-top: 6px;
  color: var(--accent);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-list {
  display: grid;
  gap: 8px;
}

.stat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.stat-row span {
  overflow: hidden;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-row strong {
  color: var(--accent);
  font-size: 18px;
}

@media (max-width: 760px) {
  .topbar,
  .grid,
  .metrics,
  .chain-strip {
    grid-template-columns: 1fr;
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.badge-ok {
  background: #dff4e8;
  color: #0a6f3c;
}

.badge-warn {
  background: #fff3d7;
  color: #946000;
}

.service-filter {
  margin-bottom: 16px;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  padding: 9px 14px;
  text-decoration: none;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.7);
}

.filter-pill:hover {
  color: var(--text);
  border-color: #9fb2c9;
}

.filter-pill.active {
  color: #fff;
  border-color: #0f766e;
  background: #0f766e;
}

.muted {
  color: var(--muted);
}

.testnet-panel {
  border-color: #b9d8ee;
  background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.testnet-strip {
  margin-bottom: 14px;
}

.testnet-checks .stat-row span {
  white-space: normal;
}

.testnet-checks small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.ok-text {
  color: #0a6f3c !important;
}

.warn-text {
  color: #946000 !important;
}

.explorer-shell {
  width: min(1480px, calc(100% - 32px));
}

.explorer-grid {
  align-items: start;
}

.top-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.nav-button {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.nav-button:hover {
  border-color: #9fb2c9;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-button,
.inline-form button,
.search-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.search-form,
.inline-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.search-form input,
.inline-form input {
  min-height: 38px;
  min-width: 180px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
}

.search-form input {
  min-width: min(360px, 45vw);
}

.address-code {
  display: block;
  overflow: hidden;
  margin: 12px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
  color: var(--accent);
  text-overflow: ellipsis;
  white-space: nowrap;
}

a {
  color: var(--accent);
}

.wallet-strip {
  margin-top: 14px;
}

.inline-form select {
  min-height: 38px;
  max-width: 280px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
}

.wallet-app .wallet-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
  gap: 16px;
  align-items: stretch;
}

.wallet-balance-panel,
.wallet-receive-panel {
  margin-bottom: 16px;
}

.wallet-balance {
  margin: 18px 0;
  color: var(--text);
  font-size: clamp(34px, 5vw, 58px);
  font-weight: 800;
  line-height: 1;
}

.wallet-subgrid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.wallet-subgrid div {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.wallet-subgrid span,
.wallet-subgrid strong {
  display: block;
}

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

.wallet-subgrid strong {
  margin-top: 5px;
  color: var(--accent);
  font-size: 18px;
}

.wallet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.wallet-receive-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
}

.wallet-qr {
  width: 180px;
  height: 180px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.wallet-note {
  margin: 12px 0 0;
  line-height: 1.45;
}

.wallet-grid {
  grid-template-columns: minmax(0, 1fr) minmax(320px, .8fr);
  align-items: start;
}

.wallet-form {
  display: grid;
  gap: 12px;
}

.wallet-form.compact {
  margin-bottom: 14px;
}

.wallet-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.wallet-form input,
.wallet-form select {
  min-height: 42px;
  width: 100%;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: 14px;
}

.wallet-form button {
  min-height: 42px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.wallet-field-error {
  margin: -2px 0 2px;
  padding: 10px 12px;
  border: 1px solid #fecaca;
  border-radius: 8px;
  background: #fff1f2;
  color: #be123c;
  font-size: 13px;
  font-weight: 700;
}

.wallet-success {
  margin: -2px 0 2px;
  padding: 10px 12px;
  border: 1px solid #a7f3d0;
  border-radius: 8px;
  background: #ecfdf5;
  color: #047857;
  font-size: 13px;
  font-weight: 700;
}

.wallet-alert {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-color: #9dd8c9;
  background: #eefaf6;
}

.wallet-alert-error {
  border-color: #f0c3bb;
  background: #fff4f2;
}

.wallet-alert code {
  overflow: hidden;
  max-width: 70vw;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 900px) {
  .wallet-app .wallet-hero,
  .wallet-grid,
  .wallet-subgrid {
    grid-template-columns: 1fr;
  }
}

.recovery-export {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}

.recovery-export span {
  color: #8aa1bd;
  font-size: 13px;
  font-weight: 700;
}

.recovery-export code {
  display: block;
  white-space: normal;
  word-break: break-all;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.34);
}

/* Explorer polish */
.explorer-wide {
  max-width: 1480px;
}

.explorer-topbar {
  align-items: flex-start;
}

.explorer-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
  gap: 18px;
  align-items: stretch;
  border-color: rgba(37, 99, 235, 0.28);
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.08), rgba(37, 99, 235, 0.05)), var(--panel, #fff);
}

.explorer-hero-main h2 {
  max-width: 780px;
  margin: 0 0 18px;
  font-size: clamp(22px, 1.85vw, 30px);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0;
}

.explorer-search {
  max-width: 780px;
}

.explorer-search input {
  flex: 1 1 420px;
  min-height: 46px;
}

.explorer-search button {
  min-height: 46px;
}

.search-warning {
  margin: 12px 0 0;
  color: #d97706;
  font-weight: 700;
}

.explorer-hero-side {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.explorer-hero-side div,
.vertical-strip div {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.explorer-hero-side span,
.vertical-strip span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.explorer-hero-side strong,
.explorer-hero-side a,
.vertical-strip strong {
  color: var(--text);
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
}

.explorer-metrics article {
  min-height: 86px;
}

.explorer-front-grid {
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, .65fr);
}

.block-timeline {
  display: grid;
  gap: 8px;
}

.block-row {
  display: grid;
  grid-template-columns: 92px minmax(180px, 1fr) minmax(160px, .8fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}

.block-row:last-child {
  border-bottom: 0;
}

.block-height {
  color: var(--accent);
  font-size: 17px;
  font-weight: 700;
}

.block-meta {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.explorer-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.explorer-item > div {
  min-width: 0;
}

.explorer-item code,
.block-row code,
.hash-block,
.stat-row code {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hash-block {
  display: block;
  margin-top: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.04);
  color: var(--accent);
  font-size: 13px;
}

.explorer-detail-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.explorer-detail-hero h2 {
  margin: 0;
  font-size: clamp(22px, 2vw, 32px);
}

.detail-status-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  min-width: 160px;
}

.detail-status-stack strong {
  color: var(--text);
  font-size: 24px;
}

.detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.stat-list.compact .stat-row {
  align-items: flex-start;
  gap: 14px;
}

.nav-button.subtle {
  background: transparent;
  color: var(--accent);
}

.nav-button.subtle:hover {
  background: rgba(37, 99, 235, 0.08);
}

.explorer-node-ledger {
  display: grid;
  gap: 18px;
}

.explorer-node-title {
  align-items: flex-start;
}

.explorer-node-title .eyebrow,
.explorer-node-title h2 {
  margin: 0;
}

.explorer-node-title .eyebrow {
  margin-bottom: 4px;
}

.node-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.node-summary-grid article,
.node-ledger-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .82);
  padding: 16px;
}

.node-summary-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.node-summary-grid strong {
  display: block;
  margin-top: 8px;
  color: var(--text);
  font-size: 22px;
  line-height: 1.15;
}

.node-ledger-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.node-ledger-card h3 {
  margin: 0 0 10px;
  font-size: 17px;
}

.node-ledger-card p {
  margin: 0 0 8px;
  color: var(--muted);
  line-height: 1.55;
}

.node-event-row {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.node-event-row:first-of-type {
  border-top: 0;
}

.node-table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.node-ledger-table {
  width: 100%;
  min-width: 1100px;
  border-collapse: collapse;
}

.node-ledger-table th,
.node-ledger-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.node-ledger-table th {
  background: rgba(15, 23, 42, .035);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.node-ledger-table td span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.node-ledger-table code {
  color: var(--accent);
  overflow-wrap: anywhere;
  word-break: break-word;
}

.node-status-pill {
  display: inline-flex;
  width: max-content;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.node-status-pill.active {
  background: #dcfce7;
  color: #047857;
}

.node-status-pill.pending {
  background: #dbeafe;
  color: #1d4ed8;
}

.node-status-pill.waiting {
  background: #fef3c7;
  color: #92400e;
}

.progress-line {
  width: 100%;
  min-width: 96px;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5e7eb;
}

.progress-line span {
  display: block;
  height: 100%;
  background: #10b981;
}

@media (max-width: 980px) {
  .explorer-hero,
  .explorer-front-grid,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .block-row {
    grid-template-columns: 1fr;
  }

  .explorer-detail-hero {
    flex-direction: column;
  }

  .detail-status-stack {
    align-items: flex-start;
  }

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

  .node-ledger-layout {
    grid-template-columns: 1fr;
  }

  .node-event-row {
    grid-template-columns: 1fr;
  }
}



.wallet-form textarea {
  min-height: 82px;
  width: 100%;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: #fff;
  resize: vertical;
  font: inherit;
}

.wallet-recovery-status {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
}

.wallet-recovery-status span {
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
}

.wallet-recovery-status strong {
  display: block;
  margin-top: 4px;
  color: var(--accent);
  font-size: 14px;
}

.wallet-restore-box {
  margin-top: 12px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.wallet-restore-box summary {
  cursor: pointer;
  color: var(--accent);
  font-weight: 700;
}

/* Mobile wallet app treatment */
.wallet-native {
  width: min(1040px, calc(100% - 24px));
  --wallet-bg: #151617;
  --wallet-card: #242528;
  --wallet-card-soft: #2b2c30;
  --wallet-text: #f7f8fb;
  --wallet-muted: #9a9ca4;
  --wallet-line: rgba(255, 255, 255, 0.09);
  --wallet-green: #42f58d;
  --wallet-green-deep: #0f7a66;
  padding: max(34px, env(safe-area-inset-top, 0px)) 0 max(38px, env(safe-area-inset-bottom, 0px));
}

body.wallet-screen {
  background:
    radial-gradient(circle at 24% 0%, rgba(66, 245, 141, 0.16), transparent 34%),
    linear-gradient(180deg, #101112 0%, #191a1c 42%, #111213 100%);
  color: var(--wallet-text);
}

body.wallet-screen::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  z-index: 9999;
  height: max(30px, env(safe-area-inset-top, 0px));
  background: #101112;
  pointer-events: none;
}

.wallet-native .wallet-topbar {
  position: relative;
  z-index: 4;
  margin: 0 -12px 18px;
  padding: 18px 12px 14px;
  background: linear-gradient(180deg, rgba(17, 18, 19, 0.98), rgba(17, 18, 19, 0.82));
  backdrop-filter: blur(16px);
}

.wallet-native .eyebrow {
  color: var(--wallet-green);
  letter-spacing: 0;
}

.wallet-native h1 {
  color: var(--wallet-text);
  font-size: clamp(30px, 7vw, 52px);
  letter-spacing: 0;
}

.wallet-native h2 {
  color: var(--wallet-text);
}

.wallet-native .panel-title span {
  color: var(--wallet-muted);
}

.wallet-native .wallet-balance-panel .panel-title span {
  color: var(--wallet-text);
  opacity: 0.85;
}

.wallet-native .muted {
  color: var(--wallet-muted);
}

.wallet-native .top-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.wallet-native .nav-button,
.wallet-native .wallet-form button {
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  background: var(--wallet-green);
  color: #101112;
  box-shadow: none;
  font-weight: 900;
}

.wallet-native .nav-button.subtle {
  border: 1px solid var(--wallet-line);
  background: var(--wallet-card-soft);
  color: var(--wallet-text);
}

.wallet-native .status {
  border-color: var(--wallet-line);
  border-radius: 999px;
  background: var(--wallet-card-soft);
  color: var(--wallet-muted);
}

.wallet-native .status span {
  background: var(--wallet-green);
}

.wallet-native .panel,
.wallet-native .metrics article {
  border-color: var(--wallet-line);
  border-radius: 24px;
  background: var(--wallet-card);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.wallet-native .wallet-hero {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 16px;
}

.wallet-native .wallet-balance-panel {
  position: relative;
  overflow: hidden;
  padding: 24px;
  background:
    radial-gradient(circle at 88% 18%, rgba(66, 245, 141, 0.2), transparent 24%),
    linear-gradient(145deg, #2a2c30 0%, #1f2023 100%);
}

.wallet-native .wallet-balance-panel::before {
  content: "plais";
  position: absolute;
  right: -12px;
  bottom: 10px;
  color: rgba(255, 255, 255, 0.035);
  font-size: clamp(82px, 16vw, 150px);
  font-weight: 900;
  line-height: 0.8;
  pointer-events: none;
}

.wallet-native .wallet-balance {
  position: relative;
  margin: 22px 0 8px;
  color: var(--wallet-text);
  max-width: 100%;
  font-size: clamp(34px, 7.5vw, 58px);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.05;
  overflow-wrap: normal;
  word-break: keep-all;
}

.wallet-native .wallet-subgrid {
  position: relative;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 18px 0;
}

.wallet-native .wallet-subgrid div {
  border-color: var(--wallet-line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
}

.wallet-native .wallet-subgrid span {
  color: var(--wallet-muted);
  font-size: 12px;
}

.wallet-native .wallet-subgrid strong {
  color: var(--wallet-green);
  max-width: 100%;
  font-size: clamp(15px, 4.2vw, 18px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.wallet-native .address-code {
  position: relative;
  border-color: var(--wallet-line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.07);
  color: #75ffd0;
  font-size: 13px;
}

.wallet-native .wallet-actions,
.wallet-native .wallet-primary-actions {
  position: relative;
}

.wallet-native .wallet-primary-actions {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.wallet-native .wallet-balance-panel > .wallet-primary-actions {
  display: none;
}

.wallet-native .wallet-sticky-actions {
  position: sticky;
  top: max(76px, calc(env(safe-area-inset-top, 0px) + 58px));
  z-index: 8;
  margin: 0 -2px 16px;
  padding: 10px 0;
  border-radius: 0 0 24px 24px;
  background: linear-gradient(180deg, rgba(17, 18, 19, 0.98), rgba(17, 18, 19, 0.88));
  backdrop-filter: blur(16px);
}

.wallet-native .wallet-primary-actions button {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 14px 8px;
  border: 0;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.075);
  color: var(--wallet-text);
  font-weight: 900;
  cursor: pointer;
}

.wallet-native .wallet-primary-actions button.active {
  background: rgba(66, 245, 141, 0.16);
  color: var(--wallet-green);
}

.wallet-native .wallet-primary-actions span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 16px;
  background: var(--wallet-green);
  color: #101112;
  font-size: 25px;
  line-height: 1;
}

.wallet-native .wallet-view {
  display: none;
  scroll-margin-top: 190px;
}

.wallet-native[data-wallet-view="receive"] .wallet-view-receive,
.wallet-native[data-wallet-view="collateral"] .wallet-view-collateral,
.wallet-native[data-wallet-view="send"] .wallet-view-send,
.wallet-native[data-wallet-view="history"] .wallet-view-history,
.wallet-native[data-wallet-view="security"] .wallet-view-security {
  display: block;
}

.wallet-native[data-wallet-view="home"] .wallet-grid,
.wallet-native[data-wallet-view="receive"] .wallet-grid,
.wallet-native[data-wallet-view="collateral"] .wallet-grid,
.wallet-native[data-wallet-view="history"] .wallet-grid {
  display: none;
}

.wallet-native[data-wallet-view="home"] .wallet-history-panel,
.wallet-native[data-wallet-view="send"] .wallet-history-panel,
.wallet-native[data-wallet-view="receive"] .wallet-history-panel,
.wallet-native[data-wallet-view="collateral"] .wallet-history-panel,
.wallet-native[data-wallet-view="security"] .wallet-history-panel {
  display: none;
}

.wallet-native:not([data-wallet-view="home"]) .wallet-balance-panel {
  display: none;
}

.wallet-native .wallet-receive-panel {
  padding: 24px;
}

.wallet-native .wallet-collateral-panel {
  margin-bottom: 16px;
  background: linear-gradient(180deg, #26272b 0%, #202124 100%);
}

.wallet-native .wallet-asset-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.wallet-native .wallet-asset-strip div {
  border: 1px solid var(--wallet-line);
  border-radius: 18px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.055);
}

.wallet-native .wallet-asset-strip span {
  display: block;
  color: var(--wallet-muted);
  font-size: 12px;
}

.wallet-native .wallet-asset-strip strong {
  display: block;
  margin-top: 6px;
  color: var(--wallet-green);
}

.wallet-native .wallet-node-select-label {
  display: grid;
  gap: 8px;
  margin: 0 0 14px;
  color: var(--wallet-muted);
  font-size: 12px;
  font-weight: 800;
}

.wallet-native .wallet-node-select-label select {
  min-height: 48px;
  border: 1px solid var(--wallet-line);
  border-radius: 16px;
  background: #17181a;
  color: var(--wallet-text);
  padding: 0 14px;
  font-weight: 800;
}

.wallet-native .wallet-node-focus {
  border: 1px solid rgba(66, 245, 141, 0.35);
  border-radius: 20px;
  padding: 16px;
  margin: 12px 0 14px;
  background: rgba(66, 245, 141, 0.08);
}

.wallet-native .wallet-node-focus-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.wallet-native .wallet-node-kicker {
  display: block;
  color: var(--wallet-green);
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 6px;
}

.wallet-native .wallet-node-focus h3 {
  margin: 0;
  color: var(--wallet-text);
  font-size: 20px;
  overflow-wrap: anywhere;
}

.wallet-native .wallet-node-badge {
  border: 1px solid var(--wallet-line);
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--wallet-muted);
  font-weight: 900;
  white-space: nowrap;
}

.wallet-native .wallet-node-badge.active {
  border-color: rgba(66, 245, 141, 0.45);
  background: rgba(66, 245, 141, 0.14);
  color: var(--wallet-green);
}

.wallet-native .wallet-node-focus-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.wallet-native .wallet-node-focus-grid div {
  border: 1px solid var(--wallet-line);
  border-radius: 14px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.055);
}

.wallet-native .wallet-node-focus-grid span {
  display: block;
  color: var(--wallet-muted);
  font-size: 12px;
}

.wallet-native .wallet-node-focus-grid strong {
  display: block;
  margin-top: 4px;
  color: var(--wallet-green);
  overflow-wrap: anywhere;
}

.wallet-native .wallet-node-memo {
  display: block;
  margin-top: 12px;
  border: 1px solid var(--wallet-line);
  border-radius: 14px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.07);
  color: #75ffd0;
  overflow-wrap: anywhere;
}

.wallet-native .wallet-node-list {
  margin: 12px 0 14px;
}

.wallet-native .wallet-node-list summary {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--wallet-line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--wallet-text);
  font-weight: 900;
}

.wallet-native .wallet-node-list-body {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.wallet-native .wallet-node-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.wallet-native .wallet-node-link .item {
  border-color: rgba(66, 245, 141, 0.2);
}

.wallet-native .wallet-collateral-events {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.wallet-native[data-wallet-view="collateral"] .wallet-collateral-address {
  display: block;
}

.wallet-native[data-wallet-view="collateral"] .wallet-collateral-actions {
  display: flex;
}

.wallet-native .wallet-receive-address {
  display: block;
  width: 100%;
  margin-top: 18px;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.wallet-native .wallet-receive-actions {
  width: 100%;
  justify-content: center;
  margin-top: 10px;
}

.wallet-native[data-wallet-view="receive"] .wallet-receive-address,
.wallet-native[data-wallet-view="receive"] .wallet-receive-actions {
  display: flex;
}

.wallet-native[data-wallet-view="receive"] .wallet-receive-address {
  display: block;
}

.wallet-native .wallet-qr {
  width: min(220px, 70vw);
  height: min(220px, 70vw);
  padding: 10px;
  border-color: var(--wallet-line);
  border-radius: 24px;
}

.wallet-native .wallet-grid {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.72fr);
  gap: 16px;
}

.wallet-native .wallet-send-panel {
  background: linear-gradient(180deg, #26272b 0%, #202124 100%);
}

.wallet-native .wallet-form label {
  color: var(--wallet-muted);
}

.wallet-native .wallet-form input,
.wallet-native .wallet-form select,
.wallet-native .wallet-form textarea {
  min-height: 48px;
  border-color: var(--wallet-line);
  border-radius: 16px;
  background: #17181a;
  color: var(--wallet-text);
}

.wallet-native .wallet-form input::placeholder,
.wallet-native .wallet-form textarea::placeholder {
  color: #6f727a;
}

.wallet-native .wallet-field-error {
  border-color: rgba(248, 113, 113, 0.45);
  border-radius: 16px;
  background: rgba(127, 29, 29, 0.25);
  color: #fecaca;
}

.wallet-native .wallet-success {
  border-color: rgba(66, 245, 141, 0.32);
  border-radius: 16px;
  background: rgba(66, 245, 141, 0.14);
  color: #86efac;
}

.wallet-native .wallet-alert {
  border-color: rgba(66, 245, 141, 0.28);
  background: rgba(66, 245, 141, 0.12);
  color: var(--wallet-text);
}

.wallet-native .wallet-history-panel {
  margin-top: 16px;
  overflow: hidden;
}

.wallet-native .wallet-history-filter {
  display: flex;
  gap: 8px;
  margin: 14px 0 18px;
  overflow-x: auto;
}

.wallet-native .wallet-history-filter button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--wallet-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--wallet-muted);
  font-weight: 900;
  white-space: nowrap;
}

.wallet-native .wallet-history-filter button.active {
  border-color: rgba(66, 245, 141, 0.35);
  background: rgba(66, 245, 141, 0.18);
  color: var(--wallet-green);
}

.wallet-native .wallet-history-hidden {
  display: none !important;
}

.wallet-native table {
  color: var(--wallet-text);
}

.wallet-native th {
  color: var(--wallet-muted);
}

.wallet-native td {
  border-color: var(--wallet-line);
}

.wallet-native code {
  color: #75ffd0;
}

.wallet-native .badge-ok {
  background: rgba(66, 245, 141, 0.14);
  color: var(--wallet-green);
}

@media (max-width: 900px) {
  .wallet-native {
    width: min(100%, calc(100% - 18px));
    padding-bottom: max(22px, env(safe-area-inset-bottom, 0px));
  }

  .wallet-native .wallet-topbar {
    display: grid;
    gap: 12px;
  }

  .wallet-native .top-actions {
    justify-content: flex-start;
  }

  .wallet-native .wallet-hero,
  .wallet-native .wallet-grid {
    grid-template-columns: 1fr;
  }

  .wallet-native .wallet-subgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wallet-native .wallet-actions .nav-button {
    flex: 1 1 140px;
    justify-content: center;
  }

  .wallet-native .wallet-primary-actions {
    grid-template-columns: repeat(6, minmax(48px, 1fr));
  }

  .wallet-native .wallet-primary-actions button {
    min-height: 86px;
  }

  .wallet-native .wallet-sticky-actions {
    margin-left: -6px;
    margin-right: -6px;
    padding: 8px 6px;
  }
}

@media (max-width: 560px) {
  .wallet-native {
    width: 100%;
    padding: max(46px, calc(env(safe-area-inset-top, 0px) + 30px)) 10px max(26px, env(safe-area-inset-bottom, 0px));
  }

  .wallet-native .wallet-node-focus h3 {
    font-size: 18px;
  }

  .wallet-native .wallet-node-focus-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wallet-native .wallet-node-list summary {
    padding: 11px 12px;
  }

  .wallet-native .wallet-topbar {
    margin: 0 -10px 14px;
    padding: 14px 14px 12px;
  }

  .wallet-native .top-actions .nav-button,
  .wallet-native .top-actions .status {
    min-height: 38px;
    padding: 8px 12px;
    font-size: 13px;
  }

  .wallet-native .wallet-balance-panel,
  .wallet-native .panel {
    border-radius: 22px;
    padding: 18px;
  }

  .wallet-native .wallet-balance {
    font-size: clamp(32px, 10.5vw, 52px);
  }

  .wallet-native .wallet-primary-actions strong {
    font-size: 13px;
  }

  .wallet-native .wallet-primary-actions span {
    width: 38px;
    height: 38px;
  }

  .wallet-native .wallet-sticky-actions {
    top: max(82px, calc(env(safe-area-inset-top, 0px) + 60px));
    grid-template-columns: repeat(6, minmax(46px, 1fr));
    gap: 8px;
    margin: 0 -10px 18px;
    padding: 8px 10px;
    border-radius: 0 0 22px 22px;
  }

  .wallet-native .wallet-sticky-actions button {
    min-height: 70px;
    padding: 10px 4px;
  }

  .wallet-native .wallet-asset-strip {
    grid-template-columns: 1fr;
  }

  .wallet-native .table-wrap {
    overflow: visible;
  }

  .wallet-native table,
  .wallet-native tbody,
  .wallet-native tr,
  .wallet-native td {
    display: block;
    width: 100%;
  }

  .wallet-native thead {
    display: none;
  }

  .wallet-native tr {
    margin-bottom: 12px;
    padding: 14px;
    border: 1px solid var(--wallet-line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.045);
  }

  .wallet-native td {
    padding: 4px 0;
    border: 0;
    overflow-wrap: anywhere;
  }
}
