/* ==========================================================================
   Vegalabs — shared base styles
   ========================================================================== */

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

:root {
  --bg: #05060a;
  --bg-elevated: #0b0e16;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-border: rgba(255, 255, 255, 0.09);
  --text: #eef1f8;
  --text-dim: rgba(238, 241, 248, 0.66);
  --text-faint: rgba(238, 241, 248, 0.4);
  --accent-cyan: #4ce0d2;
  --accent-violet: #8b7bff;
  --accent-lime: #9dff6b;
  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 8px;
  --font-display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --container: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1em;
}

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

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
  white-space: nowrap;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-violet));
  color: #04050a;
  box-shadow: 0 10px 30px -10px rgba(139, 123, 255, 0.6);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -10px rgba(139, 123, 255, 0.75);
}

.btn-ghost {
  background: var(--surface);
  border-color: var(--surface-border);
  color: var(--text);
  backdrop-filter: blur(8px);
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

/* ---------- nav ---------- */

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 18px 0;
  transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
  border-bottom: 1px solid transparent;
}

.site-nav.is-scrolled {
  background: rgba(5, 6, 10, 0.72);
  border-bottom-color: var(--surface-border);
  backdrop-filter: blur(14px);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.brand-mark {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.brand-sub {
  font-weight: 500;
  color: var(--text-faint);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-left: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 0.94rem;
  color: var(--text-dim);
}

.nav-links a {
  transition: color 0.2s ease;
  position: relative;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-toggle {
  display: none;
}

@media (max-width: 720px) {
  .nav-links {
    display: none;
  }
}

@media (max-width: 480px) {
  .nav-actions .btn-ghost {
    display: none;
  }
  .nav-actions .btn {
    padding: 11px 18px;
    font-size: 0.88rem;
  }
}

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--surface-border);
  padding: 56px 0 32px;
  color: var(--text-dim);
  background: var(--bg-elevated);
  position: relative;
  z-index: 2;
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-brand {
  max-width: 320px;
}

.footer-brand .brand {
  margin-bottom: 12px;
}

.footer-cols {
  display: flex;
  gap: 64px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-faint);
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  color: var(--text-dim);
  font-size: 0.94rem;
  margin-bottom: 10px;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: var(--text);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--surface-border);
  font-size: 0.85rem;
  color: var(--text-faint);
}

/* ---------- legal pages ---------- */

body.page-legal {
  background:
    radial-gradient(55% 45% at 10% 0%, rgba(139, 123, 255, 0.12), transparent 60%),
    radial-gradient(45% 35% at 95% 15%, rgba(76, 224, 210, 0.09), transparent 60%),
    var(--bg);
}

.legal-page {
  position: relative;
  z-index: 2;
  padding: 160px 0 100px;
}

.legal-page .eyebrow {
  color: var(--accent-cyan);
}

.legal-page h1 {
  font-size: clamp(2.1rem, 4vw, 2.8rem);
  margin-bottom: 8px;
}

.legal-updated {
  color: var(--text-faint);
  font-size: 0.9rem;
  margin-bottom: 48px;
}

.legal-body {
  max-width: 760px;
}

.legal-body h2 {
  font-size: 1.35rem;
  margin-top: 2.4em;
}

.legal-body h2:first-of-type {
  margin-top: 0;
}

.legal-body h3 {
  font-size: 1.05rem;
  margin-top: 1.6em;
  color: var(--text);
}

.legal-body p,
.legal-body li {
  color: var(--text-dim);
  font-size: 0.98rem;
}

.legal-body ul {
  padding-left: 1.2em;
}

.legal-body li {
  margin-bottom: 0.5em;
}

.legal-body a {
  color: var(--accent-cyan);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-body strong {
  color: var(--text);
}

.legal-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin: 32px 0 56px;
  padding: 20px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.legal-toc a {
  font-size: 0.85rem;
  color: var(--text-dim);
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--surface-border);
  transition: all 0.2s ease;
}

.legal-toc a:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.25);
}

/* ---------- misc ---------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-cyan);
  margin-bottom: 18px;
}

.eyebrow::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 12px currentColor;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

@media (max-width: 640px) {
  .footer-row {
    flex-direction: column;
  }
  .footer-cols {
    gap: 32px;
  }
}
