:root {
  --canvas: #fbfbfa;
  --surface: #ffffff;
  --ink: #111111;
  --body: #2f3437;
  --muted: #787774;
  --line: #eaeaea;
  --bone: #f7f6f3;
  --ok-bg: #edf3ec;
  --ok-fg: #346538;
  --err-bg: #fdebec;
  --err-fg: #9f2f2d;
  --serif: "Newsreader", "Iowan Old Style", Georgia, serif;
  --sans: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--canvas); color: var(--body); font: 400 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
a { color: var(--ink); text-underline-offset: 3px; }
h1, h2, h3 { color: var(--ink); margin: 0; font-weight: 400; }
.h-serif { font-family: var(--serif); letter-spacing: -0.03em; line-height: 1.08; }
.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 560px; }
.eyebrow { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin: 0 0 18px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.lede { font-size: 19px; color: var(--body); max-width: 34em; }

/* header */
.bar { display: flex; align-items: center; justify-content: space-between; max-width: 1040px; margin: 0 auto; padding: 18px 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--serif); font-size: 21px; letter-spacing: -0.01em; }
.bar .link, .navlink { font: 500 14px/1 var(--sans); color: var(--ink); text-decoration: none; background: none; border: 0; padding: 10px 0; cursor: pointer; }
.navlink:hover, .bar .link:hover { text-decoration: underline; }

/* buttons + inputs */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 22px; border-radius: 6px; border: 1px solid var(--ink); background: var(--ink); color: #fff; font: 500 15px/1 var(--sans); text-decoration: none; cursor: pointer; transition: background-color 0.2s, transform 0.15s; width: auto; }
.btn:hover { background: #333; }
.btn:active { transform: scale(0.98); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { background: var(--bone); }
.btn[disabled] { opacity: 0.55; cursor: default; }
.btn.block { width: 100%; }
.input { width: 100%; min-height: 50px; padding: 0 14px; border: 1px solid #dcdcd8; border-radius: 6px; background: var(--surface); color: var(--ink); font: 400 16px/1 var(--sans); appearance: none; -webkit-appearance: none; }
select.input { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 22px, calc(100% - 15px) 22px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.input:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
label.f { display: block; font-size: 13px; color: var(--muted); margin: 0 0 6px; }
.stack { display: grid; gap: 12px; }
.link.danger { color: var(--err-fg); }

/* hero */
.hero { position: relative; padding: 48px 0 72px; overflow: hidden; }
.hero::before { content: ""; position: absolute; top: 0; right: -30vw; width: 100vw; height: 100vw; max-width: 900px; max-height: 900px; background: radial-gradient(closest-side, rgba(180, 160, 130, 0.10), transparent); pointer-events: none; }
.hero-grid { position: relative; display: grid; gap: 36px; align-items: center; }
.hero h1 { font-size: clamp(44px, 11vw, 84px); }
.hero .lede { margin: 22px 0 30px; }
.hero-mark { width: min(64vw, 300px); justify-self: center; opacity: 0.92; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* sections */
.section { padding: 72px 0; border-top: 1px solid var(--line); }
.section h2 { font-size: clamp(34px, 7vw, 52px); margin-bottom: 14px; }
.section .intro-text { max-width: 36em; margin: 0 0 36px; }
.grid2 { display: grid; gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 28px; transition: box-shadow 0.2s; }
.card:hover { box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04); }
.card h3 { font-family: var(--serif); font-size: 26px; letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 10px; }
.card p { margin: 0; }
.card + .card { margin-top: 0; }
.label { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.value { margin: 0; color: var(--ink); }

/* programs */
.program { display: flex; flex-direction: column; gap: 16px; padding: 32px 28px; }
.program .term { font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin: 0; }
.program .price { font-family: var(--serif); font-size: 64px; line-height: 1; letter-spacing: -0.04em; color: var(--ink); margin: 0; }
.program .price small { font-family: var(--sans); font-size: 15px; letter-spacing: 0; color: var(--muted); margin-left: 6px; }
.program .buy { margin: auto 0 0; padding-top: 20px; border-top: 1px solid var(--line); }
.program .soon { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }

/* waitlist */
.waitlist { background: var(--bone); }
.wl-form { display: grid; gap: 14px; max-width: 560px; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.notice { padding: 14px 16px; border-radius: 8px; background: var(--ok-bg); color: var(--ok-fg); margin: 0 0 16px; font-size: 15px; }
.notice.err { background: var(--err-bg); color: var(--err-fg); }
.done-msg h3 { font-family: var(--serif); font-size: 30px; letter-spacing: -0.02em; margin-bottom: 8px; }

footer.foot { border-top: 1px solid var(--line); padding: 28px 0 40px; font-size: 14px; color: var(--muted); }
footer.foot .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* login + app pages */
.app main { padding: 40px 20px 80px; }
.app h1 { font-size: clamp(38px, 9vw, 56px); margin-bottom: 14px; }
.app .card { margin-top: 16px; }
.or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; margin: 18px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.gbtn { background: var(--surface); color: var(--ink); border-color: #dcdcd8; }
.gbtn:hover { background: var(--bone); }
.code-input { letter-spacing: 0.4em; font-size: 22px; text-align: center; font-family: "SF Mono", Menlo, Consolas, monospace; }
.tbl { width: 100%; border-collapse: collapse; font-size: 15px; }
.tbl td { padding: 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; word-break: break-word; }
.tbl td.r { text-align: right; white-space: nowrap; padding-left: 12px; }
.hidden { display: none !important; }

/* scroll entry */
.js .reveal { opacity: 0; transform: translateY(12px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); transition-delay: calc(var(--n, 0) * 80ms); }
.js .reveal.in { opacity: 1; transform: none; }

@media (min-width: 760px) {
  .wrap, .bar { padding-left: 32px; padding-right: 32px; }
  .hero { padding: 72px 0 112px; }
  .hero-grid { grid-template-columns: 1.25fr 1fr; gap: 56px; }
  .hero-mark { width: 100%; max-width: 380px; }
  .section { padding: 112px 0; }
  .grid2 { grid-template-columns: 1fr 1fr; gap: 20px; }
  .card { padding: 36px; }
  .program { padding: 40px 36px; }
}

/* ---------- intro: split-face line draw, then the face splits along its seam ---------- */
#intro { display: none; }
html.intro #intro { display: block; position: fixed; inset: 0; z-index: 1000; cursor: pointer; animation: intro-failsafe 0s linear 4s forwards; }
html.intro body { overflow: hidden; }
.intro-half { position: absolute; inset: 0; background: var(--canvas); display: grid; place-items: center; }
.intro-half.l { clip-path: inset(0 50% 0 0); }
.intro-half.r { clip-path: inset(0 0 0 50%); }
.intro-half .mark-svg { height: min(70vh, calc(80vw / var(--ar, 1))); width: auto; aspect-ratio: var(--ar, 1); overflow: visible; }
.mark-svg .ink use { fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linejoin: round; stroke-dasharray: 1 1; stroke-dashoffset: 1; animation: intro-draw var(--t) cubic-bezier(0.65, 0, 0.35, 1) var(--d) forwards; }
.mark-svg .fill-l, .mark-svg .fill-r { fill: var(--ink); opacity: 0; }
.mark-svg .fill-l { animation: intro-fade 0.35s ease-out 1.5s forwards; }
.mark-svg .fill-r { animation: intro-fade 0.4s ease-out 1.8s forwards; }
html.intro .intro-half { will-change: transform; }
html.intro .intro-half.l { animation: intro-wipe-l 0.7s cubic-bezier(0.76, 0, 0.24, 1) 2.5s forwards; }
html.intro .intro-half.r { animation: intro-wipe-r 0.7s cubic-bezier(0.76, 0, 0.24, 1) 2.5s forwards; }
html.intro-skip #intro { transition: opacity 0.2s; opacity: 0; }
@keyframes intro-draw { to { stroke-dashoffset: 0; } }
@keyframes intro-fade { to { opacity: 1; } }
@keyframes intro-wipe-l { to { transform: translate3d(-51%, 0, 0); } }
@keyframes intro-wipe-r { to { transform: translate3d(51%, 0, 0); } }
@keyframes intro-failsafe { to { visibility: hidden; pointer-events: none; } }
@keyframes intro-out { to { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .mark-svg .ink use { animation: none; stroke-dashoffset: 0; }
  .mark-svg .fill-l, .mark-svg .fill-r { animation: none; opacity: 1; }
  html.intro .intro-half.l, html.intro .intro-half.r { animation: none; }
  html.intro #intro { animation: intro-out 0.3s ease 0.6s forwards, intro-failsafe 0s linear 1s forwards; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
