/* ================================================================
   Quizalot Marketing Site
   Tokens: docs/brand/design-tokens.md · app/src/constants/theme.ts
   ================================================================ */

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

:root {
  --primary-400: #7B91F8;
  --primary-500: #4F6DF5;
  --primary-600: #3A52D4;
  --primary-700: #2B3EB3;

  --secondary-500: #10B981;
  --success: #10B981;
  --error: #EF4444;

  --neutral-50:  #F9FAFB;
  --neutral-100: #F3F4F6;
  --neutral-200: #E5E7EB;
  --neutral-300: #D1D5DB;
  --neutral-400: #9CA3AF;
  --neutral-500: #6B7280;
  --neutral-600: #4B5563;
  --neutral-700: #374151;
  --neutral-800: #1F2937;
  --neutral-900: #111827;

  --surface: #FFFFFF;
  --background: #F9FAFB;

  --color-text: var(--neutral-900);
  --color-text-secondary: var(--neutral-600);
  --color-muted: var(--neutral-500);
  --color-border: var(--neutral-200);

  --space-xs:  4px;
  --space-sm:  8px;
  --space-md:  16px;
  --space-lg:  24px;
  --space-xl:  32px;
  --space-2xl: 48px;

  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   16px;
  --radius-full: 9999px;

  --font-display: 'Spline Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --max-width: 72rem;
}

html { font-size: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--font-display);
  color: var(--color-text);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: var(--primary-500); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

/* ================================================================
   Layout
   ================================================================ */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

/* ================================================================
   Buttons
   ================================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  line-height: 1;
}

.btn-primary {
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  background: var(--primary-500);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-600);
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(79, 109, 245, 0.3);
}

.btn-ghost {
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-text);
  border: 1.5px solid var(--color-border);
}
.btn-ghost:hover {
  border-color: var(--primary-500);
  color: var(--primary-500);
  text-decoration: none;
}

.btn-sm {
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  background: var(--primary-500);
  color: #fff;
  font-size: 0.85rem;
}
.btn-sm:hover { background: var(--primary-600); text-decoration: none; }

/* ================================================================
   Shared section helpers
   ================================================================ */

.section-tag {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary-500);
  margin-bottom: var(--space-sm);
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-header h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.2;
  color: var(--color-text);
}

/* ================================================================
   Header
   ================================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  display: flex;
  align-items: center;
  height: 56px;
  gap: var(--space-lg);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
  text-decoration: none;
  flex-shrink: 0;
}
.logo:hover { text-decoration: none; }

.logo-mark {
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: var(--radius-sm);
  background: var(--primary-500);
  flex-shrink: 0;
}

.nav-desktop {
  display: flex;
  gap: var(--space-lg);
  margin-left: auto;
}
.nav-desktop a {
  color: var(--color-muted);
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-desktop a:hover { color: var(--color-text); text-decoration: none; }

.header-inner > .btn-sm { flex-shrink: 0; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all 0.2s;
}

.nav-mobile {
  display: none;
  flex-direction: column;
  padding: 0 var(--space-lg) var(--space-md);
  background: var(--surface);
  border-bottom: 1px solid var(--color-border);
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  padding: 10px 0;
  color: var(--color-muted);
  font-size: 0.9rem;
  font-weight: 500;
}
.nav-mobile a:hover { color: var(--color-text); text-decoration: none; }

/* ================================================================
   Hero
   ================================================================ */

.hero {
  padding: 80px 0 72px;
  position: relative;
  overflow: clip;
  background: var(--surface);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-tag {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary-500);
  margin-bottom: var(--space-md);
}

.hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--color-text);
  margin-bottom: var(--space-lg);
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--color-text-secondary);
  line-height: 1.65;
  margin-bottom: var(--space-xl);
  max-width: 28rem;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---- Hero visual — looping notes → quiz animation ---- */

.hero-visual {
  display: flex;
  justify-content: center;
  position: relative;
  min-height: 440px;
}

/*
  16s cycle — notes-to-quiz storytelling:
  0–3%      card-stack fades in
  3–19%     corner view: handwriting appears line by line
  19–24%    zoom out: paper scales down, reveals more of the sheet
  24–29%    camera overlay appears on zoomed-out view
  29–34%    zoom in: camera focuses/brackets tighten on notes
  34–36%    flash / snap
  36–40%    notes out, quiz card in
  40–60%    quiz elements appear (badge, progress, question, answers)
  60–64%    source badge
  64–74%    hold visible + subtle float
  74–84%    everything fades out
  84–100%   pause before restart
*/

.card-stack {
  position: relative;
  width: 340px;
  animation: stack-cycle 16s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes stack-cycle {
  0%        { opacity: 0; transform: translateY(24px) scale(0.96); }
  3%        { opacity: 1; transform: translateY(0) scale(1); }
  64%       { transform: translateY(-6px); }
  70%       { transform: translateY(0); }
  74%       { opacity: 1; transform: translateY(0); }
  84%       { opacity: 0; transform: translateY(16px) scale(0.97); }
  100%      { opacity: 0; transform: translateY(24px) scale(0.96); }
}

/* -- Notes card (viewport frame) -- */

.card-notes {
  position: absolute;
  inset: 0;
  z-index: 10;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow:
    0 24px 48px rgba(17, 24, 39, 0.10),
    0 8px 16px rgba(17, 24, 39, 0.06);
  animation: notes-cycle 16s ease infinite;
}

@keyframes notes-cycle {
  0%, 2%    { opacity: 0; }
  5%        { opacity: 1; }
  34%       { opacity: 1; }
  38%       { opacity: 0; }
  100%      { opacity: 0; }
}

/* -- Notebook paper (oversized sheet, zooms in/out) -- */

.notes-paper {
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;
  height: 200%;
  background: #fff;
  padding: 14px 24px 24px 24px;
  background-image:
    repeating-linear-gradient(
      transparent,
      transparent 31px,
      #c8d8e8 31px,
      #c8d8e8 32px
    );
  background-position: 0 12px;
  transform-origin: top left;
  animation: paper-zoom 16s ease infinite;
}

@keyframes paper-zoom {
  0%, 5%    { transform: scale(1.12); }
  19%       { transform: scale(1.12); }
  24%       { transform: scale(0.50); }
  29%       { transform: scale(0.50); }
  34%       { transform: scale(1.0) translate(-1%, 0%); }
  38%, 100% { transform: scale(1.0) translate(-1%, 0%); }
}

.notes-paper::before {
  content: "";
  position: absolute;
  left: 42px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(200, 80, 80, 0.3);
}

/* -- Paper edge fades (suggest sheet continues) -- */

.paper-fade {
  position: absolute;
  pointer-events: none;
  z-index: 3;
}

.paper-fade-right {
  top: 0;
  right: 0;
  width: 70px;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.9) 65%, #fff);
}

.paper-fade-bottom {
  bottom: 0;
  left: 0;
  width: 100%;
  height: 70px;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.9) 65%, #fff);
}

/* -- Camera overlay (dark surround + corner brackets) -- */

.cam-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 5;
  animation: overlay-cycle 16s ease infinite;
}

@keyframes overlay-cycle {
  0%, 23%   { opacity: 0; }
  26%       { opacity: 1; }
  36%       { opacity: 1; }
  38%       { opacity: 0; }
  100%      { opacity: 0; }
}

.cam-focus {
  position: absolute;
  border-radius: 4px;
  box-shadow: 0 0 0 2000px rgba(0, 0, 0, 0.6);
  animation: focus-tighten 16s ease infinite;
}

@keyframes focus-tighten {
  0%, 24%   { inset: 10% 10% 10% 10%; }
  29%       { inset: 10% 10% 10% 10%; }
  34%       { inset: 3% 3% 54% 2%; }
  38%, 100% { inset: 3% 3% 54% 2%; }
}

.cam-focus::before,
.cam-focus::after {
  content: "";
  position: absolute;
  width: 28px;
  height: 28px;
  border-style: solid;
  border-color: #fff;
}

.cam-focus::before {
  top: -2px;
  left: -2px;
  border-width: 3px 0 0 3px;
  border-radius: 6px 0 0 0;
}

.cam-focus::after {
  top: -2px;
  right: -2px;
  border-width: 3px 3px 0 0;
  border-radius: 0 6px 0 0;
}

.cam-overlay::before,
.cam-overlay::after {
  content: "";
  position: absolute;
  width: 28px;
  height: 28px;
  border-style: solid;
  border-color: #fff;
  z-index: 6;
}

.cam-overlay::before {
  border-width: 0 0 3px 3px;
  border-radius: 0 0 0 6px;
  animation: bracket-bl 16s ease infinite;
}

.cam-overlay::after {
  border-width: 0 3px 3px 0;
  border-radius: 0 0 6px 0;
  animation: bracket-br 16s ease infinite;
}

@keyframes bracket-bl {
  0%, 24%   { bottom: 10%; left: 10%; }
  29%       { bottom: 10%; left: 10%; }
  34%       { bottom: 54%; left: 2%; }
  38%, 100% { bottom: 54%; left: 2%; }
}

@keyframes bracket-br {
  0%, 24%   { bottom: 10%; right: 10%; }
  29%       { bottom: 10%; right: 10%; }
  34%       { bottom: 54%; right: 3%; }
  38%, 100% { bottom: 54%; right: 3%; }
}

/* -- Shutter button -- */

.cam-shutter {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 8;
  animation: shutter-show 16s ease infinite;
}

@keyframes shutter-show {
  0%, 25%   { opacity: 0; transform: translateX(-50%) scale(0.6); }
  28%       { opacity: 1; transform: translateX(-50%) scale(1); }
  34%       { opacity: 1; transform: translateX(-50%) scale(1); }
  35%       { opacity: 0; transform: translateX(-50%) scale(0.8); }
  100%      { opacity: 0; transform: translateX(-50%) scale(0.8); }
}

.cam-shutter-ring {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: shutter-tap 16s ease infinite;
}

@keyframes shutter-tap {
  0%, 33%   { transform: scale(1); }
  34%       { transform: scale(0.8); }
  35%       { transform: scale(1); }
  100%      { transform: scale(1); }
}

.cam-shutter-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  animation: shutter-btn-tap 16s ease infinite;
}

@keyframes shutter-btn-tap {
  0%, 33%   { transform: scale(1); background: #fff; }
  34%       { transform: scale(0.85); background: #e0e0e0; }
  35%       { transform: scale(1); background: #fff; }
  100%      { transform: scale(1); }
}

/* -- Camera flash overlay -- */

.cam-flash-overlay {
  position: absolute;
  inset: 0;
  background: #fff;
  border-radius: var(--radius-lg);
  pointer-events: none;
  z-index: 9;
  animation: cam-flash-anim 16s ease infinite;
}

@keyframes cam-flash-anim {
  0%, 34%   { opacity: 0; }
  35%       { opacity: 0.95; }
  37%       { opacity: 0; }
  100%      { opacity: 0; }
}

/* -- Notes handwriting -- */

.notes-line {
  font-family: 'Playpen Sans', sans-serif;
  font-size: 0.72rem;
  font-weight: 400;
  color: #1a1a2e;
  line-height: 32px;
  height: 32px;
  padding-left: 28px;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.notes-line-1 { animation: write-1 16s ease infinite; }
.notes-line-2 { animation: write-2 16s ease infinite; }
.notes-line-3 { animation: write-3 16s ease infinite; }
.notes-line-4 { animation: write-4 16s ease infinite; }

@keyframes write-1 {
  0%, 4%    { clip-path: inset(0 100% 0 0); }
  9%        { clip-path: inset(0 0% 0 0); }
  36%       { clip-path: inset(0 0% 0 0); }
  38%       { clip-path: inset(0 100% 0 0); }
  100%      { clip-path: inset(0 100% 0 0); }
}
@keyframes write-2 {
  0%, 7%    { clip-path: inset(0 100% 0 0); }
  12%       { clip-path: inset(0 0% 0 0); }
  36%       { clip-path: inset(0 0% 0 0); }
  38%       { clip-path: inset(0 100% 0 0); }
  100%      { clip-path: inset(0 100% 0 0); }
}
@keyframes write-3 {
  0%, 10%   { clip-path: inset(0 100% 0 0); }
  15%       { clip-path: inset(0 0% 0 0); }
  36%       { clip-path: inset(0 0% 0 0); }
  38%       { clip-path: inset(0 100% 0 0); }
  100%      { clip-path: inset(0 100% 0 0); }
}
@keyframes write-4 {
  0%, 13%   { clip-path: inset(0 100% 0 0); }
  18%       { clip-path: inset(0 0% 0 0); }
  36%       { clip-path: inset(0 0% 0 0); }
  38%       { clip-path: inset(0 100% 0 0); }
  100%      { clip-path: inset(0 100% 0 0); }
}

/* -- Class badge -- */

.card-badge {
  position: absolute;
  top: -8px;
  left: -24px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--neutral-900);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  z-index: 4;
  box-shadow: 0 4px 16px rgba(17, 24, 39, 0.15);
  animation: badge-cycle 16s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes badge-cycle {
  0%, 38%   { opacity: 0; transform: translate(-12px, 12px) scale(0.8); }
  43%       { opacity: 1; transform: translate(0, 0) scale(1); }
  64%       { transform: translate(3px, -4px); }
  70%       { transform: translate(0, 0); }
  74%       { opacity: 1; transform: translate(0, 0); }
  84%       { opacity: 0; transform: translate(-8px, 8px) scale(0.9); }
  100%      { opacity: 0; }
}

.card-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--primary-400);
  display: inline-block;
}

/* -- Main card -- */

.card-main {
  position: relative;
  z-index: 3;
  background: var(--surface);
  border-radius: 20px;
  padding: 24px 28px 28px;
  box-shadow:
    0 24px 48px rgba(17, 24, 39, 0.10),
    0 8px 16px rgba(17, 24, 39, 0.06);
  animation: main-cycle 16s ease infinite;
}

@keyframes main-cycle {
  0%, 36%   { opacity: 0; }
  40%       { opacity: 1; }
  74%       { opacity: 1; }
  84%, 100% { opacity: 0; }
}

/* -- Progress bar -- */

.card-progress {
  height: 4px;
  background: var(--neutral-100);
  border-radius: var(--radius-full);
  border: 1px solid var(--neutral-200);
  margin-bottom: 16px;
  overflow: hidden;
}

.card-progress-fill {
  height: 100%;
  background: var(--primary-500);
  border-radius: var(--radius-full);
  animation: progress-cycle 16s ease infinite;
}

@keyframes progress-cycle {
  0%, 40%   { width: 0%; }
  46%       { width: 30%; }
  74%       { width: 30%; }
  84%, 100% { width: 0%; }
}

/* -- Label + question -- */

.card-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-muted);
  margin-bottom: 10px;
  animation: label-cycle 16s ease infinite;
}

@keyframes label-cycle {
  0%, 40%   { opacity: 0; transform: translateY(8px); }
  45%       { opacity: 1; transform: translateY(0); }
  74%       { opacity: 1; transform: translateY(0); }
  84%, 100% { opacity: 0; transform: translateY(8px); }
}

.card-question {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--color-text);
  margin-bottom: 20px;
  animation: question-cycle 16s ease infinite;
}

@keyframes question-cycle {
  0%, 43%   { opacity: 0; transform: translateY(8px); }
  48%       { opacity: 1; transform: translateY(0); }
  74%       { opacity: 1; transform: translateY(0); }
  84%, 100% { opacity: 0; transform: translateY(8px); }
}

/* -- Answer rows -- */

.card-answers { display: flex; flex-direction: column; gap: 8px; }

.card-answer {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.85rem;
  padding: 10px 14px;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text);
  background: var(--surface);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.answer-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--neutral-100);
  border: 1.5px solid var(--neutral-300);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--neutral-500);
  flex-shrink: 0;
}

.answer-badge.selected {
  background: var(--primary-500);
  border-color: var(--primary-500);
  color: #fff;
}

.card-answer.is-selected {
  border-color: var(--primary-500);
  background: rgba(79, 109, 245, 0.06);
  font-weight: 600;
}

/* -- Staggered answer animations (looping) -- */

.anim-a1 { animation: answer-cycle-1 16s ease infinite; }
.anim-a2 { animation: answer-cycle-2 16s ease infinite; }
.anim-a3 { animation: answer-cycle-3 16s ease infinite; }
.anim-a4 { animation: answer-cycle-4 16s ease infinite; }

@keyframes answer-cycle-1 {
  0%, 49%   { opacity: 0; transform: translateX(30px) scale(0.94); }
  53%       { opacity: 1; transform: translateX(0) scale(1); }
  74%       { opacity: 1; transform: translateX(0) scale(1); }
  84%, 100% { opacity: 0; transform: translateX(30px) scale(0.94); }
}
@keyframes answer-cycle-2 {
  0%, 52%   { opacity: 0; transform: translateX(30px) scale(0.94); }
  56%       { opacity: 1; transform: translateX(0) scale(1); }
  74%       { opacity: 1; transform: translateX(0) scale(1); }
  84%, 100% { opacity: 0; transform: translateX(30px) scale(0.94); }
}
@keyframes answer-cycle-3 {
  0%, 55%   { opacity: 0; transform: translateX(30px) scale(0.94); }
  59%       { opacity: 1; transform: translateX(0) scale(1); }
  74%       { opacity: 1; transform: translateX(0) scale(1); }
  84%, 100% { opacity: 0; transform: translateX(30px) scale(0.94); }
}
@keyframes answer-cycle-4 {
  0%, 58%   { opacity: 0; transform: translateX(30px) scale(0.94); }
  62%       { opacity: 1; transform: translateX(0) scale(1); }
  74%       { opacity: 1; transform: translateX(0) scale(1); }
  84%, 100% { opacity: 0; transform: translateX(30px) scale(0.94); }
}

/* -- Source badge -- */

.card-source {
  position: absolute;
  bottom: -20px;
  right: -20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--surface);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--color-muted);
  z-index: 4;
  box-shadow:
    0 8px 24px rgba(17, 24, 39, 0.08),
    0 2px 8px rgba(17, 24, 39, 0.04);
  animation: source-cycle 16s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.card-source svg { color: var(--primary-500); flex-shrink: 0; }

@keyframes source-cycle {
  0%, 62%   { opacity: 0; transform: translate(14px, 14px) scale(0.85); }
  66%       { opacity: 1; transform: translate(0, 0) scale(1); }
  70%       { transform: translate(-2px, -2px); }
  74%       { opacity: 1; transform: translate(0, 0); }
  84%       { opacity: 0; transform: translate(10px, 10px) scale(0.9); }
  100%      { opacity: 0; }
}

.hero-glow {
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(79, 109, 245, 0.18) 0%, transparent 65%);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  animation: glow-pulse 4s ease-in-out infinite alternate;
}

@keyframes glow-pulse {
  0% { opacity: 0.7; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 1; transform: translate(-50%, -50%) scale(1.12); }
}

/* ================================================================
   Trust strip
   ================================================================ */

.trust-strip {
  padding: 20px 0;
  background: var(--surface);
  border-bottom: 1px solid var(--color-border);
}

.trust-grid {
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
}

.trust-item svg { color: var(--primary-500); flex-shrink: 0; }

/* ================================================================
   How it works
   ================================================================ */

.how-section {
  padding: 104px 0 96px;
  background: var(--surface);
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 640px;
  margin: 0 auto;
  position: relative;
}

.steps::before {
  content: "";
  position: absolute;
  left: 40px;
  top: 80px;
  bottom: 80px;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary-400), var(--primary-600));
  border-radius: 1px;
}

.step {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 32px;
  align-items: start;
  padding: 32px 0;
  position: relative;
}

.step-num-large {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
  color: var(--primary-500);
  text-align: center;
  position: relative;
  z-index: 2;
  background: var(--surface);
  padding: 4px 0;
}

.step-content { padding-top: 8px; }

.step-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--color-text);
  letter-spacing: -0.01em;
}

.step-content p {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
  max-width: 380px;
}

/* ================================================================
   Features
   ================================================================ */

.features-section {
  padding: 120px 0;
  background: var(--surface);
}

.features-group {
  max-width: 56rem;
  margin: 0 auto 104px;
}

.features-group:last-child {
  margin-bottom: 0;
}

.features-group-heading {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--color-text);
  text-align: center;
  margin-bottom: 48px;
}

/* -- "Your notes" section: two panels split by a pencil line -- */

.notes-split {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: stretch;
  max-width: 52rem;
  margin: 0 auto;
}

.notes-split-panel {
  padding: 48px 48px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.notes-split-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.notes-split-accent {
  display: flex;
  flex-shrink: 0;
}

.notes-split-accent--blue {
  color: var(--primary-500);
}

.notes-split-accent--purple {
  color: #7C3AED;
}

.notes-split-panel h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.notes-split-panel p {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.7;
}

.notes-split-divider {
  position: relative;
  width: 1px;
}

.notes-split-divider::after {
  content: "";
  position: absolute;
  top: 8px;
  bottom: 0;
  left: 0;
  width: 1.5px;
  background: linear-gradient(to bottom, var(--neutral-700) 0%, var(--neutral-400) 70%, transparent 100%);
  border-radius: 1px;
}

/* -- "Small steps" section: mind map layout -- */

.mindmap {
  max-width: 56rem;
  margin: 0 auto;
  text-align: center;
}

.mindmap-title {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--color-text);
  margin-bottom: 0;
}

.mindmap-branches {
  padding: 16px 0 0;
}

.mindmap-svg {
  width: 100%;
  height: 100px;
  display: block;
}

.mindmap-nodes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  text-align: left;
  padding-top: 16px;
}

.mindmap-node h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.01em;
  margin-bottom: 8px;
  line-height: 1.3;
}

.mindmap-node p {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  line-height: 1.65;
}

/* ================================================================
   CTA / Waitlist
   ================================================================ */

.cta-section {
  padding: 96px 0;
  background: var(--surface);
}

.cta-inner {
  max-width: 600px;
  text-align: center;
}

.cta-circled {
  position: relative;
  padding: 100px 80px;
}

.cta-circle-mark {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 580px;
  height: 580px;
  transform: translate(-50%, -50%) rotate(2deg);
  pointer-events: none;
  overflow: visible;
}

.cta-circled h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-sm);
}

.cta-circled > p {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  margin-bottom: var(--space-xl);
  line-height: 1.6;
}

.waitlist-form {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.waitlist-form input[type="email"] {
  flex: 1;
  padding: 13px var(--space-md);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--color-text);
  background: var(--background);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.waitlist-form input[type="email"]:focus {
  border-color: var(--primary-500);
  box-shadow: 0 0 0 3px rgba(79, 109, 245, 0.1);
}
.waitlist-form input[type="email"]::placeholder { color: var(--neutral-400); }

.form-note {
  font-size: 0.75rem;
  color: var(--color-muted);
}

/* ================================================================
   Footer
   ================================================================ */

.site-footer {
  padding: var(--space-lg) 0;
  border-top: 1px solid var(--color-border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-nav {
  display: flex;
  gap: var(--space-lg);
}

.footer-nav a {
  color: var(--color-muted);
  font-size: 0.8rem;
  font-weight: 500;
  transition: color 0.15s;
}
.footer-nav a:hover { color: var(--color-text); text-decoration: none; }

.footer-inner > p {
  font-size: 0.8rem;
  color: var(--color-muted);
}

/* ================================================================
   Responsive
   ================================================================ */

@media (max-width: 64rem) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 48px;
    text-align: center;
  }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { order: -1; }

  .mindmap-nodes {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin: 0 auto;
    gap: 32px;
  }
  .mindmap-branches { display: none; }
  .notes-split { grid-template-columns: 1fr; }
  .notes-split-divider { width: 100%; height: 1px; }
  .notes-split-divider::after {
    top: 0;
    bottom: auto;
    left: 0;
    right: 0;
    width: 100%;
    height: 1.5px;
    background: linear-gradient(to right, transparent 0%, var(--neutral-400) 30%, var(--neutral-700) 50%, var(--neutral-400) 70%, transparent 100%);
  }
  .notes-split-panel { padding: 32px 8px; }
  .features-group { margin-bottom: 72px; }
}

@media (max-width: 48rem) {
  .container { padding: 0 var(--space-md); }

  .nav-desktop,
  .header-inner > .btn-sm { display: none; }
  .nav-toggle { display: flex; }

  .hero { padding: 48px 0 40px; }
  .hero h1 { font-size: 1.75rem; }

  .how-section { padding: 72px 0 64px; }
  .features-section,
  .cta-section { padding: 64px 0; }

  .section-header { margin-bottom: 40px; }

  .steps { max-width: 100%; }
  .steps::before { left: 28px; top: 56px; bottom: 56px; }
  .step { grid-template-columns: 56px 1fr; gap: 20px; padding: 24px 0; }
  .step-num-large { font-size: 2.5rem; }

  .features-group { margin-bottom: 56px; }

  .trust-grid { gap: 16px; flex-direction: column; align-items: center; }

  .hero-visual { min-height: 380px; }
  .card-stack { width: 280px; }
  .card-main { padding: 20px 18px 22px; }
  .card-badge { left: -8px; top: -6px; font-size: 0.72rem; padding: 6px 12px; }
  .card-source { right: -4px; bottom: -16px; font-size: 0.7rem; padding: 8px 14px; }
  .card-question { font-size: 0.9rem; }
  .card-answer { font-size: 0.8rem; padding: 8px 12px; }
  .answer-badge { width: 24px; height: 24px; font-size: 0.65rem; }
  .notes-paper { padding: 10px 16px 16px 16px; }
  .notes-paper::before { left: 30px; }
  .notes-line { font-size: 0.62rem; padding-left: 18px; }
  .paper-fade-right { width: 40px; }
  .paper-fade-bottom { height: 40px; }
  .cam-shutter-ring { width: 42px; height: 42px; border-width: 2.5px; }
  .cam-shutter-btn { width: 32px; height: 32px; }

  .waitlist-form { flex-direction: column; }

  .footer-inner { flex-direction: column; gap: 12px; text-align: center; }
  .footer-nav { gap: var(--space-md); }
}
