/* Unbounded for letters only. Its "0" looks like the letter "O", so digits fall through to Nunito. */
@font-face {
  font-family: "UnboundedLetters";
  font-style: normal;
  font-weight: 600 800;
  font-display: swap;
  src: url(https://fonts.gstatic.com/s/unbounded/v12/Yq6W-LOTXCb04q32xlpwu8Zf.woff2) format("woff2");
  unicode-range: U+0000-002F, U+003A-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2122, U+2212;
}
/* =========================================================================
   ეროვნული — ინგლისური · design system
   Style: soft neo-brutalism — paper background, ink outlines, hard offset
   shadows, bold colour blocks. Headings: Unbounded (Latin) + Noto Sans
   Georgian (mtavruli for labels).
   ========================================================================= */
:root {
  --bg: #F4F0E8;
  --bg-2: #EBE5D9;
  --card: #FFFDF9;
  --ink: #17161C;
  --muted: #6E6A63;
  --line: #17161C;
  --line-soft: #E3DDD0;
  --accent: #5B45F0;
  --accent-2: #4733D6;
  --accent-soft: #ECE8FF;
  --accent-line: #5B45F0;
  --lime: #D4F25A;
  --coral: #FF6B45;
  --sky: #9BD7FF;
  --yellow: #FFD43B;
  --green: #1DB257;
  --green-dark: #10813D;
  --green-soft: #DDF6E5;
  --red: #E5383B;
  --red-soft: #FFE3E1;
  --yellow-soft: #FFF3C4;
  --blue: #2F6FEB;
  --blue-soft: #E1ECFF;
  --shadow: 3px 3px 0 var(--ink);
  --shadow-lg: 5px 5px 0 var(--ink);
  --radius: 20px;
  --radius-sm: 14px;
  --font: "Noto Sans Georgian", "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "UnboundedLetters", "Nunito", "Noto Sans Georgian", system-ui, sans-serif;
  --tabbar-h: 74px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(color-mix(in srgb, var(--ink) 7%, transparent) 1px, transparent 1px);
  background-size: 18px 18px;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
img { max-width: 100%; }
::selection { background: var(--lime); color: #17161C; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.app { max-width: 780px; margin: 0 auto; min-height: 100vh; }
.view { padding: 22px 16px calc(var(--tabbar-h) + 40px); outline: none; }
.ic { width: 1.15em; height: 1.15em; flex: none; vertical-align: -0.2em; }

/* ---------- Typography ---------- */
h1, h2, h3 { margin: 0 0 8px; line-height: 1.15; }
.page-title { font-family: var(--display); font-size: 32px; font-weight: 800; letter-spacing: -0.5px; }
.lead { color: var(--muted); margin: 0 0 22px; font-size: 16px; }
.section-title {
  font-size: 13px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase;
  margin: 30px 0 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.section-title small { font-size: 12px; color: var(--muted); font-weight: 700; text-transform: none; letter-spacing: 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.en { font-family: "Nunito", var(--font); }

/* ---------- Cards ---------- */
.card { background: var(--card); border: 2px solid var(--ink); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; margin-bottom: 16px; }
.card.flat { box-shadow: none; }
.card.note { background: var(--yellow-soft); }
.card.note .title { font-weight: 800; display: flex; gap: 10px; align-items: center; margin-bottom: 4px; }
.card.goal { background: var(--accent-soft); font-weight: 700; }
.badge-ico { width: 28px; height: 28px; border-radius: 50%; background: var(--yellow); border: 2px solid var(--ink); color: #17161C; display: inline-grid; place-items: center; font-weight: 900; flex: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 22px; min-height: 52px; border-radius: 999px;
  border: 2px solid var(--ink); background: var(--card); color: var(--ink);
  box-shadow: var(--shadow); font-weight: 800; text-decoration: none; cursor: pointer;
  transition: transform .08s, box-shadow .08s, background .15s; user-select: none;
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn.primary { background: var(--accent); color: #fff; }
.btn.accent { background: var(--coral); color: #17161C; }
.btn.ghost { background: transparent; box-shadow: none; border-color: transparent; color: var(--muted); }
.btn.ghost:hover { transform: none; color: var(--ink); }
.btn.block { width: 100%; }
.btn.sm { padding: 7px 14px; min-height: 38px; font-size: 14px; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-row > .btn { flex: 1 1 160px; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); font-weight: 800; cursor: pointer; text-decoration: none; }
.link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Home ---------- */
.topbar { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; min-height: 44px; }
.topbar .hello { font-weight: 800; font-size: 15px; }
.avatar-link { text-decoration: none; margin-left: auto; }
.avatar { width: 42px; height: 42px; border-radius: 50%; display: inline-grid; place-items: center; object-fit: cover; background: var(--lime); color: #17161C; font-weight: 900; font-size: 18px; border: 2px solid var(--ink); flex: none; }
.avatar.lg { width: 64px; height: 64px; font-size: 26px; }

.hero { position: relative; overflow: hidden; background: #17161C; color: #fff; border: 2px solid var(--ink); border-radius: 26px; box-shadow: var(--shadow-lg); padding: 24px 22px 0; margin-bottom: 18px; }
.hero .chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--lime); color: #17161C; font-weight: 800; font-size: 12px; margin-bottom: 14px; border: 2px solid #17161C; }
.hero h1 { font-family: var(--display); font-size: 34px; font-weight: 800; line-height: 1.08; margin-bottom: 12px; letter-spacing: -.5px; }
.hero h1 .hl { color: var(--lime); }
.hero .lead { color: rgba(255,255,255,.78); max-width: 440px; }
.hero .btn-row { position: relative; z-index: 1; }
.hero .btn { border-color: #fff; box-shadow: 3px 3px 0 #fff; color: #fff; background: transparent; }
.hero .btn.primary { background: var(--lime); color: #17161C; border-color: #17161C; }
.hero .art { display: block; width: 100%; max-width: 380px; margin: 14px 0 -4px auto; }
.hero .art [stroke="var(--ink)"] { stroke: #17161C; }
@media (min-width: 640px) {
  .hero { display: grid; grid-template-columns: 1.15fr 1fr; gap: 10px; padding: 30px 28px 0; }
  .hero .art { align-self: end; margin: 0 -6px -4px 0; }
  .hero > div:first-child { padding-bottom: 28px; }
}

.bento { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 6px 0 8px; }
.tile-b { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; min-height: 172px; padding: 16px; border: 2px solid var(--ink); border-radius: 22px; box-shadow: var(--shadow); text-decoration: none; color: #17161C; transition: transform .1s, box-shadow .1s; }
.tile-b:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--ink); }
.tile-b:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.tile-b .t-title { font-family: var(--display); font-weight: 800; font-size: 16px; line-height: 1.2; max-width: 78%; }
.tile-b .t-sub { font-size: 13px; font-weight: 700; opacity: .8; margin-top: 4px; max-width: 72%; }
.tile-b .t-badge { position: absolute; top: 12px; right: 12px; font-weight: 900; font-size: 12px; background: #FFFDF9; color: #17161C; border: 2px solid #17161C; border-radius: 999px; padding: 2px 9px; }
.tile-b .art { position: absolute; right: -8px; bottom: -10px; width: 112px; pointer-events: none; }
.tile-b .art [stroke="var(--ink)"] { stroke: #17161C; }
.tile-b.wide { grid-column: span 2; min-height: 156px; }
.tile-b.wide .art { width: 150px; }
.tile-b .t-go { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 13px; position: relative; }
.t-violet { background: var(--accent); color: #fff; }
.t-lime { background: var(--lime); }
.t-coral { background: var(--coral); }
.t-sky { background: var(--sky); }
.t-yellow { background: var(--yellow); }
.t-paper { background: var(--card); color: var(--ink); }
@media (min-width: 640px) { .bento { grid-template-columns: repeat(3, 1fr); } }

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 18px 0; }
.stat { background: var(--card); border: 2px solid var(--ink); border-radius: var(--radius-sm); padding: 14px; box-shadow: var(--shadow); }
.stat b { display: block; font-family: var(--display); font-size: 24px; font-weight: 800; }
.stat span { color: var(--muted); font-size: 13px; font-weight: 700; }
@media (min-width: 560px) { .stats { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Pills, tiles ---------- */
.level-pills { display: flex; gap: 8px; overflow-x: auto; padding: 4px 4px 12px 2px; margin: 0 -2px 6px; scrollbar-width: none; }
.level-pills::-webkit-scrollbar { display: none; }
.pill { text-decoration: none; flex: none; padding: 7px 16px; border-radius: 999px; border: 2px solid var(--ink); background: var(--card); font-weight: 800; cursor: pointer; box-shadow: 2px 2px 0 var(--ink); font-family: var(--display); font-size: 13px; }
.pill.on { background: #17161C; color: var(--lime); }
.tile-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
@media (min-width: 560px) { .tile-grid { grid-template-columns: repeat(5, 1fr); } }
.tile { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; aspect-ratio: 1; padding: 6px; border-radius: 16px; background: var(--card); border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); text-decoration: none; transition: transform .08s; }
.tile:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--ink); }
.tile .num { font-family: var(--display); font-size: 20px; font-weight: 800; }
.tile .sub { font-size: 10.5px; font-weight: 800; color: var(--muted); }
.tile.done { background: var(--lime); color: #17161C; }
.tile.done .sub, .tile.progress .sub { color: #17161C; }
.tile.progress { background: var(--yellow); color: #17161C; }

/* ---------- Lists ---------- */
.list { display: grid; gap: 10px; }
.row-link { display: flex; align-items: center; gap: 14px; padding: 12px 14px; background: var(--card); border: 2px solid var(--ink); border-radius: var(--radius-sm); box-shadow: 2px 2px 0 var(--ink); text-decoration: none; transition: transform .08s, box-shadow .08s; }
.row-link:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
.row-link .ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; background: var(--bg-2); border: 2px solid var(--ink); flex: none; }
.row-link .ico .ic { width: 22px; height: 22px; }
.row-link .txt { flex: 1; min-width: 0; }
.row-link .txt b { display: block; font-weight: 800; }
.row-link .txt span { color: var(--muted); font-size: 13px; }
.row-link .arrow { font-weight: 900; font-size: 20px; }
.next-up { background: var(--lime); color: #17161C; }
.next-up .ico { background: #FFFDF9; border-color: #17161C; }
.next-up .txt span { color: #17161C; opacity: .75; }

.task-table { display: grid; gap: 8px; margin: 16px 0; }
.task-table div { display: flex; justify-content: space-between; align-items: center; padding: 11px 14px; border-radius: 12px; background: var(--bg); border: 2px solid var(--line-soft); font-weight: 700; }
.task-table div span:first-child { display: flex; gap: 8px; align-items: center; }
.task-table div span:last-child { font-family: var(--display); font-size: 13px; font-weight: 800; }

/* ---------- Runner ---------- */
.runner-head { position: sticky; top: 0; z-index: 5; background: var(--bg); padding: 12px 16px 10px; margin: -22px -16px 16px; border-bottom: 2px solid var(--ink); }
.runner-top { display: flex; align-items: center; gap: 12px; }
.runner-top .back { font-size: 22px; text-decoration: none; padding: 2px 8px; font-weight: 900; }
.timer { margin-left: auto; font-family: var(--display); font-weight: 800; font-size: 14px; font-variant-numeric: tabular-nums; padding: 5px 12px; border-radius: 999px; background: var(--card); border: 2px solid var(--ink); }
.timer.low { background: var(--red); color: #fff; }
.task-tabs { display: flex; gap: 6px; margin-top: 10px; overflow-x: auto; scrollbar-width: none; }
.task-tabs::-webkit-scrollbar { display: none; }
.task-tab { text-decoration: none; flex: none; min-width: 48px; padding: 6px 10px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card); font-weight: 800; font-size: 13px; text-align: center; }
.task-tab .ic { width: 18px; height: 18px; }
.task-tab .cnt { display: block; font-size: 10px; color: var(--muted); font-weight: 800; }
.task-tab.full { background: var(--lime); color: #17161C; }
.task-tab.full .cnt { color: #17161C; }
.task-tab.on { background: #17161C; color: var(--lime); }
.task-tab.on .cnt { color: #fff; }
.bar { height: 12px; background: var(--card); border: 2px solid var(--ink); border-radius: 999px; overflow: hidden; margin-top: 10px; }
.bar > i { display: block; height: 100%; background: var(--accent); transition: width .3s; }
.task-head h2 { font-family: var(--display); font-size: 20px; font-weight: 800; display: flex; align-items: center; gap: 10px; }
.instr { font-style: italic; color: var(--muted); margin: 0 0 14px; font-family: "Nunito", var(--font); }

.passage { font-family: "Nunito", var(--font); font-size: 17px; line-height: 1.75; }
.passage p { margin: 0 0 12px; }
.para { display: flex; gap: 12px; margin-bottom: 12px; }
.para .tag { flex: none; width: 30px; height: 30px; border-radius: 9px; background: var(--yellow); color: #17161C; border: 2px solid var(--ink); font-weight: 900; display: grid; place-items: center; font-family: var(--display); font-size: 13px; }

.q { margin-bottom: 22px; }
.q-text { font-weight: 800; margin-bottom: 10px; font-family: "Nunito", var(--font); font-size: 16.5px; }
.q-text .n { font-family: var(--display); color: var(--accent); margin-right: 6px; font-size: 14px; }
.opts { display: grid; gap: 8px; }
.opt { display: flex; gap: 12px; align-items: center; text-align: left; width: 100%; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--card); border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; font-family: "Nunito", var(--font); font-size: 16px; transition: transform .06s; }
.opt:hover { transform: translate(-1px, -1px); box-shadow: 3px 3px 0 var(--ink); }
.opt .l { flex: none; width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--ink); display: grid; place-items: center; font-weight: 900; font-size: 12px; background: var(--bg); font-family: var(--display); }
.opt.sel { background: var(--accent-soft); }
.opt.sel .l { background: var(--accent); color: #fff; }
.opt.ok { background: var(--green-soft); }
.opt.ok .l { background: var(--green); color: #fff; }
.opt.bad { background: var(--red-soft); }
.opt.bad .l { background: var(--red); color: #fff; }
.opt[disabled] { cursor: default; }
.opt[disabled]:hover { transform: none; box-shadow: 2px 2px 0 var(--ink); }
.letters { display: flex; flex-wrap: wrap; gap: 8px; }
.letter { width: 46px; height: 46px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card); box-shadow: 2px 2px 0 var(--ink); font-weight: 800; cursor: pointer; font-family: var(--display); }
.letter.sel { background: var(--accent); color: #fff; }
.letter.ok { background: var(--green); color: #fff; }
.letter.bad { background: var(--red); color: #fff; }

.gap-text { font-family: "Nunito", var(--font); font-size: 17px; line-height: 2.3; }
.gap { display: inline-block; vertical-align: baseline; max-width: 100%; text-overflow: ellipsis; padding: 2px 6px; margin: 0 2px; border-radius: 10px; border: 2px solid var(--ink); background: var(--card); font-weight: 800; font-size: 15px; font-family: "Nunito", var(--font); cursor: pointer; }
.gap:focus { outline: 3px solid var(--accent); }
.gap.filled { background: var(--accent-soft); }
.gap.ok { background: var(--green-soft); border-color: var(--green-dark); }
.gap.bad { background: var(--red-soft); border-color: var(--red); }
.gap-no { font-weight: 900; color: var(--accent); font-size: 13px; }
.fix { font-weight: 800; color: var(--green-dark); font-size: 14px; }
.wordbank { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 4px; }
.word { padding: 5px 12px; border-radius: 999px; background: var(--bg); border: 2px solid var(--ink); font-weight: 700; font-size: 14px; font-family: "Nunito", var(--font); }
.word b { color: var(--accent); margin-right: 4px; font-family: var(--display); font-size: 12px; }
.word.used { opacity: .35; text-decoration: line-through; }

.dlg { display: grid; gap: 10px; font-family: "Nunito", var(--font); }
.turn { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.who { font-weight: 900; font-size: 12px; letter-spacing: .4px; text-transform: uppercase; color: var(--accent); padding-left: 4px; }
.say { background: var(--bg); border: 2px solid var(--line-soft); border-radius: 16px 16px 16px 4px; padding: 8px 12px; line-height: 1.9; min-width: 0; overflow-wrap: anywhere; }
.say .gap { width: 100%; }
.optlist { display: grid; gap: 6px; margin: 14px 0 4px; font-family: "Nunito", var(--font); }
.optlist div { padding: 8px 12px; border-radius: 12px; background: var(--bg); border: 2px solid var(--line-soft); font-size: 15px; }
.optlist b { color: var(--accent); margin-right: 6px; font-family: var(--display); font-size: 12px; }
.optlist .used { opacity: .35; }

.player { display: grid; gap: 10px; }
.plays { font-weight: 800; color: var(--muted); font-size: 13px; }
.no-audio { background: var(--yellow-soft); border: 2px dashed var(--ink); border-radius: var(--radius-sm); padding: 14px; font-size: 14px; }
.transcript { display: grid; gap: 8px; font-family: "Nunito", var(--font); margin-top: 12px; }
.transcript p { margin: 0; }
.transcript .sp { font-weight: 900; color: var(--accent); }
.lplayer .lp-btn { min-height: 58px; font-size: 17px; }
.lplayer .lp-btn[disabled] { opacity: 1; background: var(--lime); color: #17161C; }
.lp-row { display: flex; align-items: center; gap: 12px; }
.lp-bar { flex: 1; height: 12px; border-radius: 999px; background: var(--card); border: 2px solid var(--ink); overflow: hidden; }
.lp-bar i { display: block; height: 100%; background: var(--coral); transition: width .25s linear; }
.lp-time { font-size: 13px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }

.essay-box { width: 100%; min-height: 280px; padding: 16px; border-radius: var(--radius); border: 2px solid var(--ink); background: var(--card); box-shadow: var(--shadow); font-family: "Nunito", var(--font); font-size: 16px; line-height: 1.7; resize: vertical; }
.essay-box:focus { outline: none; box-shadow: 4px 4px 0 var(--accent); }
.wc { display: flex; justify-content: space-between; font-weight: 800; font-size: 14px; margin-top: 10px; }
.wc .over { color: var(--red); }
.wc .ok { color: var(--green-dark); }

.score-ring { width: 170px; height: 170px; border-radius: 50%; margin: 8px auto 16px; display: grid; place-items: center; border: 2px solid var(--ink); background: conic-gradient(var(--accent) calc(var(--p) * 1%), var(--bg-2) 0); }
.score-ring > div { width: 128px; height: 128px; border-radius: 50%; background: var(--card); border: 2px solid var(--ink); display: grid; place-items: center; text-align: center; }
.score-ring b { font-family: var(--display); font-size: 36px; font-weight: 800; display: block; line-height: 1; }
.score-ring span { color: var(--muted); font-size: 12px; font-weight: 700; }
.result-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; background: var(--card); border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); margin-bottom: 10px; font-weight: 700; }
.result-row > span { display: flex; align-items: center; gap: 8px; }
.result-row b { font-family: var(--display); font-weight: 800; font-size: 14px; }
.verdict { text-align: center; font-weight: 900; font-size: 20px; margin-bottom: 4px; }

/* ---------- Tab bar: floating dock ---------- */
.tabbar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 20; width: calc(100% - 20px); max-width: 560px; display: flex; justify-content: space-between; gap: 2px; padding: 6px; background: var(--card); border: 2px solid var(--ink); border-radius: 22px; box-shadow: var(--shadow); }
.tabbar a { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 7px 0 5px; border-radius: 16px; text-decoration: none; color: var(--muted); font-size: 10px; font-weight: 800; }
.tabbar a .ico { line-height: 1; display: grid; }
.tabbar a .ic { width: 22px; height: 22px; }
.tabbar a span:last-child { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tabbar a.on { background: #17161C; color: var(--lime); }
body.running .tabbar { display: none; }
body.running .view { padding-bottom: 40px; }
@media (max-width: 380px) { .tabbar a { font-size: 9.5px; letter-spacing: -0.3px; } }

/* ---------- Modal, misc ---------- */
.modal { position: fixed; inset: 0; z-index: 50; background: rgba(23, 22, 28, .55); display: grid; place-items: end center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-card { width: 100%; max-width: 520px; background: var(--card); border: 2px solid var(--ink); border-radius: 24px; padding: 22px; box-shadow: var(--shadow-lg); max-height: 85vh; overflow: auto; }
.modal-card h2 { font-family: var(--display); font-size: 19px; }
@media (min-width: 560px) { .modal { place-items: center; } }
.empty { text-align: center; color: var(--muted); padding: 30px 10px; }
.kbd-hint { font-size: 12px; color: var(--muted); text-align: center; margin-top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 28px); transform: translateX(-50%); background: #17161C; color: var(--lime); padding: 10px 16px; border-radius: 999px; font-weight: 800; z-index: 60; font-size: 14px; border: 2px solid #17161C; box-shadow: 3px 3px 0 var(--lime); }
h1 { overflow-wrap: break-word; }
@media (max-width: 380px) { .hero h1 { font-size: 28px; } .page-title { font-size: 27px; } }

/* ---------- Grammar course ---------- */
.lesson-no { font-family: var(--display); font-weight: 800; font-size: 14px !important; }
.lesson-no.done { background: var(--lime) !important; color: #17161C; }
.stars { color: #E8A600; letter-spacing: 1px; font-weight: 900; }
.stars.big { font-size: 34px; letter-spacing: 4px; }
.big-emoji { font-size: 64px; line-height: 1; margin-bottom: 8px; }
.lesson-title { font-size: 26px; }
.md p { margin: 0 0 12px; }
.md p:last-child { margin-bottom: 0; }
.md ul, .md ol { margin: 0 0 12px; padding-left: 20px; }
.md li { margin-bottom: 4px; }
.md b { font-weight: 800; }
.md i { font-family: "Nunito", var(--font); font-style: normal; background: var(--lime); color: #17161C; padding: 0 5px; border-radius: 6px; }
.md s { color: var(--red); }
.md code { background: var(--bg); padding: 1px 5px; border-radius: 6px; font-size: 14px; }
.md-table { overflow-x: auto; margin: 4px 0 14px; border-radius: 12px; border: 2px solid var(--ink); }
.md table { border-collapse: collapse; width: 100%; font-size: 14px; }
.md th, .md td { padding: 8px 10px; text-align: left; vertical-align: top; border-bottom: 2px solid var(--line-soft); }
.md th { background: #17161C; color: #fff; font-weight: 800; }
.md tr:last-child td { border-bottom: 0; }
.examples, .mistakes { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.examples li { display: grid; gap: 2px; }
.ex-li { display: flex !important; gap: 12px; align-items: flex-start; }
.ex-li > div { display: grid; gap: 2px; min-width: 0; }
.ex-en { font-weight: 800; font-size: 16px; }
.mistakes .wrong { color: var(--red); }
.mistakes .right { color: var(--green-dark); font-weight: 800; }

body.lesson-run .view { padding-bottom: 280px; }
.ex-card { margin-top: 4px; }
.ex-head { font-size: 12px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.ex-prompt { font-size: 21px; font-weight: 800; line-height: 1.5; margin-bottom: 16px; }
.blank { display: inline-block; min-width: 70px; height: 1.3em; vertical-align: -0.2em; border-bottom: 3px dashed var(--ink); margin: 0 4px; }
.blank.filled { min-width: 0; height: auto; border-bottom-style: solid; border-color: var(--accent); color: var(--accent); padding: 0 4px; }
.blank.filled.ok { border-color: var(--green); color: var(--green-dark); }
.blank.filled.bad { border-color: var(--red); color: var(--red); }
.answer-line { min-height: 62px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 0; border-bottom: 2px solid var(--ink); margin-bottom: 18px; }
.answer-line.ok { border-color: var(--green); }
.answer-line.bad { border-color: var(--red); }
.tiles { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.wtile { padding: 9px 14px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card); box-shadow: 2px 2px 0 var(--ink); font-weight: 800; font-size: 16px; cursor: pointer; }
.wtile:active { transform: translate(2px, 2px); box-shadow: none; }
.wtile.ghost { color: transparent; background: var(--bg-2); box-shadow: none; border-color: var(--line-soft); }
.wtile[disabled] { cursor: default; }
.match-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.match-grid > div { display: grid; gap: 10px; align-content: start; }
.mbtn { min-height: 54px; padding: 10px; border-radius: var(--radius-sm); border: 2px solid var(--ink); background: var(--card); box-shadow: 2px 2px 0 var(--ink); font-weight: 800; cursor: pointer; overflow-wrap: anywhere; }
.mbtn.sel { background: var(--accent); color: #fff; }
.mbtn.done { background: var(--green-soft); color: var(--green-dark); border-color: var(--line-soft); box-shadow: none; opacity: .6; }
.mbtn.wrong { background: var(--red-soft); border-color: var(--red); animation: shake .3s; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
.type-input { width: 100%; padding: 14px; border-radius: var(--radius-sm); border: 2px solid var(--ink); background: var(--card); font-size: 18px; font-weight: 700; box-shadow: 2px 2px 0 var(--ink); }
.type-input:focus { outline: none; box-shadow: 3px 3px 0 var(--accent); }
.type-input.ok { background: var(--green-soft); }
.type-input.bad { background: var(--red-soft); }

.lfoot { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; max-width: 780px; margin: 0 auto; }
.fb { padding: 16px 16px calc(16px + env(safe-area-inset-bottom)); border-top: 2px solid var(--ink); background: var(--bg); }
.fb.ok, .fb.bad { border-radius: 22px 22px 0 0; border: 2px solid var(--ink); border-bottom: 0; }
.fb.ok { background: var(--green-soft); }
.fb.bad { background: var(--red-soft); }
.fb.ok .fb-title { color: var(--green-dark); }
.fb.bad .fb-title { color: var(--red); }
.fb-title { font-family: var(--display); font-size: 19px; font-weight: 800; margin-bottom: 4px; }
.fb-ans { font-size: 15px; margin-bottom: 4px; }
.fb-exp { font-size: 14px; margin-bottom: 4px; }
.fb .btn { margin-top: 10px; }
.fb.ok .btn.primary { background: var(--green); }
.fb.bad .btn.accent { background: var(--red); color: #fff; }
.fb-say { display: flex; align-items: center; gap: 8px; margin: 4px 0; }

/* ---------- Speech ---------- */
.spk { flex: none; width: 36px; height: 36px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; font-size: 16px; display: inline-grid; place-items: center; padding: 0; vertical-align: middle; }
.spk:active { transform: translate(2px, 2px); box-shadow: none; }
.spk.sm { width: 30px; height: 30px; font-size: 13px; border-radius: 10px; }
.spk.big { width: 100px; height: 100px; border-radius: 30px; font-size: 44px; background: var(--coral); box-shadow: var(--shadow-lg); }
.spk.slow { width: 58px; height: 58px; border-radius: 18px; font-size: 26px; background: var(--lime); }
.listen-box { display: flex; gap: 16px; align-items: flex-end; justify-content: center; margin: 6px 0 22px; }

/* ---------- Settings & account ---------- */
.set-sec { font-size: 12px; font-weight: 900; letter-spacing: .7px; text-transform: uppercase; margin: 26px 4px 10px; display: flex; align-items: center; gap: 8px; }
.set-sec::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--accent); border: 2px solid var(--ink); }
.set-card { padding: 14px; }
.set-profile { display: flex; gap: 14px; align-items: center; margin-bottom: 10px; }
.text-in { width: 100%; padding: 11px 13px; border-radius: 12px; border: 2px solid var(--ink); background: var(--card); font-size: 16px; font-weight: 700; margin-top: 4px; }
.text-in:focus { outline: none; box-shadow: 3px 3px 0 var(--accent); }
.set-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 4px; border: 0; border-top: 2px solid var(--line-soft); background: none; text-align: left; cursor: pointer; }
.set-row:first-of-type { border-top: 0; }
.set-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.set-ico { width: 40px; height: 40px; border-radius: 12px; background: var(--bg-2); border: 2px solid var(--ink); display: grid; place-items: center; font-size: 18px; flex: none; }
.set-txt { flex: 1; min-width: 0; display: grid; }
.set-txt b { font-weight: 800; }
.set-txt span { color: var(--muted); font-size: 13px; }
.set-row.danger b { color: var(--red); }
.set-row .arrow { font-weight: 900; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; }
.seg-btn { display: grid; place-items: center; padding: 9px 4px; border-radius: 14px; border: 2px solid var(--ink); background: var(--card); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; font-weight: 800; }
.seg-btn b { font-family: var(--display); font-size: 16px; font-weight: 800; line-height: 1.3; }
.seg-btn span { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.seg-btn.on { background: #17161C; color: var(--lime); }
.seg-btn.on span { color: #fff; }
.seg-btn[data-k="size"][data-v="small"] b { font-size: 13px; }
.seg-btn[data-k="size"][data-v="large"] b { font-size: 21px; }
.switch { width: 52px; height: 30px; border-radius: 999px; background: var(--bg-2); border: 2px solid var(--ink); position: relative; flex: none; transition: background .2s; }
.switch i { position: absolute; top: 2px; left: 2px; width: 22px; height: 22px; border-radius: 50%; background: #FFFDF9; border: 2px solid #17161C; transition: left .2s; }
.switch.on { background: var(--accent); }
.switch.on i { left: 24px; }
.goal-card .goal-top, .goal-card .goal-bottom { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.goal-card .bar { margin: 10px 0 8px; }
.goal-card .goal-bottom { font-weight: 800; font-size: 14px; color: var(--muted); }
.streak { display: inline-flex; align-items: center; gap: 4px; font-weight: 900; font-size: 13px; padding: 3px 10px; border-radius: 999px; background: var(--bg-2); border: 2px solid var(--ink); }
.streak.on { background: var(--coral); color: #17161C; }
:root[data-size="small"] .app { zoom: .9; }
:root[data-size="large"] .app { zoom: 1.12; }

.auth-hero { text-align: center; margin: 18px 0 8px; }
.auth-logo { width: 76px; height: 76px; margin: 0 auto 12px; border-radius: 24px; display: grid; place-items: center; font-size: 38px; background: var(--lime); border: 2px solid var(--ink); box-shadow: var(--shadow); }
.auth-card { max-width: 440px; margin: 0 auto 16px; }
.auth-card .text-in { margin: 4px 0 12px; }
.google-btn { gap: 12px; }
.or { display: flex; align-items: center; gap: 12px; margin: 18px 0 14px; color: var(--muted); font-size: 13px; font-weight: 800; }
.or::before, .or::after { content: ""; flex: 1; height: 2px; background: var(--line-soft); }
.auth-err { margin: 2px 0 0; padding: 10px 12px; border-radius: 12px; background: var(--red-soft); border: 2px solid var(--red); color: var(--red); font-weight: 700; font-size: 14px; }
.auth-switch { text-align: center; font-weight: 700; color: var(--muted); }

/* ---------- Flashcards ---------- */
.today-cards { background: var(--lime); color: #17161C; }
.today-cards .muted { color: #17161C; opacity: .75; }
.tc-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; margin-bottom: 14px; }
.tc-row b { display: block; font-family: var(--display); font-size: 28px; font-weight: 800; }
.tc-row span { font-size: 12px; font-weight: 800; opacity: .7; }
.deck .txt { display: grid; gap: 4px; }
.deck-lv { font-family: var(--display); font-weight: 800; font-size: 13px !important; background: var(--yellow) !important; color: #17161C; }
.deck-bar { display: block; height: 10px; margin: 2px 0 0; }
.deck .due { color: var(--coral); }
.flash { min-height: 320px; display: flex; flex-direction: column; justify-content: center; padding: 24px; box-shadow: var(--shadow-lg); position: relative; }
.flash-top { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; margin-bottom: 18px; }
.pill-sm { font-size: 11.5px; font-weight: 800; padding: 3px 10px; border-radius: 999px; background: var(--bg); border: 2px solid var(--ink); }
.pill-sm.new { background: var(--lime); color: #17161C; }
.flash-word { font-family: var(--display); font-size: 36px; font-weight: 800; text-align: center; line-height: 1.15; margin-bottom: 12px; overflow-wrap: anywhere; }
.flash-back { border-top: 2px dashed var(--ink); margin-top: 18px; padding-top: 18px; text-align: center; animation: fadein .25s; }
.flash-ka { font-size: 24px; font-weight: 900; color: var(--accent); margin-bottom: 12px; }
.flash-ex { font-size: 16px; display: flex; gap: 8px; align-items: center; justify-content: center; flex-wrap: wrap; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.grades { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.gbtn { display: grid; gap: 2px; padding: 10px 4px; border-radius: 14px; border: 2px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); cursor: pointer; text-align: center; color: var(--ink); }
.gbtn:active { transform: translate(2px, 2px); box-shadow: none; }
.gbtn b { font-size: 12.5px; font-weight: 900; }
.gbtn span { font-size: 11px; font-weight: 800; opacity: .7; }
.gbtn.again { background: var(--red-soft); }
.gbtn.hard { background: var(--yellow-soft); }
.gbtn.good { background: var(--green-soft); }
.gbtn.easy { background: var(--blue-soft); }

/* ---------- Dark theme ---------- */
:root[data-theme="dark"] {
  --bg: #121117; --bg-2: #24222C; --card: #1C1B22; --ink: #F1EDE4; --muted: #A39E95; --line: #F1EDE4; --line-soft: #34313C;
  --accent: #8B78FF; --accent-soft: #2B2550; --green-soft: #173823; --red-soft: #45191B; --yellow-soft: #3B3315; --blue-soft: #172A4A;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    --bg: #121117; --bg-2: #24222C; --card: #1C1B22; --ink: #F1EDE4; --muted: #A39E95; --line: #F1EDE4; --line-soft: #34313C;
    --accent: #8B78FF; --accent-soft: #2B2550; --green-soft: #173823; --red-soft: #45191B; --yellow-soft: #3B3315; --blue-soft: #172A4A;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] .hero { background: #24222C; }
:root[data-theme="dark"] :is(.pill.on, .seg-btn.on, .task-tab.on, .tabbar a.on) { background: var(--lime); color: #17161C; }
:root[data-theme="dark"] :is(.seg-btn.on span, .task-tab.on .cnt) { color: #17161C; }
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] .hero { background: #24222C; }
  :root[data-theme="auto"] :is(.pill.on, .seg-btn.on, .task-tab.on, .tabbar a.on) { background: var(--lime); color: #17161C; }
  :root[data-theme="auto"] :is(.seg-btn.on span, .task-tab.on .cnt) { color: #17161C; }
}
.hero .btn-row > .btn { flex: 0 1 auto; white-space: nowrap; }
@media (max-width: 420px) { .hero .btn-row > .btn { flex: 1 1 100%; } }
.em { display: inline-flex; vertical-align: -0.18em; line-height: 1; }
.em .ic { width: 1.15em; height: 1.15em; }
.big-emoji .ic { width: 72px; height: 72px; stroke-width: 1.6; color: var(--accent); }
.spk .ic { width: 18px; height: 18px; }
.spk.big .ic { width: 46px; height: 46px; }
.spk.slow .ic { width: 28px; height: 28px; }
.set-ico .ic { width: 20px; height: 20px; }

/* =========================================================================
   v2 · calmer pass — bold styling only where it matters
   (previous version saved in design-versions/v1-neobrutal)
   ========================================================================= */
/* 1. Hard shadows only on things you can press; containers are flat */
.card, .stat, div.result-row { box-shadow: none; }
.card.flash { box-shadow: var(--shadow-lg); }
.essay-box { box-shadow: none; }
.essay-box:focus { box-shadow: 3px 3px 0 var(--accent); }
.row-link, .opt, .tile, .seg-btn, .mbtn, .wtile, .gbtn, .letter, .pill, .spk { box-shadow: 2px 2px 0 var(--ink); }

/* 2. No box-in-box: inner rows are plain */
.task-table div { border: 0; background: var(--bg); }
.card .task-table { margin: 12px 0; }
.fold > summary { cursor: pointer; list-style: none; display: flex; flex-direction: column; gap: 2px; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::after { content: "+"; position: absolute; right: 18px; top: 14px; font-family: var(--display); font-weight: 800; font-size: 20px; }
.fold[open] > summary::after { content: "–"; }
.fold { position: relative; }

/* 3. Home: smaller mountains on phones, so the tiles come sooner */
@media (max-width: 639px) {
  .hero { padding: 20px 18px 0; }
  .hero h1 { font-size: 30px; }
  .hero .lead { font-size: 15px; margin-bottom: 18px; }
  .hero .art { max-width: 230px; margin: 4px -14px -4px auto; }
}

/* 4. No dot pattern while doing an exercise, test or cards — nothing to distract */
body.running, body.lesson-run { background-image: none; }

/* 6. Course units fold; the current one is open */
.unit { margin-bottom: 10px; border: 2px solid var(--ink); border-radius: var(--radius-sm); background: var(--card); }
.unit > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.unit > summary::-webkit-details-marker { display: none; }
.unit .u-no { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border-radius: 10px; border: 2px solid var(--ink); font-family: var(--display); font-weight: 800; font-size: 14px; background: var(--bg); }
.unit[open] .u-no { background: var(--sec, var(--accent)); color: #fff; }
.unit .u-txt { flex: 1; min-width: 0; display: grid; }
.unit .u-txt b { font-weight: 800; }
.unit .u-txt span { font-size: 12.5px; color: var(--muted); font-weight: 700; }
.unit .u-bar { width: 56px; height: 8px; flex: none; border-radius: 999px; border: 2px solid var(--ink); overflow: hidden; background: var(--bg); }
.unit .u-bar i { display: block; height: 100%; background: var(--sec, var(--accent)); }
.unit > .list { padding: 0 12px 12px; }
.unit .row-link { box-shadow: none; border-width: 2px; border-color: var(--line-soft); }
.unit .row-link:hover { border-color: var(--ink); transform: none; box-shadow: 2px 2px 0 var(--ink); }

/* 7. The lesson's start button stays visible while reading */
.sticky-cta { position: sticky; bottom: calc(var(--tabbar-h) + 20px); z-index: 4; margin-top: 18px; }

/* 8. One colour per section, repeated on its pages */
body { --sec: var(--accent); }
body[data-section="learn"] { --sec: var(--accent); }
body[data-section="cards"] { --sec: #9BC21F; }
body[data-section="tests"] { --sec: var(--coral); }
body[data-section="practice"] { --sec: #3AA6E8; }
body[data-section="progress"] { --sec: #E8B100; }
.page-title { display: flex; align-items: center; gap: 12px; }
.page-title::before { content: ""; flex: none; width: 12px; height: 1.05em; border-radius: 6px; background: var(--sec); border: 2px solid var(--ink); }
.hero h1, .auth-hero .page-title { display: block; }
.auth-hero .page-title::before, .hero h1::before { display: none; }
.bar > i, .deck-bar > i { background: var(--sec); }
.goal-card .bar > i { background: var(--accent); }

/* 9. Exercise screens: a little larger and airier */
.ex-card { padding: 22px 18px; }
.ex-prompt { font-size: 22px; }
.ex-card .opt { padding: 14px 16px; font-size: 17px; }
.q-text { font-size: 17px; }

/* 10. Consistent rhythm */
.section-title { margin: 28px 0 12px; }
.lead { margin-bottom: 20px; }
.list { gap: 10px; }

/* =========================================================================
   v3 — mtavruli headings, 5-tab dock / desktop sidebar, results, empty states
   (previous versions: design-versions/v1-neobrutal, v2-calm)
   ========================================================================= */
/* 1. (mtavruli headings were tried and dropped: Noto Sans Georgian draws mtavruli almost like mkhedruli) */
.hero h1 { font-size: 30px; line-height: 1.12; }
.page-title { font-size: 26px; }
@media (max-width: 380px) { .hero h1 { font-size: 26px; } .page-title { font-size: 22px; } }

/* 2. Five tabs → roomier labels */
.tabbar a { font-size: 11.5px; letter-spacing: 0; }
.tabbar a .ic { width: 23px; height: 23px; }
@media (max-width: 380px) { .tabbar a { font-size: 10.5px; } }

/* Profile header (progress page) */
.profile-head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.profile-head > div { flex: 1; min-width: 0; }
.profile-head .page-title { margin-bottom: 2px; }
.profile-head .page-title::before { display: none; }

/* 5. Empty state */
.empty-state { text-align: center; padding: 22px 18px; }
.empty-state .art { width: 130px; margin: 0 auto 6px; display: block; }
.empty-state h2 { font-size: 16px; font-weight: 900; }
.empty-state .btn-row { justify-content: center; margin-top: 14px; }

/* 4. Results: a celebratory card, the ring fills up */
@property --p { syntax: "<number>"; inherits: false; initial-value: 0; }
.score-ring { animation: ringfill 1.1s cubic-bezier(.2,.8,.2,1) both; }
@keyframes ringfill { from { --p: 0; } }
.card.celebrate { background: var(--lime); color: #17161C; box-shadow: var(--shadow-lg); }
.card.celebrate .muted { color: #17161C; opacity: .75; }
.card.celebrate .score-ring { border-color: #17161C; background: conic-gradient(#17161C calc(var(--p) * 1%), rgba(23,22,28,.12) 0); }
.card.celebrate .score-ring > div { background: #FFFDF9; border-color: #17161C; }
.card.celebrate .score-ring span { color: #6E6A63; }
.card.celebrate .stars { color: #17161C; }
.big-emoji .ic { color: var(--sec); }

/* 6. Tests: score colours + a bar per level */
.lvl-bar { height: 8px; margin: -4px 0 12px; }
.tile.done.hi { background: var(--lime); }
.tile.done.mid { background: var(--yellow); }
.tile.done.lo { background: var(--coral); }
.tile.progress { background: var(--card); border-style: dashed; }
.tile.progress .sub { color: var(--coral); }

/* 7. Lesson explanation: the first paragraph (the core rule) is a callout; comfortable line length */
.md { line-height: 1.7; }
.md > p, .md > ul, .md > ol { max-width: 68ch; }
.md > p:first-child { background: var(--accent-soft); border-left: 5px solid var(--sec); border-radius: 0 12px 12px 0; padding: 12px 14px; font-weight: 600; }

/* 3. Desktop: the dock becomes a left sidebar and the page gets wider */
@media (min-width: 1024px) {
  .app { max-width: 1120px; padding-left: 250px; }
  .tabbar {
    left: max(24px, calc(50% - 560px + 12px)); top: 24px; bottom: auto; transform: none;
    flex-direction: column; justify-content: flex-start; gap: 4px;
    width: 214px; max-width: none; padding: 14px 10px; border-radius: 24px;
  }
  .tabbar::before { content: "ეროვნული"; display: block; padding: 4px 12px 14px; font-family: var(--display); font-weight: 800; font-size: 18px; text-transform: uppercase; letter-spacing: .02em; border-bottom: 2px solid var(--line-soft); margin-bottom: 8px; }
  .tabbar a { flex: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 11px 14px; font-size: 15px; }
  .tabbar a span:last-child { overflow: visible; }
  .view { padding: 32px 24px 48px; }
  .runner-head { margin: -32px -24px 18px; padding: 14px 24px 12px; }
  .toast { bottom: 28px; }
  .bento { grid-template-columns: repeat(3, 1fr); }
  .tile-b { min-height: 190px; }
  .tile-grid { grid-template-columns: repeat(10, 1fr); }
  .hero h1 { font-size: 38px; }
  .page-title { font-size: 30px; }
  .sticky-cta { bottom: 24px; }
  body.running .app, body.lesson-run .app { padding-left: 0; max-width: 820px; }
  .lfoot { max-width: 820px; }
}

/* ---------- Retelling (მოყოლა ხმით) ---------- */
.rt-head { display: flex; align-items: center; gap: 10px; margin: 12px 0 8px; }
.rt-head .page-title { margin: 0; }
.rt-head .pill { cursor: default; }
.rt-text { font-size: 18px; line-height: 1.75; }
.rt-sub { font-family: var(--display); font-size: 18px; margin: 20px 0 10px; }
.rt-words { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.rt-word { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; background: var(--card); border: 2px solid var(--line-soft); border-radius: 14px; }
.rt-word span { color: var(--muted); font-size: 14px; }
.rt-lastbtn { width: 100%; margin-top: 16px; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.rec-card { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 26px 18px; }
.rec-btn { width: 92px; height: 92px; border-radius: 50%; border: 3px solid var(--ink); background: var(--coral); color: #17161C; box-shadow: var(--shadow); font-size: 36px; cursor: pointer; display: grid; place-items: center; }
.rec-btn:active { transform: translate(2px, 2px); box-shadow: none; }
.rec-btn.on { background: var(--red); color: #fff; animation: rec-pulse 1.4s infinite; }
@keyframes rec-pulse { 0% { box-shadow: 0 0 0 0 rgba(229,56,59,.5); } 70% { box-shadow: 0 0 0 18px rgba(229,56,59,0); } 100% { box-shadow: 0 0 0 0 rgba(229,56,59,0); } }
.rec-time { font-variant-numeric: tabular-nums; font-size: 18px; }
.rec-live { width: 100%; min-height: 64px; max-height: 170px; overflow: auto; text-align: left; padding: 10px 12px; border: 2px dashed var(--line-soft); border-radius: 12px; color: var(--muted); font-size: 15px; }
.rec-live:empty::before { content: "აქ გამოჩნდება, რასაც ბრაუზერი გაიგებს…"; font-style: italic; }
.rt-details summary { cursor: pointer; font-weight: 800; }
.rt-details p { line-height: 1.65; }
.rt-wait { display: flex; gap: 14px; align-items: center; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--line-soft); border-top-color: var(--accent); animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.rt-score { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.rt-big { width: 112px; height: 112px; flex: none; border-radius: 50%; display: grid; place-content: center; text-align: center; position: relative; border: 2px solid var(--ink); background: conic-gradient(var(--green) calc(var(--p) * 1%), var(--line-soft) 0); }
.rt-big::before { content: ""; position: absolute; inset: 12px; border-radius: 50%; background: var(--card); border: 2px solid var(--ink); }
.rt-big b, .rt-big span { position: relative; }
.rt-big b { font-family: var(--display); font-size: 32px; line-height: 1; }
.rt-big span { font-size: 13px; color: var(--muted); }
.rt-parts { flex: 1 1 210px; display: grid; gap: 9px; }
.rt-part { display: grid; grid-template-columns: 92px 1fr 34px; align-items: center; gap: 10px; font-size: 14px; }
.rt-part .bar { margin: 0; }
.rt-summary { font-size: 16px; line-height: 1.6; margin: 0 0 16px; }
.rt-box h3, .rt-h3 { font-family: var(--display); font-size: 16px; margin: 0 0 8px; }
.rt-box ul { margin: 0; padding-left: 20px; display: grid; gap: 5px; }
.rt-box.good { background: var(--green-soft); }
.rt-box.warn { background: var(--yellow-soft); }
.rt-mistake { padding: 9px 0; border-top: 1px solid var(--line-soft); }
.rt-mistake:first-of-type { border-top: 0; padding-top: 0; }
.rt-mistake s { color: var(--red); }
.rt-mistake b { color: var(--green-dark); }
.rt-mistake p { margin: 4px 0 0; }
@media (max-width: 420px) { .rt-part { grid-template-columns: 80px 1fr 32px; } .rt-text { font-size: 17px; } }

/* Flashcards: choose the meaning from four answers */
.cards-run .card.flash { min-height: 0; padding: 20px 20px 22px; }
.fc-opts { margin: 4px 0 20px; }
.fc-opts .opt { font-family: var(--font); font-weight: 700; }
.opt.dim { opacity: .45; }
.opt:disabled { cursor: default; }
.opt:disabled:hover { transform: none; box-shadow: 2px 2px 0 var(--ink); }
.grades.three { grid-template-columns: repeat(3, 1fr); }
.fc-verdict { margin: 0 0 10px; font-weight: 800; text-align: center; }
