/* ================================================================
   DopaFlow Landing Page — Full Rebuild
   ================================================================ */

:root {
  --bg:              #07070f;
  --surface:         #0f0f1c;
  --surface-raised:  #15152a;
  --surface-glass:   rgba(255,255,255,0.03);
  --accent:          #6366f1;
  --accent-glow:     rgba(99,102,241,0.35);
  --accent-warm:     #f59e0b;
  --accent-cyan:     #06b6d4;
  --accent-green:    #10b981;
  --text:            #eef2ff;
  --text-muted:      #7c8ba0;
  --text-faint:      #343a4a;
  --border:          #1a1c2e;
  --border-light:    #252840;

  --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a855f7 100%);
  --gradient-warm:    linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  --gradient-cool:    linear-gradient(135deg, #06b6d4 0%, #6366f1 100%);

  --font-display: 'Space Grotesk', sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   14px;
  --radius-xl:   20px;
  --radius-2xl:  28px;
  --radius-full: 100px;

  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --tr:          0.25s ease;
  --tr-fast:     0.15s ease;

  --shadow-card: 0 2px 24px rgba(0,0,0,0.4), 0 0 0 1px var(--border);
  --shadow-glow: 0 0 48px rgba(99,102,241,0.18);
}

/* ================================================================
   RESET / BASE
   ================================================================ */

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

html { scroll-behavior: smooth; }

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

code {
  font-family: var(--font-mono);
  font-size: 0.85em;
  background: var(--surface-raised);
  padding: 0.1em 0.4em;
  border-radius: 4px;
  color: var(--text-muted);
}

.sr-only {
  position: absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0;
}

/* ================================================================
   BACKGROUND
   ================================================================ */

#particle-canvas {
  position: fixed; inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
}

.bg-grid {
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(99,102,241,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99,102,241,0.02) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none;
  z-index: 0;
}

.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(130px);
  pointer-events: none;
  z-index: 0;
}

.bg-glow-1 {
  width: 800px; height: 800px;
  top: -300px; right: -200px;
  background: #6366f1;
  opacity: 0.07;
  animation: glow-1 24s ease-in-out infinite;
}

.bg-glow-2 {
  width: 600px; height: 600px;
  bottom: -250px; left: -150px;
  background: #f59e0b;
  opacity: 0.055;
  animation: glow-2 30s ease-in-out infinite reverse;
}

.bg-glow-3 {
  width: 450px; height: 450px;
  top: 55vh; left: 45vw;
  background: #06b6d4;
  opacity: 0.045;
  animation: glow-3 20s ease-in-out infinite;
}

@keyframes glow-1 {
  0%,100% { transform: translate(0,0) scale(1); }
  50%      { transform: translate(60px,50px) scale(1.1); }
}
@keyframes glow-2 {
  0%,100% { transform: translate(0,0) scale(1); }
  50%      { transform: translate(-50px,30px) scale(0.9); }
}
@keyframes glow-3 {
  0%,100% { transform: scale(1); }
  50%      { transform: scale(1.3) translate(30px,-20px); }
}

/* ================================================================
   NAVIGATION
   ================================================================ */

.back-link {
  position: fixed; top: 1.5rem; left: 1.5rem;
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  z-index: 100;
  padding: 0.45rem 0.9rem;
  background: rgba(10,10,20,0.7);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  transition: all var(--tr-fast);
}

.back-link:hover { color: var(--accent); border-color: var(--accent); }

/* ================================================================
   HERO
   ================================================================ */

.hero-section {
  position: relative; z-index: 1;
  display: flex;
  align-items: center;
  gap: 4rem;
  max-width: 1340px;
  margin: 0 auto;
  padding: 8rem 2.5rem 4rem;
  min-height: 100vh;
}

.hero-content { flex: 1; min-width: 0; }

.hero-visual {
  flex: 0 0 auto;
  width: 530px;
  position: relative;
}

/* badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: var(--surface-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1.75rem;
}

.badge-dot {
  width: 7px; height: 7px;
  background: var(--accent-green);
  border-radius: 50%;
  animation: pulse-dot 2.5s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%,100% { opacity:1; transform:scale(1); }
  50%      { opacity:0.5; transform:scale(0.75); }
}

h1 {
  font-size: clamp(2.75rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin-bottom: 1.5rem;
}

.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 540px;
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

.cta-group {
  display: flex;
  gap: 0.875rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.hero-note {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-faint);
}

/* ================================================================
   BUTTONS
   ================================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--tr);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  border: none;
  box-shadow: 0 4px 22px rgba(99,102,241,0.38);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(99,102,241,0.55);
}

.btn-secondary {
  background: var(--surface-raised);
  color: var(--text);
  border-color: var(--border-light);
}

.btn-secondary:hover {
  border-color: var(--accent);
  background: var(--surface);
}

.price-tag {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  background: rgba(255,255,255,0.18);
  padding: 0.1rem 0.45rem;
  border-radius: 4px;
}

/* ================================================================
   APP FRAME (MOCKUP)
   ================================================================ */

.app-frame {
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid var(--border-light);
  box-shadow:
    0 48px 96px rgba(0,0,0,0.6),
    0 0 0 1px rgba(99,102,241,0.12),
    inset 0 1px 0 rgba(255,255,255,0.04);
  overflow: hidden;
  transform: perspective(1400px) rotateY(-9deg) rotateX(4deg) rotateZ(0.5deg);
  transition: transform 0.6s var(--ease-out), box-shadow 0.6s var(--ease-out);
  will-change: transform;
}

.app-frame:hover {
  transform: perspective(1400px) rotateY(-2deg) rotateX(1deg) rotateZ(0deg);
  box-shadow:
    0 60px 120px rgba(0,0,0,0.5),
    0 0 0 1px rgba(99,102,241,0.25),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

/* Titlebar */
.app-titlebar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.875rem;
  background: #0a0a16;
  border-bottom: 1px solid var(--border);
}

.app-dots { display:flex; gap:6px; }

.dot-red, .dot-yellow, .dot-green {
  width: 10px; height: 10px; border-radius: 50%;
}
.dot-red    { background: #ff5f57; }
.dot-yellow { background: #ffbd2e; }
.dot-green  { background: #28c840; }

.app-title-text {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
}

.app-xp {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--accent-warm);
  background: rgba(245,158,11,0.1);
  border: 1px solid rgba(245,158,11,0.2);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

/* Body */
.app-body {
  display: flex;
  height: 306px;
}

/* Sidebar */
.app-sidebar {
  width: 44px;
  background: #0a0a16;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.65rem 0;
  gap: 0.2rem;
}

.sn {
  width: 30px; height: 30px;
  background: none;
  border: none;
  border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  cursor: default;
  color: var(--text-faint);
  transition: all var(--tr-fast);
}
.sn svg { width: 13px; height: 13px; }
.sn.active { background: rgba(99,102,241,0.14); color: var(--accent); }

/* Main content */
.app-main {
  flex: 1;
  padding: 0.75rem 0.8rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  min-width: 0;
}

.app-greeting {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.1rem;
}

.greeting-text {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.greeting-date {
  font-size: 0.6rem;
  font-family: var(--font-mono);
  color: var(--text-faint);
}

.app-section-label {
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--font-mono);
  color: var(--text-faint);
}

/* Task list */
.task-list { display:flex; flex-direction:column; gap:0.3rem; }

.mock-task {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.45rem;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 5px;
  font-size: 0.68rem;
  color: var(--text);
}

.mock-task.done { opacity: 0.45; }
.mock-task.done .task-text { text-decoration: line-through; }

.mock-task.active {
  border-color: rgba(99,102,241,0.3);
  background: rgba(99,102,241,0.05);
}

.task-check {
  width: 13px; height: 13px;
  border-radius: 3px;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}

.task-check.checked {
  background: var(--accent-green);
  color: white;
}
.task-check.checked svg { width: 8px; height: 8px; }
.task-check.empty { border: 1.5px solid var(--border-light); }

.task-check.pulse-ring {
  border: 1.5px solid var(--accent);
  animation: ring-pulse 2s ease-in-out infinite;
}

@keyframes ring-pulse {
  0%,100% { border-color: var(--accent); box-shadow: 0 0 0 0 rgba(99,102,241,0.5); }
  50%      { border-color: #818cf8; box-shadow: 0 0 0 3px rgba(99,102,241,0); }
}

.task-text { flex: 1; min-width: 0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

.task-tag {
  font-family: var(--font-mono);
  font-size: 0.56rem;
  padding: 0.08rem 0.3rem;
  border-radius: 3px;
  flex-shrink: 0;
}

.task-tag.routine { background: rgba(16,185,129,0.1); color: var(--accent-green); }
.task-tag.review  { background: rgba(99,102,241,0.1); color: var(--accent); }

.task-priority {
  color: var(--accent-warm);
  font-weight: 700;
  font-size: 0.7rem;
  flex-shrink: 0;
}

/* Habit row */
.habit-row {
  display: flex;
  gap: 0.6rem;
  flex-wrap: nowrap;
}

.habit-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}

.habit-ring {
  position: relative;
  width: 34px; height: 34px;
}

.habit-ring svg {
  width: 34px; height: 34px;
}

.habit-streak {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-mono);
  font-size: 0.52rem;
  font-weight: 600;
  color: var(--text);
}

.habit-name {
  font-size: 0.52rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.ring-arc {
  animation: ring-draw 1.4s var(--ease-out) both;
}

@keyframes ring-draw {
  from { stroke-dasharray: 0 94.25; }
}

/* Side panel */
.app-panel {
  width: 96px;
  background: #0a0a16;
  border-left: 1px solid var(--border);
  padding: 0.75rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  flex-shrink: 0;
}

/* Focus widget */
.focus-widget { display:flex; flex-direction:column; align-items:center; gap:0.25rem; }

.focus-label, .momentum-label, .xp-label {
  font-size: 0.56rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--font-mono);
  color: var(--text-faint);
}

.focus-timer-wrap {
  position: relative;
  width: 56px; height: 56px;
}

.focus-ring-svg {
  width: 56px; height: 56px;
}

.focus-arc {
  animation: arc-pulse 1s ease-in-out infinite;
}

@keyframes arc-pulse {
  0%,100% { opacity: 1; }
  50%      { opacity: 0.75; }
}

.focus-time {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
}

.focus-task-name {
  font-size: 0.52rem;
  font-family: var(--font-mono);
  color: var(--text-faint);
  text-align: center;
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Momentum */
.momentum-widget { display:flex; flex-direction:column; align-items:center; gap:0.3rem; }

.momentum-bar-wrap {
  width: 78px; height: 5px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}

.momentum-fill {
  height: 100%;
  background: var(--gradient-primary);
  border-radius: 3px;
  animation: momentum-pulse 3s ease-in-out infinite;
}

@keyframes momentum-pulse {
  0%,100% { opacity:1; }
  50%      { opacity:0.6; }
}

.momentum-score {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent);
}

/* XP widget */
.xp-widget { display:flex; flex-direction:column; gap:0.3rem; }

.xp-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.xp-sub {
  font-size: 0.5rem;
  font-family: var(--font-mono);
  color: var(--text-faint);
}

.xp-bar-wrap {
  width: 78px; height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.xp-fill {
  height: 100%;
  background: var(--accent-warm);
  border-radius: 2px;
  animation: xp-glow 2s ease-in-out infinite;
}

@keyframes xp-glow {
  0%,100% { opacity:1; }
  50%      { opacity:0.7; }
}

/* Floating callout chips */
.callout {
  position: absolute;
  background: var(--surface-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  padding: 0.35rem 0.75rem;
  white-space: nowrap;
  pointer-events: none;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.callout-1 {
  bottom: -14px; left: 18%;
  animation: chip-float 4s ease-in-out infinite;
}

.callout-2 {
  top: 30%; right: -10px;
  animation: chip-float 5s ease-in-out 0.8s infinite;
}

.callout-3 {
  bottom: 22%; left: -16px;
  animation: chip-float 4.5s ease-in-out 1.6s infinite;
}

@keyframes chip-float {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}

/* ================================================================
   STATS BAR
   ================================================================ */

.stats-section {
  position: relative; z-index: 1;
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2.5rem 6rem;
}

.stats-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  background: var(--surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-2xl);
  padding: 1.75rem 2rem;
  gap: 0;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0 2.5rem;
}

.stat-num {
  font-family: var(--font-mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}

.stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.stat-divider {
  width: 1px;
  height: 44px;
  background: var(--border);
}

/* ================================================================
   PHILOSOPHY SECTION
   ================================================================ */

.philosophy-section {
  position: relative; z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.philosophy-inner {
  position: relative;
}

.philosophy-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 1rem;
  text-align: center;
}

.philosophy-inner > h2 {
  font-size: clamp(1.75rem, 4vw, 2.6rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
  text-align: center;
  margin-bottom: 3.5rem;
}

.philosophy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.25rem;
}

.philosophy-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all 0.3s var(--ease-out);
}

.philosophy-card:hover {
  border-color: var(--border-light);
  transform: translateY(-3px);
  background: var(--surface-raised);
}

.phi-icon {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  display: block;
  line-height: 1;
  opacity: 0.8;
}

.philosophy-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--text);
}

.philosophy-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.72;
}

/* ================================================================
   FEATURES SECTION
   ================================================================ */

.features-section {
  position: relative; z-index: 1;
  max-width: 1340px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin-bottom: 1rem;
}

.section-header p {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(285px, 1fr));
  gap: 1.25rem;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all 0.3s var(--ease-out);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--tr);
  pointer-events: none;
  mix-blend-mode: overlay;
}

.feature-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.feature-card:hover::before { opacity: 0.04; }

.feature-icon-wrap {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem;
}
.feature-icon-wrap svg { width: 22px; height: 22px; }

.icon-tasks        { background: rgba(99,102,241,0.14); color: var(--accent); }
.icon-habits       { background: rgba(16,185,129,0.14); color: var(--accent-green); }
.icon-focus        { background: rgba(6,182,212,0.14);  color: var(--accent-cyan); }
.icon-journal      { background: rgba(245,158,11,0.14); color: var(--accent-warm); }
.icon-calendar     { background: rgba(139,92,246,0.14); color: #8b5cf6; }
.icon-review       { background: rgba(99,102,241,0.14); color: var(--accent); }
.icon-alarms       { background: rgba(239,68,68,0.14);  color: #ef4444; }
.icon-packy        { background: rgba(6,182,212,0.14);  color: var(--accent-cyan); }
.icon-digest       { background: rgba(16,185,129,0.14); color: var(--accent-green); }
.icon-gamification { background: rgba(245,158,11,0.14); color: var(--accent-warm); }

.feature-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.feature-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.feature-tags {
  display: flex; gap: 0.4rem; flex-wrap: wrap;
}

.feature-tags span {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  padding: 0.18rem 0.5rem;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-muted);
}

/* ================================================================
   COGNITION / PACKY SECTION
   ================================================================ */

.cognition-section {
  position: relative; z-index: 1;
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.cognition-header {
  text-align: center;
  margin-bottom: 4rem;
}

.cognition-header h2 {
  font-size: clamp(1.75rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 1rem 0 1.25rem;
}

.cognition-desc {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.8;
  max-width: 600px;
  margin: 0 auto;
}

.cognition-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

/* ---- Association Graph ---- */

.assoc-graph-wrap {
  position: relative;
}

.assoc-graph {
  width: 100%;
  max-width: 460px;
  display: block;
  margin: 0 auto;
  overflow: visible;
}

/* Lines */
.assoc-line {
  stroke: rgba(99,102,241,0.25);
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
}

.assoc-line-far {
  stroke: rgba(99,102,241,0.08);
  stroke-width: 1;
  stroke-dasharray: 3 5;
}

.al-slow { animation: dash-scroll 8s linear infinite; }
.al-med  { animation: dash-scroll 5s linear infinite; }
.al-fast { animation: dash-scroll 3s linear infinite; }

@keyframes dash-scroll {
  to { stroke-dashoffset: -48; }
}

/* Pulse lines */
.pulse-line {
  stroke: rgba(99,102,241,0);
  stroke-width: 2;
  stroke-linecap: round;
}

.pulse-line.firing {
  stroke: rgba(99,102,241,0.6);
  animation: pulse-travel 0.8s ease-out both;
}

@keyframes pulse-travel {
  0%   { stroke-dashoffset: 200; stroke-dasharray: 200; opacity:1; }
  100% { stroke-dashoffset: 0;   stroke-dasharray: 200; opacity:0; }
}

/* Nodes */
.assoc-node-far {
  fill: rgba(99,102,241,0.12);
  stroke: rgba(99,102,241,0.2);
  stroke-width: 1;
}

.assoc-node-group {
  animation: node-breathe 4s ease-in-out var(--delay, 0s) infinite;
}

@keyframes node-breathe {
  0%,100% { opacity: 0.7; }
  50%      { opacity: 1; }
}

.assoc-node {
  fill: var(--surface-raised);
  stroke: rgba(99,102,241,0.35);
  stroke-width: 1.5;
}

.assoc-label {
  fill: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
  font-size: 7px;
  text-anchor: middle;
  dominant-baseline: middle;
  pointer-events: none;
}

/* Hub */
.hub-ring {
  fill: none;
  stroke: rgba(99,102,241,0.4);
  stroke-width: 1.5;
  stroke-dasharray: 6 3;
  animation: hub-spin 20s linear infinite;
}

@keyframes hub-spin {
  to { stroke-dashoffset: -300; }
}

.hub-core {
  fill: rgba(99,102,241,0.12);
  stroke: var(--accent);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 10px rgba(99,102,241,0.4));
}

.hub-label {
  fill: var(--text);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: middle;
}

.hub-sublabel {
  fill: var(--text-faint);
  font-family: 'JetBrains Mono', monospace;
  font-size: 7px;
  text-anchor: middle;
}

/* Surfaced memory card */
.surfaced-card {
  background: var(--surface-raised);
  border: 1px solid rgba(99,102,241,0.3);
  border-radius: var(--radius-lg);
  padding: 1rem 1.25rem;
  margin-top: 1.25rem;
  animation: surface-appear 0.5s var(--ease-out) 1.8s both;
  box-shadow: 0 0 24px rgba(99,102,241,0.1);
}

@keyframes surface-appear {
  from { opacity:0; transform:translateY(10px); }
  to   { opacity:1; transform:translateY(0); }
}

.surfaced-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.surfaced-icon { font-size: 0.9rem; }

.surfaced-title {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  flex: 1;
}

.surfaced-age {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-faint);
}

.surfaced-body {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
  line-height: 1.6;
  margin-bottom: 0.6rem;
  padding-left: 0.5rem;
  border-left: 2px solid rgba(99,102,241,0.3);
}

.surfaced-source {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.25rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--text-faint);
}

.surfaced-match em { color: var(--accent-cyan); font-style: normal; }

/* ---- Right side ---- */

.cognition-right {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

/* Compare */
.cog-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.cog-col {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}

.cog-col.cog-good {
  border-color: var(--accent);
  background: rgba(99,102,241,0.04);
}

.cog-col-label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  margin-bottom: 1rem;
}

.cog-example {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.875rem;
}
.cog-example:last-child { margin-bottom: 0; }

.cog-query {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  background: var(--surface);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.cog-result {
  font-size: 0.75rem;
  line-height: 1.5;
  padding: 0.35rem 0.5rem;
  border-radius: 4px;
}

.cog-result.fail {
  color: var(--text-faint);
  background: rgba(239,68,68,0.05);
  border: 1px solid rgba(239,68,68,0.12);
}

.cog-result.fail strong { color: rgba(239,68,68,0.7); }

.cog-result.pass {
  color: var(--text-muted);
  background: rgba(16,185,129,0.05);
  border: 1px solid rgba(16,185,129,0.15);
}

.cog-result.pass em { color: var(--accent-cyan); font-style: normal; }

/* Rules */
.cog-rules {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.cog-rule {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.cog-rule-icon { font-size: 1.25rem; flex-shrink: 0; margin-top: 0.1rem; }

.cog-rule strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--text);
}

.cog-rule p {
  font-size: 0.835rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ================================================================
   VOICE SECTION
   ================================================================ */

.voice-section {
  position: relative; z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.voice-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

/* Left col */
.voice-left h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 1rem 0 1.5rem;
}

.voice-desc {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 2rem;
  max-width: 440px;
}

.voice-destinations {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 2rem;
}

.dest-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 500;
  border: 1px solid transparent;
  width: fit-content;
}

.dest-chip svg { width: 15px; height: 15px; flex-shrink: 0; }

.dest-tasks    { background: rgba(99,102,241,0.1);  border-color: rgba(99,102,241,0.2);  color: #a5b4fc; }
.dest-journal  { background: rgba(245,158,11,0.1);  border-color: rgba(245,158,11,0.2);  color: #fcd34d; }
.dest-calendar { background: rgba(139,92,246,0.1);  border-color: rgba(139,92,246,0.2);  color: #c4b5fd; }
.dest-focus    { background: rgba(6,182,212,0.1);   border-color: rgba(6,182,212,0.2);   color: #67e8f9; }

/* Flow indicator */
.voice-flow {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.flow-step {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-faint);
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  transition: all 0.4s ease;
}

.flow-step.active {
  color: var(--accent);
  border-color: var(--accent);
  background: rgba(99,102,241,0.08);
}

.flow-arrow {
  color: var(--text-faint);
  font-size: 0.75rem;
}

/* Terminal */
.voice-terminal {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow:
    0 32px 64px rgba(0,0,0,0.4),
    0 0 0 1px rgba(99,102,241,0.1);
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1rem;
  background: #0a0a16;
  border-bottom: 1px solid var(--border);
}

.terminal-title {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
}

.mic-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.mic-dot {
  width: 7px; height: 7px;
  background: var(--accent-green);
  border-radius: 50%;
  animation: mic-blink 1.2s ease-in-out infinite;
}

@keyframes mic-blink {
  0%,100% { opacity:1; transform:scale(1); }
  50%      { opacity:0.4; transform:scale(0.75); }
}

.mic-label {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--accent-green);
}

.terminal-body {
  padding: 1.5rem;
  min-height: 200px;
}

/* Voice example */
.voice-example { display: none; }
.voice-example.active { display: block; }

.ve-input {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--surface-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 0.8rem 1rem;
  margin-bottom: 1rem;
}

.ve-icon { font-size: 1rem; flex-shrink: 0; }

.ve-text {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text);
  flex: 1;
  min-height: 1.2em;
}

.ve-cursor {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 1rem;
  animation: blink-cursor 1s step-end infinite;
}

@keyframes blink-cursor {
  0%,100% { opacity:1; }
  50%      { opacity:0; }
}

.ve-preview {
  display: none;
  animation: fadeInUp 0.3s ease-out both;
}

.ve-preview-label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  margin-bottom: 0.5rem;
}

.ve-preview-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.875rem 1rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 0.75rem;
  min-height: 2.5rem;
}

.ve-preview-card strong {
  color: var(--text);
  font-weight: 600;
}

.ve-confirm-row {
  display: flex;
  gap: 0.5rem;
}

.ve-btn-confirm, .ve-btn-cancel {
  padding: 0.4rem 1rem;
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  cursor: default;
  border: 1px solid transparent;
}

.ve-btn-confirm {
  background: var(--gradient-primary);
  color: white;
  border: none;
}

.ve-btn-cancel {
  background: var(--surface-raised);
  color: var(--text-muted);
  border-color: var(--border);
}

/* Nav tabs */
.terminal-examples-nav {
  display: flex;
  gap: 0;
  border-top: 1px solid var(--border);
}

.teg {
  flex: 1;
  padding: 0.65rem 0.5rem;
  background: none;
  border: none;
  border-right: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-faint);
  cursor: pointer;
  transition: all var(--tr-fast);
  text-align: center;
}

.teg:last-child { border-right: none; }
.teg:hover { color: var(--text-muted); background: var(--surface-raised); }
.teg.active { color: var(--accent); background: rgba(99,102,241,0.07); }

/* ================================================================
   VERSUS SECTION
   ================================================================ */

.versus-section {
  position: relative; z-index: 1;
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.versus-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.versus-col {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
}

.versus-us {
  border-color: var(--accent);
  background: linear-gradient(160deg, var(--surface) 0%, rgba(99,102,241,0.04) 100%);
}

.versus-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.accent-label { color: var(--accent); }

.versus-col ul { list-style: none; display: flex; flex-direction: column; }

.versus-col li {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border);
}

.versus-col li:last-child { border-bottom: none; }

.versus-col li::before {
  content: '✗';
  font-weight: 700;
  flex-shrink: 0;
  font-size: 0.8rem;
  margin-top: 0.1rem;
  color: rgba(239,68,68,0.55);
}

.versus-col li.good { color: var(--text-muted); }

.versus-col li.good::before {
  content: '✓';
  color: var(--accent-green);
}

/* ================================================================
   VERSIONS
   ================================================================ */

.versions-section {
  position: relative; z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2.5rem 8rem;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
  font-size: 2rem;
}

.versions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.version-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  position: relative;
  transition: all var(--tr);
}

.version-card.featured {
  border-color: var(--accent);
  background: linear-gradient(160deg, var(--surface) 0%, var(--surface-raised) 100%);
}

.version-card.featured::before {
  content: 'Recommended';
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  background: var(--gradient-primary);
  color: white;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.3rem 1rem;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.version-header { margin-bottom: 1.75rem; }

.version-name {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.version-price {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
}

.version-price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-muted);
}

.version-card ul { list-style: none; margin-bottom: 2rem; }

.version-card li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.875rem;
}

.version-card li:last-child { border-bottom: none; }

.version-card li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.version-card .btn { width: 100%; justify-content: center; }

/* ================================================================
   TECH STACK
   ================================================================ */

.tech-section {
  position: relative; z-index: 1;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2.5rem 6rem;
  text-align: center;
}

.tech-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-faint);
  margin-bottom: 1.5rem;
}

.tech-icons {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.tech-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.75rem 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  transition: all var(--tr);
}

.tech-item:hover { border-color: var(--accent); color: var(--text); }

.tech-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ================================================================
   FOOTER
   ================================================================ */

footer {
  position: relative; z-index: 1;
  border-top: 1px solid var(--border);
  padding: 3rem 2.5rem;
}

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

.footer-brand { display:flex; flex-direction:column; gap:0.3rem; }

.footer-logo { font-weight: 700; font-size: 1rem; }

.footer-tagline { font-size: 0.8rem; color: var(--text-muted); }

.footer-links { display:flex; gap:1.5rem; }

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color var(--tr-fast);
}
.footer-links a:hover { color: var(--accent); }

.footer-meta { text-align: right; }

.footer-meta p {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-faint);
}
.footer-meta p + p { margin-top: 0.25rem; }

/* ================================================================
   REVEAL ANIMATIONS
   ================================================================ */

[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out);
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

[data-reveal][data-reveal-delay="1"] { transition-delay: 0.1s; }
[data-reveal][data-reveal-delay="2"] { transition-delay: 0.2s; }
[data-reveal][data-reveal-delay="3"] { transition-delay: 0.3s; }
[data-reveal][data-reveal-delay="4"] { transition-delay: 0.45s; }

/* ================================================================
   GENERAL ANIMATIONS
   ================================================================ */

@keyframes fadeInUp {
  from { opacity:0; transform:translateY(20px); }
  to   { opacity:1; transform:translateY(0); }
}

@keyframes ripple-effect {
  to { transform:scale(4); opacity:0; }
}

/* ================================================================
   RESPONSIVE
   ================================================================ */

@media (max-width: 1100px) {
  .hero-visual { width: 460px; }
}

@media (max-width: 920px) {
  .hero-section {
    flex-direction: column;
    padding-top: 7rem;
    min-height: auto;
    gap: 3rem;
  }

  .hero-visual {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
  }

  .app-frame { transform: none !important; }
  .callout-2 { display: none; }

  .philosophy-grid { grid-template-columns: 1fr; }
  .cognition-body { grid-template-columns: 1fr; }
  .cog-compare { grid-template-columns: 1fr; }
  .voice-inner { grid-template-columns: 1fr; gap: 3rem; }
  .versus-grid { grid-template-columns: 1fr; }
  .versions { grid-template-columns: 1fr; }

  .stat-item { padding: 0 1.5rem; }
}

@media (max-width: 640px) {
  .hero-section { padding-left: 1.25rem; padding-right: 1.25rem; }
  .hero-note { flex-direction: column; gap: 0.4rem; }
  .stats-bar { flex-direction: column; gap: 1.25rem; }
  .stat-divider { display: none; }
  .features-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-meta { text-align: left; }
  .callout { display: none; }
}

/* ================================================================
   REDUCED MOTION
   ================================================================ */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity:1; transform:none; }
}
