/* Member app + test + start pages. Builds on site.css tokens (--bg, --ink, --muted, --hairline, --serif, --sans). Mobile first. */
body.app, body.page { padding-bottom: 0; }
.a-wrap { max-width: var(--maxw); margin: 0 auto; padding: 7rem var(--pad) 5rem; }
.a-narrow { max-width: 760px; }
.a-h1 { font-size: clamp(1.9rem, 6vw, 3rem); line-height: 1.15; margin: 0.9rem 0 0.6rem; }
.a-h2 { font-size: clamp(1.25rem, 3.4vw, 1.7rem); line-height: 1.2; margin: 2.4rem 0 1rem; }
.a-h3 { font-family: var(--sans); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); margin: 2rem 0 0.8rem; }
.a-muted { color: var(--ink-2); }
.a-small { font-size: 0.85rem; }
.a-big { font-family: var(--serif); font-size: clamp(1.6rem, 5vw, 2.3rem); line-height: 1.2; }
.a-label { font-size: 0.66rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--faint); margin-bottom: 0.6rem; }
.a-back { display: inline-block; font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); text-decoration: none; margin-bottom: 1.2rem; }
.a-back:hover { color: var(--ink); }
.a-card { border: 1px solid var(--hairline); background: rgba(var(--ink-rgb), 0.03); padding: 1.4rem 1.5rem; margin-bottom: 1rem; }
.a-card p + p { margin-top: 0.5rem; }
.a-hero { padding: 2.2rem 1.6rem; }
.a-hero .btn-solid { margin-top: 1.4rem; }
.a-empty { text-align: center; padding: 2.4rem 1.4rem; }
.a-empty .btn-solid, .a-empty .btn-line { margin-top: 1.2rem; }
.a-wrap a.btn-solid, .a-wrap a.btn-line, .t-wrap a.btn-solid, .t-wrap a.btn-line { display: inline-block; text-decoration: none; text-align: center; }
.a-wrap .btn-solid, .t-wrap .btn-solid { padding: 1rem 1.6rem; }
.a-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.8rem 0 0.9rem; }
.a-badge { border: 1px solid var(--hairline); border-radius: 999px; padding: 0.3rem 0.9rem; font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-2); }
.a-badge:first-child { border-color: rgba(var(--ink-rgb), 0.7); color: var(--ink); }

/* today / lists */
.a-today { display: grid; gap: 0.7rem; }
.a-item { display: flex; align-items: center; justify-content: space-between; gap: 1rem; border: 1px solid var(--hairline); background: rgba(var(--ink-rgb), 0.03); padding: 1.1rem 1.3rem; text-decoration: none; color: var(--ink); transition: border-color 0.2s ease, background 0.2s ease; }
a.a-item:hover { border-color: rgba(var(--ink-rgb), 0.6); background: rgba(var(--ink-rgb), 0.06); }
.a-item strong { display: block; font-weight: 700; font-size: 1rem; }
.a-item span { display: block; color: var(--ink-2); font-size: 0.85rem; }
.a-item em { font-style: normal; font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; white-space: nowrap; color: var(--ink-2); }
.a-item.static .btn-solid, .a-item.static .btn-line { margin: 0; white-space: nowrap; padding: 0.8rem 1.1rem; }
.a-next { margin-top: 1.6rem; }
.a-next .btn-line { margin-top: 1rem; }
.a-dates { list-style: none; display: grid; gap: 0.5rem; }
.a-dates li { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--hairline-soft); padding: 0.7rem 0; }
.a-dates li.first strong { color: var(--ink); } .a-dates li span { color: var(--muted); }
.a-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.a-qr { display: flex; align-items: center; gap: 1.1rem; text-decoration: none; color: var(--ink); }
.a-qr img { width: 112px; height: 112px; flex: none; background: #f1ece0; padding: 6px; }
.a-qr strong { display: block; } .a-qr span { color: var(--muted); font-size: 0.85rem; }
.a-list { list-style: none; margin: 0.6rem 0 1.1rem; } .a-list li { padding: 0.3rem 0; border-bottom: 1px solid var(--hairline-soft); font-size: 0.95rem; }

/* choices / chips (onboarding) */
.a-choices { display: grid; gap: 0.7rem; }
.a-choice { text-align: left; font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 1rem 1.2rem; cursor: pointer; transition: border-color 0.2s ease, background 0.2s ease; }
.a-choice strong { display: block; } .a-choice span { color: var(--muted); font-size: 0.85rem; }
.a-choice.on { border-color: var(--accent); background: rgba(var(--ink-rgb), 0.08); }
.a-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.a-chip { font: inherit; font-size: 0.85rem; text-transform: capitalize; color: var(--ink-2); background: transparent; border: 1px solid var(--hairline); border-radius: 999px; padding: 0.55rem 1.1rem; cursor: pointer; min-height: 44px; }
.a-chip.on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.a-field { margin-top: 1rem; } .a-field label { display: block; font-size: 0.8rem; color: var(--muted); margin-bottom: 0.4rem; }
.a-field input, .a-gap input { font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 0.8rem 1rem; width: 100%; max-width: 320px; color-scheme: dark; }
.a-narrow .err { color: var(--danger); margin: 1rem 0 0.2rem; min-height: 1.3rem; font-size: 0.9rem; }

/* account */
.a-id { display: flex; align-items: center; justify-content: space-between; gap: 1rem; font-family: var(--serif); font-size: clamp(1.4rem, 6vw, 2rem); letter-spacing: 0.1em; }
.a-toggle { display: flex; gap: 0.9rem; align-items: flex-start; padding: 0.6rem 0; cursor: pointer; }
.a-toggle input { width: 22px; height: 22px; margin-top: 0.2rem; accent-color: var(--ink); flex: none; }
.a-toggle strong { display: block; } .a-toggle em { font-style: normal; color: var(--muted); font-size: 0.85rem; }
.a-danger input { font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 0.7rem 1rem; margin: 0.6rem 0.6rem 0.6rem 0; }
.btn-line.danger { border-color: var(--danger); color: var(--danger); } .btn-line.danger:hover:not(:disabled) { background: var(--danger); color: var(--on-accent); } .btn-line:disabled { opacity: 0.4; cursor: not-allowed; }

/* lesson */
.a-sec { margin-top: 0.4rem; }
.a-examples { list-style: none; display: grid; gap: 0.9rem; }
.a-examples li { border-left: 2px solid var(--hairline); padding-left: 1rem; }
.a-examples .de { display: block; font-family: var(--serif); font-size: 1.25rem; } .a-examples .en { display: block; color: var(--muted); font-size: 0.9rem; }
.a-verb { background: transparent; color: var(--ink); border-bottom: 2px solid var(--ink); padding-bottom: 1px; font-weight: 600; }
.a-rule { font-family: var(--serif); font-size: clamp(1.2rem, 4vw, 1.5rem); line-height: 1.4; border: 1px solid rgba(var(--ink-rgb), 0.5); padding: 1.1rem 1.3rem; margin-bottom: 0.8rem; }
.a-tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.a-table { border-collapse: collapse; width: 100%; min-width: 420px; }
.a-table th, .a-table td { text-align: left; padding: 0.65rem 0.9rem; border-bottom: 1px solid var(--hairline-soft); font-size: 0.95rem; }
.a-table th { font-size: 0.64rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.a-table .v { background: rgba(var(--ink-rgb), 0.08); font-weight: 700; }
.a-errors { display: grid; gap: 0.9rem; }
.a-error { border: 1px solid var(--hairline); padding: 1rem 1.2rem; }
.a-error .x { color: var(--danger); text-decoration: line-through; text-decoration-color: rgba(var(--danger-rgb), 0.6); }
.a-error .ok { color: var(--ok); margin-bottom: 0.4rem; } .a-error .sym { text-decoration: none; display: inline-block; font-weight: 700; }
.a-q { font-family: var(--serif); font-size: 1.3rem; margin-bottom: 1rem; }
.a-opts { display: grid; gap: 0.6rem; }
.a-opt { text-align: left; font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 0.9rem 1.1rem; cursor: pointer; min-height: 48px; }
.a-opt:hover:not(:disabled) { border-color: rgba(var(--ink-rgb), 0.6); }
.a-opt.right { border-color: var(--ok); background: rgba(158, 230, 176, 0.12); } .a-opt.wrong { border-color: var(--danger); background: rgba(var(--danger-rgb), 0.12); }
.a-gap { display: flex; gap: 0.7rem; flex-wrap: wrap; } .a-gap .btn-solid { margin: 0; }
.a-gap input.right { border-color: var(--ok); } .a-gap input.wrong { border-color: var(--danger); }
.a-fb { margin: 1rem 0 0.4rem; padding: 0.9rem 1.1rem; border-left: 3px solid; font-size: 0.95rem; } .a-fb.good { border-color: var(--ok); background: rgba(158, 230, 176, 0.08); } .a-fb.bad { border-color: var(--danger); background: rgba(var(--danger-rgb), 0.08); }
.a-practice .btn-solid { margin-top: 0.6rem; }
.a-result { text-align: center; } .a-result .btn-line { margin-top: 1rem; }
.a-words { list-style: none; columns: 2; column-gap: 1.5rem; margin: 0.8rem 0 1.2rem; } .a-words li { break-inside: avoid; padding: 0.35rem 0; border-bottom: 1px solid var(--hairline-soft); display: flex; justify-content: space-between; gap: 0.6rem; } .a-words span { color: var(--muted); }
.a-sec + .btn-line, .a-narrow > .btn-line { margin-top: 2rem; }

/* flashcards */
.a-rev-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.a-flash { min-height: 230px; display: flex; flex-direction: column; justify-content: center; text-align: center; padding: 2rem 1.2rem; }
.a-front { font-family: var(--serif); font-size: clamp(2rem, 9vw, 3rem); line-height: 1.2; }
.a-back-face { margin-top: 1.4rem; padding-top: 1.2rem; border-top: 1px solid var(--hairline); }
.a-answer { font-size: 1.3rem; } .a-ex { color: var(--muted); font-style: italic; margin-top: 0.5rem; }
.a-reveal { width: 100%; margin-top: 0.4rem; min-height: 52px; }
.a-rates { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.5rem; margin-top: 0.4rem; }
.a-rate { font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 0.8rem 0.2rem; cursor: pointer; min-height: 64px; position: relative; }
.a-rate strong { display: block; font-size: 0.85rem; } .a-rate span { display: block; color: var(--muted); font-size: 0.75rem; }
.a-rate kbd { position: absolute; top: 3px; right: 6px; font: inherit; font-size: 0.6rem; color: var(--faint); }
.a-rate.r1:hover { border-color: var(--danger); } .a-rate.r2:hover { border-color: var(--warn); } .a-rate.r3:hover { border-color: var(--ok); } .a-rate.r4:hover { border-color: var(--info); }
.a-rate:active { background: rgba(var(--ink-rgb), 0.1); }

/* header + bottom tab bar */
.nav-links .nav-link.on { color: var(--ink); border-bottom: 1px solid var(--accent); padding-bottom: 2px; }
.tabbar { display: none; }
@media (max-width: 780px) {
  .nav.member .nav-link { display: none; }
  .nav.public .nav-links { gap: 1rem; } .nav.public .nav-link { font-size: 0.6rem; }
  .nav.public .btn-pill { padding: 0.45rem 0.9rem !important; font-size: 0.58rem; }
  body.app { padding-bottom: 76px; }
  .a-wrap { padding-top: 6rem; }
  .a-grid2 { grid-template-columns: 1fr; }
  .a-words { columns: 1; }
  .tabbar { display: grid; grid-template-columns: repeat(4, 1fr); position: fixed; inset: auto 0 0 0; z-index: 60; background: rgba(var(--bg-rgb), 0.96); border-top: 1px solid var(--hairline); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar .tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 60px; color: var(--muted); text-decoration: none; background: none; border: 0; font: inherit; font-size: 0.62rem; letter-spacing: 0.16em; text-transform: uppercase; cursor: pointer; }
  .tabbar .tab i { width: 18px; height: 18px; border: 1px solid currentColor; border-radius: 50%; display: block; }
  .tabbar .tab.on { color: var(--ink); } .tabbar .tab.on i { background: var(--accent); }
  .tabbar .more-sheet { position: absolute; right: 8px; bottom: 68px; background: var(--surface); border: 1px solid var(--hairline); min-width: 190px; display: grid; }
  .tabbar .more-sheet[hidden] { display: none; }
  .tabbar .more-sheet a, .tabbar .more-sheet button { padding: 0.95rem 1.2rem; color: var(--ink-2); text-decoration: none; background: none; border: 0; border-bottom: 1px solid var(--hairline-soft); font: inherit; font-size: 0.8rem; text-align: left; cursor: pointer; }
  .tabbar .more-sheet button { color: var(--danger); border-bottom: 0; }
  .a-item { flex-direction: column; align-items: flex-start; } .a-item em { align-self: flex-end; }
  .a-item.static { flex-direction: row; align-items: center; }
}

/* placement test + start (public pages) */
.t-wrap { max-width: 720px; margin: 0 auto; padding: 7rem var(--pad) 4rem; }
.t-bar { height: 3px; background: var(--hairline); margin: 1rem 0 1.6rem; } .t-bar i { display: block; height: 100%; background: var(--accent); transition: width 0.3s ease; }
.t-meta { display: flex; justify-content: space-between; color: var(--muted); font-size: 0.8rem; }
.t-text { border-left: 2px solid var(--hairline); padding: 0.2rem 0 0.2rem 1rem; margin-bottom: 1.2rem; font-family: var(--serif); font-size: 1.2rem; line-height: 1.55; }
.t-q { font-family: var(--serif); font-size: clamp(1.3rem, 5vw, 1.7rem); line-height: 1.35; margin-bottom: 1.2rem; }
.t-opts { display: grid; gap: 0.6rem; }
.t-opt { text-align: left; font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 1rem 1.1rem; cursor: pointer; min-height: 52px; font-size: 1rem; }
.t-opt:hover, .t-opt.on { border-color: var(--accent); } .t-opt.on { background: rgba(var(--ink-rgb), 0.1); }
.t-opt.skip { color: var(--muted); border-style: dashed; font-size: 0.9rem; }
.t-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 1.4rem; } .t-nav button { margin: 0; }
.t-level { font-family: var(--serif); font-size: clamp(4rem, 22vw, 7rem); line-height: 1; text-align: center; margin: 1rem 0 0.2rem; }
.t-skills { list-style: none; margin: 1.4rem 0; } .t-skills li { display: flex; justify-content: space-between; padding: 0.7rem 0; border-bottom: 1px solid var(--hairline-soft); } .t-skills strong { font-family: var(--serif); font-size: 1.2rem; }
.t-cta { display: grid; gap: 0.8rem; margin-top: 1.6rem; } .t-cta .btn-solid, .t-cta .btn-line { margin: 0; width: 100%; }
.s-goals { display: grid; gap: 0.8rem; margin: 1.8rem 0; }
.s-qr { display: flex; align-items: center; gap: 1.2rem; margin-top: 2.4rem; padding-top: 1.6rem; border-top: 1px solid var(--hairline); }
.s-qr img { width: 120px; height: 120px; background: #f1ece0; padding: 7px; flex: none; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
/* ---- admin window (/app/admin): class names must stay "adm-", not "ad-" — ad blockers hide ad-grid / ad-card / ad-bar / ad-head / ad-tag ---- */
.adm-bar { margin: 1.2rem 0 0.6rem; } .adm-bar input { font: inherit; color: var(--ink); background: transparent; border: 1px solid var(--hairline); padding: 0.9rem 1rem; width: 100%; max-width: 480px; }
.adm-bar input:focus { outline: none; border-color: var(--accent); }
.adm-stats { color: var(--ink-2); font-size: 0.85rem; margin-bottom: 1.2rem; }
.adm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 1rem; align-items: start; } .adm-grid > .a-empty { grid-column: 1 / -1; }
.adm-card { margin-bottom: 0; } .adm-card p { overflow-wrap: anywhere; }
.adm-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.8rem; } .adm-name { font-family: var(--serif); font-size: 1.25rem; font-weight: 400; overflow-wrap: anywhere; }
.adm-del, .adm-make { padding: 0.45rem 0.9rem; font-size: 0.7rem; flex: none; margin: 0; }
.adm-acts { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.5rem; }
.adm-id { font-variant-numeric: lining-nums tabular-nums; letter-spacing: 0.06em; margin-top: 0.5rem; } .adm-mail { color: var(--ink-2); font-size: 0.9rem; }
.adm-status { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0.8rem 0; }
.adm-tag { border: 1px solid var(--hairline); border-radius: 999px; padding: 0.25rem 0.75rem; font-size: 0.65rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-2); flex: none; }
.adm-tag.ok { border-color: var(--ok); color: var(--ok); } .adm-tag.no { border-color: var(--warn); color: var(--warn); }
.adm-ints { display: inline-flex; flex-wrap: wrap; gap: 0.35rem; vertical-align: middle; } .adm-int { border: 1px solid var(--hairline); border-radius: 999px; padding: 0.15rem 0.6rem; font-size: 0.8rem; text-transform: capitalize; color: var(--ink-2); }

/* ---- v2: technical minimalism for the app, test and start pages (rounded surfaces, mono details, page transitions) ---- */
.a-route { animation: routeIn 0.6s var(--ease) both; }
.t-wrap { animation: routeIn 0.7s var(--ease) both; }
@keyframes routeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.a-card, .a-item, .a-choice, .t-opt, .adm-card, .step { border-radius: 12px; background: var(--surface); }
.a-chip, .a-badge, .adm-tag, .adm-int { font-family: var(--mono); letter-spacing: 0.02em; text-transform: none; }
.a-label, .a-h3, .a-back, .t-meta { font-family: var(--mono); letter-spacing: 0.02em; text-transform: none; }
.a-h1, .a-h2, .p-hello { letter-spacing: -0.035em; font-weight: 600; }
.a-item, .a-choice, .t-opt { transition: border-color 0.2s ease, transform 0.3s var(--ease); }
a.a-item:hover, .a-choice:hover, .t-opt:hover { transform: translateY(-2px); border-color: var(--ink); }
.a-field input, .a-gap input, .adm-bar input, .set-select { border-radius: 8px; background: var(--bg); }
.t-bar { border-radius: 3px; overflow: hidden; } .t-bar i { border-radius: 3px; }
.t-level { font-weight: 600; letter-spacing: -0.06em; }
.a-qr img, .s-qr img { border-radius: 10px; background: #fff; }
.tabbar { background: rgba(var(--bg-rgb), 0.9); backdrop-filter: blur(12px); }
.tabbar .more-sheet { border-radius: 12px; background: var(--surface); }

/* ---- dashboard: greeting, level scale, counters, today list; the member card on the side ---- */
.d-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(2rem, 4vw, 3.5rem); align-items: start; }
.d-side { position: sticky; top: 6rem; display: grid; gap: 0.8rem; justify-items: center; animation: routeIn 0.9s var(--ease) 0.15s both; }
.d-avatar { background: none; border: 0; font-family: var(--mono); font-size: 0.74rem; color: var(--muted); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.d-avatar:hover { color: var(--ink); }
.d-hello em { font-style: normal; color: var(--faint); }
.d-scale { margin: 2rem 0 1.4rem; }
.d-track { height: 4px; border-radius: 4px; background: var(--hairline-soft); overflow: hidden; }
.d-track i { display: block; height: 100%; width: calc((var(--lv) + 1) / 6 * 100%); background: var(--ink); border-radius: 4px; transform-origin: left; animation: grow 1.4s var(--ease) 0.3s both; }
.d-marks { display: grid; grid-template-columns: repeat(6, 1fr); margin-top: 0.55rem; font-family: var(--mono); font-size: 0.72rem; color: var(--faint-2); }
.d-marks .past { color: var(--faint); } .d-marks .on { color: var(--ink); font-weight: 600; }
@keyframes grow { from { transform: scaleX(0); } to { transform: none; } }
.d-stats { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--hairline); border-radius: 12px; background: var(--surface); }
.d-stat { padding: 1rem 1.2rem; border-left: 1px solid var(--hairline-soft); }
.d-stat:first-child { border-left: 0; }
.d-stat b { display: block; font-size: clamp(1.6rem, 3.4vw, 2.2rem); font-weight: 600; letter-spacing: -0.04em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.d-stat span { font-family: var(--mono); font-size: 0.68rem; color: var(--muted); }
.d-today .a-item { animation: routeIn 0.7s var(--ease) both; animation-delay: calc(0.25s + var(--i) * 0.08s); }

/* ---- member card ---- */
.mc-scene { perspective: 1100px; width: 100%; max-width: 340px; }
.mcard { position: relative; aspect-ratio: 5 / 7.2; transform-style: preserve-3d; transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform 0.5s var(--ease); }
.mcard:hover { transition: transform 0.12s linear; }
.mc-face {
  position: absolute; inset: 0; border-radius: 18px; border: 1px solid var(--hairline); overflow: hidden;
  background: radial-gradient(120% 80% at 20% 0%, rgba(var(--ink-rgb), 0.06), transparent 60%), var(--surface);
  box-shadow: 0 30px 70px -35px rgba(var(--ink-rgb), 0.45); backface-visibility: hidden; -webkit-backface-visibility: hidden;
}
.mc-front { display: flex; flex-direction: column; padding: 1.1rem 1.2rem 1rem; }
.mc-front::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(300px circle at var(--mx, 30%) var(--my, 0%), rgba(var(--ink-rgb), 0.07), transparent 60%); }
.mc-back { transform: rotateY(180deg); display: grid; place-content: center; justify-items: center; gap: 1rem; font-family: var(--mono); font-size: 0.7rem; color: var(--faint);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 16px 16px; }
.mc-back .logo-mark { width: 56px; height: 56px; }
.mc-top { display: flex; align-items: center; gap: 0.5rem; font-family: var(--mono); font-size: 0.7rem; color: var(--ink-2); }
.mc-top .logo-mark { width: 18px; height: 18px; }
.mc-kind { margin-left: auto; color: var(--faint); text-transform: uppercase; letter-spacing: 0.08em; }
.mc-avatar { flex: 1; position: relative; min-height: 120px; margin: 0.4rem -0.4rem; }
.mc-avatar .ascii { position: absolute; inset: 0; }
.mc-name { font-size: 1.45rem; font-weight: 600; letter-spacing: -0.035em; line-height: 1.15; overflow-wrap: anywhere; }
.mc-id { font-family: var(--mono); font-size: 0.74rem; color: var(--faint); letter-spacing: 0.06em; margin-top: 0.15rem; }
.mc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.4rem; margin: 0.8rem 0 0.6rem; padding-top: 0.7rem; border-top: 1px solid var(--hairline-soft); }
.mc-grid span { display: block; font-family: var(--mono); font-size: 0.6rem; color: var(--faint); text-transform: uppercase; letter-spacing: 0.06em; }
.mc-grid b { font-size: 0.86rem; font-weight: 600; }
.mc-tags { display: flex; flex-wrap: wrap; gap: 0.3rem; min-height: 1.6rem; }
.mc-tags span { font-family: var(--mono); font-size: 0.62rem; border: 1px solid var(--hairline); border-radius: 999px; padding: 0.12rem 0.5rem; color: var(--muted); }
.mc-tags .off { border-style: dashed; }
.mc-foot { display: flex; justify-content: space-between; align-items: end; gap: 0.6rem; margin-top: 0.7rem; font-family: var(--mono); font-size: 0.62rem; color: var(--faint); }
.mc-bar { letter-spacing: -0.12em; color: var(--ink-2); overflow: hidden; white-space: nowrap; }
.mc-scene.intro .mcard { animation: cardIn 1.7s var(--ease) both; }
@keyframes cardIn {
  0% { opacity: 0; transform: translateY(90px) rotateX(28deg) rotateY(-200deg) scale(0.6); }
  55% { opacity: 1; }
  100% { opacity: 1; transform: none; }
}

/* reveal / picker dialog */
dialog.mc-dialog { width: min(420px, calc(100vw - 1.5rem)); max-height: calc(100svh - 1.5rem); overflow: auto; text-align: center; }
.mc-dialog .eyebrow { justify-content: center; }
.mc-dialog h2 { margin: 0.5rem 0 1.2rem; }
.mc-dialog .mc-scene { margin: 0 auto; max-width: 280px; }
.mc-dialog .sub { margin: 1.2rem 0 0.8rem; }
.av-opts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem; }
.av-opt { display: grid; gap: 0.3rem; justify-items: center; background: var(--bg); border: 1px solid var(--hairline); border-radius: 12px; padding: 0.5rem 0.4rem 0.6rem; cursor: pointer; color: var(--muted); font-family: var(--mono); font-size: 0.72rem; transition: border-color 0.2s ease, transform 0.3s var(--ease); }
.av-opt:hover { transform: translateY(-2px); }
.av-opt.on { border-color: var(--ink); color: var(--ink); }
.av-opt .ascii { width: 100%; height: 76px; cursor: pointer; }
.mc-dialog .btn-solid { width: 100%; margin-top: 1rem; }

@media (max-width: 960px) {
  .d-wrap { grid-template-columns: 1fr; }
  .d-side { position: static; order: -1; }
  .d-side .mc-scene { max-width: 300px; }
}
@media (max-width: 520px) { .d-stat { padding: 0.8rem; } }
@media (prefers-reduced-motion: reduce) { .mc-scene.intro .mcard, .d-track i, .d-today .a-item, .d-side { animation: none !important; } }

/* ---- cards: 3D flip cards with live ASCII associations ---- */
.fc { position: relative; width: 100%; max-width: 580px; aspect-ratio: 1.5; margin: 0 auto; perspective: 1400px; cursor: pointer; z-index: 2; }
.fc-inner { position: absolute; inset: 0; transform-style: preserve-3d; transform: rotateX(var(--rx, 0deg)) rotateY(calc(var(--flip, 0deg) + var(--ry, 0deg))); transition: transform 0.85s cubic-bezier(0.3, 1.25, 0.4, 1); }
.fc.flipped { --flip: 180deg; }
.fc-face {
  position: absolute; inset: 0; border-radius: 20px; border: 1px solid var(--hairline); overflow: hidden;
  background: radial-gradient(120% 90% at 15% 0%, rgba(var(--ink-rgb), 0.06), transparent 55%), var(--surface);
  background-image: radial-gradient(120% 90% at 15% 0%, rgba(var(--ink-rgb), 0.06), transparent 55%), linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: auto, 24px 24px, 24px 24px;
  box-shadow: 0 40px 80px -45px rgba(var(--ink-rgb), 0.5); backface-visibility: hidden; -webkit-backface-visibility: hidden;
}
.fc-front { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.6rem; padding: 1.4rem; text-align: center; }
.fc-tag { position: absolute; top: 1rem; left: 1.1rem; font-family: var(--mono); font-size: 0.68rem; color: var(--faint); text-transform: uppercase; letter-spacing: 0.06em; }
.fc-word { font-size: clamp(2.2rem, 7vw, 3.8rem); font-weight: 600; letter-spacing: -0.045em; line-height: 1.05; }
.fc-hint { position: absolute; bottom: 1rem; font-family: var(--mono); font-size: 0.68rem; color: var(--faint); }
.fc-back { transform: rotateY(180deg); display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 0.5rem; padding: 1rem 1.4rem 1rem 0.6rem; }
.fc-obj { position: relative; height: 100%; min-height: 160px; }
.fc-obj .ascii { position: absolute; inset: 0; }
.fc-meaning { display: grid; gap: 0.45rem; }
.fc-small { font-family: var(--mono); font-size: 0.74rem; color: var(--faint); }
.fc-ans { font-size: clamp(1.4rem, 3.6vw, 2rem); font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; }
.fc-ex { color: var(--muted); font-size: 0.95rem; border-left: 2px solid var(--hairline); padding-left: 0.7rem; }
.fc.in { animation: fcIn 0.65s var(--ease) both; }
.fc.out-l { animation: fcOutL 0.42s var(--ease) forwards; }
.fc.out-r { animation: fcOutR 0.42s var(--ease) forwards; }
@keyframes fcIn { from { opacity: 0; transform: translateY(26px) scale(0.94); } to { opacity: 1; transform: none; } }
@keyframes fcOutL { to { opacity: 0; transform: translateX(-70%) rotate(-9deg); } }
@keyframes fcOutR { to { opacity: 0; transform: translateX(70%) rotate(9deg); } }

/* the stack behind the active card */
.fc-stage { position: relative; display: grid; place-items: center; padding: 1rem 0 2.2rem; }
.fc-stage > .fc { grid-area: 1 / 1; }
.fc-ghost { grid-area: 1 / 1; align-self: start; width: 100%; max-width: 580px; aspect-ratio: 1.5; margin-top: 1rem; border-radius: 20px; border: 1px solid var(--hairline-soft); background: var(--surface); }
.fc-ghost.g1 { transform: translateY(14px) scale(0.955); opacity: 0.7; }
.fc-ghost.g2 { transform: translateY(28px) scale(0.91); opacity: 0.4; }

/* review page */
.fc-review { max-width: 760px; }
.fc-top { display: grid; grid-template-columns: auto 1fr auto; gap: 1rem; align-items: center; margin-bottom: 1.6rem; }
.fc-top .a-back { margin: 0; }
.fc-prog { height: 3px; border-radius: 3px; background: var(--hairline-soft); overflow: hidden; }
.fc-prog i { display: block; height: 100%; width: 0; background: var(--ink); transition: width 0.6s var(--ease); }
.fc-count { font-family: var(--mono); font-size: 0.74rem; color: var(--muted); }
.fc-controls { display: grid; justify-items: center; min-height: 92px; }
.fc-flip { animation: routeIn 0.5s var(--ease) both; }
.fc-flip kbd, .fc-rate kbd { font-family: var(--mono); font-size: 0.66rem; border: 1px solid var(--hairline); border-radius: 5px; padding: 0.05rem 0.35rem; color: var(--faint); margin-left: 0.4rem; }
.fc-rates { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.6rem; width: 100%; max-width: 580px; }
.fc-rate { display: grid; gap: 0.15rem; justify-items: center; padding: 0.8rem 0.4rem; border: 1px solid var(--hairline); border-radius: 12px; background: var(--surface); color: var(--ink); cursor: pointer; font: inherit;
  animation: routeIn 0.5s var(--ease) both; animation-delay: calc(var(--i) * 0.06s); transition: border-color 0.2s ease, transform 0.3s var(--ease); }
.fc-rate:hover { border-color: var(--ink); transform: translateY(-2px); }
.fc-rate strong { font-weight: 600; } .fc-rate span { font-family: var(--mono); font-size: 0.7rem; color: var(--muted); }
.fc-rate.r1 strong { color: var(--danger); }
.fc-done { grid-area: 1 / 1; text-align: center; display: grid; justify-items: center; gap: 0.6rem; animation: routeIn 0.7s var(--ease) both; }
.fc-done-obj { position: relative; width: 260px; height: 170px; }
.fc-done-obj .ascii { position: absolute; inset: 0; }

/* cards home */
.fc-home { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.fc-stats { margin: 1.6rem 0 1.4rem; }
.fc-cta { margin-top: 0.2rem; }
.fc-show { padding-top: 0; }
.fc-decks { display: grid; gap: 0.8rem; }
.fc-deck { display: grid; grid-template-columns: 70px 1fr auto; gap: 1.2rem; align-items: center; border: 1px solid var(--hairline); border-radius: 14px; background: var(--surface); padding: 1rem 1.2rem; transition: border-color 0.2s ease; }
.fc-deck:hover { border-color: var(--ink); }
.fc-deck strong { display: block; font-weight: 600; } .fc-deck span { font-family: var(--mono); font-size: 0.72rem; color: var(--muted); }
.fc-deck .btn-solid, .fc-deck .btn-line { margin: 0; white-space: nowrap; }
.fc-deck-pile { position: relative; width: 56px; height: 40px; }
.fc-deck-pile i { position: absolute; inset: 0; border: 1px solid var(--hairline); border-radius: 7px; background: var(--bg); transition: transform 0.4s var(--ease); }
.fc-deck-pile i:nth-child(1) { transform: rotate(-9deg) translate(-3px, 2px); }
.fc-deck-pile i:nth-child(2) { transform: rotate(5deg) translate(3px, 1px); }
.fc-deck-pile i:nth-child(3) { display: grid; place-items: center; font-family: var(--mono); font-size: 0.7rem; font-style: normal; border-color: var(--ink); }
.fc-deck:hover .fc-deck-pile i:nth-child(1) { transform: rotate(-16deg) translate(-8px, 3px); }
.fc-deck:hover .fc-deck-pile i:nth-child(2) { transform: rotate(12deg) translate(8px, 1px); }

@media (max-width: 960px) { .fc-home { grid-template-columns: 1fr; } }
@media (max-width: 600px) {
  .fc { aspect-ratio: 0.82; } .fc-ghost { aspect-ratio: 0.82; }
  .fc-back { grid-template-columns: 1fr; grid-template-rows: 1fr auto; padding: 1rem 1.2rem 1.3rem; }
  .fc-obj { min-height: 170px; }
  .fc-rates { grid-template-columns: repeat(2, 1fr); }
  .fc-deck { grid-template-columns: 56px 1fr; } .fc-deck > button { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) { .fc-inner { transition: none; } }

/* ---- member card: clickable on the dashboard, its own page at /app/card ---- */
.mcard.is-link { cursor: pointer; }
.mcard.is-link:hover .mc-face { border-color: var(--ink); }
.mcard.is-link:focus-visible { outline: none; } .mcard.is-link:focus-visible .mc-face { outline: 2px solid var(--ink); outline-offset: 3px; }
.mc-scene.enter .mcard { animation: cardEnter 1s var(--ease) both; }
@keyframes cardEnter { from { opacity: 0; transform: translateX(-40px) rotateY(-35deg) scale(0.9); } to { opacity: 1; transform: none; } }
.mc-page { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.mc-page-card { position: sticky; top: 6rem; display: grid; justify-items: center; gap: 0.9rem; text-align: center; }
.mc-page-card .mc-scene { max-width: 380px; }
.mc-page-form .a-h3 { margin: 1.6rem 0 0.7rem; }
.mc-page-form .av-opts { max-width: 420px; }
.mc-page-form .a-field input { max-width: 420px; }
.mc-actions { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 1.4rem; }
.mc-actions .btn-solid { margin: 0; }
@media (max-width: 960px) { .mc-page { grid-template-columns: 1fr; } .mc-page-card { position: static; } .mc-page-card .mc-scene { max-width: 320px; } }

/* ---- "About you" (/app/about): one question a screen. Class names must stay "ab-", never "ad-" — ad blockers hide those ---- */
.ab-bar { height: 2px; background: var(--hairline); border-radius: 2px; overflow: hidden; margin: 0 0 1.4rem; }
.ab-bar i { display: block; height: 100%; background: var(--ink); transition: width .25s ease; }
.ab-why { color: var(--muted); font-size: 0.92rem; border-left: 2px solid var(--hairline); padding-left: 0.7rem; margin: 0.6rem 0 1rem; }
.ab-nav { display: flex; gap: 0.6rem; margin-top: 1.4rem; }
.ab-nav .btn-solid { flex: 1; }
.ab-card { margin-top: 0.4rem; }
.ab-row { display: flex; justify-content: space-between; gap: 1rem; padding: 0.5rem 0; border-bottom: 1px solid var(--hairline-soft); }
.ab-row:last-child { border-bottom: 0; }
.ab-row span:first-child { color: var(--muted); }
.ab-row span:last-child { text-align: right; }
.ab-hint { margin-top: 1rem; }
.a-inline { color: inherit; text-decoration: underline; }
.adm-study { color: var(--muted); font-size: 0.92rem; }

/* ---- dashboard notice: shown once to members who have not answered "About you" yet ---- */
.d-note { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  border: 1px solid var(--hairline); border-radius: 12px; background: var(--surface); padding: 0.9rem 1.1rem; margin-bottom: 1.4rem; }
.d-note-tag { font-family: var(--mono, inherit); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 0.2rem; }
.d-note-text { margin: 0; font-size: 0.95rem; max-width: 46ch; }
.d-note .btn-line { margin: 0; white-space: nowrap; }
.d-note-btns { display: flex; gap: 0.5rem; flex-wrap: wrap; }
@media (max-width: 560px) { .d-note .btn-line { width: 100%; text-align: center; } }
@media (max-width: 560px) { .d-note-btns { width: 100%; flex-direction: column; } }

/* Club presentations (assets/app-talks.js): deck in a 16:9 frame, bar with ‹ n / N › and full screen */
.tk-section { margin-top: 0.5rem; }
.tk { margin: 1rem 0 1.4rem; }
.tk-view { border: 1px solid var(--hairline); background: #000; }
.tk-box { position: relative; aspect-ratio: 16 / 9; width: 100%; }
.tk-frame { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #0c0a08; }
.tk-bar { display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.7rem; border-top: 1px solid var(--hairline); background: var(--bg); }
.tk-btn { font: inherit; font-family: "Geist Mono", ui-monospace, monospace; background: none; color: var(--ink); border: 1px solid var(--hairline); padding: 0.35rem 0.8rem; min-width: 2.75rem; min-height: 2.75rem; cursor: pointer; }
.tk-btn:hover:not(:disabled) { border-color: rgba(var(--ink-rgb), 0.7); }
.tk-btn:disabled { opacity: 0.35; cursor: default; }
.tk-btn:focus-visible, .tk-card:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.tk-fs { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; }
.tk-count { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.85rem; color: var(--ink-2); min-width: 4.5rem; text-align: center; }
.tk-gap { flex: 1; }
.tk-view:fullscreen { display: flex; flex-direction: column; border: 0; width: 100vw; height: 100vh; }
.tk-view:fullscreen .tk-box { flex: 1; aspect-ratio: auto; }
.tk-view:-webkit-full-screen { display: flex; flex-direction: column; width: 100vw; height: 100vh; }
.tk-view:-webkit-full-screen .tk-box { flex: 1; aspect-ratio: auto; }
.tk-view.tk-max { position: fixed; inset: 0; z-index: 1000; display: flex; flex-direction: column; border: 0; }
.tk-view.tk-max .tk-box { flex: 1; aspect-ratio: auto; }
html.tk-lock, html.tk-lock body { overflow: hidden; }
.a-route.tk-still { animation: none; } /* a running (fill: both) transform animation would trap position:fixed */

/* Presentations history on /app/club: a grid of cards (cover flips through slides on hover) → own page per deck */
.tk-intro { margin-bottom: 1.2rem; }
.tk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.2rem; margin-bottom: 1rem; }
.tk-card { display: block; color: var(--ink); text-decoration: none; border: 1px solid var(--hairline); background: rgba(var(--ink-rgb), 0.02); transition: border-color 0.25s ease, background 0.25s ease; }
.tk-card:hover { border-color: rgba(var(--ink-rgb), 0.55); background: rgba(var(--ink-rgb), 0.04); }
.tk-cover { position: relative; aspect-ratio: 16 / 9; background: #0c0a08; overflow: hidden; border-bottom: 1px solid var(--hairline); }
.tk-cover-img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tk-cover-n { position: absolute; right: 0.6rem; top: 0.6rem; font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase; color: #ededed; background: rgba(10, 10, 10, 0.72); padding: 0.25rem 0.5rem; }
.tk-meta { padding: 1rem 1.1rem 1.15rem; }
.tk-date { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.tk-title { font-size: 1.35rem; font-weight: 600; letter-spacing: -0.02em; margin: 0.35rem 0 0; }
.tk-sum { margin-top: 0.4rem; font-size: 0.88rem; color: var(--ink-2); }
.tk-page .tk { margin-top: 1.4rem; max-width: max(320px, calc((100vh - 9rem) * 16 / 9)); } /* slide + bar fit on one screen */
/* Dashboard "next meeting" card (assets/app-nextcard.js): pixel cat + the date in bold Geist, ink colour only */
.nc { display: flex; align-items: center; gap: 1.4rem; margin: 1.6rem 0 0.4rem; padding: 1.1rem 1.3rem; border: 1px solid var(--hairline); color: var(--ink); text-decoration: none; transition: border-color 0.2s ease; }
.nc:hover { border-color: rgba(var(--ink-rgb), 0.6); }
.nc-pic { flex: none; width: 72px; }
.nc-cat { display: block; width: 72px; height: auto; fill: currentColor; }
.nc-cat .nc-eye { fill: var(--bg); animation: ncBlink 5s steps(1) infinite; }
@keyframes ncBlink { 0%, 94% { fill: var(--bg); } 95%, 100% { fill: currentColor; } }
.nc-body { min-width: 0; }
.nc-tag { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.6rem; }
.nc-date { font-size: clamp(1.5rem, 4vw, 2.1rem); font-weight: 700; letter-spacing: -0.03em; line-height: 1.05; }
.nc-sub { margin-top: 0.6rem; font-size: 0.82rem; color: var(--ink-2); }
@media (prefers-reduced-motion: reduce) { .nc-cat .nc-eye { animation: none; } }

/* hover panel on a card: fades in from the bottom of the cover, slides as a timeline strip gliding sideways */
.tk-strip { position: absolute; left: 0; right: 0; bottom: 0; padding: 0.55rem 0 0.5rem; background: rgba(10, 10, 10, 0.86); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); border-top: 1px solid rgba(237, 237, 237, 0.14); overflow: hidden; opacity: 0; transform: translateY(10px); transition: opacity 0.35s ease, transform 0.35s var(--ease, ease); pointer-events: none; }
.tk-card:hover .tk-strip, .tk-card:focus-visible .tk-strip { opacity: 1; transform: none; }
.tk-track { display: flex; gap: 0.4rem; width: max-content; padding-left: 0.55rem; }
.tk-glide { animation: tkGlide calc(var(--n) * 2.2s) linear infinite; animation-play-state: paused; }
.tk-card:hover .tk-glide, .tk-card:focus-visible .tk-glide { animation-play-state: running; }
@keyframes tkGlide { to { transform: translateX(calc(-50% - 0.2rem)); } }
.tk-thumb { margin: 0; width: 5.2rem; flex: none; }
.tk-thumb img { display: block; width: 100%; aspect-ratio: 16 / 9; height: auto; object-fit: cover; background: #1a1a1a; border: 1px solid rgba(237, 237, 237, 0.16); }
.tk-thumb figcaption { font-family: "Geist Mono", ui-monospace, monospace; font-size: 0.58rem; letter-spacing: 0.12em; color: rgba(237, 237, 237, 0.6); margin-top: 0.25rem; }
@media (prefers-reduced-motion: reduce) { .tk-glide { animation: none; } .tk-strip { transition: none; } }
@media (hover: none) { .tk-strip { display: none; } }

/* Copy link (member page) */
.tk-share { display: flex; align-items: center; flex-wrap: wrap; gap: 0.8rem; margin-top: 1rem; }
.tk-copy { font: inherit; cursor: pointer; }
.tk-copied { font-size: 0.82rem; color: var(--ink-2); }

/* public page of one presentation (talk.html) */
.tp-top { padding: 1.1rem clamp(1rem, 4vw, 2rem); border-bottom: 1px solid var(--hairline); }
.tp-top .logo { color: var(--ink); text-decoration: none; display: inline-flex; align-items: center; gap: 0.6rem; }
.tp-top .logo-u { width: 26px; height: 26px; }
.tp .a-wrap { padding-top: 2rem; padding-bottom: 1.5rem; }
.tp-foot.a-wrap { padding-top: 0; padding-bottom: 3rem; }
.adm-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; } .adm-top .a-h1 { margin-bottom: 0; } .adm-top .adm-cx { padding: 0.8rem 1.3rem; }
