/* Wallet panel (wallet-panel.js). Black finish on every theme, matching the wallet inside it
   (wallet-web/styles.css); self-contained tokens, no external resources.
   The same file is shipped as website/assets/wallet-panel.css. */
.wp,
.wp-backdrop {
  --wp-bg: #050505;
  --wp-surface: #161617;
  --wp-border: rgba(255, 255, 255, 0.1);
  --wp-text: #f5f5f8;
  --wp-muted: #98989c;
  --wp-accent: #dfdfe2;
  --wp-accent-ink: #0a0a0a;
  --wp-warn: #f2cd7d;
  --wp-focus: #dfdfe2;
  --wp-shade: rgba(0, 0, 0, 0.6);
}

.wp-backdrop {
  position: fixed;
  inset: 0;
  pointer-events: none; /* dims only: clicks reach the page (see wallet-panel.js) */
  z-index: 90;
  background: var(--wp-shade);
}
.wp {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 91;
  width: min(380px, 100vw);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  background: var(--wp-bg);
  color: var(--wp-text);
  color-scheme: dark;
  border-left: 1px solid var(--wp-border);
  box-shadow: -24px 0 70px rgba(0, 0, 0, 0.6);
  font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  animation: wp-in 0.16s ease-out;
}
.wp[hidden],
.wp-backdrop[hidden] {
  display: none;
}
@keyframes wp-in {
  from { transform: translateX(24px); opacity: 0; }
  to { transform: none; opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .wp { animation: none; }
}
.wp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 10px 10px 18px;
  border-bottom: 1px solid var(--wp-border);
}
.wp-head h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  font-size: 15px;
  font-weight: 650;
  color: var(--wp-text);
}
.wp-body {
  flex: 1;
  overflow: auto;
  padding: 6px 18px 12px;
}
.wp-body p {
  margin: 10px 0;
}
.wp-muted {
  color: var(--wp-muted);
  font-size: 13.5px;
}
.wp-warn {
  color: var(--wp-warn);
}
.wp-foot {
  margin: 0;
  padding: 12px 18px;
  border-top: 1px solid var(--wp-border);
  background: var(--wp-surface);
  color: var(--wp-muted);
  font-size: 12.5px;
}
.wp-list {
  margin: 8px 0;
  padding-left: 20px;
}
.wp-list li {
  margin: 4px 0;
}
.wp-btn,
.wp-close,
.wp-toggle {
  font: inherit;
  color: var(--wp-text);
  background: var(--wp-surface);
  border: 1px solid var(--wp-border);
  border-radius: 12px;
  padding: 9px 15px;
  cursor: pointer;
  margin: 6px 6px 6px 0;
}
.wp-close {
  margin: 0;
  padding: 4px 11px;
  background: none;
  border-color: transparent;
  font-size: 20px;
  line-height: 1.2;
}
.wp-primary {
  background: linear-gradient(180deg, #fff, #d9d9dc);
  color: var(--wp-accent-ink);
  border-color: transparent;
  font-weight: 600;
}
.wp-toggle {
  display: block;
  width: 100%;
  text-align: left;
}
.wp-toggle[aria-pressed="true"] {
  border-color: var(--wp-accent);
}
.wp button:focus-visible,
.wp a:focus-visible {
  outline: 2px solid var(--wp-focus);
  outline-offset: 2px;
}
.wp-link {
  color: var(--wp-accent);
}
.wp-code {
  font: 600 28px/1.2 ui-monospace, "Cascadia Mono", Menlo, Consolas, monospace;
  letter-spacing: 0.12em;
  text-align: center;
  padding: 12px;
  border: 1px dashed var(--wp-border);
  border-radius: 10px;
  background: var(--wp-surface);
}
.wp-section {
  margin-top: 14px;
}
.wp-section h3 {
  margin: 0 0 6px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--wp-muted);
}
.wp-dl {
  margin: 0;
}
.wp-dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 0;
  border-bottom: 1px solid var(--wp-border);
}
.wp-dl dt {
  overflow: hidden;
  text-overflow: ellipsis;
}
.wp-dl dd {
  margin: 0;
  font-variant-numeric: tabular-nums;
}
.wp-props {
  list-style: none;
  margin: 0;
  padding: 0;
}
.wp-props li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 12px;
  padding: 6px 0;
  border-bottom: 1px solid var(--wp-border);
}
.wp-status {
  color: var(--wp-muted);
  font-size: 13px;
}
.wp-active {
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px solid var(--wp-accent);
  border-radius: 10px;
}
.wp-active p {
  margin: 4px 0 0;
}
/* Web wallet mode: the wallet's own panel, embedded from the wallet origin. */
.wp[data-mode="web"] {
  width: min(420px, 100vw);
}
.wp-web {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.wp-web[hidden],
.wp-body[hidden] {
  display: none;
}
.wp-frame-box {
  flex: 1;
  display: flex;
  min-height: 320px;
}
.wp-frame {
  flex: 1;
  width: 100%;
  min-height: 320px;
  border: 0;
  background: var(--wp-bg);
}
.wp-webbar {
  padding: 0 18px;
}
.wp-webbar:empty {
  display: none;
}
.wp-footer {
  border-top: 1px solid var(--wp-border);
  background: #080808;
}
.wp-footer .wp-foot {
  border-top: 0;
  background: none;
  padding: 2px 18px 10px;
  font-size: 11.5px;
  line-height: 1.4;
}
.wp-switch {
  font: inherit;
  font-size: 13px;
  background: none;
  border: 0;
  padding: 8px 18px 0;
  cursor: pointer;
  color: var(--wp-muted);
  text-decoration: underline;
}
.wp-switch[hidden] {
  display: none;
}
@media (max-width: 480px) {
  .wp,
  .wp[data-mode="web"] {
    width: 100vw;
    border-left: 0;
  }
}
