/* ============================================================
   RankMate Waitlist Page — waitlist.css
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  background: #080e1a; color: #f1f5f9; min-height: 100vh;
  display: flex; flex-direction: column; overflow-x: hidden; line-height: 1.6;
}
a { text-decoration: none; }
img { display: block; max-width: 100%; }

:root {
  --accent: #3b82f6; --accent2: #2563eb;
  --lime: #a3e635;
  --n950: #080e1a; --n900: #0d1b2e; --n800: #102a43; --n700: #1e3a5f;
  --t1: #f1f5f9; --t2: #94a3b8; --t3: #64748b;
  --border: rgba(255,255,255,0.08); --border2: rgba(255,255,255,0.14);
  --card: rgba(255,255,255,0.04); --card2: rgba(255,255,255,0.07);
  --r-md: 12px; --r-lg: 16px; --r-xl: 20px; --r-full: 9999px;
  --red: #ef4444; --green: #22c55e;
}

/* ── Layout ── */
.wl-page {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 60px 24px 80px;
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%,   rgba(59,130,246,.18) 0%, transparent 70%),
    radial-gradient(ellipse 50% 40% at 10% 80%,  rgba(30,58,95,.6)    0%, transparent 60%),
    radial-gradient(ellipse 40% 35% at 90% 20%,  rgba(163,230,53,.05) 0%, transparent 60%),
    linear-gradient(180deg, #080e1a 0%, #0a0f1e 100%);
  position: relative;
}

/* ── Nav ── */
.wl-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 16px 28px; display: flex; align-items: center; justify-content: space-between;
  background: rgba(8,14,26,.85); backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}
.wl-nav-logo { display: flex; align-items: center; gap: 10px; }
.wl-nav-logo img { width: 32px; height: 32px; border-radius: 8px; }
.wl-nav-logo span { font-size: 18px; font-weight: 800; color: #fff; }
.wl-back { font-size: 13px; font-weight: 600; color: var(--t2); display: flex; align-items: center; gap: 6px; transition: color .2s; }
.wl-back:hover { color: #fff; }

/* ── Card ── */
.wl-card {
  background: rgba(255,255,255,.04); border: 1px solid var(--border2);
  border-radius: 24px; padding: 48px 44px; width: 100%; max-width: 520px;
  box-shadow: 0 32px 80px rgba(0,0,0,.5);
  position: relative; z-index: 1;
}

.wl-badge {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(59,130,246,.12); border: 1px solid rgba(59,130,246,.3);
  padding: 5px 14px; border-radius: var(--r-full);
  font-size: 12px; font-weight: 600; color: #93c5fd; margin-bottom: 20px;
}
.wl-badge .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); animation: pulse-dot 2s ease-out infinite; flex-shrink: 0; }
@keyframes pulse-dot { 0%{box-shadow:0 0 0 0 rgba(163,230,53,.6)} 100%{box-shadow:0 0 0 10px rgba(163,230,53,0)} }

.wl-title { font-size: clamp(26px, 4vw, 36px); font-weight: 800; line-height: 1.15; letter-spacing: -.8px; margin-bottom: 10px; }
.wl-title span { color: var(--accent); }
.wl-sub { font-size: 15px; color: var(--t2); line-height: 1.7; margin-bottom: 32px; }

/* social proof */
.wl-proof { display: flex; align-items: center; gap: 10px; margin-bottom: 30px; }
.wl-avatars { display: flex; }
.wl-av { width: 28px; height: 28px; border-radius: 50%; border: 2px solid #0d1b2e; background: var(--n700); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; margin-left: -6px; }
.wl-av:first-child { margin-left: 0; }
.wl-proof-text { font-size: 13px; color: var(--t2); }
.wl-proof-text strong { color: #fff; }

/* ── Form ── */
.wl-form { display: flex; flex-direction: column; gap: 14px; }
.wl-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.wl-field { display: flex; flex-direction: column; gap: 6px; }
.wl-label { font-size: 12px; font-weight: 700; color: var(--t2); text-transform: uppercase; letter-spacing: 1px; }
.wl-label span { color: var(--accent); }

.wl-input, .wl-select {
  background: rgba(255,255,255,.05); border: 1.5px solid var(--border2);
  border-radius: var(--r-md); padding: 13px 16px;
  font-size: 15px; font-weight: 500; color: #fff;
  font-family: inherit; width: 100%; outline: none;
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none; appearance: none;
}
.wl-input::placeholder { color: var(--t3); }
.wl-input:focus, .wl-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(59,130,246,.18);
}
.wl-input.error, .wl-select.error { border-color: var(--red); }
.wl-select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2394a3b8' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; cursor: pointer; }
.wl-select option { background: #0d1b2e; color: #f1f5f9; }

/* phone field */
.wl-phone-wrap { display: flex; gap: 8px; }
.wl-dial { flex: 0 0 120px; }
.wl-phone-input { flex: 1; }
.wl-phone-hint { font-size: 11px; color: var(--t3); margin-top: 4px; }
.wl-phone-hint span { color: #25D366; font-weight: 600; }

.wl-field-err { font-size: 12px; color: var(--red); margin-top: 2px; display: none; }
.wl-field-err.visible { display: block; }

/* ── Submit button ── */
.wl-btn {
  width: 100%; padding: 16px; border-radius: var(--r-full);
  background: var(--accent); color: #fff; font-size: 16px; font-weight: 700;
  font-family: inherit; border: none; cursor: pointer; margin-top: 6px;
  transition: all .2s; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.wl-btn:hover:not(:disabled) { background: var(--accent2); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(59,130,246,.45); }
.wl-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.wl-btn .spinner { width: 18px; height: 18px; border: 2.5px solid rgba(255,255,255,.3); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.wl-error-banner { background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); border-radius: var(--r-md); padding: 12px 16px; font-size: 14px; color: #fca5a5; display: none; }
.wl-error-banner.visible { display: block; }

/* ── Success state ── */
.wl-success { display: none; flex-direction: column; align-items: center; text-align: center; }
.wl-success.visible { display: flex; }
.wl-success-ico { font-size: 56px; margin-bottom: 16px; }
.wl-success-title { font-size: 28px; font-weight: 800; margin-bottom: 10px; }
.wl-success-sub { font-size: 15px; color: var(--t2); line-height: 1.7; margin-bottom: 28px; max-width: 380px; }

.wl-ref-box { background: rgba(255,255,255,.05); border: 1.5px solid var(--border2); border-radius: var(--r-lg); padding: 14px 16px; width: 100%; max-width: 420px; margin-bottom: 16px; }
.wl-ref-label { font-size: 11px; font-weight: 700; color: var(--t2); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.wl-ref-link-row { display: flex; align-items: center; gap: 8px; }
.wl-ref-url { flex: 1; font-size: 13px; font-weight: 600; color: #93c5fd; word-break: break-all; }
.wl-copy-btn {
  flex-shrink: 0; padding: 7px 14px; border-radius: var(--r-md);
  background: var(--card2); border: 1px solid var(--border2);
  color: #fff; font-size: 12px; font-weight: 700; font-family: inherit;
  cursor: pointer; transition: all .2s; white-space: nowrap;
}
.wl-copy-btn:hover { background: rgba(255,255,255,.12); }
.wl-copy-btn.copied { background: rgba(34,197,94,.15); border-color: rgba(34,197,94,.3); color: #86efac; }

.wl-share-row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-bottom: 24px; }
.wl-share-wa {
  display: flex; align-items: center; gap: 8px;
  background: #25D366; color: #fff; padding: 12px 22px;
  border-radius: var(--r-full); font-size: 14px; font-weight: 700;
  cursor: pointer; border: none; font-family: inherit; transition: all .2s;
}
.wl-share-wa:hover { background: #1ebe5d; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(37,211,102,.35); }
.wl-share-copy {
  display: flex; align-items: center; gap: 8px;
  background: var(--card2); color: #fff; padding: 12px 22px;
  border-radius: var(--r-full); font-size: 14px; font-weight: 700;
  cursor: pointer; border: 1px solid var(--border2); font-family: inherit; transition: all .2s;
}
.wl-share-copy:hover { background: rgba(255,255,255,.1); }

.wl-back-home { font-size: 14px; color: var(--t2); display: flex; align-items: center; gap: 6px; transition: color .2s; cursor: pointer; background: none; border: none; font-family: inherit; }
.wl-back-home:hover { color: #fff; }

/* referrer banner (shown when arriving via ref link) */
.wl-ref-banner {
  display: none; align-items: center; gap: 10px;
  background: rgba(163,230,53,.08); border: 1px solid rgba(163,230,53,.2);
  border-radius: var(--r-lg); padding: 12px 16px; margin-bottom: 20px;
  font-size: 13px; color: var(--t2);
}
.wl-ref-banner.visible { display: flex; }
.wl-ref-banner strong { color: #d9f99d; }

/* ── Footer ── */
.wl-footer { text-align: center; padding: 24px; font-size: 12px; color: var(--t3); }
.wl-footer a { color: var(--t3); transition: color .2s; }
.wl-footer a:hover { color: #fff; }

/* ── Responsive ── */
@media (max-width: 560px) {
  .wl-card { padding: 32px 22px; border-radius: 20px; }
  .wl-row { grid-template-columns: 1fr; }
  .wl-phone-wrap { flex-direction: column; }
  .wl-dial { flex: none; }
}
