/* ===== Design tokens (oklch) ===== */
:root {
  --background: oklch(0.985 0.005 100);
  --foreground: oklch(0.22 0.02 160);
  --surface: oklch(1 0 0);
  --primary: oklch(0.58 0.08 160);
  --primary-foreground: oklch(0.99 0.005 100);
  --primary-soft: oklch(0.93 0.04 160);
  --secondary: oklch(0.96 0.01 160);
  --muted-foreground: oklch(0.5 0.02 160);
  --accent: oklch(0.93 0.04 220);
  --destructive: oklch(0.6 0.2 25);
  --destructive-foreground: oklch(0.99 0 0);
  --border: oklch(0.92 0.01 160);
  --radius: 1rem;
  --shadow-soft: 0 1px 2px oklch(0.2 0.03 160 / 0.04), 0 8px 24px oklch(0.2 0.03 160 / 0.06);
  --shadow-glow: 0 20px 60px -20px oklch(0.65 0.09 160 / 0.35);
  --font-display: "Fraunces", Georgia, serif;
  --font-sans: "Inter", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-feature-settings: "ss01", "cv11";
  line-height: 1.5;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-display); letter-spacing: -0.02em; margin: 0; font-weight: 500; }
p { margin: 0; }

.container { max-width: 72rem; margin: 0 auto; padding: 0 1.5rem; }
.container.narrow { max-width: 56rem; }
.muted-text { color: var(--muted-foreground); font-size: 0.75rem; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 30;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  background: color-mix(in oklab, var(--background) 80%, transparent);
  backdrop-filter: blur(12px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.5rem; }
.brand { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; letter-spacing: -0.01em; }
.brand-icon { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; border-radius: 999px; background: var(--primary-soft); color: var(--primary); }
.brand-icon.small { width: 1.75rem; height: 1.75rem; }
.brand-icon.big { width: 3rem; height: 3rem; margin: 0 auto 2rem; }

.nav { display: none; gap: 2rem; font-size: 0.875rem; color: var(--muted-foreground); }
.nav a { transition: color 0.2s; }
.nav a:hover { color: var(--foreground); }
@media (min-width: 768px) { .nav { display: flex; align-items: center; } }

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

.lang-toggle { display: inline-flex; padding: 2px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); }
.lang-toggle button {
  padding: 4px 10px; font-size: 0.75rem; font-weight: 500; color: var(--muted-foreground);
  border-radius: 999px; transition: all 0.2s;
}
.lang-toggle button.active { background: var(--primary); color: var(--primary-foreground); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.75rem 1.5rem; border-radius: 999px;
  font-size: 0.875rem; font-weight: 500;
  transition: transform 0.2s, background-color 0.2s;
  white-space: nowrap;
}
.btn-sm { padding: 0.5rem 1rem; }
.btn-primary { background: var(--primary); color: var(--primary-foreground); box-shadow: var(--shadow-glow); }
.btn-primary:hover { transform: translateY(-2px); }
.btn-ghost { background: var(--surface); color: var(--foreground); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--secondary); }
.btn-ghost.on-surface { background: var(--background); }
.hide-mobile { display: none; }
@media (min-width: 640px) { .hide-mobile { display: inline-flex; } }

/* ===== Hero ===== */
.hero { position: relative; overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0 0 auto 0; height: 600px; z-index: -1;
  background: linear-gradient(to bottom, color-mix(in oklab, var(--primary-soft) 40%, transparent), var(--background));
}
.hero-inner { padding: 4rem 1.5rem 6rem; }
@media (min-width: 768px) { .hero-inner { padding: 6rem 1.5rem 8rem; } }
.hero-text { max-width: 48rem; margin: 0 auto; text-align: center; }
.badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.25rem 0.75rem; border: 1px solid var(--border); border-radius: 999px;
  background: var(--surface); font-size: 0.75rem; font-weight: 500; color: var(--muted-foreground);
}
.badge .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--primary); }

h1.display { font-size: clamp(2.25rem, 6vw, 4.5rem); line-height: 1.05; margin-top: 1.5rem; }
.lead { margin: 1.5rem auto 0; max-width: 36rem; color: var(--muted-foreground); font-size: 1.0625rem; line-height: 1.65; }
.cta-row { display: flex; flex-direction: column; gap: 0.75rem; margin-top: 2.5rem; align-items: stretch; }
.cta-row.center, .cta-row { justify-content: center; }
@media (min-width: 640px) {
  .cta-row { flex-direction: row; align-items: center; justify-content: center; }
  .cta-row .btn { width: auto; }
}
.cta-row .btn { width: 100%; }
.micro { margin-top: 1.25rem; font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-foreground); }

/* ===== Classroom mock ===== */
.classroom-wrap { position: relative; max-width: 42rem; margin: 4rem auto 0; }
.classroom-glow {
  position: absolute; inset: -2rem; z-index: -1; border-radius: 2.5rem;
  background: color-mix(in oklab, var(--primary-soft) 60%, transparent);
  filter: blur(48px);
}
.classroom { overflow: hidden; border-radius: 1.5rem; border: 1px solid var(--border); background: var(--surface); box-shadow: var(--shadow-soft); }
.classroom-top { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1.25rem; border-bottom: 1px solid var(--border); }
.live { display: flex; align-items: center; gap: 0.5rem; font-size: 0.7rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted-foreground); }
.live-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--primary); }
.classroom-video {
  position: relative; aspect-ratio: 16/10;
  background: linear-gradient(135deg, var(--primary-soft), var(--secondary), var(--accent));
}
.teacher-avatar {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 6rem; height: 6rem; border-radius: 999px;
  background: color-mix(in oklab, var(--surface) 80%, transparent);
  backdrop-filter: blur(4px); box-shadow: var(--shadow-soft);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-size: 1.875rem; color: var(--primary);
}
.teacher-avatar span::first-letter, .teacher-avatar span { /* show only initial via JS */ }
.teacher-name {
  position: absolute; bottom: 1rem; left: 1rem;
  padding: 0.25rem 0.75rem; border-radius: 999px;
  background: color-mix(in oklab, var(--foreground) 80%, transparent);
  color: var(--background); font-size: 0.75rem; font-weight: 500;
  backdrop-filter: blur(4px);
}
.student-tile {
  position: absolute; bottom: 1rem; right: 1rem;
  width: 7rem; height: 5rem; border-radius: 0.75rem; overflow: hidden;
  border: 1px solid color-mix(in oklab, var(--surface) 60%, transparent);
  background: color-mix(in oklab, var(--foreground) 40%, transparent);
  backdrop-filter: blur(4px);
}
.student-name {
  position: absolute; bottom: 4px; left: 4px;
  padding: 1px 8px; border-radius: 999px;
  background: color-mix(in oklab, var(--foreground) 70%, transparent);
  color: var(--background); font-size: 10px;
}
.classroom-controls {
  display: flex; align-items: center; justify-content: center; gap: 0.75rem;
  padding: 1rem 1.25rem; border-top: 1px solid var(--border); background: var(--surface);
}
.classroom-controls button {
  width: 2.5rem; height: 2.5rem; border-radius: 999px;
  border: 1px solid var(--border); color: var(--muted-foreground);
  display: inline-flex; align-items: center; justify-content: center;
  transition: background-color 0.2s, color 0.2s;
}
.classroom-controls button:hover { background: var(--secondary); color: var(--foreground); }
.classroom-controls .leave {
  width: auto; padding: 0 1rem; height: 2.5rem; border: 0;
  background: color-mix(in oklab, var(--destructive) 90%, transparent);
  color: var(--destructive-foreground); font-size: 0.75rem; font-weight: 500;
  margin-left: 0.5rem;
}

/* ===== Sections ===== */
.section { border-top: 1px solid color-mix(in oklab, var(--border) 60%, transparent); padding: 5rem 0; }
@media (min-width: 768px) { .section { padding: 7rem 0; } }
.section-surface { background: var(--surface); }
.section-center { text-align: center; }
.section-head { max-width: 36rem; }
.kicker { font-size: 0.7rem; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--primary); }
.section-head h2 { margin-top: 0.75rem; font-size: clamp(1.875rem, 4vw, 3rem); line-height: 1.15; }
.section-center h2 { font-size: clamp(1.875rem, 4vw, 3rem); line-height: 1.15; }
.section-center .lead { margin-top: 1.25rem; }

/* Pain grid */
.grid-3 {
  margin-top: 3.5rem;
  display: grid; gap: 1px;
  background: var(--border);
  border-radius: 1.5rem; overflow: hidden;
}
@media (min-width: 768px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.pain-card { background: var(--surface); padding: 2rem; }
@media (min-width: 768px) { .pain-card { padding: 2.5rem; } }
.pain-num {
  width: 2.5rem; height: 2.5rem; border-radius: 999px;
  background: var(--primary-soft); color: var(--primary);
  font-family: var(--font-display); font-size: 1rem;
  display: inline-flex; align-items: center; justify-content: center;
}
.pain-card h3 { margin-top: 1.5rem; font-size: 1.25rem; }
.pain-card p { margin-top: 0.75rem; color: var(--muted-foreground); font-size: 0.875rem; line-height: 1.65; }

/* Diff */
.diff-grid { display: grid; gap: 3rem; }
@media (min-width: 768px) { .diff-grid { grid-template-columns: 1fr 1fr; gap: 5rem; } }
.diff-head { position: sticky; top: 7rem; align-self: start; }
.diff-list {
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: 1px;
  background: var(--border); border: 1px solid var(--border);
  border-radius: 1.5rem; overflow: hidden;
}
.diff-list li { background: var(--surface); padding: 2rem; }
.diff-list h3 { font-size: 1.25rem; }
.diff-list p { margin-top: 0.5rem; color: var(--muted-foreground); font-size: 0.875rem; line-height: 1.65; }

/* Footer */
.site-footer { border-top: 1px solid color-mix(in oklab, var(--border) 60%, transparent); }
.footer-inner {
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 2rem 1.5rem; font-size: 0.875rem; color: var(--muted-foreground);
}
@media (min-width: 640px) { .footer-inner { flex-direction: row; } }
