/* Copyright (c) 2026 Yuriy Voevodin. All rights reserved. */
/* Copyright © 2026 IURII VOEVODIN. All rights reserved. */
@import url("https://fonts.googleapis.com/css2?family=Roboto&family=Open+Sans&family=Noto+Sans&family=Fira+Sans&family=IBM+Plex+Sans&family=Rubik&family=Manrope&family=PT+Sans&family=Ubuntu&family=Noto+Serif&family=PT+Serif&family=Lora:ital@0;1&family=Merriweather:ital@0;1&family=Playfair+Display:ital@0;1&family=Literata&family=IBM+Plex+Serif&family=Source+Serif+4&family=GFS+Didot&family=Cormorant+Garamond&display=swap");
@font-face { font-family:"GFS Porson"; src:url("/fonts/alphabet/gfs-porson.otf") format("opentype"); font-display:swap; }
@font-face { font-family:"GFS Solomos"; src:url("/fonts/alphabet/gfs-solomos.otf") format("opentype"); font-display:swap; }

:root { --ink:#12303b; --muted:#667985; --line:#d9e5e5; --cream:#f1f7f5; --blue:#087e83; --blue-dark:#075b61; --yellow:#f2c75c; --coral:#ed6a5a; --navy:#0b3340; --aqua:#35c6ba; }
* { box-sizing:border-box; }
body { margin:0; background:var(--cream); color:var(--ink); font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; user-select:none; -webkit-user-select:none; }
input,textarea,[contenteditable="true"] { user-select:text; -webkit-user-select:text; }
button, input { font:inherit; }
button { color:inherit; }
.app-shell { min-height:100vh; display:flex; }
.sidebar { width:235px; background:#fff; border-right:1px solid var(--line); padding:30px 22px 20px; display:flex; flex-direction:column; position:fixed; inset:0 auto 0 0; z-index:5; }
.brand { border:0; background:none; display:flex; align-items:center; gap:11px; padding:0 9px 31px; cursor:pointer; }
.brand span,.mobile-brand { width:35px; height:35px; border-radius:11px 11px 11px 3px; background:var(--blue); color:#fff; display:grid; place-items:center; font:700 25px Georgia; box-shadow:0 5px 0 #3d48b2; }
.brand b { font:700 23px Georgia; letter-spacing:.5px; }
nav { display:flex; flex-direction:column; gap:7px; }
nav button { border:0; background:none; border-radius:12px; padding:13px 14px; text-align:left; color:#687287; font-weight:700; display:flex; gap:14px; align-items:center; cursor:pointer; }
nav button span { font-size:20px; width:22px; text-align:center; }
nav .nav-active { background:#eef0ff; color:var(--blue); }
.course-card { margin-top:auto; border-top:1px solid var(--line); padding:20px 5px 0; display:flex; align-items:center; gap:10px; }
.course-card .flag { background:#e7f1ff; color:#166ac1; padding:7px 6px; border-radius:7px; font-size:11px; font-weight:800; }
.course-card div { display:flex; flex-direction:column; flex:1; gap:3px; }.course-card small{color:#9aa1b1;font-size:10px;text-transform:uppercase}.course-card b{font-size:12px}
.course-selector-trigger{width:100%;border:0;background:transparent;color:inherit;text-align:left;cursor:pointer}.course-selector-trigger>span:last-child{margin-left:auto;font-size:18px}.course-selector-modal{width:min(490px,calc(100vw - 34px));background:#fff;border-radius:24px;padding:26px;box-shadow:0 28px 90px rgba(18,25,52,.3)}.course-selector-modal header{display:flex;align-items:flex-start;justify-content:space-between;margin-bottom:20px}.course-selector-modal header small{font-size:10px;letter-spacing:1.4px;color:#07858b;font-weight:900}.course-selector-modal h2{margin:5px 0 0;font:700 27px Georgia,"Times New Roman",serif;color:#173540}.course-selector-modal header button{border:0;background:transparent;font-size:28px;line-height:1;color:#8d96a9;cursor:pointer}.course-language-options{display:grid;gap:10px}.course-language-options>button{width:100%;border:1px solid #d9e3e6;border-radius:15px;background:#fff;padding:15px;display:flex;align-items:center;gap:13px;text-align:left;color:#173540;cursor:pointer}.course-language-options>button.active{border-color:#43c5c1;background:#edfafa;box-shadow:inset 0 0 0 1px #87ddd9}.course-language-options>button>span{font-size:30px;line-height:1}.course-language-options div{display:grid;gap:3px}.course-language-options b{font-size:16px}.course-language-options small{font-size:12px;color:#82909c}.course-language-options i{margin-left:auto;font-style:normal;color:#088a72;font-size:20px;font-weight:900}
.workspace { margin-left:235px; width:calc(100% - 235px); min-height:100vh; }
.topbar { height:76px; background:#fff; border-bottom:1px solid var(--line); display:flex; align-items:center; justify-content:flex-end; padding:0 40px; gap:27px; }
.streak,.stat { display:flex; align-items:center; gap:8px; font-size:14px; }.streak>span{color:var(--coral);font-size:22px}.streak div{display:flex;flex-direction:column}.streak small{font-size:10px;color:#9aa1b1;text-transform:uppercase}.heart{color:#f05d6e}.coin{color:#e2a919}.avatar{border:0;background:#e8d9c7;color:#674d3b;width:37px;height:37px;border-radius:50%;font-weight:800;cursor:pointer}.mobile-brand,.mobile-language{display:none;border:0}.mobile-language{align-items:center;gap:3px;border:1px solid #d4e9e8;background:#f5fbfb;color:#0b5961;border-radius:12px;padding:6px 8px;font-size:10px;font-weight:900;cursor:pointer}.mobile-language span{font-size:16px;line-height:1}.mobile-language b{font-size:10px}
.lesson-wrap { max-width:1080px; margin:0 auto; padding:31px 54px 0; min-height:calc(100vh - 76px); display:flex; flex-direction:column; }
.lesson-head { display:flex; align-items:center; gap:20px; }.close{border:0;background:none;font-size:28px;color:#9aa1b1;cursor:pointer}.progress-track{height:9px;background:#e1e3e8;border-radius:9px;flex:1;overflow:hidden}.progress-track div{height:100%;background:linear-gradient(90deg,var(--yellow),#ffb42f);border-radius:9px;transition:width .4s}.counter{font-weight:800;font-size:15px}.counter i{font-style:normal;color:#a3a8b4;font-size:12px}
.exercise-card { background:#fff; border:1px solid #e5e2da; border-radius:22px; padding:35px 48px 31px; margin-top:25px; box-shadow:0 8px 28px rgba(55,49,35,.06); min-height:520px; }
.eyebrow { display:flex; justify-content:space-between; color:#9aa1ae; font-size:10px; font-weight:800; letter-spacing:1.2px; }.exercise-card h1{font:700 27px Georgia,serif;text-align:center;margin:28px 0 22px}.prompt{border:0;background:none;margin:0 auto 30px;display:flex;align-items:center;gap:18px;font:700 28px Georgia;cursor:pointer}.speaker{background:var(--blue);color:white;width:46px;height:46px;border-radius:50%;display:grid;place-items:center;font:700 25px Arial;box-shadow:0 4px 0 #414cb4;transform:rotate(0deg)}.prompt-static{cursor:default;text-align:center;justify-content:center}
.answer-zone { min-height:93px; border-top:1px solid #dfe2e9; border-bottom:1px solid #dfe2e9; padding:15px 8px; display:flex; align-content:flex-start; flex-wrap:wrap; gap:9px; position:relative; }.placeholder{color:#b4b9c4;margin:auto;font-size:13px}.word-bank{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;padding:27px 10px 5px;min-height:90px;border:1px dashed transparent;border-radius:12px;transition:.18s}.word-bank.drop-ready{border-color:#ff9a91;background:#fff5f3}.word-bank.drop-ready:after{content:"Перетащите сюда, чтобы удалить";width:100%;text-align:center;color:#d86056;font-size:11px;font-weight:700}.word-chip{border:1px solid #cfd4df;background:#fff;border-radius:10px;padding:10px 15px;font-weight:700;font-size:14px;box-shadow:0 3px 0 #d5d9e1;cursor:grab;transition:.15s;touch-action:none;user-select:none;-webkit-user-select:none}.word-chip:active,.word-chip[aria-grabbed="true"]{cursor:grabbing}.word-chip[aria-grabbed="true"]{opacity:.72;transform:translateY(-1px) scale(.98)}.word-chip:hover{transform:translateY(-1px);border-color:#aab2c3}.word-chip:disabled{opacity:.17;cursor:default}.word-chip.selected{border-color:#8f98e4;background:#f0f1ff;color:#3e49ac}.hint-wrap{text-align:center;margin-top:12px}.hint-toggle{border:0;background:none;color:#737dbb;font-size:12px;font-weight:700;cursor:pointer;padding:8px}.hint-panel{max-width:640px;margin:5px auto 0;background:#f6f7ff;border:1px solid #dfe2fb;border-radius:12px;padding:13px 17px;text-align:left}.hint-panel b{font-size:11px;text-transform:uppercase;color:#727bb4;letter-spacing:.6px}.hint-panel p{font:700 17px Georgia;margin:6px 0;color:#303a71}.hint-panel small{display:block;color:#667087;line-height:1.5;font-size:12px}
.action-bar { min-height:115px; margin-top:auto; display:flex; justify-content:space-between; align-items:center; padding:20px 8px; }.check{border:0;background:var(--blue);box-shadow:0 5px 0 var(--blue-dark);color:white;border-radius:12px;padding:15px 25px;font-weight:800;letter-spacing:.5px;cursor:pointer;margin-left:auto}.check:disabled{background:#c8ccd5;box-shadow:0 5px 0 #adb2bd;cursor:not-allowed}.check kbd{font-size:10px;background:rgba(255,255,255,.18);border-radius:4px;padding:3px 5px;margin-left:12px}.action-bar.correct{background:#e8f8ed;margin-left:-54px;margin-right:-54px;padding-left:62px;padding-right:62px}.action-bar.correct .check{background:#2daf69;box-shadow:0 5px 0 #218e53}.action-bar.wrong{background:#fff0ee;margin-left:-54px;margin-right:-54px;padding-left:62px;padding-right:62px}.action-bar.wrong .retry{background:var(--coral);box-shadow:0 5px 0 #d94e43}.feedback{display:flex;align-items:center;gap:12px}.feedback>span{width:42px;height:42px;border-radius:50%;background:white;display:grid;place-items:center;font-weight:900;font-size:20px}.feedback div{display:flex;flex-direction:column;gap:3px}.feedback small{color:#718078}.correct .feedback{color:#18884c}.wrong .feedback{color:#d64d43}.auto-next{margin-left:auto;color:#258853;font-size:12px;font-weight:800;letter-spacing:.3px}
.big-word{margin:5px auto 35px;border:0;background:none;display:flex;align-items:center;gap:18px;cursor:pointer;font:700 34px Georgia}.choices{display:grid;grid-template-columns:1fr 1fr;gap:12px;max-width:620px;margin:auto}.choices button{position:relative;min-width:0;border:1px solid #d6dae3;background:white;border-radius:12px;padding:15px;text-align:center;font-weight:700;cursor:pointer;box-shadow:0 3px 0 #e0e3e9;display:flex;align-items:center;justify-content:center;overflow:hidden;white-space:nowrap}.choices button span{position:absolute;left:14px;display:inline-grid;place-items:center;border:1px solid #d8dce5;border-radius:6px;width:25px;height:25px;margin:0;color:#9ba1ae}.choices button.choice-picked{background:#eef0ff;border-color:#818be2;color:#404ab0}.match-note{text-align:center;color:#8f97a7;font-size:13px}.matching{display:grid;grid-template-columns:1fr 1fr;gap:16px;width:100%;max-width:650px;margin:14px auto}.matching>div{display:flex;flex-direction:column;gap:8px}.matching button{height:clamp(40px,calc((100dvh - 510px)/6),48px);min-height:0;padding:5px 10px;border:1px solid #d6dae3;background:#fff;border-radius:12px;font-weight:700;box-shadow:0 3px 0 #e0e3e9;cursor:pointer}.matching button.match-picked{border-color:#747fdd;background:#eef0ff;color:#414cb1}.matching button:disabled{background:#edf8f1;color:#27935b;border-color:#b8e4c8;box-shadow:none}
.match-label{display:flex;flex-direction:column;align-items:center;gap:2px;line-height:1.05}.match-label small{font:500 10px/1.15 system-ui,sans-serif;color:#8994a7}.matching button:disabled .match-label small{color:#6cae88}
.modal-backdrop{position:fixed;inset:0;background:rgba(27,32,50,.48);z-index:20;display:grid;place-items:center;padding:25px}.vocab-modal{width:min(820px,100%);height:min(760px,90vh);background:#f9f8f4;border-radius:24px;padding:32px;position:relative;display:flex;flex-direction:column;box-shadow:0 25px 80px rgba(20,25,50,.25)}.modal-close{position:absolute;right:24px;top:18px;border:0;background:none;font-size:30px;color:#8b92a2;cursor:pointer}.vocab-title{display:flex;gap:17px;align-items:center}.vocab-title>span{font:700 35px Georgia;background:var(--yellow);width:75px;height:75px;border-radius:18px 18px 18px 5px;display:grid;place-items:center}.vocab-title small{color:#8d95a5;font-weight:800;font-size:10px;letter-spacing:1px}.vocab-title h2{font:700 28px Georgia;margin:4px 0}.vocab-modal>p{color:#717a8d;line-height:1.5;font-size:14px;max-width:680px}.vocab-modal input{border:1px solid #d8dce3;background:white;border-radius:12px;padding:13px 16px;outline:none;margin:5px 0 18px}.vocab-modal input:focus{border-color:var(--blue)}.vocab-grid{overflow:auto;display:grid;grid-template-columns:repeat(3,1fr);gap:8px;padding-right:7px}.vocab-grid button{border:1px solid #e0e2e7;background:white;border-radius:10px;padding:10px;text-align:left;display:flex;align-items:center;gap:8px;cursor:pointer}.vocab-grid small{color:#a0a6b2;width:34px}.vocab-grid b{font:700 17px Georgia;flex:1}.vocab-grid span{color:var(--blue)}.download{color:var(--blue);font-weight:800;text-decoration:none;margin-top:18px;text-align:center;font-size:13px}
.lesson-summary-backdrop{z-index:80;background:rgba(8,38,48,.62)}.lesson-summary{width:min(520px,100%);position:relative;overflow:hidden;text-align:center;background:#fff;border-radius:28px;padding:34px;box-shadow:0 28px 90px rgba(0,0,0,.32)}.lesson-summary h2{font:700 27px Georgia;margin:8px 0 14px;color:var(--navy)}.summary-score{display:flex;align-items:baseline;justify-content:center;gap:8px;color:var(--blue)}.summary-score b{font:700 72px/1 Georgia}.summary-score span{font-weight:800;font-size:18px;color:#7a8796}.summary-score-label{margin:3px 0 24px;color:#637283;font-weight:700}.summary-metrics{display:grid;gap:9px;text-align:left}.summary-metrics article{border:1px solid var(--line);border-radius:13px;padding:12px 15px;display:flex;align-items:center;justify-content:space-between;gap:16px}.summary-metrics small{font-size:9px;letter-spacing:1px;font-weight:900;color:#758395}.summary-metrics b{font:700 20px Georgia;color:var(--blue);white-space:nowrap}.lesson-summary-actions{display:grid;gap:9px;margin-top:23px}.lesson-summary-actions button{width:100%;min-width:0;border:1px solid #cbd3dd;background:#fff;border-radius:12px;padding:14px 12px;font-weight:850;cursor:pointer}.lesson-summary-actions .start-button{border:0}.confetti{position:absolute;inset:0;pointer-events:none;overflow:hidden}.confetti i{position:absolute;left:calc((var(--piece) + 1) * 4%);top:-12px;width:8px;height:14px;border-radius:2px;background:hsl(calc(var(--piece) * 31),82%,58%);animation:confetti-fall 1.7s cubic-bezier(.2,.7,.3,1) both;animation-delay:calc(var(--piece) * -45ms)}@keyframes confetti-fall{to{transform:translate(calc((var(--piece) - 12) * 8px),340px) rotate(540deg);opacity:0}}

/* Every full-screen result or dialog gets one mobile scroll container. */
@media(max-width:850px){.modal-backdrop{display:block;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding:16px}.modal-backdrop>*{margin:0 auto}.lesson-summary{max-height:calc(100dvh - 32px);overflow-y:auto;-webkit-overflow-scrolling:touch}}
@media(max-width:850px){.sidebar{display:none}.workspace{margin:0;width:100%}.mobile-brand{display:grid}.mobile-language{display:flex}.topbar{height:66px;padding:0 18px;justify-content:space-between;gap:12px}.streak small{display:none}.lesson-wrap{padding:20px 18px 0;min-height:calc(100vh - 66px)}.exercise-card{padding:25px 22px;min-height:520px}.exercise-card h1{font-size:23px}.prompt{font-size:22px}.eyebrow span:last-child{display:none}.action-bar.correct,.action-bar.wrong{margin-left:-18px;margin-right:-18px;padding:18px}.feedback small{display:none}.vocab-grid{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.streak{display:none}.exercise-card{margin-top:18px;border-radius:17px}.lesson-head{gap:10px}.answer-zone{min-height:110px}.choices{grid-template-columns:1fr}.matching{gap:10px}.matching button{padding:7px;font-size:13px}.action-bar{min-height:95px}.check{width:100%;margin:0}.feedback{display:none}.vocab-modal{padding:24px 18px}.vocab-grid{grid-template-columns:1fr}.vocab-title>span{width:60px;height:60px;font-size:27px}}

/* Product sections */
.catalog-stat{display:flex;flex-direction:column;align-items:flex-end;line-height:1}.catalog-stat b{font-size:14px}.catalog-stat small{font-size:9px;color:#9aa1b1;text-transform:uppercase;margin-top:4px}.page-content{max-width:1120px;margin:0 auto;padding:55px 58px 70px}.page-heading{min-height:285px;background:#232d55;color:white;border-radius:26px;padding:44px 52px;display:flex;justify-content:space-between;align-items:center;position:relative;overflow:hidden}.page-heading:after{content:"α";position:absolute;right:210px;top:-75px;font:700 330px Georgia;color:rgba(255,255,255,.035);transform:rotate(-9deg)}.kicker{font-size:10px;font-weight:900;letter-spacing:1.8px;color:#9da8ea}.page-heading h1,.catalog-heading h1,.stats-page>h1{font:700 40px/1.05 Georgia;margin:13px 0}.page-heading p{color:#b9c1dd;font-size:14px}.start-orb{width:138px;height:138px;border:0;border-radius:50%;background:var(--yellow);color:#2d3350;box-shadow:0 9px 0 #d9a62f;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:9px;cursor:pointer;z-index:1}.start-orb span{font-size:32px;margin-left:5px}.start-orb b{font-size:11px;letter-spacing:1px}.mode-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:12px;margin:23px 0}.mode-grid article{background:white;border:1px solid var(--line);border-radius:15px;padding:18px 15px;min-height:145px}.mode-grid article>span{display:grid;place-items:center;width:39px;height:39px;background:#eef0ff;color:var(--blue);border-radius:10px;font-weight:900;font-size:12px}.mode-grid h3{font-size:14px;margin:15px 0 6px}.mode-grid p{font-size:11px;line-height:1.45;color:#858d9e;margin:0}.course-strip{background:white;border:1px solid var(--line);border-radius:16px;padding:20px 23px;display:grid;grid-template-columns:1.2fr 1fr auto;gap:25px;align-items:center}.course-strip div:first-child{display:flex;flex-direction:column;gap:5px}.course-strip small{font-size:9px;color:#9299a8;font-weight:800;letter-spacing:1px}.course-strip b{font-size:13px}.course-strip button{border:0;background:none;color:var(--blue);font-weight:800;cursor:pointer}.mini-progress,.accuracy-track{height:7px;background:#eceef2;border-radius:10px;overflow:hidden}.mini-progress span,.accuracy-track span{display:block;height:100%;background:var(--yellow);border-radius:10px}.attempt{font-size:10px;font-weight:800;color:#da795f;background:#fff0eb;padding:7px 10px;border-radius:7px}.listen-orb{border:0;background:none;margin:20px auto 35px;display:flex;flex-direction:column;align-items:center;gap:12px;color:var(--blue);cursor:pointer}.listen-orb span{display:grid;place-items:center;width:84px;height:84px;background:var(--blue);color:white;border-radius:50%;box-shadow:0 7px 0 var(--blue-dark);font-size:40px}.listen-orb b{font-size:10px;letter-spacing:1px}.hint-toggle{display:block;margin:14px auto 0}.skipped.action-bar{background:#fff0ee;margin-left:-54px;margin-right:-54px;padding-left:62px;padding-right:62px;color:#c84e45}

/* Catalogs */
.catalog-page{max-width:1180px}.catalog-heading{display:flex;justify-content:space-between;align-items:end;border-bottom:1px solid var(--line);padding-bottom:27px;margin-bottom:26px}.catalog-heading h1{margin-bottom:7px}.catalog-heading p{margin:0;color:#7c8598;font-size:13px}.catalog-heading input{width:330px;border:1px solid #d8dce4;background:white;border-radius:12px;padding:13px 16px;outline:none}.catalog-heading input:focus{border-color:var(--blue)}.word-catalog{display:grid;grid-template-columns:repeat(3,1fr);gap:11px}.word-catalog article{background:white;border:1px solid var(--line);border-radius:13px;padding:15px;display:flex;gap:13px;min-height:126px}.sound-mini{border:0;background:#eef0ff;color:var(--blue);border-radius:9px;width:35px;height:35px;flex:none;cursor:pointer}.word-catalog article>div{min-width:0}.word-catalog small{font-size:9px;color:#999faf;text-transform:uppercase}.word-catalog h3{font:700 18px Georgia;margin:4px 0}.word-catalog p{font-size:12px;margin:0 0 8px;color:#596378}.word-catalog span{font-size:9px;color:#8d94a2}.catalog-note{text-align:center;color:#8e96a7;font-size:11px}.phrase-list{display:flex;flex-direction:column;gap:9px}.phrase-list article{display:grid;grid-template-columns:45px 1fr auto;align-items:center;background:white;border:1px solid var(--line);border-radius:14px;padding:15px 17px}.phrase-index{font:700 15px Georgia;color:#b2b7c3}.phrase-copy{display:flex;gap:13px;align-items:center}.phrase-copy>button{border:0;background:#eef0ff;color:var(--blue);width:35px;height:35px;border-radius:50%;cursor:pointer}.phrase-copy h3{font:700 17px Georgia;margin:0 0 4px}.phrase-copy p{font-size:12px;margin:0 0 5px;color:#5f687a}.phrase-copy small{font-size:9px;color:#9a9fad}.phrase-actions{display:flex;gap:6px}.phrase-actions button{border:1px solid #d7dbe5;background:white;border-radius:8px;padding:8px 10px;font-size:10px;font-weight:900;color:var(--blue);cursor:pointer}.phrase-actions button:hover{background:#eef0ff}.stats-page{max-width:960px}.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin:30px 0}.stats-grid article{background:white;border:1px solid var(--line);border-radius:18px;padding:25px;text-align:center;display:flex;flex-direction:column;gap:8px}.stats-grid span{font-size:22px;color:var(--blue)}.stats-grid b{font:700 36px Georgia}.stats-grid small{font-size:10px;color:#8d95a5}.accuracy-card{background:#232d55;color:white;border-radius:22px;padding:31px;display:grid;grid-template-columns:auto 1fr auto;gap:30px;align-items:center}.accuracy-card>div:first-child{display:flex;flex-direction:column}.accuracy-card small{font-size:9px;color:#adb5d2;letter-spacing:1px}.accuracy-card b{font:700 28px Georgia}.accuracy-card button{border:0;background:var(--yellow);border-radius:10px;padding:12px 16px;font-weight:800;cursor:pointer}

/* Full-screen hint */
.hint-screen{position:fixed;inset:0;background:#f6f5f0;z-index:50;overflow:auto}.hint-screen>header{height:78px;background:white;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 max(28px,calc((100vw - 950px)/2))}.hint-screen>header div{display:flex;flex-direction:column;gap:3px}.hint-screen>header span{font-size:9px;color:var(--blue);letter-spacing:1.3px;font-weight:900}.hint-screen>header b{font-size:13px}.hint-screen>header button{border:0;background:none;font-size:30px;color:#8e95a5;cursor:pointer}.hint-screen>main{max-width:950px;margin:auto;padding:35px 30px 110px}.hint-phrase{background:#232d55;color:white;border-radius:20px;padding:28px 32px;display:flex;gap:22px;align-items:center}.hint-phrase>button{border:0;background:var(--yellow);width:52px;height:52px;border-radius:50%;font-size:23px;cursor:pointer}.hint-phrase h2{font:700 27px Georgia;margin:0 0 7px}.hint-phrase p{margin:0;color:#bdc5df}.grammar-summary{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:17px 0 30px}.grammar-summary article{background:white;border:1px solid var(--line);border-radius:14px;padding:19px}.grammar-summary small{font-size:9px;color:var(--blue);font-weight:900;letter-spacing:1px}.grammar-summary p{font-size:13px;line-height:1.55;margin:8px 0 0;color:#5c6578}.word-breakdown-title{font:700 22px Georgia}.word-breakdown{display:grid;grid-template-columns:1fr 1fr;gap:10px}.word-breakdown article{background:white;border:1px solid var(--line);border-radius:13px;padding:14px;display:flex;gap:12px}.word-breakdown button{border:0;background:#eef0ff;color:var(--blue);border-radius:8px;width:32px;height:32px;flex:none;cursor:pointer}.word-breakdown small{font-size:8px;color:#989faf;text-transform:uppercase}.word-breakdown h4{font:700 17px Georgia;margin:3px 0}.word-breakdown p{font-size:12px;margin:0 0 5px;color:#3e4960}.word-breakdown span{font-size:9px;line-height:1.4;color:#8991a1}.hint-screen>footer{position:fixed;bottom:0;left:0;right:0;background:white;border-top:1px solid var(--line);padding:16px;display:flex;justify-content:center}.hint-screen>footer button{border:0;background:var(--blue);color:white;border-radius:11px;padding:14px 24px;font-weight:800;cursor:pointer;box-shadow:0 4px 0 var(--blue-dark)}

.word-breakdown .word-analysis-line{display:block;margin-top:5px;font-size:11px;line-height:1.5;color:#596579}.word-breakdown .word-analysis-line b{color:#263c49}
@media(max-width:1050px){.mode-grid{grid-template-columns:repeat(3,1fr)}.word-catalog{grid-template-columns:1fr 1fr}.page-content{padding-left:30px;padding-right:30px}.phrase-list article{grid-template-columns:38px 1fr}.phrase-actions{grid-column:2;margin-top:11px}}
@media(max-width:850px){.page-content{padding:30px 18px}.page-heading{padding:34px 28px}.page-heading h1{font-size:32px}.start-orb{width:110px;height:110px}.mode-grid{grid-template-columns:1fr 1fr}.course-strip{grid-template-columns:1fr}.catalog-heading{align-items:stretch;flex-direction:column;gap:17px}.catalog-heading input{width:100%}.word-catalog{grid-template-columns:1fr 1fr}.skipped.action-bar{margin-left:-18px;margin-right:-18px;padding:18px}.word-breakdown{grid-template-columns:1fr}}
@media(max-width:560px){.catalog-stat{display:none}.page-heading{min-height:360px;align-items:flex-start;flex-direction:column}.start-orb{align-self:flex-end}.mode-grid,.word-catalog,.stats-grid{grid-template-columns:1fr}.phrase-list article{grid-template-columns:1fr}.phrase-index{display:none}.phrase-actions{grid-column:1}.grammar-summary{grid-template-columns:1fr}.accuracy-card{grid-template-columns:1fr}.hint-screen>main{padding:20px 14px 100px}.hint-phrase{padding:22px 18px}.hint-phrase h2{font-size:21px}.lesson-wrap{padding-left:12px;padding-right:12px}.exercise-card{padding-left:17px;padding-right:17px}.attempt{display:none}}

/* Unified audio controls */
.speaker{border-radius:11px;font-size:18px}
.listen-orb span{border-radius:16px;font-size:28px}
.sound-mini{border-radius:9px;font-size:14px}
.phrase-copy>button{border-radius:9px;font-size:14px}
.phrase-actions .audio-action{width:34px;height:34px;padding:0;display:grid;place-items:center;font-size:13px}
.hint-phrase>button{border-radius:12px;font-size:18px}
.word-breakdown button{border-radius:8px;font-size:12px}
.answer-comparison{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:14px}.answer-result{border-radius:14px;padding:16px 18px;display:flex;flex-direction:column;gap:7px}.answer-result small{font-size:9px;font-weight:900;letter-spacing:1px}.answer-result strong{font-size:18px;line-height:1.5}.correct-result{background:#eaf8ef;border:1px solid #b9e3c8}.correct-result small{color:#268353}.incorrect-result{background:#fff3f1;border:1px solid #f0c1bc}.incorrect-result small{color:#b84b42}.submitted-words{display:flex;flex-wrap:wrap;gap:4px 8px}.answer-error{color:#bd3028;text-decoration-line:line-through;text-decoration-color:#d9362d;text-decoration-thickness:3px;text-decoration-skip-ink:none;background:#ffe2de;border-radius:3px}.missing-word{color:#17884f;text-decoration-line:underline;text-decoration-color:#1c9c5c;text-decoration-thickness:3px;text-underline-offset:5px;text-decoration-skip-ink:none;background:#e3f7eb;border-radius:3px;font-size:inherit;font-style:normal;font-weight:800}
.inline-answer{align-self:stretch;width:100%;min-width:0;max-width:none;margin:38px auto;text-align:center}.inline-answer h1{margin-bottom:22px}.inline-answer>p{color:#687387;font-size:14px}

/* Readable Greek typography */
.prompt,.big-word,.word-chip,.matching button,.phrase-copy h3,.word-catalog h3,.hint-phrase h2,.word-breakdown h4,.brand b{font-family:Georgia,"Times New Roman",serif;letter-spacing:.01em}
.prompt,.big-word,.phrase-copy h3,.hint-phrase h2,.word-breakdown h4{line-height:1.35}
@media(max-width:680px){.answer-comparison{grid-template-columns:1fr}.hint-screen .answer-comparison{gap:8px;margin-bottom:10px}.hint-screen .answer-result{padding:12px 14px;gap:4px}.hint-screen .answer-result strong{font-size:16px;line-height:1.35;overflow-wrap:anywhere}.hint-screen .submitted-words{gap:3px 6px}.hint-screen .answer-error{text-underline-offset:3px;text-decoration-thickness:2px}}
@media(max-width:560px){.hint-phrase{padding:20px 18px;gap:14px}.hint-phrase h2{font-size:22px;line-height:1.25}.hint-phrase-heading{display:flex;flex-direction:column;gap:8px;margin-bottom:6px}.translate-check{position:static;align-self:flex-end}}

/* Local storage consent */
.consent-backdrop{position:fixed;inset:0;z-index:100;background:rgba(25,31,52,.58);display:grid;place-items:center;padding:20px;backdrop-filter:blur(4px)}
.consent-card{width:min(560px,100%);background:#fff;border-radius:22px;padding:29px;box-shadow:0 28px 90px rgba(18,25,52,.3);display:grid;grid-template-columns:58px 1fr;gap:18px}
.consent-mark{width:52px;height:52px;border-radius:14px 14px 14px 4px;background:var(--blue);color:#fff;display:grid;place-items:center;font-size:30px;font-weight:700}
.consent-card small{font-size:9px;letter-spacing:1.4px;font-weight:900;color:var(--blue)}
.consent-card h2{font-size:25px;margin:7px 0 9px}
.consent-card p{font-size:14px;line-height:1.55;color:#667087;margin:0}
.consent-actions{grid-column:1/-1;display:flex;justify-content:flex-end;gap:9px;margin-top:6px}
.consent-actions button{border-radius:10px;padding:12px 16px;font-weight:700;cursor:pointer}
.consent-primary{border:0;background:var(--blue);color:#fff;box-shadow:0 4px 0 var(--blue-dark)}
.consent-secondary{border:1px solid #d9dde6;background:#fff;color:#687287}
.preparation-card{width:min(420px,100%);background:#fff;border-radius:22px;padding:30px;text-align:center;box-shadow:0 28px 90px rgba(18,25,52,.3)}
.preparation-card h2{margin:16px 0 7px;font-size:25px}.preparation-card p{margin:0 0 8px;color:#46536a;font-weight:700}.preparation-card small{color:#7d8799;line-height:1.45}.preparation-card button{margin-top:18px;border:0;border-radius:11px;padding:12px 24px;font-weight:800}
.loading-spinner{display:inline-block;width:34px;height:34px;border:4px solid #d8eff0;border-top-color:var(--blue);border-radius:50%;animation:akoema-spin .8s linear infinite}
.preparation-warning{display:grid;width:42px;height:42px;margin:auto;place-items:center;border-radius:50%;background:#fff0ed;color:#c95248;font-size:25px;font-weight:900}
.catalog-loading{min-height:220px;display:flex;align-items:center;justify-content:center;gap:14px;color:#687287;font-weight:750}
@keyframes akoema-spin{to{transform:rotate(360deg)}}
.microphone-waves{width:34px;height:36px;display:flex;align-items:center;justify-content:center;gap:3px;flex:0 0 34px}
.microphone-waves i{display:block;width:3px;min-height:5px;max-height:32px;border-radius:4px;background:#ff8c80;transition:height 45ms linear}
.reading-state.is-listening .microphone-waves{filter:drop-shadow(0 0 6px rgba(255,106,94,.35))}

/* A lesson occupies one mobile viewport: dragging never competes with page scrolling. */
@media(max-width:850px){
  body.lesson-active{overflow:hidden;overscroll-behavior:none}
  body.lesson-active .app-shell,body.lesson-active .workspace{height:100dvh;min-height:100dvh;overflow:hidden}
  /* Explicitly restore the document scroll container after the summary closes.
     This prevents mobile Safari from retaining the lesson viewport's height. */
  html:not(.lesson-active),body:not(.lesson-active){height:auto;min-height:100%;overflow-y:auto;overscroll-behavior:auto}
  body:not(.lesson-active) .app-shell,body:not(.lesson-active) .workspace{height:auto;min-height:100vh;overflow:visible}
  body.lesson-active .workspace .topbar{display:none}
  .lesson-wrap{height:100dvh;min-height:0;padding:10px 12px 0;overflow:hidden}
  .lesson-head{height:34px;flex:none}
  .exercise-card{flex:1;min-height:0;margin-top:8px;padding:13px 15px 8px;overflow:hidden;display:flex;flex-direction:column}
  .exercise-card h1{font-size:20px;margin:10px 0 9px}
  .prompt{font-size:20px;margin-bottom:12px;gap:10px}
  .speaker{width:38px;height:38px;flex:none}
  .listen-orb{margin:4px auto 11px;gap:8px}.listen-orb span{width:58px;height:58px;border-radius:13px;font-size:21px}
  .answer-zone{min-height:68px;padding:8px 5px;gap:6px;flex:none}
  .word-bank{min-height:58px;padding:10px 4px 2px;gap:6px;flex:none}
  .word-chip{padding:7px 10px;font-size:13px;touch-action:none;user-select:none;-webkit-user-select:none}
  .hint-toggle{margin:5px auto 0;padding:5px}
  .choices{gap:7px}.choices button{padding:10px}
  .matching{margin:6px auto;gap:8px}.matching>div{gap:6px}.matching button{height:clamp(34px,calc((100dvh - 290px)/6),46px);min-height:0;padding:4px 7px;font-size:13px}
  .action-bar{height:76px;min-height:76px;flex:none;padding:10px 6px}
  .action-bar.correct,.action-bar.wrong,.skipped.action-bar{margin-left:-12px;margin-right:-12px;padding:10px 18px}
}
@media(max-width:520px){
  .consent-card{grid-template-columns:1fr;padding:23px}.consent-mark{width:45px;height:45px}.consent-actions{grid-column:1;flex-direction:column-reverse}.consent-actions button{width:100%}
}
@media(max-width:850px) and (max-height:690px){
  .eyebrow{display:none}.exercise-card h1{margin-top:3px;font-size:18px}.listen-orb span{width:48px;height:48px}.listen-orb b{display:none}.word-chip{padding:6px 9px}.action-bar{height:64px;min-height:64px}.hint-toggle{font-size:10px}
}

/* Audio controls keep a stable square hit area beside long text. */
.speaker{width:46px;min-width:46px;max-width:46px;flex:0 0 46px}
.listen-orb span{width:84px;min-width:84px;max-width:84px;flex:0 0 84px}
.number-card{min-height:0}.number-prompt{max-width:760px;justify-content:center;text-align:center}.number-display{width:min(440px,100%);min-height:68px;margin:0 auto 14px;padding:12px 18px;border:1px solid var(--line);border-radius:14px;background:#f5f8f8;color:#a4afb6;text-align:right;font:700 34px/1.25 Arial,Helvetica,sans-serif;letter-spacing:.02em;font-variant-numeric:lining-nums tabular-nums;font-feature-settings:"lnum" 1,"tnum" 1}.number-display.has-value{background:#fff;color:var(--ink);border-color:#8ed4cf}.number-pad{width:min(440px,100%);margin:0 auto;display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.number-pad button{min-height:48px;border:1px solid #cdd8dd;border-radius:11px;background:#fff;color:var(--ink);font:700 22px/1 Arial,Helvetica,sans-serif;font-variant-numeric:lining-nums tabular-nums;font-feature-settings:"lnum" 1,"tnum" 1;box-shadow:0 3px 0 #d7dfe2;cursor:pointer}.number-pad button:active{transform:translateY(2px);box-shadow:0 1px 0 #d7dfe2}.number-pad .number-pad-action{grid-column:span 1;font:800 12px -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--blue)}
.clock-answer{width:min(330px,100%);margin:8px auto 10px;color:var(--ink);font:800 29px/1.15 Arial,Helvetica,sans-serif;letter-spacing:.04em;text-align:center;font-variant-numeric:tabular-nums}.clock-picker{display:grid;justify-items:center;gap:9px;margin:0 auto;color:#71828d;text-align:center}.clock-face{width:min(280px,78vw);height:auto;overflow:visible;touch-action:none;user-select:none}.clock-face.dragging{cursor:grabbing}.clock-rim{fill:#fbfdfd;stroke:#94d8d3;stroke-width:5;filter:drop-shadow(0 5px 0 rgba(15,78,92,.12))}.clock-number{fill:var(--ink);font:700 19px Arial,Helvetica,sans-serif;text-anchor:middle;dominant-baseline:middle;pointer-events:none}.clock-minute-number{fill:#5d8589;font:700 10px Arial,Helvetica,sans-serif;text-anchor:middle;dominant-baseline:middle;pointer-events:none}.clock-tick{stroke:#9eb5ba;stroke-width:3;stroke-linecap:round;pointer-events:none}.clock-hand{stroke-linecap:round;pointer-events:none}.hour-hand{stroke:#123946;stroke-width:12}.minute-hand{stroke:#078b93;stroke-width:8}.clock-handle{stroke:#fff;stroke-width:4;cursor:grab}.hour-handle{fill:#123946}.minute-handle{fill:#0babb0}.clock-center{fill:#ffd25a;stroke:#fff;stroke-width:4;pointer-events:none}.clock-period{display:flex;gap:8px}.clock-period button{min-width:126px;min-height:43px;padding:8px 16px;border:1px solid #b8cbd0;border-radius:12px;background:#fff;color:#617782;font:800 16px/1 Arial,Helvetica,sans-serif;box-shadow:0 3px 0 #d7dfe2;cursor:pointer}.clock-period button.active{border-color:#0a9ba0;background:#dff7f4;color:#087d84;box-shadow:0 3px 0 #91d8d2}.clock-picker p{max-width:360px;margin:0;font:600 13px/1.35 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
@media(max-width:850px){.number-prompt{font-size:23px}.number-display{min-height:54px;margin-bottom:10px;padding:8px 14px;font-size:28px}.number-pad{gap:6px;width:min(360px,100%)}.number-pad button{min-height:38px;font-size:19px}.number-submit{margin-top:12px;padding:11px 24px}.number-card + .action-bar{height:64px;min-height:64px}}
.sound-mini,.phrase-copy>button{width:35px;min-width:35px;max-width:35px;flex:0 0 35px}
.phrase-actions .audio-action{width:34px;min-width:34px;max-width:34px;flex:0 0 34px}
.hint-phrase>button{width:52px;min-width:52px;max-width:52px;flex:0 0 52px}
.word-breakdown button{width:32px;min-width:32px;max-width:32px;flex:0 0 32px}
@media(max-width:850px){.speaker{width:38px;min-width:38px;max-width:38px;flex-basis:38px}.listen-orb span{width:58px;min-width:58px;max-width:58px;flex-basis:58px}}
@media(max-width:850px) and (max-height:690px){.listen-orb span{width:48px;min-width:48px;max-width:48px;flex-basis:48px}}

.drop-cursor{display:block;width:4px;min-width:4px;height:40px;margin:0 -3px;align-self:center;border-radius:4px;background:var(--coral);box-shadow:0 0 0 4px rgba(237,106,90,.18);pointer-events:none;position:relative;z-index:4;animation:dropPulse .55s ease-in-out infinite alternate}
@keyframes dropPulse{from{opacity:.55;transform:scaleY(.82)}to{opacity:1;transform:scaleY(1)}}

/* Start action: a stable square with softly rounded corners. */
.start-orb{aspect-ratio:1;border-radius:24px}

/* Keep the lesson controls inside Safari's actual viewport. */
body.lesson-active{overflow:hidden;overscroll-behavior:none}
body.lesson-active .app-shell,body.lesson-active .workspace{height:100vh;height:100dvh;min-height:0;overflow:hidden}
.lesson-wrap{height:calc(100vh - 76px);height:calc(100dvh - 76px);min-height:0}
.lesson-wrap .exercise-card{display:flex;flex:1;flex-direction:column;min-height:0;overflow:auto}
.lesson-wrap .action-bar{flex:none}

/* Learning-time statistics and reset controls. */
.stats-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:20px}
.stats-heading h1{font:700 40px/1.05 Georgia;margin:13px 0 0}
.clear-stats{border:1px solid #e0b4af;background:#fff7f5;color:#bd554b;border-radius:10px;padding:11px 15px;font-size:12px;font-weight:800;cursor:pointer}
.time-stats{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:0 0 18px}
.time-stats article{background:white;border:1px solid var(--line);border-radius:18px;padding:22px 25px;display:flex;align-items:center;gap:17px}
.time-stats article>span{width:46px;height:46px;flex:0 0 46px;display:grid;place-items:center;border-radius:13px;background:#eef0ff;color:var(--blue);font-size:23px;font-weight:800}
.time-stats article>div{display:flex;flex-direction:column;gap:4px}.time-stats small{font-size:9px;color:#8d95a5;font-weight:900;letter-spacing:1px}.time-stats b{font:700 25px Georgia}.time-stats p{margin:0;color:#8d95a5;font-size:10px}
.topic-time-section{margin:26px 0}.topic-time-section h2{font:700 27px Georgia;margin:7px 0 14px;color:var(--navy)}.topic-time-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.topic-time-grid article{background:#fff;border:1px solid var(--line);border-radius:17px;padding:19px;display:flex;flex-direction:column;gap:4px}.topic-time-grid small{font-size:10px;font-weight:900;letter-spacing:1px;color:var(--blue);text-transform:uppercase}.topic-time-grid b{font:700 29px Georgia;color:var(--navy);margin-top:4px}.topic-time-grid span{font-size:10px;color:#8b95a5}.topic-time-grid p{min-height:28px;margin:8px 0 0;font-size:11px;line-height:1.35;color:#647284}
.topic-average-accuracy{margin-top:4px;font-size:12px;color:#178b8b}
.clear-stats-card{width:min(520px,100%);background:#fff;border-radius:22px;padding:30px;box-shadow:0 28px 90px rgba(18,25,52,.3)}
.clear-stats-card>small{font-size:9px;letter-spacing:1.4px;font-weight:900;color:var(--coral)}
.clear-stats-card h2{font:700 26px Georgia;margin:8px 0 10px}.clear-stats-card p{font-size:14px;line-height:1.55;color:#667087;margin:0 0 22px}
.clear-stats-actions{display:flex;flex-direction:column;gap:9px}.clear-stats-actions button{width:100%;border-radius:10px;padding:13px 16px;font-weight:800;cursor:pointer}
.danger-action{border:1px solid #e0b4af;background:#fff1ef;color:#b94239}

@media(max-width:850px){
  .lesson-wrap{height:100vh;height:100dvh}
  .lesson-wrap .exercise-card{overflow:hidden}
}
@media(max-width:560px){
  .stats-heading{align-items:flex-start;flex-direction:column}.clear-stats{width:100%}
  .time-stats,.topic-time-grid{grid-template-columns:1fr}.clear-stats-card{padding:24px}
  .course-selector-trigger{display:none!important}
}

/* Simplified home actions. */
.start-button{border:0;border-radius:12px;background:var(--yellow);color:#2d3350;box-shadow:0 5px 0 #d9a62f;padding:15px 23px;display:flex;align-items:center;justify-content:center;gap:10px;font-weight:800;cursor:pointer;z-index:1}
.start-button span{font-size:14px}.start-button b{font-size:13px}
.course-strip{margin-top:23px}
.course-strip .course-start{border:0;border-radius:10px;background:var(--blue);color:white;padding:12px 17px;box-shadow:0 4px 0 var(--blue-dark);font-weight:800}

/* Reading exercise with progressive word recognition. */
.morphology-table{width:100%;border-collapse:collapse;background:white;margin:20px 0}.morphology-table th,.morphology-table td{padding:10px;text-align:left;border-bottom:1px solid var(--line)}
.lesson-wrap .morphology-card{overflow:hidden;padding-top:12px;padding-bottom:8px}.morphology-card h1{font-size:22px;margin:8px 0}.morphology-card .match-note{margin:0 0 6px}.morphology-card .matching{flex:1;min-height:0;margin:4px auto;max-height:520px;gap:8px}.morphology-card .matching>div{display:grid;grid-auto-rows:minmax(0,1fr);min-height:0;gap:5px}.morphology-card .matching button{height:100%;min-height:0;line-height:1.05;font-size:clamp(10px,2vw,17px);overflow-wrap:anywhere;hyphens:auto;padding:3px 6px}.morphology-card .hint-toggle{flex:none;margin:5px auto}.morphology-card .eyebrow{display:none}
.reading-phrase{max-width:780px;margin:22px auto 25px;display:flex;justify-content:center;flex-wrap:wrap;gap:8px;font:700 29px/1.35 Georgia,"Times New Roman",serif}
.reading-phrase span{padding:5px 7px;border-radius:8px;transition:background .2s,color .2s}
.reading-phrase span.recognized{background:#dff5e7;color:#16834a;box-shadow:inset 0 0 0 1px #b9e6c9}
.reading-state{margin:0 auto 18px;display:flex;align-items:center;justify-content:center;gap:9px;color:#8d95a5;font-size:12px}
.reading-state>span{color:#a9afba}.reading-state.is-listening>span{color:#ec5e52;animation:micPulse .8s ease-in-out infinite alternate}.reading-state.is-listening b{color:#3f4961}
.reading-note{margin:-9px auto 12px;text-align:center;color:#8993a5;font-size:11px;font-weight:650}
.reading-controls{display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap;margin:4px auto 4px}
.reading-transcript{margin:10px auto 0;max-width:680px;text-align:center;font-size:14px;color:var(--blue)}.reading-transcript summary{cursor:pointer}.reading-transcript p{margin:6px 0;overflow-wrap:anywhere;font-family:Georgia,"Times New Roman",serif}.reading-transcript small{display:block;margin:7px auto 0;max-width:480px;font-size:10px;line-height:1.35;color:#7d8b9f}.reading-transcript .recognized-summary{color:#188b50}
.reading-start{margin:0 auto;border:1px solid #cfd4e2;background:#fff;color:var(--blue);border-radius:11px;padding:12px 17px;font-size:12px;font-weight:800;cursor:pointer}
.reading-replay{display:flex;align-items:center;justify-content:center;gap:7px;margin:0;border:1px solid #95d9d6;background:#effbfa;color:#087d84;border-radius:11px;padding:12px 16px;font-size:12px;font-weight:800;cursor:pointer}.reading-replay span{font-size:16px;line-height:1}.reading-replay:disabled{cursor:wait;opacity:.65}
.temporary-disable{display:block;margin:13px auto 0;border:0;background:none;color:#8a6470;font-size:11px;font-weight:800;text-decoration:underline;text-underline-offset:3px;cursor:pointer;padding:6px 10px}
.reading-footer{margin-left:auto;color:#778095;font-size:12px;font-weight:700}
@keyframes micPulse{from{opacity:.35}to{opacity:1}}

/* Listening result waits for an explicit acknowledgement. */
.listening-result-card{width:min(600px,100%);background:white;border-radius:22px;padding:32px;text-align:center;box-shadow:0 28px 90px rgba(18,25,52,.3)}
.result-mark{width:54px;height:54px;margin:0 auto 14px;border-radius:50%;display:grid;place-items:center;background:#dff5e7;color:#18884c;font-size:26px;font-weight:900}
.listening-result-card .result-title{font:800 14px/1.25 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;letter-spacing:1.6px;text-transform:uppercase;color:var(--blue);margin:15px 0 18px}
.listening-result-card .result-phrase{font:700 28px/1.4 Georgia,"Times New Roman",serif;color:var(--navy);margin:0 0 13px}
.listening-result-card .result-translation{font:600 18px/1.45 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#53656e;background:#eef7f4;border-radius:12px;padding:14px 18px;margin:0 0 25px}
.listening-result-card button{border:0;border-radius:11px;background:var(--blue);color:white;padding:14px 20px;box-shadow:0 4px 0 var(--blue-dark);font-weight:800;cursor:pointer}
.temporary-disable-card{width:min(520px,100%);background:white;border-radius:22px;padding:31px;text-align:center;box-shadow:0 28px 90px rgba(18,25,52,.3)}
.temporary-disable-card>span{width:58px;height:58px;margin:0 auto 14px;border-radius:15px;background:#fff0ee;color:#d6574c;display:grid;place-items:center;font:700 24px Georgia;box-shadow:inset 0 0 0 1px #f2c4bf}.temporary-disable-card small{font-size:9px;letter-spacing:1.2px;color:#d6574c;font-weight:900}.temporary-disable-card h2{font-size:25px;margin:8px 0 10px}.temporary-disable-card p{font-size:14px;line-height:1.55;color:#667087;margin:0 0 23px}.temporary-disable-card button{border:0;border-radius:11px;background:var(--blue);color:white;padding:13px 24px;box-shadow:0 4px 0 var(--blue-dark);font-weight:800;cursor:pointer}

@media(max-width:560px){
  .page-heading{min-height:285px}.start-button{align-self:flex-start}
  .reading-phrase{font-size:21px;margin:10px auto 13px;gap:4px}.reading-phrase span{padding:3px 5px}
  .reading-state{margin-bottom:10px}.reading-note{margin:-4px auto 9px;font-size:10px}.reading-controls{gap:7px}.reading-start,.reading-replay{padding:10px 12px;font-size:11px}.listening-result-card{padding:24px 18px}.listening-result-card .result-title{font-size:13px}.listening-result-card .result-phrase{font-size:23px}.listening-result-card .result-translation{font-size:17px}
}

/* Akoema identity: Aegean ink, clear speech, bright progress. */
.sidebar{background:var(--navy);border-right:0;padding:25px 18px 18px;box-shadow:14px 0 40px rgba(9,41,52,.08)}
.brand{width:100%;height:62px;padding:0 8px 20px;justify-content:flex-start}
.brand img{display:block;width:182px;max-width:100%;height:auto;overflow:visible}
.sidebar nav{gap:6px}
.sidebar nav button{color:#b8d0d1;border-radius:13px;padding:13px 14px;font-size:14px;transition:background .16s,color .16s,transform .16s}
.sidebar nav button:hover{background:rgba(255,255,255,.07);color:#fff;transform:translateX(2px)}
.sidebar nav .nav-active{background:#f4fbf8;color:var(--navy);box-shadow:0 6px 20px rgba(0,0,0,.12)}
.sidebar nav button span{color:var(--aqua)}
.sidebar nav .nav-active span{color:var(--blue)}
.course-card{border-top:1px solid rgba(255,255,255,.13);color:#f5fbf9}
.course-card small{color:#83aaad}.course-card .flag{background:var(--yellow);color:var(--navy)}
.workspace{background:radial-gradient(circle at 94% 7%,rgba(53,198,186,.13),transparent 24rem),linear-gradient(180deg,#f8fcfa 0,var(--cream) 31rem)}
.topbar{background:rgba(255,255,255,.88);border-color:rgba(13,91,97,.12);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.avatar{background:var(--navy);color:white;box-shadow:0 0 0 3px rgba(53,198,186,.18)}
.page-heading{min-height:300px;background:radial-gradient(circle at 78% 40%,rgba(53,198,186,.23),transparent 11rem),linear-gradient(135deg,#0b3340,#0c4751);border-radius:30px;padding:47px 52px;box-shadow:0 20px 55px rgba(11,51,64,.16)}
.page-heading:before{content:"";position:absolute;right:-28px;bottom:34px;width:48%;height:54px;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 500 70'%3E%3Cpath d='M0 35c42-35 83-35 125 0s83 35 125 0 83-35 125 0 83 35 125 0' fill='none' stroke='%2335c6ba' stroke-width='6' stroke-linecap='round' opacity='.48'/%3E%3C/svg%3E") center/contain no-repeat}
.page-heading:after{content:"A";right:17%;top:-77px;color:rgba(255,255,255,.035);font-size:340px;transform:none}
.page-heading h1{font-size:46px;letter-spacing:-.025em;line-height:1.04;position:relative;z-index:1}
.page-heading p{font-size:16px;color:#c1d7d6;margin:15px 0 0;position:relative;z-index:1}
.kicker{color:#69dbd0}
.start-button{min-width:160px;border-radius:15px;background:var(--yellow);color:var(--navy);box-shadow:0 6px 0 #c79e38;padding:17px 23px;transition:transform .15s,box-shadow .15s}
.start-button:hover{transform:translateY(-2px);box-shadow:0 8px 0 #c79e38}.start-button:active{transform:translateY(4px);box-shadow:0 2px 0 #c79e38}
.lesson-starts{display:flex;align-items:center;gap:12px;position:relative;z-index:1}.overall-mastery{display:flex;flex-direction:column;gap:2px;border-left:1px solid rgba(255,255,255,.3);padding-left:12px;color:#fff}.overall-mastery small{font-size:8px;letter-spacing:1px;font-weight:900;color:#c8d1e6}.overall-mastery b{font:700 22px Georgia}.topic-strip{margin-top:14px}.topic-accuracy{display:flex;flex-direction:column;align-items:center;gap:3px;min-width:150px;text-align:center}.topic-accuracy b{font:700 22px Georgia;color:#178b8b}.topic-accuracy small{font-size:9px!important;line-height:1.2;color:#788992!important;letter-spacing:0!important;text-transform:none}.microphone-start{display:flex;align-items:center;justify-content:center;gap:8px;margin:12px auto 8px}.microphone-start span{font-size:20px;line-height:1}
.course-strip,.word-catalog article,.phrase-list article,.stats-grid article,.time-stats article{border-color:var(--line);box-shadow:0 8px 28px rgba(14,60,68,.045)}
.course-strip{border-radius:18px;margin-top:22px}.course-strip .course-start{background:var(--blue);box-shadow:0 4px 0 var(--blue-dark)}
.mini-progress span,.accuracy-track span,.progress-track div{background:linear-gradient(90deg,var(--aqua),#72dcc4)}
.exercise-card{border-color:var(--line);border-radius:24px;box-shadow:0 15px 45px rgba(12,55,63,.07)}
.speaker,.listen-orb span{background:var(--blue);box-shadow:0 4px 0 var(--blue-dark)}
.word-chip:hover{border-color:var(--aqua)}.word-chip.selected{border-color:#62cfc7;background:#eafaf6;color:#075b61}
.check,.consent-primary,.hint-screen>footer button,.listening-result-card button,.temporary-disable-card button{background:var(--blue);box-shadow:0 4px 0 var(--blue-dark)}
.choices button.choice-picked,.matching button.match-picked{background:#e8faf6;border-color:#65cec5;color:#075b61}
.hint-screen{background:var(--cream)}.hint-phrase,.accuracy-card{background:var(--navy)}
.consent-mark{padding:0;background:none;box-shadow:none}.consent-mark img{display:block;width:52px;height:52px}
.mobile-brand{padding:0;background:none;box-shadow:none}.mobile-brand img{display:block;width:38px;height:38px}
button:focus-visible,input:focus-visible{outline:3px solid rgba(53,198,186,.48);outline-offset:3px}

/* The action always occupies the same visual anchor. Status copy may change,
   but it must never push «Проверить» / «Исправить» / «Далее» sideways. */
.action-bar{position:relative;justify-content:center}
.action-bar .check{width:280px;min-width:280px;min-height:56px;margin-left:0;display:inline-grid;place-items:center}
.action-bar .feedback{position:absolute;left:62px;max-width:calc(50% - 190px)}
.action-bar:not(.correct):not(.wrong):not(.skipped) .feedback{left:8px}
.action-bar .auto-next{margin-left:0}
.hint-screen>footer button:not(.report-trigger){width:280px;min-height:56px;display:inline-grid;place-items:center}

@media(max-width:520px){
  .action-bar .check{width:min(280px,100%);min-width:0}
  .hint-screen>footer button:not(.report-trigger){width:min(280px,100%);min-height:48px}
}

@media(max-width:850px){
  .sidebar{display:flex;position:fixed;inset:auto 0 0;width:100%;height:72px;padding:7px max(8px,env(safe-area-inset-right)) calc(7px + env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left));z-index:18;border-radius:20px 20px 0 0;box-shadow:0 -10px 35px rgba(8,45,55,.17)}
  .sidebar .brand,.sidebar .course-card{display:none}.sidebar nav{width:100%;display:grid;grid-template-columns:repeat(4,1fr);gap:5px}
  .sidebar nav button{min-width:0;padding:7px 4px;justify-content:center;flex-direction:column;gap:2px;text-align:center;font-size:11px;border-radius:11px}
  .sidebar nav button:hover{transform:none}.sidebar nav button span{font-size:18px;line-height:1;width:auto}
  .workspace{padding-bottom:72px}.topbar{height:64px;padding:0 16px}.page-content{padding:24px 17px 34px}
  .page-heading{min-height:300px;padding:32px 27px;border-radius:24px}.page-heading h1{font-size:38px}.page-heading p{font-size:15px;max-width:19rem}
  .page-heading:before{width:70%;bottom:23px}.page-heading:after{right:-10px;top:-38px;font-size:260px}
  body.lesson-active .sidebar{display:none}body.lesson-active .workspace{padding-bottom:0}
}
@media(max-width:560px){.page-heading{min-height:330px}.page-heading h1{font-size:34px}.page-heading .start-button{align-self:flex-start;margin-top:auto}.lesson-starts{width:100%;justify-content:space-between;align-items:flex-end}.topic-accuracy{display:flex;align-items:flex-start;min-width:0;text-align:left}.topic-accuracy b{font-size:20px}.catalog-heading input{font-size:16px}}

/* Lessons: compact desktop composition without a nested or page scrollbar. */
.lesson-wrap .exercise-card{overflow:hidden}
.lesson-wrap .exercise-card h1{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:clamp(17px,1.45vw,21px);font-weight:800;line-height:1.2;letter-spacing:.025em;color:#667b86;margin:14px 0 16px}
.lesson-wrap .prompt,.lesson-wrap .big-word,.lesson-wrap .reading-phrase{font-family:Georgia,"Times New Roman",serif;color:#0b4350}
.lesson-wrap .prompt{font-size:clamp(24px,2.35vw,34px)}
.lesson-wrap .prompt-static{color:#126b72}
.lesson-wrap .big-word{color:#0b4350}
.lesson-wrap .hint-toggle{position:relative;z-index:2;flex:none;color:var(--blue);line-height:1.2}

@media(min-width:851px){
  .lesson-wrap{height:calc(100vh - 76px);height:calc(100dvh - 76px);padding:18px 40px 0}
  .lesson-head{height:38px;min-height:38px;flex:none}
  .lesson-wrap .exercise-card{min-height:0;margin-top:14px;padding:18px 42px 12px}
  .lesson-wrap .action-bar{height:82px;min-height:82px;padding:12px 8px}
  .lesson-wrap .eyebrow{font-size:9px}
  .lesson-wrap .listen-orb{margin:7px auto 13px;gap:8px}
  .lesson-wrap .listen-orb span{width:64px;min-width:64px;max-width:64px;height:64px;flex-basis:64px;border-radius:14px;font-size:23px}
  .lesson-wrap .temporary-disable{margin:2px auto 5px;padding:4px 10px}
  .lesson-wrap .answer-zone{min-height:72px;padding:9px 7px;gap:7px}
  .lesson-wrap .word-bank{min-height:58px;padding:12px 5px 2px;gap:8px;align-content:flex-start}
  .lesson-wrap .word-chip{padding:8px 12px;font-size:14px}
  .lesson-wrap .hint-toggle{margin:6px auto 0;padding:5px 8px}
}

@media(min-width:851px) and (max-height:700px){
  .topbar{height:60px}
  .lesson-wrap{height:calc(100vh - 60px);height:calc(100dvh - 60px);padding:8px 28px 0}
  .lesson-head{height:28px;min-height:28px;gap:14px}
  .lesson-head .close{font-size:24px;line-height:1}.lesson-head .progress-track{height:7px}
  .lesson-wrap .exercise-card{margin-top:8px;padding:10px 30px 7px;border-radius:19px}
  .lesson-wrap .eyebrow{display:none}
  .lesson-wrap .exercise-card h1{font-size:16px;margin:2px 0 6px}
  .lesson-wrap .listen-orb{flex-direction:row;margin:1px auto 5px;gap:10px}
  .lesson-wrap .listen-orb span{width:45px;min-width:45px;max-width:45px;height:45px;flex-basis:45px;border-radius:11px;font-size:18px;box-shadow:0 3px 0 var(--blue-dark)}
  .lesson-wrap .listen-orb b{font-size:9px}
  .lesson-wrap .temporary-disable{margin:0 auto 3px;padding:3px 8px;font-size:10px}
  .lesson-wrap .prompt{font-size:23px;margin:1px auto 8px;gap:11px}
  .lesson-wrap .big-word{font-size:26px;margin:0 auto 9px}
  .lesson-wrap .answer-zone{min-height:55px;padding:6px;gap:6px}
  .lesson-wrap .word-bank{min-height:47px;padding:7px 4px 1px;gap:6px}
  .lesson-wrap .word-chip{padding:6px 10px;font-size:13px;box-shadow:0 2px 0 #d5d9e1}
  .lesson-wrap .hint-toggle{margin:2px auto 0;padding:4px 7px;font-size:11px}
  .lesson-wrap .action-bar{height:56px;min-height:56px;padding:6px 8px}
  .lesson-wrap .check{padding:11px 20px;box-shadow:0 4px 0 var(--blue-dark)}
  .lesson-wrap .matching{margin:2px auto;max-height:245px}
  .lesson-wrap .choices{gap:7px}.lesson-wrap .choices button{padding:9px}
}

/* The calculator is intentionally compact: its own submit action never falls
   behind the fixed lesson edge on short desktop or mobile viewports. */
.lesson-wrap .number-card{justify-content:center;overflow:hidden;padding-top:10px;padding-bottom:8px}
.lesson-wrap .number-card{flex:1 1 0}
.lesson-wrap .number-card + .action-bar{display:flex!important;flex:0 0 82px;min-height:82px}
.lesson-wrap .number-card h1{margin:2px 0 8px}
.lesson-wrap .number-card .number-prompt{margin:0 auto 9px;font-size:clamp(20px,2vw,29px);line-height:1.2}
.lesson-wrap .number-card .number-display{min-height:52px;margin-bottom:8px;padding:7px 14px;font-size:27px}
.lesson-wrap .number-card .number-pad{gap:6px}
.lesson-wrap .number-card .number-pad button{min-height:clamp(36px,4.3vh,43px);font-size:20px}
.lesson-wrap .number-card .number-submit{margin:10px auto 0;padding:11px 26px}
.lesson-wrap .number-card .hint-toggle{margin:5px auto 0;padding:4px 8px}
.number-pad button.number-pad-action:nth-last-child(2){font-size:27px;line-height:1;color:var(--blue)}
.number-words-card{justify-content:center}.number-words-card>h1,.number-words-card>.prompt-static{display:none}.number-words-prompt{text-align:center;margin:0 0 14px}.number-words-prompt h1{margin:0 0 10px!important}.number-words-prompt b{display:block;font:700 clamp(38px,5vw,62px)/1 Arial,Helvetica,sans-serif;letter-spacing:.04em;font-variant-numeric:lining-nums tabular-nums;color:var(--blue)}.number-words-prompt p{margin:9px 0 0;font-size:13px;color:#84909d}.number-words-card .answer-zone{min-height:74px}.number-words-card .word-bank{max-width:820px}
.hidden-greek-card .phrase-prompt-text{filter:blur(9px);user-select:none}.hidden-greek-card .prompt{cursor:default}
@media(max-width:560px){.lesson-wrap .number-card + .action-bar{flex-basis:64px;min-height:64px}.lesson-wrap .number-card .number-prompt{font-size:20px}.lesson-wrap .number-card .number-pad button{min-height:35px}.lesson-wrap .number-card .number-submit{padding:10px 22px}}

@keyframes match-wrong-flash{0%,100%{background:#fff;color:#12303b;border-color:#d6dae3;transform:translateX(0)}15%,45%,75%{background:#e95d52;color:#fff;border-color:#bf3931;box-shadow:0 0 0 4px rgba(233,93,82,.2),0 3px 0 #c63f36;transform:translateX(-3px)}30%,60%,90%{background:#fff0ee;color:#a9342d;border-color:#df655b;box-shadow:0 0 0 3px rgba(233,93,82,.12),0 2px 0 #e3aaa4;transform:translateX(3px)}}
.matching button.match-wrong{animation:match-wrong-flash .9s ease-in-out both}
.choices button.choice-wrong{animation:match-wrong-flash .9s ease-in-out both}
@media (prefers-reduced-motion:reduce){.matching button.match-wrong{animation:none;background:#fff1ef;border-color:#ef8f85;color:#bf493f;box-shadow:0 0 0 3px rgba(233,93,82,.16)}}

.pronunciation-card{display:flex;flex-direction:column;align-items:center}.pronunciation-card h1{margin-bottom:26px}.pronunciation-word{margin:0 auto 32px;flex-wrap:wrap;justify-content:center}.pronunciation-word b{font-size:clamp(37px,7vw,66px);line-height:1.08}.pronunciation-word::after{content:attr(data-translation);flex-basis:100%;margin-top:7px;text-align:center;font:600 16px/1.2 system-ui,sans-serif;color:#748391}.pronunciation-choices{width:min(100%,720px)}.pronunciation-choices button{min-height:64px;justify-content:center;font:700 min(clamp(16px,3.5vw,31px),calc(420px / var(--choice-length)))/1.1 Georgia,"Times New Roman",serif;letter-spacing:.02em}.pronunciation-choices button span{display:none}.pronunciation-card .hint-toggle{margin-top:18px}.pronunciation-hint{z-index:51}.pronunciation-hint main{max-width:900px}.pronunciation-rule{border:1px solid #d7e5e5;border-radius:18px;background:#f3faf9;padding:20px 22px;margin-bottom:24px}.pronunciation-rule small{color:#07858b;font-weight:900;letter-spacing:1px}.pronunciation-rule h2{margin:8px 0;font-size:27px}.pronunciation-rule p,.pronunciation-source{line-height:1.55;color:#29434d}.pronunciation-rule blockquote{margin:14px 0 0;border-left:4px solid #e35d51;padding:9px 14px;background:#fff;color:#8f332d;font-weight:700}.pronunciation-hint h3{margin:23px 0 10px;color:#0a6770}.pronunciation-table-wrap{overflow:hidden;border:1px solid #d8e3e5;border-radius:14px}.pronunciation-table{border-collapse:collapse;width:100%;table-layout:fixed}.pronunciation-table th{background:#0c858c;color:#fff;text-align:left;padding:12px}.pronunciation-table td{padding:12px;border-top:1px solid #d9e4e5;vertical-align:top;line-height:1.4;overflow-wrap:anywhere;word-break:break-word}.pronunciation-table th:first-child,.pronunciation-table td:first-child{width:17%}.pronunciation-table th:nth-child(2),.pronunciation-table td:nth-child(2){width:48%}.pronunciation-table td:first-child{font:700 23px Georgia,"Times New Roman",serif;text-align:center}.pronunciation-active{background:#fff3f1}.pronunciation-pattern-active{color:#c9372c;text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:3px}.pronunciation-source{margin:9px 0;padding:10px 13px;background:#f7f9f8;border-radius:9px}
.dictation-card .dictation-listen{margin:0 0 25px}.dictation-mask{margin:0 0 8px;font:700 clamp(42px,8vw,76px)/1.1 Georgia,"Times New Roman",serif;letter-spacing:.07em;color:#123d49}.dictation-mask::first-letter{letter-spacing:normal}.dictation-translation{margin:0 0 16px;color:#4f7a72;font:700 clamp(18px,2.6vw,25px)/1.2 system-ui,sans-serif}.dictation-instruction{margin:0 0 20px;color:#718292;font-weight:700}.dictation-choices button{font-family:Georgia,"Times New Roman",serif}.dictation-wrong-rule{border-color:#f0b2ad;background:#fff5f4}.dictation-wrong-rule small{color:#b84239}
.pronunciation-word.proper-name:not(.translation-revealed)::after{filter:blur(7px);user-select:none;opacity:.78}.pronunciation-word.proper-name::after{transition:filter .22s ease,opacity .22s ease}

.pronunciation-hint-word{display:flex;align-items:center;gap:14px;margin:0 0 20px;padding:14px 0 18px;border-bottom:1px solid #d6e4e3}
.pronunciation-hint-word .speaker{border:0;flex:none;cursor:pointer}
.pronunciation-hint-word div{display:flex;flex-direction:column;gap:4px;min-width:0}
.pronunciation-hint-word b{font:700 clamp(27px,5vw,40px)/1.05 Georgia,"Times New Roman",serif;color:#0b3e49;overflow-wrap:anywhere}
.pronunciation-hint-word span{font:600 16px/1.25 system-ui,sans-serif;color:#748391}
.gender-card .pronunciation-word small{flex-basis:100%;margin-top:8px;font:600 18px/1.25 system-ui,sans-serif;color:#748391}
.lesson-wrap.pronunciation-lesson{height:auto;min-height:calc(100dvh - 76px);overflow:visible;padding-bottom:28px}
.gender-speech-controls{width:min(720px,calc(100% - 32px));margin:12px auto 18px;justify-content:center;position:relative;z-index:2}.gender-speech-controls .temporary-disable{margin:0}
.gender-speech-transcript{width:min(720px,calc(100% - 32px));margin:0 auto 36px;position:relative;z-index:2}.gender-speech-transcript .reading-transcript{margin-top:0}
.alpha-speech-transcript{position:fixed;z-index:8;left:50%;bottom:16px;width:min(680px,calc(100% - 32px));margin:0;transform:translateX(-50%);padding:10px 14px;border:1px solid #d8e3e5;border-radius:12px;background:#fff;box-shadow:0 8px 22px rgba(19,55,65,.14)}
.hidden-greek-card .reading-phrase{font-size:0!important;min-height:72px;display:flex;align-items:center;justify-content:center}.hidden-greek-card .reading-phrase>*{display:none}.hidden-greek-card .reading-phrase::after{content:"Слушайте фразу";font:700 clamp(28px,5vw,48px)/1.1 Georgia,"Times New Roman",serif;color:#0b4350}
.gender-rule-table{margin:0 0 20px;border:1px solid #d8e3e5;border-radius:14px;overflow:hidden}
.gender-rule-table th:first-child,.gender-rule-table td:first-child{width:auto;text-align:left;font:700 16px/1.35 system-ui,sans-serif}
.gender-rule-table th:nth-child(2),.gender-rule-table td:nth-child(2){width:auto}

.pronunciation-table th{white-space:normal;overflow-wrap:anywhere;word-break:normal;text-wrap:balance;line-height:1.25}

/* A family member is one lexical item: never split its spelling between
   lines. Russian definitions may wrap, but only at their ordinary spaces. */
.word-family-table td{overflow-wrap:normal;word-break:normal;hyphens:none}
.word-family-table td:first-child{width:34%;font-size:clamp(16px,4.1vw,20px);white-space:nowrap;letter-spacing:0}
.word-family-table td:nth-child(2){width:66%;font-size:clamp(15px,3.5vw,18px);line-height:1.3}
.word-family-table td:first-child button{max-width:100%;padding:0;border:0;background:none;color:inherit;font:inherit;white-space:nowrap;cursor:pointer}

/* Family entries are examples themselves: present them as natural word pairs,
   not as a cramped two-column grammar table. */
.word-family-table,.word-family-table tbody{display:block;width:100%}
.word-family-table tr{display:flex;align-items:baseline;padding:15px 18px;border-top:1px solid #d9e4e5}
.word-family-table tr:first-child{border-top:0}
.word-family-table td,.word-family-table td:first-child,.word-family-table td:nth-child(2){display:block;width:auto;padding:0;border:0}
.word-family-table td:first-child{flex:none;white-space:nowrap}
.word-family-table td:first-child::after{content:" — ";white-space:pre}
.word-family-table td:nth-child(2){min-width:0;flex:1}
/* The forms above already supply the examples, so do not repeat three cards. */
.word-family-table + h3,.word-family-table + h3 + .pronunciation-source,.word-family-table + h3 + .pronunciation-source + .pronunciation-source,.word-family-table + h3 + .pronunciation-source + .pronunciation-source + .pronunciation-source{display:none}

/* Word choice always presents six concise alternatives in three rows. */
.lesson-wrap .choices{grid-template-columns:repeat(2,minmax(0,1fr));max-width:640px;gap:10px}
.lesson-wrap .choices button{min-height:54px;padding:12px 14px}
@media(max-width:520px){.lesson-wrap .choices{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.lesson-wrap .choices button{min-height:48px;padding:9px 8px;font-size:13px}.lesson-wrap .choices button span{width:22px;height:22px;margin-right:7px}}

.hint-phrase{position:relative;padding-right:32px}.hint-phrase-content{min-width:0;flex:1}.hint-phrase-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:7px}.hint-phrase-heading h2{margin:0}.hint-phrase-actions{display:flex;gap:6px;flex:none}.translate-check,.hint-report-trigger{display:inline-flex;align-items:center;border:1px solid #ffffff40;border-radius:6px;padding:4px 6px;font:600 9px/1.2 system-ui,sans-serif;color:#fff;text-decoration:none;background:transparent;cursor:pointer}.translate-check:hover,.hint-report-trigger:hover{background:#ffffff18}.translate-check:focus-visible,.hint-report-trigger:focus-visible{outline:2px solid var(--yellow);outline-offset:3px}.hint-report-trigger{white-space:nowrap}

/* A matched pair reserves a fixed left gutter for its checkmark, so labels stay centred and legible. */
.matching button{position:relative;display:grid;place-items:center;padding:5px 12px;border-width:1px;border-bottom-width:4px;background:linear-gradient(180deg,#fff 0%,#fff 72%,#f4f6f9 100%);box-shadow:inset 0 1px 0 rgba(255,255,255,.98),0 3px 0 #d7dbe3,0 7px 12px rgba(37,56,77,.07);transition:transform .14s ease,box-shadow .14s ease,background .14s ease}
.matching button:hover:not(:disabled){transform:translateY(-1px);box-shadow:inset 0 1px 0 rgba(255,255,255,.98),0 4px 0 #d7dbe3,0 9px 14px rgba(37,56,77,.1)}.matching button:active:not(:disabled){transform:translateY(3px);box-shadow:inset 0 1px 2px rgba(35,54,76,.12),0 1px 0 #d7dbe3}
.matching .match-mark{display:none!important}
.matching .match-value{display:flex;min-width:0;justify-content:center;align-items:center}
.matching button.match-picked{background:linear-gradient(180deg,#effcf8 0%,#e8faf6 100%);box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 3px 0 #8fd9d1,0 7px 12px rgba(7,91,97,.09)}.matching button:disabled{background:linear-gradient(180deg,#f1fbf5 0%,#edf8f1 100%);box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 3px 0 #b8e4c8,0 6px 11px rgba(39,147,91,.08)}.matching button.match-wrong{background:linear-gradient(180deg,#fff8f6 0%,#fff1ef 100%);border-color:#ef8f85;color:#bf493f;box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 3px 0 #edc5c0,0 6px 11px rgba(191,73,63,.08)}
.matching button.match-complete{background:linear-gradient(180deg,#f1fbf5 0%,#edf8f1 100%);color:#27935b;border-color:#b8e4c8;box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 3px 0 #b8e4c8,0 6px 11px rgba(39,147,91,.08)}
.matching button.match-wrong .match-label small{color:#bd756d}
.lesson-wrap .morphology-card .matching button{padding-left:28px;padding-right:6px}
.lesson-wrap .morphology-card .matching .match-mark{left:6px}

/* One shared matching board.  Each column receives the same available height,
 * then its answers divide that height equally instead of forming a compact
 * block at the top of the exercise. */
.lesson-wrap .exercise-card:has(.matching) .matching{flex:1;min-height:0;align-self:stretch;max-width:760px;margin:14px auto 18px}
.lesson-wrap .exercise-card:has(.matching) .matching>div{display:grid;grid-auto-rows:minmax(0,1fr);min-height:0;gap:clamp(8px,1.8vh,18px)}
.lesson-wrap .exercise-card:has(.matching) .matching button{height:100%;min-height:0;overflow-wrap:anywhere;line-height:1.12}
.lesson-wrap .exercise-card:has(.matching) .match-note{flex:none;margin:0 0 4px}
@media(max-width:850px){.lesson-wrap .exercise-card:has(.matching) .matching{margin:8px auto 10px}.lesson-wrap .exercise-card:has(.matching) .matching>div{gap:clamp(6px,1.3vh,12px)}}

/* Keep the complete bilingual answer together and balanced when there is no submitted answer to compare. */
.inline-answer .answer-comparison{width:100%;min-width:0}.inline-answer .answer-comparison-single{grid-template-columns:minmax(0,1fr);width:min(720px,100%);max-width:720px;margin-left:auto;margin-right:auto}
.answer-result .answer-translation{display:block;color:#667388;font-size:16px;line-height:1.35}
.correct-result .answer-translation{color:#41765b}

.choices button.choice-wrong{background:#fff1ef;border-color:#ef8f85;color:#bf493f;box-shadow:0 3px 0 #edc5c0}
.choices button.choice-wrong span{border-color:#efaaa2;color:#bf493f}

/* Answer labels are centred independently from their optional number badge.
   The per-button --choice-length comes from the actual label, so only a
   label that would overflow is reduced. */
.choices button{font-size:min(clamp(13px,2.2vw,22px),calc(330px / var(--choice-length,12)))}
.pronunciation-choices button{font-size:min(clamp(16px,3.5vw,31px),calc(420px / var(--choice-length,12)))}
@media(max-width:520px){
  .lesson-wrap .choices button{font-size:min(clamp(10px,3.5vw,16px),calc(185px / var(--choice-length,12)))}
  .lesson-wrap .pronunciation-choices button{font-size:min(clamp(10px,3.5vw,18px),calc(185px / var(--choice-length,12)))}
}

@media(max-width:680px){
  .lesson-wrap .inline-answer{align-self:stretch;width:100%;max-width:100%;margin:22px auto;padding:0 4px}
  .lesson-wrap .inline-answer h1{margin:0 0 14px;font-size:28px}
  .lesson-wrap .inline-answer .answer-comparison-single{max-width:100%;margin-bottom:0}
  .lesson-wrap .inline-answer .answer-result{padding:14px 16px;gap:6px}
  .lesson-wrap .inline-answer .answer-result strong{font-size:clamp(18px,6vw,24px);line-height:1.28;overflow-wrap:anywhere}
  .lesson-wrap .inline-answer .answer-translation{font-size:clamp(15px,4.6vw,18px);line-height:1.35}
}

/* Local task-report dialog */
.hint-screen>footer .report-trigger{background:white;color:var(--blue);box-shadow:none;border:1px solid var(--blue);margin-right:10px}
.task-report-modal{width:min(560px,calc(100vw - 32px));background:white;border-radius:20px;padding:26px;box-shadow:0 22px 70px #10253a55}.task-report-modal header{display:flex;align-items:flex-start;justify-content:space-between;margin-bottom:18px}.task-report-modal header small{font-size:10px;letter-spacing:1px;font-weight:900;color:var(--blue)}.task-report-modal h2{margin:4px 0 0;font-size:26px}.task-report-modal header button{border:0;background:none;color:#8e95a5;font-size:30px;line-height:1;cursor:pointer}.task-report-modal label{display:grid;gap:7px;margin:14px 0;font-size:13px;font-weight:800;color:#334157}.task-report-modal select,.task-report-modal textarea{font:inherit;font-weight:500;color:#24384b;background:#fafbf9;border:1px solid var(--line);border-radius:10px;padding:11px;resize:vertical}.task-report-modal textarea{line-height:1.45}.task-report-note{font-size:12px;line-height:1.45;color:#748094;margin:15px 0}.task-report-error{font-size:12px;color:#b64e43}.task-report-modal footer{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}.task-report-modal footer button,.task-report-result button{border:0;border-radius:10px;padding:12px 18px;background:var(--blue);color:white;font-weight:800;cursor:pointer;box-shadow:0 3px 0 var(--blue-dark)}.task-report-modal footer .report-cancel{background:white;color:#536176;box-shadow:none;border:1px solid var(--line)}.task-report-result{padding:18px 0 4px}.task-report-result b{font-size:19px}.task-report-result p{color:#657186;line-height:1.5}
@media(max-width:560px){.hint-screen>footer{padding:10px;gap:8px}.hint-screen>footer button{padding:11px 12px;font-size:12px}.hint-screen>footer .report-trigger{margin-right:0}.task-report-modal{padding:20px}.task-report-modal h2{font-size:22px}}

/* Browser device emulation matches max-width but still needs wheel/touch
   scrolling inside a lesson. Keep tiles draggable while the card itself pans. */
@media(max-width:850px){
  .lesson-wrap .exercise-card{overflow-y:auto;overflow-x:hidden;touch-action:pan-y;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
}

/* One tactile language for every primary control.  The existing colours and
   radii stay intact; only the light, edge and pressed depth are shared. */
.start-button,.check,.course-strip .course-start,.reading-replay,.choices button,.word-chip,.number-pad button,.lesson-summary-actions button,.consent-primary,.temporary-disable-card button,.task-report-modal footer button,.task-report-result button{
  background-image:linear-gradient(180deg,rgba(255,255,255,.16),rgba(255,255,255,0) 58%,rgba(0,0,0,.035));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.72),inset 0 -1px 0 rgba(0,0,0,.08),0 4px 0 rgba(22,46,62,.24),0 8px 14px rgba(22,46,62,.10);
  transition:transform .14s ease,box-shadow .14s ease,filter .14s ease;
}
.start-button:hover,.check:not(:disabled):hover,.course-strip .course-start:hover,.reading-replay:not(:disabled):hover,.choices button:not(:disabled):hover,.word-chip:not(:disabled):hover,.number-pad button:hover,.lesson-summary-actions button:hover,.consent-primary:hover,.temporary-disable-card button:hover,.task-report-modal footer button:hover,.task-report-result button:hover{transform:translateY(-1px);filter:brightness(1.015)}
.start-button:active,.check:not(:disabled):active,.course-strip .course-start:active,.reading-replay:not(:disabled):active,.choices button:not(:disabled):active,.word-chip:not(:disabled):active,.number-pad button:active,.lesson-summary-actions button:active,.consent-primary:active,.temporary-disable-card button:active,.task-report-modal footer button:active,.task-report-result button:active{transform:translateY(3px);box-shadow:inset 0 2px 3px rgba(15,38,55,.16),0 1px 0 rgba(22,46,62,.2)}
.check:disabled{box-shadow:inset 0 1px 0 rgba(255,255,255,.42),inset 0 -1px 0 rgba(0,0,0,.06),0 4px 0 rgba(22,46,62,.18)}

/* Match cards are deliberately quieter: they read as a minimal framed choice,
   not a tall raised action button. */
.matching button,.lesson-wrap .morphology-card .matching button{border-bottom-width:2px;padding-left:10px;padding-right:10px;box-shadow:inset 0 1px 0 rgba(255,255,255,.92),0 1px 0 #d7dbe3,0 3px 7px rgba(37,56,77,.045)}
.matching button:hover:not(:disabled){transform:translateY(0);box-shadow:inset 0 1px 0 rgba(255,255,255,.92),0 2px 0 #d7dbe3,0 4px 8px rgba(37,56,77,.065)}.matching button:active:not(:disabled){transform:translateY(1px);box-shadow:inset 0 1px 2px rgba(35,54,76,.1),0 1px 0 #d7dbe3}.matching button.match-picked{box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 1px 0 #8fd9d1,0 3px 7px rgba(7,91,97,.05)}.matching button:disabled{box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 1px 0 #b8e4c8,0 3px 7px rgba(39,147,91,.04)}.matching button.match-wrong{box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 1px 0 #edc5c0,0 3px 7px rgba(191,73,63,.04)}

/* Search-friendly public product page. It is server-rendered at /about/ru,
   /about/el and /about/en; the app itself remains focused on practice. */
.sidebar nav a{color:#b8d0d1;border-radius:13px;padding:13px 14px;font-size:14px;display:flex;gap:14px;align-items:center;text-decoration:none;font-weight:700;transition:background .16s,color .16s,transform .16s}.sidebar nav a:hover{background:rgba(255,255,255,.07);color:#fff;transform:translateX(2px)}.sidebar nav a span{width:22px;text-align:center;color:var(--aqua);font-size:20px}
.promo-page{min-height:100vh;background:radial-gradient(circle at 90% 0,rgba(53,198,186,.22),transparent 30rem),var(--cream);color:var(--navy);padding:0 max(24px,calc((100vw - 1180px)/2));font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}.promo-nav{height:92px;display:flex;justify-content:space-between;align-items:center}.promo-brand img{display:block;width:180px;height:auto}.promo-nav nav{display:flex;flex-direction:row;gap:6px}.promo-nav nav a{color:#527078;text-decoration:none;font-size:13px;font-weight:750;border-radius:9px;padding:9px 10px}.promo-nav nav a[aria-current="page"]{background:#dff5f1;color:#087e83}.promo-hero{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(280px,.75fr);gap:50px;align-items:center;padding:76px 0 94px}.promo-eyebrow{margin:0 0 14px;color:#07858b;font-size:11px;letter-spacing:1.8px;font-weight:900}.promo-hero h1,.promo-section h2,.promo-course h2{font:700 clamp(39px,5.1vw,68px)/1.03 Georgia,"Times New Roman",serif;letter-spacing:-.035em;margin:0;max-width:770px}.promo-lead{max-width:660px;margin:23px 0 29px;color:#526b73;font-size:18px;line-height:1.6}.promo-cta{display:inline-flex;gap:14px;align-items:center;border-radius:14px;background:var(--yellow);box-shadow:inset 0 1px 0 #fff8,0 5px 0 #c79e38,0 10px 20px rgba(114,86,19,.12);padding:16px 21px;color:var(--navy);text-decoration:none;font-size:15px;font-weight:900}.promo-cta:hover{transform:translateY(-1px);filter:brightness(1.02)}.promo-cta span{font-size:21px}.promo-phrase{background:linear-gradient(145deg,#0b3340,#0b5660);border-radius:26px;padding:34px;box-shadow:0 22px 50px rgba(10,49,59,.2);color:#fff;position:relative;overflow:hidden}.promo-phrase:after{content:"α";position:absolute;right:-10px;bottom:-88px;font:700 210px Georgia;color:rgba(255,255,255,.05)}.promo-phrase>span{position:relative;z-index:1;display:grid;place-items:center;width:48px;height:48px;border-radius:14px;background:var(--yellow);font-size:22px}.promo-phrase p{position:relative;z-index:1;font:700 30px/1.25 Georgia;margin:28px 0 13px}.promo-phrase small{position:relative;z-index:1;color:#bed7d6;font-size:16px}.promo-section{padding:68px 0 75px;border-top:1px solid #d4e4e1}.promo-section h2,.promo-course h2{font-size:clamp(31px,3.7vw,47px);max-width:620px}.promo-steps{display:grid;grid-template-columns:repeat(3,1fr);gap:17px;margin-top:34px}.promo-steps article{background:#fff;border:1px solid #d7e6e3;border-radius:19px;padding:24px;box-shadow:0 10px 28px rgba(11,66,73,.05)}.promo-steps span{color:#0a8989;font-weight:900;font-size:12px;letter-spacing:1px}.promo-steps h3{font:700 24px Georgia;margin:20px 0 8px}.promo-steps p{margin:0;color:#61767c;font-size:14px;line-height:1.55}.promo-course{margin:0 0 52px;padding:42px;background:linear-gradient(120deg,#eefaf7,#fff);border:1px solid #d7e6e3;border-radius:25px;display:grid;grid-template-columns:1fr 1fr;gap:40px}.promo-course ul{margin:0;padding:0;list-style:none;display:grid;gap:11px}.promo-course li{display:flex;gap:10px;align-items:flex-start;color:#48636c;font-size:15px;line-height:1.35}.promo-course li:before{content:"✓";color:#0d9788;font-weight:900}.promo-footer{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #d4e4e1;padding:24px 0 32px;color:#738a8f;font-size:12px}.promo-footer a{color:#087e83;font-weight:800;text-decoration:none}
@media(max-width:850px){.sidebar nav{grid-template-columns:repeat(5,1fr)}.sidebar nav a{min-width:0;padding:7px 3px;justify-content:center;flex-direction:column;gap:2px;text-align:center;font-size:9px;border-radius:11px}.sidebar nav a:hover{transform:none}.sidebar nav a span{font-size:18px;line-height:1;width:auto}.promo-page{padding:0 22px}.promo-hero{grid-template-columns:1fr;padding:47px 0 58px;gap:34px}.promo-hero h1{font-size:clamp(39px,9vw,58px)}.promo-phrase{max-width:500px}.promo-steps{grid-template-columns:1fr}.promo-course{grid-template-columns:1fr;gap:26px;padding:29px}.promo-lead{font-size:16px}.promo-nav{height:76px}.promo-brand img{width:145px}}
@media(max-width:440px){.promo-page{padding:0 16px}.promo-nav nav{gap:1px}.promo-nav nav a{padding:8px 6px;font-size:11px}.promo-hero{padding-top:34px}.promo-phrase{padding:26px}.promo-phrase p{font-size:25px}.promo-section{padding:51px 0}.promo-course{margin-bottom:34px;padding:24px}.promo-footer{padding-bottom:90px}}

/* First-run setup uses the same language cards as the later course switcher,
   but keeps both choices visible before a lesson can begin. */
.course-setup-modal{max-height:min(720px,calc(100dvh - 32px));overflow:auto}.course-setup-intro{margin:-5px 0 20px;color:#69778a;font-size:14px;line-height:1.45}.setup-language-group{display:grid;gap:8px;margin-top:17px}.setup-language-group>small{font-size:10px;letter-spacing:1.3px;color:#07858b;font-weight:900}.setup-start{width:100%;margin-top:23px;border:0;border-radius:12px;padding:15px 20px;background-color:var(--blue);color:white;font-weight:900;cursor:pointer}.course-setup-backdrop{z-index:120}
@media(max-width:520px){.course-setup-modal{padding:22px 18px;border-radius:20px}.course-setup-intro{font-size:13px;margin-bottom:17px}.course-language-options>button{padding:12px}.course-language-options>button>span{font-size:26px}.setup-start{margin-top:18px}}
/* Alphabet lessons keep the hint reachable without reintroducing the standard
   exercise footer, which is intentionally not rendered for these cards. */
.alphabet-hint-floating {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  z-index: 20;
}

.alphabet-card .choices > button > span { display: none; }
.alphabet-card .choices {
  width: 100%;
  max-width: none;
  flex: 1;
  min-height: 0;
  margin: 0;
  grid-template-rows: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
.alphabet-card .choices > button {
  min-height: 0;
  padding: 0;
  display: grid;
  place-items: center;
  text-align: center;
  border:1px solid #d6dae3;
  border-bottom-width:4px;
  border-radius:12px;
  background:linear-gradient(180deg,#fff 0%,#fff 72%,#f4f6f9 100%);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.98),0 3px 0 #d7dbe3,0 7px 12px rgba(37,56,77,.07);
  font:700 clamp(18px,2.15vw,27px) Georgia,"Times New Roman",serif;
}
.alphabet-card .choices > button:hover {
  transform:translateY(-1px);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.98),0 4px 0 #d7dbe3,0 9px 14px rgba(37,56,77,.1);
}
.alphabet-letter { display: block; font-size: 4.5rem; line-height: 1; }
.alphabet-letter-name { display: block; margin-top: .35rem; font-size: 1rem; font-weight: 700; line-height: 1.25; }
.alphabet-letter-name span { color: var(--muted, #71808a); font-weight: 600; }
.alphabet-card .alphabet-letter,
.alphabet-card .alphabet-letter-name [lang="el"],
.alphabet-card .choices > button,
.alphabet-card .matching:not(.alpha-sound-matching) button,
.alphabet-card .matching.alpha-sound-matching.match-greek-left > div:first-child button,
.alphabet-card .matching.alpha-sound-matching.match-greek-right > div:last-child button {
  font-family:var(--alphabet-glyph-font, Georgia, serif);
  font-style:var(--alphabet-glyph-style, normal);
}
.alphabet-card:has(.matching) > .big-word { display: none; }
.alphabet-card:has(.matching) .matching {
  flex: 1;
  min-height: 0;
  margin: 42px auto 20px;
  max-height: none;
}
.alphabet-card:has(.matching) .matching > div {
  display: grid;
  grid-template-rows: repeat(6, minmax(0, 1fr));
  min-height: 0;
  gap: 14px;
}
.alphabet-card:has(.matching) .matching button {
  height: 100%;
  font-size: clamp(18px, 2.15vw, 27px);
}
.alphabet-card:has(.matching) h1 { margin-top: 44px; }
.alphabet-table-wrap { overflow-x:hidden; overflow-y:auto; border:1px solid #dce4e4; border-radius:14px; background:#fff; }
.alphabet-table { width:100%; table-layout:fixed; border-collapse:collapse; font-size:14px; }
.alphabet-table th { position:sticky; top:0; background:#0b7f86; color:#fff; padding:10px 5px; font-size:11px; text-align:left; overflow-wrap:anywhere; }
.alphabet-table td { padding:9px 5px; border-top:1px solid #e4e9e9; overflow-wrap:anywhere; word-break:break-word; }
.alphabet-table td:first-child,.alphabet-table td:nth-child(2) { font:bold 22px Georgia,serif; text-align:center; }
.alphabet-table td button { border:0; background:none; padding:0; color:#075b61; font:700 16px Georgia,serif; cursor:pointer; }
.alphabet-table .alphabet-active { background:#fff0ef; color:#b8322a; }
.alphabet-table .alphabet-active td button { color:#b8322a; }
.alphabet-hint-note { color:#b8322a; font-weight:700; }
@media (max-width: 700px) {
  .alphabet-table { font-size:11px; }
  .alphabet-table th { font-size:9px; padding:8px 3px; }
  .alphabet-table td { padding:7px 3px; }
  .alphabet-table td:first-child,.alphabet-table td:nth-child(2) { font-size:17px; }
  .alphabet-table td button { font-size:12px; }
}

@media (max-width: 700px) {
  .alphabet-hint-floating { bottom: 18px; }
}

/* The lesson page intentionally locks the document while an exercise is open.
   Make a long completion dialog its own touch-scroll container on phones. */
@media (max-width: 680px) {
  .lesson-summary-backdrop {
    display:block;
    overflow-y:auto;
    overscroll-behavior:contain;
    -webkit-overflow-scrolling:touch;
    padding:16px 12px calc(16px + env(safe-area-inset-bottom));
  }
  .lesson-summary {
    width:100%;
    max-height:none;
    margin:auto;
    overflow:visible;
    padding:26px 20px;
  }
}

/* Reading reference: a legible rule card works better than a single dense line. */
.reading-rules{margin-top:34px}.reading-rules-heading{display:flex;justify-content:space-between;align-items:end;margin-bottom:15px}.reading-rules h2{margin:0;font:700 27px Georgia;color:var(--ink)}.reading-rules-heading p{margin:7px 0 0;color:#7c8598;font-size:13px}.reading-rules-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px}.reading-rules-grid article{min-width:0;background:#fff;border:1px solid var(--line);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:10px;box-shadow:0 8px 28px rgba(14,60,68,.045)}.reading-pattern{align-self:flex-start;border-radius:999px;padding:5px 10px;background:#e9fbf7;color:#087d85;font:700 14px Georgia}.reading-rules-grid h3{margin:0;color:#183a45;font-size:15px;line-height:1.25}.reading-rules-grid p{margin:0;color:#596378;font-size:13px;line-height:1.48}.reading-rules-grid blockquote{margin:0;padding:10px 12px;border-left:3px solid #57cec0;background:#f3fbf9;color:#31656a;font:700 13px/1.4 Georgia}.reading-notes{margin:18px 0 0;padding:17px 20px;border-radius:14px;background:#f1f8f7;border:1px solid #d8ece8;color:#677486}.reading-notes p{margin:5px 0;font-size:13px;line-height:1.45}
@media(max-width:1050px){.reading-rules-grid{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.reading-rules-grid{grid-template-columns:1fr}.reading-rules{margin-top:27px}.reading-rules h2{font-size:24px}.reading-rules-grid article{padding:16px}}

/* Explicit values from choiceTextStyle avoid unsupported CSS calc division. */
.choices button,.pronunciation-choices button{font-size:var(--choice-font-desktop,22px)}
@media(max-width:560px){.lesson-wrap .choices button,.lesson-wrap .pronunciation-choices button{font-size:var(--choice-font-mobile,14px)}}

/* Russian translations are phrases, not unbreakable word labels.  Let every
   option wrap and balance its lines while choiceTextStyle keeps one shared
   font size for the whole answer group. */
.pronunciation-choices button{white-space:normal;overflow-wrap:anywhere;word-break:normal;text-wrap:balance;line-height:1.16;min-height:68px}

/* One navigation bar for every screen: controls which used to live in the
   sidebar and in the mobile dock now share the application header. */
.app-shell{display:block}
.workspace{margin-left:0;width:100%}
.topbar{height:76px;justify-content:center;padding:0 max(22px,calc((100vw - 1240px)/2));gap:22px;position:sticky;top:0;z-index:20}
.header-brand{flex:none;width:46px;height:46px;padding:0;border:0;border-radius:14px;background:var(--navy);cursor:pointer;box-shadow:0 3px 0 var(--blue-dark)}
.header-brand img{display:block;width:100%;height:100%}
.top-navigation{display:flex;flex:1;flex-direction:row;justify-content:flex-end;align-items:center;gap:6px}
.top-navigation button{display:inline-flex;align-items:center;gap:0;border:0;border-radius:11px;background:transparent;padding:10px 13px;color:#526873;font-size:14px;font-weight:800;text-align:center;white-space:nowrap;cursor:pointer;transition:background .16s,color .16s}
.top-navigation button span{display:inline-block;width:auto;margin-right:6px;color:var(--blue);font-size:16px}
.top-navigation button:hover{background:#edf9f7;color:var(--blue)}
.top-navigation .nav-active{background:#e8faf6;color:#075b61}
.top-navigation .top-language{margin-left:6px;border:1px solid #c8e3e1;background:#f5fbfb;color:#075b61}

@media(max-width:700px){
  .topbar{height:auto;min-height:64px;padding:8px 10px;justify-content:flex-start;gap:8px;overflow-x:auto;scrollbar-width:none}
  .topbar::-webkit-scrollbar{display:none}
  .header-brand{width:38px;height:38px;border-radius:11px}
  .top-navigation{gap:4px;justify-content:flex-start;width:max-content;flex:none}
  .top-navigation button{padding:8px 9px;font-size:11px}
  .top-navigation button span{display:none}
  .top-navigation .top-language{margin-left:2px}
  .workspace{padding-bottom:0}
  body.lesson-active .workspace{padding-bottom:0}
}

/* Labels are drawn before the decorative face, so keep that SVG layer clear. */
.clock-rim{fill:transparent}
.clock-minute-number{font-size:10px}
.clock-face{margin:22px 0 42px}
.clock-rim{filter:none}
.clock-number{font-size:19px}
.clock-picker p{font-size:0}
.clock-picker p::after{content:"Вращайте стрелки за ручки";font:600 15px/1.35 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}

/* In speaking tasks the text is gradually revealed by speech recognition. */
.reading-phrase span{display:inline-block;transition:filter .22s ease,color .22s ease,background-color .22s ease}
.reading-phrase span:not(.recognized){filter:blur(7px);color:rgba(11,67,80,.44);user-select:none}
.reading-phrase span.recognized{filter:none}

/* In speaking exercises the phrase stays on screen: unrecognized words are
   blurred by the rules above and are revealed individually after recognition. */
.hidden-greek-card .reading-phrase{
  font-size:clamp(2rem,4vw,4.5rem)!important;
  min-height:0;
  display:flex;
  align-items:center;
  justify-content:center;
}
.hidden-greek-card .reading-phrase>*{display:inline-block}
.hidden-greek-card .reading-phrase::after{content:none}

/* Time tasks must remain a one-screen interaction.  The labels outside the
   face have their own reserved space, but never turn the exercise card into
   a scroll area. */
@media(max-width:850px){
  .lesson-wrap .number-card{overflow:hidden!important}
  .lesson-wrap .number-card .clock-answer{margin:2px auto 4px;font-size:25px}
  .lesson-wrap .number-card .clock-picker{gap:4px}
  .lesson-wrap .number-card .clock-face{width:min(220px,54dvh);margin:2px 0 27px}
  .lesson-wrap .number-card .clock-period button{min-height:37px;padding:7px 13px;font-size:15px}
  .lesson-wrap .number-card .clock-picker p::after{font-size:12px}
}
@media(max-width:850px) and (max-height:690px){
  .lesson-wrap .number-card .clock-face{width:min(185px,43dvh);margin:0 0 21px}
  .lesson-wrap .number-card .clock-period button{min-height:33px;font-size:13px}
  .lesson-wrap .number-card .clock-picker p::after{font-size:10px}
}

/* Text containment is an application-wide layout rule.  Phrases wrap only at
   spaces; a measured fallback in page.tsx reduces a single overlong word as a
   whole instead of cutting it in the middle. */
html,body{max-width:100%;overflow-x:hidden}
.app-shell,.app-shell *{min-width:0}
.app-shell :is(h1,h2,h3,h4,p,b,strong,small,span,button,a,label,li,td,th){
  max-inline-size:100%;
  overflow-wrap:normal;
  word-break:normal;
  hyphens:manual;
}
.app-shell :is(.prompt,.big-word,.reading-phrase,.choices button,.matching button,.word-chip,.top-navigation button){
  white-space:normal;
}
.lesson-wrap .big-word,.lesson-wrap .prompt{flex-wrap:wrap;justify-content:center}
.lesson-wrap .big-word> :is(b,small),.lesson-wrap .prompt>.phrase-prompt-text{min-width:0;max-width:100%;text-align:center}
.lesson-wrap .pronunciation-word>b{flex:1 1 100%}
.lesson-wrap .choices button,.lesson-wrap .matching button{height:auto;min-height:48px;line-height:1.16}
.pronunciation-choices button,.pronunciation-table td{overflow-wrap:normal;word-break:normal;hyphens:manual}

/* Every recorded phrase offers normal and slower playback from the same file.
   Individual vocabulary words retain their existing single speaker button. */
.phrase-prompt{flex-direction:column;gap:12px;cursor:default}
.phrase-prompt-text{display:block;text-align:center}
.phrase-audio-controls{display:flex;align-items:center;justify-content:center;gap:8px;margin-inline:auto;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
.phrase-audio-controls button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:44px;padding:8px 13px;border:1px solid #80d2cf;border-radius:11px;background:#e9faf7;color:#087d84;box-shadow:0 3px 0 #a8cfcb;font:800 13px/1.2 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;cursor:pointer}
.phrase-audio-controls button.phrase-audio-slow{background:#fff;border-color:#cbd8dd;color:#42616b;box-shadow:0 3px 0 #d7dfe2}
.phrase-audio-controls button:hover:not(:disabled){filter:brightness(.97)}
.phrase-audio-controls button:active:not(:disabled){transform:translateY(2px);box-shadow:0 1px 0 #a8cfcb}
.phrase-audio-controls button:disabled{opacity:.58;cursor:wait}
.phrase-audio-controls button>span:first-child{font-size:19px;line-height:1}
.phrase-audio-compact button{width:44px;min-width:44px;height:44px;padding:6px}
.phrase-audio-compact .phrase-audio-label{display:none}
.listening-audio-controls{margin:20px auto 35px}
.phrase-copy>.phrase-audio-controls{flex:none;margin:0}
.hint-phrase>.phrase-audio-controls{flex:none;margin:0}
@media(max-width:560px){.phrase-audio-controls button{min-height:42px;padding:7px 10px;font-size:12px}.phrase-audio-compact button{width:40px;min-width:40px;height:40px}.phrase-prompt{gap:8px}}
