/* ============================================
   CSS VARIABLES & RESET
   ============================================ */
:root {
  --bg-primary: #0c0c0e;
  --bg-secondary: #111113;
  --bg-card: #151517;
  --bg-card-hover: #1b1b1e;
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-hover: rgba(245, 158, 11, 0.35);
  --text-primary: #f4f4f5;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --accent: #f59e0b;
  --accent-bright: #fbbf24;
  --accent-glow: rgba(245, 158, 11, 0.14);
  --accent-glow-soft: rgba(245, 158, 11, 0.07);
  --curve-blue: #60aed6;
  --font-body: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'Geist Mono', 'JetBrains Mono', 'SF Mono', monospace;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

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

button, input {
  font-family: inherit;
  border: none;
  outline: none;
  background: none;
}

/* ============================================
   BACKGROUND
   ============================================ */
.bg-mesh {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.bg-mesh::before {
  content: '';
  position: absolute;
  width: 120vw;
  height: 120vh;
  top: -20%;
  left: -10%;
  background:
    radial-gradient(ellipse 640px 560px at 22% 24%, rgba(245, 158, 11, 0.055) 0%, transparent 70%),
    radial-gradient(ellipse 520px 480px at 82% 18%, rgba(96, 174, 214, 0.045) 0%, transparent 70%),
    radial-gradient(ellipse 800px 420px at 50% 82%, rgba(245, 158, 11, 0.035) 0%, transparent 70%);
  animation: meshDrift 22s ease-in-out infinite alternate;
}

.bg-mesh::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  background-size: 256px 256px;
  opacity: 0.5;
}

@keyframes meshDrift {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-2%, 3%) scale(1.02); }
  100% { transform: translate(2%, -2%) scale(1); }
}

/* Grid overlay */
.bg-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 30%, black 20%, transparent 70%);
}

/* ============================================
   LAYOUT
   ============================================ */
.page-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

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

/* ============================================
   HEADER
   ============================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 24px;
  background: rgba(12, 12, 14, 0.75);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  border-bottom: 1px solid var(--border-subtle);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  width: 30px;
  height: 30px;
  display: block;
}

.logo-wordmark {
  font-family: var(--font-body);
  font-weight: 650;
  font-size: 1.2rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1;
}

.header-cta {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--bg-primary);
  letter-spacing: -0.01em;
  padding: 9px 18px;
  border-radius: 8px;
  background: var(--accent);
  cursor: pointer;
  transition: all 0.3s var(--ease-out-expo);
}

.header-cta:hover {
  background: var(--accent-bright);
  box-shadow: 0 0 24px rgba(245, 158, 11, 0.25);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  margin-top: auto;
  padding: 48px 24px;
  border-top: 1px solid var(--border-subtle);
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-legal {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-family: var(--font-mono);
  letter-spacing: -0.01em;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 0.78rem;
  color: var(--text-muted);
  transition: color 0.3s ease;
  font-family: var(--font-mono);
  letter-spacing: -0.01em;
}

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

.footer-links a::after {
  content: '';
  display: block;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.3s var(--ease-out-expo);
}

.footer-links a:hover::after {
  width: 100%;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .header-inner {
    height: 56px;
  }
}
