/* ============================================================
   CRX MODS — Premium Store UI · v2
   Layered elevations · gradient accents · springy interactions
   Mobile-first · zero external deps · GPU-cheap animations
   ============================================================ */
:root {
  --bg: #f4f5fa;
  --fg: #14172c;
  --muted: #6b7280;
  --card: #ffffff;
  --line: #e6e8f0;
  --line-soft: #eef0f6;
  --accent: #4f46e5;
  --accent-2: #6366f1;
  --accent-soft: #eef0ff;
  --accent-grad: linear-gradient(135deg, #4f46e5 0%, #6366f1 100%);
  /* Wallet brand palette (checkout tutorial + selected pay-card) */
  --bkash-1: #EE1876;
  --bkash-2: #C10A5A;
  --nagad-1: #F6921E;
  --nagad-2: #D97706;
  --rocket-1: #8B3D9E;
  --rocket-2: #5C2870;
  --pay-c1: var(--bkash-1);
  --pay-c2: var(--bkash-2);
  --shadow-sm: 0 1px 2px rgba(20, 23, 44, 0.04);
  --shadow-md: 0 4px 14px rgba(20, 23, 44, 0.07);
  --shadow-lg: 0 12px 32px rgba(20, 23, 44, 0.12);
  /* Card elevations — two-layer (contact + ambient) for a premium depth feel */
  --shadow-card: 0 1px 2px rgba(20, 23, 44, 0.05), 0 3px 14px -4px rgba(20, 23, 44, 0.08);
  --shadow-card-hover: 0 2px 4px rgba(20, 23, 44, 0.05), 0 14px 30px -10px rgba(20, 23, 44, 0.18);
  /* Premium glow tokens (accent-tinted, cheap box-shadows only) */
  --glow-sm: 0 0 0 1px rgba(79, 70, 229, 0.28), 0 10px 26px -10px rgba(79, 70, 229, 0.45);
  --glow-md: 0 0 0 1px rgba(79, 70, 229, 0.34), 0 16px 34px -12px rgba(79, 70, 229, 0.52);
  --glow-cta: 0 8px 22px -8px rgba(79, 70, 229, 0.55);
  --ok: #059669;
  --err: #dc2626;
  --warn: #d97706;
  --tg: #229ed9;
  --r-sm: 9px;
  --r-md: 14px;
  --r-lg: 18px;
  --ease: cubic-bezier(.2, .8, .3, 1);
  --ease-spring: cubic-bezier(.34, 1.45, .5, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

html, body { height: 100%; }
body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* Premium ambient wash — two soft accent radials over the base gray */
  background:
    radial-gradient(900px 440px at 12% -8%, rgba(79, 70, 229, 0.055), transparent 62%),
    radial-gradient(720px 400px at 108% 112%, rgba(99, 102, 241, 0.05), transparent 58%),
    var(--bg);
  background-attachment: fixed;
  color: var(--fg);
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Topbar ---------- */
.topbar {
  flex: 0 0 auto; z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid rgba(230, 232, 240, 0.9);
}
.topbar-in {
  width: 100%; max-width: 1080px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px;
}
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--fg); }
.brand span { white-space: nowrap; }
.brand img {
  width: 30px; height: 30px; object-fit: cover; border-radius: 9px;
  border: 1px solid var(--line);
  box-shadow: 0 0 0 2px #fff, 0 2px 8px -2px rgba(79, 70, 229, 0.35);
}
.brand span {
  font-weight: 800; font-size: 14px; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--fg);
}
.top-right { display: flex; align-items: center; gap: 8px; }
.chip.bal {
  font-weight: 700; font-size: 12.5px; padding: 6px 11px;
  color: var(--accent); border-radius: 8px;
  background: var(--accent-soft);
  border: 1px solid #dcdffb;
}
.btn-login {
  display: inline-flex; align-items: center; gap: 5px;
  font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer;
  padding: 7px 14px; color: var(--accent);
  background: #fff;
  border: 1px solid #c7caf7; border-radius: 8px;
  transition: background .18s var(--ease), border-color .18s var(--ease), transform .12s var(--ease), box-shadow .2s var(--ease);
}
.btn-login:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px -4px rgba(79, 70, 229, 0.28);
}
.btn-login:active { transform: scale(.97); }
.btn-login svg { width: 14px; height: 14px; }
.btn-support {
  display: inline-flex; align-items: center; gap: 5px;
  font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer;
  padding: 7px 12px; color: var(--fg);
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  transition: border-color .15s, color .15s, background .15s;
}
.btn-support:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.btn-support svg { width: 15px; height: 15px; }

/* ---------- Main scroll region ---------- */
.main {
  flex: 1 1 auto; min-height: 0;
  width: 100%; max-width: 1080px; margin: 0 auto;
  padding: 14px 14px 24px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scroll-behavior: smooth;
}

.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 18px 16px;
  box-shadow: var(--shadow-card);
  animation: fadeUp .35s var(--ease) both;
}
.panel.center { text-align: center; }
.panel + .panel { margin-top: 12px; }

h2 { font-size: 17px; font-weight: 800; letter-spacing: -0.01em; }
h3 { font-size: 14px; font-weight: 700; }
.muted { color: var(--muted); }
.sm { font-size: 12px; }
.big { font-size: 34px; margin-bottom: 4px; }

/* ---------- Banner (auto-height, full image, card border) ---------- */
.banner-wrap {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: #fff;
  animation: fadeUp .4s var(--ease) both;
}
.banner-slide {
  display: none;
  width: 100%;
  border-radius: var(--r-md);
  overflow: hidden;
}
.banner-slide.on { display: block; animation: fadeIn .5s ease both; }

.banner-slide img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  background: #fafbfd;
  border-radius: var(--r-md);
  pointer-events: none;
}
@media (max-width: 560px) {
  .banner-slide img { max-height: 240px; }
}

a.banner-slide { cursor: pointer; }
a.banner-slide img { pointer-events: auto; }

.banner-dots {
  position: absolute;
  bottom: 10px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 6px;
  z-index: 3;
  pointer-events: none;
}
.banner-dot {
  width: 7px; height: 7px; border-radius: 50%;
  border: none; padding: 0; cursor: pointer;
  background: rgba(255, 255, 255, 0.65);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  transition: transform .25s var(--ease), background .25s var(--ease);
  pointer-events: auto;
}
.banner-dot.on { background: #fff; transform: scale(1.3); }

.banner-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 32px; height: 32px; border-radius: 50%;
  display: none; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 800; cursor: pointer;
  color: var(--fg); background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  transition: background .18s, color .18s, transform .18s;
  user-select: none;
  pointer-events: auto;
}
.banner-arrow:hover { background: var(--accent); color: #fff; }
.banner-arrow.prev { left: 10px; }
.banner-arrow.next { right: 10px; }
.banner-wrap:hover .banner-arrow { display: inline-flex; }

/* ---------- Filters ---------- */
.filters { display: flex; gap: 7px; margin: 14px 0; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.filters::-webkit-scrollbar { display: none; }
.chip-btn {
  flex: 0 0 auto; cursor: pointer; border-radius: 999px;
  font: inherit; font-size: 12px; font-weight: 700; color: var(--muted);
  padding: 7px 14px;
  background: #fff; border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: color .18s, border-color .18s, background .18s, transform .15s var(--ease), box-shadow .2s var(--ease);
}
.chip-btn:hover { color: var(--accent); border-color: #c9cdf5; transform: translateY(-1px); box-shadow: 0 4px 12px -6px rgba(79, 70, 229, 0.35); }
.chip-btn.on {
  color: #fff; background: var(--accent-grad);
  border-color: transparent;
  box-shadow: 0 4px 14px -4px rgba(79, 70, 229, 0.55);
  animation: chipPop .3s var(--ease-spring);
}
@keyframes chipPop {
  0% { transform: scale(.9); }
  50% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

/* ---------- Product cards ---------- */
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 11px; }
.card {
  position: relative;
  display: flex; flex-direction: column; text-align: center; cursor: pointer;
  font: inherit; color: var(--fg);
  background: linear-gradient(180deg, #ffffff 0%, #fbfbfe 100%);
  border: 1px solid #e3e6f2;
  border-radius: var(--r-md);
  padding: 16px 12px 12px;
  box-shadow: var(--shadow-card);
  transition: border-color .2s var(--ease), transform .28s var(--ease-spring), box-shadow .28s var(--ease);
  animation: fadeUp .4s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 40ms);
  overflow: hidden;
}
/* gloss sweep — a light band that crosses the card on hover */
.card::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 32%, rgba(255, 255, 255, 0.5) 48%, transparent 62%);
  transform: translateX(-130%);
  transition: transform .7s var(--ease);
  pointer-events: none;
}
.card:hover::after { transform: translateX(130%); }
.card:hover {
  border-color: rgba(79, 70, 229, 0.45);
  transform: translateY(-4px);
  box-shadow: var(--glow-sm), var(--shadow-card-hover);
}
.card:active { transform: translateY(-1px) scale(.97); transition-duration: .12s; }
.card-art {
  width: 62px; height: 62px; margin: 0 auto;
  overflow: hidden; border-radius: 16px;
  border: 1px solid rgba(79, 70, 229, 0.18);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 22px; color: #fff;
  background-image: var(--accent-grad);
  flex-shrink: 0;
  position: relative;
  transition: transform .3s var(--ease-spring), box-shadow .3s var(--ease);
}
/* art ring — soft halo that lifts on hover */
.card-art::before {
  content: "";
  position: absolute; inset: -4px;
  border-radius: 19px;
  box-shadow: 0 0 0 0 rgba(79, 70, 229, 0);
  transition: box-shadow .3s var(--ease);
  pointer-events: none;
}
.card:hover .card-art {
  transform: scale(1.07) rotate(-1.2deg);
  box-shadow: 0 10px 22px -8px rgba(79, 70, 229, 0.55);
}
.card:hover .card-art::before { box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.12); }
.card-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-art.sm { width: 44px; height: 44px; font-size: 16px; margin: 0; border-radius: 12px; }
.card-body { margin-top: 11px; flex: 1; }
.card-body h3 {
  font-size: 13px; font-weight: 700; letter-spacing: -0.01em;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.tag-pill {
  display: inline-block; margin: 6px 3px 0 0;
  font-size: 10px; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase;
  padding: 2px 7px; border-radius: 6px; color: var(--muted);
  border: 1px solid var(--line-soft); background: #fafbfd;
}
.tag-pill.maint { color: var(--err); border-color: #f6c5c0; background: #fdebea; }

/* Maintenance card — visible but clearly not purchasable (professional: dot, no emoji) */
.card.is-maint {
  background: linear-gradient(180deg, #fbfbfd 0%, #f7f8fb 100%);
  border-style: solid;
}
.card.is-maint::after { display: none; }
.card.is-maint .card-art img,
.card.is-maint .card-art .fb {
  filter: grayscale(1);
  opacity: .5;
}
.card.is-maint h3 { color: #9aa0b0; }
.card.is-maint .card-meta .maint-note {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 600; color: var(--muted);
  padding: 4px 9px; border-radius: 999px;
  background: #f1f2f6; border: 1px solid var(--line);
}
.card.is-maint .card-meta .maint-note::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--warn);
  animation: maintPulse 1.6s ease-in-out infinite;
}
@keyframes maintPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .35; transform: scale(.8); }
}
.card-meta {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line-soft);
  font-size: 11.5px; color: var(--muted);
}
.price { font-weight: 800; color: var(--fg); font-size: 13px; }
.card-meta .price {
  padding: 4px 10px; border-radius: 999px; font-size: 12.5px;
  background: var(--accent-soft); color: var(--accent);
  transition: background .22s, color .22s, box-shadow .22s, transform .22s var(--ease-spring);
}
.card:hover .card-meta .price {
  background: var(--accent-grad);
  color: #fff;
  box-shadow: 0 5px 14px -5px rgba(79, 70, 229, 0.6);
  transform: scale(1.05);
}
/* Free (৳0 trial) price — green, confident */
.price-free { color: var(--ok) !important; }
.card-meta .price.price-free { background: #e7f8f1; color: var(--ok); }
.card:hover .card-meta .price.price-free {
  background: linear-gradient(135deg, #059669, #10b981);
  color: #fff;
  box-shadow: 0 5px 14px -5px rgba(5, 150, 105, 0.55);
}
/* Small gradient tag next to a trial "from" price */
.trial-tag {
  display: inline-block; margin-right: 5px; vertical-align: 1.5px;
  font-size: 8.5px; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase;
  padding: 2px 6px; border-radius: 999px; line-height: 1.2;
  color: #fff; background: linear-gradient(135deg, #059669, #10b981);
  box-shadow: 0 2px 8px -2px rgba(5, 150, 105, 0.55);
}

/* Featured card — wide hero row: gradient border, aurora wash, arrow affordance */
.card.card-premium {
  grid-column: 1 / -1;
  text-align: left;
  padding: 15px 16px;
  border: 1px solid transparent;
  background:
    linear-gradient(150deg, #ffffff 0%, #f8f9ff 55%, #eef1ff 100%) padding-box,
    linear-gradient(135deg, #c7d2fe 0%, #818cf8 50%, #e0e7ff 100%) border-box;
  position: relative;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(20, 23, 44, 0.04), 0 8px 22px -10px rgba(79, 70, 229, 0.28);
}
/* aurora blobs — two soft accent glows drifting inside the hero */
.card.card-premium::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(220px 140px at 88% -10%, rgba(99, 102, 241, 0.14), transparent 65%),
    radial-gradient(180px 130px at 104% 110%, rgba(79, 70, 229, 0.1), transparent 60%);
  pointer-events: none;
  transition: opacity .3s var(--ease);
}
.card.card-premium::after { display: none; }
.card.card-premium:hover {
  box-shadow: 0 2px 4px rgba(20, 23, 44, 0.04), 0 16px 34px -12px rgba(79, 70, 229, 0.4);
}
.card.card-premium:hover::before { opacity: 1.35; }
.card-premium-row {
  display: flex; align-items: flex-start; gap: 12px; text-align: left;
  position: relative; z-index: 1;
}
.card-premium-left { flex-shrink: 0; }
.card-premium .card-art {
  width: 64px; height: 64px; margin: 0; border-radius: 16px;
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12), 0 8px 18px -8px rgba(79, 70, 229, 0.4);
}
.card-premium-main {
  flex: 1; min-width: 0; text-align: left;
  display: flex; flex-direction: column; justify-content: center;
  min-height: 64px;
}
.card-premium-main h3 {
  font-size: 14.5px; font-weight: 800; margin: 0 0 3px; letter-spacing: -0.01em;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  padding-right: 12px;
}
.card-premium-tags { line-height: 1.2; }
.card-premium-tags .tag-pill { margin: 0 3px 3px 0; font-size: 9px; padding: 2px 6px; }
.card-premium-main .card-meta { margin-top: auto; padding-top: 7px; border-top: 1px solid var(--line-soft); }
.card-premium-desc {
  margin: 9px 0 0; padding-top: 9px;
  border-top: 1px solid var(--line-soft);
  font-size: 12px; line-height: 1.45; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  position: relative; z-index: 1;
}
/* arrow affordance — invites the tap, slides on hover */
.feat-arrow {
  flex-shrink: 0; align-self: center;
  width: 30px; height: 30px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--accent); background: #fff;
  border: 1px solid #dfe3fb;
  box-shadow: 0 2px 8px -3px rgba(79, 70, 229, 0.3);
  transition: transform .28s var(--ease-spring), background .2s, color .2s, box-shadow .25s;
}
.feat-arrow svg { width: 15px; height: 15px; }
.card-premium:hover .feat-arrow {
  background: var(--accent-grad); color: #fff; border-color: transparent;
  transform: translateX(3px) scale(1.06);
  box-shadow: 0 5px 14px -5px rgba(79, 70, 229, 0.6);
}
.card-premium:active .feat-arrow { transform: translateX(5px) scale(.94); }

/* ---------- Package detail ---------- */
.back {
  display: inline-flex; align-items: center; gap: 5px;
  font: inherit; font-size: 12.5px; font-weight: 600; color: var(--muted);
  background: transparent; border: none; cursor: pointer;
  padding: 3px 0; margin-bottom: 10px;
  transition: color .15s, transform .15s;
}
.back:hover { color: var(--accent); transform: translateX(-3px); }
.app-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.app-head h2 { font-size: 16px; }
.pkg-list { display: flex; flex-direction: column; gap: 9px; }
.pkg {
  position: relative;
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  font: inherit; color: var(--fg); text-align: left; cursor: pointer;
  padding: 14px 15px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfbfe 100%);
  border: 1px solid #e3e6f2;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-card);
  transition: border-color .2s var(--ease), box-shadow .25s var(--ease), transform .2s var(--ease-spring);
  animation: fadeUp .4s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 45ms);
}
/* left accent rail — grows on hover */
.pkg::before {
  content: "";
  position: absolute; left: 0; top: 14%; bottom: 14%;
  width: 3px; border-radius: 0 3px 3px 0;
  background: var(--accent-grad);
  opacity: 0; transform: scaleY(.4);
  transition: opacity .2s, transform .25s var(--ease-spring);
}
.pkg:hover::before { opacity: 1; transform: scaleY(1); }
.pkg:hover { border-color: rgba(79, 70, 229, 0.45); box-shadow: var(--glow-sm); transform: translateY(-2px); }
.pkg:active { transform: scale(.98); }
.pkg b { font-size: 13.5px; font-weight: 700; }
.pkg .price { font-size: 14px; color: var(--accent); font-weight: 800; }
.pkg .price .price-free { color: var(--ok) !important; }
.pkg-trial::before { background: linear-gradient(135deg, #059669, #10b981); }
.pkg-blocked { opacity: .55; cursor: not-allowed; border-style: dashed; box-shadow: none; }
.pkg-blocked::before { display: none; }
.pkg-blocked:hover { border-color: var(--line); box-shadow: none; transform: none; }
.pkg-badge {
  display: inline-block; margin-left: 6px;
  padding: 2px 8px; border-radius: 999px;
  font-size: 10px; font-weight: 700;
  color: var(--muted); background: #f1f2f6; border: 1px solid var(--line);
  vertical-align: middle;
}
/* Free-trial badge on selectable package rows */
.pkg-free {
  display: inline-block; margin-left: 6px;
  padding: 2px 8px; border-radius: 999px;
  font-size: 10px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase;
  color: #fff; background: linear-gradient(135deg, #059669, #10b981);
  box-shadow: 0 2px 8px -3px rgba(5, 150, 105, 0.55);
  vertical-align: middle;
}
/* Maintenance panel icon (packages view) — replaces the old emoji */
.maint-ico {
  width: 54px; height: 54px; margin: 2px auto 10px;
  border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  color: var(--warn); background: #fff7ed;
  border: 1px solid #fed7aa;
  box-shadow: 0 6px 16px -8px rgba(217, 119, 6, 0.45);
}
.maint-ico svg { width: 24px; height: 24px; }

/* ---------- Free trial claim (buy view) ---------- */
.free-claim { margin-top: 2px; }
.free-note {
  display: flex; align-items: flex-start; gap: 9px;
  margin-top: 14px; padding: 12px 13px;
  font-size: 12.5px; font-weight: 600; color: #065f46;
  background: linear-gradient(135deg, #ecfdf5 0%, #e7f8f1 100%);
  border: 1px solid #bbe9d6;
  border-radius: var(--r-md);
  line-height: 1.45;
}
.free-dot {
  flex-shrink: 0;
  width: 8px; height: 8px; border-radius: 50%;
  margin-top: 5px;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.18);
  animation: maintPulse 1.6s ease-in-out infinite;
}
.btn-claim {
  background: linear-gradient(135deg, #059669 0%, #10b981 100%) !important;
  box-shadow: 0 8px 22px -8px rgba(5, 150, 105, 0.6) !important;
}
.btn-claim:hover {
  background: linear-gradient(135deg, #047857 0%, #059669 100%) !important;
  box-shadow: 0 10px 26px -8px rgba(5, 150, 105, 0.7) !important;
}

/* Downloads */
.dl-section { margin-top: 16px; }
.dl-title {
  font-size: 11px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 8px;
}
.dl-list { display: grid; grid-template-columns: 1fr; gap: 8px; }
.dl-item {
  display: flex; flex-direction: column;
  padding: 12px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--r-md);
  animation: fadeUp .4s var(--ease) both;
}
.dl-desc { font-size: 13px; color: var(--fg); line-height: 1.5; word-break: break-word; }
.dl-desc .muted { display: block; margin-top: 2px; font-size: 11.5px; }
.dl-actions { display: flex; gap: 8px; margin-top: 10px; }
.dl-actions .btn { flex: 1; padding: 10px 12px; font-size: 12.5px; font-weight: 700; }

/* ---------- Buy panel ---------- */
.row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-soft); font-size: 13.5px; }
.row:last-of-type { border-bottom: none; }
.row span { color: var(--muted); }
.row b { text-align: right; }
.row.total { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 12px; }
.row.total b { font-size: 17px; color: var(--accent); }

.lbl {
  display: block; margin: 12px 0 5px;
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted);
}
.lbl .req { color: var(--warn); }
.inp {
  width: 100%; font: inherit; font-size: 13.5px; color: var(--fg);
  padding: 11px 13px;
  background: #fafbfd;
  border: 1px solid var(--line); border-radius: var(--r-sm);
  outline: none;
  transition: border-color .18s, box-shadow .18s, background .18s;
}
.inp::placeholder { color: #9ca3af; }
.inp:focus { border-color: var(--accent); background: #fff; box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12); }
.hint-line { margin-top: 5px; font-size: 11.5px; color: var(--muted); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer;
  padding: 11px 18px; color: var(--fg); text-decoration: none;
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  transition: border-color .18s var(--ease), background .18s var(--ease), color .18s var(--ease), transform .12s var(--ease), box-shadow .2s var(--ease);
}
.btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px -4px rgba(79, 70, 229, 0.28);
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn:disabled:hover { transform: none; box-shadow: none; background: #fff; color: var(--fg); border-color: var(--line); }

.btn-block { width: 100%; margin-top: 12px; }

/* Primary — accent outline (soft) */
.btn-primary {
  color: var(--accent);
  background: #fff;
  border: 1px solid #c7caf7;
}
.btn-primary:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

/* Telegram — outline blue */
.btn-tg {
  color: var(--tg);
  background: #fff;
  border: 1px solid #b8ddf0;
}
.btn-tg:hover {
  background: #eaf6fc;
  border-color: var(--tg);
  color: var(--tg);
  box-shadow: 0 4px 12px -4px rgba(34, 158, 217, 0.28);
}

.btn-ghost { background: transparent; box-shadow: none; border-color: transparent; }
.btn-ghost:hover { background: var(--accent-soft); border-color: var(--accent); }

.btn-sm { padding: 7px 14px; font-size: 12px; }

/* Video — soft pink outline */
.btn-video {
  color: #db2777;
  background: #fff;
  border: 1px solid #fbcfe8;
}
.btn-video:hover {
  background: #fdf2f8;
  border-color: #db2777;
  color: #db2777;
  box-shadow: 0 4px 12px -4px rgba(219, 39, 119, 0.22);
}

/* Download — soft accent outline */
.btn-download {
  color: var(--accent);
  background: #fff;
  border: 1px solid #c7caf7;
}
.btn-download:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

/* Full-width CTA — main action, gradient + glow */
.btn-cta {
  color: #fff !important;
  background: var(--accent-grad) !important;
  border: none !important;
  border-radius: var(--r-sm) !important;
  box-shadow: var(--glow-cta);
}
.btn-cta:hover {
  background: linear-gradient(135deg, #4338ca 0%, #4f46e5 100%) !important;
  color: #fff !important;
  box-shadow: 0 10px 26px -8px rgba(79, 70, 229, 0.65);
  transform: translateY(-1px);
}
.btn-cta:active { transform: scale(.97) !important; }

/* ---------- Keys ---------- */
.keybox {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13.5px; word-break: break-all;
  padding: 14px 12px; margin-top: 12px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px dashed #c7caf7; border-radius: var(--r-sm);
  user-select: all;
}
.key-row {
  display: flex; flex-direction: column; gap: 8px;
  padding: 12px; margin-bottom: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-md);
  animation: fadeUp .4s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 40ms);
  transition: border-color .2s, box-shadow .2s;
}
.key-row:hover { border-color: #c7caf7; box-shadow: 0 4px 12px -6px rgba(79, 70, 229, 0.2); }
.key-row code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px; word-break: break-all; font-weight: 700; color: var(--fg);
}
.key-row .meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.key-row .k-app { font-size: 12px; font-weight: 600; color: var(--fg); }
.key-row .k-val { font-size: 11.5px; font-weight: 700; color: #1FAE63; }
.key-row .k-val.exp { color: #E0463C; }
.key-row .k-val.pending { color: #9C6C10; }
.key-row .k-dev { font-size: 11px; color: var(--muted); word-break: break-all; }
.key-row .k-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.btn-mini {
  flex: 0 0 auto; cursor: pointer; border-radius: 6px;
  font: inherit; font-size: 10.5px; font-weight: 700; letter-spacing: 0.03em;
  padding: 6px 11px; color: var(--accent);
  background: var(--accent-soft); border: 1px solid #dcdffb;
  transition: background .15s, color .15s;
}
.btn-mini:hover { background: var(--accent); color: #fff; }
.btn-mini.reset { color: #C10A5A; background: #FDEBEA; border-color: #F6C5C0; }
.btn-mini.reset:hover { background: #EE1876; color: #fff; border-color: transparent; }
.btn-mini.reset:disabled, .btn-mini:disabled {
  opacity: .55; cursor: default; background: #f0f1f5; color: var(--muted); border-color: var(--line-soft);
}
.key-load-more { width: 100%; margin-top: 4px; }

/* ---------- Add Money ---------- */
.fund-wrap { max-width: 420px; margin: 0 auto; }
.fund-status {
  position: fixed;
  top: calc(10px + env(safe-area-inset-top, 0px));
  left: 50%;
  transform: translateX(-50%) translateY(-12px);
  z-index: 120;
  width: min(92vw, 380px);
  display: flex; align-items: flex-start; gap: 10px;
  padding: 11px 13px; border-radius: 12px;
  opacity: 0; pointer-events: none;
  transition: opacity .3s ease, transform .3s ease;
  box-shadow: var(--shadow-lg);
}
.fund-status.show { opacity: 1; pointer-events: auto; transform: translateX(-50%) translateY(0); }
.fund-status.ok { background: #E4F9EE; border: 1px solid #B9EFD1; }
.fund-status.err { background: #FDEBEA; border: 1px solid #F6C5C0; }
.fund-status.warn { background: #FFF6E0; border: 1px solid #FBE29B; }
.fund-status .icon {
  flex-shrink: 0; width: 24px; height: 24px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; color: #fff;
}
.fund-status.ok .icon { background: #1FAE63; }
.fund-status.err .icon { background: #E0463C; }
.fund-status.warn .icon { background: #E8A93A; }
.fund-status h3 { font-size: 12.5px; font-weight: 700; margin: 0 0 2px; }
.fund-status.ok h3 { color: #137A44; }
.fund-status.err h3 { color: #B02E26; }
.fund-status.warn h3 { color: #9C6C10; }
.fund-status p { font-size: 11.5px; color: var(--muted); margin: 0; line-height: 1.4; }

.wallet-tabs {
  display: flex; flex-wrap: wrap; justify-content: center; align-items: stretch;
  gap: 8px; margin-bottom: 10px;
}
.wallet-tab {
  display: flex; align-items: center; justify-content: center;
  width: 76px; height: 76px;
  background: #fff; border: 1.5px solid var(--line); border-radius: 14px;
  padding: 8px; text-align: center; cursor: pointer;
  transition: border-color .2s var(--ease), opacity .18s, transform .2s var(--ease), box-shadow .2s var(--ease);
}
.wallet-tab:not(.off):hover { transform: translateY(-2px); box-shadow: 0 6px 14px -6px rgba(0,0,0,0.15); }
.wallet-tab:not(.off):active { transform: scale(.96); }
.wallet-tab[aria-selected="true"] {
  border-color: var(--w1, var(--accent));
  box-shadow:
    0 0 0 1.5px var(--w1, var(--accent)),
    0 6px 20px -6px var(--w1, rgba(79, 70, 229, 0.5));
}
.wallet-tab.off { opacity: .42; cursor: not-allowed; }
.wallet-tab .w-logo {
  width: 56px; height: 56px; border-radius: 10px; object-fit: contain;
  background: transparent; display: block;
}
#wBkash { --w1: var(--bkash-1); }
#wNagad { --w1: var(--nagad-1); }
#wRocket { --w1: var(--rocket-1); }

.pay-card {
  background: linear-gradient(160deg, var(--pay-c1, #EE1876), var(--pay-c2, #C10A5A));
  border-radius: 16px; padding: 16px 14px;
  color: #fff;
  box-shadow: 0 12px 28px -12px var(--pay-c2, #C10A5A);
  animation: fadeUp .4s var(--ease) both;
}
.pay-card h2 { text-align: center; font-size: 14px; font-weight: 700; margin: 0 0 10px; color: #fff; }
.pay-card input.trx-inp, input.trx-inp {
  width: 100%; padding: 12px 14px; border-radius: 10px; font-size: 14px; font-family: inherit;
  background: #fff !important; border: 2px solid rgba(255,255,255,.7);
  color: #12152b !important; caret-color: #12152b;
  text-align: center; margin-bottom: 12px; box-sizing: border-box;
  -webkit-text-fill-color: #12152b;
  transition: border-color .18s, box-shadow .18s;
}
.pay-card input.trx-inp:focus, input.trx-inp:focus {
  border-color: #fff;
  box-shadow: 0 0 0 3px rgba(255,255,255,.35);
  outline: none;
}
.pay-card input.trx-inp::placeholder, input.trx-inp::placeholder {
  color: #6b7280 !important; -webkit-text-fill-color: #6b7280; opacity: 1;
}
.pay-card input.trx-inp.err { border-color: #FFE14D; animation: shakePay .4s ease; }
@keyframes shakePay {
  20% { transform: translateX(-6px); } 40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); } 80% { transform: translateX(4px); }
}
ol.pay-steps { list-style: none; margin: 0; padding: 0; counter-reset: s; }
ol.pay-steps li {
  display: flex; gap: 10px; font-size: 12.5px; padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.16); align-items: flex-start; line-height: 1.45;
}
ol.pay-steps li:last-child { border-bottom: none; padding-bottom: 0; }
ol.pay-steps li::before {
  content: ''; flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255,255,255,.85); margin-top: 6px;
}
.pay-num-hl {
  font-weight: 800; color: #FFE14D; background: rgba(0,0,0,.22);
  padding: 2px 8px; border-radius: 6px; display: inline-block;
  font-variant-numeric: tabular-nums;
}
.pay-copy {
  background: rgba(0,0,0,.28); color: #fff; border: 1px solid rgba(255,255,255,.3);
  font-size: 10.5px; padding: 3px 9px; border-radius: 6px; margin-left: 5px;
  cursor: pointer; font-family: inherit; font-weight: 600;
  transition: background .15s, transform .12s;
}
.pay-copy:hover { background: rgba(0,0,0,.45); }
.pay-copy:active { transform: scale(.94); }
button.pay-verify {
  width: 100%; padding: 13px; border: none; border-radius: 10px; font-size: 15px; font-weight: 800;
  color: #fff; background: var(--pay-c2, #C10A5A); cursor: pointer; font-family: inherit; margin-top: 10px;
  display: flex; align-items: center; justify-content: center; gap: 7px;
  transition: filter .18s, transform .12s;
}
button.pay-verify:hover { filter: brightness(1.08); }
button.pay-verify:active { transform: scale(.98); }
button.pay-verify:disabled { opacity: .7; cursor: default; }
.pay-spin {
  width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff;
  border-radius: 50%; animation: spinPay .7s linear infinite;
}
@keyframes spinPay { to { transform: rotate(360deg); } }

.pay-num {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  margin-top: 8px; padding: 12px 13px;
  background: #fafbfd; border: 1px solid var(--line); border-radius: var(--r-sm);
  font-size: 13.5px;
}
.pay-num span { color: var(--muted); font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.pay-num b { font-family: ui-monospace, monospace; font-size: 14px; letter-spacing: 0.03em; }

/* ---------- Files (new layout) ---------- */
.file-grid { display: grid; grid-template-columns: 1fr; gap: 10px; margin-top: 10px; }

.file-card {
  display: flex; flex-direction: column;
  padding: 14px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: border-color .2s var(--ease), box-shadow .25s var(--ease), transform .25s var(--ease);
  animation: fadeUp .4s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 55ms);
}
.file-card:hover {
  border-color: var(--accent);
  box-shadow: 0 10px 24px -10px rgba(79, 70, 229, 0.28);
  transform: translateY(-2px);
}

.file-top {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 12px;
}
.file-logo {
  width: 52px; height: 52px; border-radius: 12px; flex: 0 0 auto;
  overflow: hidden; border: 1px solid var(--line-soft);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; color: #fff; font-size: 20px;
  background-image: var(--accent-grad);
  box-shadow: 0 4px 10px -4px rgba(79, 70, 229, 0.35);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.file-card:hover .file-logo {
  transform: scale(1.06);
  box-shadow: 0 6px 14px -4px rgba(79, 70, 229, 0.45);
}
.file-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }

.file-head-text { min-width: 0; flex: 1; }
.file-head-text b {
  font-size: 14.5px; font-weight: 800; display: block;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--fg);
}
.file-ver {
  display: inline-block; margin-top: 4px;
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.04em;
  color: var(--muted);
  padding: 2px 8px;
  background: #f4f5fa;
  border-radius: 6px;
}

.file-desc {
  font-size: 12.5px; color: var(--muted); line-height: 1.55;
  word-break: break-word;
  margin-bottom: 12px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}

.file-actions { display: flex; gap: 8px; }
.file-actions .btn {
  flex: 1; padding: 11px 12px; font-size: 12.5px; font-weight: 700;
}

/* ---------- Account (new layout) ---------- */
.acc-hero {
  display: flex; align-items: center; gap: 12px;
  padding: 4px 0 14px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 14px;
  animation: fadeSlide .4s var(--ease) both;
}
.acc-avatar {
  width: 56px; height: 56px; object-fit: cover; border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--line), 0 4px 12px -4px rgba(20, 23, 44, 0.15);
  transition: transform .25s var(--ease);
}
.acc-avatar:hover { transform: scale(1.05); }
.acc-meta { min-width: 0; }
.acc-meta h2 { font-size: 16px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acc-tg { color: var(--accent); font-size: 12.5px; font-weight: 600; margin-top: 2px; }
.acc-id { color: var(--muted); font-size: 10.5px; margin-top: 2px; word-break: break-all; }

.bal-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  padding: 16px;
  background: linear-gradient(135deg, #fafbff 0%, #f0f2ff 100%);
  border: 1px solid #e0e4ff;
  border-radius: 14px;
  margin-bottom: 14px;
  animation: fadeSlide .4s var(--ease) both;
  animation-delay: .06s;
  transition: box-shadow .25s var(--ease);
}
.bal-row:hover { box-shadow: 0 6px 16px -8px rgba(79, 70, 229, 0.3); }
.bal-info { min-width: 0; }
.bal-label {
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--muted);
  margin-bottom: 4px;
}
.bal-value {
  font-size: 24px; font-weight: 800; color: var(--accent);
  letter-spacing: -0.02em; line-height: 1;
  transition: color .2s;
}
.bal-row .btn { flex-shrink: 0; padding: 10px 16px; font-size: 12.5px; }

.acc-actions { display: flex; flex-direction: column; gap: 8px; }
.acc-actions .btn {
  justify-content: flex-start;
  padding: 13px 14px;
  animation: fadeSlide .4s var(--ease) both;
}
.acc-actions .btn:nth-child(1) { animation-delay: .12s; }
.acc-actions .btn:nth-child(2) { animation-delay: .18s; }
.acc-actions .btn:nth-child(3) { animation-delay: .24s; }
.acc-actions .btn svg {
  width: 16px; height: 16px; flex-shrink: 0;
  color: var(--muted);
  transition: color .18s;
}
.acc-actions .btn:hover svg { color: var(--accent); }
.acc-actions .btn span { flex: 1; text-align: left; }
.acc-actions .btn svg:last-child { color: #c5c8d4; }
.acc-actions .btn:hover svg:last-child { color: var(--accent); transform: translateX(2px); }

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- Login ---------- */
.login-ico {
  width: 64px; height: 64px; margin: 0 auto 14px;
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #eef0ff 0%, #e0e4ff 100%);
  border: 1px solid #dcdffb;
  box-shadow: 0 8px 24px -10px rgba(79, 70, 229, 0.4);
  color: var(--accent);
  animation: loginIcoPop .5s cubic-bezier(.2,.9,.3,1.2) both;
}
.login-ico svg { width: 32px; height: 32px; }
@keyframes loginIcoPop {
  from { opacity: 0; transform: scale(.7) rotate(-8deg); }
  to { opacity: 1; transform: scale(1) rotate(0); }
}

.status { color: var(--muted); font-size: 12.5px; margin-top: 12px; }
.status.ok-text { color: var(--ok); font-weight: 600; }
.chk-row {
  display: flex; align-items: center; gap: 8px;
  margin-top: 10px; font-size: 12.5px; font-weight: 600; color: var(--fg);
  cursor: pointer; user-select: none;
}
.chk-row input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; flex: 0 0 auto; }
.linklike {
  display: inline-block; margin-top: 10px;
  background: none; border: none; cursor: pointer; font: inherit;
  font-size: 12.5px; font-weight: 600; color: var(--accent);
  padding: 2px 4px;
  transition: color .15s;
}
.linklike:hover { text-decoration: underline; }
.divider {
  display: flex; align-items: center; gap: 10px;
  margin: 14px 0 10px; color: var(--muted);
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
}
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line-soft); }

/* Buy window — wallet vs instant */
.pay-step-title {
  display: flex; align-items: center; gap: 9px;
  font-size: 15px; font-weight: 800; color: var(--fg);
  margin: 14px 0 10px;
}
.pay-step-num {
  width: 24px; height: 24px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--accent); color: #fff; font-size: 12px; font-weight: 800;
  flex-shrink: 0;
}
.pay-choice { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pay-choice-card {
  position: relative;
  display: flex; flex-direction: column;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 0; overflow: hidden;
  cursor: pointer; font: inherit;
  transition: border-color .2s var(--ease), transform .15s var(--ease), box-shadow .2s var(--ease);
}
.pay-choice-card:active:not(.dis) { transform: scale(.98); }
.pay-choice-card.on {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}
.pay-choice-card.dis { opacity: .55; }
.pay-choice-card .pcc-check {
  position: absolute; top: 0; left: 0;
  width: 20px; height: 20px;
  background: var(--accent);
  border-bottom-right-radius: 9px;
  opacity: 0;
  transition: opacity .2s;
}
.pay-choice-card.on .pcc-check { opacity: 1; }
.pay-choice-card.on .pcc-check::after {
  content: "✓"; color: #fff; font-size: 11px; font-weight: 900;
  position: absolute; top: 1px; left: 4px;
}
.pcc-visual {
  flex: 1; min-height: 76px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 5px;
  padding: 12px 8px 10px;
}
.pcc-brand { width: 34px; height: 34px; border-radius: 10px; object-fit: cover; }
.pcc-brand-txt { font-size: 12px; font-weight: 800; color: var(--accent); }
.pcc-instant { flex-direction: row; flex-wrap: wrap; gap: 5px 7px; }
.pcc-instant img { width: 24px; height: 24px; object-fit: contain; border-radius: 6px; background: #fff; }
.pcc-inst-label { width: 100%; text-align: center; font-size: 12px; font-weight: 800; color: var(--fg); margin-top: 2px; }
.pcc-foot {
  display: block; width: 100%; text-align: center;
  font-size: 11.5px; font-weight: 700; color: var(--muted);
  background: #f4f5fa; padding: 8px;
  transition: background .2s, color .2s;
}
.pay-choice-card.on .pcc-foot { background: var(--accent-soft); color: var(--accent); }
.pay-meta { margin: 12px 0 4px; display: flex; flex-direction: column; gap: 6px; }
.pay-meta-row { font-size: 12.5px; color: var(--muted); font-weight: 600; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.pay-meta-row b { color: var(--fg); font-weight: 800; }
.pay-meta-warn {
  font-size: 12px; font-weight: 700; color: #c2410c;
  background: #fff7ed; border: 1px solid #fed7aa;
  border-radius: 8px; padding: 7px 9px;
}
.pay-cta { margin-top: 12px !important; border-radius: 10px !important; padding: 13px !important; font-size: 15px !important; }

/* Account sub panels */
.acc-sub h3 { font-size: 14.5px; margin-top: 4px; }
.acc-sub .status { margin-top: 8px; }
.loading { color: var(--muted); font-size: 12.5px; padding: 22px 0; text-align: center; }
.empty {
  color: var(--muted); text-align: center; font-size: 12.5px;
  padding: 24px 12px;
  border: 1px dashed var(--line); border-radius: var(--r-md);
  grid-column: 1 / -1;
}

/* ---------- Bottom nav ---------- */
.bottom-nav {
  flex: 0 0 auto; z-index: 50;
  display: flex; width: 100%; max-width: 1080px; margin: 0 auto;
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-top: 1px solid rgba(230, 232, 240, 0.9);
  padding-bottom: env(safe-area-inset-bottom);
}
.nav-item {
  flex: 1; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font: inherit; font-size: 10px; font-weight: 600; letter-spacing: 0.02em;
  color: var(--muted); background: transparent; border: none;
  padding: 8px 0 7px;
  position: relative;
  transition: color .2s var(--ease);
}
.nav-item svg { width: 20px; height: 20px; transition: transform .2s var(--ease); }
.nav-item.active { color: var(--accent); }
/* active pill — soft indigo glow under the icon */
.nav-item.active::before {
  content: "";
  position: absolute; top: 4px;
  width: 34px; height: 26px; border-radius: 999px;
  background: var(--accent-soft);
  z-index: -1;
  animation: navPillIn .28s var(--ease-spring) both;
}
@keyframes navPillIn {
  from { opacity: 0; transform: scaleX(.4); }
  to { opacity: 1; transform: scaleX(1); }
}
.nav-item.active svg { animation: navPop .35s var(--ease-spring); }
@keyframes navPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.18); }
  100% { transform: scale(1.06); }
}
.nav-item:active svg { transform: scale(.9); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%;
  top: calc(12px + env(safe-area-inset-top, 0px));
  transform: translateX(-50%) translateY(-10px) scale(.95);
  z-index: 130; max-width: min(92vw, 400px);
  font-size: 12.5px; font-weight: 600; text-align: center;
  padding: 11px 16px; color: #fff;
  background: rgba(20, 23, 44, 0.94);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none;
  transition: opacity .22s ease, transform .28s cubic-bezier(.2,.9,.3,1.2);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
.toast.ok { background: #065f46; }
.toast.err { background: #7f1d1d; }

/* ---------- Notice modal (premium) ---------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 18px;
  background: rgba(20, 23, 44, 0.5);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  animation: noticeFade .25s ease both;
}
@keyframes noticeFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.notice-shell {
  position: relative;
  width: 100%; max-width: 400px;
  animation: noticePop .35s cubic-bezier(.2,.9,.3,1.1) both;
}
@keyframes noticePop {
  from { opacity: 0; transform: translateY(12px) scale(.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.notice-card {
  position: relative;
  max-height: 78vh; overflow-y: auto;
  background: #fff;
  border-radius: 20px;
  border: 1px solid var(--line);
  box-shadow: 0 24px 60px -16px rgba(20, 23, 44, 0.32), 0 4px 14px rgba(20, 23, 44, 0.08);
  padding: 22px 20px 20px;
  scrollbar-width: thin;
}
.notice-card::-webkit-scrollbar { width: 5px; }
.notice-card::-webkit-scrollbar-thumb { background: #d5d8e4; border-radius: 4px; }

.notice-card::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, #4f46e5 0%, #6366f1 50%, #8b5cf6 100%);
  border-radius: 20px 20px 0 0;
}

.notice-ico {
  width: 48px; height: 48px; margin: 4px auto 12px;
  border-radius: 14px; display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  background: linear-gradient(135deg, #eef0ff 0%, #e0e4ff 100%);
  border: 1px solid #dcdffb;
  box-shadow: 0 4px 12px -4px rgba(79, 70, 229, 0.18);
}
.notice-card h2 {
  font-size: 17px; font-weight: 800; text-align: center;
  letter-spacing: -0.01em; margin: 0 0 4px;
}
.notice-subtitle {
  text-align: center; font-size: 12px; color: var(--muted);
  margin-bottom: 12px; font-weight: 500;
}

.notice-img {
  display: block; width: 100%; max-height: 34vh;
  object-fit: contain;
  margin: 0 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fafbfd;
}

.notice-body {
  margin-top: 4px;
  font-size: 13.5px; line-height: 1.6;
  color: #3a3f55;
  white-space: pre-wrap; word-break: break-word;
  max-height: 34vh; overflow-y: auto;
  text-align: center;
  scrollbar-width: thin;
}
.notice-body::-webkit-scrollbar { width: 4px; }
.notice-body::-webkit-scrollbar-thumb { background: #d5d8e4; border-radius: 4px; }

.notice-btns {
  display: flex; flex-direction: column; gap: 8px;
  margin-top: 16px;
}
.notice-btns .btn { margin-top: 0; }

.notice-dont {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin-top: 16px; padding-top: 14px;
  border-top: 1px solid var(--line-soft);
  cursor: pointer; user-select: none;
  font-size: 12.5px; color: var(--muted); font-weight: 600;
}
.notice-dont input {
  width: 15px; height: 15px;
  accent-color: var(--accent); cursor: pointer;
}

.notice-close {
  display: flex;
  align-items: center; justify-content: center;
  width: 40px; height: 40px;
  margin: 14px auto 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(20, 23, 44, 0.12);
  color: var(--fg);
  cursor: pointer;
  box-shadow: 0 8px 22px -6px rgba(20, 23, 44, 0.28), 0 2px 6px rgba(20, 23, 44, 0.1);
  transition: transform .2s var(--ease), background .18s, color .18s, box-shadow .25s;
  -webkit-tap-highlight-color: transparent;
}
.notice-close:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: scale(1.08);
  box-shadow: 0 10px 26px -6px rgba(79, 70, 229, 0.5);
}
.notice-close:active { transform: scale(.94); }
.notice-close svg {
  width: 18px; height: 18px;
  stroke-width: 2.6;
}

/* ---------- Support sheet ---------- */
.support-backdrop {
  position: fixed; inset: 0; z-index: 190;
  background: rgba(20, 23, 44, 0.4);
  animation: noticeFade .22s ease both;
}
.support-sheet {
  position: fixed; z-index: 195;
  left: 50%; transform: translate(-50%, 0);
  bottom: 0; width: 100%; max-width: 460px;
  background: #fff;
  border-radius: 18px 18px 0 0;
  border: 1px solid var(--line); border-bottom: none;
  box-shadow: var(--shadow-lg);
  padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
  animation: sheetUp .35s cubic-bezier(.2,.9,.3,1.05) both;
}
@keyframes sheetUp {
  from { transform: translate(-50%, 40px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}
.support-grab { width: 38px; height: 4px; border-radius: 4px; background: var(--line); margin: 0 auto 10px; }
.support-sheet h2 { font-size: 15px; text-align: center; margin-bottom: 10px; }
.support-list { display: flex; flex-direction: column; gap: 8px; }
.support-item {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 13px; text-decoration: none; color: var(--fg);
  background: #fafbfd; border: 1px solid var(--line); border-radius: var(--r-sm);
  transition: border-color .18s, background .18s, transform .15s;
  font-weight: 700; font-size: 13.5px;
}
.support-item:hover { border-color: var(--accent); background: var(--accent-soft); transform: translateX(2px); }
.support-ico {
  width: 30px; height: 30px; border-radius: 50%; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 13px;
  background: var(--accent);
}
.support-ico svg { width: 16px; height: 16px; }
.support-item .sup-name { flex: 1; }
.support-item .sup-arrow { color: var(--muted); font-weight: 800; transition: transform .18s; }
.support-item:hover .sup-arrow { transform: translateX(2px); color: var(--accent); }

/* ---------- Method cards (Add Money) ---------- */
.fund-entry { padding-bottom: 16px; max-width: 420px; margin: 0 auto; }
.fund-hero { margin-bottom: 10px; }
.fund-hero h2 { margin: 0 0 2px; font-size: 18px; font-weight: 800; letter-spacing: -0.02em; }
.fund-sec-label {
  font-size: 11px; font-weight: 800; letter-spacing: 0.03em;
  text-transform: uppercase; color: var(--muted);
  margin: 12px 0 7px;
}
.amt-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 15px 11px;
  transition: border-color .2s, box-shadow .2s;
}
.amt-card:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}
.amt-card-label {
  font-size: 11px; font-weight: 800; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 5px;
}
.amt-box { display: flex; align-items: center; gap: 5px; background: transparent; border: none; padding: 0; }
.amt-prefix { font-size: 25px; font-weight: 800; color: var(--accent); line-height: 1; }
.amt-inp {
  border: none !important; background: transparent !important;
  box-shadow: none !important; font-size: 28px !important;
  font-weight: 800 !important; padding: 3px 0 !important;
  flex: 1; min-width: 0; color: var(--fg) !important;
  letter-spacing: -0.02em;
}
.amt-inp:focus { outline: none; }
.amt-inp::placeholder { color: #c5c8d4; font-weight: 700; }
.amt-hints { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.amt-chip {
  border: 1px solid var(--line); background: #fff;
  border-radius: 7px; padding: 5px 11px;
  font: inherit; font-size: 12px; font-weight: 700;
  color: var(--fg); cursor: pointer;
  transition: border-color .15s, background .15s, transform .12s;
}
.amt-chip:hover { border-color: var(--accent); color: var(--accent); }
.amt-chip:active { background: var(--accent-soft); border-color: var(--accent); transform: scale(.95); }
.method-cards { display: flex; flex-direction: column; gap: 9px; margin-top: 0; }
.method-cards-row { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.method-card {
  display: flex; align-items: center; gap: 11px;
  width: 100%; text-align: left; cursor: pointer;
  padding: 13px;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  font: inherit;
  transition: border-color .2s var(--ease), background .2s var(--ease), transform .15s var(--ease);
  position: relative;
}
.method-card-lg {
  flex-direction: column; align-items: center; text-align: center;
  gap: 5px; padding: 13px 9px 11px;
}
.method-card:hover:not(:disabled):not(.soon) { transform: translateY(-2px); box-shadow: 0 6px 14px -6px rgba(79,70,229,0.2); }
.method-card:active:not(:disabled) { transform: scale(.985); }
.method-card.on {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}
.method-card.soon { opacity: .6; cursor: not-allowed; }
.method-card .pcc-check {
  position: absolute; top: 0; left: 0;
  width: 18px; height: 18px;
  background: var(--accent);
  border-bottom-right-radius: 8px;
  opacity: 0;
  transition: opacity .2s;
}
.method-card.on .pcc-check { opacity: 1; }
.method-card.on .pcc-check::after {
  content: "✓"; color: #fff; font-size: 10px; font-weight: 900;
  position: absolute; top: 1px; left: 4px;
}
.mc-logos {
  display: flex; align-items: center; justify-content: center;
  gap: 5px; min-height: 32px; margin-bottom: 2px;
}
.mc-logos img { width: 26px; height: 26px; object-fit: contain; border-radius: 7px; background: #fff; }
.mc-logos.single img { width: 30px; height: 30px; }
.method-name { font-size: 12.5px; font-weight: 800; color: var(--fg); }
.method-sub { font-size: 11px; font-weight: 600; color: var(--muted); }
.method-badge {
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 3px 7px; border-radius: 6px;
  background: var(--accent);
  color: #fff; flex-shrink: 0; margin-top: 2px;
}
.method-badge.muted { background: #e8eaf0; color: var(--muted); }

/* Checkout compact */
.ck-compact .wallet-tabs { gap: 7px; margin-bottom: 7px; }
.ck-compact .wallet-tab { width: 66px; height: 66px; border-radius: 12px; padding: 7px; }
.ck-compact .wallet-tab .w-logo { width: 44px; height: 44px; }
.ck-compact .pay-card { padding: 11px 13px; border-radius: 12px; margin-top: 0; }
.ck-compact .pay-card h2 { font-size: 13px; margin: 0 0 7px; }
.ck-compact .trx-inp { padding: 11px 13px; font-size: 14px; }
.ck-compact ol.pay-steps { margin: 7px 0 0; gap: 5px; }
.ck-compact ol.pay-steps li { font-size: 11.5px; line-height: 1.35; padding-left: 0; }
.ck-compact button.pay-verify { margin-top: 9px; padding: 12px; border-radius: 10px; font-size: 14px; }

/* Checkout page */
.ck-page { max-width: 400px; margin: 0 auto; padding: 10px 12px 32px; }
.ck-back {
  display: inline-flex; align-items: center; gap: 5px;
  border: none; background: transparent; color: var(--muted);
  font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer;
  padding: 3px 0 9px; margin: 0;
  transition: color .15s, transform .15s;
}
.ck-back svg { width: 16px; height: 16px; flex-shrink: 0; }
.ck-back:hover { color: var(--accent); transform: translateX(-2px); }
.ck-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 13px; }
.ck-row span { color: var(--muted); }
.ck-row b { color: var(--fg); font-weight: 700; }
.ck-amount { color: var(--accent) !important; font-size: 16.5px; }
.ck-sec-title {
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--muted); margin: 0 0 7px;
}
.main.ck-main { padding: 0; min-height: 100vh; }

/* Checkout — compact order summary card */
.ck-order-card {
  background: #fff;
  border: 1px solid #dfe3f2;
  border-radius: 14px;
  padding: 9px 12px 5px;
  margin-bottom: 10px;
  box-shadow: 0 1px 2px rgba(20, 23, 44, 0.04), 0 8px 20px -12px rgba(79, 70, 229, 0.25);
  animation: fadeUp .35s var(--ease) both;
}
.ck-order-head {
  display: flex; align-items: center; gap: 7px;
  padding-bottom: 6px; margin-bottom: 2px;
  border-bottom: 1px dashed var(--line);
}
.ck-order-ico {
  width: 24px; height: 24px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 12px; border-radius: 7px;
  background: var(--accent-soft); border: 1px solid #dcdffb;
}
.ck-order-title {
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--muted);
}
.ck-order-body .ck-row { padding: 5.5px 0; font-size: 12.5px; }
.ck-order-body .ck-row b {
  max-width: 62%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ck-row-total {
  margin-top: 2px;
  border-top: 1px dashed var(--line);
  padding-top: 7px !important;
  padding-bottom: 7px !important;
}
.ck-row-total span { font-weight: 700; color: var(--fg); }

/* ---------- Skeleton ---------- */
@keyframes skShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.sk {
  background: linear-gradient(100deg, #e7e9f4 0%, #eef0fa 38%, #f8f9ff 50%, #eef0fa 62%, #e7e9f4 100%);
  background-size: 220% 100%;
  animation: skShimmer 1.6s ease-in-out infinite;
  border-radius: 8px;
  pointer-events: none;
  user-select: none;
}
.sk-line { height: 11px; margin: 5px 0; }
.sk-line.lg { height: 15px; }
.sk-line.sm { height: 9px; width: 55%; }
.sk-circle { border-radius: 50%; }
.boot-shell { animation: fadeUp .35s var(--ease) both; }
.boot-brand {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  margin: 8px 0 16px;
}
.boot-logo {
  width: 56px; height: 56px; border-radius: 50%; overflow: hidden;
  background: #fff; border: 1px solid var(--line);
  animation: bootBreath 1.9s ease-in-out infinite;
}
.boot-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.boot-name {
  font-size: 17px; font-weight: 800; letter-spacing: .4px; line-height: 1;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.boot-tag { font-size: 9px; font-weight: 700; letter-spacing: 2.4px; color: var(--muted); }
@keyframes bootBreath {
  0%, 100% { box-shadow: 0 0 0 1px rgba(79, 70, 229, .16), 0 6px 16px -8px rgba(79, 70, 229, .38); }
  50% { box-shadow: 0 0 0 1px rgba(79, 70, 229, .34), 0 12px 26px -8px rgba(79, 70, 229, .55); }
}
.sk-banner {
  position: relative; height: 150px; border-radius: var(--r-md);
  margin-bottom: 12px; border: 1px solid var(--line); overflow: hidden;
}
.sk-banner-hero {
  background: linear-gradient(135deg, #eef0ff 0%, #ffffff 52%, #f4f1ff 100%);
  border-color: rgba(79, 70, 229, .22);
  box-shadow: var(--glow-sm);
}
.sk-banner-in {
  position: absolute; inset: 0; padding: 16px;
  display: flex; flex-direction: column; justify-content: center;
}
.sk-cta {
  width: 118px; height: 34px; border-radius: 11px; margin-top: 13px;
  background: var(--accent-grad);
  box-shadow: var(--glow-cta);
  animation: skPulse 1.4s ease-in-out infinite;
}
.sk-filters { display: flex; gap: 6px; margin: 12px 0; overflow: hidden; }
.sk-chip { width: 58px; height: 28px; border-radius: 8px; flex-shrink: 0; }
.sk-chip.is-on {
  background: linear-gradient(135deg, #eef0ff 0%, #e5e8ff 100%);
  box-shadow: inset 0 0 0 1px rgba(79, 70, 229, .26);
}
.sk-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 720px) { .sk-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1020px) { .sk-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.sk-card {
  position: relative;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--r-md); padding: 12px;
  min-height: 140px;
  box-shadow: var(--shadow-card);
  animation: fadeUp .45s var(--ease) both;
}
.sk-card:nth-child(2) { animation-delay: .04s; }
.sk-card:nth-child(3) { animation-delay: .08s; }
.sk-card:nth-child(4) { animation-delay: .12s; }
.sk-card:nth-child(5) { animation-delay: .16s; }
.sk-card:nth-child(6) { animation-delay: .2s; }
.sk-card .sk-thumb { width: 100%; aspect-ratio: 1.15; border-radius: 10px; margin-bottom: 9px; }
/* Wide featured placeholder — matches the featured product card layout */
.sk-card-feat {
  grid-column: 1 / -1;
  display: grid; grid-template-columns: 76px 1fr; gap: 11px; align-items: start;
  min-height: 100px; padding: 13px;
  background: linear-gradient(135deg, #fdfdff 0%, #f6f7fd 100%);
  border-color: rgba(99, 102, 241, .18);
}
.sk-card-feat .sk-thumb { width: 76px; height: 76px; aspect-ratio: auto; margin: 0; border-radius: 12px; }
.sk-key-card, .sk-file-card, .sk-acc-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: 12px; padding: 13px; margin-bottom: 9px;
  box-shadow: var(--shadow-sm);
}
.sk-row { display: flex; gap: 11px; align-items: center; }
.sk-avatar { width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0; }
.sk-fund-amt { height: 48px; border-radius: 12px; margin-bottom: 12px; }
.sk-wallet-row { display: flex; gap: 9px; justify-content: center; flex-wrap: wrap; margin: 10px 0; }
.sk-wallet { width: 88px; height: 66px; border-radius: 12px; }
.sk-pulse-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  animation: skPulse 1.1s ease-in-out infinite;
  display: inline-block; margin-right: 7px; vertical-align: middle;
}
@keyframes skPulse {
  0%, 100% { opacity: .35; transform: scale(.85); }
  50% { opacity: 1; transform: scale(1.15); }
}
.sk-status {
  display: flex; align-items: center; justify-content: center;
  gap: 5px; margin: 7px 0 12px;
  font-size: 12px; font-weight: 600; color: var(--muted);
}

/* ---------- Beta build (injected by /beta endpoint) ---------- */
.beta-chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3.5px 8px; border-radius: 999px;
  font-size: 9px; font-weight: 800; letter-spacing: 1.2px;
  color: #fff; background: var(--accent-grad);
  box-shadow: 0 4px 12px -4px rgba(79, 70, 229, .55);
  white-space: nowrap; flex-shrink: 0;
}
.beta-dot {
  width: 5px; height: 5px; border-radius: 50%; background: #fff;
  animation: skPulse 1.1s ease-in-out infinite;
}
@media (max-width: 359px) { .beta-chip { display: none; } }

/* ---------- Animations ---------- */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-view { animation: fadeUp .3s var(--ease) both; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Desktop ---------- */
@media (min-width: 560px) {
  .grid { grid-template-columns: repeat(2, 1fr); gap: 11px; }
  h2 { font-size: 18px; }
  .file-grid { grid-template-columns: repeat(2, 1fr); }
  .dl-list { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 860px) {
  .main { padding-top: 20px; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .card.card-premium { grid-column: span 2; }
}
@media (min-width: 1180px) {
  .grid { grid-template-columns: repeat(4, 1fr); }
  .file-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1440px) {
  .grid { grid-template-columns: repeat(5, 1fr); }
}
/* ---------- Coupon box (buy flow only) ---------- */
.coupon-box {
  margin-top: 14px;
  padding: 11px 12px;
  border: 1px dashed var(--line);
  border-radius: var(--r-md, 12px);
  background: #fafbfd;
}
.coupon-box.applied {
  border-style: solid;
  border-color: rgba(5, 150, 105, 0.35);
  background: #ecfdf5;
}
.coupon-head {
  font-size: 11px; font-weight: 800; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--muted);
  margin-bottom: 8px;
}
.coupon-row { display: flex; gap: 8px; align-items: stretch; }
.coupon-inp {
  flex: 1; min-width: 0;
  text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600;
}
.coupon-apply {
  font: inherit; font-size: 13px; font-weight: 700;
  color: #fff; background: var(--accent);
  border: none; border-radius: var(--r-sm, 10px);
  padding: 0 16px; cursor: pointer;
  transition: background .18s, transform .12s;
  white-space: nowrap;
}
.coupon-apply:hover { background: var(--accent-2); }
.coupon-apply:active { transform: scale(.97); }
.coupon-apply:disabled { opacity: .6; cursor: wait; }
.coupon-status {
  margin-top: 6px; font-size: 11.5px; color: var(--muted);
  min-height: 0; display: none;
}
.coupon-status.show-err { display: block; color: var(--err); font-weight: 600; }
.coupon-applied-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.coupon-chip {
  font-size: 12.5px; color: var(--ok);
  background: #fff; border: 1px solid rgba(5, 150, 105, 0.3);
  border-radius: 999px; padding: 4px 10px; font-weight: 600;
}
.coupon-chip b { font-weight: 800; letter-spacing: 0.03em; }
.coupon-save {
  font-size: 12.5px; font-weight: 800; color: var(--ok);
}
.coupon-remove {
  margin-left: auto;
  width: 26px; height: 26px; border-radius: 8px;
  border: 1px solid var(--line); background: #fff;
  color: var(--muted); font-size: 12px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: color .15s, border-color .15s;
}
.coupon-remove:hover { color: var(--err); border-color: var(--err); }
.coupon-ok-line {
  margin-top: 10px; font-size: 12.5px; font-weight: 600; color: var(--ok);
  background: #ecfdf5; border: 1px solid rgba(5, 150, 105, 0.3);
  border-radius: 10px; padding: 8px 11px;
}
.price-was {
  text-decoration: line-through;
  color: #9ca3af;
  opacity: 1;
  font-weight: 600;
  font-size: 13px;
  margin-right: 6px;
}
.price-now {
  font-weight: 800;
  color: var(--fg);
}


/* Currency: primary vs reference */
.price-main { font-weight: 700; }
.price-ref { font-size: 0.82em; font-weight: 500; opacity: 0.55; white-space: nowrap; }
.price-now .price-ref, .price .price-ref { opacity: 0.5; }


/* —— Keys manage (public shop) —— */
.keys-panel h2 { margin-bottom: 8px; }
.keys-stats { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; }
.ks-pill {
  font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 999px;
  background: rgba(0,0,0,0.04); color: var(--muted);
}
.ks-pill.ok { background: rgba(31,174,99,0.12); color: #0d8a4a; }
.ks-pill.warn { background: rgba(245,158,11,0.14); color: #b45309; }
.ks-pill.bad { background: rgba(224,70,60,0.12); color: #c0362e; }
.keys-toolbar { display: flex; flex-direction: column; gap: 8px; }
.keys-search { width: 100%; }
.keys-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  border: 1px solid var(--border, #e5e7eb); background: #fff; color: var(--muted);
  font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 999px; cursor: pointer;
}
.chip.on { background: var(--accent, #4f46e5); color: #fff; border-color: transparent; }
.key-row { display: flex; flex-direction: column; align-items: stretch; gap: 0; padding: 0; overflow: hidden; }
.key-main {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 8px;
  width: 100%; text-align: left; background: transparent; border: 0; padding: 12px 12px 10px;
  cursor: pointer; color: inherit; font: inherit;
}
.key-row .k-chev { color: var(--muted); font-size: 14px; padding-top: 2px; flex-shrink: 0; }
.key-detail {
  padding: 0 12px 12px; border-top: 1px solid rgba(0,0,0,0.05);
  animation: keyOpen 0.15s ease;
}
@keyframes keyOpen { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.k-badge {
  display: inline-block; font-size: 10px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.04em; padding: 2px 6px; border-radius: 6px; margin-left: 6px;
  vertical-align: middle;
}
.k-badge--ok { background: rgba(31,174,99,0.15); color: #0d8a4a; }
.k-badge--warn { background: rgba(245,158,11,0.18); color: #b45309; }
.k-badge--bad { background: rgba(224,70,60,0.15); color: #c0362e; }
.k-badge--exp { background: rgba(0,0,0,0.06); color: #6b7280; }
.k-badge--muted { background: rgba(0,0,0,0.05); color: #6b7280; }
.btn-mini.act { color: #3730a3; background: #eef2ff; border-color: #c7d2fe; }
.btn-mini.act.warn { color: #b45309; background: #fffbeb; border-color: #fde68a; }
.btn-mini.act.danger { color: #b91c1c; background: #fef2f2; border-color: #fecaca; }
.btn-mini.act:hover { filter: brightness(0.97); }
.k-detail-note { margin-top: 8px; line-height: 1.35; }
.wallet-tx-list { display: flex; flex-direction: column; gap: 6px; }
.wtx-row {
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
  padding: 8px 10px; border-radius: 10px; background: rgba(0,0,0,0.03); font-size: 12.5px;
}
.wtx-desc { color: var(--fg); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wtx-amt { font-weight: 700; flex-shrink: 0; }
.wtx-amt.plus { color: #0d8a4a; }
.wtx-amt.minus { color: #c0362e; }
@media (max-width: 480px) {
  .key-main { padding: 11px 10px 9px; }
  .chip { padding: 5px 10px; font-size: 11.5px; }
}

/* Promo card + fund activity */
.promo-card {
  margin: 14px 0;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(79,70,229,0.22);
  background: linear-gradient(145deg, rgba(79,70,229,0.08), rgba(255,255,255,0.03));
}
.promo-card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
.promo-card-label { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.promo-code {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  margin: 4px 0 12px;
  color: var(--fg);
}
.promo-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}
.promo-stat {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(0,0,0,0.04);
  text-align: center;
}
.ps-val { display: block; font-size: 1.15rem; font-weight: 800; color: var(--fg); }
.ps-lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.promo-card-hint { font-size: 12px; color: var(--muted); line-height: 1.4; }

.fund-tx-section { margin-top: 22px; padding-top: 16px; border-top: 1px solid rgba(0,0,0,0.06); }
.fund-tx-head { font-size: 13px; font-weight: 700; margin-bottom: 10px; }
.wtx-card {
  padding: 12px 12px;
  border-radius: 12px;
  background: rgba(0,0,0,0.03);
  border: 1px solid rgba(0,0,0,0.04);
  margin-bottom: 8px;
}
.wtx-main { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.wtx-when { font-size: 11px; color: var(--muted); margin-top: 4px; }

/* Promo compact card */
.promo-card-compact{padding:10px 12px;margin:10px 0;border-radius:12px;border:1px solid var(--border,rgba(0,0,0,.08));background:var(--card,#fff)}
.promo-card-compact .promo-card-top{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:6px}
.promo-card-compact .promo-card-label{font-size:12px;font-weight:700;display:flex;align-items:center;gap:6px}
.promo-help{width:22px;height:22px;border-radius:999px;border:1px solid var(--border,rgba(0,0,0,.12));background:transparent;font-weight:800;font-size:12px;line-height:1;cursor:pointer;padding:0}
.promo-card-compact .promo-code{display:block;font-size:1.15rem;letter-spacing:.06em;margin:2px 0 8px}
.promo-card-compact .promo-stats{display:flex;gap:12px}
.promo-card-compact .promo-stat{display:flex;flex-direction:column;min-width:64px}
.promo-card-compact .ps-val{font-weight:800;font-size:14px}
.promo-card-compact .ps-lbl{font-size:11px;opacity:.7}
.promo-help-modal{max-width:340px}
.modal-overlay{position:fixed;inset:0;background:rgba(0,0,0,.45);display:flex;align-items:center;justify-content:center;z-index:9999;padding:16px}
.modal-card{background:var(--card,#fff);color:inherit;border-radius:14px;padding:14px 16px;width:100%;max-width:400px;box-shadow:0 12px 40px rgba(0,0,0,.2)}
.modal-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}
.modal-x{border:0;background:transparent;font-size:22px;line-height:1;cursor:pointer}

/* —— Recent purchases (bottom of home) —— */
.recent-wrap {
  margin-top: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #fcfcff 100%);
  border: 1px solid #e0e3f0;
  border-radius: var(--r-md);
  padding: 13px 12px 9px;
  box-shadow: var(--shadow-sm);
  animation: fadeUp .4s var(--ease) both;
}
.recent-head {
  display: flex; align-items: center; gap: 7px;
  padding: 0 2px 10px;
  border-bottom: 1px solid var(--line-soft);
}
.recent-ico {
  width: 26px; height: 26px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 14px; border-radius: 8px;
  background: var(--accent-soft); border: 1px solid #dcdffb;
}
.recent-head h3 { font-size: 13.5px; font-weight: 800; letter-spacing: -0.01em; }
.recent-sub { font-size: 11px; color: var(--muted); font-weight: 600; margin-left: auto; }
.recent-list { display: flex; flex-direction: column; }
.recent-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 6px;
  margin: 1px -6px 0;
  border-bottom: 1px solid var(--line-soft);
  border-radius: 9px;
  transition: background .15s var(--ease);
  animation: fadeUp .35s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 35ms);
}
.recent-item:last-child { border-bottom: none; }
.recent-item:hover { background: #f7f8ff; }
.rp-avatar {
  width: 38px; height: 38px; flex-shrink: 0;
  border-radius: 50%; overflow: hidden;
  border: 1.5px solid #fff;
  outline: 1.5px solid rgba(79, 70, 229, 0.35);
  background: var(--accent-grad);
  display: flex; align-items: center; justify-content: center;
}
.rp-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rp-fb { color: #fff; font-weight: 800; font-size: 15px; }
.rp-info { flex: 1; min-width: 0; }
.rp-title {
  font-size: 13px; font-weight: 800; color: var(--fg); line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rp-sub {
  display: flex; align-items: center; gap: 6px;
  margin-top: 2px; font-size: 11.5px; color: var(--muted);
  overflow: hidden; white-space: nowrap;
}
.rp-pkg {
  font-weight: 700; color: var(--accent);
  overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.rp-by { flex-shrink: 0; max-width: 45%; overflow: hidden; text-overflow: ellipsis; }
.rp-side {
  flex-shrink: 0; display: flex; flex-direction: column;
  align-items: flex-end; gap: 4px;
}
.rp-time { font-size: 10px; color: var(--muted); opacity: .85; white-space: nowrap; }
.rp-check {
  flex-shrink: 0; width: 20px; height: 20px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800; color: #0d8a4a;
  background: rgba(31,174,99,.12); border-radius: 50%;
}
@media (max-width: 480px) {
  .recent-wrap { padding: 12px 10px 7px; }
  .rp-avatar { width: 34px; height: 34px; }
  .rp-title { font-size: 12.5px; }
}


/* ================= Google Sign-In + Connected Accounts (v46) ================= */
.google-btn-wrap { display: flex; justify-content: center; margin-top: 12px; min-height: 44px; }
.google-btn-wrap[hidden] { display: none; }
.google-btn-wrap iframe { border-radius: 999px !important; }

.gg-conn-modal { width: min(92vw, 340px); }

/* Connected accounts (Account tab) */
.conn-acc {
  margin: 14px 0 12px;
  padding: 12px 12px 10px;
  border: 1px solid var(--border, #e0e3f0);
  border-radius: 14px;
  background: linear-gradient(160deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
}
.conn-title {
  font-size: 11px; font-weight: 800; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--muted, #8a90a8);
  margin-bottom: 8px;
}
.conn-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 2px;
  border-top: 1px solid rgba(128,140,170,0.12);
}
.conn-row:first-of-type { border-top: 0; }
.conn-ico {
  width: 34px; height: 34px; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px;
  background: rgba(128,140,170,0.10);
}
.conn-ico svg { width: 18px; height: 18px; }
.conn-ico.tg { color: #2ea6ff; background: rgba(46,166,255,0.12); }
.conn-ico.gg svg { width: 20px; height: 20px; }
.conn-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.conn-info b { font-size: 13.5px; font-weight: 700; }
.conn-info .ok {
  font-size: 12px; color: var(--accent, #7c8cff);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.conn-badge {
  flex: none; width: 26px; height: 26px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-size: 13px; font-weight: 800;
}
.conn-badge.on {
  color: #22c55e;
  background: rgba(34,197,94,0.12);
  box-shadow: 0 0 10px rgba(34,197,94,0.25);
}
/* Telegram deep-link connect panel */
.btn-tg svg { width: 17px; height: 17px; }

/* Layout safety — prevent any image from blowing the viewport */
img, video, canvas, svg {
  max-width: 100%;
}
.card-art, .card-art.sm, .banner-wrap, .banner-slide {
  overflow: hidden;
  max-width: 100%;
}
.banner-slide img {
  max-width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  display: block;
}
.notice-img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--r-md, 12px);
}
.main, .shell, #main {
  max-width: 100%;
  overflow-x: hidden;
}
