/* ════════════════════════════════════════
   RankForm — Shared Stylesheet
   ════════════════════════════════════════ */

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

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink:       #07080d;
  --ink2:      #0f1018;
  --ink3:      #181921;
  --ink4:      #21222d;
  --ink5:      #2c2d3a;
  --border:    rgba(255,255,255,0.06);
  --border2:   rgba(255,255,255,0.11);
  --mist:      #52536a;
  --fog:       #9596b0;
  --text:      #c0c1d8;
  --white:     #eeeef8;
  --blue:      #4d88ff;
  --blue2:     #3a72e8;
  --blue-glow: rgba(77,136,255,0.2);
  --blue-dim:  rgba(77,136,255,0.08);
  --amber:     #f0a030;
  --amber-dim: rgba(240,160,48,0.09);
  --green:     #3ecf8e;
  --green-dim: rgba(62,207,142,0.08);
}

html { scroll-behavior: smooth; }

body {
  background: var(--ink);
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  min-height: 100vh;
}

/* ── Blobs ── */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(110px);
  pointer-events: none;
  z-index: 0;
}
.blob-1 {
  width: 700px; height: 700px;
  top: -250px; left: -180px;
  background: radial-gradient(circle, rgba(77,136,255,0.09) 0%, transparent 70%);
}
.blob-2 {
  width: 500px; height: 500px;
  top: 50%; right: -160px;
  background: radial-gradient(circle, rgba(240,160,48,0.06) 0%, transparent 70%);
}
.blob-3 {
  width: 450px; height: 450px;
  bottom: 5%; left: 15%;
  background: radial-gradient(circle, rgba(62,207,142,0.05) 0%, transparent 70%);
}

/* ── Layout ── */
.wrap {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 40px;
  position: relative;
  z-index: 1;
}

/* ════════════════════════════════════════
   NAV
   ════════════════════════════════════════ */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  border-bottom: 1px solid transparent;
  transition: background 0.35s, border-color 0.35s, backdrop-filter 0.35s;
}
nav.scrolled {
  background: rgba(7,8,13,0.88);
  border-color: var(--border2);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.nav-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 40px;
  height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-icon {
  width: 30px; height: 30px;
  background: var(--blue);
  border-radius: 7px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.logo-icon::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(145deg, rgba(255,255,255,0.22) 0%, transparent 55%);
}
.logo-icon svg { width: 16px; height: 16px; fill: white; position: relative; z-index: 1; }
.logo-text { font-size: 18px; font-weight: 700; color: var(--white); letter-spacing: -0.4px; }
.logo-text span { color: var(--blue); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--fog);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--white); }

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Language toggle */
.lang-toggle {
  display: flex;
  align-items: center;
  background: var(--ink3);
  border: 1px solid var(--border2);
  border-radius: 6px;
  overflow: hidden;
  font-size: 12px;
  font-weight: 600;
}
.lang-btn {
  padding: 6px 11px;
  color: var(--mist);
  cursor: pointer;
  transition: all 0.15s;
  border: none;
  background: transparent;
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
}
.lang-btn.active {
  background: var(--blue);
  color: white;
}
.lang-btn:not(.active):hover { color: var(--white); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  border-radius: 8px;
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  letter-spacing: 0.1px;
}
.btn-ghost { color: var(--fog); background: transparent; }
.btn-ghost:hover { color: var(--white); }
.btn-primary {
  background: var(--blue);
  color: white;
  box-shadow: 0 0 22px rgba(77,136,255,0.28);
}
.btn-primary:hover {
  background: var(--blue2);
  box-shadow: 0 0 36px rgba(77,136,255,0.42);
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--white);
  border: 1px solid var(--border2);
}
.btn-outline:hover { border-color: var(--blue); background: var(--blue-dim); }
.btn-lg { padding: 13px 28px; font-size: 15px; }

/* ════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════ */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  position: relative;
  z-index: 1;
}
.foot-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.foot-left { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.foot-links { display: flex; gap: 22px; flex-wrap: wrap; }
.foot-links a {
  font-size: 13px;
  font-weight: 500;
  color: var(--mist);
  text-decoration: none;
  transition: color 0.2s;
}
.foot-links a:hover { color: var(--white); }
.foot-copy { font-size: 13px; color: var(--mist); }
.foot-right {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--ink5);
}

/* ════════════════════════════════════════
   SHARED COMPONENTS
   ════════════════════════════════════════ */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: 1.4px;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.eyebrow::before { content: ''; width: 20px; height: 1.5px; background: var(--blue); border-radius: 1px; }

h1 {
  font-size: clamp(48px, 6.5vw, 84px);
  font-weight: 900;
  line-height: 1.0;
  letter-spacing: -2.5px;
  color: var(--white);
  margin-bottom: 28px;
}
h1 em {
  font-style: normal;
  background: linear-gradient(130deg, var(--blue) 0%, #99bfff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
h1 .muted { color: var(--mist); -webkit-text-fill-color: var(--mist); }

h2 {
  font-size: clamp(34px, 4.5vw, 58px);
  font-weight: 800;
  color: var(--white);
  letter-spacing: -2px;
  line-height: 1.05;
  margin-bottom: 20px;
}
h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.3px;
  margin-bottom: 10px;
}

.section { padding: 108px 0; position: relative; z-index: 1; }
.section-lead {
  font-size: 18px;
  font-weight: 300;
  color: var(--fog);
  max-width: 500px;
  line-height: 1.7;
}
.section-head { margin-bottom: 64px; }
.section-head.center { text-align: center; }
.section-head.center .section-lead { margin: 0 auto; }

/* Reveal animation */
.r { opacity: 0; transform: translateY(26px); transition: opacity 0.75s ease, transform 0.75s ease; }
.r.on { opacity: 1; transform: translateY(0); }
.r.d1 { transition-delay: 0.1s; }
.r.d2 { transition-delay: 0.2s; }
.r.d3 { transition-delay: 0.3s; }

/* Page intro hero (non-home pages) */
.page-hero {
  padding: 148px 0 72px;
  position: relative;
  z-index: 1;
  border-bottom: 1px solid var(--border);
}
.page-hero h1 { font-size: clamp(40px, 5vw, 64px); margin-bottom: 16px; }
.page-hero .sub {
  font-size: 18px;
  font-weight: 300;
  color: var(--fog);
  max-width: 520px;
  line-height: 1.7;
}

/* Placeholder card */
.placeholder-section {
  padding: 108px 0;
  position: relative;
  z-index: 1;
}
.placeholder-card {
  background: var(--ink2);
  border: 1px dashed var(--border2);
  border-radius: 14px;
  padding: 72px 40px;
  text-align: center;
}
.placeholder-card .ph-icon { font-size: 40px; margin-bottom: 20px; opacity: 0.4; }
.placeholder-card h3 { color: var(--mist); font-size: 18px; margin-bottom: 10px; }
.placeholder-card p { color: var(--ink5); font-size: 14px; }

/* CTA box */
.cta-box {
  background: var(--ink2);
  border: 1px solid var(--border2);
  border-radius: 20px;
  padding: 72px 64px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 60px;
  align-items: center;
  position: relative;
  overflow: hidden;
}
.cta-box::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, var(--blue), rgba(77,136,255,0) 60%);
}
.cta-glow {
  position: absolute; top: -120px; left: -80px;
  width: 500px; height: 400px;
  background: radial-gradient(ellipse, rgba(77,136,255,0.09) 0%, transparent 65%);
  pointer-events: none;
}
.cta-text h2 { margin-bottom: 14px; }
.cta-sub { font-size: 17px; font-weight: 300; color: var(--fog); line-height: 1.7; max-width: 480px; }
.cta-side { display: flex; flex-direction: column; align-items: center; gap: 14px; flex-shrink: 0; }
.cta-email { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--mist); text-align: center; }
.cta-note { font-size: 12.5px; color: var(--mist); text-align: center; line-height: 1.8; }

/* ════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════ */
@media (max-width: 960px) {
  .wrap, .nav-inner { padding: 0 24px; }
  .cta-box { grid-template-columns: 1fr; gap: 36px; padding: 44px 32px; }
  .cta-side { align-items: flex-start; }
  .cta-note { text-align: left; }
}
@media (max-width: 640px) {
  .nav-links { display: none; }
  /* Hide CTA button in nav on mobile — keep only lang toggle */
  .nav-right .btn { display: none; }
  /* Slightly smaller toggle on mobile */
  .lang-btn { padding: 7px 12px; font-size: 13px; }
  h1 { letter-spacing: -1.8px; }
  .foot-inner { flex-direction: column; align-items: flex-start; }
}

/* ── Cookie banner ── */
.cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 200;
  background: var(--ink2);
  border-top: 1px solid var(--border2);
  padding: 20px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}
.cookie-banner.visible { transform: translateY(0); }
.cookie-text {
  font-size: 13.5px;
  color: var(--fog);
  font-weight: 300;
  line-height: 1.6;
  max-width: 640px;
}
.cookie-text a {
  color: var(--blue);
  text-decoration: none;
}
.cookie-text a:hover { text-decoration: underline; }
.cookie-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.btn-cookie-accept {
  padding: 9px 20px;
  background: var(--blue);
  color: white;
  border: none;
  border-radius: 7px;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}
.btn-cookie-accept:hover { background: var(--blue2); }
.btn-cookie-decline {
  padding: 9px 20px;
  background: transparent;
  color: var(--fog);
  border: 1px solid var(--border2);
  border-radius: 7px;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.btn-cookie-decline:hover { color: var(--white); border-color: var(--mist); }
@media (max-width: 640px) {
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px 24px;
    gap: 16px;
  }
  .cookie-actions { width: 100%; }
  .btn-cookie-accept, .btn-cookie-decline { flex: 1; text-align: center; }
}
