/* ─── Reset & Base ─────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #0a1a0f;
  --bg-2:       #0d2e1e;
  --bg-3:       #08140c;
  --accent:     #d4a843;
  --accent-dim: #9c7a2f;
  --cream:      #f5f0e8;
  --cream-dim:  #c8c0b0;
  --muted:      rgba(245,240,232,0.35);
  --border:     rgba(212,168,67,0.15);
  --card-bg:    rgba(13,46,30,0.6);

  --font-display: 'Fraunces', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  --space-xs:  0.5rem;
  --space-sm:  1rem;
  --space-md:  2rem;
  --space-lg:  4rem;
  --space-xl:  7rem;
  --space-2xl: 10rem;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ─── Ambient Background ───────────────────────────── */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.amb-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.18;
}
.amb-glow-1 {
  width: 800px; height: 600px;
  top: -200px; left: -300px;
  background: radial-gradient(ellipse, #0d2e1e 0%, transparent 70%);
}
.amb-glow-2 {
  width: 600px; height: 500px;
  bottom: -100px; right: -200px;
  background: radial-gradient(ellipse, #d4a843 0%, transparent 70%);
  opacity: 0.06;
}
.amb-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(212,168,67,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(212,168,67,0.03) 1px, transparent 1px);
  background-size: 80px 80px;
}
.amb-noise {
  position: absolute;
  inset: 0;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* ─── Tag / Label utility ───────────────────────────── */
.tag, .hero-label, .manifesto-tag, .vector-tag, .reality-tag {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 0.3em 0.8em;
  border-radius: 2px;
  margin-bottom: var(--space-md);
}

/* ─── Hero ─────────────────────────────────────────── */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: var(--space-xl) var(--space-md);
}

.hero-inner {
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
}

.hero-label { margin-bottom: var(--space-sm); }

.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 5vw, 5.5rem);
  font-weight: 900;
  line-height: 1.05;
  color: var(--cream);
  margin-bottom: var(--space-md);
}
.hero-headline em {
  font-style: italic;
  font-weight: 300;
  color: var(--accent);
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--cream-dim);
  font-weight: 300;
  max-width: 480px;
  line-height: 1.7;
}

/* Dashboard Preview Card */
.hero-dashboard-preview {
  position: relative;
}

.dashboard-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  backdrop-filter: blur(12px);
  position: relative;
  overflow: hidden;
}
.dashboard-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.4;
}

.dash-label {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.2rem;
  font-weight: 500;
}

.dash-chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 80px;
  margin-bottom: 1.5rem;
}
.chart-bar {
  flex: 1;
  height: var(--h);
  background: rgba(212,168,67,0.12);
  border-radius: 3px 3px 0 0;
  transition: height 1s ease;
}
.chart-bar.active {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-dim) 100%);
}

.dash-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.metric { display: flex; flex-direction: column; gap: 2px; }
.metric-val {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--cream);
}
.metric-val.positive { color: #5aad87; }
.metric-key {
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}

/* Decorative lines */
.dashboard-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.line {
  position: absolute;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.06;
  height: 1px;
}
.l1 { width: 100%; top: -20px; }
.l2 { width: 80%; bottom: -15px; right: 0; }
.l3 { width: 60%; top: 50%; left: -30px; transform: rotate(-45deg); }
.l4 { width: 40%; top: 30%; right: -20px; transform: rotate(30deg); }

/* ─── Stats Row ────────────────────────────────────── */
.stats-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-lg);
  padding: var(--space-lg) var(--space-md);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: rgba(13,46,30,0.3);
}

.stat { text-align: center; }
.stat-number {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 0.4rem;
}
.stat-label {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}
.stat-divider {
  width: 1px;
  height: 60px;
  background: var(--border);
}

/* ─── Manifesto ────────────────────────────────────── */
.manifesto {
  position: relative;
  z-index: 1;
  padding: var(--space-xl) var(--space-md);
}
.manifesto-inner {
  max-width: 860px;
  margin: 0 auto;
}
.manifesto-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 700;
  color: var(--cream);
  line-height: 1.2;
  margin-bottom: var(--space-md);
}
.manifesto-body {
  font-size: 1.1rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.8;
  margin-bottom: 1.2rem;
}

/* ─── Vector Section ────────────────────────────────── */
.vector-section {
  position: relative;
  z-index: 1;
  padding: var(--space-xl) var(--space-md);
  background: var(--bg-3);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.vector-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
}

.vector-tag { margin-bottom: var(--space-sm); }
.vector-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.6rem);
  font-weight: 700;
  color: var(--cream);
  line-height: 1.2;
  margin-bottom: var(--space-md);
}
.vector-body {
  font-size: 1rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.8;
  margin-bottom: var(--space-md);
}

.vector-pillars {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.pillar {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.2rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(13,46,30,0.4);
  transition: border-color 0.3s ease, background 0.3s ease;
}
.pillar:hover {
  border-color: rgba(212,168,67,0.4);
  background: rgba(13,46,30,0.7);
}
.pillar-icon {
  flex-shrink: 0;
  color: var(--accent);
  margin-top: 2px;
}
.pillar-text { display: flex; flex-direction: column; gap: 3px; }
.pillar-text strong {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--cream);
}
.pillar-text span {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 300;
}

/* Constellation visual */
.vector-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
}
.constellation {
  position: relative;
  width: 320px;
  height: 320px;
}

.node {
  position: absolute;
  border-radius: 50%;
  background: var(--accent);
}
.n1 { width: 10px; height: 10px; top: 80px; left: 60px; box-shadow: 0 0 12px var(--accent); }
.n2 { width: 6px; height: 6px; top: 40px; left: 160px; box-shadow: 0 0 8px var(--accent); opacity: 0.8; }
.n3 { width: 8px; height: 8px; top: 140px; left: 20px; box-shadow: 0 0 10px var(--accent); opacity: 0.9; }
.n4 { width: 14px; height: 14px; top: 120px; left: 140px; box-shadow: 0 0 20px var(--accent); }
.n5 { width: 5px; height: 5px; top: 200px; left: 80px; box-shadow: 0 0 6px var(--accent); opacity: 0.7; }
.n6 { width: 9px; height: 9px; top: 240px; left: 200px; box-shadow: 0 0 12px var(--accent); opacity: 0.85; }
.n7 { width: 7px; height: 7px; top: 60px; left: 260px; box-shadow: 0 0 8px var(--accent); opacity: 0.75; }

.conn {
  position: absolute;
  background: linear-gradient(90deg, var(--accent-dim), var(--accent));
  opacity: 0.25;
  transform-origin: left center;
}
.c1 { width: 100px; height: 1px; top: 85px; left: 65px; transform: rotate(25deg); }
.c2 { width: 130px; height: 1px; top: 50px; left: 63px; transform: rotate(5deg); }
.c3 { width: 80px; height: 1px; top: 125px; left: 145px; transform: rotate(-50deg); }
.c4 { width: 110px; height: 1px; top: 195px; left: 25px; transform: rotate(40deg); }
.c5 { width: 90px; height: 1px; top: 205px; left: 85px; transform: rotate(-10deg); }
.c6 { width: 70px; height: 1px; top: 245px; left: 85px; transform: rotate(55deg); }

.data-flow { position: absolute; inset: 0; }
.flow {
  position: absolute;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  border-radius: 2px;
  animation: flowPulse 3s ease-in-out infinite;
}
.f1 { width: 60%; height: 2px; top: 45%; left: 20%; animation-delay: 0s; }
.f2 { width: 40%; height: 1px; top: 60%; left: 30%; animation-delay: 1s; opacity: 0.6; }
.f3 { width: 50%; height: 1px; top: 35%; left: 25%; animation-delay: 2s; opacity: 0.4; }

@keyframes flowPulse {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

.orbit-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--border);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}
.r1 { width: 200px; height: 200px; }
.r2 { width: 280px; height: 280px; border-style: dashed; opacity: 0.3; }

.center-glow {
  position: absolute;
  width: 30px; height: 30px;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  border-radius: 50%;
  box-shadow: 0 0 30px var(--accent), 0 0 60px rgba(212,168,67,0.3);
  animation: glowPulse 4s ease-in-out infinite;
}

@keyframes glowPulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
  50% { transform: translate(-50%, -50%) scale(1.3); opacity: 1; }
}

/* ─── Reality / Features ───────────────────────────── */
.reality { position: relative; z-index: 1; padding: var(--space-xl) var(--space-md); }
.reality-tag { margin-bottom: var(--space-md); }
.reality-inner { max-width: 1200px; margin: 0 auto; }
.reality-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}
.reality-card {
  padding: 2rem;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  backdrop-filter: blur(8px);
  transition: border-color 0.3s ease, transform 0.3s ease;
}
.reality-card:hover {
  border-color: rgba(212,168,67,0.35);
  transform: translateY(-2px);
}
.reality-icon {
  color: var(--accent);
  margin-bottom: 1.2rem;
}
.reality-card h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 0.8rem;
}
.reality-card p {
  font-size: 0.9rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.7;
}

/* ─── Closing ─────────────────────────────────────── */
.closing {
  position: relative;
  z-index: 1;
  padding: var(--space-xl) var(--space-md) var(--space-2xl);
  text-align: center;
}
.closing-inner { max-width: 900px; margin: 0 auto; }
.closing-headline {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 3.2rem);
  font-weight: 700;
  color: var(--cream);
  line-height: 1.2;
  margin-bottom: var(--space-md);
}
.closing-sub {
  font-size: 1.05rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.8;
  max-width: 680px;
  margin: 0 auto var(--space-lg);
}
.cta-text {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 400;
  font-style: italic;
  color: var(--accent);
  letter-spacing: 0.02em;
}

/* ─── Footer ───────────────────────────────────────── */
.site-footer {
  position: relative;
  z-index: 1;
  padding: var(--space-lg) var(--space-md);
  border-top: 1px solid var(--border);
  background: var(--bg-3);
}
.footer-inner { max-width: 1200px; margin: 0 auto; text-align: center; }
.footer-brand {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.footer-tagline { font-size: 0.85rem; color: var(--muted); margin-bottom: 0.5rem; font-weight: 300; }
.footer-meta { font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(245,240,232,0.2); }

/* ─── Responsive ──────────────────────────────────── */
@media (max-width: 768px) {
  .hero-inner,
  .vector-inner,
  .reality-grid { grid-template-columns: 1fr; }

  .hero { min-height: auto; padding: var(--space-lg) var(--space-sm); }
  .hero-dashboard-preview { display: none; }

  .stats-row { flex-direction: column; gap: var(--space-sm); }
  .stat-divider { width: 60px; height: 1px; }

  .vector-visual { min-height: 280px; }
  .constellation { width: 240px; height: 240px; }

  .reality-grid { grid-template-columns: 1fr; }

  .closing-headline br { display: none; }
}

/* ─── Sticky Header ────────────────────────────────── */
.sticky-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 2rem;
  background: rgba(10, 26, 15, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transform: translateY(-100%);
  transition: transform 0.3s ease;
}
.sticky-header.visible { transform: translateY(0); }

.sticky-brand {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
}

.sticky-actions { display: flex; gap: 0.75rem; align-items: center; }

.sticky-btn-primary,
.sticky-btn-secondary {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.5em 1.2em;
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.2s ease;
}
.sticky-btn-primary {
  background: var(--accent);
  color: #0a1a0f;
}
.sticky-btn-primary:hover { background: #e8c060; }
.sticky-btn-secondary {
  background: transparent;
  color: var(--cream);
  border: 1px solid var(--border);
}
.sticky-btn-secondary:hover {
  border-color: rgba(212,168,67,0.5);
  color: var(--accent);
}

/* ─── Hero CTA Row ──────────────────────────────────── */
.hero-cta-row {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.btn-primary, .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.75em 1.75em;
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: var(--accent);
  color: #0a1a0f;
}
.btn-primary:hover { background: #e8c060; transform: translateY(-1px); }
.btn-secondary {
  background: transparent;
  color: var(--cream);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  border-color: rgba(212,168,67,0.5);
  color: var(--accent);
}

/* ─── Signup Form Section ───────────────────────────── */
.signup-section {
  position: relative;
  z-index: 1;
  padding: var(--space-xl) var(--space-md);
  background: var(--bg-3);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.signup-inner {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}
.signup-tag {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 0.3em 0.8em;
  border-radius: 2px;
  margin-bottom: var(--space-sm);
}
.signup-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 700;
  color: var(--cream);
  line-height: 1.2;
  margin-bottom: 0.8rem;
}
.signup-sub {
  font-size: 1rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: var(--space-md);
}

/* ─── Form ──────────────────────────────────────────── */
.signup-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: left;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.form-group label {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--cream-dim);
  letter-spacing: 0.03em;
}
.label-opt {
  font-weight: 300;
  color: var(--muted);
}
.form-group input,
.form-group select {
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.7em 1em;
  background: rgba(13,46,30,0.8);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--cream);
  outline: none;
  transition: border-color 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
}
.form-group input::placeholder { color: var(--muted); }
.form-group input:focus,
.form-group select:focus {
  border-color: rgba(212,168,67,0.5);
}
.form-group select option { background: #0d2e1e; color: var(--cream); }

.form-error {
  font-size: 0.85rem;
  color: #e07070;
  padding: 0.6em 1em;
  background: rgba(200,60,60,0.12);
  border: 1px solid rgba(200,60,60,0.25);
  border-radius: 4px;
}

.btn-signup {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.85em 2em;
  background: var(--accent);
  color: #0a1a0f;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  margin-top: 0.5rem;
}
.btn-signup:hover:not(:disabled) { background: #e8c060; transform: translateY(-1px); }
.btn-signup:disabled { opacity: 0.6; cursor: not-allowed; }

/* Success state */
.signup-success {
  padding: 2.5rem 2rem;
  text-align: center;
}
.success-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px; height: 56px;
  background: rgba(90,173,135,0.15);
  border: 1px solid rgba(90,173,135,0.4);
  border-radius: 50%;
  color: #5aad87;
  margin: 0 auto 1.2rem;
}
.signup-success h3 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--cream);
  margin-bottom: 0.6rem;
}
.signup-success p {
  font-size: 0.95rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.6;
}
.signup-meta {
  margin-top: 1.2rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 300;
  letter-spacing: 0.03em;
}

/* ─── Standalone Signup Page ───────────────────────── */
.standalone-signup {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8rem var(--space-md) var(--space-lg);
}
.standalone-inner {
  width: 100%;
  max-width: 600px;
  text-align: center;
}
.standalone-badge {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 0.3em 0.8em;
  border-radius: 2px;
  margin-bottom: 1.5rem;
}
.standalone-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 900;
  color: var(--cream);
  line-height: 1.1;
  margin-bottom: 1rem;
}
.standalone-sub {
  font-size: 1rem;
  color: var(--cream-dim);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: var(--space-lg);
}

/* ─── Responsive ──────────────────────────────────── */
@media (max-width: 768px) {
  .form-row { grid-template-columns: 1fr; }
  .hero-cta-row { flex-direction: column; align-items: flex-start; }
  .sticky-header { padding: 0.7rem 1rem; }
}

@media (max-width: 480px) {
  .btn-primary, .btn-secondary { width: 100%; text-align: center; }
  .btn-signup { width: 100%; }
  .form-row { grid-template-columns: 1fr; }
}