@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;900&family=JetBrains+Mono:wght@400;600&display=swap');

/* ============================================================
   DESIGN TOKENS
   ============================================================ */
:root {
  --bg-primary:    #0d0d0f;
  --bg-secondary:  #141418;
  --bg-card:       #1a1a20;
  --accent:        #ff6b2b;
  --accent-hover:  #ff8c55;
  --accent-sec:    #7c3aed;
  --text-primary:  #f0f0f0;
  --text-secondary:#9a9aaa;
  --text-muted:    #5a5a70;
  --border:        #2a2a35;
  --success:       #22c55e;
  --error:         #ef4444;
  --warning:       #f59e0b;
  --radius:        12px;
  --radius-sm:     8px;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background-color: var(--bg-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  color: var(--text-primary);
  min-height: 100vh;
  animation: pageIn 0.3s ease;
}

@keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

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

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================================
   NAV
   ============================================================ */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 13, 15, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.03em;
}
.nav-logo span { color: var(--accent); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease,
              background 0.15s ease, opacity 0.15s ease, border-color 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(255, 107, 43, 0.4);
}
.btn-primary:active { transform: translateY(0); }

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
  transform: translateY(-2px);
  border-color: var(--accent);
}

.btn-lg { padding: 15px 36px; font-size: 1.0625rem; }
.btn-full { width: 100%; }

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  min-height: 88vh;
  display: flex;
  align-items: center;
  padding: 80px 24px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 900px;
  background: radial-gradient(circle, rgba(255,107,43,0.07) 0%, transparent 68%);
  pointer-events: none;
}

.hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 107, 43, 0.1);
  border: 1px solid rgba(255, 107, 43, 0.25);
  border-radius: 100px;
  padding: 6px 14px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -0.035em;
  color: var(--text-primary);
  margin-bottom: 20px;
}
.hero h1 .hl { color: var(--accent); }

.hero-sub {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 440px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-note {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.hero-visual {
  aspect-ratio: 16/10;
  background: linear-gradient(145deg, var(--bg-secondary) 0%, #1a1a28 100%);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.hero-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,
    rgba(255,107,43,0.06) 0%,
    transparent 45%,
    rgba(124,58,237,0.06) 100%);
}

.hero-visual-label {
  position: relative;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: center;
}

/* ============================================================
   DEMO / MONTAGE
   ============================================================ */
.demo { background: var(--bg-secondary); }
.demo-inner {
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}
.demo-frame {
  margin-top: 36px;
  aspect-ratio: 16 / 9;
  background: #000;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}
.demo-video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

/* ============================================================
   SECTION BASICS
   ============================================================ */
section { padding: 96px 24px; }

.section-label {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.375rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.section-sub {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  max-width: 560px;
}

/* ============================================================
   FEATURES
   ============================================================ */
.features {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.features-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.features-text .section-sub { margin-bottom: 32px; }

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9375rem;
  color: var(--text-secondary);
}

.feature-list li::before {
  content: '✓';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 50%;
  color: var(--success);
  font-size: 0.7rem;
  font-weight: 800;
  flex-shrink: 0;
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.how-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.how-header {
  text-align: center;
  margin-bottom: 64px;
}
.how-header .section-sub { margin: 0 auto; }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.step {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.step:hover {
  border-color: rgba(255,107,43,0.35);
  transform: translateY(-3px);
}

.step-num {
  font-size: 3.5rem;
  font-weight: 900;
  color: rgba(255, 107, 43, 0.12);
  line-height: 1;
  margin-bottom: 20px;
  letter-spacing: -0.06em;
}

.step-title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.step-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* ============================================================
   FAQ
   ============================================================ */
.faq {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.faq-inner {
  max-width: 760px;
  margin: 0 auto;
}

.faq-header {
  text-align: center;
  margin-bottom: 48px;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.9375rem;
  font-weight: 600;
  text-align: left;
  transition: color 0.15s ease;
}
.faq-q:hover { color: var(--accent); }

.faq-chevron {
  flex-shrink: 0;
  transition: transform 0.25s ease;
  color: var(--text-muted);
}
.faq-item.open .faq-chevron { transform: rotate(180deg); }

.faq-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.faq-item.open .faq-body { max-height: 300px; }

.faq-a {
  padding: 0 24px 20px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 40px 24px;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  text-align: center;
}

.footer-copy { font-size: 0.875rem; color: var(--text-muted); }

.footer-links { display: flex; gap: 24px; }
.footer-links a {
  font-size: 0.875rem;
  color: var(--text-muted);
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--text-secondary); }

/* ============================================================
   PAGE HEADER (buy / pay / success)
   ============================================================ */
.page-header {
  padding: 64px 24px 0;
  text-align: center;
}
.page-header h1 {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}
.page-header p { color: var(--text-secondary); }

/* ============================================================
   BUY PAGE
   ============================================================ */
.buy-section { padding: 48px 24px 96px; }

.buy-inner { max-width: 900px; margin: 0 auto; }

.buy-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.buy-product-name {
  font-size: 1.375rem;
  font-weight: 700;
}

.buy-sep { color: var(--text-muted); }

.buy-price {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--accent);
}

.coin-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

.coin-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: border-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}
.coin-card:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 10px 36px rgba(255, 107, 43, 0.13);
}

.coin-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.coin-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.375rem;
  font-weight: 700;
  flex-shrink: 0;
}
.coin-icon.btc  { background: rgba(247,147,26,0.12); color: #f7931a; }
.coin-icon.eth  { background: rgba(98,126,234,0.12);  color: #627eea; }
.coin-icon.ltc  { background: rgba(190,190,190,0.12); color: #bebebe; }
.coin-icon.usdt { background: rgba(38,161,123,0.12);  color: #26a17b; }

.coin-name   { font-size: 1.0625rem; font-weight: 700; }
.coin-ticker { font-size: 0.8125rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; }

.coin-amount {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.25rem;
  font-weight: 600;
}

.coin-amount-label { font-size: 0.8125rem; color: var(--text-muted); }

/* ============================================================
   SPINNER / LOADING
   ============================================================ */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.2);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.loading-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(13,13,15,0.72);
  backdrop-filter: blur(6px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}
.loading-overlay.active { display: flex; }
.loading-overlay .spinner { width: 42px; height: 42px; border-width: 3px; color: var(--accent); }
.loading-overlay p { color: var(--text-secondary); font-size: 0.9375rem; }

/* ============================================================
   PAY PAGE
   ============================================================ */
.pay-section { padding: 48px 24px 96px; }
.pay-inner { max-width: 640px; margin: 0 auto; }

.pay-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
}

.status-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: rgba(245,158,11,0.07);
  border: 1px solid rgba(245,158,11,0.2);
  border-radius: var(--radius-sm);
  color: var(--warning);
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 32px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--warning);
  animation: blink 2s ease infinite;
  flex-shrink: 0;
}
@keyframes blink { 0%,100% { opacity:1; } 50% { opacity:0.25; } }

/* Payment detected, awaiting on-chain confirmation. */
.status-bar.confirming {
  background: rgba(34,197,94,0.08);
  border-color: rgba(34,197,94,0.25);
  color: var(--success);
}
.status-bar.confirming .status-dot { background: var(--success); }

.pay-field { margin-bottom: 22px; }

.pay-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.pay-value {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
}

.pay-text {
  flex: 1;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9375rem;
  color: var(--text-primary);
  word-break: break-all;
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
  flex-shrink: 0;
  white-space: nowrap;
}
.copy-btn:hover  { border-color: var(--accent);   color: var(--accent);   }
.copy-btn.copied { border-color: var(--success); color: var(--success); }

/* QR */
.qr-wrap {
  display: flex;
  justify-content: center;
  margin: 30px 0;
}
.qr-inner {
  background: #fff;
  padding: 12px;
  border-radius: var(--radius-sm);
  display: inline-block;
  line-height: 0;
}

/* Countdown */
.countdown-wrap {
  text-align: center;
  margin: 28px 0;
}
.countdown-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.countdown {
  font-family: 'JetBrains Mono', monospace;
  font-size: 3rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  transition: color 0.3s ease;
}
.countdown.urgent {
  color: var(--error);
  animation: urgentPulse 1s ease infinite;
}
@keyframes urgentPulse { 0%,100% { opacity:1; } 50% { opacity:0.55; } }

.pay-warn {
  background: rgba(245,158,11,0.06);
  border: 1px solid rgba(245,158,11,0.18);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  font-size: 0.875rem;
  color: var(--warning);
  margin-top: 24px;
}

/* ============================================================
   SUCCESS PAGE
   ============================================================ */
.success-section { padding: 48px 24px 96px; }
.success-inner { max-width: 640px; margin: 0 auto; }

.success-hero {
  text-align: center;
  margin-bottom: 40px;
}

.check-circle {
  width: 76px;
  height: 76px;
  background: rgba(34,197,94,0.1);
  border: 2px solid rgba(34,197,94,0.35);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  font-size: 2.25rem;
}

.success-hero h1 {
  font-size: 1.875rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}
.success-hero p { color: var(--text-secondary); }

.success-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  margin-bottom: 20px;
}
.success-card-title {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.license-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
}
.license-key {
  flex: 1;
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.06em;
  word-break: break-all;
}

.instruction-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.instruction-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.9375rem;
  color: var(--text-secondary);
}
.inst-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: rgba(255,107,43,0.1);
  border: 1px solid rgba(255,107,43,0.25);
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 1px;
}

/* ============================================================
   ALERTS
   ============================================================ */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 0.875rem;
  margin-bottom: 20px;
}
.alert-warn    { background: rgba(245,158,11,0.06); border: 1px solid rgba(245,158,11,0.2); color: var(--warning); }
.alert-error   { background: rgba(239,68,68,0.06);  border: 1px solid rgba(239,68,68,0.2);  color: var(--error);   }
.alert-success { background: rgba(34,197,94,0.06);  border: 1px solid rgba(34,197,94,0.2);  color: var(--success); }

/* State / error card */
.state-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 56px 40px;
  text-align: center;
}
.state-card h2 { font-size: 1.5rem; font-weight: 700; margin-bottom: 12px; }
.state-card p  { color: var(--text-secondary); margin-bottom: 28px; }

/* Utility */
.hidden { display: none !important; }
.divider { height: 1px; background: var(--border); margin: 24px 0; }
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.mt-8  { margin-top: 8px;  }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 800px) {
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .hero-visual { display: none; }
  .features-inner { grid-template-columns: 1fr; gap: 48px; }
  .steps { grid-template-columns: 1fr; }
  .coin-grid { grid-template-columns: 1fr; }
  .pay-card { padding: 24px 20px; }
  .success-card { padding: 24px 20px; }
}
