:root {
  --bg-0: #07080c;
  --bg-1: #0d0f16;
  --glass: rgba(22, 25, 36, 0.55);
  --glass-border: rgba(232, 213, 163, 0.12);
  --glass-highlight: rgba(255, 255, 255, 0.04);
  --text: #ffffff;
  --muted: #c2c6d0;
  --accent: #c8a45a;
  --accent-2: #7a9e8e;
  --track: rgba(255, 255, 255, 0.08);
  --thumb: #e8d5a3;
  --ok: #7a9e8e;
  --warn: #c8a45a;
  --danger: #b86b6b;
  --radius: 22px;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --font: "Sora", "Trebuchet MS", "Segoe UI", sans-serif;
  --mono: "Sora", "Trebuchet MS", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  min-height: 100%;
}

body {
  font-family: var(--font) !important;
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: 0.015em;
  font-weight: 500;
  color: var(--text);
  background: radial-gradient(1200px 800px at 10% -10%, #151821 0%, var(--bg-0) 55%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, button, input, label, .gift-card .title, .picker-item-name, .frow-label, .chip {
  font-family: var(--font) !important;
}

.ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.35;
  animation: drift 14s ease-in-out infinite alternate;
}

.orb-a {
  width: 280px;
  height: 280px;
  top: -60px;
  right: -40px;
  background: radial-gradient(circle, rgba(200, 164, 90, 0.55), transparent 70%);
}

.orb-b {
  width: 320px;
  height: 320px;
  bottom: 10%;
  left: -80px;
  background: radial-gradient(circle, rgba(122, 158, 142, 0.4), transparent 70%);
  animation-delay: -4s;
}

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(18px, 24px, 0) scale(1.08); }
}

.shell {
  position: relative;
  z-index: 1;
  max-width: 440px;
  margin: 0 auto;
  padding: 28px 20px 40px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  padding: 4px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.tabs button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: var(--font);
  font-size: 0.75rem;
  font-weight: 500;
  padding: 10px 4px;
  border-radius: 12px;
  cursor: pointer;
}

.tabs button.active {
  background: rgba(200, 164, 90, 0.14);
  color: #e8d5a3;
}

.tab-pane {
  display: none;
  flex-direction: column;
  gap: 16px;
}

.tab-pane.active {
  display: flex;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 4px;
}

.health {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted);
}

.health[data-state="live"] {
  color: var(--ok);
  border-color: rgba(122, 158, 142, 0.35);
  background: rgba(122, 158, 142, 0.1);
}

.health[data-state="err"] {
  color: var(--danger);
  border-color: rgba(184, 107, 107, 0.35);
  background: rgba(184, 107, 107, 0.1);
}

.presets, .alerts {
  padding: 14px 16px 16px;
}

.panel-head.tight {
  margin-bottom: 12px;
  font-size: 0.85rem;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.preset-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.preset-row button {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: #cfcabe;
  border-radius: 12px;
  padding: 10px 4px;
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
}

.preset-row button.active {
  border-color: rgba(200, 164, 90, 0.4);
  background: rgba(200, 164, 90, 0.14);
  color: #e8d5a3;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field-label {
  font-size: 0.84rem;
  color: #d5d2c8;
}

.field-hint {
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.35;
}

.text-input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.88rem;
  padding: 12px 14px;
  outline: none;
}

.text-input:focus {
  border-color: rgba(200, 164, 90, 0.35);
}

.alerts-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 220px;
  overflow-y: auto;
}

.alert-item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.alert-item strong {
  display: block;
  font-size: 0.84rem;
  font-weight: 500;
}

.alert-item span {
  font-size: 0.72rem;
  color: var(--muted);
  font-family: var(--mono);
}

.alert-item .roi {
  color: var(--ok);
  font-family: var(--mono);
  font-size: 0.84rem;
  white-space: nowrap;
}

.empty {
  font-size: 0.78rem;
  color: var(--muted);
  padding: 8px 2px;
}

.linkish {
  border: 0;
  background: none;
  color: var(--accent);
  font-family: var(--font);
  font-size: 0.75rem;
  cursor: pointer;
}

.feed-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gift-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.gift-card {
  border-radius: 16px;
  overflow: hidden;
  background: #12141c;
  border: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.gift-card .art {
  position: relative;
  aspect-ratio: 1;
  background: #0d1018;
  overflow: hidden;
  cursor: pointer;
}

.gift-card .art:active {
  opacity: 0.92;
}

.gift-card .art img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  position: relative;
  z-index: 1;
}

.gift-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  font-size: 2.4rem;
  opacity: 0.5;
}

.modal-art {
  position: relative;
  aspect-ratio: 1;
  background: #111318;
  overflow: hidden;
  cursor: default;
  border-radius: 0;
}

.modal-art.is-entering .gift-stage {
  animation: gift-import 0.35s ease-out both;
}

@keyframes gift-import {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-media {
  position: absolute;
  inset: 0;
}

.gift-stage {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.gift-stage .gift-static--base,
.gift-stage .gift-static {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border: 0;
  border-radius: 0;
  outline: none;
  box-shadow: none;
  filter: none;
  transform: scale(1.04);
  z-index: 1;
}

.gift-stage .gift-lottie {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  padding: 0;
  margin: 0;
  filter: none;
  box-shadow: none;
  background: transparent;
}

.gift-stage .gift-lottie svg {
  width: 100% !important;
  height: 100% !important;
  display: block;
  transform: scale(1.04);
}

.modal-art-fade {
  position: absolute;
  inset: auto 0 0 0;
  height: 46%;
  background: linear-gradient(180deg, transparent 0%, rgba(8, 10, 14, 0.55) 45%, rgba(8, 10, 14, 0.92) 100%);
  pointer-events: none;
  z-index: 3;
}

.modal-art-meta {
  position: absolute;
  left: 16px;
  right: 52px;
  bottom: 14px;
  z-index: 4;
}

.gift-card .badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  gap: 4px;
}

.gift-card .badge-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(20, 22, 30, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: grid;
  place-items: center;
}

.gift-card .badge-dot svg {
  width: 10px;
  height: 10px;
  color: #dfe3ea;
}

.gift-card .meta {
  padding: 10px 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.gift-card .title {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.25;
  color: #fff;
}

.gift-card .sub {
  font-family: var(--font);
  font-size: 0.74rem;
  font-weight: 500;
  color: var(--muted);
}

.gift-card .attrs {
  font-size: 0.62rem;
  color: #9aa0ad;
  line-height: 1.35;
}

.gift-card .buy {
  margin-top: 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.gift-card .price-btn {
  flex: 1;
  border: 0;
  border-radius: 10px;
  padding: 8px 10px;
  background: #2f6fed;
  color: #fff;
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
}

.gift-card .roi-tag {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--ok);
  white-space: nowrap;
}

.gift-grid .empty {
  grid-column: 1 / -1;
}

.ghost-btn.compact {
  width: auto;
  padding: 10px 14px;
  margin: 0;
}

.deposit-row {
  margin-top: 12px;
}

.header-balance {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--accent);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(200, 164, 90, 0.25);
  background: rgba(200, 164, 90, 0.08);
}

.buy-rub {
  margin-top: 6px;
  width: 100%;
  border: 0;
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(122, 158, 142, 0.25);
  color: #d7ebe2;
  font-family: var(--mono);
  font-size: 0.72rem;
  cursor: pointer;
}

.wallet-balance {
  font-family: var(--mono);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--accent);
  margin-top: 4px;
}

.modal[hidden] {
  display: none !important;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: end center;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(8px);
}

.modal-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 440px);
  max-height: 92vh;
  overflow: auto;
  border-radius: 24px 24px 0 0;
  background:
    radial-gradient(120% 80% at 50% -10%, rgba(200, 164, 90, 0.16), transparent 55%),
    linear-gradient(180deg, #151821 0%, #0c0e14 100%);
  border: 1px solid rgba(200, 164, 90, 0.18);
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.45);
  animation: sheet-up 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes sheet-up {
  from { transform: translateY(24px); opacity: 0.4; }
  to { transform: translateY(0); opacity: 1; }
}

.modal-x {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(8, 10, 14, 0.55);
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.modal-eye {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 5;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(8, 10, 14, 0.55);
  color: #e8ecf4;
  display: grid;
  place-items: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
  padding: 0;
}

.modal-eye:active {
  transform: scale(0.94);
  opacity: 0.9;
}

.modal-eye svg {
  display: block;
}

.modal-art-meta h2 {
  margin: 0;
  font-family: var(--font) !important;
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.65);
}

.modal-art-meta .sub {
  margin: 6px 0 0;
  font-family: var(--font) !important;
  font-size: 0.88rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
}

.modal-body {
  padding: 14px 16px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-price-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.modal-price {
  font-family: var(--mono);
  font-size: 1.55rem;
  font-weight: 700;
  color: #f0e6c8;
  letter-spacing: -0.03em;
}

.modal-roi {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(122, 158, 142, 0.2);
  border: 1px solid rgba(122, 158, 142, 0.35);
  color: #cfe8dc;
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
}

.attr-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.attr-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: calc(33.33% - 6px);
  flex: 1 1 96px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.attr-chip .k {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(197, 200, 208, 0.65);
}

.attr-chip .v {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: #e8e4dc;
  line-height: 1.25;
}

.attr-chip .r {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--accent);
}

.modal-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.stat-pill {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(200, 164, 90, 0.06);
  border: 1px solid rgba(200, 164, 90, 0.14);
}

.stat-pill .k {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(197, 200, 208, 0.65);
}

.stat-pill .v {
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 0.86rem;
  color: #f3efe6;
}

.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
  position: sticky;
  bottom: 0;
  padding-top: 4px;
  background: linear-gradient(180deg, transparent, #0c0e14 30%);
}

.sales-block {
  margin-top: 2px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.sales-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.82rem;
  color: #e8e4dc;
}

.sales-scope {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: rgba(197, 200, 208, 0.55);
}

.sales-log {
  margin-top: 10px;
  max-height: 168px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--mono);
  font-size: 0.72rem;
}

.sales-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 8px;
  align-items: center;
  padding: 9px 11px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.05);
  color: #c5c8d0;
}

.sales-row.summary {
  background: rgba(200, 164, 90, 0.08);
  border-color: rgba(200, 164, 90, 0.18);
}

.sales-row .price {
  color: var(--accent, #c8a45a);
  font-weight: 600;
}

.sales-row .mint {
  opacity: 0.75;
}

.wallet-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.deposit-row {
  margin-top: 12px;
}

.header-balance {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--accent);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(200, 164, 90, 0.25);
  background: rgba(200, 164, 90, 0.08);
  white-space: nowrap;
}

.buy-rub {
  margin-top: 6px;
  width: 100%;
  border: 0;
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(122, 158, 142, 0.25);
  color: #d7ebe2;
  font-family: var(--mono);
  font-size: 0.72rem;
  cursor: pointer;
}

.buy-rub:active {
  opacity: 0.85;
}

.price-btn.big {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 14px 16px;
  background: #2f6fed;
  color: #fff;
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
}

.gift-card .art {
  cursor: zoom-in;
}

.gift-card .price-btn {
  cursor: pointer;
  border: 0;
}

.logo-mark {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 18px rgba(200, 164, 90, 0.25));
  animation: pulse-soft 3.6s ease-in-out infinite;
}

.logo-mark svg {
  width: 100%;
  height: 100%;
}

@keyframes pulse-soft {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 14px rgba(200, 164, 90, 0.2)); }
  50% { transform: scale(1.03); filter: drop-shadow(0 0 22px rgba(200, 164, 90, 0.35)); }
}

.brand-text h1 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  background: linear-gradient(120deg, #f2e6c8 0%, #c8a45a 45%, #9bb8a8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-text p {
  margin-top: 4px;
  font-size: 0.88rem;
  color: var(--muted);
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.glass {
  background: linear-gradient(160deg, var(--glass-highlight), transparent 40%), var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.panel {
  padding: 20px 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.panel-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text);
}

.panel-head .status {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.25s ease;
}

.panel-head .status[data-state="saving"] { color: var(--warn); }
.panel-head .status[data-state="saved"] { color: var(--ok); }
.panel-head .status[data-state="error"] { color: var(--danger); }

.icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
  flex-shrink: 0;
}

.icon-sm {
  width: 16px;
  height: 16px;
  color: var(--accent-2);
  flex-shrink: 0;
}

.control {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.control-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.control-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #d5d2c8;
}

.control-value {
  font-family: var(--mono);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--accent);
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.control-value .unit {
  font-size: 0.7rem;
  color: var(--muted);
  font-weight: 400;
}

.slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(200, 164, 90, 0.55), rgba(122, 158, 142, 0.35));
  outline: none;
  cursor: pointer;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff6df, var(--thumb));
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4), 0 0 0 4px rgba(200, 164, 90, 0.12);
  transition: transform 0.15s ease;
}

.slider::-webkit-slider-thumb:active {
  transform: scale(1.12);
}

.slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff6df, var(--thumb));
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  cursor: pointer;
}

.range-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--muted);
  font-family: var(--mono);
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 18px;
}

.toggle-copy {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.toggle-copy strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 500;
}

.toggle-copy p {
  margin-top: 2px;
  font-size: 0.75rem;
  color: var(--muted);
}

.switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 28px;
  cursor: pointer;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.track {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: var(--track);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: background 0.25s ease, border-color 0.25s ease;
}

.thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #c5c2b8;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), background 0.25s ease;
}

.switch input:checked + .track {
  background: linear-gradient(90deg, rgba(122, 158, 142, 0.55), rgba(200, 164, 90, 0.45));
  border-color: rgba(200, 164, 90, 0.25);
}

.switch input:checked + .track .thumb {
  transform: translateX(20px);
  background: linear-gradient(145deg, #fff6df, #c8a45a);
}

.ghost-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: #d5d2c8;
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.ghost-btn:active {
  background: rgba(200, 164, 90, 0.12);
  border-color: rgba(200, 164, 90, 0.25);
}

.status-card {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.84rem;
}

.status-row.muted {
  color: var(--muted);
  font-size: 0.78rem;
}

.live-dot {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ok);
  position: relative;
  padding-left: 12px;
}

.live-dot::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ok);
  transform: translateY(-50%);
  box-shadow: 0 0 0 0 rgba(122, 158, 142, 0.55);
  animation: ping 1.8s ease-out infinite;
}

@keyframes ping {
  0% { box-shadow: 0 0 0 0 rgba(122, 158, 142, 0.45); }
  70% { box-shadow: 0 0 0 8px rgba(122, 158, 142, 0); }
  100% { box-shadow: 0 0 0 0 rgba(122, 158, 142, 0); }
}

.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.badge {
  font-family: var(--mono);
  font-size: 0.68rem;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: #b8b4a8;
}

.num-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 8px;
}

.picker-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.picker-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 14px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: #f2f4f8;
  font-family: var(--font);
  font-size: 0.92rem;
  cursor: pointer;
  text-align: left;
}

.picker-row-label { font-weight: 600; }

.picker-row-value {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.8rem;
  max-width: 46%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.picker-row-chevron { color: #6a7080; font-size: 1.2rem; line-height: 1; }

.picker-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: #000;
  display: flex;
  flex-direction: column;
}

.picker-modal[hidden] { display: none !important; }

.picker-sheet {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 10px 14px calc(18px + env(safe-area-inset-bottom));
  background: #000;
}

.picker-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 2px 12px;
}

.picker-head h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.picker-close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #9aa0ad;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.picker-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 12px;
  background: #1c1c1e;
  color: #8e8e93;
  margin-bottom: 8px;
}

.picker-search input {
  flex: 1;
  border: 0;
  outline: none;
  background: transparent;
  color: #fff;
  font-family: var(--font);
  font-size: 0.95rem;
}

.picker-select-all {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.95rem;
  font-weight: 600;
}

.picker-cols {
  margin-left: auto;
  display: grid;
  grid-template-columns: 72px 88px;
  gap: 8px;
  text-align: right;
  font-size: 0.72rem;
  font-weight: 500;
  color: #c8a45a;
  margin-right: 10px;
}

.picker-check {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  background: transparent;
  flex-shrink: 0;
  cursor: pointer;
  padding: 0;
  position: relative;
}

.picker-check[aria-pressed="true"] {
  background: #2f6fed;
  border-color: #2f6fed;
}

.picker-check[aria-pressed="true"]::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 3px;
  width: 6px;
  height: 11px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.picker-list {
  flex: 1;
  overflow: auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
}

.picker-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 4px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: transparent;
  color: #fff;
  font-family: var(--font);
  text-align: left;
  cursor: pointer;
}

.picker-item-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  object-fit: cover;
  background: #1c1c1e;
  flex-shrink: 0;
}

.picker-item-icon.ph {
  display: grid;
  place-items: center;
  font-size: 0.7rem;
  color: #6a7080;
}

.picker-item-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.picker-item-name {
  font-size: 0.95rem;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.picker-item-sub {
  font-size: 0.72rem;
  color: #8e8e93;
}

.picker-item-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.picker-rarity {
  font-size: 0.68rem;
  font-weight: 700;
  color: #111;
  background: #e8c547;
  border-radius: 999px;
  padding: 2px 7px;
}

.picker-ton {
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 500;
  white-space: nowrap;
}

.picker-ton::before {
  content: "◆ ";
  font-size: 0.7rem;
  opacity: 0.85;
}

.picker-metrics {
  display: grid;
  grid-template-columns: 72px 88px;
  gap: 8px;
  text-align: right;
  flex-shrink: 0;
}

.picker-metrics .picker-ton { font-size: 0.78rem; }
.picker-metrics .up { color: #3dcf7a; }
.picker-metrics .down { color: #e07a3a; }

.browse-toolbar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

.browse-search-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.browse-search {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #1c1c1e;
  color: #8e8e93;
}

.browse-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: #fff;
  font-family: var(--font);
  font-size: 0.86rem;
}

.browse-icon-btn,
.browse-feed-btn {
  flex-shrink: 0;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: #1c1c1e;
  color: #fff;
  cursor: pointer;
  font-family: var(--font);
  font-size: 0.86rem;
  font-weight: 600;
}

.browse-icon-btn {
  width: 40px;
  display: grid;
  place-items: center;
  padding: 0;
}

.browse-feed-btn {
  padding: 0 14px;
}

.browse-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.browse-chips::-webkit-scrollbar { display: none; }

.chip {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: #1c1c1e;
  color: #fff;
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.chip-gear {
  width: 34px;
  padding: 0;
  justify-content: center;
  background: #f5c518;
  color: #111;
}

.chip.active {
  background: #f5c518;
  color: #111;
}

.chip-count {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #111;
  color: #f5c518;
  font-size: 0.68rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.chip.active .chip-count {
  background: #111;
  color: #f5c518;
}

.chip-x {
  font-size: 0.95rem;
  line-height: 1;
  opacity: 0.75;
  margin-left: 2px;
}

.chip-chevron {
  font-size: 0.7rem;
  opacity: 0.7;
  margin-left: 2px;
}

.status-card.compact {
  padding: 10px 12px;
  margin-bottom: 12px;
}

.status-card.compact .status-row {
  font-size: 0.78rem;
}

.price-sheet {
  position: fixed;
  inset: 0;
  z-index: 85;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.price-sheet[hidden] { display: none !important; }

.price-sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.price-sheet-card {
  position: relative;
  z-index: 1;
  width: min(100%, 440px);
  border-radius: 20px 20px 0 0;
  background: #121214;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px 16px calc(18px + env(safe-area-inset-bottom));
}

.price-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 1.05rem;
}

.price-sheet-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

.filters-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: #000;
  display: flex;
  flex-direction: column;
}

.filters-menu[hidden] { display: none !important; }

.filters-menu-sheet {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: #000;
  padding: 8px 0 calc(12px + env(safe-area-inset-bottom));
}

.filters-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px 14px;
}

.filters-menu-head h2 {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 700;
}

.filters-menu-body {
  flex: 1;
  overflow: auto;
  min-height: 0;
  padding: 0 4px;
}

.frow {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 52px;
  padding: 12px 16px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: transparent;
  color: #fff;
  font-family: var(--font);
  text-align: left;
}

.frow-btn { cursor: pointer; }

.frow-label {
  font-size: 1rem;
  font-weight: 600;
}

.frow-input {
  margin-left: auto;
  width: 88px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: #1c1c1e;
  color: #fff;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.95rem;
  outline: none;
}

.frow-input::placeholder { color: #8e8e93; }

.frow-value {
  margin-left: auto;
  color: #8e8e93;
  font-size: 0.86rem;
  max-width: 42%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.frow-chevron {
  color: #8e8e93;
  font-size: 0.75rem;
}

.frow-reset {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 10px 0 6px;
  border-radius: 999px;
  background: #f5c518;
  color: #111;
  font-size: 0.78rem;
  font-weight: 700;
  border: 0;
  cursor: pointer;
  font-family: var(--font);
}

.frow-reset .n {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #111;
  color: #f5c518;
  display: grid;
  place-items: center;
  font-size: 0.68rem;
}

.frow-panel {
  padding: 8px 16px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: #0a0a0a;
}

.fopt {
  display: block;
  width: 100%;
  padding: 12px 4px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: transparent;
  color: #fff;
  text-align: left;
  font-family: var(--font);
  font-size: 0.95rem;
  cursor: pointer;
}

.fopt:last-child { border-bottom: 0; }
.fopt.active { color: #f5c518; font-weight: 650; }

.ftag {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 4px;
  font-size: 0.95rem;
  color: #fff;
}

.filters-menu-foot {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 10px;
  padding: 14px 16px 0;
}

.filters-clear,
.filters-apply {
  height: 48px;
  border: 0;
  border-radius: 14px;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.filters-clear {
  background: #1c1c1e;
  color: #fff;
}

.filters-apply {
  background: #f5c518;
  color: #111;
}
