/* ps99gems app — same premium system as the landing. Near-black, Inter, glass, restrained blue. */
:root {
  --bg0: #050505;
  --bg1: #080808;
  --panel: rgba(255, 255, 255, 0.028);
  --panel2: rgba(255, 255, 255, 0.05);
  --border: rgba(255, 255, 255, 0.08);
  --border-bright: rgba(255, 255, 255, 0.18);
  --txt: #ffffff;
  --mut: #a3a3ad;
  --faint: #6e6e78;
  --acc: #38bdf8;
  --acc2: #0ea5e9;
  --acc-ink: #04121a;
  --acc-glow: rgba(56, 189, 248, 0.32);
  --err: #F05270;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.55);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  /* legacy aliases */
  --bg: var(--bg0);
  --bg2: var(--bg1);
  --bg-soft: var(--panel2);
  --card: var(--panel);
  --card2: var(--panel2);
  --line: var(--border);
  --line2: var(--border-bright);
  --acc-dark: var(--acc2);
  --ok: var(--acc);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; min-height: 100%; }
body {
  background: var(--bg0);
  background-image: radial-gradient(900px 420px at 50% -8%, rgba(56, 189, 248, 0.06), transparent 65%);
  background-attachment: fixed;
  color: var(--txt);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
body::after {
  content: ''; position: fixed; inset: 0; z-index: 200; pointer-events: none; opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
}
::selection { background: rgba(56, 189, 248, 0.28); }
a { color: var(--acc); text-decoration: none; transition: color .25s ease; }
a:hover { color: #bae6fd; }

/* NAV */
.nav {
  display: flex; align-items: center; gap: 10px;
  padding: 0 20px; height: 68px;
  background: rgba(5, 5, 5, 0.72);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.brand { font-weight: 700; font-size: 16px; letter-spacing: -0.01em; color: var(--txt); display: flex; align-items: center; gap: 10px; }
.brand-icon { width: 26px; height: 26px; object-fit: contain; transition: transform .3s var(--ease); }
.brand:hover .brand-icon { transform: scale(1.1) rotate(-6deg); }
.hero-gem { width: 40px; height: 40px; object-fit: contain; vertical-align: -10px; margin-right: 4px; }
.nav-links { display: flex; align-items: center; gap: 4px; margin-left: 18px; }
.nav-links a {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: 8px;
  color: var(--mut); font-weight: 500; font-size: 14px;
  transition: color .25s ease, background .25s ease;
}
.nav-links a:hover { color: var(--txt); background: rgba(255, 255, 255, 0.05); }
.nav-links a.active { color: var(--txt); background: rgba(255, 255, 255, 0.07); box-shadow: inset 0 0 0 1px var(--border); }
.rates-pill {
  margin-left: auto; font-size: 12.5px; font-weight: 500; color: var(--mut);
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border);
  border-radius: 999px; padding: 6px 14px; white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.user-box { display: flex; align-items: center; gap: 8px; margin-left: auto; font-size: 14px; }
.user-box img { width: 30px; height: 30px; border-radius: 50%; background: var(--panel2); border: 1px solid var(--border); }

/* LAYOUT */
.container { max-width: 860px; margin: 0 auto; padding: 40px 28px 90px; animation: page-in 0.9s var(--ease); }
@keyframes page-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.page-title { font-size: clamp(30px, 4vw, 40px); margin: 6px 0 6px; font-weight: 800; letter-spacing: -0.035em; line-height: 1.08; }
.page-sub { color: var(--mut); margin: 0 0 26px; font-size: 16px; }
.card {
  background:
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.016) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, 0.016) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.015));
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; margin: 14px 0; box-shadow: var(--shadow), inset 0 1px 0 rgba(255,255,255,0.06);
  transition: border-color .5s ease;
}
.card:hover { border-color: var(--border-bright); }
.card h2, .card h3 { margin-top: 0; letter-spacing: -0.02em; }
.accent-bar { height: 1px; background: var(--border); border-radius: 1px; margin-bottom: 20px; }

/* BUTTONS / INPUTS */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--border); border-radius: 9px;
  padding: 11px 18px; font: inherit; font-weight: 600; font-size: 14px; cursor: pointer;
  background: transparent; color: var(--txt);
  transition: transform .3s var(--ease), background .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.btn:hover { border-color: var(--border-bright); background: rgba(255, 255, 255, 0.04); }
.btn:active { transform: scale(.98); }
.btn.primary { background: #fff; border-color: #fff; color: #050505; }
.btn.primary:hover { background: #fff; box-shadow: 0 0 28px rgba(255, 255, 255, 0.22); }
.btn.success { background: var(--acc); border-color: transparent; color: var(--acc-ink); }
.btn.success:hover { background: var(--acc); box-shadow: 0 0 28px rgba(56, 189, 248, 0.4); }
.btn.quiet { background: transparent; }
.btn.small { padding: 8px 13px; font-size: 13px; }
.btn.big { width: 100%; margin-top: 16px; font-size: 15px; padding: 14px 18px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
input, select {
  background: #000; border: 1px solid var(--border); color: var(--txt);
  border-radius: var(--radius-sm); padding: 13px 15px; width: 100%; font: inherit; font-size: 15px;
  transition: border-color .25s ease, box-shadow .25s ease;
}
input:focus, select:focus { outline: none; border-color: rgba(56, 189, 248, 0.6); box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12); }
input::placeholder { color: var(--faint); }
label { display: block; margin: 20px 0 8px; color: var(--mut); font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.row { display: flex; gap: 8px; } .row input { flex: 1; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* RATE CARDS / STATS */
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.rate-card {
  background: var(--panel);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 26px;
  transition: transform .5s var(--ease), border-color .5s ease;
}
.rate-card:hover { transform: translateY(-3px); border-color: var(--border-bright); }
.rate-card h3 { margin: 0 0 6px; font-size: 12px; font-weight: 700; color: var(--mut); text-transform: uppercase; letter-spacing: 0.14em; }
.price { font-size: 34px; font-weight: 800; letter-spacing: -0.04em; }
.price span { font-size: 15px; color: var(--mut); font-weight: 500; letter-spacing: 0; }
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 14px 0; }
.stat { background: rgba(0, 0, 0, 0.3); border: 1px solid var(--border); border-radius: 12px; padding: 14px; text-align: center; transition: border-color .4s ease; }
.stat:hover { border-color: var(--border-bright); }
.stat b { display: block; font-size: 20px; letter-spacing: -0.02em; }
.stat small { color: var(--mut); font-size: 12px; }

/* CHART */
.chart { display: flex; align-items: flex-end; gap: 14px; min-height: 120px; padding: 14px; background: #000; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.bar-group { flex: 1; text-align: center; }
.bar { width: 100%; background: var(--acc); border-radius: 4px 4px 0 0; box-shadow: 0 0 16px rgba(56,189,248,.35); transition: height .8s var(--ease); min-height: 4px; }
.bar-group small { color: var(--mut); font-size: 12px; }

/* STEPS / LOGIN WIDGETS */
.steps-nav { display: flex; gap: 8px; margin: 16px 0; }
.step-dot { flex: 1; text-align: center; font-size: 12px; font-weight: 600; color: var(--mut); padding: 10px 4px; border: 1px solid var(--border); border-radius: 9px; background: rgba(255,255,255,0.02); transition: all .4s ease; }
.step-dot.on { color: #050505; background: #fff; border-color: #fff; font-weight: 700; }
.step-dot.done { color: var(--acc); border-color: rgba(56,189,248,.4); }
.progress { height: 6px; background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; margin: 10px 0; }
.progress > div { height: 100%; border-radius: 999px; background: var(--acc); width: 33%; transition: width .8s var(--ease); }
.challenge { margin-top: 16px; background: rgba(0, 0, 0, 0.3); border: 1px solid rgba(56,189,248,.28); border-radius: 14px; padding: 20px; }
.challenge-user { display: flex; gap: 12px; align-items: center; }
.challenge-user img { width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--border-bright); background: var(--panel2); }
.code-row { display: flex; align-items: center; gap: 10px; margin: 14px 0; flex-wrap: wrap; }
.code-row code { font-size: 17px; letter-spacing: .5px; line-height: 1.6; overflow-wrap: anywhere; background: #000; color: #fff; padding: 10px 18px; border-radius: 9px; border: 1px solid var(--border-bright); font-family: ui-monospace, 'SF Mono', 'Cascadia Code', Consolas, monospace; }
.list-check { list-style: none; padding: 0; margin: 12px 0; }
.list-check li { padding: 9px 0 9px 28px; position: relative; color: var(--mut); font-size: 14px; border-bottom: 1px solid var(--border); transition: color .3s ease; }
.list-check li:last-child { border-bottom: 0; }
.list-check li::before { content: ""; position: absolute; left: 4px; top: 15px; width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--border-bright); transition: all .3s ease; }
.list-check li.hit { color: var(--txt); }
.list-check li.hit::before { background: var(--acc); border-color: var(--acc); box-shadow: 0 0 10px var(--acc); }

/* TRADE */
.crypto-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.crypto { display: flex; align-items: center; gap: 11px; border: 1px solid var(--border); border-radius: 10px; padding: 11px 13px; cursor: pointer; background: rgba(255,255,255,0.02); transition: border-color .3s ease, background .3s ease, transform .3s var(--ease); }
.coin-img { width: 36px; height: 36px; border-radius: 50%; object-fit: contain; flex-shrink: 0; }
.crypto:hover { border-color: var(--border-bright); background: rgba(255,255,255,0.045); transform: translateY(-2px); }
.crypto.active { border-color: var(--border-bright); background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06); }
.crypto b { display: block; font-size: 15px; letter-spacing: -0.01em; } .crypto small { color: var(--mut); font-size: 12px; }
.calc { background: rgba(56, 189, 248, 0.05); border: 1px solid rgba(56, 189, 248, 0.18); border-radius: 10px; padding: 15px 17px; font-size: 16px; min-height: 52px; font-variant-numeric: tabular-nums; }
.calc b { letter-spacing: -0.01em; }
.calc .muted { font-size: 12.5px; }
.paybox { background: rgba(0, 0, 0, 0.3); border: 1px solid var(--border); border-radius: 10px; padding: 14px; margin-top: 12px; word-break: break-all; font-size: 14px; }
.msg { min-height: 22px; font-size: 14px; margin: 12px 0 0; }
.msg.err { color: var(--err); } .msg.ok { color: var(--acc); }
.hidden { display: none !important; }
.muted { color: var(--mut); } .tiny { font-size: 12px; } .center { text-align: center; }
.nowrap { white-space: nowrap; }
.id-avatar { width: 84px; height: 84px; border-radius: 50%; border: 1px solid var(--border-bright); background: var(--panel2); display: block; margin: 14px auto; }
.gem-icon { width: 1.15em; height: 1.15em; object-fit: contain; vertical-align: -0.2em; }
.gem-icon.lg { width: 30px; height: 30px; vertical-align: -7px; }
.footer { text-align: center; color: var(--faint); font-size: 12.5px; padding: 30px 0 10px; border-top: 1px solid var(--border); margin-top: 30px; }
.how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.how div { background: rgba(255,255,255,0.02); border: 1px solid var(--border); border-radius: 10px; padding: 15px; font-size: 13.5px; color: var(--mut); transition: border-color .4s ease; }
.how div:hover { border-color: var(--border-bright); }
.how b { color: var(--txt); display: block; margin-bottom: 4px; }
.cta-row { display: flex; gap: 10px; margin-top: 16px; } .cta-row .btn { flex: 1; text-align: center; }

/* tap-to-copy payment values */
.copy-chip {
  display: inline-block; font: inherit; cursor: pointer; text-align: left;
  color: var(--acc); background: rgba(56, 189, 248, 0.06);
  border: 1px solid rgba(56, 189, 248, 0.35); border-radius: 10px;
  padding: 10px 16px; word-break: break-all;
  transition: background .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.copy-chip:hover { background: rgba(56, 189, 248, 0.12); border-color: var(--acc); box-shadow: 0 0 18px rgba(56,189,248,.25); }
.copy-chip.big { font-size: 26px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin: 6px 0 4px; }
.copy-chip.addr { width: 100%; font-size: 14px; font-family: ui-monospace, 'SF Mono', Consolas, monospace; }
.copy-chip.copied { color: #fff; border-color: var(--border-bright); }

/* gift page */
.gift-hero { width: 84px; height: 84px; object-fit: contain; filter: drop-shadow(0 8px 26px rgba(56,189,248,.35)); }
.badge { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 5px 13px; border-radius: 999px; border: 1px solid var(--border-bright); }
.badge.open { color: var(--acc); border-color: rgba(56,189,248,.45); background: rgba(56,189,248,.07); }
.badge.done { color: var(--mut); }

/* carbon weave + dot textures (no external assets) */
.tex-carbon {
  background-image:
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.02) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, 0.02) 0 2px, transparent 2px 5px);
}
.tex-dots {
  background-image: radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1.3px);
  background-size: 18px 18px;
}

/* network picker pills */
.net-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.net-pill { border: 1px solid var(--border); border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 600; color: var(--mut); cursor: pointer; background: transparent; font: inherit; transition: all .25s ease; }
.net-pill:hover { color: #fff; border-color: var(--border-bright); }
.net-pill.on { color: #04121a; background: var(--acc); border-color: transparent; box-shadow: 0 0 16px var(--acc-glow); }

/* payment modal: pills, stepper, skeleton, focus */
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 6px 13px; border-radius: 999px; border: 1px solid var(--border-bright); white-space: nowrap; }
.pill-wait { color: var(--acc); border-color: rgba(56,189,248,.45); background: rgba(56,189,248,.07); }
.pill-done { color: #04121a; background: var(--acc); border-color: transparent; }
.pill-dead { color: var(--mut); }
.step-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 800; border: 1px solid var(--border); color: var(--faint); background: rgba(255,255,255,0.02); transition: all .5s ease; }
.step-n.done { background: var(--acc); border-color: transparent; color: #04121a; }
.step-n.active { border-color: var(--acc); color: var(--acc); box-shadow: 0 0 0 4px rgba(56,189,248,.15), 0 0 18px rgba(56,189,248,.35); animation: step-pulse 2s ease-in-out infinite; }
@keyframes step-pulse { 0%,100% { box-shadow: 0 0 0 4px rgba(56,189,248,.15), 0 0 18px rgba(56,189,248,.35); } 50% { box-shadow: 0 0 0 7px rgba(56,189,248,.08), 0 0 22px rgba(56,189,248,.45); } }
.step-lbl { font-size: 11.5px; color: var(--faint); font-weight: 600; }
.step-lbl.active { color: var(--txt); }
.step-lbl.done { color: var(--acc); }
.skel { border-radius: 10px; background: linear-gradient(100deg, rgba(255,255,255,.04) 30%, rgba(255,255,255,.09) 50%, rgba(255,255,255,.04) 70%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }

.amber { color: #fbbf24 !important; }
/* calm checkout: icon copy buttons + smooth expanders */
.copy-ic { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; border: 1px solid rgba(56,189,248,.45); color: #7dd3fc; background: rgba(56,189,248,.07); transition: all .25s ease; flex-shrink: 0; cursor: pointer; font: inherit; }
.copy-ic:hover { background: rgba(56,189,248,.14); box-shadow: 0 0 18px rgba(56,189,248,.3); }
.copy-ic.ghost { border-color: rgba(255,255,255,.12); color: #a1a1aa; background: transparent; }
.copy-ic.ghost:hover { border-color: rgba(255,255,255,.3); color: #fff; box-shadow: none; }
.copy-ic.copied { color: #fff; border-color: rgba(255,255,255,.3); }
.expandable { max-height: 0; overflow: hidden; transition: max-height .5s cubic-bezier(.16,1,.3,1); }
.expandable.open { max-height: 340px; }

@media (max-width: 640px) {
  .grid2, .row2, .how, .stat-row { grid-template-columns: 1fr; }
  .container { padding: 28px 18px 70px; }
  .nav-links { display: none; }
  .nav-links.open { display: flex; position: absolute; top: 68px; left: 0; right: 0; background: rgba(5,5,5,.95); backdrop-filter: blur(18px); flex-direction: column; padding: 10px; border-bottom: 1px solid var(--border); align-items: stretch; }
  #menuBtn { display: inline-flex !important; }
}
#menuBtn { display: none; }
