
:root {
  --brand-primary: #25d366;
  --brand-text: #111b21;
  --brand-soft: #e4f9ec;
  --green: var(--brand-primary);
  --muted: #54656f;
  --line: #e9edef;
  --surface: #f5f7f6;
  font: 15px/1.45 system-ui, sans-serif;
  color: var(--brand-text);
  background: var(--surface);
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
button, input, select { font: inherit; }
button, input, select {
  min-width: 0; min-height: 40px; padding: 8px 12px;
  border: 1px solid var(--line); border-radius: 9px;
}
input, select { color: var(--brand-text); background: white; }
button { color: var(--brand-text); background: var(--green); border-color: var(--green); font-weight: 650; cursor: pointer; }
button:disabled { opacity: .55; cursor: default; }
.secondary, #statement { background: white; border-color: var(--line); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid #137a40; outline-offset: 2px;
}
h1, h2, p { margin: 0; }
h1 { font-size: 21px; }
h2 { font-size: 16px; margin-bottom: 8px; }
p:empty { display: none; }
small { color: var(--muted); }
form { display: grid; gap: 10px; }
label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; }
#auth { max-width: 410px; margin: 32px auto; padding: 22px; background: white; border: 1px solid var(--line); border-radius: 14px; }
#auth h1 { margin-bottom: 18px; }
#register { margin-top: 10px; }
.top {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 56px; gap: 12px; padding: 8px 16px;
  border-bottom: 1px solid var(--line); background: white;
}
.top strong { font-size: 21px; }
.top button { background: var(--brand-soft); border: 0; }
.navigation {
  position: fixed; z-index: 2; bottom: 0; inset-inline: 0;
  display: flex; justify-content: space-around; background: white;
  border-top: 1px solid var(--line); padding: 4px 8px calc(4px + env(safe-area-inset-bottom));
}
.navigation a {
  display: grid; justify-items: center; align-content: center; min-height: 51px; min-width: 62px;
  gap: 2px; padding: 3px 8px; color: var(--brand-text); text-decoration: none; font-size: 12px; font-weight: 600;
}
.navigation span {
  display: grid; place-items: center; background: var(--brand-soft);
  width: 37px; height: 24px; border-radius: 20px; font-size: 18px; line-height: 1;
}
.navigation a:hover span, .navigation a:focus-visible span { background: var(--green); }
.workspace { display: grid; gap: 10px; align-content: start; padding: 12px 12px calc(74px + env(safe-area-inset-bottom)); min-width: 0; }
.workspace-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 0 2px; }
#name { color: var(--muted); overflow-wrap: anywhere; }
.balance { display: grid; gap: 4px; padding: 14px; border: 1px solid #c6edda; border-radius: 14px; background: var(--brand-soft); }
.balance strong { font-size: clamp(27px, 6vw, 35px); line-height: 1.15; overflow-wrap: anywhere; }
.balance .controls { margin-bottom: 3px; }
.balance button, .balance select { background: white; border-color: #c6e5d3; }
.balance small, #assets, #activity { color: var(--muted); }
#valuation { font-size: 12px; color: var(--muted); }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.controls select { max-width: 150px; }
.wallet-actions button { width: 100%; }
.panel { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: white; min-width: 0; }
.checkbox { display: flex; align-items: center; margin-bottom: 4px; }
.checkbox input { min-height: auto; width: 18px; height: 18px; accent-color: var(--green); }
.asset, .activity, .account-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; color: var(--brand-text); }
.asset div:last-child, .activity div:last-child { text-align: right; }
.asset small, .activity small { display: block; }
.asset button, .transfer-quick button { background: var(--brand-soft); border: 0; }
.asset .amount { font-weight: 600; }
.panel-header { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.transfer-review { display: grid; gap: 8px; margin: 10px 0; }
.transfer-review div { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); padding: 8px 0; overflow-wrap: anywhere; }
.transfer-review b { text-align: right; }
.transfer-quick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.transfer-notice { padding: 8px; background: var(--surface); border-radius: 8px; }
#activity-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 10px; }
#activity-filters .controls { grid-column: 1 / -1; }
#status, #transfer-status, #activity-status { color: #a12626; overflow-wrap: anywhere; }
#status { margin: 12px; }
.disconnected :is(#account, .account-link, .wallet-actions, .balance .controls, .checkbox) { display: none; }
@media (max-width: 759px) {
  .sidebar { position: sticky; top: 0; z-index: 2; }
  :is(#overview, #holdings, #account, #transactions) { scroll-margin-top: 64px; }
  #auth { margin-inline: 12px; }
}
@media (min-width: 760px) {
  body { background: linear-gradient(var(--green) 0 105px, #e9edef 105px); padding: 24px; }
  main { max-width: 1320px; margin: 0 auto; }
  #wallet { display: grid; grid-template-columns: minmax(210px, 25%) minmax(0, 1fr); min-height: calc(100vh - 48px); border: 1px solid #dce4df; border-radius: 12px; box-shadow: 0 8px 26px #111b211a; }
  .sidebar { background: white; border-radius: 12px 0 0 12px; border-right: 1px solid var(--line); }
  .top { border-radius: 12px 0 0; }
  .navigation { position: static; display: grid; padding: 10px; border: 0; gap: 4px; }
  .navigation a { display: flex; align-items: center; min-height: 49px; justify-content: flex-start; gap: 10px; font-size: 14px; border-radius: 8px; }
  .navigation a:hover { background: var(--surface); }
  .navigation span { width: 33px; height: 33px; }
  .workspace { padding: 16px 20px 24px; border-radius: 0 12px 12px 0; background: var(--surface); }
  #activity-filters { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
