body:has(#pz-wallet-quicklinks) { padding-bottom: calc(8.75rem + env(safe-area-inset-bottom, 0px)); }
#pz-wallet-quicklinks { position: fixed; z-index: 9999; inset: auto 0 0; padding: .45rem max(.65rem, env(safe-area-inset-right, 0px)) calc(.45rem + env(safe-area-inset-bottom, 0px)) max(.65rem, env(safe-area-inset-left, 0px)); background: rgba(15, 23, 42, .98); border-top: 1px solid #334155; box-shadow: 0 -8px 24px rgba(0, 0, 0, .22); color: #fff; pointer-events: none; }
#pz-wallet-quicklinks nav { max-width: 54rem; margin: 0 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: stretch; gap: .45rem; }
#pz-wallet-quicklinks a,
#pz-wallet-quicklinks button { pointer-events: auto; }
#pz-wallet-quicklinks .pz-quicklink { min-width: 0; min-height: 3.15rem; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: .12rem; padding: .42rem .58rem; border: 1px solid #334155; border-radius: .75rem; background: #1e293b; color: #fff; text-decoration: none; }
#pz-wallet-quicklinks .pz-quicklink strong { font-size: .75rem; line-height: 1.2; font-weight: 750; }
#pz-wallet-quicklinks .pz-quicklink:hover { border-color: #34d399; background: #26364b; }
#pz-wallet-quicklinks .pz-quicklink-promocje { border-color: #047857; background: #064e3b; }
#pz-wallet-quicklinks .pz-quicklink-promocje:hover { background: #065f46; }
#pz-wallet-quicklinks .pz-install-button { min-width: 0; border: 0; border-radius: .75rem; padding: .55rem .7rem; background: #10b981; color: #052e24; text-align: center; font-size: .78rem; line-height: 1.2; font-weight: 800; }
#pz-wallet-quicklinks .pz-install-button:disabled { background: #d1fae5; color: #065f46; opacity: 1; }
.pz-install-dialog { position: fixed; inset: 50% auto auto 50%; transform: translate(-50%, -50%); width: min(90vw, 26rem); max-width: 26rem; border: 1px solid #475569; border-radius: 1rem; padding: 1.25rem; background: #0f172a; color: #fff; box-shadow: 0 24px 80px rgba(0, 0, 0, .5); }
.pz-install-dialog::backdrop { background: rgba(2, 6, 23, .72); }
.pz-install-dialog h2 { margin: 0 0 .75rem; font-size: 1.15rem; }
.pz-install-dialog p { line-height: 1.55; }
.pz-install-dialog button { margin-top: .5rem; border: 0; border-radius: .65rem; padding: .7rem 1rem; background: #10b981; color: #052e24; font-weight: 700; }
@media (max-width: 700px) {
  body:has(#pz-wallet-quicklinks) { padding-bottom: calc(8.5rem + env(safe-area-inset-bottom, 0px)); }
  #pz-wallet-quicklinks nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .35rem; }
  #pz-wallet-quicklinks .pz-quicklink { min-height: 2.75rem; padding: .35rem .48rem; }
  #pz-wallet-quicklinks .pz-quicklink strong { font-size: .69rem; }
  #pz-wallet-quicklinks .pz-quicklink-home { grid-column: 1; }
  #pz-wallet-quicklinks .pz-install-button { grid-column: 2; font-size: .69rem; }
}
@media (max-width: 360px) {
  #pz-wallet-quicklinks { padding-left: max(.4rem, env(safe-area-inset-left, 0px)); padding-right: max(.4rem, env(safe-area-inset-right, 0px)); }
  #pz-wallet-quicklinks nav { gap: .3rem; }
  #pz-wallet-quicklinks .pz-quicklink { padding: .32rem .38rem; }
  #pz-wallet-quicklinks .pz-quicklink strong { font-size: .64rem; }
}

/* Prevent the main flex item from expanding to its min-content width on narrow phones. */
body > main { width: 100%; min-width: 0; box-sizing: border-box; }
body > main > nav { max-width: 100%; min-width: 0; }

/* Expense category chips must keep dark, readable text in every interaction state. */
main button[aria-pressed="true"],
main button[aria-pressed="false"] {
  color: #0f172a !important;
  background-color: #f8fafc;
}
main button[aria-pressed="true"] {
  color: #064e3b !important;
  background-color: #d1fae5;
  border-color: #059669;
}
main button[aria-pressed="true"]:hover,
main button[aria-pressed="false"]:hover,
main button[aria-pressed="true"]:focus-visible,
main button[aria-pressed="false"]:focus-visible {
  color: #064e3b !important;
  background-color: #a7f3d0;
  outline: 2px solid #059669;
  outline-offset: 2px;
}

/* Privacy badge sits on a light-green background over the site's dark theme. */
main aside.wallet-privacy-badge {
  color: #0f172a !important;
}
