/* Referral program styles — uses theme.css CSS variables */

/* === HERO === */
.ref-hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 120px 80px 80px;
}
.ref-hero-bg {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, #07090E 0%, #070E0A 60%, #0A0F12 100%);
}
.ref-hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(10,191,156,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(10,191,156,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
}
.ref-hero-content {
  position: relative; z-index: 2; max-width: 680px;
}
.ref-kicker {
  font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--accent); margin-bottom: 24px;
  font-family: var(--font-body);
}
.ref-hero-content h1 {
  font-family: var(--font-display); font-weight: 900;
  font-size: clamp(44px, 5vw, 72px); line-height: 0.97;
  letter-spacing: -0.03em; color: var(--fg); margin-bottom: 24px;
}
.ref-accent { color: var(--accent); }
.ref-sub {
  font-size: 18px; color: var(--fg-muted); line-height: 1.65;
  max-width: 520px; margin-bottom: 48px; font-weight: 300;
}
.ref-how { display: flex; flex-direction: column; gap: 20px; max-width: 480px; }
.ref-step { display: flex; align-items: flex-start; gap: 16px; }
.step-num {
  width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid var(--accent);
  color: var(--accent); font-family: var(--font-display); font-weight: 800;
  font-size: 14px; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; background: rgba(10,191,156,0.08);
}
.step-body { font-size: 15px; color: var(--fg-muted); padding-top: 4px; line-height: 1.5; }
.step-body strong { color: var(--fg); }

/* === SIGNUP SECTION === */
.ref-signup {
  background: var(--bg-surface); border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border); padding: 80px;
}
.ref-signup-inner { max-width: 520px; margin: 0 auto; }
.ref-signup-inner h2 {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(24px, 2.5vw, 36px); letter-spacing: -0.025em;
  color: var(--fg); margin-bottom: 10px;
}
.ref-signup-sub { font-size: 15px; color: var(--fg-muted); margin-bottom: 32px; line-height: 1.6; }
.ref-code-banner {
  background: rgba(10,191,156,0.08); border: 1px solid rgba(10,191,156,0.25);
  border-radius: 8px; padding: 14px 18px; font-size: 14px; color: var(--fg-muted);
  margin-bottom: 24px; line-height: 1.5;
}
.ref-code-banner strong { color: var(--accent); }

/* Form */
.ref-form { display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group label {
  font-size: 13px; font-weight: 600; color: var(--fg-muted);
  letter-spacing: 0.01em;
}
.form-group input {
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  padding: 12px 16px; font-size: 15px; color: var(--fg); font-family: var(--font-body);
  outline: none; transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input::placeholder { color: var(--fg-dim); }
.form-group input:focus {
  border-color: rgba(10,191,156,0.5);
  box-shadow: 0 0 0 3px rgba(10,191,156,0.08);
}
.optional { font-weight: 400; color: var(--fg-dim); font-size: 12px; }

.ref-btn {
  background: var(--accent); color: #07090E; border: none; border-radius: 8px;
  padding: 14px 28px; font-size: 15px; font-weight: 700; font-family: var(--font-body);
  cursor: pointer; transition: opacity 0.15s, transform 0.15s;
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
  letter-spacing: 0.01em;
}
.ref-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.ref-btn:active { transform: translateY(0); }
.ref-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.ref-btn-secondary {
  background: transparent; color: var(--accent); border: 1.5px solid var(--accent);
}
.ref-btn-outline {
  background: transparent; border: 1.5px solid rgba(255,255,255,0.15);
  color: var(--fg-muted); padding: 10px 20px; font-size: 13px;
}
.ref-btn-outline:hover { border-color: rgba(255,255,255,0.3); color: var(--fg); }

.form-error {
  background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.25);
  border-radius: 6px; padding: 12px 14px; font-size: 13px; color: #EF4444;
  margin-top: -8px;
}

/* Code reveal */
.code-success-header {
  display: flex; align-items: center; gap: 20px;
  margin-bottom: 28px; padding: 20px; background: rgba(10,191,156,0.06);
  border: 1px solid rgba(10,191,156,0.15); border-radius: 12px;
}
.code-success-header h2 {
  font-family: var(--font-display); font-weight: 800;
  font-size: 22px; color: var(--fg); margin-bottom: 4px;
}
.code-success-header p { font-size: 13px; color: var(--fg-muted); }
.ref-code-display { display: flex; align-items: center; gap: 16px; margin-bottom: 28px; }
.ref-code {
  flex: 1; background: var(--bg); border: 2px solid var(--accent);
  border-radius: 10px; padding: 18px 24px; font-family: var(--font-display);
  font-weight: 800; font-size: 28px; letter-spacing: 0.1em;
  color: var(--accent); text-align: center;
}
.ref-copy-btn {
  display: flex; align-items: center; gap: 6px; padding: 12px 18px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--border);
  border-radius: 8px; color: var(--fg-muted); font-size: 13px; font-weight: 500;
  font-family: var(--font-body); cursor: pointer; transition: all 0.15s; white-space: nowrap;
}
.ref-copy-btn:hover { background: rgba(255,255,255,0.1); color: var(--fg); }

/* Stats box */
.stats-box {
  display: flex; align-items: center; gap: 0;
  background: var(--bg); border: 1px solid var(--border); border-radius: 12px;
  overflow: hidden; margin-bottom: 24px;
}
.stat-item { flex: 1; padding: 24px; text-align: center; }
.stat-item .stat-val {
  font-family: var(--font-display); font-weight: 800; font-size: 36px;
  color: var(--fg); line-height: 1; margin-bottom: 8px;
}
.stat-item .stat-label { font-size: 12px; color: var(--fg-dim); letter-spacing: 0.05em; }
.stat-divider { width: 1px; height: 60px; background: var(--border); }

/* History */
.history-heading {
  font-family: var(--font-display); font-weight: 700; font-size: 16px;
  color: var(--fg); margin-bottom: 16px; letter-spacing: -0.01em;
}
.ref-table { width: 100%; border-collapse: collapse; }
.ref-table th {
  font-size: 11px; font-weight: 600; color: var(--fg-dim);
  letter-spacing: 0.08em; text-transform: uppercase;
  text-align: left; padding: 0 0 10px; border-bottom: 1px solid var(--border);
}
.ref-table td {
  font-size: 14px; color: var(--fg-muted); padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.credit-cell { color: var(--accent) !important; font-weight: 600; }

.status-badge {
  display: inline-block; padding: 3px 10px; border-radius: 100px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.04em;
}
.status-applied { background: rgba(10,191,156,0.1); color: var(--accent); }
.status-pending { background: rgba(244,166,54,0.1); color: var(--accent-warm); }
.status-activated { background: rgba(96,165,250,0.1); color: #60A5FA; }

/* === FAQ === */
.ref-faq { padding: 80px; }
.ref-faq-inner { max-width: 960px; margin: 0 auto; }
.ref-faq-inner h2 {
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(24px, 2.5vw, 36px); letter-spacing: -0.025em;
  color: var(--fg); margin-bottom: 48px;
}
.faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.faq-card { background: var(--bg-surface); padding: 32px; transition: background 0.2s; }
.faq-card:hover { background: var(--bg-card); }
.faq-icon { margin-bottom: 16px; }
.faq-card h3 { font-family: var(--font-display); font-weight: 700; font-size: 16px; color: var(--fg); margin-bottom: 8px; }
.faq-card p { font-size: 14px; color: var(--fg-muted); line-height: 1.65; font-weight: 300; }

/* === DASHBOARD CTA === */
.ref-dashboard-cta { background: var(--bg-surface); border-top: 1px solid var(--border); padding: 60px 80px; }
.ref-dashboard-inner { max-width: 960px; margin: 0 auto; }
.ref-dash-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px;
  padding: 40px; display: flex; align-items: center; gap: 40px;
}
.dash-card-left { flex: 1; }
.dash-card-left h3 { font-family: var(--font-display); font-weight: 700; font-size: 22px; color: var(--fg); margin-bottom: 8px; }
.dash-card-left p { font-size: 14px; color: var(--fg-muted); margin-bottom: 20px; }
.dash-lookup-form { display: flex; gap: 10px; }
.dash-lookup-form input {
  flex: 1; background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  padding: 12px 16px; font-size: 14px; color: var(--fg); font-family: var(--font-body); outline: none;
}
.dash-lookup-form input::placeholder { color: var(--fg-dim); }
.dash-lookup-form input:focus { border-color: rgba(10,191,156,0.4); }
.dash-card-icon { flex-shrink: 0; opacity: 0.7; }

/* === DASHBOARD PAGE === */
.dash-main { padding: 120px 80px 80px; max-width: 900px; margin: 0 auto; }
.dash-header { margin-bottom: 48px; }
.dash-greeting { font-size: 14px; color: var(--fg-muted); margin-bottom: 8px; }
.dash-greeting strong { color: var(--fg); }
.dash-header h1 {
  font-family: var(--font-display); font-weight: 900; font-size: clamp(32px, 3vw, 48px);
  letter-spacing: -0.03em; color: var(--fg);
}
.dash-grid { display: flex; flex-direction: column; gap: 24px; }
.dash-code-card {
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: 16px;
  padding: 32px; border-color: rgba(10,191,156,0.2); background: rgba(10,191,156,0.04);
}
.dash-section-label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 16px;
}
.dash-share-hint { font-size: 14px; color: var(--fg-muted); margin-top: 12px; line-height: 1.6; }
.dash-share-hint strong { color: var(--fg); }
.dash-stats-row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.dash-stat-card {
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: 12px;
  padding: 28px 24px; text-align: center;
}
.dash-stat-icon { margin-bottom: 12px; display: flex; justify-content: center; }
.dash-stat-val {
  font-family: var(--font-display); font-weight: 800; font-size: 36px;
  color: var(--fg); line-height: 1; margin-bottom: 8px;
}
.dash-stat-label { font-size: 12px; color: var(--fg-dim); line-height: 1.4; letter-spacing: 0.04em; }
.dash-stat-highlight { background: rgba(244,166,54,0.05); border-color: rgba(244,166,54,0.15); }
.dash-stat-sub {
  font-family: var(--font-body); font-weight: 500; font-size: 11px;
  color: var(--fg-muted); margin-top: 6px; letter-spacing: 0.02em;
}
.dash-history-card {
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: 12px; padding: 32px;
}
.dash-empty-card {
  background: var(--bg-surface); border: 1px dashed var(--border); border-radius: 12px;
  padding: 48px; text-align: center; display: flex; flex-direction: column;
  align-items: center; gap: 12px;
}
.dash-empty-card h3 { font-family: var(--font-display); font-weight: 700; font-size: 18px; color: var(--fg); }
.dash-empty-card p { font-size: 14px; color: var(--fg-dim); }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .ref-hero { padding: 100px 40px 60px; }
  .faq-grid { grid-template-columns: 1fr; }
  .dash-stats-row { grid-template-columns: 1fr; }
  .ref-dash-card { flex-direction: column; }
  .dash-card-icon { display: none; }
}
@media (max-width: 600px) {
  .ref-hero { padding: 90px 24px 50px; }
  .ref-signup { padding: 48px 24px; }
  .ref-faq { padding: 48px 24px; }
  .ref-dashboard-cta { padding: 48px 24px; }
  .dash-lookup-form { flex-direction: column; }
  .dash-main { padding: 90px 24px 48px; }
  .ref-code { font-size: 20px; }
  .stats-box { flex-direction: column; }
  .stat-divider { width: 80%; height: 1px; }
}