/* ==========================================================================
   WikiPay — Design System
   ========================================================================== */

:root {
  --brand-primary: #0057ff;
  --brand-primary-dark: #003fbf;
  --brand-accent: #00d1b2;
  --brand-gradient: linear-gradient(135deg, #0057ff 0%, #00a3ff 60%, #00d1b2 100%);
  --brand-gradient-soft: linear-gradient(135deg, rgba(0,87,255,0.08), rgba(0,209,178,0.08));

  --text-primary: #0b1220;
  --text-secondary: #4a5568;
  --text-muted: #7a869a;
  --text-invert: #ffffff;

  --bg-page: #ffffff;
  --bg-alt: #f7f9fc;
  --bg-card: #ffffff;
  --bg-dark: #0b1220;

  --border: #e6ebf2;
  --border-strong: #d0d7e2;
  --shadow-sm: 0 2px 8px rgba(11, 18, 32, 0.05);
  --shadow-md: 0 10px 30px rgba(11, 18, 32, 0.08);
  --shadow-lg: 0 24px 60px rgba(11, 18, 32, 0.12);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  --container: 1200px;
  --header-h: 72px;

  --font-sans: "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--bg-page);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  scroll-behavior: smooth;
}

img { max-width: 100%; display: block; }

a { color: var(--brand-primary); text-decoration: none; }
a:hover { color: var(--brand-primary-dark); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ HEADER / NAV ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 20px;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}
.nav-brand .logo-mark {
  width: 32px; height: 32px;
  border-radius: 10px;
  background: var(--brand-gradient);
  display: inline-grid; place-items: center;
  color: #fff; font-weight: 900;
  font-size: 15px;
  box-shadow: 0 6px 16px rgba(0, 87, 255, 0.35);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-links a {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 15px;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-cta { display: flex; align-items: center; gap: 12px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, color .2s;
  white-space: nowrap;
}
.btn-primary {
  color: #fff;
  background: var(--brand-gradient);
  box-shadow: 0 8px 22px rgba(0, 87, 255, 0.28);
}
.btn-primary:hover { transform: translateY(-1px); color: #fff; box-shadow: 0 12px 26px rgba(0, 87, 255, 0.34); }
.btn-ghost {
  color: var(--text-primary);
  background: transparent;
  border-color: var(--border-strong);
}
.btn-ghost:hover { border-color: var(--text-primary); }
.btn-lg { padding: 14px 26px; font-size: 16px; }

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  border-radius: 10px;
  background: transparent;
  border: 1px solid var(--border);
  cursor: pointer;
  align-items: center; justify-content: center;
}
.nav-toggle span {
  display: block;
  width: 18px; height: 2px;
  background: var(--text-primary);
  position: relative;
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: ""; position: absolute; left: 0;
  width: 18px; height: 2px; background: var(--text-primary);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }

/* ============ HERO ============ */
.hero {
  position: relative;
  padding: 88px 0 96px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -20% -10% auto auto;
  width: 720px; height: 720px;
  background: radial-gradient(closest-side, rgba(0, 209, 178, 0.18), transparent 70%);
  filter: blur(10px);
  z-index: -1;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto auto -30% -20%;
  width: 640px; height: 640px;
  background: radial-gradient(closest-side, rgba(0, 87, 255, 0.16), transparent 70%);
  filter: blur(10px);
  z-index: -1;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--brand-gradient-soft);
  color: var(--brand-primary-dark);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.02em;
  border: 1px solid rgba(0, 87, 255, 0.15);
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--brand-accent);
  box-shadow: 0 0 0 4px rgba(0, 209, 178, 0.2);
}
.hero h1 {
  font-size: clamp(38px, 5.4vw, 62px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 20px 0 18px;
  font-weight: 800;
}
.hero h1 .accent {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p.lead {
  font-size: 19px;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 0 32px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.trust-badges {
  display: flex; gap: 22px; margin-top: 34px;
  color: var(--text-muted);
  font-size: 13px;
  align-items: center;
  flex-wrap: wrap;
}
.trust-badges .check { color: var(--brand-accent); font-weight: 700; }

/* Hero visual — floating card mockup */
.hero-visual {
  position: relative;
  height: 520px;
}
.mock-card {
  position: absolute;
  width: 380px;
  border-radius: 22px;
  padding: 26px 26px 22px;
  color: #fff;
  box-shadow: var(--shadow-lg);
  background: linear-gradient(135deg, #0b1220 0%, #143a8a 55%, #0057ff 100%);
  overflow: hidden;
}
.mock-card::before {
  content: "";
  position: absolute;
  right: -60px; top: -60px;
  width: 220px; height: 220px;
  background: radial-gradient(closest-side, rgba(0, 209, 178, 0.55), transparent 70%);
}
.mock-card .brand-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 60px;
}
.mock-card .brand-row .chip {
  width: 40px; height: 30px; border-radius: 6px;
  background: linear-gradient(135deg, #f5c46b, #b8862a);
}
.mock-card .brand-row .brand {
  font-weight: 800; letter-spacing: 0.06em;
}
.mock-card .number {
  font-family: "Menlo", "SF Mono", monospace;
  font-size: 20px;
  letter-spacing: 0.18em;
  margin-bottom: 22px;
}
.mock-card .meta {
  display: flex; justify-content: space-between;
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}
.mock-card .meta strong { color: #fff; font-size: 14px; display: block; margin-top: 2px; }
.card-1 { top: 40px; left: 20px; transform: rotate(-6deg); }
.card-2 {
  top: 190px; left: 130px; transform: rotate(4deg);
  background: linear-gradient(135deg, #00a3ff 0%, #00d1b2 100%);
}
.card-2::before {
  background: radial-gradient(closest-side, rgba(255,255,255,0.35), transparent 70%);
}

.float-widget {
  position: absolute;
  background: #fff;
  border-radius: 16px;
  padding: 14px 18px;
  box-shadow: var(--shadow-md);
  display: flex; align-items: center; gap: 12px;
  border: 1px solid var(--border);
}
.float-widget .icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center;
  background: var(--brand-gradient-soft);
  color: var(--brand-primary);
}
.float-widget .label {
  font-size: 12px; color: var(--text-muted);
}
.float-widget .value {
  font-weight: 700; font-size: 15px; color: var(--text-primary);
}
.widget-1 { top: 10px; right: 20px; }
.widget-2 { bottom: 50px; left: 10px; }
.widget-3 { bottom: 0; right: 30px; }

/* ============ STATS BAR ============ */
.stats {
  background: var(--bg-dark);
  color: #fff;
  padding: 42px 0;
  border-radius: 22px;
  margin-top: -32px;
  position: relative;
  z-index: 2;
  box-shadow: var(--shadow-lg);
  background-image:
    radial-gradient(circle at 15% 30%, rgba(0, 163, 255, 0.25), transparent 40%),
    radial-gradient(circle at 85% 70%, rgba(0, 209, 178, 0.25), transparent 40%),
    linear-gradient(180deg, #0b1220, #0b1220);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}
.stat .num {
  font-size: 42px; font-weight: 800; letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ffffff, #b6dcff);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.stat .label {
  color: rgba(255,255,255,0.7);
  font-size: 14px; margin-top: 4px;
}

/* ============ SECTIONS ============ */
section { padding: 96px 0; }
.section-head { max-width: 720px; margin: 0 auto 48px; text-align: center; }
.section-head .kicker {
  color: var(--brand-primary);
  font-weight: 700; font-size: 13px;
  letter-spacing: 0.14em; text-transform: uppercase;
  margin-bottom: 12px;
}
.section-head h2 {
  font-size: clamp(30px, 3.5vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  font-weight: 800;
}
.section-head p {
  color: var(--text-secondary);
  font-size: 17px;
  margin: 0;
}

/* Wallet feature grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.feature-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--brand-gradient-soft);
  color: var(--brand-primary);
  display: grid; place-items: center;
  margin-bottom: 18px;
}
.feature-card h3 {
  font-size: 20px; margin: 0 0 8px; font-weight: 700;
}
.feature-card p {
  color: var(--text-secondary); margin: 0; font-size: 15px;
}

/* Virtual card split section */
.split { background: var(--bg-alt); }
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.split-copy .kicker {
  color: var(--brand-primary);
  font-weight: 700; font-size: 13px;
  letter-spacing: 0.14em; text-transform: uppercase;
  margin-bottom: 14px;
}
.split-copy h2 {
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
  font-weight: 800;
}
.split-copy p {
  color: var(--text-secondary); font-size: 17px; margin: 0 0 26px;
}
.check-list { list-style: none; padding: 0; margin: 0 0 32px; }
.check-list li {
  display: flex; gap: 12px; padding: 10px 0;
  color: var(--text-primary); font-weight: 500;
}
.check-list .tick {
  flex: 0 0 22px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--brand-gradient);
  color: #fff; display: grid; place-items: center;
  font-size: 12px; font-weight: 800;
  margin-top: 2px;
}

.card-showcase {
  position: relative;
  aspect-ratio: 1 / 1;
  display: grid; place-items: center;
}
.card-showcase .glow {
  position: absolute; inset: 10%;
  background: var(--brand-gradient);
  filter: blur(60px); opacity: 0.35;
  border-radius: 50%;
}
.card-showcase .mock-card {
  position: relative;
  transform: perspective(1200px) rotateX(12deg) rotateY(-16deg);
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.step {
  padding: 32px 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  position: relative;
}
.step .num {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: grid; place-items: center;
  background: var(--brand-gradient);
  color: #fff; font-weight: 800; font-size: 18px;
  box-shadow: 0 6px 16px rgba(0, 87, 255, 0.35);
  margin-bottom: 18px;
}
.step h3 { margin: 0 0 8px; font-size: 20px; font-weight: 700; }
.step p { margin: 0; color: var(--text-secondary); font-size: 15px; }

/* Security */
.security { background: var(--bg-dark); color: #fff; }
.security .section-head h2 { color: #fff; }
.security .section-head p { color: rgba(255,255,255,0.7); }
.security .section-head .kicker { color: var(--brand-accent); }
.pillars {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
}
.pillar {
  padding: 26px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
}
.pillar-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center;
  background: rgba(0, 209, 178, 0.12);
  color: var(--brand-accent);
  margin-bottom: 16px;
}
.pillar h4 { margin: 0 0 6px; font-size: 17px; font-weight: 700; }
.pillar p { margin: 0; font-size: 14px; color: rgba(255,255,255,0.7); }

/* CTA */
.cta {
  padding: 96px 0;
}
.cta-inner {
  padding: 56px 48px;
  border-radius: var(--radius-lg);
  background: var(--brand-gradient);
  color: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}
.cta-inner::after {
  content: "";
  position: absolute; inset: -40% -20% auto auto;
  width: 500px; height: 500px;
  background: radial-gradient(closest-side, rgba(255,255,255,0.25), transparent 70%);
}
.cta-inner h2 {
  font-size: clamp(26px, 3vw, 36px);
  margin: 0 0 8px; font-weight: 800; letter-spacing: -0.01em;
}
.cta-inner p { margin: 0; color: rgba(255,255,255,0.85); }
.cta-inner .btn-primary {
  background: #fff; color: var(--brand-primary-dark);
  box-shadow: 0 12px 24px rgba(0,0,0,0.16);
}
.cta-inner .btn-primary:hover { color: var(--brand-primary-dark); }

/* ============ FOOTER ============ */
.site-footer {
  background: #06090f;
  color: rgba(255,255,255,0.7);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand p {
  color: rgba(255,255,255,0.6);
  font-size: 14px;
  margin: 12px 0 0;
  max-width: 320px;
}
.footer-col h5 {
  color: #fff;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 16px;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  color: rgba(255,255,255,0.65);
  font-size: 14px;
}
.footer-col a:hover { color: #fff; }
.footer-bottom {
  padding-top: 28px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 13px; color: rgba(255,255,255,0.5);
  flex-wrap: wrap; gap: 16px;
}
.footer-bottom p { margin: 0; max-width: 780px; }

/* ============ LEGAL / DOC PAGES ============ */
.doc-hero {
  background: var(--brand-gradient-soft);
  padding: 72px 0 48px;
  border-bottom: 1px solid var(--border);
}
.doc-hero h1 {
  font-size: clamp(32px, 4vw, 48px);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
  font-weight: 800;
}
.doc-hero .meta {
  color: var(--text-muted);
  font-size: 14px;
}
.doc {
  padding: 64px 0 96px;
}
.doc .container { max-width: 860px; }
.doc h2 {
  margin: 40px 0 12px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.doc h3 {
  margin: 24px 0 8px;
  font-size: 17px;
  font-weight: 700;
}
.doc p, .doc li {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.75;
}
.doc ul { padding-left: 22px; }
.doc a { color: var(--brand-primary-dark); text-decoration: underline; }

/* ============ REVEAL ANIMATION ============ */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ============ RESPONSIVE ============ */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { height: 460px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: 1fr 1fr; }
  .split-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .cta-inner { flex-direction: column; text-align: center; align-items: stretch; }
}

@media (max-width: 640px) {
  section { padding: 72px 0; }
  .hero { padding: 56px 0 72px; }
  .nav-links, .nav-cta .btn-ghost { display: none; }
  .nav-toggle { display: inline-flex; }
  .site-header.menu-open .nav-links {
    display: flex; flex-direction: column;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    padding: 16px 24px; gap: 8px;
  }
  .site-header.menu-open .nav-links a { padding: 10px 0; font-size: 16px; }
  .features-grid { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .cta-inner { padding: 40px 28px; }
  .stat .num { font-size: 34px; }
  .mock-card { width: 300px; }
  .card-1 { left: 0; }
  .card-2 { left: 80px; }
}
