.wallet-menu {
  position: relative;
  z-index: 20;
}

.wallet-menu .wallet {
  position: relative;
  z-index: 1;
}

.wallet-popover[hidden] {
  display: none;
}

.wallet-popover {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(320px, calc(100vw - 28px));
  padding: 17px;
  border: 1px solid #7d9851;
  background:
    linear-gradient(145deg, rgba(25, 34, 26, .98), rgba(35, 24, 15, .97)),
    url('assets/nt-chart-frame.jpg') center / cover;
  box-shadow: 8px 8px 0 rgba(0, 0, 0, .38);
}

.wallet-popover::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(222, 200, 151, .08), transparent 42%);
}

.wallet-popover > * {
  position: relative;
}

.wallet-popover-head {
  display: grid;
  gap: 7px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(208, 210, 190, .28);
}

.wallet-popover-head span {
  color: var(--acid);
  font: 800 10px/1.3 ui-monospace, monospace;
  letter-spacing: .06em;
}

.wallet-popover-head strong {
  color: var(--text);
  font: 800 14px/1.2 ui-monospace, monospace;
  letter-spacing: .02em;
  word-break: break-all;
}

.wallet-balances {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 12px;
}

.wallet-balance {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(129, 151, 125, .48);
  background: rgba(8, 14, 10, .56);
}

.wallet-balance span {
  display: block;
  color: var(--muted);
  font: 800 10px/1.3 ui-monospace, monospace;
}

.wallet-balance strong {
  display: block;
  margin-top: 7px;
  color: var(--text);
  font: 800 17px/1.1 ui-monospace, monospace;
  word-break: break-word;
}

.wallet-balance-status {
  margin: 12px 0 14px;
  color: var(--muted);
  font: 800 10px/1.5 ui-monospace, monospace;
}

.wallet-disconnect {
  width: 100%;
  padding: 11px;
  border: 1px solid #8a5b43;
  background: #3a251a;
  color: #ffd9c4;
  font: 800 11px ui-monospace, monospace;
  cursor: pointer;
}

.wallet-disconnect:hover {
  border-color: var(--orange);
  background: #4a2a1c;
}

@media (max-width: 500px) {
  .wallet-popover {
    width: min(320px, calc(100vw - 24px));
  }
}
