:root {
  --ink: oklch(0.24 0.02 270);
  --ink-2: oklch(0.46 0.02 270);
  --paper: oklch(0.985 0.008 90);
  --white: oklch(0.995 0.004 90);
  --cream: oklch(0.97 0.035 92);
  --sky: oklch(0.95 0.035 235);
  --blush: oklch(0.95 0.03 340);
  --lime: oklch(0.96 0.045 128);
  --line: oklch(0.9 0.012 90);

  --o: oklch(0.82 0.035 275);
  --dot: oklch(0.88 0.15 94);
  --puff: oklch(0.72 0.15 238);
  --bo: oklch(0.72 0.19 340);
  --lo: oklch(0.87 0.17 128);
  --accent: oklch(0.52 0.15 255);

  --radius: 28px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --gutter: clamp(16px, 4vw, 48px);
  --section: clamp(80px, 11vw, 144px);
}

* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body { background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.6 Figtree, system-ui, sans-serif; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
img, svg { display: block; }
a { color: inherit; }
.zh { font-family: "Noto Sans SC", sans-serif; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 var(--gutter); }
.ph { background: oklch(0.93 0.06 94); border-radius: 4px; padding: 0 4px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* characters */
.ch { display: inline-block; width: var(--s, 120px); aspect-ratio: 1; vertical-align: middle; flex: none; }
.ch svg { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 calc(var(--s, 120px) * .05) calc(var(--s, 120px) * .06) oklch(0.3 0.04 270 / .16)); }

/* type */
.eyebrow { font: 700 .75rem/1 Figtree; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); }
h1, h2, h3 { letter-spacing: -.035em; line-height: 1.02; font-weight: 800; }
h2 { font-size: clamp(2rem, 4.4vw, 3.3rem); max-width: 18ch; }
.lead { font-size: 1.15rem; color: var(--ink-2); max-width: 54ch; }
.section-head { display: grid; gap: 14px; align-content: start; margin-bottom: clamp(32px, 5vw, 56px); }

/* buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1rem; padding: 14px 24px; border-radius: 999px; text-decoration: none; border: 0; cursor: pointer; transition: transform .25s var(--ease), background-color .25s; }
.btn:hover { transform: translateY(-2px); }
.btn-dark { background: var(--ink); color: var(--paper); }
.btn-light { background: var(--white); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn-sm { padding: 10px 18px; font-size: .95rem; }

/* header */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in oklch, var(--paper), transparent 8%); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 20px; }
.wordmark { display: inline-flex; align-items: center; font: 800 1.55rem/1 Figtree; letter-spacing: -.045em; text-decoration: none; }
.wordmark .ch { --s: .95em; margin: 0 .02em; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { text-decoration: none; font-weight: 600; font-size: .97rem; color: var(--ink-2); transition: color .2s; }
.nav a:hover { color: var(--ink); }
.menu { display: none; }
.menu summary { list-style: none; cursor: pointer; font-weight: 700; padding: 10px 16px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
.menu summary::-webkit-details-marker { display: none; }
.menu[open] .menu-panel { display: grid; }
.menu-panel { display: none; position: absolute; left: var(--gutter); right: var(--gutter); top: 76px; background: var(--white); border-radius: 22px; padding: 12px; gap: 2px; box-shadow: 0 24px 60px -20px oklch(0.3 0.04 270 / .35); }
.menu-panel a { padding: 14px 16px; border-radius: 14px; text-decoration: none; font-weight: 600; }
.menu-panel a:hover { background: var(--paper); }

/* language switch */
.header-actions { display: flex; align-items: center; gap: 12px; }
.lang-switch { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--white); box-shadow: inset 0 0 0 1px var(--line); }
.lang-switch a { padding: 7px 12px; border-radius: 999px; font: 700 .85rem/1 Figtree; letter-spacing: .04em; text-decoration: none; color: var(--ink-2); transition: background-color .2s, color .2s; }
.lang-switch a:hover { color: var(--ink); }
.lang-switch a[aria-current="page"] { background: var(--ink); color: var(--paper); }

/* hero */
.hero { padding-top: clamp(16px, 2vw, 24px); }
.hero-card { background: var(--cream); border-radius: calc(var(--radius) + 8px); padding: clamp(36px, 6vw, 80px) clamp(24px, 6vw, 72px); display: grid; grid-template-columns: 1.15fr .85fr; gap: 32px; align-items: center; overflow: hidden; }
.hero h1 { font-size: clamp(3rem, 7.4vw, 5.8rem); letter-spacing: -.05em; line-height: .96; }
.hero h1 span { display: block; color: var(--ink-2); font-weight: 600; }
.hero .lead { margin: 24px 0 32px; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 10px; }
.trust { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 36px; font-size: .92rem; font-weight: 600; color: var(--ink-2); list-style: none; padding: 0; }
.trust li { display: flex; align-items: center; gap: 8px; }
.trust li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--puff); }
.morph { position: relative; width: min(100%, 400px); aspect-ratio: 1; justify-self: center; }
.morph .ch { position: absolute; inset: 0; width: 100%; --s: 400px; opacity: 0; animation: cycle 16s var(--ease) infinite backwards; }
.morph .o { animation-name: o-cycle; }
.morph .c2 { animation-delay: 4s; } .morph .c3 { animation-delay: 8s; } .morph .c4 { animation-delay: 12s; }
@keyframes o-cycle {
  0%, 3% { opacity: 1; transform: scale(1); } 9%, 19% { opacity: 0; transform: scale(.6); }
  25%, 28% { opacity: 1; transform: scale(1); } 34%, 44% { opacity: 0; transform: scale(.6); }
  50%, 53% { opacity: 1; transform: scale(1); } 59%, 69% { opacity: 0; transform: scale(.6); }
  75%, 78% { opacity: 1; transform: scale(1); } 84%, 94% { opacity: 0; transform: scale(.6); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes cycle {
  0%, 4% { opacity: 0; transform: scale(.55) rotate(-8deg); }
  10%, 18% { opacity: 1; transform: scale(1) rotate(0); }
  24%, 100% { opacity: 0; transform: scale(.55) rotate(6deg); }
}

section.wrap { margin-top: var(--section); }

/* courses */
.courses { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.course { background: var(--bg); border-radius: var(--radius); padding: 32px 28px; display: flex; flex-direction: column; gap: 18px; }
.course-top { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.course h3 { font-size: 2rem; }
.course h3 small { display: block; font-size: .95rem; font-weight: 600; color: var(--ink-2); letter-spacing: 0; margin-top: 6px; }
.lvl { font: 700 .78rem Figtree; padding: 6px 10px; border-radius: 999px; background: var(--white); white-space: nowrap; }
.course p { color: var(--ink-2); }
.course ul { list-style: none; padding: 0; display: grid; gap: 10px; border-top: 1px solid oklch(0.3 0.03 270 / .1); padding-top: 18px; }
.course li { position: relative; padding-left: 26px; font-size: .97rem; }
.course li::before { content: "→"; position: absolute; left: 0; font-weight: 700; color: var(--ink-2); }
.course .btn { margin-top: auto; align-self: flex-start; }

/* steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); counter-reset: step; border-top: 1px solid var(--line); }
.step { padding: 28px 24px 0 0; counter-increment: step; }
.step + .step { padding-left: 24px; border-left: 1px solid var(--line); }
.step::before { content: "0" counter(step); display: block; font: 800 .9rem Figtree; color: var(--ink-2); margin-bottom: 40px; }
.step h3 { font-size: 1.35rem; margin-bottom: 10px; letter-spacing: -.02em; }
.step p { color: var(--ink-2); font-size: .97rem; }

/* formats */
.formats { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.format { border-radius: var(--radius); padding: 28px; background: var(--white); box-shadow: inset 0 0 0 1px var(--line); display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: center; }
.format .ch { --s: 76px; }
.format h3 { font-size: 1.4rem; letter-spacing: -.02em; }
.format p { color: var(--ink-2); font-size: .97rem; margin-top: 4px; }

/* teachers */
.teachers { display: grid; gap: 20px; }
.teacher { display: grid; grid-template-columns: minmax(260px, 380px) 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; padding: clamp(20px, 3vw, 32px); border-radius: calc(var(--radius) + 8px); background: var(--bg); }
.teacher:nth-child(even) { grid-template-columns: 1fr minmax(260px, 380px); }
.teacher:nth-child(even) .portrait { order: 2; }
.portrait { aspect-ratio: 4 / 5; border-radius: var(--radius); background: var(--white); display: grid; place-items: center; text-align: center; font-size: .85rem; color: var(--ink-2); }
.portrait { overflow: hidden; position: relative; }
.portrait img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 48%; }
.teacher .eyebrow { display: block; margin-bottom: 12px; }
.teacher h3 { font-size: clamp(2.4rem, 5vw, 3.8rem); letter-spacing: -.045em; }
.teacher .role { font-size: 1.1rem; font-weight: 600; color: var(--ink-2); margin: 10px 0 20px; }
.teacher p { font-size: 1.08rem; color: var(--ink-2); max-width: 52ch; }
.teacher p + p { margin-top: 12px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.tags span { font-size: .85rem; font-weight: 700; padding: 8px 14px; border-radius: 999px; background: var(--white); }

/* stories: auto-scrolling row */
.students-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; }
.story-nav { display: flex; gap: 8px; margin-bottom: clamp(32px, 5vw, 56px); }
.story-nav button { width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--white); box-shadow: inset 0 0 0 1px var(--line); font: 700 1.2rem Figtree; color: var(--ink); cursor: pointer; transition: background-color .2s, transform .25s var(--ease); }
.story-nav button:hover { background: var(--cream); transform: translateY(-2px); }
.marquee { overflow: hidden; touch-action: pan-y; cursor: grab; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee.dragging { cursor: grabbing; user-select: none; }
.marquee-track { display: flex; gap: 16px; width: max-content; will-change: transform; }
.story { width: 340px; flex: none; border-radius: var(--radius); padding: 28px; background: var(--bg); display: flex; flex-direction: column; justify-content: space-between; gap: 28px; }
.story blockquote { font-size: 1.3rem; font-weight: 700; letter-spacing: -.02em; line-height: 1.3; }
.story figcaption { display: flex; align-items: center; gap: 12px; font-size: .9rem; color: var(--ink-2); }
.story figcaption b { display: block; color: var(--ink); font-size: 1rem; }
.story img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 3px var(--white); }

/* faq */
.faq { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 6vw, 80px); }
.faq-list { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; font-weight: 700; font-size: 1.1rem; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; translate: 0 -50%; font-size: 1.5rem; font-weight: 500; transition: rotate .3s var(--ease); }
.faq details[open] summary::after { rotate: 45deg; }
.faq details p { padding: 0 40px 22px 0; color: var(--ink-2); }

/* footer */
.site-footer { padding: 64px 0 48px; }
.foot { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
.foot p { color: var(--ink-2); font-size: .95rem; margin-top: 14px; max-width: 30ch; }
.foot h4 { font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); margin-bottom: 14px; }
.foot ul { list-style: none; padding: 0; display: grid; gap: 8px; }
.foot a { text-decoration: none; font-weight: 600; }
.foot a:hover { text-decoration: underline; }
.legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 24px; font-size: .88rem; color: var(--ink-2); }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* responsive */
@media (max-width: 1000px) {
  .courses { grid-template-columns: 1fr; max-width: 620px; }
  .steps { grid-template-columns: 1fr 1fr; }
  .step:nth-child(3) { padding-left: 0; border-left: 0; }
  .step:nth-child(n+3) { margin-top: 32px; }
  .teacher, .teacher:nth-child(even) { grid-template-columns: 1fr; }
  .teacher:nth-child(even) .portrait { order: 0; }
  .portrait { max-width: 380px; }
}
@media (max-width: 860px) {
  .nav, .site-header .btn-sm { display: none; }
  .menu { display: block; }
  .hero-card, .faq { grid-template-columns: 1fr; }
  .formats { grid-template-columns: 1fr; }
  .morph { width: min(100%, 300px); }
  .morph .ch { --s: 300px; }
  .foot { grid-template-columns: 1fr 1fr; }
  .foot > div:first-child { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .steps { grid-template-columns: 1fr; }
  .step + .step { padding-left: 0; border-left: 0; margin-top: 24px; }
  .story { width: 82vw; max-width: 320px; }
  .story-nav { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .morph .ch { animation: none; } .morph .o { opacity: 1; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
