:root { --bg:#f7f5f0; --card:#fff; --ink:#22262b; --muted:#5b6370; --line:#e2ddd3; --accent:#2f6f5e; --danger:#b3261e; --warn:#8a5a00; }
* { box-sizing:border-box; }
html { -webkit-text-size-adjust:100%; }
body { margin:0; background:var(--bg); color:var(--ink); font:1rem/1.5 "Onest", system-ui, "Segoe UI", Roboto, sans-serif; overflow-wrap:break-word; }
header { background:var(--card); border-bottom:1px solid var(--line); padding:8px 16px; display:flex; gap:4px 16px; align-items:center; flex-wrap:wrap; }
header a { color:var(--ink); text-decoration:none; display:inline-flex; align-items:center; min-height:44px; }
header a:hover, header a:focus { text-decoration:underline; }
header .brand { font-weight:700; margin-right:auto; }
header .brand.btn { min-height:44px; padding:9px 16px; border-radius:999px; text-align:center; }
header .brand.btn:hover, header .brand.btn:focus { text-decoration:none; }
main { max-width:760px; margin:0 auto; padding:16px; }
main.wide { max-width:1100px; }
a { color:var(--accent); }
.card { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:16px; margin:0 0 16px; }
h1 { font-size:1.6rem; line-height:1.25; margin:8px 0 4px; } h2 { font-size:1.2rem; margin:0 0 8px; } h3 { font-size:1rem; margin:12px 0 4px; }
p { margin:0 0 10px; max-width:80ch; }
.muted { color:var(--muted); font-size:1rem; }
video, img { max-width:100%; border-radius:8px; display:block; margin:0 auto; }
video { max-height:80vh; background:#000; }
audio { width:100%; margin:8px 0; display:block; }
label { display:block; font-weight:600; margin-top:6px; }
label.check { display:flex; gap:10px; align-items:flex-start; font-weight:400; min-height:44px; padding:8px 0; }
label.check input { width:22px; height:22px; flex:none; margin:2px 0 0; }
input[type=text], input[type=search], input[type=password], input[type=email], input[type=date], input[type=number], textarea, select {
  width:100%; min-height:44px; padding:9px 10px; border:1px solid #b9b2a4; border-radius:8px; font:inherit; font-size:1rem; margin:4px 0 10px; background:#fff; color:var(--ink); }
textarea { min-height:90px; }
input[type=file] { max-width:100%; font:inherit; margin:6px 0; min-height:44px; }
button, .btn { font:inherit; min-height:44px; padding:9px 16px; border-radius:12px; border:1px solid var(--accent); background:var(--accent); color:#fff; cursor:pointer; display:inline-flex; align-items:center; justify-content:center; text-decoration:none; gap:6px; transition:background-color .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease, transform .06s ease; }
button.ghost, .btn.ghost { background:transparent; color:var(--accent); }
button.danger, .btn.danger { background:transparent; color:var(--danger); border-color:var(--danger); }
button:hover:not(:disabled), .btn:hover { box-shadow:0 3px 10px rgba(34,38,43,.14); }
button:active:not(:disabled), .btn:active { transform:translateY(1px); box-shadow:0 1px 4px rgba(34,38,43,.10); }
button.ghost:hover:not(:disabled), .btn.ghost:hover { background:rgba(47,111,94,.09); }
button.danger:hover:not(:disabled), .btn.danger:hover { background:rgba(179,38,30,.09); }
button:disabled { opacity:.5; cursor:default; }
:focus-visible { outline:3px solid #1d4ed8; outline-offset:2px; }
form.inline { display:inline; }
.row { display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.row > input, .row > select { width:auto; flex:1 1 150px; margin:0; }
.file { display:flex; gap:8px; align-items:center; justify-content:space-between; border-top:1px solid var(--line); padding:8px 0; flex-wrap:wrap; }
.file > span, .file > a { overflow-wrap:anywhere; min-width:0; flex:1 1 200px; }
.error { color:var(--danger); }
.ok { color:var(--accent); font-weight:600; }
.warn { color:var(--warn); font-weight:600; }
.flash { border-left:4px solid var(--accent); }
.flash.error { border-left-color:var(--danger); }
.tag { font-size:1rem; background:var(--bg); border:1px solid var(--line); border-radius:999px; padding:1px 8px; color:var(--muted); white-space:nowrap; }
.bar { height:8px; background:var(--line); border-radius:999px; margin:6px 0 16px; overflow:hidden; }
.bar i { display:block; height:100%; background:var(--accent); }
.locked { opacity:.75; }
.lesson-link { display:block; color:inherit; text-decoration:none; }
.lesson-link:hover h2, .lesson-link:focus h2 { text-decoration:underline; }
.scroll { overflow-x:auto; -webkit-overflow-scrolling:touch; }
table.grid { border-collapse:collapse; width:100%; }
table.grid th, table.grid td { padding:8px 10px; border-bottom:1px solid var(--line); text-align:left; vertical-align:top; }
table.grid th { font-size:1rem; color:var(--muted); }
pre.doc { white-space:pre-wrap; font:inherit; margin:0; max-width:80ch; }
details summary { cursor:pointer; min-height:44px; display:flex; align-items:center; color:var(--accent); }

/* звуки и слова */
.ipa { font-family:"Charis SIL", "Gentium Plus", "Doulos SIL", "Segoe UI", "Noto Sans", "Lucida Sans Unicode", "DejaVu Sans", sans-serif; }
.sounds { display:grid; grid-template-columns:repeat(4, 1fr); gap:10px; margin:12px 0; }
.sound { position:relative; background:var(--bg); border:1px solid var(--line); border-radius:10px; padding:18px 8px 14px; text-align:center; }
button.sound { display:block; width:100%; font:inherit; color:inherit; min-height:0; cursor:pointer; transition:border-color .15s, background .15s; }
button.sound:hover, button.sound:focus-visible { border-color:var(--accent); }
button.sound.playing { border-color:var(--accent); background:var(--line); }
button.sound:disabled { opacity:1; cursor:default; }
.sound .n { position:absolute; top:6px; left:10px; font-size:1rem; color:var(--muted); }
.sound .ipa { font-size:1.9rem; line-height:1.2; color:var(--accent); }
.sound-row .row { flex-wrap:nowrap; gap:16px; }
.sound-row .sounds { display:block; width:96px; flex:none; margin:0; }
.sound-row p { margin:2px 0; }
.words { border-collapse:collapse; width:100%; margin:12px 0; overflow-wrap:anywhere; }
.words td { padding:8px 10px; border-bottom:1px solid var(--line); }
.words td:first-child { font-weight:700; }
.words td.ipa { color:var(--accent); font-size:1.1rem; white-space:nowrap; }
.words tr:last-child td { border-bottom:0; }

/* водяной знак с именем ученика поверх видео и картинок */
.wm { position:relative; margin:8px 0; overflow:hidden; border-radius:8px; }
.wm.video { background:#000; }
.wm::before, .wm::after { content:attr(data-wm); position:absolute; left:0; right:0; text-align:center; pointer-events:none; color:#fff; opacity:.4;
  text-shadow:0 0 3px #000, 0 0 3px #000; font-size:1rem; transform:rotate(-12deg); z-index:2; }
.wm::before { top:22%; } .wm::after { top:68%; }
/* свой плеер: во весь экран раскрывается рамка с именем, а не системный плеер телефона */
.wm.video video { display:block; width:100%; }
.player { display:flex; align-items:center; gap:6px; padding:0 6px; background:#111; color:#fff; position:relative; z-index:3; }
.player button { width:44px; min-height:44px; padding:0; flex:none; background:transparent; border-color:transparent; color:#fff; }
.player svg { width:22px; height:22px; fill:currentColor; }
.player input[type=range] { flex:1; min-width:0; height:44px; margin:0; accent-color:#fff; }
.player .time { font-size:1rem; white-space:nowrap; font-variant-numeric:tabular-nums; }
.wm:fullscreen { display:flex; flex-direction:column; justify-content:center; border-radius:0; margin:0; background:#000; }
.wm:-webkit-full-screen { display:flex; flex-direction:column; justify-content:center; border-radius:0; margin:0; background:#000; width:100%; height:100%; }
.wm.full { position:fixed; top:0; right:0; bottom:0; left:0; z-index:1000; display:flex; flex-direction:column; justify-content:center;
  border-radius:0; margin:0; background:#000; padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); }
.wm:fullscreen video, .wm.full video { flex:1; max-height:none; min-height:0; object-fit:contain; }
.wm:-webkit-full-screen video { flex:1; max-height:none; min-height:0; object-fit:contain; }
.wm:fullscreen::before, .wm:fullscreen::after, .wm.full::before, .wm.full::after { font-size:1.4rem; }
html.noscroll, html.noscroll body { overflow:hidden; }

/* упражнения */
.q { border:0; padding:0; margin:0 0 14px; min-width:0; }
.q legend { font-weight:700; padding:0; margin-bottom:6px; }
.opt { display:flex; gap:10px; align-items:center; min-height:44px; padding:8px 12px; margin:6px 0; border:1px solid var(--line); border-radius:8px; cursor:pointer; font-weight:400; }
.opt:has(input:checked) { border-color:var(--accent); background:var(--bg); }
.opt input { width:20px; height:20px; flex:none; }
input.bad { border-color:var(--danger); background:#fdf3f2; }
input.good { border-color:var(--accent); background:#f1f8f5; }
ol.order { list-style:none; padding:0; margin:8px 0; }
ol.order li { display:flex; gap:8px; align-items:center; padding:6px 8px 6px 12px; margin:6px 0; background:var(--bg); border:1px solid var(--line); border-radius:8px; touch-action:manipulation; }
ol.order li span { flex:1; min-width:0; }
ol.order li button { width:44px; padding:0; flex:none; }
ol.order li.drag { opacity:.4; }
button.next { padding:10px 22px; margin-top:8px; }

/* запись ответа */
.rec { border:1px dashed #b9b2a4; border-radius:10px; padding:12px; margin:10px 0; }
.rec video { max-height:60vh; margin:8px auto; }
.rec .timer { font-variant-numeric:tabular-nums; font-weight:700; }
.rec .live::before { content:"● "; color:var(--danger); }
.studio-dialog { width:min(760px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow:auto;border:0;border-radius:16px;padding:18px;background:var(--card,#fff);color:var(--ink,#222);box-shadow:0 16px 60px #0007; }
.studio-dialog::backdrop { background:#111a;backdrop-filter:blur(3px); }
.studio-dialog-head { display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:1.15rem; }
.studio-dialog .rec { border:0;padding:4px 0;margin:8px 0; }
.studio-dialog .rec video { width:100%;max-height:min(62dvh,560px);object-fit:contain;background:#111;border-radius:10px; }
.studio-dialog .rec p { display:flex;align-items:center;justify-content:space-between;gap:12px;position:sticky;bottom:0;background:var(--card,#fff);padding:8px 0;margin:0; }
.studio-dialog [data-stop] { min-height:52px;min-width:180px;font-size:1.05rem; }
@media(max-width:480px) and (pointer:coarse) { .studio-dialog { padding:14px; } .studio-dialog .rec p { flex-direction:column;align-items:stretch; } .studio-dialog [data-stop] { width:100%; } }
.studio-dialog-inner { position:relative; }
.studio-dialog-head strong { display:inline-flex; align-items:center; gap:8px; }
.studio-dialog-head strong::before { content:""; width:10px; height:10px; border-radius:50%; background:var(--warn); flex:none; }
.studio-dialog.recording .studio-dialog-head strong::before { background:var(--danger); animation:pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity:1; transform:scale(1); } 50% { opacity:.35; transform:scale(.8); } }
.countdown-big { position:absolute; inset:0; display:flex; align-items:center; justify-content:center; font-size:clamp(88px, 20vw, 150px); font-weight:800; line-height:1; color:var(--accent); background:rgba(255,255,255,.6); backdrop-filter:blur(2px); border-radius:16px; pointer-events:none; z-index:4; }
.countdown-big.tick { animation:count-pop .95s ease-out; }
@keyframes count-pop { 0% { transform:scale(1.4); opacity:.2; } 60% { transform:scale(1); opacity:1; } 100% { transform:scale(.96); opacity:.9; } }
.audio-level { display:flex; gap:7px; align-items:flex-end; justify-content:center; height:72px; margin:20px 0 16px; }
.audio-level i { flex:0 1 12px; width:12px; border-radius:6px; background:var(--accent); opacity:.9; height:14px; }
[data-audio-dialog].recording .audio-level i { animation:level 1.05s ease-in-out infinite; }
[data-audio-dialog].recording .audio-level i:nth-child(2) { animation-delay:.13s; } [data-audio-dialog].recording .audio-level i:nth-child(3) { animation-delay:.26s; }
[data-audio-dialog].recording .audio-level i:nth-child(4) { animation-delay:.39s; } [data-audio-dialog].recording .audio-level i:nth-child(5) { animation-delay:.52s; }
@keyframes level { 0%,100% { height:14px; } 50% { height:64px; } }
p.center { text-align:center; }
.tabs { display:flex; gap:6px; flex-wrap:wrap; margin:0 0 14px; position:sticky; top:0; z-index:20; background:var(--bg); padding:10px 0 8px; }
/* титульная страница для гостей */
.hero { display:grid; grid-template-columns:minmax(0,7fr) minmax(0,5fr); gap:20px; align-items:center;
  background:linear-gradient(135deg,#2f6f5e 0%,#3d8a74 55%,#57a48b 100%); color:#fff; border:0; }
.hero h1 { font-size:clamp(1.6rem,3.2vw,2.3rem); line-height:1.2; margin:6px 0 10px; }
.hero .lead { color:#eaf4f0; font-size:1.08rem; }
.hero-kicker { text-transform:uppercase; letter-spacing:.08em; font-weight:700; font-size:.85rem; color:#cfe7de; margin:0; }
.hero-cta { display:flex; gap:14px; align-items:center; flex-wrap:wrap; margin:16px 0 12px; }
.btn.big { min-height:56px; padding:14px 28px; font-size:1.1rem; font-weight:700; box-shadow:0 8px 24px #0004; }
.hero .btn.big { background:#fff; color:var(--accent); border-color:#fff; }
.quiet-link { color:#dcefe8; text-underline-offset:3px; }
.trust { list-style:none; display:flex; flex-wrap:wrap; gap:6px 14px; margin:0; padding:0; font-size:.92rem; color:#dcefe8; }
.landing-contacts { display:flex; flex-wrap:wrap; gap:10px; margin:4px 0 0; }
.landing-contacts .btn { min-height:44px; background:transparent; color:#eef7f3; border-color:#ffffff59; font-weight:600; }
.landing-contacts .btn:hover { background:#ffffff14; border-color:#ffffff8c; box-shadow:none; }
.landing-contacts .btn.copied { border-color:var(--amber); color:var(--amber); }
.hero-shot { position:relative; }
.hero-shot img { width:100%; max-width:300px; margin:0 auto; border-radius:26px; border:6px solid #fff;
  box-shadow:0 24px 60px #0006; transform:rotate(2.5deg); display:block; }
.steps { list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); gap:10px; counter-reset:step; }
.steps li { counter-increment:step; border:1px solid var(--line); border-radius:12px; padding:12px 12px 12px 44px; position:relative; background:var(--bg); }
.steps li::before { content:counter(step); position:absolute; left:12px; top:12px; width:24px; height:24px; border-radius:50%;
  background:var(--accent); color:#fff; font-weight:700; display:flex; align-items:center; justify-content:center; font-size:.9rem; }
.steps b { display:block; margin-bottom:2px; }
.steps span { color:var(--muted); font-size:.95rem; }
.teacher { display:grid; grid-template-columns:150px minmax(0,1fr); gap:18px; align-items:center; }
.teacher-photo { width:150px; height:150px; border-radius:50%; overflow:hidden; flex:none; margin:0 auto;
  background:linear-gradient(135deg,#3d8a74,#57a48b); display:flex; align-items:center; justify-content:center; }
.teacher-photo img { width:100%; height:100%; object-fit:cover; }
.teacher-photo span { color:#fff; font-size:2.6rem; font-weight:800; letter-spacing:.04em; }
.teacher .facts { color:var(--muted); }
.teacher .facts b { color:var(--accent); font-size:1.15rem; }
#login details { border:1px solid var(--line); border-radius:12px; padding:10px 14px; background:var(--bg); }
#login summary { cursor:pointer; font-weight:600; min-height:44px; display:flex; align-items:center; }
#faq details { border-bottom:1px solid var(--line); padding:4px 0; }
#faq summary { cursor:pointer; font-weight:600; min-height:48px; display:flex; align-items:center; }
.title-footer { text-align:center; color:var(--muted); padding:6px 0 14px; }
.streak-card { display:flex; gap:14px; align-items:center; flex-wrap:wrap; padding:12px 16px; }
.streak-card .flame { font-size:1.15rem; color:var(--accent); }
.streak-info { display:flex; flex-direction:column; gap:2px; min-width:0; }
.ring { --p:0%; width:52px; height:52px; border-radius:50%; flex:none; display:flex; align-items:center; justify-content:center;
  font-size:1.4rem; background:conic-gradient(var(--amber,#e8a020) var(--p), var(--line) 0); position:relative; }
.ring::after { content:""; position:absolute; inset:5px; border-radius:50%; background:var(--card,#fff); z-index:-1; }
/* продающий титул: янтарь, волны, лестница, zigzag, персоны */
:root { --amber:#e8a020; --amber-dark:#c9860e; }
.btn.amber { background:var(--amber); border-color:var(--amber-dark); color:#3a2c05; font-weight:700; }
.btn.amber:hover { box-shadow:0 6px 22px #e8a02066; background:#f2ae30; }
.waves-bg { position:relative; overflow:hidden; }
.waves-bg::before { content:""; position:absolute; inset:0; background:url("waves.svg") center bottom/900px auto repeat-x;
  opacity:.5; pointer-events:none; }
.hero.card.waves-bg::before { opacity:.8; }
.hero-shot { position:relative; padding-bottom:14px; }
.hero-shot .ladder { position:absolute; right:50%; transform:translateX(50%); bottom:-6px; filter:drop-shadow(0 6px 14px #0003); }
.zigzag { display:grid; gap:18px; margin-top:8px; }
.zz { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:16px; align-items:center; }
.zz.flip .zz-visual { order:2; }
.zz-text b { font-size:1.05rem; display:block; margin-bottom:4px; }
.zz-visual img { width:100%; border-radius:14px; border:1px solid var(--line); display:block; }
.zz-visual.frame { padding:10px; background:var(--bg); border:1px solid var(--line); border-radius:16px; }
.zz-visual .ph { min-height:180px; border-radius:14px; display:flex; flex-direction:column; gap:8px; align-items:center; justify-content:center;
  background:linear-gradient(135deg,#e8f1ed,#f7f5f0); border:1px dashed #bcd3ca; padding:16px; }
.zz-visual .ph span { font-size:2.2rem; }
.zz-visual .ph p { margin:0; color:var(--muted); text-align:center; }
.teacher-facts { list-style:none; margin:8px 0 0; padding:0; display:grid; gap:8px; }
.teacher-facts .teacher-fact { display:flex; align-items:center; gap:10px; }
.teacher-fact > span:last-child { min-width:0; }
.teacher-fact-icon { display:block; flex:0 0 44px; width:44px; aspect-ratio:1.25;
  background:transparent url("landing/custom-icons-board-v2.png") 0 0 / 600% 500% no-repeat; }
.teacher-fact-icon--family { background-position:20% 50%; }
.teacher-fact-icon--microphone { background-position:40% 0; }
.teacher-fact-icon--course { background-position:0 0; }
.personas { display:grid; grid-template-columns:repeat(auto-fit,minmax(190px,1fr)); gap:12px; margin-top:8px; }
.persona { border:1px solid var(--line); border-radius:14px; padding:14px; background:var(--bg); display:grid; gap:8px; }
.persona img { width:100%; border-radius:10px; aspect-ratio:1; object-fit:cover; }
.persona .ph { border-radius:10px; aspect-ratio:1; display:flex; align-items:center; justify-content:center; font-size:2.6rem;
  background:linear-gradient(135deg,#e8f1ed,#f7f5f0); border:1px dashed #bcd3ca; }
.persona b { margin-top:2px; }
.persona p { margin:0; color:var(--muted); font-size:.95rem; }
.title-footer { border-radius:14px; padding:14px; text-align:center; color:var(--muted); }
@media(max-width:480px) and (pointer:coarse) { .zz { grid-template-columns:1fr; } .zz.flip .zz-visual { order:0; } .hero-shot .ladder { width:170px; } }
.law-list { margin:8px 0 0; padding-left:22px; }
.law-list li { margin-bottom:10px; line-height:1.45; }
@media(max-width:480px) and (pointer:coarse) {
  .hero { grid-template-columns:1fr; }
  .hero-shot { order:-1; }
  .hero-shot img { max-width:230px; }
  .teacher { grid-template-columns:1fr; text-align:center; }
}
.tabs button { flex:1 1 150px; min-height:48px; border-radius:12px; border:1px solid var(--line); background:var(--card); color:var(--muted); font-weight:600; padding:9px 10px; }
.tabs button.on { background:var(--accent); border-color:var(--accent); color:#fff; box-shadow:0 3px 10px rgba(47,111,94,.25); }
@media(max-width:480px) and (pointer:coarse) { .tabs { padding:8px 0 6px; } .tabs button { flex:1 1 100%; } }
.pager { display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin:0 0 14px; }
.pager .muted { text-align:center;flex:1 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
[hidden] { display:none !important; }

@media (max-width:480px) and (pointer:coarse) {
  .sounds { grid-template-columns:repeat(2, 1fr); }
  button.next, .rec button, .stack button { width:100%; }
  h1 { font-size:1.35rem; }
  .words td { padding:8px 6px; } .words td.ipa { white-space:normal; }
  main { padding:12px; } .card { padding:14px; }
}
/* 14.11.2026: крупный текст и на «узком» (при зуме) десктопном окне — иначе при пересечении 1200px CSS-пикселей базовый кегль менялся и текст прыгал */
@media (min-width:1200px), (pointer:fine) { body { font-size:1.06rem; } }

/* --- меню: сверху на компьютере, снизу на телефоне --- */
nav.top { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; }
nav.bottom { display: none; }
@media (max-width: 480px) and (pointer:coarse) {
  nav.top { display: none; }
  /* 16.11.2026 (Максим): «← Назад» — с левого края шапки, «В начало» — по центру,
     «Выйти из платформы» — у правого края. Три кнопки в ряд на телефоне не помещаются, поэтому
     первая строка: «Назад» слева + выход справа, «В начало» — второй строкой ровно
     по центру окна (порядок в DOM — в base.html, десктопная сетка — ниже) */
  body.signed > header .header-exit { margin-left: auto; }
  body.signed > header .brand { order: 3; margin: 0 auto; }
  body.signed { padding-bottom: calc(68px + env(safe-area-inset-bottom, 0px)); }
  nav.bottom { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: var(--card);
    border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom, 0px); }
  nav.bottom > a, nav.bottom > details, nav.bottom > form { flex: 1 1 0; min-width: 0; margin: 0; }
  nav.bottom > a, nav.bottom summary, nav.bottom > form button { display: flex; align-items: center; justify-content: center; gap: 4px;
    min-height: 56px; padding: 4px 2px; font-size: .82rem; line-height: 1.15; text-align: center; text-decoration: none;
    color: var(--muted); background: none; border: 0; border-radius: 0; width: 100%; }
  nav.bottom > a[aria-current], nav.bottom details[open] > summary { color: var(--accent); font-weight: 700; box-shadow: inset 0 3px 0 var(--accent); }
  nav.bottom b { background: var(--danger); color: #fff; border-radius: 10px; padding: 0 6px; font-size: .75rem; }
  nav.bottom summary { list-style: none; }
  nav.bottom summary::-webkit-details-marker { display: none; }
  nav.bottom .more { position: absolute; right: 8px; bottom: calc(100% + 8px); min-width: 220px; background: var(--card);
    border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 6px 24px rgba(0,0,0,.18); padding: 6px; }
  nav.bottom .more a, nav.bottom .more button { display: flex; align-items: center; min-height: 48px; padding: 0 14px; width: 100%;
    text-decoration: none; color: var(--ink); background: none; border: 0; font-size: 1rem; text-align: left; border-radius: 8px; }
  nav.bottom .more form { margin: 0; }
  nav.bottom .more a[aria-current] { color: var(--accent); font-weight: 700; }
}

/* 15.11.2026: «В начало» в самом низу всех страниц (кроме лендинга и документов — там свои);
   кнопка в потоке, на телефоне размещается выше nav.bottom за счёт padding-bottom у body.signed */
.page-backtop { display: flex; justify-content: center; padding: 20px 16px; }
/* 15.11.2026 (Максим): кастомные стрелки кнопок — SVG вместо текстовых ↑, красятся в цвет текста */
.arrow { width: .72em; height: .72em; vertical-align: -.04em; }

/* --- главная --- */
.btn.resume { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; padding: 16px 18px;
  font-size: 1.15rem; margin: 0 0 16px; box-sizing: border-box; }
.btn.resume small { font-size: .9rem; font-weight: 400; opacity: .9; }
.attention { border-left: 5px solid var(--warn); }
.attention ul { margin: 0; padding-left: 1.2em; }
.attention li { margin: 6px 0; }
.intro { border-left: 5px solid var(--accent); }
.intro ol { padding-left: 1.3em; }
.intro li { margin: 6px 0; }

/* --- урок: свёрнутые пройденные шаги --- */
/* --- урок по шагам: закреплённая панель «Назад · Шаг k из N · Next» и меню шагов --- */
.stepper { margin: 12px 0 16px; }
.step-menu-head { font-weight: 700; margin: 0 0 6px; }
.step-menu ol { list-style: none; margin: 0 0 16px; padding: 0; }
.step-menu li > a, .step-menu li > span { display: flex; gap: 10px; align-items: center; padding: 7px 8px; border-radius: 8px;
  color: var(--ink); text-decoration: none; line-height: 1.25; }
.step-menu li > a:hover { background: var(--bg); }
.step-menu i { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px;
  border-radius: 15px; border: 2px solid var(--line); box-sizing: border-box; font-style: normal; font-weight: 700; font-size: .85rem; color: var(--muted); }
.step-menu .done i { border-color: var(--accent); color: var(--accent); }
.step-menu .current i { background: var(--accent); border-color: var(--accent); color: #fff; }
.step-menu .wait i { border-color: var(--warn); color: var(--warn); }
.step-menu .locked > span { color: var(--muted); cursor: not-allowed; }
.step-menu .locked i { border-style: dashed; }
.step-menu a[aria-current] { background: var(--bg); font-weight: 700; box-shadow: inset 3px 0 0 var(--accent); }
.step-bar { position: sticky; top: 0; z-index: 15; display: flex; gap: 8px; align-items: center; padding: 8px 0;
  margin-bottom: 10px; background: var(--bg); border-bottom: 1px solid var(--line); }
.step-bar button { margin: 0; min-height: 44px; white-space: nowrap; }
.step-bar .step-pos { flex: 1 1 auto; }
.step-bar button[disabled] { opacity: .45; cursor: not-allowed; }
.step-hint { margin: -4px 0 10px; }
.stepper.on .step-menu { display: none; }
.stepper.on.menu-open .step-menu { display: block; position: fixed; z-index: 25; left: 12px; right: 12px; max-height: 65vh; overflow: auto;
  background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px; box-shadow: 0 12px 32px rgba(0, 0, 0, .2); }
@media (max-width: 420px) and (pointer:coarse) { .step-bar button { padding-left: 10px; padding-right: 10px; } }
/* 14.11.2026: мышь (pointer:fine) — боковое меню шагов (grid 260px+1fr).
   15.11.2026 (Максим, ред. 1.107): только пока окно ≥820px — кабинету запрещено быть шире
   окна (пол 880 отменён), а при колонке 260px панель шагов ниже ~800px сжимается в щель
   и кнопки вылезают за край. Узкое окно с мышью (сильный зум) получает тот же режим,
   что и телефон: меню шагов за бургером, панель шагов в одну колонку. */
@media (min-width: 1000px), (pointer: fine) and (min-width: 820px) {
  main.stepped { max-width: 1100px; }
  .stepper.on { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 24px; align-items: stretch; }
  .stepper.on .step-menu { align-self: start; }
  .stepper.on .step-menu, .stepper.on.menu-open .step-menu { display: block; position: sticky; top: 12px; max-height: calc(100vh - 24px);
    overflow: auto; box-shadow: none; border: 0; padding: 0; background: none; }
  .step-bar .burger { display: none; }
  .step-bar .step-pos { pointer-events: none; }
}
details.step-done { padding-top: 6px; padding-bottom: 6px; }
details.step-done[open] { padding-bottom: 16px; }
details.step-done > summary { color: var(--ink); justify-content: space-between; gap: 10px; }
details.step-done > summary::after { content: "показать"; color: var(--accent); font-size: .9rem; white-space: nowrap; }
details.step-done[open] > summary::after { content: "свернуть"; }
section.step-current { border: 2px solid var(--accent); }
section.step-wait { border: 2px solid var(--warn); }
section.step-locked { opacity: .75; }

/* --- обсуждения --- */
.fresh { border-left: 5px solid var(--accent); }
.tag.new { background: var(--accent); color: #fff; }

/* --- документы: вид как в скачанном файле --- */
.doc { font-family: Georgia, "Times New Roman", serif; line-height: 1.55; max-width: 46em; }
.doc-title { text-align: center; font-size: 1.25rem; text-transform: uppercase; letter-spacing: .02em; margin: 8px 0 4px; }
.doc-note { text-align: center; color: var(--muted); margin: 0 0 18px; }
.doc-section { font-size: 1rem; text-transform: uppercase; letter-spacing: .03em; margin: 22px 0 8px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
.doc-clause, .doc-bullet { display: flex; gap: 10px; margin: 6px 0; }
.doc-clause .num { flex: 0 0 2.8em; font-weight: 700; }
.doc-bullet { padding-left: 2.8em; }
.doc-bullet .num { flex: 0 0 1.2em; }
.doc-text { margin: 8px 0; text-indent: 2.8em; text-align: justify; }
.doc-meta { display: flex; justify-content: space-between; gap: 12px; margin: 4px 0 18px; }
.doc-req { display: grid; grid-template-columns: minmax(8em, 33%) 1fr; gap: 10px; margin: 2px 0; font-size: .95rem; }
.doc-clause span + span, .doc-bullet span + span { text-align: justify; }
.doc span + span { min-width: 0; overflow-wrap: anywhere; }

/* --- ученики: список с поиском --- */
.filter { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; margin-bottom: 6px; }
.filter label { flex: 1 1 180px; margin: 0; }
details.student { border: 1px solid var(--line); border-radius: 10px; padding: 0 14px; margin: 8px 0; background: var(--card); }
details.student[open] { padding-bottom: 14px; border-color: var(--accent); }
details.student > summary { justify-content: space-between; gap: 6px 14px; flex-wrap: wrap; color: var(--ink); padding: 8px 0; }
details.student .who { display: flex; flex-direction: column; min-width: 0; }
details.student h3 { font-size: 1rem; margin: 14px 0 4px; }
[hidden] { display: none !important; }

/* --- редактор: убрать строку, полоса загрузки --- */
.item { position: relative; }
button.x { flex: 0 0 44px; min-width: 44px; padding: 0; align-self: flex-end; }
.upload { margin-top: 10px; }
progress { display: block; width: 100%; height: 14px; accent-color: var(--accent); }
/* ред. 1.108: /admin — столбик курсов, кнопка «Новый курс» сверху, все уроки курса без пейджера */
.btn.course { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; width: 100%;
  padding: 14px 18px; font-size: 1.1rem; margin: 0 0 10px; box-sizing: border-box; overflow-wrap: anywhere; }
.btn.course small { font-size: .9rem; font-weight: 400; opacity: .9; }
details.new-course { margin: 0 0 18px; }
details.new-course > summary { justify-content: center; }
details.new-course > summary::after { content: "▾"; font-weight: 400; }
details.new-course[open] > summary::after { content: "▴"; }
details.new-course > summary::marker, details.new-course > summary::-webkit-details-marker { display: none; list-style: none; }
details.new-course[open] > form { margin-top: 10px; }
/* узкое окно с мышью: боковая панель резервирует 156px слева, инпуты со встроенной шириной (~227px)
   вылезают за край — разрешаем сжиматься (реальные телефоны pointer:coarse панель не разворачивают) */
main.admin-courses input[type="text"], main.admin-courses input[type="date"], main.admin-courses textarea { min-width: 0; }

/* --- чаты --- */
a.chat-link { display:flex; flex-direction:column; gap:4px; text-decoration:none; color:var(--ink); }
a.chat-link.fresh { border-left:4px solid var(--accent); }
.chat { display:flex; flex-direction:column; gap:10px; margin:0 0 16px; }
.msg { max-width:85%; align-self:flex-start; background:var(--card); border:1px solid var(--line); border-radius:12px 12px 12px 4px; padding:8px 12px; overflow-wrap:anywhere; }
.msg.mine { align-self:flex-end; background:#eef6f2; border-radius:12px 12px 4px 12px; }
.msg p { margin:4px 0; white-space:pre-wrap; }
.msg img, .msg video { display:block; max-width:100%; max-height:360px; border-radius:8px; margin:6px 0; }
.msg audio { width:100%; max-width:320px; margin:6px 0; }
.msg button.small { min-height:32px; padding:2px 8px; font-size:.9rem; }
.attach { margin:8px 0; }

/* --- «послушать слово» --- */
button.say { background:none; border:0; color:var(--ink); padding:0; min-height:0; font-weight:600; text-decoration:underline dotted var(--accent); text-underline-offset:3px; cursor:pointer; text-align:left; display:inline; }
button.say::after { content:""; display:inline-block; width:1.5em; aspect-ratio:1.25; margin-left:5px; vertical-align:-.18em;
  background:transparent url("landing/custom-icons-board-v2.png") 20% 0 / 600% 500% no-repeat; }
button.say.playing { color:var(--accent); }

/* --- урок пройден, баллы --- */
.points { color:var(--accent); }
.win { position:relative; overflow:hidden; text-align:center; border:2px solid var(--accent); }
.balloons { position:absolute; inset:0; pointer-events:none; }
.balloons span { position:absolute; bottom:-60px; font-size:2.2rem; animation:fly 4s ease-in forwards; }
.balloons span:nth-child(1) { left:5%; animation-delay:0s; }
.balloons span:nth-child(2) { left:22%; animation-delay:.4s; }
.balloons span:nth-child(3) { left:40%; animation-delay:.1s; }
.balloons span:nth-child(4) { left:58%; animation-delay:.6s; }
.balloons span:nth-child(5) { left:75%; animation-delay:.2s; }
.balloons span:nth-child(6) { left:90%; animation-delay:.8s; }
@keyframes fly { to { transform:translateY(-420px) rotate(12deg); opacity:0; } }
@media (prefers-reduced-motion: reduce) { .balloons { display:none; } }

/* оценка урока: 5 звёзд. В разметке звёзды идут от 5 к 1, row-reverse ставит их по порядку,
   а «~» подсвечивает выбранную и все левее неё */
.sr { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
fieldset.stars { border:0; padding:0; margin:0 0 12px; display:flex; flex-direction:row-reverse; justify-content:flex-end; gap:4px; }
fieldset.rate-like { border:0; padding:0; margin:0 0 12px; }  /* бинарный отзыв: понравился / не понравился */
fieldset.rate-like legend { padding:0; margin-bottom:6px; }
fieldset.stars legend { padding:0; margin-bottom:6px; }
fieldset.stars input { position:absolute; opacity:0; width:1px; height:1px; }
fieldset.stars label { font-size:2.2rem; line-height:1; min-width:44px; min-height:44px; display:inline-flex; align-items:center;
  justify-content:center; cursor:pointer; color:#c9c9c9; transition:color .15s, transform .15s; }
fieldset.stars input:checked ~ label, fieldset.stars label:hover, fieldset.stars label:hover ~ label { color:#f5a623; }
fieldset.stars label:hover { transform:scale(1.12); }
fieldset.stars input:focus-visible + label { outline:2px solid var(--accent); outline-offset:2px; border-radius:8px; }
.stars-view { color:#f5a623; white-space:nowrap; letter-spacing:1px; }
.stars-view .muted { color:#c9c9c9; }

/* студия записи у автора */
.studio-start { display:flex; gap:10px; flex-wrap:wrap; }
.rec video.mirror { transform:scaleX(-1); }
.studio-start .btn, .studio-more .btn { cursor:pointer; }
@media (max-width:480px) and (pointer:coarse) { .studio-start > *, .studio-more > * { flex:1 1 100%; } }
.take video { max-height:50vh; width:100%; background:#000; border-radius:8px; }
.take .trim-timeline { position:relative;height:64px;margin:4px 16px 8px;touch-action:pan-y }
.take .trim-rail { position:absolute;left:0;right:0;top:18px;height:28px;background:#d9dadd;border-radius:6px;overflow:hidden }
.take .trim-selection { position:absolute;inset:0 calc(100% - var(--trim-end)) 0 var(--trim-start);background:#2f6f5e;box-shadow:inset 0 0 0 2px #1b5143 }
.take .trim-timeline input[type=range] { position:absolute;left:-14px;top:0;width:calc(100% + 28px);height:64px;margin:0;padding:0;border:0;background:transparent;appearance:none;-webkit-appearance:none;pointer-events:none;box-shadow:none }
.take .trim-timeline input[type=range]::-webkit-slider-runnable-track { height:28px;background:transparent }
.take .trim-timeline input[type=range]::-moz-range-track { height:28px;background:transparent }
.take .trim-timeline input[type=range]::-webkit-slider-thumb { appearance:none;-webkit-appearance:none;width:28px;height:48px;margin-top:-10px;border:3px solid #fff;border-radius:8px;background:#174f41;box-shadow:0 1px 5px #0005;pointer-events:auto;cursor:ew-resize;touch-action:none }
.take .trim-timeline input[type=range]::-moz-range-thumb { width:24px;height:44px;border:3px solid #fff;border-radius:8px;background:#174f41;box-shadow:0 1px 5px #0005;pointer-events:auto;cursor:ew-resize;touch-action:none }
.take-edit { margin:8px 0 14px; }
.take-edit > p { margin:8px 0; }
.take > .row { display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin-top:12px; }
.take > .row button { flex:1 1 180px;min-height:48px;margin:0; }
.studio-more { display:flex; gap:10px; flex-wrap:wrap; margin:10px 0; }

/* Unified actions, compact registration and responsive lesson navigation. */
button.big, .btn.big { min-height:56px; padding:14px 24px; font-size:1.1rem; font-weight:700; }
button.amber, .btn.amber, .hero .btn.big.amber {
  background:var(--amber); border-color:var(--amber-dark); color:#3a2c05; font-weight:700;
}
button.amber:hover:not(:disabled), .btn.amber:hover, .hero .btn.big.amber:hover { background:#f2ae30; }
input[type=tel] { width:100%; min-height:44px; padding:9px 10px; border:1px solid #b9b2a4; border-radius:8px;
  font:inherit; margin:4px 0 10px; background:var(--card); color:var(--ink); }
.guest-nav { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
header .guest-nav a { text-decoration:none; }
main.landing { max-width:1120px; }
.landing #register, .landing #login, .landing #faq, .landing #law { max-width:760px; margin-left:auto; margin-right:auto; }
.hero-copy { position:relative; }
.hero-cta .btn { max-width:100%; text-align:center; }
.password-field { display:flex; gap:8px; align-items:center; margin:4px 0 10px; }
.password-field input { flex:1; min-width:0; width:0; margin:0; }
.password-field button { flex:none; padding:9px 12px; }
.optional-field { border-bottom:1px solid var(--line); margin:4px 0 16px; }
.optional-field summary { padding:8px 0; }
.optional-field summary::after { content:" +"; margin-left:auto; padding-left:12px; }
.optional-field[open] summary::after { content:" −"; }
.result-card summary { justify-content:space-between; gap:8px 16px; flex-wrap:wrap; padding:6px 0; }
.result-card summary::after { content:"Показать разбор ↓"; font-size:.9rem; }
.result-card[open] summary::after { content:"Свернуть ↑"; }
.results { margin-bottom:24px; }
.result-summary { margin:10px 0; }
.step-bar { display:grid; grid-template-columns:minmax(0,1fr) auto minmax(0,1fr); }
.step-bar button { white-space:normal; padding:9px 12px; }
.step-bar [data-prev] { justify-self:start; }
.step-bar [data-next] { justify-self:end; }
.step-bar .step-pos { min-width:0; }
@media(max-width:480px) and (pointer:coarse) {
  .hero-shot { order:0; }
  .hero-shot img { max-width:190px; }
  .hero-cta { align-items:stretch; flex-direction:column; }
  .hero-cta .quiet-link { min-height:44px; display:flex; align-items:center; }
  .zz-visual img { max-height:260px; object-fit:contain; }
  .personas { grid-template-columns:1fr; }
  .persona { grid-template-columns:88px minmax(0,1fr); align-items:center; }
  .persona img, .persona .ph { grid-row:1 / 3; }
}
@media(max-width:480px) and (pointer:coarse) {
  header { padding:8px 12px; }
  .guest-nav { width:100%; display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); }
  .guest-nav .btn { padding:9px 8px; font-size:.88rem; white-space:normal; }
  .step-bar { grid-template-columns:1fr 1fr; gap:6px; }
  .step-bar .step-pos { grid-row:1; grid-column:1 / -1; width:100%; }
  .step-bar [data-prev], .step-bar [data-next] { grid-row:2; width:100%; font-size:.95rem; }
  .result-summary .btn { width:100%; }
  .password-field { gap:6px; }
}
@media(prefers-reduced-motion:reduce) {
  button, .btn { transition:none; }
}


/* ==== Дизайн-аудит 08.11.2026: шрифт Onest, мобильный hero, лестница уроков, отзывы, персоны, анимация ==== */
@font-face { font-family:"Onest"; font-style:normal; font-weight:400; font-display:swap;
  src:url("/static/fonts/onest-400-cyrillic-ext.woff2") format("woff2");
  unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:400; font-display:swap;
  src:url("/static/fonts/onest-400-cyrillic.woff2") format("woff2");
  unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:400; font-display:swap;
  src:url("/static/fonts/onest-400-latin.woff2") format("woff2");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02CC,U+02D0-02D1,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:600; font-display:swap;
  src:url("/static/fonts/onest-600-cyrillic-ext.woff2") format("woff2");
  unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:600; font-display:swap;
  src:url("/static/fonts/onest-600-cyrillic.woff2") format("woff2");
  unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:600; font-display:swap;
  src:url("/static/fonts/onest-600-latin.woff2") format("woff2");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02CC,U+02D0-02D1,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:700; font-display:swap;
  src:url("/static/fonts/onest-700-cyrillic-ext.woff2") format("woff2");
  unicode-range:U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:700; font-display:swap;
  src:url("/static/fonts/onest-700-cyrillic.woff2") format("woff2");
  unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:"Onest"; font-style:normal; font-weight:700; font-display:swap;
  src:url("/static/fonts/onest-700-latin.woff2") format("woff2");
  unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02CC,U+02D0-02D1,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215; }

/* мобильный hero: заголовок и кнопка важнее картинки */
@media(max-width:480px) and (pointer:coarse) {
  .hero.card { padding:18px 14px 6px; }
  .hero h1 { font-size:2rem; line-height:1.22; margin:4px 0 8px; }
  .hero .lead { font-size:1rem; }
  .hero-kicker { font-size:.78rem; }
  header { padding:6px 12px; }
}

/* ==== Лестница уроков, ред. 2 (08.11.2026, вечер): ступени-медальоны, соединители-лесенки ==== */
ol.ladder-track { list-style:none; margin:4px 0 8px; padding:0; position:relative; }
ol.ladder-track::before { content:none; }
ol.ladder-track > li { position:relative; padding:0 0 26px 0; margin:0; }
ol.ladder-track > li:last-child { padding-bottom:0; }

/* медальон-ступень: квадрат со скруглением и внутренним бликом */
.rung { position:absolute; left:0; top:0; width:46px; height:46px; border-radius:12px;
  display:flex; align-items:center; justify-content:center; font-weight:700; font-size:1.15rem;
  background:linear-gradient(180deg,#ffffff, #eceae4); border:1.5px solid var(--line);
  color:var(--muted); box-shadow:0 1px 2px rgba(34,38,43,.08), inset 0 1px 0 #fff; z-index:1; }
li.state-done > .rung { background:linear-gradient(180deg,#3d8a74, var(--accent));
  border-color:#25604f; color:#fff; box-shadow:0 2px 6px rgba(47,111,94,.35), inset 0 1px 0 rgba(255,255,255,.25); }
li.state-current > .rung { background:linear-gradient(180deg,#f7b53b, var(--amber));
  border-color:var(--amber-dark); color:#3a2c05; font-size:1.05rem;
  box-shadow:0 3px 10px rgba(232,160,32,.45), inset 0 1px 0 rgba(255,255,255,.4);
  animation:rungPulse 2.2s ease-in-out infinite; }
@keyframes rungPulse {
  0%,100% { box-shadow:0 3px 10px rgba(232,160,32,.45), inset 0 1px 0 rgba(255,255,255,.4); }
  50% { box-shadow:0 3px 18px rgba(232,160,32,.75), inset 0 1px 0 rgba(255,255,255,.4); }
}

/* карточка урока занимает место рядом с медальоном */
ol.ladder-track > li > .card { margin:0 0 0 60px; min-height:46px; display:flex; flex-direction:column; justify-content:center; }
li.state-done > .card { background:#fbfaf7; }
li.state-current > .card { background:linear-gradient(180deg,#fffdf4,#fdf6e3);
  border-color:#ecc26a; box-shadow:0 4px 14px rgba(232,160,32,.18); }
li.state-locked > .card { background:#f6f5f1; }
li.state-locked > .card h2, li.state-locked > .card p { color:var(--muted); }

/* соединитель-лесенка между ступенями: маленькая Г-образная ступень */
ol.ladder-track > li::after { content:""; position:absolute; left:21px; top:52px; width:22px; height:14px;
  border-left:3px solid #cfd8d3; border-bottom:3px solid #cfd8d3; border-bottom-left-radius:4px; }
li.state-done::after { border-left-color:#8fc0b0; border-bottom-color:#8fc0b0; }
li.state-current::after { border-left-color:#ecc26a; border-bottom-color:#ecc26a; }
li.state-locked::after, li:last-child::after { border-left-style:dashed; border-bottom-style:dashed; border-left-color:#ddd8cd; border-bottom-color:#ddd8cd; }
li:last-child::after { content:none; }

/* метка «Вы здесь» */
.here-chip { display:inline-block; margin-left:8px; padding:2px 10px 3px; border-radius:999px;
  background:var(--amber); color:#3a2c05; font-size:.8rem; font-weight:700; vertical-align:middle;
  box-shadow:0 1px 4px rgba(232,160,32,.4); }

@media(max-width:480px) and (pointer:coarse) {
  .rung { width:40px; height:40px; border-radius:10px; font-size:1rem; }
  ol.ladder-track > li > .card { margin-left:52px; }
  ol.ladder-track > li::after { left:18px; top:46px; width:20px; height:12px; }
}

/* лендинг: метод «Лестница речи» — раскрывающиеся ступени (№24–25, 14.11.2026;
   сжато 14.11.2026 по указанию Максима: все ступени свёрнуты, блок помещается в окно при 100%) */
#method ol.ladder-track > li { padding-bottom:10px; }
#method ol.ladder-track > li::after { top:50px; height:6px; }
#method ol.ladder-track > li > details.card { padding:10px 14px; }
#method ol.ladder-track summary { cursor:pointer; }
#method ol.ladder-track summary b { font-size:1.02rem; }
#method ol.ladder-track summary::marker { color:var(--muted); }
#method ol.ladder-track .method-step-body { margin:6px 0 2px; }
#method ol.ladder-track .method-step-body p { margin:0 0 6px; }
#method ol.ladder-track details.card { background:#fffdf7; }
@media(max-width:480px) and (pointer:coarse) { #method ol.ladder-track > li::after { top:42px; height:8px; } }

/* отзывы на титульной странице */
.reviews { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr)); gap:16px; margin-top:18px; }
.review { min-width:0; border:1px solid var(--line); border-radius:16px; padding:16px; background:#fffdf7; margin:0; overflow-wrap:anywhere; }
.review .review-text { margin:0 0 10px; font-size:1rem; }
.review-text p { margin:0; white-space:pre-line; }
.review .review-name { margin:0; font-weight:700; }
.review .review-meta { margin:0; color:var(--muted); font-size:.88rem; }
.review-image-link { display:block; margin-bottom:16px; border:1px solid var(--line); border-radius:10px; overflow:hidden; background:#f3f5ef; color:var(--accent); text-decoration:none; }
.review-image-link:focus-visible { outline:3px solid var(--amber); outline-offset:3px; }
.review-image-link .review-image { display:block; width:100%; height:280px; max-height:none; object-fit:contain; }
.review-image-link > span { display:flex; align-items:center; justify-content:center; min-height:44px; padding:8px; text-align:center; font-size:.9rem; background:var(--soft); }
.review-source { display:inline-flex; align-items:center; min-height:44px; margin-top:4px; font-size:.9rem; }
.review-dialog { width:min(960px,calc(100vw - 24px)); }
.review-dialog .studio-dialog-head { position:sticky; top:0; background:var(--card); padding-bottom:12px; }
.review-dialog [data-review-full] { display:block; width:100%; height:auto; max-height:none; object-fit:contain; }
.review-dialog [data-review-close] { min-width:44px; min-height:44px; }

/* выбор персоны на первом входе */
.persona-pick { display:grid; grid-template-columns:repeat(auto-fit,minmax(190px,1fr)); gap:10px; margin-top:8px; }
.persona-pick button { flex-direction:column; gap:4px; background:var(--card); color:var(--ink);
  border:1px solid var(--line); padding:12px 10px; text-align:center; }
.persona-pick button:hover { border-color:var(--accent); background:rgba(47,111,94,.07); }
.persona-pick .emoji { font-size:1.7rem; line-height:1; }
.persona-pick small { color:var(--muted); font-weight:400; }
.persona-pick form { display:flex; min-width:0; }
.persona-pick form > button { width:100%; min-height:152px; justify-content:flex-start; }
.account-art { display:block; flex:none; width:72px; aspect-ratio:1.25;
  background:transparent url("landing/custom-icons-board-v2.png") 80% 25% / 600% 500% no-repeat; }
.account-art--school { background-position:0% 50%; clip-path:inset(8% 0 0); }
.account-art--fifty { background-position:60% 25%; }
.account-art--streak { background-position:60% 100%; }
.persona-pick .account-art { margin:0 auto 4px; }
.ring .account-art { width:42px; position:relative; z-index:1; }

/* анкета сегментатора при первом входе (№8) */
.seg-pick { display:grid; grid-template-columns:repeat(auto-fit,minmax(190px,1fr)); gap:10px;
  margin:8px 0 12px; border:0; padding:0; }
.seg-option { display:flex; flex-direction:column; gap:4px; background:var(--card); color:var(--ink);
  border:1px solid var(--line); padding:12px 10px; text-align:center; cursor:pointer; min-height:96px; }
.seg-option:hover { border-color:var(--accent); background:rgba(47,111,94,.07); }
.seg-option:has(input:checked) { border-color:var(--accent); background:rgba(47,111,94,.12); }
.seg-option input { margin:0 auto 2px; }
.seg-option small { color:var(--muted); font-weight:400; }
.seg-tried { border:0; padding:0; display:flex; flex-wrap:wrap; gap:8px 16px; margin:4px 0 12px; }
.seg-field { display:block; margin:8px 0; }
.seg-field input, .seg-field textarea { width:100%; }

/* результаты проверки наверху главной */
.results-top { border-left:4px solid var(--amber); }

/* анимация «подъём по лестнице» на завершении урока */
.climb { display:block; margin:4px auto 12px; }
.climb .st { opacity:.22; }
.climb .st1 { animation:stepGlow .45s ease .15s forwards; }
.climb .st2 { animation:stepGlow .45s ease .55s forwards; }
.climb .st3 { animation:stepGlow .45s ease .95s forwards; }
.climb .climber { opacity:0; animation:climbUp 1.5s ease .2s forwards; }
@keyframes stepGlow { to { opacity:1; } }
@keyframes climbUp {
  0% { opacity:0; transform:translate(6px,58px); }
  25% { opacity:1; }
  45% { transform:translate(52px,32px); }
  70% { transform:translate(98px,10px); }
  100% { opacity:1; transform:translate(150px,-14px); }
}
@media(prefers-reduced-motion:reduce) {
  .climb .st, .climb .climber { animation:none; opacity:1; }
}

/* кольцо стрика: цель дня выполнена — зелёное */
.ring.full { background:conic-gradient(var(--accent) var(--p), var(--line) 0); }

/* карточка тарифа на /pay: имя, пояснение и кнопка не прилипают друг к другу */
.tariff { border:1px solid var(--line); border-radius:12px; padding:14px; margin:0 0 12px; background:#fffdf7; }
.tariff .tariff-name { margin:0 0 6px; }
.tariff .tariff-note { margin:0 0 12px; }
.tariff .btn { width:100%; }
@media(min-width:481px), (pointer:fine) { .tariff .btn { width:auto; } }

/* ==== Десктоп-расширение 08.11.2026 (вариант Б+А): лендинг 1160, внутренние 980 ==== */
main { max-width: 980px; }
h1 { font-size: 1.8rem; }
main.landing { max-width: 1160px; }

/* Узкое окно на компьютере: платформа не сжимается (решение Максима 14.11.2026).
   При ширине окна 481–879px держим десктопную вёрстку расчётной шириной 880px —
   появляется горизонтальная прокрутка, а не сжатие; мобильная вёрстка остаётся
   только для телефонов (до 480px). Значения ниже — фиксированные «как при 880px»:
   при ≥880 их перекрывает блок @media(min-width:880px), при ≥1024 — его блок. */
/* 14.11.2026: «десктоп» = ширина ≥481px ИЛИ мышь (pointer:fine) — увеличение (зум)
   в настольном браузере сужает окно в CSS-пикселях, но десктопную вёрстку не выключает */
@media(min-width:481px), (pointer:fine) {
  /* 15.11.2026 (Максим, ред. 1.107): пол 880px — только для гостевых страниц (лендинг/вход:
     там действует решение «не сжимать вообще», ред. 1.95). Страницы кабинета (body.signed)
     помещаются в окно целиком: раньше из-за пола при окне <880px правый край (кнопки «Дальше: …»,
     «Все сразу» и т.п.) уходил под горизонтальную прокрутку; теперь колонка контента сжимается,
     а панель разделов слева по-прежнему резервирует свои 156px. Телефоны (≤480, сенсор) не менялись. */
  body:not(.signed) { min-width: 880px; }
  main.landing .hero { padding: 30px 34px; gap: 26px; }
  main.landing .hero h1 { font-size: 2.75rem; line-height: 1.15; }
  main.landing .hero .lead { font-size: 1.05rem; max-width: 56ch; }
  main.landing .hero-shot img { max-width: 289px; }
}
/* 880–1023 — та же композиция крупнее (размеры плавные). Правила перекрываются
   блоком @media(min-width:1024px), поэтому вид ≥1024 не меняется; на мыши
   (pointer:fine) блок ниже действует при любой ширине окна — эти клампы
   остаются живыми только для сенсорных устройств. */
@media(min-width:880px) {
  main.landing .hero { padding: 30px 34px; gap: 26px; }
  main.landing .hero h1 { font-size: clamp(2.4rem, 1.21rem + 2.8vw, 3rem); line-height: 1.15; }
  main.landing .hero .lead { font-size: clamp(1.08rem, 1rem + .1vw, 1.28rem); max-width: 56ch; }
  main.landing .hero-shot img { max-width: clamp(280px, calc(44px + 27.8vw), 330px); }
}

/* 14.11.2026: мышь (pointer:fine) — композиция «>=1024px» при любой ширине окна:
   зум лендинг не перестраивает, меняется только масштаб */
@media(min-width:1024px), (pointer:fine) {
  main.landing > section.card { padding: 26px 30px; }
  main.landing .hero { padding: 40px 44px; gap: 36px; }
  main.landing .hero h1 { font-size: 3rem; line-height: 1.15; }
  main.landing .hero .lead { font-size: 1.28rem; max-width: 56ch; }
  main.landing .hero-shot img { max-width: 330px; }

  /* «Как проходит обучение»: 4 шага сеткой 2×2 */
  main.landing #how .zigzag { grid-template-columns: 1fr 1fr; gap: 22px 28px; }
  main.landing #how .zz { gap: 18px; }

  /* преподаватель: крупнее фото */
  main.landing .teacher { grid-template-columns: 210px minmax(0,1fr); gap: 30px; }
  main.landing .teacher-photo { width: 210px; height: 210px; }
  main.landing .teacher-facts { font-size: 1.05rem; }

  /* формы и текстовые секции — читаемая колонка по центру */
  main.landing #register, main.landing #login, main.landing #faq, main.landing #law { max-width: 780px; margin-left: auto; margin-right: auto; }
}

/* внутренние страницы: шире — но текст и формы не растягиваем до предела */
main:not(.landing) p { max-width: 88ch; }
main:not(.landing) section.card { padding: 18px 22px; }

/* ==== 11.11.2026: закреплённая шапка гостя + регистрация в диалоговом окне ==== */
/* шапка прилипает только на гостевых страницах (лендинг, вход, документы);
   кабинет не трогаем — там свои закреплённые панели уроков */
body:not(.signed) header { position: sticky; top: 0; z-index: 30; }
/* якоря лендинга не прячутся под липкой шапкой (~61px в одну строку, ~101px в две на <=480px) */
.landing section[id] { scroll-margin-top: 76px; }
@media (max-width: 480px) and (pointer:coarse) { .landing section[id] { scroll-margin-top: 116px; } }
/* Якорь #step-N (редактор урока, страница ученика) не прячется под липкой панелью */
.card[id^="step-"], #lesson-list { scroll-margin-top: 64px; }
/* окно регистрации — уже студийного диалога, под форму */
.register-dialog { width: min(560px, calc(100vw - 24px)); }
.register-dialog form { margin: 0; }
.register-dialog .flash { margin: 10px 0; }
.register-cta .hero-cta { justify-content: center; }

/* окно входа — устроено как окно регистрации */
.login-dialog { width: min(560px, calc(100vw - 24px)); }
.login-dialog form { margin: 0; }
.login-dialog .muted { margin: 10px 0 0; }

/* ==== 11.11.2026 (2): сворачиваемые курсы в разделе «Курсы и уроки» ==== */
.course-group > summary { color: inherit; justify-content: space-between; gap: 10px; }
.course-group > summary h1 { margin: 0; }
.course-group > summary::after { content: "▾"; color: var(--accent); flex: none; }
.course-group[open] > summary::after { content: "▴"; }
.course-meta { flex: none; text-align: right; }
@media (max-width: 480px) and (pointer:coarse) {
  .course-group > summary { flex-wrap: wrap; }
  .course-meta { flex: 1 1 100%; text-align: left; }
}

/* ==== 11.11.2026 (3): анимации первой очереди (№ 25, 1, 3, 19, 21, 23, 26) ==== */

/* 25: каскадное появление секций лендинга (классы вешает ux.js, без JS всё видно сразу) */
.rv-sec { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.rv-sec.rv-in { opacity: 1; transform: none; }
.rv-ch { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease; }
.rv-sec.rv-in .rv-ch { opacity: 1; transform: none; }

/* 1: живая лестница в hero — ступени вырастают, ученик поднимается, флажок зажигается */
.hero-shot .ladder .lb { transform-box: fill-box; transform-origin: 50% 100%; animation: lb-rise .55s cubic-bezier(.2,.7,.3,1.25) backwards; }
.hero-shot .ladder .lb1 { animation-delay: .1s; }
.hero-shot .ladder .lb2 { animation-delay: .35s; }
.hero-shot .ladder .lb3 { animation-delay: .6s; }
@keyframes lb-rise { from { transform: scaleY(0); } }
.hero-shot .ladder .lflag { opacity: 0; animation: lflag-on .4s ease .95s forwards, lflag-glow 3s ease-in-out 1.6s infinite; }
@keyframes lflag-on { to { opacity: 1; } }
@keyframes lflag-glow { 0%, 100% { opacity: 1; } 50% { opacity: .6; } }
.hero-shot .ladder .lclimb { opacity: 0; animation: lclimb 7s ease-in-out 1.2s infinite; }
@keyframes lclimb {
  0% { opacity: 0; transform: translate(0,0); }
  4% { opacity: 1; }
  14% { transform: translate(0,0); }
  22%, 34% { transform: translate(70px,-22px); }
  42%, 54% { transform: translate(140px,-44px); }
  66% { transform: translate(140px,-44px) scale(1.3); }
  74% { transform: translate(140px,-44px) scale(1); }
  88% { opacity: 1; transform: translate(140px,-44px); }
  94%, 100% { opacity: 0; transform: translate(140px,-44px); }
}

/* 19: кнопка, которая зовёт — блик раз в ~4.5 с и ступенька под кнопкой при наведении */
.btn.amber.shine { position: relative; overflow: hidden; }
.btn.amber.shine::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 42%, rgba(255,255,255,.75) 50%, transparent 58%);
  transform: translateX(-130%); animation: cta-shine 4.5s ease-in-out 1.5s infinite;
}
@keyframes cta-shine { 0%, 70% { transform: translateX(-130%); } 82%, 100% { transform: translateX(130%); } }
.hero-cta .btn.amber.shine::before {
  content: ""; position: absolute; left: 50%; bottom: -9px; width: 36%; height: 0;
  transform: translateX(-50%); background: var(--amber-dark); border-radius: 4px;
  transition: width .3s ease, height .3s ease;
}
.hero-cta .btn.amber.shine:hover::before { width: 88%; height: 7px; }

/* 3: счётчики уроков и шагов (значение в разметке, намотку делает ux.js) */
.teacher-facts .cnt { font-variant-numeric: tabular-nums; }

/* 21: плавное раскрытие вопросов FAQ */
#faq details { border: 1px solid var(--line); border-radius: 10px; background: #fff; margin: 0 0 10px; }
#faq details:last-child { margin-bottom: 0; }
#faq details > summary { padding: 0 16px; font-weight: 600; }
#faq details > summary::after { content: "▾"; color: var(--accent); margin-left: auto; flex: none; transition: transform .3s ease; }
#faq details[open] > summary::after { transform: rotate(180deg); }
#faq details > p { margin: 0; padding: 0 16px 14px; }
#faq details[open] > p { animation: faq-open .35s ease; }
@keyframes faq-open { from { opacity: 0; transform: translateY(-5px); } }

/* 23: полоса курса в кабинете — ступенчатые «прутья», наполняется при появлении */
.course-group .bar { height: 10px; border-radius: 6px; }
.course-group .bar i {
  background: var(--accent);
  -webkit-mask: repeating-linear-gradient(90deg, #000 0 12px, transparent 12px 15px);
  mask: repeating-linear-gradient(90deg, #000 0 12px, transparent 12px 15px);
  transition: width 1s ease .15s;
}

/* 26: бегущая строка слов курса (две одинаковые половины — бесшовный цикл) */
.marquee { overflow: hidden; padding: 4px 0 14px; }
.marquee-track { display: flex; gap: 34px; width: max-content; animation: mq-run 30s linear infinite; }
.marquee .mq { display: flex; gap: 34px; }
.marquee span { white-space: nowrap; font-weight: 700; color: var(--accent); font-size: 1.05rem; }
.marquee span::after { content: ""; display:inline-block; width:24px; aspect-ratio:1.25; vertical-align:-4px; margin-left:7px;
  background:transparent url("landing/custom-icons-board-v2.png") 20% 0 / 600% 500% no-repeat; }
@keyframes mq-run { to { transform: translateX(calc(-50% - 17px)); } }
.marquee:hover .marquee-track { animation-play-state: paused; }

/* уважение к настройке «меньше движения»: всё замирает, контент виден целиком */
@media (prefers-reduced-motion: reduce) {
  .hero-shot .ladder .lb, .hero-shot .ladder .lflag, .hero-shot .ladder .lclimb,
  .btn.amber.shine::after, .marquee-track, #faq details[open] > p { animation: none; }
  .hero-shot .ladder .lflag { opacity: 1; }
  .hero-shot .ladder .lclimb { opacity: 1; transform: translate(140px,-44px); }
  .rv-sec, .rv-ch { opacity: 1; transform: none; transition: none; }
  .course-group .bar i { transition: none; }
}

/* ==== 11.11.2026 (4): разделы кабинета — жёлтые овальные кнопки, активный раздел выделен ==== */
nav.top { gap: 6px 8px; }
nav.top > a {
  display: inline-flex; align-items: center; min-height: 34px; padding: 5px 14px;
  border-radius: 999px; background: var(--amber); border: 1px solid var(--amber-dark);
  color: #3a2c05; font-weight: 600; font-size: .92rem; text-decoration: none;
  transition: background-color .15s ease, box-shadow .15s ease, transform .06s ease;
}
nav.top > a:hover { background: #f2ae30; box-shadow: 0 4px 14px rgba(232, 160, 32, .42); }
nav.top > a:active { transform: translateY(1px); box-shadow: none; }
nav.top > a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: #fff; }
nav.top form.inline { margin-left: 4px; }

/* Разделы кабинета — компактная левая панель; телефоны (до 480px) используют
   нижнее меню, узкое окно на компьютере держит десктопную ширину 880px. */
@media (min-width: 481px), (pointer:fine) {
  body.signed { padding-left: 156px; }
  /* 16.11.2026 (Максим): шапка кабинета — «← Назад» у левого края, «В начало» ровно
     по центру, «Выйти из платформы» у правого края. Сетка 1fr-auto-1fr даёт точный центр
     при любых ширине кнопок и окна (панель разделов nav.top — fixed, в раскладке не участвует). */
  body.signed > header { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
  body.signed > header .header-back { justify-self: start; }
  body.signed > header .brand { justify-self: center; margin-right: 0; }
  body.signed > header .header-exit { justify-self: end; }
  body.signed nav.top {
    position: fixed; top: 12px; left: 12px; z-index: 40; width: 132px;
    max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px);
    display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch;
    gap: 6px; padding: 10px; margin: 0; overflow-x: hidden; overflow-y: auto;
    scrollbar-width: thin; overscroll-behavior: contain;
    background: var(--card); border: 1px solid var(--line); border-radius: 16px;
    box-shadow: 0 3px 14px rgba(34,38,43,.06);
  }
  body.signed nav.top > a {
    flex: 0 0 auto; width: 100%; min-height: 44px; padding: 7px 8px;
    justify-content: center; text-align: center; font-size: .86rem; line-height: 1.25;
    white-space: normal; overflow-wrap: anywhere;
  }
  body.signed nav.top form.inline { margin: 0; padding: 0; border: 0; flex-shrink: 0; }
  body.signed nav.top form.inline button { width: auto; }
}
@media print {
  body.signed { padding-left: 0; padding-right: 0; }
  body.signed nav.top, body.signed nav.bottom { display: none; }
  .page-backtop { display: none; }   /* 15.11.2026: навигационная кнопка не печатается */
}

/* Selected realistic landing illustrations: 1, 3, 4, 7, 20, 26. */
main.landing .brand-moment { position: relative; margin: 0; color: var(--accent); }
main.landing .brand-art {
  display: block; width: 94px; aspect-ratio: 1.25; flex: 0 0 auto; border-radius: 12px;
  background: transparent url("landing/custom-icons-board-v2.png") 0 0 / 600% 500% no-repeat;
  transform-origin: center 75%;
}
main.landing .brand-caption { display: block; font-weight: 650; font-size: .86rem; line-height: 1.35; }
main.landing .brand-moment--inline { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
main.landing .brand-moment--inline .brand-caption { max-width: 150px; }
main.landing .brand-moment--ladder {
  width: 210px; padding: 9px 12px 14px; margin: -40px 0 0 -10px; z-index: 1;
  background: transparent; border: 0; text-align: center;
}
main.landing .brand-moment--ladder .brand-art { width: 100%; }
main.landing .brand-moment--ladder .brand-caption { color:#fff; }
main.landing .brand-moment--ladder .brand-art { filter:drop-shadow(0 6px 9px #11362544); }
main.landing [data-brand-motion="book"] .brand-art { background-position: 60% 0; }
main.landing [data-brand-motion="microphone"] .brand-art { background-position: 40% 0; }
main.landing [data-brand-motion="feedback"] .brand-art { background-position: 20% 75%; clip-path: inset(8% 0 0 0); }
main.landing [data-brand-motion="passport"] .brand-art { background-position: 0 25%; }
main.landing [data-brand-motion="door"] .brand-art { background-position: 20% 100%; width: 120px; }
main.landing .brand-moment--passport { display: flex; align-items: center; gap: 8px; }
main.landing .brand-moment--passport .brand-art { width: 80px; }
main.landing .brand-moment--passport .brand-caption {
  border: 1px solid var(--accent); border-radius: 6px; padding: 7px 9px; background: #fffaf0; font-size: .78rem;
}
main.landing .register-welcome { display: grid; grid-template-columns: 120px minmax(0, 1fr); align-items: center; gap: 18px; }
main.landing .register-welcome h2 { margin: 0 0 8px; }
main.landing .brand-wave { display: flex; align-items: center; gap: 3px; height: 28px; flex: 0 0 auto; }
main.landing .brand-wave i { display: block; width: 3px; height: 12px; border-radius: 4px; background: var(--accent); }
main.landing .brand-wave i:nth-child(2n) { height: 24px; }
main.landing .brand-wave i:nth-child(3) { height: 18px; }
main.landing .brand-moment--inline:has(.brand-wave) { flex-wrap: wrap; gap: 6px; }
main.landing .landing-motion-controls { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 8px; }
main.landing .landing-motion-controls button {
  background: transparent; border: 0; color: #e5f0eb; padding: 5px 0; min-height: 44px;
  font-size: .78rem; text-decoration: underline; text-underline-offset: 3px; box-shadow: none;
}
main.landing [data-brand-motion="ladder"] { --brand-move: brand-climb; }
main.landing [data-brand-motion="book"] { --brand-move: brand-book; }
main.landing [data-brand-motion="microphone"] { --brand-move: brand-voice; }
main.landing [data-brand-motion="feedback"] { --brand-move: brand-feedback; }
main.landing [data-brand-motion="passport"] { --brand-move: brand-passport; }
main.landing [data-brand-motion="door"] { --brand-move: brand-door; }
main.landing .brand-play .brand-art { animation: var(--brand-move) 2.8s ease both; }
main.landing .brand-play .brand-caption { animation: brand-caption 2.8s ease both; }
main.landing .brand-play .brand-wave i { animation: brand-wave .4s ease 6 alternate; }
main.landing .brand-play .brand-wave i:nth-child(2n) { animation-delay: .12s; }
main.landing .brand-play.brand-moment--passport .brand-caption { animation: brand-stamp 2.8s ease both; }
@keyframes brand-climb { 0% { transform: translateY(16px); opacity: .65; } 45% { transform: translateY(-4px); } 75%,100% { transform: none; opacity: 1; } }
@keyframes brand-book { 0%,100% { transform: none; } 40% { transform: perspective(500px) rotateY(-12deg) rotate(-2deg); } 75% { transform: rotate(1deg); } }
@keyframes brand-voice { 0%,100% { transform: none; } 30%,60% { transform: scale(1.04); } 45%,75% { transform: scale(1); } }
@keyframes brand-feedback { 0%,100% { transform: none; } 40% { transform: translateY(-8px) rotate(-3deg); } 75% { transform: translateY(-2px); } }
@keyframes brand-passport { 0%,100% { transform: none; } 40% { transform: rotate(-5deg); } 70% { transform: rotate(2deg); } }
@keyframes brand-door { 0%,100% { transform: none; } 50% { transform: perspective(500px) rotateY(-14deg); } }
@keyframes brand-caption { 0%,15% { opacity: .5; transform: translateY(5px); } 50%,100% { opacity: 1; transform: none; } }
@keyframes brand-stamp { 0%,20% { opacity: .4; transform: scale(1.12) rotate(-5deg); } 45%,100% { opacity: 1; transform: none; } }
@keyframes brand-wave { from { transform: scaleY(.35); } to { transform: scaleY(1); } }
.landing-motion-paused main.landing *, .landing-motion-paused main.landing *::before,
.landing-motion-paused main.landing *::after, .landing-motion-paused body:not(.signed) header .shine::after {
  animation: none !important; transition: none !important;
}
.landing-motion-paused main.landing .rv-sec, .landing-motion-paused main.landing .rv-ch { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  main.landing .brand-art, main.landing .brand-caption, main.landing .brand-wave i { animation: none !important; }
}
@media (max-width: 480px) and (pointer:coarse) {
  main.landing .brand-moment--ladder { width: 172px; margin: -30px 0 0; }
  main.landing .brand-moment--inline .brand-art { width: 76px; }
  main.landing .register-welcome { grid-template-columns: 1fr; gap: 6px; }
  main.landing [data-brand-motion="door"] .brand-art { width: 96px; }
}

/* Transparent illustrations: audiences, an oral prompt and actual completion. */
main.landing [data-brand-motion="briefcase"] { --brand-move: brand-feedback; }
main.landing [data-brand-motion="briefcase"] .brand-art { background-position: 80% 25%; }
main.landing [data-brand-motion="family"] { --brand-move: brand-voice; }
main.landing [data-brand-motion="family"] .brand-art { background-position: 20% 50%; }
main.landing [data-brand-motion="bookmark"] { --brand-move: brand-bookmark; }
main.landing [data-brand-motion="bookmark"] .brand-art { background-position:100% 100%; }
@keyframes brand-bookmark { 0% { transform:translateY(-10px) rotate(-5deg); } 65%,100% { transform:none; } }
main.landing .brand-moment--audience { display:flex; align-items:center; gap:8px; }
main.landing .brand-moment--audience .brand-art { width:80px; }
main.landing .brand-moment--audience .brand-caption { font-size:.8rem; min-width:0; }
.learning-art { display:block; width:80px; aspect-ratio:1.25; flex:0 0 auto;
  background:transparent url("landing/custom-icons-board-v2.png") 0 0 / 600% 500% no-repeat; }
.learning-art--microphone { background-position:40% 0; }
.oral-intro { display:flex; align-items:center; gap:12px; margin:8px 0 14px; }
.oral-intro > div { min-width:0; }
.oral-intro b { display:block; color:var(--accent); }
.oral-intro p { font-size:.9rem; margin:3px 0 0; }
.lesson-achievement { margin:4px auto 16px; }
.lesson-achievement .learning-art { width:150px; margin:0 auto 6px; }
.lesson-achievement-note { display:block; font-size:.9rem; color:var(--accent); }
.lesson-celebrate .learning-art { animation:brand-climb 2.8s ease both; }
.sound-mark { display:inline-block; width:26px; aspect-ratio:1.25; vertical-align:middle;
  background:transparent url("landing/custom-icons-board-v2.png") 20% 0 / 600% 500% no-repeat; }
main.landing .landing-backtop {
  position:fixed; right:max(16px, env(safe-area-inset-right, 0px)); bottom:calc(18px + env(safe-area-inset-bottom, 0px));
  z-index:18; min-height:44px; padding:9px 16px; border-radius:999px;
  box-shadow:0 4px 18px #25382e26; font-size:.9rem; max-width:calc(100vw - 32px);
}
@media print { main.landing .landing-backtop { display:none; } }
@media(prefers-reduced-motion:reduce) { .lesson-celebrate .learning-art { animation:none; } }
@media(max-width:480px) and (pointer:coarse) {
  main.landing .persona .brand-moment { grid-column:1 / -1; }
  .oral-intro { gap:8px; }
  .oral-intro .learning-art { width:64px; }
}

/* Adaptive lesson video: whole frame, a light surround and a labelled expand action. */
.wm.video {
  width:fit-content; max-width:100%; margin:16px auto; padding:6px;
  border:1px solid #cbdad0; border-radius:16px; background:#fafbf8;
  box-shadow:0 6px 20px #25382e12;
}
.wm.video video { width:auto; height:auto; max-width:100%; max-height:68dvh; object-fit:contain; border-radius:10px; }
.wm.video.video-sized video { width:100%; max-height:none; aspect-ratio:auto var(--video-ratio, 16 / 9); }
.wm.video .player { display:grid; grid-template-columns:44px minmax(48px,1fr) auto auto; gap:6px; padding:6px 0 0; background:transparent; color:var(--ink); }
.wm.video .player button { color:var(--accent); }
.wm.video .player input[type=range] { width:100%; accent-color:var(--accent); }
.wm.video .player .time { font-size:.82rem; }
.wm.video .player .player-expand { width:auto; min-height:44px; padding:6px 10px; border:1px solid var(--line); border-radius:999px;
  background:var(--soft,#e8f0eb); color:var(--accent); font-size:.82rem; max-width:100%; white-space:normal; text-align:center; }
.wm.video .player-expand svg { width:18px; height:18px; }
.wm.video.player-narrow .player { grid-template-columns:44px minmax(40px,1fr) auto; }
.wm.video.player-narrow .player-expand { grid-column:1 / -1; justify-self:center; }
.wm.video:is(.full, :fullscreen, :-webkit-full-screen) {
  width:100%; max-width:none; height:100%; padding:0; margin:0; border:0; border-radius:0; background:#000; box-shadow:none;
}
.wm.video:is(.full, :fullscreen, :-webkit-full-screen) video {
  flex:1 1 0; width:100%; height:0; max-height:none; border-radius:0; object-fit:contain;
}
.wm.video:is(.full, :fullscreen, :-webkit-full-screen) .player { flex:none; padding:6px; background:var(--bg); }
@media(max-width:480px) and (pointer:coarse) { .wm.video { margin:12px auto; padding:4px; border-radius:12px; } }

/* ==== компактные формы входа и регистрации — 12.11.2026 (ред. 1.59) ==== */
#register .field, #login-dialog .field, #login .field, .login-page .field { position:relative; margin:0 0 10px; }
#register .field input, #login-dialog .field input, #login .field input, .login-page .field input { margin:0; padding:15px 10px 5px; }
#register .field label, #login-dialog .field label, #login .field label, .login-page .field label { position:absolute; left:11px; top:50%; transform:translateY(-50%); margin:0; font-weight:400; color:var(--muted); pointer-events:none; transition:top .12s ease, transform .12s ease, font-size .12s ease; }
#register .field input:focus + label, #register .field input:not(:placeholder-shown) + label,
#register .field .password-field:has(input:focus) + label, #register .field .password-field:has(input:not(:placeholder-shown)) + label,
#login-dialog .field input:focus + label, #login-dialog .field input:not(:placeholder-shown) + label,
#login-dialog .field .password-field:has(input:focus) + label, #login-dialog .field .password-field:has(input:not(:placeholder-shown)) + label,
#login .field input:focus + label, #login .field input:not(:placeholder-shown) + label,
.login-page .field input:focus + label, .login-page .field input:not(:placeholder-shown) + label { top:.44rem; transform:none; font-size:.72rem; line-height:1; }
#register .field input::placeholder { color:transparent; }
#register .field input:focus::placeholder, #register .field input:not(:placeholder-shown)::placeholder { color:var(--muted); }
.who-pills { display:grid; grid-template-columns:1fr 1fr; gap:8px; }
.who-pills label.check { display:flex; align-items:center; min-height:44px; padding:6px 10px; margin:0; border:1px solid var(--line); border-radius:10px; font-weight:400; }
.who-pills label.check:has(input:checked) { border-color:var(--accent); background:var(--bg); }
.who-pills label.check span { font-size:.92rem; }
.consent-divider { margin:10px 0 2px; font-size:.78rem; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }
#register label.check { padding:3px 0; }
#register .q legend { font-size:.85rem; margin-bottom:2px; }
.register-dialog, .login-dialog { width:min(480px, calc(100vw - 24px)); padding:14px; }

/* Keep guest header controls on the same 1160px content grid as the landing. */
body:not(.signed):has(> main.landing) > header {
  padding-inline:max(16px,calc(50% - 564px));
}

/* Full-width footer with a centered four-column content grid. */
.landing-footer { margin-top:28px; background:#102f29; color:#fff; }
.landing-footer-inner { max-width:1160px; margin:0 auto; padding:40px 16px 76px; }
.landing-footer-grid { display:grid; grid-template-columns:minmax(0,1.2fr) minmax(0,1fr) minmax(0,1.3fr) minmax(0,1fr); gap:24px 36px; }
.landing-footer-grid > * { min-width:0; }
.landing-footer h2 { margin:0 0 12px; font-size:.95rem; font-weight:700; color:#fff; }
.landing-footer a { color:#dce9e3; text-underline-offset:4px; text-decoration:none; }
.landing-footer a:hover { color:#fff; text-decoration:underline; }
.landing-footer a:focus-visible { outline:3px solid var(--amber); outline-offset:4px; border-radius:4px; }
.landing-footer .landing-footer-brand { display:inline-flex; align-items:center; min-height:44px; font-size:1.1rem; font-weight:700; color:#fff; }
.landing-footer p { color:#dce9e3; margin:0 0 12px; font-size:.9rem; line-height:1.65; }
.landing-footer-links { list-style:none; padding:0; margin:0; }
.landing-footer-links a { display:inline-flex; align-items:center; gap:6px; min-height:44px; max-width:100%; padding:6px 0; font-size:.9rem; }
.landing-footer .landing-footer-name { display:flex; align-items:center; min-height:44px; font-weight:600; color:#fff; margin:0; }
.landing-footer-bottom { display:flex; align-items:center; justify-content:space-between; gap:12px 24px; flex-wrap:wrap; border-top:1px solid #ffffff26; margin-top:32px; padding-top:18px; }
.landing-footer-bottom small { color:#c0d4ca; font-size:.8rem; }
.landing-footer-bottom a { display:inline-flex; align-items:center; gap:8px; min-height:44px; font-size:.9rem; }
@media(max-width:480px) and (pointer:coarse) {
  .landing-footer-inner { padding-top:28px; }
  .landing-footer-grid { grid-template-columns:minmax(0,1fr); gap:26px; }
  .landing-footer-bottom { flex-direction:column; align-items:flex-start; }
}
@media(max-width:480px) and (pointer:coarse) {
  body:not(.signed):has(> main.landing) > header { padding-inline:12px; }
  .landing-footer-inner { padding-inline:12px; }
}

/* Shared back link on internal pages; the guest landing keeps its own header. */
header .header-back { flex:0 0 auto; gap:8px; min-height:44px; }
@media print { header .header-back { display:none; } }

/* Payment administration: equal controls and predictable form rows. */
.payments-page { --payment-button-width:200px; }
.payments-page button, .payments-page .payment-export {
  width:var(--payment-button-width); height:48px; min-height:48px; max-width:100%;
  padding:4px 12px; border-radius:12px; font-size:.95rem; line-height:1.15; text-align:center;
}
.payments-page .compact-tabs { display:grid; grid-template-columns:repeat(auto-fit,minmax(160px,1fr)); gap:10px; }
.payments-page .compact-tabs button { width:100%; margin:0; }
.payments-page .payment-form { margin:16px 0; }
.payments-page .payment-fields { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-bottom:12px; }
.payments-page label { min-width:0; margin:0; font-size:.9rem; font-weight:600; }
.payments-page input:is([type=text],[type=number],[type=url]) {
  display:block; width:100%; height:48px; min-height:48px; margin:6px 0 0; padding:10px 12px;
  border:1px solid #b9b2a4; border-radius:12px; background:var(--card); color:var(--ink); font:inherit; font-size:1rem;
}
.payments-page .payment-tariff { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:center; padding:14px 0; }
.payments-page .payment-actions { display:flex; flex-wrap:wrap; align-items:center; gap:10px; margin:0; }
.payments-page .payment-link-form { display:flex; flex-wrap:wrap; gap:12px 10px; }
.payments-page .payment-link-form > label { flex:0 0 100%; }
.payments-page table.grid { table-layout:fixed; }
.payments-page table.grid th, .payments-page table.grid td { padding:12px; overflow-wrap:anywhere; }
.payments-page .payment-history table { min-width:640px; }
@media(max-width:480px) and (pointer:coarse) {
  .payments-page .payment-tariff { grid-template-columns:minmax(0,1fr); }
  .payments-page .payment-fields { grid-template-columns:minmax(0,1fr); }
}
@media(max-width:480px) and (pointer:coarse) {
  .payments-page .compact-tabs { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .payments-page .payment-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); width:100%; }
  .payments-page .payment-actions button { width:100%; }
  .payments-page .payment-link-form > button { width:calc((100% - 10px) / 2); }
  .payments-page .payment-tariff-form > button, .payments-page .payment-export { width:100%; }
}

/* Camera photos and custom locked-step artwork. */
.step-lock{width:22px;height:26px;flex:0 0 22px;object-fit:contain;vertical-align:middle}
.photo-file{display:block;font-size:.9rem;margin:12px 0}.photo-file input{display:block;max-width:100%;margin-top:6px}
[data-photo-preview] img,.answer-photo img{display:block;width:auto;max-width:100%;max-height:420px;object-fit:contain;border-radius:12px;margin:10px 0}
.answer-photo{margin:16px 0}.photo-dialog{width:min(680px,calc(100% - 24px));max-height:90dvh;overflow:auto;border:1px solid var(--accent);border-radius:16px;padding:16px;background:#fff}
.photo-dialog::backdrop{background:rgba(12,32,27,.68)}.photo-dialog video{display:block;width:100%;max-height:60dvh;object-fit:contain;background:#173e34;margin:12px 0;border-radius:10px}
.photo-dialog .row{justify-content:space-between}.photo-dialog .row b{flex:1;min-width:150px}
@media(max-width:480px) and (pointer:coarse){.photo-dialog{padding:12px}.photo-capture input[type=file]{font-size:13px}}

/* Photorealistic weekday calendars replace the word/headphone label, keeping audio. */
button.say.weekday-art{display:inline-flex;align-items:center;justify-content:center;width:144px;min-height:112px;border-radius:12px;text-decoration:none;vertical-align:middle;transition:background-color .18s ease,transform .18s ease}
button.say.weekday-art::after{content:none;display:none}
.weekday-art img{display:block;width:144px;max-width:100%;height:auto;object-fit:contain}
button.say.weekday-art:hover,button.say.weekday-art:focus-visible{background:#edf5f0;outline:2px solid var(--accent);outline-offset:2px}
button.say.weekday-art.playing{background:#fff2cf;outline:2px solid var(--amber);outline-offset:2px}
@media(max-width:480px) and (pointer:coarse){
  button.say.weekday-art{width:96px;min-height:90px}.weekday-art img{width:96px}
  .words:has(.weekday-art),.words:has(.weekday-art) tbody{display:block;width:100%}
  .words:has(.weekday-art) tr{display:grid;grid-template-columns:96px minmax(0,1fr);column-gap:12px;row-gap:2px;padding:9px 0;border-bottom:1px solid var(--line)}
  .words:has(.weekday-art) tr:last-child{border-bottom:0}
  .words:has(.weekday-art) td{display:block;padding:0;border:0;overflow-wrap:normal}
  .words:has(.weekday-art) td:first-child{grid-column:1;grid-row:1 / 3;align-self:center}
  .words:has(.weekday-art) td:nth-child(2){grid-column:2;grid-row:1;align-self:end;font-size:.95rem;white-space:nowrap}
  .words:has(.weekday-art) td:nth-child(3){grid-column:2;grid-row:2;align-self:start}
}
@media(prefers-reduced-motion:reduce){button.say.weekday-art{transition:none}}

/* Generated physical phonetic cards; precise IPA remains accessible HTML. */
.sound.sound-picture{background:transparent;border:0;padding:0;isolation:isolate;border-radius:14px}
.sound-art{display:block;position:relative;width:100%;max-width:168px;margin:0 auto;container-type:inline-size}
.sound-art img{display:block;width:100%;height:auto;border-radius:0}
.sound-picture .sound-art .ipa{position:absolute;left:10%;top:50%;transform:translateY(-50%);width:80%;font-family:"Segoe UI","DejaVu Sans","Noto Sans",Arial,sans-serif;font-size:1.7rem;font-size:clamp(1.5rem,25cqw,3rem);font-weight:500;line-height:1.1;white-space:nowrap;color:#215845;text-shadow:0 1px 0 #fff9}
.sound-picture .n{top:14%;left:15%;z-index:1;font-size:.85rem;color:#52685d}
button.sound.sound-picture{transition:transform .15s ease,background-color .15s ease}
button.sound.sound-picture:hover,button.sound.sound-picture:focus-visible{background:#edf5f0;outline:2px solid var(--accent);outline-offset:2px;transform:translateY(-2px)}
button.sound.sound-picture.playing{background:#fff2cf;outline:2px solid #dfa11d;outline-offset:2px}
@media(prefers-reduced-motion:reduce){button.sound.sound-picture{transition:none}button.sound.sound-picture:hover,button.sound.sound-picture:focus-visible{transform:none}}

/* ==== 14.11.2026: при увеличении (зуме) страница не двигается — вариант 1+3 ==== */
/* 1) Контент кабинета пришит к левому краю, а не центрируется: при увеличении зума
      страница «растёт» вправо от неподвижного края — вкладки, карточки и переносы
      строк остаются на месте. Лендинг и гостевые страницы остаются по центру. */
body.signed main:not(.landing) { margin-left:24px; margin-right:0; }
/* 2) Постоянный резерв под вертикальную полосу прокрутки: её появление/исчезание
      (например, при зуме, когда контент стал выше окна) больше не сдвигает всё влево. */
html { scrollbar-gutter:stable; }
/* Мобильная вёрстка (запросы «max-width … and (pointer:coarse)» выше) включается
   только на сенсорных экранах: зум в настольном браузере не перескакивает в
   телефонный режим, а держит десктопную вёрстку 880px с горизонтальной прокруткой
   (развивает решение от 14.11.2026 о min-width:880px). */

/* Аналитика и Документы: разделы — свёрнутые карточки в столбик, раскрываются по нажатию (Максим, 15.11.2026) */
main.analytics details.card > summary, main.docs details.card > summary { color:var(--ink); justify-content:space-between; gap:10px; }
main.analytics details.card > summary h2, main.docs details.card > summary h2 { margin:0; }
main.analytics details.card > summary::after, main.docs details.card > summary::after { content:"▾"; color:var(--accent); flex:none; }
main.analytics details.card[open] > summary::after, main.docs details.card[open] > summary::after { content:"▴"; }
main.analytics details.card > summary::marker, main.analytics details.card > summary::-webkit-details-marker,
main.docs details.card > summary::marker, main.docs details.card > summary::-webkit-details-marker { display:none; list-style:none; }
main.analytics details.card > summary + *, main.docs details.card > summary + * { margin-top:10px; }

/* Тренажёр слов: плитки букв (unscramble) и сетка кроссворда (crossword + /lesson/<id>/practice). */
/* Кастомные плитки-карточки: нажатие кладёт букву в поле, повторное нажатие возвращает её. */
.letters { display:flex; flex-wrap:wrap; gap:8px; margin:10px 0; }
.tile {
  appearance:none; -webkit-appearance:none; font:inherit;
  min-width:48px; height:52px; padding:0 12px; border-radius:12px;
  border:1.5px solid var(--line); background:var(--card); color:var(--ink);
  font-weight:700; font-size:1.3rem; line-height:1; text-transform:lowercase;
  cursor:pointer; box-shadow:0 3px 0 var(--line);
  transition:transform .12s ease, box-shadow .12s ease, border-color .12s ease,
             background-color .12s ease, color .12s ease, opacity .12s ease;
}
.tile:hover { border-color:var(--accent); transform:translateY(-2px); box-shadow:0 5px 0 var(--line); }
.tile:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.tile:active { transform:translateY(1px); box-shadow:0 1px 0 var(--line); }
.tile.spent {
  background:#eceae4; color:var(--muted); border-color:var(--line);
  box-shadow:0 0 0 var(--line); transform:translateY(1px); opacity:.72;
}
@media(prefers-reduced-motion:reduce) { .tile { transition:none; } }
.exercise-item .say { margin-bottom:6px; }
.crossword-grid { margin:10px 0; overflow-x:auto; }
.cw-table { border-collapse:collapse; }
.cw-table td { padding:0; }
.cw-cell { border:1px solid var(--ink, #22262b); width:34px; height:38px; position:relative; background:#fff; }
.cw-empty { border:1px solid transparent; width:34px; height:38px; background:transparent; }
.cw-box { display:block; text-align:center; line-height:36px; font-weight:700; text-transform:lowercase; color:var(--accent, #2f6f5e); min-height:36px; }
.cw-n { position:absolute; top:1px; left:2px; font-size:10px; font-style:normal; color:var(--muted, #5b6370); }
