:root {
  --bg: #05070d;
  --bg-2: #0a101c;
  --glass: rgba(15, 23, 42, 0.55);
  --glass-2: rgba(15, 23, 42, 0.7);
  --card: rgba(17, 25, 40, 0.6);
  --border: rgba(148, 163, 184, 0.12);
  --border-strong: rgba(148, 163, 184, 0.2);
  --text: #eaf1fb;
  --muted: #94a3b8;
  --muted-2: #64748b;

  --accent: #3b82f6;
  --accent-2: #38bdf8;
  --accent-soft: rgba(59, 130, 246, 0.14);
  --accent-grad: linear-gradient(135deg, #2563eb 0%, #3b82f6 45%, #06b6d4 100%);
  --green: #34d399;
  --red: #f87171;
  --amber: #fbbf24;

  --radius: 16px;
  --radius-sm: 11px;
  --shadow: 0 20px 50px rgba(2, 6, 23, 0.6);
  --glow: 0 10px 40px rgba(59, 130, 246, 0.35);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body {
  margin: 0;
  padding: 0;
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(1100px 520px at 82% -12%, rgba(37, 99, 235, 0.22), transparent 60%),
    radial-gradient(900px 460px at -8% 4%, rgba(6, 182, 212, 0.14), transparent 55%),
    radial-gradient(700px 500px at 50% 120%, rgba(59, 130, 246, 0.12), transparent 60%),
    var(--bg);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.04) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
  z-index: 0;
}

::selection { background: rgba(59, 130, 246, 0.35); color: #fff; }

a { color: var(--accent); text-decoration: none; }

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 1;
}

/* Header */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(5, 7, 13, 0.72);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  border-bottom: 1px solid var(--border);
}
.topbar .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.4px;
}
.brand .logo {
  width: 34px; height: 34px;
  border-radius: 10px;
  background: var(--accent-grad);
  display: grid; place-items: center;
  font-weight: 800; color: #04101f;
  flex: none;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4);
}
.brand .logo svg { width: 18px; height: 18px; }
.topbar .nav { display: flex; align-items: center; gap: 8px; }
.topbar .nav a, .topbar .nav button {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  padding: 8px 13px;
  border-radius: 9px;
  cursor: pointer;
  font-family: var(--font);
  transition: color .15s ease, background .15s ease;
}
.topbar .nav a:hover, .topbar .nav button:hover { color: var(--text); background: var(--glass); }
.topbar .nav a.active {
  color: #fff;
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.3);
}
.btn-outline {
  border: 1px solid var(--border-strong) !important;
  color: var(--text) !important;
}
.btn-outline:hover { border-color: var(--accent) !important; color: var(--accent-2) !important; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent-grad);
  color: #04101f;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-sm);
  padding: 12px 20px;
  font-size: 15px;
  cursor: pointer;
  font-family: var(--font);
  letter-spacing: -0.1px;
  transition: transform .1s ease, box-shadow .2s ease, opacity .2s ease;
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.28);
}
.btn:hover { box-shadow: var(--glow); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn.ghost {
  background: var(--glass);
  color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: none;
}
.btn.ghost:hover { border-color: var(--accent); color: var(--accent-2); box-shadow: none; }
.btn.block { width: 100%; }
.btn.sm { padding: 8px 14px; font-size: 13px; }

/* Cards */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

/* Hero / landing */
.hero { padding: 88px 0 44px; text-align: center; }
.hero .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: var(--accent-2);
  background: var(--accent-soft);
  border: 1px solid rgba(59, 130, 246, 0.25);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(34px, 6vw, 60px);
  font-weight: 800;
  letter-spacing: -2px;
  margin: 0 0 18px;
  line-height: 1.03;
}
.hero h1 .grad {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p.sub { color: var(--muted); font-size: 18px; max-width: 560px; margin: 0 auto 30px; line-height: 1.55; }

.stats-strip {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin: 26px 0;
}
.stat-pill {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 10px 24px;
  font-size: 14px;
  color: var(--muted);
}
.stat-pill b { color: #fff; margin-right: 6px; font-weight: 700; }

/* Auth box */
.auth-box {
  max-width: 420px;
  margin: 0 auto;
}
.auth-box h2 { margin: 0 0 6px; font-size: 23px; letter-spacing: -0.4px; }
.auth-box p.hint { color: var(--muted); font-size: 14px; margin: 0 0 18px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 7px; font-weight: 500; }
.field input {
  width: 100%;
  background: var(--glass-2);
  border: 1px solid var(--border-strong);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 13px 15px;
  font-size: 15px;
  font-family: var(--font);
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}
.err { color: var(--red); font-size: 13px; min-height: 18px; margin: 4px 0 10px; }

/* Token reveal */
.token-box {
  background: var(--glass-2);
  border: 1px dashed var(--accent);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  margin: 18px 0;
}
.token-box .code {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: 3px;
  color: var(--accent-2);
  word-break: break-all;
  margin: 8px 0;
}
.warn {
  background: rgba(248, 113, 113, 0.08);
  border: 1px solid rgba(248, 113, 113, 0.25);
  color: #fca5a5;
  font-size: 13px;
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  margin: 12px 0;
  line-height: 1.5;
}

/* Tiers */
.tiers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  margin-top: 24px;
}
.tier-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  transition: border-color .2s ease, transform .18s ease, box-shadow .2s ease;
}
.tier-card:hover { transform: translateY(-4px); border-color: rgba(59, 130, 246, 0.5); box-shadow: var(--shadow); }
.tier-card.popular {
  border-color: rgba(59, 130, 246, 0.55);
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.55), 0 20px 50px rgba(2, 6, 23, 0.5);
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.1), var(--card));
}
.badge-popular {
  position: absolute;
  top: -12px; right: 18px;
  background: var(--accent-grad);
  color: #04101f;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: .6px;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4);
}
.tier-card h3 { margin: 0 0 4px; font-size: 20px; letter-spacing: -0.3px; }
.tier-card .duration { color: var(--muted); font-size: 13px; margin-bottom: 14px; }
.tier-price { font-size: 36px; font-weight: 800; letter-spacing: -1.5px; }
.tier-price .cur { font-size: 16px; color: var(--muted); font-weight: 600; }
.tier-price s { color: var(--muted-2); font-weight: 500; font-size: 18px; margin-right: 6px; }
.tier-features { list-style: none; padding: 0; margin: 18px 0 22px; flex: 1; }
.tier-features li {
  padding: 6px 0 6px 26px;
  color: var(--muted);
  font-size: 14px;
  position: relative;
}
.tier-features li::before {
  content: "✓";
  position: absolute; left: 0;
  color: var(--accent-2); font-weight: 800;
}

/* Sale banner */
.sale-banner {
  background: var(--accent-grad);
  color: #04101f;
  border-radius: var(--radius);
  padding: 15px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.3);
}
.sale-banner .countdown {
  background: rgba(0, 0, 0, 0.18);
  border-radius: 8px;
  padding: 6px 13px;
  font-variant-numeric: tabular-nums;
}

/* Files grid */
.section-title { margin: 40px 0 6px; font-size: 21px; letter-spacing: -0.4px; }
.section-sub { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.files-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.file-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  position: relative;
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.file-card:hover { border-color: rgba(59, 130, 246, 0.5); transform: translateY(-3px); box-shadow: var(--shadow); }
.file-card .cat {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--muted-2);
  margin-bottom: 8px;
  font-weight: 600;
}
.file-card h4 { margin: 0 0 10px; font-size: 16px; letter-spacing: -0.2px; }
.file-card .lock {
  font-size: 12px;
  color: var(--accent-2);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 5px;
}
.file-card .free { color: var(--green); font-size: 12px; font-weight: 600; }
.file-card .badge-hot {
  position: absolute; top: 14px; right: 14px;
  font-size: 10px; font-weight: 800; color: var(--accent-2);
  text-transform: uppercase; letter-spacing: .6px;
}

/* Payment modal */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(2, 6, 23, 0.75);
  display: none;
  align-items: center; justify-content: center;
  z-index: 100;
  padding: 20px;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--glass-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  max-width: 440px;
  width: 100%;
  padding: 26px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow);
}
.modal h3 { margin: 0 0 14px; font-size: 20px; letter-spacing: -0.3px; }
.pay-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.pay-row .amount { font-size: 27px; font-weight: 800; letter-spacing: -0.5px; }
.pay-row .crypto { color: var(--muted); }
.address-box {
  background: var(--bg-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  word-break: break-all;
  margin: 10px 0;
  color: var(--accent-2);
}
.qr-wrap { text-align: center; margin: 14px 0; }
.qr-wrap img { border-radius: 12px; background: #fff; padding: 10px; }
.currency-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.currency-chips button {
  background: var(--glass);
  border: 1px solid var(--border-strong);
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 15px;
  font-size: 13px;
  cursor: pointer;
  font-family: var(--font);
  font-weight: 500;
  transition: all .15s ease;
}
.currency-chips button.active {
  border-color: var(--accent);
  color: #fff;
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.35);
}

/* Toasts (social proof + notifications) */
.toasts { position: fixed; bottom: 18px; left: 18px; z-index: 200; display: flex; flex-direction: column; gap: 10px; }
.toast {
  background: var(--glass-2);
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 13px;
  box-shadow: var(--shadow);
  animation: slidein .35s cubic-bezier(.2,.7,.3,1);
  max-width: 320px;
}
.toast b { color: var(--accent-2); }
.toast .time { color: var(--muted-2); font-size: 11px; margin-top: 3px; }
@keyframes slidein { from { transform: translateX(-24px); opacity: 0; } to { transform: none; opacity: 1; } }

/* Profile */
.profile-head { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; margin: 30px 0; }
.avatar {
  width: 68px; height: 68px; border-radius: 50%;
  background: var(--accent-soft);
  border: 1px solid rgba(59, 130, 246, 0.3);
  display: grid; place-items: center;
  color: var(--accent-2);
  box-shadow: 0 8px 26px rgba(59, 130, 246, 0.25);
}
.avatar svg { width: 34px; height: 34px; }
.profile-head h1 { margin: 0 0 4px; font-size: 26px; letter-spacing: -0.5px; }
.profile-head .meta { color: var(--muted); font-size: 14px; }
.badge-tier {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent-soft);
  color: var(--accent-2);
  font-weight: 700; font-size: 13px;
  padding: 6px 13px; border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.3);
}
.badge-tier.free { background: var(--glass); color: var(--muted); box-shadow: inset 0 0 0 1px var(--border-strong); }

.stat-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 14px; margin: 20px 0; }
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.stat-card .num { font-size: 29px; font-weight: 800; letter-spacing: -0.5px; }
.stat-card .lbl { color: var(--muted); font-size: 13px; margin-top: 4px; }

.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.table td { padding: 12px 12px; border-bottom: 1px solid var(--border); }
.table tr:last-child td { border-bottom: none; }
.status-pill { font-size: 12px; font-weight: 700; padding: 4px 11px; border-radius: 999px; }
.status-pill.pending { background: rgba(251, 191, 36, 0.12); color: var(--amber); }
.status-pill.approved { background: rgba(52, 211, 153, 0.12); color: var(--green); }
.status-pill.rejected { background: rgba(248, 113, 113, 0.12); color: var(--red); }

.empty { text-align: center; color: var(--muted); padding: 32px 10px; font-size: 14px; }

.footer { margin-top: 64px; padding: 30px 0; border-top: 1px solid var(--border); color: var(--muted-2); font-size: 13px; text-align: center; }

@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .topbar .wrap { height: 58px; }
  .brand { font-size: 17px; gap: 9px; }
  .brand .logo { width: 30px; height: 30px; }
  .topbar .nav { gap: 4px; }
  .topbar .nav a, .topbar .nav button { padding: 7px 10px; font-size: 13px; }

  .hero { padding: 48px 0 24px; }
  .hero h1 { font-size: 32px; }
  .hero p.sub { font-size: 16px; }

  .card { padding: 18px; }
  .tiers-grid { grid-template-columns: 1fr; }
  .section-title { margin-top: 30px; }

  .profile-head { gap: 16px; margin: 22px 0; }
  .avatar { width: 56px; height: 56px; }
  .avatar svg { width: 28px; height: 28px; }
  .profile-head h1 { font-size: 21px; }

  .stat-cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-card { padding: 16px; }
  .stat-card .num { font-size: 24px; }

  .table { font-size: 13px; }
  .table th, .table td { padding: 9px 8px; }

  .modal { padding: 20px; }
  .toast { max-width: 260px; }
  .pay-row .amount { font-size: 22px; }

  .footer { margin-top: 44px; }
}

