/* Thimoli's level-zero adventure, sharing the established palette and type. */
.quest-models.quest-models-visual article{grid-template-columns:64px minmax(0,1fr) 44px;gap:8px 12px}
.quest-models-visual .quest-model-picture{grid-column:1;grid-row:1/3;width:64px;height:64px}
.quest-models.quest-models-visual article>strong{grid-column:2;grid-row:1;font-size:1.2rem;text-align:left;line-height:1.9}
.quest-models-visual article>span{grid-column:2;grid-row:2}
.quest-models-visual article>button{grid-column:3;grid-row:1/3}
.quest-finish>.secondary{width:100%;margin:12px 0;min-height:48px}
.quest-home-heading { margin: 20px 0 14px; }
.quest-home-heading h1 { margin: 5px 0; font: 800 1.9rem/1.15 var(--font-display); }
.quest-home-heading .eyebrow, .quest-kicker { font-size: .75rem; color: #a54324; font-weight: 900; letter-spacing: .055em; }
.quest-hero { position: relative; display: grid; grid-template-columns: minmax(0,1fr) 82px; gap: 12px 4px; padding: 22px 18px 16px; border: 1px solid #f4caa9; border-radius: 28px; background: linear-gradient(130deg,#fff0d9,#fff8ec 55%,#fbe6d7); box-shadow: 0 12px 25px #b15e2810; }
.quest-kicker span { color: var(--ink-2); letter-spacing: 0; }
.quest-hero h2 { margin: 8px 0 12px; font: 800 1.6rem/1.12 var(--font-display); }
.quest-hero-copy { min-width: 0; }
.quest-hero-copy p { margin: 12px 0 0; font-size: .875rem; line-height: 1.4; color: var(--ink-2); }
.quest-hero-mascot { align-self: center; width: 90px; max-width: 100%; height: 145px; object-fit: contain; filter: drop-shadow(0 8px 8px #734c2320); }
.quest-hero-signs { display: flex; flex-wrap: wrap; gap: 6px; font-family: var(--font-tamil); }
.quest-hero-signs > span { display: inline-flex; min-width: 52px; min-height: 54px; align-items: center; justify-content: center; padding: 5px 8px; background: #fffaf4; border: 1px solid #ecd7bf; border-radius: 14px; color: var(--ink); font-size: 1.35rem; line-height: 1.7; white-space: nowrap; }
.quest-hero > .primary { grid-column: 1/-1; margin: 2px 0 0; min-height: 52px; font-size: 1.125rem; }
.quest-journey-progress { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin: 20px 2px; font-size: .875rem; color: var(--ink-2); }
.quest-journey-progress > span { color: #8b6619; font-weight: 900; }
.quest-journey-progress .bar { grid-column: 1/-1; margin: 0; height: 7px; }
.quest-journey-progress .bar span { background: var(--green); }
.quest-chapters { display: grid; gap: 12px; }
.quest-chapter { border: 1px solid #e0e9e1; border-radius: 22px; background: #fcfefb; overflow: hidden; }
.quest-chapter:nth-child(2) { border-color: #dce6ed; background: #fafdff; }
.quest-chapter:nth-child(3) { border-color: #e7dff0; background: #fdfbff; }
.quest-chapter summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px; cursor: pointer; list-style: none; }
.quest-chapter summary::-webkit-details-marker, .quest-library summary::-webkit-details-marker { display: none; }
.quest-chapter summary > span { display: grid; gap: 4px; }
.quest-chapter summary small { font-size: .75rem; color: #467d60; font-weight: 900; }
.quest-chapter summary strong { font: 800 1.125rem/1.2 var(--font-display); }
.quest-chapter summary > b { font-size: 1.4rem; }
.quest-chapter[open] summary > b { transform: rotate(45deg); }
.quest-chapter ol { list-style: none; padding: 0 12px 12px; margin: 0; }
.quest-chapter li + li { margin-top: 6px; }
.quest-stop { display: grid; grid-template-columns: 38px minmax(0,1fr) 16px; align-items: center; width: 100%; gap: 10px; padding: 13px 8px; border: 1px solid transparent; border-radius: 15px; background: transparent; text-align: left; color: var(--ink); cursor: pointer; }
.quest-stop > span:nth-child(2) { display: grid; gap: 4px; }
.quest-stop strong { font-size: .9375rem; line-height: 1.3; }
.quest-stop small { font-size: .75rem; color: var(--ink-2); line-height: 1.4; }
.quest-stop-number { display: grid; place-items: center; width: 38px; height: 42px; border-radius: 13px; background: #e8eee8; color: #536355; font-weight: 900; }
.quest-stop.is-current { border-color: #f4c6ae; background: #fff6ee; }
.quest-stop.is-current .quest-stop-number { background: var(--orange); color: white; box-shadow: 0 4px 0 #dc5327; }
.quest-stop.is-complete .quest-stop-number { background: var(--green-soft); color: #267c51; }
.quest-stop:disabled { opacity: .65; cursor: default; }
.quest-library { margin: 22px 0 0; border-top: 1px solid var(--line); }
.quest-library summary { display: grid; gap: 4px; padding: 18px 4px; cursor: pointer; list-style: none; }
.quest-library summary > span { font-size: 1rem; font-weight: 900; }
.quest-library summary small { font-size: .8125rem; color: var(--ink-2); }
.quest-library > div { display: grid; }
.quest-library button { display: flex; justify-content: space-between; padding: 16px 8px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); text-align: left; font-size: 1rem; cursor: pointer; }
.quest-play-head { display: grid; grid-template-columns: 44px 1fr auto; gap: 14px; align-items: center; margin: 12px 0 26px; }
.quest-play-head .icon-button { width: 44px; height: 44px; }
.quest-play-head .bar { margin: 0; }
.quest-play-head > span { font-size: .875rem; font-weight: 900; }
.quest-play > h1 { margin: 8px 0 12px; font: 800 1.9rem/1.2 var(--font-display); }
.quest-play > .eyebrow { font-size: .75rem; }
.quest-instruction { margin: 0 0 22px; font-size: 1rem; line-height: 1.5; color: var(--ink-2); }
.quest-models { display: grid; gap: 10px; margin-bottom: 24px; }
.quest-models article { display: grid; grid-template-columns: minmax(60px,.7fr) 1fr 44px; gap: 12px; align-items: center; padding: 18px 12px; background: #fff; border: 1px solid var(--line); border-radius: 22px; }
.quest-models article > strong { font: 700 1.5rem/1.6 var(--font-tamil); overflow-wrap: anywhere; text-align: center; }
.quest-models article > span { font-size: .875rem; color: var(--ink-2); }
.quest-models button { display: grid; width: 44px; height: 44px; place-items: center; border: 0; border-radius: 50%; background: var(--blue-soft); color: var(--blue); cursor: pointer; }
.quest-models .sound-svg, .quest-listen .sound-svg { width: 24px; height: 24px; }
.quest-memory { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.quest-memory button { min-width: 0; min-height: 96px; padding: 9px; border: 1px solid #ead1b2; border-bottom-width: 4px; border-radius: 18px; background: #fff3df; color: #ad6a39; cursor: pointer; }
.quest-memory button > span { font-size: 1.65rem; line-height: 1.7; white-space: nowrap; }
.quest-memory .is-revealed { background: white; color: var(--ink); border-color: #cddde6; }
.quest-memory .is-paired { background: var(--green-soft); color: #267c51; border-color: #a6d4b6; opacity: 1; }
.quest-memory .is-wrong { background: #fff0ec; color: #b84232; border-color: #e36f61; animation: quest-wrong-shake .28s ease-in-out 2; }
.quest-memory-count { text-align: center; font-size: .875rem; color: var(--ink-2); margin: 18px 0 0; }
.quest-memory-count.is-wrong { color: #a73c30; font-weight: 800; }
.quest-memory-words { grid-template-columns: repeat(2,minmax(0,1fr)); }
.quest-memory + .secondary { width: 100%; margin-top: 12px; font-size: .875rem; }
.quest-listen { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; min-height: 64px; margin: 0 0 18px; border: 1px solid #bddbec; border-radius: 20px; background: var(--blue-soft); color: var(--ink); font-size: 1rem; font-weight: 800; cursor: pointer; }
.quest-feedback { display: grid; grid-template-columns: 56px minmax(0,1fr); gap: 12px; margin: 18px 0; padding: 14px; border-radius: 20px; background: var(--green-soft); }
.quest-feedback.wrong { background: #fff0de; }
.quest-feedback img { width: 56px; height: 70px; object-fit: contain; }
.quest-feedback strong { font-size: 1rem; }
.quest-feedback p { margin: 5px 0 0; font-size: .875rem; line-height: 1.5; }
.quest-help { margin-top: 22px; color: var(--ink-2); font-size: .875rem; }
.quest-help summary { padding: 12px 0; cursor: pointer; }
.quest-help p { margin: 10px 0; }
.quest-help [lang="ta"] { font-size: 1.25rem; line-height: 1.6; }
.quest-finish { text-align: center; }
.quest-finish-mascot { display: block; width: 140px; height: 180px; object-fit: contain; margin: 20px auto; }
.quest-stars { margin: 16px 0; color: #b68018; font-size: 2.4rem; letter-spacing: .08em; }
.quest-reward { font-size: 1.25rem; font-weight: 900; color: #2c865b; }
.quest-play .primary { font-size: 1.05rem; }

/* Generous native-script cells, never Latin-sized boxes. */
.page-alphabet .alphabet-grid-clean, .page-alphabet .syllable-grid, .writing-picker, .pronunciation-letter-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.page-alphabet .alphabet-grid-clean button, .page-alphabet .syllable-cell, .writing-picker button, .pronunciation-letter-grid button { min-width: 0; min-height: 82px; padding: 12px 8px; border: 1px solid var(--line); border-radius: 17px; background: white; color: var(--ink); }
.page-alphabet .alphabet-grid-clean button strong, .page-alphabet .syllable-cell strong, .writing-picker strong, .pronunciation-letter-grid strong { display: block; font: 700 1.45rem/1.7 var(--font-tamil); white-space: nowrap; }
.page-alphabet .alphabet-grid-clean button small { display:block; margin-top:2px; color:var(--ink-2); font-size:.78rem; font-weight:800; letter-spacing:.01em; }
.page-alphabet .alphabet-focus { grid-template-columns: minmax(112px,.8fr) minmax(0,1fr); }
.page-alphabet .alphabet-focus-letter span { font-size: 2.5rem; line-height: 1.7; white-space: nowrap; }
.page-practice .practice-head { grid-template-columns: 44px minmax(0,1fr); gap: 10px; align-items: start; }
.page-practice .practice-head .icon-button { width: 44px; height: 44px; }
.page-practice .practice-head > div { min-width: 0; }
.page-practice .practice-head h1 { font-size: 1.65rem; line-height: 1.2; }
.page-practice .practice-head p { font-size: .875rem; line-height: 1.5; }
.page-practice .practice-head .eyebrow { font-size: .75rem; }
.page-practice .practice-progress { grid-column: 2; justify-self: start; font-size: .75rem; }
.page-practice .practice-tip { font-size: .875rem; line-height: 1.5; }
.page-practice .alphabet-focus-letter small, .page-practice .alphabet-focus p { font-size: .875rem; line-height: 1.5; }
.page-alphabet .practice-tabs button { font-size: .875rem; min-height: 54px; padding: 9px 4px; }
.page-alphabet .syllable-cell small { font-size: .875rem; }
.writing-choose { margin: 12px 0 20px; }
.writing-choose summary { padding: 15px; border-radius: 16px; background: var(--green-soft); color: var(--ink); cursor: pointer; font-size: 1rem; font-weight: 800; }
.writing-picker { margin-top: 12px; max-height: 310px; overflow-y: auto; padding: 4px; }
.writing-picker button { cursor: pointer; }
.writing-picker button.active { border: 2px solid var(--green); background: var(--green-soft); }
.writing-family-select { display: grid; gap: 8px; margin: 14px 0; font-size: .875rem; }
.writing-family-select select { width: 100%; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: white; font: 1rem var(--font-tamil); color: var(--ink); }
.page-writing .writing-level-strip button { min-width: 92px; }
.page-writing .writing-level-strip button span { font-size: .8125rem; line-height: 1.3; }
.page-writing .writing-level-strip button strong { font-size: 1rem; }
.writing-practice-note { font-size: .875rem; color: var(--ink-2); line-height: 1.5; }
.writing-next { width: 100%; margin-top: 14px; }
.page-writing .writing-letter-nav > span { max-width: 100%; overflow-wrap: anywhere; line-height: 1.6; }
.pronunciation-library { margin-top: 24px; }
.pronunciation-library summary { padding: 15px 0; font-size: 1rem; font-weight: 900; cursor: pointer; }
.pronunciation-letter-grid button { cursor: pointer; }
.pronunciation-letter-grid small { display: block; font-size: .875rem; color: var(--ink-2); }
.audio-notice { position: fixed; z-index: 60; bottom: calc(var(--nav-height) + var(--safe-bottom) + 12px); left: 50%; transform: translateX(-50%); width: min(380px,calc(100% - 32px)); padding: 14px 16px; border: 1px solid #f0cca7; border-radius: 16px; background: #fff7e9; color: var(--ink); font-size: .875rem; line-height: 1.5; box-shadow: var(--shadow-md); }
.audio-notice:empty { display: none; }
.audio-is-active { outline: 3px solid var(--green) !important; outline-offset: 2px; background-color: var(--green-soft) !important; }
[data-speak][aria-busy="true"] { cursor: progress; }
.quest-audio-model { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.quest-audio-model p { min-width: 0; }
.quest-audio-model button, .letter-speaker { flex: 0 0 44px; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: #fff; color: var(--ink); display: inline-grid; place-items: center; cursor: pointer; }
.quest-audio-model button svg, .letter-speaker svg { width: 20px; height: 20px; }
.quest-play button:focus-visible, .quest-chapter button:focus-visible, .quest-library button:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
@media (max-width: 360px) { .quest-hero { grid-template-columns: minmax(0,1fr) 62px; padding: 18px 14px; } .quest-hero-mascot { height: 120px; } .quest-hero-signs > span { min-width: 42px; padding: 4px; font-size: 1.1rem; } .quest-memory { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (prefers-reduced-motion: reduce) { .quest-play *, .page-foundation-quests * { scroll-behavior: auto; transition: none !important; } }

/* Preschool home: a calm, touch-first entry point inspired by classroom exercise families. */
.preschool-home { padding-bottom: 112px; }
.preschool-welcome { display:grid;grid-template-columns:minmax(0,1fr) 86px;align-items:center;gap:10px;margin:18px 0 14px;padding:0 4px; }
.preschool-welcome h1 { margin:5px 0 4px;font:800 1.85rem/1.08 var(--font-display); }
.preschool-welcome p { margin:0;color:var(--ink-2);font-size:.9rem;line-height:1.45; }
.preschool-welcome .eyebrow { color:#a54324;font-size:.72rem;letter-spacing:.06em; }
.preschool-welcome-mascot { width:86px;height:112px;object-fit:contain;filter:drop-shadow(0 8px 9px #785a3720); }
.preschool-today { position:relative;display:block;overflow:hidden;padding:17px;border:1px solid #f2c9a8;border-radius:28px;background:linear-gradient(145deg,#fff0d7 0%,#fffaf0 58%,#fde5d7 100%);box-shadow:0 12px 28px #9e5d2814; }
.preschool-today::before { content:"";position:absolute;right:-34px;top:-48px;width:130px;height:130px;border-radius:50%;background:#ffd77b55; }
.preschool-today-top { position:relative;display:flex;align-items:flex-start;justify-content:space-between;gap:10px; }
.preschool-today-top>span { display:grid;gap:3px; }
.preschool-today-top small { color:#a54324;font-size:.7rem;font-weight:900;letter-spacing:.06em; }
.preschool-today-top strong { color:var(--ink-2);font-size:.76rem; }
.preschool-today-top>b { padding:6px 9px;border-radius:999px;background:#fff9ec;color:#9a6b0e;font-size:.78rem; }
.preschool-today-body { position:relative;display:grid;grid-template-columns:minmax(0,1fr) 72px;align-items:center;gap:8px;margin-top:13px; }
.preschool-today h2 { margin:5px 0 10px;font:800 1.45rem/1.12 var(--font-display); }
.preschool-today .quest-hero-signs>span { min-width:45px;min-height:46px;background:#fffdf8;font-size:1.18rem; }
.preschool-today-mascot { width:76px;height:112px;object-fit:contain; }
.preschool-today>.primary { position:relative;width:100%;min-height:52px;margin-top:12px;font-size:1.05rem; }
.preschool-progress { display:grid;gap:8px;margin:15px 2px 22px;padding:12px 14px;border-radius:18px;background:#f5f1ea; }
.preschool-progress>div { display:flex;justify-content:space-between;gap:10px;font-size:.8rem; }
.preschool-progress>div span { color:var(--ink-2);font-weight:800; }
.preschool-progress .bar { height:7px;margin:0; }
.preschool-progress .bar span { background:linear-gradient(90deg,#50a878,#7cc995); }
.preschool-section-title { display:flex;align-items:end;justify-content:space-between;gap:12px;margin-bottom:12px;padding:0 3px; }
.preschool-section-title h2 { margin:3px 0 0;font:800 1.35rem/1.15 var(--font-display); }
.preschool-section-title .eyebrow { color:#467d60;font-size:.7rem; }
.preschool-section-title>span { color:var(--ink-2);font-size:.78rem;font-weight:800; }
.preschool-activity-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px; }
.preschool-activity { --activity:#e8863f;--activity-soft:#fff1de;display:grid;grid-template-columns:45px minmax(0,1fr);grid-template-rows:auto auto;align-items:center;gap:9px 10px;min-height:126px;padding:14px 12px;border:1px solid color-mix(in srgb,var(--activity) 24%,#fff);border-bottom-width:4px;border-radius:21px;background:linear-gradient(145deg,#fff 28%,var(--activity-soft));color:var(--ink);text-align:left;cursor:pointer; }
.preschool-activity-icon { display:grid;width:45px;height:45px;place-items:center;border-radius:15px;background:var(--activity-soft);color:var(--activity);font:900 1.25rem/1 var(--font-display); }
.preschool-activity>span:nth-child(2) { display:grid;gap:4px; }
.preschool-activity strong { font:800 1rem/1.1 var(--font-display); }
.preschool-activity small { color:var(--ink-2);font-size:.72rem;line-height:1.3; }
.preschool-activity>b { grid-column:1/-1;justify-self:end;color:var(--activity);font-size:1.2rem; }
.preschool-leaf { --activity:#4d9b6f;--activity-soft:#eaf7ee; }.preschool-sky { --activity:#3989b8;--activity-soft:#e9f6fc; }.preschool-berry { --activity:#8d63ad;--activity-soft:#f3ecf8; }.preschool-peach { --activity:#d86c50;--activity-soft:#fff0e9; }.preschool-mint { --activity:#2f948b;--activity-soft:#e7f7f4; }
.preschool-path { margin:22px 0 0;border:1px solid var(--line);border-radius:22px;background:var(--card);overflow:hidden; }
.preschool-path>summary { display:flex;align-items:center;justify-content:space-between;gap:12px;padding:17px;list-style:none;cursor:pointer; }
.preschool-path>summary::-webkit-details-marker { display:none; }
.preschool-path>summary>span { display:grid;gap:3px; }.preschool-path>summary small { color:#467d60;font-size:.68rem;font-weight:900;letter-spacing:.06em; }.preschool-path>summary strong { font-size:.95rem; }
.preschool-path>summary>b { font-size:1.3rem;transition:transform .2s ease; }.preschool-path[open]>summary>b { transform:rotate(45deg); }
.preschool-path-content { padding:0 10px 12px; }
.preschool-path .quest-chapter { border-radius:17px; }
.preschool-activity:focus-visible,.preschool-path summary:focus-visible { outline:3px solid var(--ink);outline-offset:3px; }
html[data-theme="dark"] .preschool-today { background:linear-gradient(145deg,#3b3029,#29352f);border-color:#654b37; }
html[data-theme="dark"] .preschool-progress { background:#2c302e; }
html[data-theme="dark"] .preschool-activity { background:linear-gradient(145deg,#302f2d,#282c2a);border-color:#4a504c; }
html[data-theme="dark"] .preschool-activity-icon { background:#263f36; }
@media (max-width:360px) { .preschool-welcome{grid-template-columns:minmax(0,1fr) 70px}.preschool-welcome-mascot{width:70px}.preschool-activity-grid{grid-template-columns:1fr}.preschool-activity{min-height:92px;grid-template-columns:45px minmax(0,1fr) 16px;grid-template-rows:auto}.preschool-activity>b{grid-column:3} }

/* Child-first home: one mission, three large choices, everything else folded away. */
.preschool-home .brandbar { margin-bottom:18px; }
.preschool-home .preschool-today { padding:19px 18px 15px; }
.preschool-home .preschool-today h1 { margin:5px 0 11px;font:800 1.65rem/1.08 var(--font-display); }
.preschool-home .preschool-today>.bar { position:relative;height:6px;margin:13px 2px 0;background:#eadfce; }
.preschool-home .preschool-today>.bar span { background:#53a276; }
.preschool-home .preschool-section-title { margin:22px 2px 12px; }
.preschool-home .preschool-section-title h2 { margin:0;font-size:1.18rem; }
.preschool-quick-grid { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px; }
.preschool-quick { --activity:#d4783f;--activity-soft:#fff0df;display:grid;justify-items:center;gap:8px;min-width:0;min-height:102px;padding:13px 7px 11px;border:1px solid color-mix(in srgb,var(--activity) 24%,#fff);border-bottom-width:4px;border-radius:20px;background:linear-gradient(150deg,#fff 20%,var(--activity-soft));color:var(--ink);cursor:pointer; }
.preschool-quick strong { font:800 .88rem/1.15 var(--font-display);text-align:center; }
.preschool-quick .preschool-activity-icon { width:48px;height:48px;border-radius:16px;font-size:1.3rem; }
.preschool-quick.preschool-sky { --activity:#3989b8;--activity-soft:#e9f6fc; }
.preschool-quick.preschool-peach { --activity:#d86c50;--activity-soft:#fff0e9; }
.preschool-home .preschool-path { margin-top:18px;box-shadow:none; }
.preschool-quick:focus-visible { outline:3px solid var(--ink);outline-offset:3px; }
html[data-theme="dark"] .preschool-quick { background:linear-gradient(145deg,#302f2d,#282c2a);border-color:#4a504c; }
html[data-theme="dark"] .preschool-home .preschool-today>.bar { background:#24343a; }

/* Original digital adaptations of recurring preschool worksheet mechanics. */
.foundation-illustrated .brandbar { margin-bottom:22px; }
.foundation-mission { position:relative;isolation:isolate;overflow:hidden;min-height:260px;padding:24px 20px 22px;border:1px solid #f3d8be;border-radius:28px;background:linear-gradient(145deg,#fff1dd,#fff8eb 58%,#fce3cc);box-shadow:0 8px 22px #8553270c; }
.foundation-mission::before { content:"";position:absolute;bottom:-74px;right:-32px;width:220px;height:150px;border-radius:50%;background:#f6c88c55;transform:rotate(-25deg);z-index:-1; }
.foundation-mission::after { content:"";position:absolute;top:-18px;left:-15px;width:49px;height:84px;border-radius:50%;background:#fff9f2a8;transform:rotate(39deg);z-index:-1; }
.foundation-mission-copy { position:relative;z-index:2;width:65%; }
.foundation-mission h1 { margin:0 0 10px;font:800 2.2rem/1.02 var(--font-display);letter-spacing:-.02em;color:var(--ink); }
.foundation-mission h2 { margin:0 0 5px;font:800 1.16rem/1.25 var(--font-body);color:var(--ink);max-width:90%;overflow-wrap:anywhere; }
.foundation-mission-time { display:block;font-size:.75rem;line-height:1.4;color:var(--ink-2); }
.foundation-mission-progress { display:flex;align-items:center;gap:7px;margin:18px 0 20px;padding:9px 10px 9px 7px;border-radius:15px;background:#fffaf4e6; }
.foundation-progress-star { width:21px;height:21px;color:#edb544;flex-shrink:0; }
.foundation-progress-star svg { display:block;width:100%;height:100%; }
.foundation-mission-progress .bar { flex:1;min-width:0;height:8px;margin:0;background:#e9e4da; }
.foundation-mission-progress .bar span { background:#54a780; }
.foundation-mission-progress b { flex-shrink:0;font-size:.8rem; }
.foundation-mission-copy>.primary { min-height:52px;padding:12px 14px;width:100%;display:flex;align-items:center;justify-content:space-between;gap:6px;font-size:1.03rem;border-radius:20px;box-shadow:0 6px 14px #e7733733; }
.foundation-mission-scene { position:absolute;z-index:1;right:-3px;bottom:0;width:43%;height:100%;pointer-events:none; }
.foundation-home-mascot { position:absolute;bottom:-36px;right:-14px;width:180px;max-width:none;height:267px;object-fit:contain;object-position:bottom;filter:drop-shadow(0 5px 6px #b26b2520); }
.foundation-mascot-halo { position:absolute;right:-20px;bottom:12px;width:164px;height:174px;border-radius:55% 45% 55% 45%;background:#f7cd7850;transform:rotate(-12deg); }
.foundation-mascot-sign { position:absolute;top:14px;right:16px;z-index:2;display:grid;place-items:center;width:54px;height:57px;border-radius:15px;background:#fffaf4;color:#db7445;font:800 1.65rem/1.5 var(--font-tamil);transform:rotate(9deg);box-shadow:0 3px 8px #9953250a; }
.foundation-scene-spark { position:absolute;top:53px;left:8px;width:19px;height:19px;color:#eeb244;transform:rotate(-12deg); }
.foundation-scene-spark svg { width:100%;height:100%; }
.foundation-illustrated .preschool-activities { margin-top:15px; }
.foundation-illustrated .preschool-quick-grid { gap:9px; }
.foundation-illustrated .preschool-quick { position:relative;overflow:hidden;display:flex;flex-direction:column;gap:0;padding:0;min-height:171px;border:1px solid #d8e8eb;border-bottom-width:3px;border-radius:23px;background:linear-gradient(145deg,#e6f1f7,#d5e9f1);box-shadow:0 4px 10px #51797708; }
.foundation-illustrated .preschool-mint { border-color:#d0e5d5;background:linear-gradient(145deg,#dfefdf,#cce7d8); }
.foundation-illustrated .preschool-peach { border-color:#f1dcc6;background:linear-gradient(145deg,#fff0dc,#fae1cb); }
.foundation-game-art { position:relative;display:block;width:100%;height:126px;flex:1;color:#294d64; }
.art-letter { position:absolute;display:grid;place-items:center;width:55px;height:62px;background:#fffaf4;border-radius:14px;font:800 1.8rem/1.4 var(--font-tamil);box-shadow:0 5px 9px #37546a10; }
.art-letter-main { top:18px;left:50%;transform:translateX(-50%) rotate(-7deg); }
.art-speaker { position:absolute;bottom:9px;left:16px;width:32px;height:32px;color:#5489ad; }
.art-speaker svg { width:100%;height:100%; }
.art-spark { position:absolute;color:#81a8c3; }
.art-spark-one { top:10px;left:10px;width:13px;height:13px;transform:rotate(-13deg); }
.art-spark svg { width:100%;height:100%; }
.art-letter-left { width:45px;height:53px;top:19px;left:10px;color:#d97650;transform:rotate(-11deg); }
.art-letter-right { width:45px;height:53px;top:37px;right:9px;color:#294d64;transform:rotate(10deg); }
.art-link,.foundation-game-art>svg.art-trace { position:absolute;inset:0;width:100%;height:100%; }
.art-letter-trace { top:16px;left:16px;width:66px;height:87px;transform:rotate(-5deg);align-items:start;padding-top:8px; }
.art-pencil { position:absolute;right:12px;bottom:11px;width:22px;height:68px;transform:rotate(28deg);filter:drop-shadow(1px 2px 2px #85532712); }
.foundation-illustrated .preschool-quick strong { display:grid;place-items:center;width:100%;min-height:44px;padding:10px 4px;background:#fffaf4e8;border-radius:18px 18px 0 0;font:800 1.04rem/1.15 var(--font-display);color:var(--ink); }
.foundation-illustrated .preschool-path { margin-top:16px;background:linear-gradient(135deg,#fff4e5,#fef8ef);border-color:#f1ddc6;border-radius:25px; }
.foundation-illustrated .preschool-path>summary { display:grid;grid-template-columns:40px minmax(0,1fr) 20px;column-gap:10px;row-gap:7px;padding:15px 18px 13px; }
.foundation-path-badge { display:grid;place-items:center;width:38px;height:38px;border-radius:14px;background:#f1b24b;color:#fffaf4;transform:rotate(-6deg); }
.foundation-path-badge svg { width:24px;height:24px; }
.foundation-illustrated .foundation-path-copy small { font-size:.62rem;color:#8d6839;letter-spacing:.04em; }
.foundation-illustrated .foundation-path-copy strong { font:800 1.22rem/1.12 var(--font-display); }
.foundation-illustrated .preschool-path>summary>b { grid-column:3;grid-row:1; }
.foundation-illustrated .foundation-mini-trail { position:relative;grid-column:1/-1;display:flex;justify-content:space-between;padding:2px 18px; }
.foundation-mini-trail::before { content:"";position:absolute;left:31px;right:31px;top:18px;height:4px;border-radius:3px;background:#e7dfd3; }
.foundation-mini-trail>span { position:relative;display:grid;place-items:center;width:34px;height:34px;border:3px solid #fff7ed;border-radius:50%;background:#e7dfd3;color:#fffcf7; }
.foundation-mini-trail svg { width:18px;height:18px; }
.foundation-mini-trail>.is-current { background:#ef996b; }
.foundation-mini-trail>.is-complete { background:#62a881; }
.foundation-illustrated .foundation-path-caption { grid-column:1/-1;display:block;text-align:center;font-size:.75rem;color:var(--ink-2); }
html[data-theme="dark"] .foundation-mission { background:linear-gradient(145deg,#3c3028,#283c33);border-color:#65513c; }
html[data-theme="dark"] .foundation-mission::after { background:#60544033; }
html[data-theme="dark"] .foundation-mission-progress { background:#263f36; }
html[data-theme="dark"] .foundation-mission-progress .bar { background:#192d2c; }
html[data-theme="dark"] .foundation-mascot-halo { background:#9e794533; }
html[data-theme="dark"] .foundation-mascot-sign { background:#e6cfac;color:#784f2d; }
html[data-theme="dark"] .foundation-illustrated .preschool-quick { background:linear-gradient(145deg,#2b414d,#233944);border-color:#496372; }
html[data-theme="dark"] .foundation-illustrated .preschool-mint { background:linear-gradient(145deg,#304a3e,#263f35);border-color:#496b59; }
html[data-theme="dark"] .foundation-illustrated .preschool-peach { background:linear-gradient(145deg,#4d3b2c,#3e3027);border-color:#6b5341; }
html[data-theme="dark"] .foundation-illustrated .preschool-quick strong { background:#172a29e8; }
html[data-theme="dark"] .foundation-illustrated .preschool-path { background:linear-gradient(135deg,#293c32,#293631);border-color:#486353; }
html[data-theme="dark"] .foundation-illustrated .foundation-path-copy small { color:#b4cbb6; }
html[data-theme="dark"] .foundation-mini-trail::before { background:#405249; }
html[data-theme="dark"] .foundation-mini-trail>span { background:#526158;border-color:#293c32;color:#c2d0c5; }
html[data-theme="dark"] .foundation-mini-trail>.is-current { background:#d38f61;color:#fff5db; }
html[data-theme="dark"] .foundation-mini-trail>.is-complete { background:#5b9d76;color:#fff5db; }
@media(max-width:360px) {
  .foundation-mission { padding:21px 15px 19px;min-height:254px; }
  .foundation-mission h1 { font-size:1.92rem; }
  .foundation-mission h2 { font-size:1.01rem; }
  .foundation-mission-copy { width:67%; }
  .foundation-home-mascot { right:-20px;width:159px;height:235px;bottom:-28px; }
  .foundation-mascot-sign { right:9px;width:47px;height:49px;font-size:1.35rem; }
  .foundation-mission-copy>.primary { font-size:.9rem;padding:12px 10px; }
  .foundation-illustrated .preschool-quick { min-height:155px;border-radius:20px; }
  .foundation-game-art { height:112px; }
  .foundation-illustrated .preschool-quick strong { font-size:.86rem; }
  .art-letter-left { left:4px;width:40px;font-size:1.55rem; }
  .art-letter-right { right:5px;width:40px;font-size:1.55rem; }
  .art-letter-trace { left:9px;width:57px; }
  .art-pencil { right:8px; }
}
.learning-odd-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px; }
/* Themes, not exercise mechanics, are the child's front door. */
.preschool-theme-section { margin-top:25px; }
.preschool-theme-section h2 { margin:0;font:800 1.7rem/1.2 var(--font-display);color:var(--ink); }
.preschool-theme-caption { margin:7px 0 17px;color:var(--muted);font-size:.95rem; }
.preschool-theme-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px; }
.preschool-theme { position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-width:0;min-height:163px;padding:10px 18px 17px 10px;border:1px solid #fff9e8;border-radius:26px;color:#203e50;cursor:pointer;text-align:center;font:inherit;box-shadow:0 6px 14px #74634509; }
.preschool-theme[hidden] { display:none; }
.theme-peach { background:#fbeadd; }
.theme-sky { background:#e2f0f8; }
.theme-sun { background:#fcf3d5; }
.theme-mint { background:#e5f1e2; }
.theme-lavender { background:#ede8f6; }
.theme-rose { background:#f8e5e6; }
.theme-aqua { background:#e1f1ed; }
.preschool-theme-art { position:relative;display:grid;place-items:center;width:116px;max-width:100%;height:106px;flex-shrink:0; }
.preschool-theme-art>.vocabulary-picture { width:112px;height:112px; }
.preschool-theme-art .vocabulary-picture-halo { opacity:0; }
.preschool-theme-name { font:800 1.15rem/1.3 var(--font-display);max-width:100%;overflow-wrap:anywhere; }
.preschool-theme-arrow { position:absolute;right:10px;bottom:13px;display:grid;place-items:center;width:25px;height:25px;border-radius:50%;background:#fff8;color:#a66444;font:800 23px/1 var(--font-body); }
.preschool-theme-progress { position:absolute;top:9px;right:10px;padding:4px 6px;border-radius:10px;background:#fff9;color:#386c50;font-size:.72rem;font-weight:900; }
.theme-art-letter { display:grid;place-items:center;width:83px;height:85px;transform:rotate(-8deg);border-radius:17px;background:#fffaf1;color:#d27250;font:800 2.8rem/1.6 var(--font-tamil);box-shadow:0 5px 12px #796d5810; }
.theme-art-numbers { position:relative;display:block;width:105px;height:100px; }
.theme-art-numbers b { position:absolute;display:grid;place-items:center;width:48px;height:48px;border-radius:12px;background:#699fc4;color:#fff9e9;font:900 2rem/1 var(--font-body);transform:rotate(-8deg);top:2px;left:30px; }
.theme-art-numbers b:nth-child(2) { top:48px;left:6px;background:#e68a52;transform:rotate(7deg); }
.theme-art-numbers b:nth-child(3) { top:45px;left:58px;background:#78a866;transform:rotate(-6deg); }
.theme-art-colors { position:relative;width:112px;height:103px; }
.theme-art-colors i { position:absolute;width:58px;height:58px;border-radius:50%;background:#d97a65;left:1px;top:43px; }
.theme-art-colors i:nth-child(2) { background:#699ec3;left:53px; }
.theme-art-colors i:nth-child(3) { background:#edc456;left:28px;top:4px;box-shadow:0 0 0 4px #fff5; }
.theme-art-shapes { display:flex;gap:6px;align-items:center; }
.theme-art-shapes i { width:33px;height:33px;border-radius:50%;background:#d97a65; }
.theme-art-shapes i:nth-child(2) { border-radius:0;clip-path:polygon(50% 0,100% 100%,0 100%);background:#edc456;height:44px;width:38px; }
.theme-art-shapes i:nth-child(3) { border-radius:5px;background:#699ec3;transform:rotate(-5deg); }
.theme-art-family { position:relative;width:122px;height:105px; }
.theme-art-family svg { position:absolute;width:82px;height:95px;left:-7px;top:0; }
.theme-art-family svg:nth-child(2) { left:46px; }
.theme-art-family svg:nth-child(3) { top:30px;left:27px;width:68px;height:82px; }
.preschool-show-themes { display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;margin:18px 0 8px;min-height:50px; }
.preschool-theme-view { padding-bottom:120px; }
.theme-page-header { display:flex;gap:12px;align-items:center;margin:22px 0; }
.theme-page-header h1 { margin:4px 0 0;font:800 2rem/1.2 var(--font-display); }
.theme-page-header .eyebrow { font-size:.7rem; }
.theme-discovery { display:flex;align-items:center;gap:14px;padding:14px;border-radius:25px;color:#203e50; }
.theme-discovery .preschool-theme-art { width:96px;height:96px; }
.theme-discovery>div { min-width:0;flex:1; }
.theme-discovery strong { font:800 1.05rem/1.35 var(--font-display); }
.theme-discovery p { margin:10px 0;color:#536b60;font-size:.85rem; }
.theme-quest-list { list-style:none;margin:22px 0;padding:0;display:grid;gap:12px; }
.theme-quest { width:100%;display:flex;align-items:center;gap:12px;padding:16px 13px;border:1px solid var(--line);border-bottom-width:3px;border-radius:23px;background:var(--card);color:var(--ink);text-align:left;font:inherit;cursor:pointer; }
.theme-quest.is-next { border-color:#9fbb99; }
.theme-quest:disabled { opacity:.65;cursor:default; }
.theme-quest>span:nth-child(2) { min-width:0;flex:1; }
.theme-quest strong { display:block;font:800 1.1rem/1.35 var(--font-display);overflow-wrap:anywhere; }
.theme-quest small { display:block;margin-top:5px;color:var(--muted);font-size:.81rem;line-height:1.4; }
.theme-step { display:grid;place-items:center;width:36px;height:40px;flex-shrink:0;border-radius:12px;background:#e7f0df;color:#537449;font-weight:900; }
.theme-quest>b { font-size:25px;color:var(--muted); }
.theme-letter-tools { border:1px solid var(--line);border-radius:20px;padding:16px;background:var(--card); }
.theme-letter-tools summary { cursor:pointer;font-weight:800; }
.theme-letter-tools>div { display:grid;gap:10px;margin-top:14px; }
.preschool-number-model { display:grid;place-items:center;width:58px;height:58px;background:#e4f0f5;color:#476f85;border-radius:16px;font:900 2rem/1 var(--font-body); }
.quest-models-visual article>strong { overflow-wrap:anywhere;font-size:1.35rem;line-height:1.6; }
.preschool-word-model { font-size:1.35rem; }
.preschool-number-token { display:grid;place-items:center;gap:8px;min-width:0;max-width:100%; }
.preschool-number-token b { font:900 1.4rem/1 var(--font-body);color:#689384; }
.preschool-number-token>span { font-size:1rem;overflow-wrap:anywhere; }
.learning-count-scene.is-many { padding:14px; }
.is-many .learning-count-items { display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px; }
.is-many .learning-count-items>span { width:auto;height:42px;border-radius:12px; }
.preschool-count-star { color:#d9aa41; }
.learning-odd-grid .vocabulary-picture { display:block;width:100%;height:100px; }
.learning-count-options .learning-tile { font-size:1.1rem;overflow-wrap:anywhere;min-width:0; }
.preschool-theme:focus-visible,.theme-quest:focus-visible,.theme-letter-tools summary:focus-visible { outline:3px solid var(--orange);outline-offset:3px; }
html[data-theme="dark"] .preschool-theme,html[data-theme="dark"] .theme-discovery { border-color:#45554b;color:#edf1e8; }
html[data-theme="dark"] .theme-peach { background:#3c302a; }
html[data-theme="dark"] .theme-sky { background:#263c48; }
html[data-theme="dark"] .theme-sun { background:#3c3927; }
html[data-theme="dark"] .theme-mint { background:#2b3e30; }
html[data-theme="dark"] .theme-lavender { background:#39334b; }
html[data-theme="dark"] .theme-rose { background:#45313b; }
html[data-theme="dark"] .theme-aqua { background:#263f3a; }
html[data-theme="dark"] .preschool-theme-arrow,html[data-theme="dark"] .preschool-theme-progress { background:#ffffff12;color:#e5c8a3; }
html[data-theme="dark"] .theme-art-letter { background:#f4ead4;color:#be603e; }
html[data-theme="dark"] .theme-discovery p { color:#b7cbbd; }
html[data-theme="dark"] .theme-step { background:#354c3b;color:#bcd4ae; }
html[data-theme="dark"] .preschool-number-model { background:#284755;color:#c0dbe7; }
@media(max-width:360px) {
  .preschool-theme-grid { gap:10px; }
  .preschool-theme { min-height:148px;padding:8px 14px 16px 6px;border-radius:23px; }
  .preschool-theme-name { font-size:1rem; }
  .preschool-theme-art { width:98px;height:92px;transform:scale(.92); }
  .preschool-theme-arrow { right:7px;bottom:12px;width:22px;height:22px; }
  .theme-discovery .preschool-theme-art { width:74px; }
  .theme-discovery { gap:9px;padding:12px; }
  .theme-discovery strong { font-size:.95rem; }
  .theme-quest strong { font-size:1rem; }
}
.learning-image-options { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px; }
.learning-image-options .learning-tile { padding:8px;min-height:116px; }
.learning-image-options svg { display:block;width:100%;height:108px; }
.learning-picture-word { text-align:center;font:800 2rem/1.6 var(--font-tamil);margin:0 0 14px;overflow-wrap:anywhere; }
.learning-picture-clue { margin:0 auto 14px;width:132px;max-width:100%; }
.learning-picture-clue svg { width:100%;height:auto;display:block; }
.quest-memory-picture { display:block; }
.quest-memory-picture svg { width:86px;max-width:100%;height:86px;display:block; }
.quest-memory-pronunciation { display:block;font:500 13px/1.4 var(--font-body);margin-top:7px; }
.learning-sort-row > strong:has(svg) { width:76px;flex-shrink:0; }
.learning-sort-row > strong svg { width:76px;height:76px; }
.learning-shape { display:block;width:54px;height:54px;margin:10px; }
.shape-circle { border-radius:50%; }
.shape-square { border-radius:6px; }
.shape-coral { background:#da6556; }
.shape-blue { background:#518cca; }
.learning-sound-pair { display:flex;gap:6px;align-items:stretch; }
.learning-sound-pair .learning-match-tile { flex:1;min-width:0; }
.learning-sound-listen { width:44px;min-height:44px;border:1px solid var(--line,#d2ddd3);border-radius:15px;background:var(--surface,#fffaf4);color:var(--ink,#173d4f);flex-shrink:0; }
.learning-sound-listen svg { width:23px;height:23px; }
.learning-picture-token { display:flex;flex-direction:column;align-items:center;min-width:72px;max-width:100px;padding:8px; }
.learning-picture-quantity { display:flex;flex-wrap:wrap;justify-content:center;width:68px; }
.learning-picture-quantity svg { width:32px;height:38px; }
.learning-picture-token small { font:700 15px/1.4 var(--font-body); }
html[data-theme="dark"] .learning-sound-listen { background:#203d35;color:#e8efe7;border-color:#527066; }
.learning-odd-grid .learning-tile { min-height:104px;font:800 2rem/1.4 var(--font-tamil);border-radius:22px;background:#fffaf1; }
.learning-pattern { display:grid;gap:22px; }
.learning-pattern-row { display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;align-items:center; }
.learning-pattern-row>span { display:grid;min-width:0;min-height:66px;place-items:center;border:1px solid var(--line);border-radius:16px;background:#fff;font:700 1.35rem/1.5 var(--font-tamil); }
.learning-pattern-row .learning-pattern-hole { border:2px dashed #dd8757;background:#fff4e9;color:#b14f2e; }
.learning-count-scene { padding:18px;border:1px solid #d9e6d8;border-radius:24px;background:linear-gradient(155deg,#f8fff7,#eef8ee); }
.learning-count-items { display:flex;flex-wrap:wrap;justify-content:center;gap:8px; }
.learning-count-items>span { display:grid;width:82px;height:82px;place-items:center;border-radius:18px;background:#fff;box-shadow:0 5px 12px #344b3410; }
.learning-count-items .vocabulary-picture { width:76px;height:76px; }
.learning-count-items b { font:800 1.7rem/1.4 var(--font-tamil); }
.learning-count-options { margin-top:16px; }
.learning-path { position:relative;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;padding:16px;border:1px solid #d7e5dc;border-radius:26px;background:linear-gradient(145deg,#f5fbf5,#edf6f2); }
.learning-path::before,.learning-path::after { position:absolute;z-index:1;display:grid;width:30px;height:30px;place-items:center;border-radius:50%;color:#fff;font-size:.9rem;font-weight:900;box-shadow:0 4px 9px #21382b22; }
.learning-path::before { content:'⚑';left:6px;top:6px;background:#e06c43; }
.learning-path::after { content:'★';right:6px;bottom:6px;background:#4c9a6d; }
.learning-path button { position:relative;min-width:0;min-height:72px;border:1px solid #c7d8ce;border-bottom-width:4px;border-radius:18px;background:#fff;color:var(--ink);cursor:pointer; }
.learning-path button span { font:700 1.35rem/1.5 var(--font-tamil); }
.learning-path button b { position:absolute;right:5px;top:5px;display:grid;width:22px;height:22px;place-items:center;border-radius:50%;background:#4d9c70;color:#fff;font-size:.7rem; }
.learning-path button[aria-pressed="true"] { border-color:#4d9c70;background:#e7f5eb;transform:translateY(2px); }
html[data-theme="dark"] .learning-odd-grid .learning-tile,
html[data-theme="dark"] .learning-pattern-row>span,
html[data-theme="dark"] .learning-count-items>span,
html[data-theme="dark"] .learning-path button { background:#21302e;color:var(--ink);border-color:#466057; }
html[data-theme="dark"] .learning-count-scene,
html[data-theme="dark"] .learning-path { background:linear-gradient(145deg,#1d2e2a,#172723);border-color:#3f5b52; }
html[data-theme="dark"] .learning-pattern-row .learning-pattern-hole { background:#3b2a23;border-color:#b96847; }
@media (max-width:360px) { .preschool-quick-grid{gap:7px}.preschool-quick{min-height:94px;padding-inline:4px}.preschool-quick strong{font-size:.79rem}.learning-count-items>span{width:68px;height:68px}.learning-count-items .vocabulary-picture{width:62px;height:62px} }
@keyframes quest-wrong-shake { 0%,100% { transform: translateX(0); } 35% { transform: translateX(-4px); } 70% { transform: translateX(4px); } }

/* ===== Modern refresh (iOS-like): white cards, tinted art wells, grouped lists ===== */
.preschool-theme-grid .theme-peach { --tone: #fbe3d1; }
.preschool-theme-grid .theme-sky { --tone: #dcecf8; }
.preschool-theme-grid .theme-sun { --tone: #fbefc9; }
.preschool-theme-grid .theme-mint { --tone: #dff0da; }
.preschool-theme-grid .theme-lavender { --tone: #e8e1f6; }
.preschool-theme-grid .theme-rose { --tone: #f8dfe1; }
.preschool-theme-grid .theme-aqua { --tone: #d9efe9; }
.preschool-theme-grid .preschool-theme {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto;
  align-items: center; gap: 10px 6px; min-height: 0; padding: 8px 8px 12px;
  border: 1px solid color-mix(in srgb, var(--line) 80%, transparent); border-radius: 26px;
  background: var(--card); color: var(--ink); text-align: left;
  box-shadow: 0 1px 2px rgba(23, 57, 84, 0.04), 0 10px 26px rgba(23, 57, 84, 0.07);
}
.preschool-theme-grid .preschool-theme[hidden] { display: none; }
.preschool-theme-grid .preschool-theme-art {
  grid-column: 1 / -1; width: 100%; height: 118px; border-radius: 20px;
  background: radial-gradient(120% 90% at 30% 20%, rgba(255, 255, 255, 0.7), transparent 60%), var(--tone, var(--cream-2));
}
.preschool-theme-grid .preschool-theme-name { grid-row: 2; padding-left: 8px; font-size: 1.05rem; }
.preschool-theme-grid .preschool-theme-arrow {
  position: static; grid-row: 2; width: 28px; height: 28px; margin-right: 4px;
  background: color-mix(in srgb, var(--line) 70%, transparent); color: var(--muted); font-size: 20px;
}
.preschool-theme-grid .preschool-theme-progress {
  top: 14px; right: 14px; padding: 4px 8px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.92); color: #2f7d62; box-shadow: 0 2px 6px rgba(23, 57, 84, 0.08);
}
.preschool-show-themes {
  border: 0; border-radius: 18px; background: var(--card); color: var(--ink);
  box-shadow: 0 1px 2px rgba(23, 57, 84, 0.04), 0 8px 22px rgba(23, 57, 84, 0.06);
}
html[data-theme="dark"] .preschool-theme-grid .preschool-theme { background: var(--card); border-color: var(--line); color: var(--ink); }
html[data-theme="dark"] .preschool-theme-grid .preschool-theme-art { background: color-mix(in srgb, var(--tone, #333) 16%, var(--card)); }
html[data-theme="dark"] .preschool-theme-grid .preschool-theme-progress { background: #ffffff18; color: #9fdcbc; }

/* Theme page */
.theme-discovery {
  border: 1px solid color-mix(in srgb, var(--line) 80%, transparent); background: var(--card);
  box-shadow: 0 1px 2px rgba(23, 57, 84, 0.04), 0 10px 26px rgba(23, 57, 84, 0.07);
}
.theme-discovery .preschool-theme-art { border-radius: 20px; background: var(--cream-2); }
.theme-quest-list {
  overflow: hidden; padding: 0; border: 1px solid color-mix(in srgb, var(--line) 80%, transparent); border-radius: 26px;
  background: var(--card); box-shadow: 0 1px 2px rgba(23, 57, 84, 0.04), 0 10px 26px rgba(23, 57, 84, 0.07);
}
.theme-quest-list > li { margin: 0; }
.theme-quest-list > li + li { border-top: 1px solid var(--line); }
.theme-quest-list .theme-quest { border: 0; border-radius: 0; background: none; box-shadow: none; }
.theme-quest-list .theme-step { width: 36px; height: 36px; border-radius: 50%; }
html[data-theme="dark"] .theme-discovery { background: var(--card); }
html[data-theme="dark"] .preschool-theme-grid .preschool-theme-progress { background: rgba(10, 20, 24, 0.82); color: #9fdcbc; }

/* Letter activity tiles (listen, compare, trace) on the vowel and consonant themes */
.theme-tools { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 14px 0 16px; }
.theme-tool { display: grid; grid-template-rows: 1fr auto; padding: 0; overflow: hidden; border: 1px solid color-mix(in srgb, var(--line) 80%, transparent); border-radius: 22px; background: var(--card); color: var(--ink); font: inherit; cursor: pointer; box-shadow: 0 1px 2px rgba(23, 57, 84, 0.04), 0 10px 24px rgba(23, 57, 84, 0.07); transition: transform 160ms var(--ease); }
.theme-tool:active { transform: scale(0.96); }
.theme-tool strong { padding: 10px 4px 12px; font-family: var(--font-display); font-size: 16px; font-weight: 800; }
.theme-tool-art { position: relative; display: block; height: 104px; background: var(--tt-bg); }
.tt-listen { --tt-bg: #e6e2fb; --tt-fg: #6c63d9; }
.tt-compare { --tt-bg: #d9f1e6; --tt-fg: #24425a; }
.tt-trace { --tt-bg: #fde6d6; --tt-fg: #24425a; }
html[data-theme="dark"] .tt-listen { --tt-bg: #2f2c4d; }
html[data-theme="dark"] .tt-compare { --tt-bg: #1f3a33; }
html[data-theme="dark"] .tt-trace { --tt-bg: #3d2c25; }
.tt-card { position: absolute; display: grid; width: 46px; height: 46px; place-items: center; border-radius: 12px; background: #fffaf3; color: #24425a; font: 700 24px/1 var(--font-tamil); box-shadow: 0 4px 10px rgba(36, 66, 90, 0.12); }
.tt-listen .tt-card { top: 14px; right: 16%; }
.tt-speaker { position: absolute; bottom: 12px; left: 14%; width: 46px; color: var(--tt-fg); }
.tt-card-a { top: 14px; left: 10%; color: #ef6b4f; transform: rotate(-8deg); }
.tt-card-b { top: 26px; right: 10%; transform: rotate(6deg); }
.tt-link { position: absolute; bottom: 8px; left: 12%; width: 76%; color: #24425a; }
html[data-theme="dark"] .tt-link { color: #c6d3cf; }
.tt-card-trace { top: 16px; left: 18%; width: 54px; height: 60px; transform: rotate(-6deg); }
.tt-pencil { position: absolute; right: 10%; bottom: 8px; width: 30px; }

/* Review lessons: 12-card memory and the "on révise aussi" strip */
.quest-memory.quest-memory-big { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; }
.quest-memory-big button { min-height: 78px; padding: 6px; border-radius: 16px; }
.quest-memory-big button > span { font-size: 1.35rem; line-height: 1.5; }
.quest-memory-big .quest-memory-picture svg { width: 54px; height: 54px; margin: 0 auto; }
.quest-memory-big .quest-memory-pronunciation { font-size: 11px; margin-top: 3px; }
.quest-review { display: grid; gap: 8px; margin: 4px 0 18px; padding: 14px 16px; border-radius: 20px; background: color-mix(in srgb, var(--green-soft, #e4f2e8) 70%, transparent); }
.quest-review .eyebrow { margin: 0; }
.quest-review > div { display: flex; flex-wrap: wrap; gap: 8px; }
.quest-review [lang="ta"] { min-width: 44px; padding: 6px 12px; border-radius: 14px; background: var(--card, #fff); font-size: 1.15rem; font-weight: 700; text-align: center; }
html[data-theme=dark] .quest-review { background: #22362c; }
html[data-theme=dark] .quest-review [lang="ta"] { background: #2b3a33; color: var(--ink); }

/* Tracing inside a lesson */
.quest-trace { margin: 0; }
.quest-trace-done { display: grid; place-items: center; min-height: 200px; border-radius: 24px; background: var(--green-soft, #e4f2e8); color: #267c51; font-size: 6rem; font-weight: 700; }
.quest-trace-skip { display: block; margin: 12px auto 0; padding: 10px 16px; font-size: .95rem; color: var(--ink-2); }
html[data-theme=dark] .quest-trace-done { background: #254e3a; color: #e2f9ea; }

/* ---- Preschool games ---- */
.kid-tools { display: flex; flex-wrap: wrap; gap: 8px; margin: -4px 0 12px; }
.kid-say, .kid-hint { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 6px 14px 6px 10px; border: 0; border-radius: 999px; font: 700 .9rem/1 var(--font-body, inherit); cursor: pointer; }
.kid-say { background: #e8f3fb; color: #2d5d80; }
.kid-say .sound-svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2; }
.kid-hint { background: #fff4cf; color: #8a6200; }
.kid-hint svg { width: 20px; height: 20px; }
.kid-hint.is-empty { opacity: .55; }
[data-hint-out], .is-out { opacity: .28 !important; filter: grayscale(1); text-decoration: line-through; pointer-events: none; }

.quest-memory-sound { display: grid; place-items: center; }
.quest-memory-sound .sound-svg { width: 40px; height: 40px; stroke: currentColor; stroke-width: 2; }

.bubbles-listen { margin-bottom: 8px; }
.bubbles-round { margin: 0 0 6px; text-align: center; font-weight: 800; color: var(--ink-2); }
.bubbles-field { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 10px; padding: 8px 2px 4px; }
.kid-bubble { aspect-ratio: 1; width: 100%; max-width: 104px; justify-self: center; display: grid; place-items: center; border: 2px solid rgba(255,255,255,.9); border-radius: 50%; background: radial-gradient(circle at 32% 28%, #ffffff 0 12%, transparent 13%), radial-gradient(circle at 50% 50%, #dff1ff 0%, #b9dcf7 62%, #9cc9ee 100%); box-shadow: inset -6px -8px 14px rgba(65,120,170,.25), 0 6px 14px rgba(65,120,170,.18); color: #1d3b55; font-size: 1.9rem; font-weight: 700; cursor: pointer; animation: kid-float 3.2s ease-in-out infinite; animation-delay: calc(var(--i) * -.37s); }
.kid-bubble:nth-child(3n+2) { margin-top: 22px; }
.kid-bubble:nth-child(4n+2) { background: radial-gradient(circle at 32% 28%, #ffffff 0 12%, transparent 13%), radial-gradient(circle at 50% 50%, #ffe9f1 0%, #f9c8da 62%, #f2abc5 100%); box-shadow: inset -6px -8px 14px rgba(190,90,130,.22), 0 6px 14px rgba(190,90,130,.16); }
.kid-bubble:nth-child(4n+3) { background: radial-gradient(circle at 32% 28%, #ffffff 0 12%, transparent 13%), radial-gradient(circle at 50% 50%, #eaf8e6 0%, #c6e8bd 62%, #a8d99c 100%); box-shadow: inset -6px -8px 14px rgba(80,150,80,.22), 0 6px 14px rgba(80,150,80,.16); }
.kid-bubble-picture svg { width: 62px; height: 62px; display: block; }
.kid-bubble.is-popped { animation: kid-pop .35s ease-out forwards; background: transparent; box-shadow: none; border-color: transparent; color: #f2b632; }
.kid-bubble.is-wrong { animation: quest-wrong-shake .28s ease-in-out 2; }
.kid-bubble.is-hint { outline: 4px solid #f5c84b; outline-offset: 3px; animation: kid-glow 1s ease-in-out infinite; }
.kid-bubble-pop { font-size: 1.6rem; }
@keyframes kid-float { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-7px) } }
@keyframes kid-pop { 0% { transform: scale(1) } 60% { transform: scale(1.25); opacity: .6 } 100% { transform: scale(.6); opacity: .45 } }
@keyframes kid-glow { 0%,100% { outline-color: #f5c84b } 50% { outline-color: #ffe9a3 } }

.feed-scene { display: grid; justify-items: center; gap: 16px; padding: 4px 0 2px; }
.feed-mouth { position: relative; width: min(190px, 56vw); }
.feed-monster { width: 100%; height: auto; display: block; }
.feed-monster.is-happy { animation: kid-chomp .5s ease-in-out 2; }
.feed-monster.is-yuck { animation: quest-wrong-shake .28s ease-in-out 2; }
.feed-monster.is-yuck .feed-mouth-shape { d: path("M54 104c10-8 42-8 52 0z"); }
.feed-eaten { position: absolute; left: 50%; top: 58%; transform: translate(-50%, -50%) scale(.2); font-size: 2rem; font-weight: 800; color: #fff; opacity: 0; animation: kid-eat .6s ease-in forwards; }
.feed-foods { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.feed-food { width: 86px; height: 86px; border-radius: 50%; border: 0; background: radial-gradient(circle at 35% 30%, #ffe2a8, #f5b45a 70%, #e39a3e); box-shadow: inset -4px -6px 0 rgba(160,90,20,.25), 0 6px 12px rgba(160,90,20,.2); color: #5a3510; font-size: 2rem; font-weight: 800; cursor: grab; touch-action: none; transition: transform .12s; }
.feed-food.is-dragging { z-index: 5; position: relative; cursor: grabbing; transition: none; }
.feed-tip { margin: 0; font-size: .85rem; color: var(--ink-2); text-align: center; }
@keyframes kid-chomp { 0%,100% { transform: scale(1) } 50% { transform: scale(1.06, .94) } }
@keyframes kid-eat { to { transform: translate(-50%, -50%) scale(1); opacity: 0 } 40% { opacity: 1 } }

.kid-train { display: flex; align-items: flex-end; gap: 4px; overflow-x: auto; padding: 8px 2px 14px; }
.kid-loco { flex: 0 0 64px; }
.kid-loco svg { width: 64px; height: auto; display: block; }
.kid-car { position: relative; flex: 1 1 0; min-width: 56px; height: 66px; display: grid; place-items: center; border-radius: 12px 12px 6px 6px; background: #ffd58a; box-shadow: inset 0 -6px 0 rgba(150,90,20,.18); font-size: 1.8rem; font-weight: 800; color: #4b2f12; }
.kid-car:nth-of-type(even) { background: #9fd2f0; color: #173a55; }
.kid-car.is-empty { background: #fff; outline: 3px dashed #e3a24d; outline-offset: -5px; color: #e07b2f; }
.kid-car.is-wrong { outline-color: #e36f61; color: #b84232; animation: quest-wrong-shake .28s ease-in-out 2; }
.kid-car i { position: absolute; bottom: -9px; width: 16px; height: 16px; border-radius: 50%; background: #22313f; }
.kid-car i:first-of-type { left: 10px; } .kid-car i:last-of-type { right: 10px; }
.kid-train-options { display: flex; justify-content: center; gap: 12px; margin-top: 8px; }
.kid-train-options .learning-tile { min-width: 84px; min-height: 84px; font-size: 2rem; }

.kid-confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 30; }
.kid-confetti i { position: absolute; top: -12px; left: calc(var(--i) * 7% + 2%); width: 10px; height: 14px; border-radius: 3px; background: hsl(calc(var(--i) * 47), 85%, 62%); animation: kid-fall 1.4s ease-in forwards; animation-delay: calc(var(--i) * 40ms); }
@keyframes kid-fall { to { transform: translateY(105vh) rotate(calc(var(--i) * 70deg)); opacity: .2 } }
@media (prefers-reduced-motion: reduce) { .kid-bubble, .kid-confetti i, .feed-monster, .feed-eaten { animation: none !important; } .kid-confetti { display: none; } }
html[data-reduced-motion=true] .kid-confetti { display: none; }

html[data-theme=dark] .kid-say { background: #1f3445; color: #b9dcf7; }
html[data-theme=dark] .kid-hint { background: #3d3418; color: #f5d27a; }
html[data-theme=dark] .kid-car.is-empty { background: #22313f; }
html[data-theme=dark] .feed-tip, html[data-theme=dark] .bubbles-round { color: var(--ink-2); }
/* Packs of ten for counting above 20 (10 Nov 2026). */
.has-packs .learning-count-items { display:flex;flex-wrap:wrap;justify-content:center;gap:10px; }
.has-packs .learning-count-items>span { width:64px;height:64px; }
.learning-count-items>span.learning-count-pack { width:72px;height:86px;display:grid;grid-template-rows:auto 1fr;place-items:stretch;gap:6px;padding:8px 6px;background:linear-gradient(180deg,#fff4e6,#ffe3c7);border:2px solid #f2b27c;border-radius:16px; }
.learning-count-pack b { font:900 1.25rem/1 var(--font-body);color:#b65a2a;text-align:center; }
.learning-count-pack i { display:grid;grid-template-columns:repeat(5,1fr);gap:3px;align-content:center; }
.learning-count-pack s { display:block;aspect-ratio:1;border-radius:50%;background:#f08a4b;text-decoration:none; }
html[data-theme="dark"] .learning-count-items>span.learning-count-pack { background:linear-gradient(180deg,#3d2c22,#33251c);border-color:#a9673d; }
html[data-theme="dark"] .learning-count-pack b { color:#ffc49a; }
/* Exercise redesign, lot 2 (10 Nov 2026): hidden pairs, listen-and-find, which number. */
.quest-memory button:not(.is-revealed):not(.is-paired) { background-color:#fff0e8; background-image:radial-gradient(circle,#f6b08c 2.2px,transparent 2.6px); background-size:16px 16px; border-color:#f6c3a8; color:#e0703e; }
.quest-memory button:not(.is-revealed):not(.is-paired) > span { font-family:var(--font-tamil); font-weight:800; }
.quest-memory .is-paired { position:relative; border-color:#2f8a5b; border-width:2px; }
.quest-memory .is-paired::after { content:"✓"; position:absolute; top:-8px; right:-8px; width:24px; height:24px; border-radius:50%; background:#2f8a5b; color:#fff; display:grid; place-items:center; font:800 13px/1 var(--font-body); }
html[data-theme=dark] .quest-memory button:not(.is-revealed):not(.is-paired) { background-color:#3c261f; background-image:radial-gradient(circle,#7a4a33 2.2px,transparent 2.6px); border-color:#7a4a33; color:#ffb48c; }
.quest-listen-big { display:grid; justify-items:center; gap:6px; margin:6px 0 14px; }
.quest-listen-round { width:92px; height:92px; border-radius:50%; border:0; background:#ff6737; color:#fff; display:grid; place-items:center; cursor:pointer; animation:quest-listen-pulse 1.8s infinite; }
.quest-listen-round .sound-svg, .quest-listen-round svg { width:40px; height:40px; }
.quest-listen-big small { font-weight:700; color:var(--ink-2); }
@keyframes quest-listen-pulse { 0% { box-shadow:0 0 0 0 #ff673766; } 70% { box-shadow:0 0 0 16px #ff673700; } 100% { box-shadow:0 0 0 0 #ff673700; } }
.learning-image-options .learning-tile { position:relative; }
.learning-image-options .learning-tile.is-right { border-color:#2f8a5b; background:#e3f4ea; }
.learning-image-options .learning-tile.is-wrong, .learning-count-choice .learning-tile.is-wrong { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
.learning-image-options .learning-tile.is-right::after, .learning-image-options .learning-tile.is-wrong::after, .learning-count-choice .learning-tile.is-right::after, .learning-count-choice .learning-tile.is-wrong::after { position:absolute; top:-9px; right:-9px; width:26px; height:26px; border-radius:50%; display:grid; place-items:center; color:#fff; font:800 14px/1 var(--font-body); }
.learning-image-options .learning-tile.is-right::after, .learning-count-choice .learning-tile.is-right::after { content:"✓"; background:#2f8a5b; }
.learning-image-options .learning-tile.is-wrong::after, .learning-count-choice .learning-tile.is-wrong::after { content:"✕"; background:#c2452d; }
.learning-image-caption { display:block; font:700 15px/1.4 var(--font-tamil); color:#205936; }
.learning-count-digit { display:grid; place-items:center; height:170px; border-radius:24px; background:#eaf6fc; border:2px solid #b9d6e8; margin-bottom:16px; }
.learning-count-digit span { font:900 104px/1 var(--font-display); color:var(--ink); }
.learning-count-digit small { font:800 15px var(--font-body); color:var(--ink-2); }
.learning-count-choices { display:flex; flex-wrap:wrap; justify-content:center; gap:8px; }
.learning-count-choice { display:grid; gap:4px; justify-items:stretch; flex:1 1 auto; min-width:28%; }
.learning-count-choice .learning-tile { position:relative; min-height:64px; padding-inline:12px; font:700 clamp(17px,4.6vw,21px)/1.3 var(--font-tamil); white-space:nowrap; }
.learning-count-choice .learning-tile.is-right { border-color:#2f8a5b; background:#e3f4ea; }
.learning-count-listen { display:flex; align-items:center; justify-content:center; gap:4px; min-height:32px; border:0; background:none; color:var(--blue,#4b91bd); font:800 12px var(--font-body); cursor:pointer; }
.learning-count-listen svg { width:15px; height:15px; }
html[data-theme=dark] .learning-count-digit { background:#1d2d38; border-color:#35566b; }
html[data-theme=dark] .learning-image-options .learning-tile.is-right, html[data-theme=dark] .learning-count-choice .learning-tile.is-right { background:#173a29; }
html[data-theme=dark] .learning-image-options .learning-tile.is-wrong, html[data-theme=dark] .learning-count-choice .learning-tile.is-wrong { background:#3d221c; }
@media (prefers-reduced-motion:reduce) { .quest-listen-round { animation:none; } }
.quest-listen-big .quest-listen-round { background:#ff6737 !important; color:#fff !important; border:0 !important; outline-offset:4px; }
.learning-image-options .learning-tile:last-child:nth-child(odd) { grid-column:1/-1; justify-self:center; width:calc(50% - 6px); }
/* Exercise redesign, lot 3 (11 Nov 2026): order in numbered boxes, missing letter in tiles, sorting baskets. */
.learning-slot-legend { display:flex; justify-content:space-between; font:800 12px var(--font-body); color:var(--ink-2); margin:0 2px 6px; }
.learning-slots { display:grid; grid-template-columns:repeat(var(--slots,3),minmax(0,1fr)); gap:8px; margin-bottom:14px; }
.learning-slot { position:relative; min-height:80px; border-radius:18px; border:2px dashed #b9d6e8; background:#eaf6fc; display:grid; place-items:center; padding:6px 4px; color:var(--ink); cursor:pointer; }
.learning-slot em { position:absolute; top:4px; left:8px; font:800 11px var(--font-body); font-style:normal; color:#4b91bd; }
.learning-slot b { font:700 clamp(15px,4.4vw,19px)/1.25 var(--font-tamil); text-align:center; overflow-wrap:anywhere; }
.learning-slot i { position:absolute; bottom:3px; right:8px; font:900 15px var(--font-display); font-style:normal; color:#2f8a5b; }
.learning-slot.is-filled { border-style:solid; border-color:#4b91bd; background:#fff; }
.learning-slot.is-wrong { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
.learning-slot.is-right { border-color:#2f8a5b; background:#e3f4ea; }
.learning-slot-retry { margin:0 0 10px; text-align:center; font-weight:800; color:#a73c30; }
.learning-say-row { display:flex; justify-content:center; margin:4px 0 12px; }
.learning-say { display:inline-flex; align-items:center; gap:6px; border:0; background:#eaf6fc; color:#4b91bd; border-radius:99px; padding:8px 14px; font:800 14px var(--font-body); cursor:pointer; }
.learning-say svg { width:18px; height:18px; }
.learning-word-tiles { display:flex; justify-content:center; flex-wrap:wrap; gap:6px; margin-bottom:10px; }
.learning-letter { min-width:58px; height:70px; padding:0 6px; border-radius:16px; border:2px solid #e3dbd3; background:#fff; display:grid; place-items:center; font:700 28px var(--font-tamil); color:var(--ink); }
.learning-letter.is-hole { border:2px dashed #ff6737; background:#fff0e8; color:#ff6737; }
.learning-letter.is-right { border-style:solid; border-color:#2f8a5b; background:#e3f4ea; color:var(--ink); }
.learning-model-toggle { text-align:center; margin:0 0 12px; color:var(--ink-2); font-size:13px; font-weight:700; }
.learning-model-toggle summary { display:inline-block; cursor:pointer; border:1px solid #e3dbd3; border-radius:99px; padding:6px 12px; list-style:none; }
.learning-model-toggle summary::-webkit-details-marker { display:none; }
.learning-model-toggle b { display:block; margin-top:6px; font:700 18px var(--font-tamil); color:var(--ink); }
.learning-gap-options { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; }
.learning-gap-options .learning-tile { position:relative; min-height:64px; font:700 24px var(--font-tamil); }
.learning-gap-options .learning-tile.is-wrong { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
.learning-sort-cards { display:flex; flex-wrap:wrap; justify-content:center; gap:8px; min-height:96px; margin-bottom:12px; }
.learning-sort-card { width:92px; height:92px; border-radius:20px; border:2px solid #e3dbd3; background:#fff; display:grid; place-items:center; padding:2px; cursor:pointer; transition:transform .15s; }
.learning-sort-card .vocabulary-picture { width:80px; height:80px; }
.learning-sort-card.is-selected { border-color:#4b91bd; background:#eaf6fc; transform:translateY(-4px); }
.learning-sort-card.is-wrong { border-color:#c2452d; animation:quest-wrong-shake .28s ease-in-out 2; }
.learning-baskets { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.learning-basket { display:grid; gap:6px; justify-items:center; align-content:start; min-height:150px; padding:12px 8px; border-radius:22px; border:3px solid; cursor:pointer; }
.learning-basket.basket-0 { background:#fff1e3; border-color:#f2c497; color:#9a4f17; }
.learning-basket.basket-1 { background:#e8f5e4; border-color:#b5d9ad; color:#2f6a32; }
.learning-basket.is-ready { box-shadow:0 0 0 4px #4b91bd55; }
.learning-basket-name { font:800 17px/1.2 var(--font-display); text-align:center; }
.learning-basket-name small { display:block; font:700 14px var(--font-tamil); opacity:.85; }
.learning-basket-in { display:flex; flex-wrap:wrap; justify-content:center; gap:4px; }
.learning-basket-in .vocabulary-picture { width:46px; height:46px; }
html[data-theme=dark] .learning-slot { background:#1d2d38; border-color:#35566b; }
html[data-theme=dark] .learning-slot.is-filled, html[data-theme=dark] .learning-letter, html[data-theme=dark] .learning-sort-card { background:#22272e; border-color:#38404a; }
html[data-theme=dark] .learning-slot.is-right, html[data-theme=dark] .learning-letter.is-right { background:#173a29; }
html[data-theme=dark] .learning-letter.is-hole { background:#3c261f; }
html[data-theme=dark] .learning-basket.basket-0 { background:#3a2a1c; border-color:#7a5a3a; color:#ffcf9f; }
html[data-theme=dark] .learning-basket.basket-1 { background:#1f3320; border-color:#4c7a4a; color:#bfe6b8; }
@media (prefers-reduced-motion:reduce) { .learning-sort-card { transition:none; } }
/* Exercise redesign, lot 4 (11 Nov 2026): bubbles, monster, train, odd one out, pattern. */
.kid-bubble, .kid-bubble span { color:#173954; }
.feed-food, .feed-food span { color:#5a2d0c; }
.feed-mouth { width:min(220px, 62vw); }
.kid-car { color:#3a2a10; font:inherit; cursor:pointer; border:0; }
.kid-car.is-empty { cursor:default; }
.kid-car:nth-of-type(even) { color:#173a55; }
.kid-train { transition:transform .9s ease-in; }
.kid-train.is-leaving { transform:translateX(110%); transition-delay:.8s; }
html[data-theme=dark] .kid-car.is-empty { color:#ffb48c; }
.learning-odd-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.learning-odd-grid .learning-tile { position:relative; min-height:100px; font-size:40px; }
.learning-odd-grid .learning-tile.is-right, .learning-odd-grid .learning-tile[data-odd="is-right"] { border-color:#2f8a5b; background:#e3f4ea; }
.learning-odd-grid .learning-tile.is-same, .learning-odd-grid .learning-tile[data-odd="is-same"] { opacity:.5; }
.learning-odd-grid .learning-tile.is-wrong, .learning-odd-grid .learning-tile[data-odd="is-wrong"] { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
.learning-odd-why { margin:12px 0 0; text-align:center; font-weight:700; color:var(--ink-2); }
.learning-pattern-row span.tone-0 { background:#fff0e8; color:#b8501d; border:2px solid #f6c3a8; }
.learning-pattern-row span.tone-1 { background:#efeafd; color:#5a3fb8; border:2px solid #cfc3f5; }
.learning-pattern-row span.tone-2 { background:#e2f5f2; color:#14786d; border:2px solid #a6dcd4; }
.learning-pattern-row span.tone-3 { background:#fdf3d8; color:#8a6410; border:2px solid #efd58e; }
.learning-pattern-hole:not(.is-filled) { border:3px dashed #ff6737 !important; color:#ff6737; background:#fff; animation:pattern-bob 1.4s ease-in-out infinite; }
@keyframes pattern-bob { 0%,100% { transform:translateY(0); } 50% { transform:translateY(-6px); } }
.learning-signs .learning-tile[data-odd="is-wrong"] { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
html[data-theme=dark] .learning-pattern-row span.tone-0 { background:#3c261f; color:#ffb48c; border-color:#7a4a33; }
html[data-theme=dark] .learning-pattern-row span.tone-1 { background:#2a2443; color:#c9bbff; border-color:#4f4180; }
html[data-theme=dark] .learning-pattern-row span.tone-2 { background:#173430; color:#8fe0d4; border-color:#2d6a60; }
html[data-theme=dark] .learning-pattern-row span.tone-3 { background:#3a3016; color:#f2d27c; border-color:#6e5a22; }
html[data-theme=dark] .learning-pattern-hole:not(.is-filled) { background:#22272e; }
html[data-theme=dark] .learning-odd-grid .learning-tile.is-right, html[data-theme=dark] .learning-odd-grid .learning-tile[data-odd="is-right"] { background:#173a29; }
@media (prefers-reduced-motion:reduce) { .learning-pattern-hole { animation:none !important; } .kid-train { transition:none; } }
/* Dark theme: keep wrong/right answer states readable (light text on dark tints). */
html[data-theme=dark] :is(.learning-signs .learning-tile[data-odd="is-wrong"], .learning-odd-grid .learning-tile.is-wrong, .learning-odd-grid .learning-tile[data-odd="is-wrong"], .learning-gap-options .learning-tile.is-wrong, .learning-count-choice .learning-tile.is-wrong, .learning-image-options .learning-tile.is-wrong, .learning-slot.is-wrong, .learning-sort-card.is-wrong) { background:#3d221c; border-color:#c2452d; color:#ffc3b5; }
html[data-theme=dark] :is(.learning-odd-grid .learning-tile.is-right, .learning-odd-grid .learning-tile[data-odd="is-right"], .learning-count-choice .learning-tile.is-right, .learning-image-options .learning-tile.is-right, .learning-slot.is-right, .learning-letter.is-right) { background:#173a29; border-color:#4fae7c; color:#d9f5e4; }
html[data-theme=dark] .learning-image-caption { color:#bfe9cf; }
html[data-theme=dark] .learning-count-digit span { color:#f3f6f7; }
.learning-odd-retry { margin:12px 0 0; text-align:center; font-weight:800; color:#a73c30; }
html[data-theme=dark] .learning-odd-retry { color:#ffb4a5; }
/* Exercise redesign, lot 5 (11 Nov 2026): tracing, river, short or long, word puzzle, picture gap, harvest. */
.quest-trace-meter { height:12px; border-radius:99px; background:rgba(120,140,150,.22); overflow:hidden; margin:12px 4px 0; }
.quest-trace-meter i { display:block; height:100%; width:0; background:linear-gradient(90deg,#ffb36b,#ff6737); transition:width .25s; }
.quest-trace-row { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-top:8px; }
.quest-trace-row .writing-feedback { margin:0; flex:1; }
.quest-trace-stars { font-size:24px; color:#f2b632; letter-spacing:2px; white-space:nowrap; }
.kid-river-left { text-align:center; font-weight:800; color:var(--ink-2); margin:0 0 8px; min-height:1.2em; }
.kid-river { border-radius:26px; overflow:hidden; display:grid; gap:10px; position:relative; background:linear-gradient(#7fd0ee,#4aa6d6 55%,#3a8fc4); box-shadow:inset 0 0 0 3px rgba(255,255,255,.35); }
.kid-river::before { content:""; position:absolute; inset:0; background:url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='60'%3E%3Cg fill='none' stroke='%23fff' stroke-width='2.5' stroke-linecap='round' opacity='.35'%3E%3Cpath d='M10 15q8-6 16 0t16 0'/%3E%3Cpath d='M70 45q8-6 16 0t16 0'/%3E%3C/g%3E%3C/svg%3E"); background-size:120px 60px; animation:kid-river-flow 14s linear infinite; pointer-events:none; }
.kid-river-bank { height:72px; display:flex; align-items:center; justify-content:center; gap:8px; position:relative; z-index:1; background-size:100% 100%; background-repeat:no-repeat; }
.kid-river-bank.is-top { background-size:100% 40px,100% 100%; background-position:top,center; }
.kid-river-bank.is-bottom { background-size:100% 40px,100% 100%; background-position:bottom,center; }
.kid-river-bank.is-top { background-image:url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 40'%3E%3Cg fill='%235bb565'%3E%3Ccircle cx='30' cy='22' r='13'/%3E%3Ccircle cx='46' cy='18' r='15'/%3E%3Ccircle cx='62' cy='24' r='11'/%3E%3Ccircle cx='330' cy='20' r='14'/%3E%3Ccircle cx='350' cy='16' r='16'/%3E%3Ccircle cx='370' cy='23' r='11'/%3E%3C/g%3E%3Cg fill='%23ff8fa3'%3E%3Ccircle cx='110' cy='26' r='3'/%3E%3Ccircle cx='270' cy='22' r='3'/%3E%3Ccircle cx='300' cy='30' r='2.5'/%3E%3C/g%3E%3Cg fill='%23ffd166'%3E%3Ccircle cx='125' cy='18' r='2.5'/%3E%3Ccircle cx='90' cy='30' r='2.5'/%3E%3Ccircle cx='285' cy='14' r='2.5'/%3E%3C/g%3E%3C/svg%3E"),url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 70' preserveAspectRatio='none'%3E%3Cpath d='M0 0H400V50C360 64 330 46 290 54C250 62 220 70 180 58C140 46 110 64 70 60C40 57 20 50 0 56Z' fill='%23f3e2b3'/%3E%3Cpath d='M0 0H400V42C360 56 330 38 290 46C250 54 220 62 180 50C140 38 110 56 70 52C40 49 20 42 0 48Z' fill='%237ccf7e'/%3E%3Cpath d='M0 0H400V30C350 40 320 26 280 32C240 38 200 44 160 36C120 28 90 42 50 38C30 36 15 32 0 34Z' fill='%239edc8f'/%3E%3C/svg%3E"); align-items:flex-start; padding-top:6px; }
.kid-river-bank.is-bottom { background-image:url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 40'%3E%3Cg fill='%23d8c08a'%3E%3Cellipse cx='40' cy='26' rx='6' ry='3.5'/%3E%3Cellipse cx='58' cy='30' rx='4' ry='2.5'/%3E%3Cellipse cx='320' cy='24' rx='5' ry='3'/%3E%3Cellipse cx='350' cy='30' rx='7' ry='4'/%3E%3C/g%3E%3Cg fill='%23f08a5d'%3E%3Cpath d='M100 30l4-6 4 6-4 3z'/%3E%3C/g%3E%3Cg fill='%237cc3e0'%3E%3Cpath d='M290 28q4-8 8 0q-4 4-8 0z'/%3E%3C/g%3E%3C/svg%3E"),url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 70' preserveAspectRatio='none'%3E%3Cpath d='M0 70H400V18C360 6 330 22 290 14C250 6 220 0 180 12C140 24 110 6 70 10C40 13 20 20 0 14Z' fill='%23fff4d6' opacity='.7'/%3E%3Cpath d='M0 70H400V24C360 12 330 28 290 20C250 12 220 6 180 18C140 30 110 12 70 16C40 19 20 26 0 20Z' fill='%23f3e2b3'/%3E%3Cpath d='M0 70H400V52C360 46 320 56 280 50C240 44 200 54 160 50C120 46 80 56 40 50C25 48 10 50 0 52Z' fill='%23e6cf92'/%3E%3C/svg%3E"); align-items:flex-end; padding-bottom:10px; }
.kid-river-bank em { font-style:normal; font-weight:800; font-size:14px; color:#2d4a33; background:rgba(255,255,255,.85); padding:3px 12px; border-radius:99px; box-shadow:0 2px 0 rgba(0,0,0,.08); }
@keyframes kid-river-flow { from { background-position:0 0; } to { background-position:120px 0; } }
.kid-river-bank span { font-size:34px; line-height:1; filter:drop-shadow(0 3px 0 rgba(0,0,0,.12)); }
.kid-river-bank .kid-river-thimoli { width:40px; height:40px; object-fit:contain; }
.kid-river-row { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; padding:4px 14px; position:relative; z-index:1; border-radius:18px; }
.kid-river-row.is-now { background:rgba(255,255,255,.16); box-shadow:0 0 0 2px rgba(255,255,255,.45); }
.kid-stone { position:relative; height:64px; width:100%; max-width:118px; justify-self:center; border:0; border-radius:50% 46% 52% 48%/58% 50% 50% 42%; background:radial-gradient(circle at 40% 30%,#d6cfc4,#8f857a); color:#2b2620; font:700 30px var(--tamil-font,"Noto Sans Tamil",sans-serif); box-shadow:0 5px 0 rgba(0,0,0,.16), 0 9px 0 1px rgba(255,255,255,.28); opacity:.72; filter:saturate(.6); transition:transform .3s,opacity .3s; }
.kid-stone:disabled { cursor:default; }
.kid-river-row.is-now .kid-stone { opacity:1; filter:none; cursor:pointer; animation:kid-stone-bob 2.2s ease-in-out infinite; }
.kid-river-row.is-now .kid-stone:nth-child(2) { animation-delay:-.7s; }
.kid-river-row.is-now .kid-stone:nth-child(3) { animation-delay:-1.4s; }
.kid-stone.is-on { opacity:1; filter:none; background:radial-gradient(circle at 40% 30%,#ffd9bf,#ff9a6b); }
.kid-stone.is-sinking { animation:kid-stone-sink .6s !important; }
.kid-stone.is-hint { box-shadow:0 0 0 4px #ffd166, 0 5px 0 rgba(0,0,0,.16); }
.kid-stone .kid-river-thimoli { position:absolute; left:-12px; top:-12px; width:34px; height:34px; border-radius:50%; background:#fff; border:2px solid #ff6737; object-fit:contain; padding:2px; }
@keyframes kid-stone-bob { 0%,100% { transform:translateY(0); } 50% { transform:translateY(-5px); } }
@keyframes kid-stone-sink { 0% { transform:translateY(0); } 40% { transform:translateY(9px) scale(.92); filter:brightness(.8); } 100% { transform:translateY(0); } }
.learning-compare { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.learning-compare-card { border-radius:22px; border:2px solid var(--line,#eadfd6); background:var(--card,#fff); color:inherit; padding:16px 10px 12px; display:grid; justify-items:center; gap:10px; cursor:pointer; font:inherit; }
.learning-compare-card b { font:700 54px/1.1 "Noto Sans Tamil",sans-serif; }
.learning-compare-bar { height:12px; border-radius:99px; background:#4b91bd; }
.learning-compare-bar.is-short { width:34px; }
.learning-compare-bar.is-long { width:min(100px,80%); }
.learning-compare-card small { font-weight:800; color:var(--ink-2); }
.learning-compare-card.is-right { border-color:#2f8a5b; background:#e3f4ea; }
.learning-compare-card.is-wrong { border-color:#c2452d; background:#fde8e2; animation:quest-wrong-shake .28s ease-in-out 2; }
html[data-theme=dark] .learning-compare-card.is-right { background:#173a29; }
html[data-theme=dark] .learning-compare-card.is-wrong { background:#3d221c; }
.kid-harvest { position:relative; height:400px; border-radius:22px; overflow:hidden; background:linear-gradient(#cfeaf7,#eaf6fc 70%,#bfe3a8 70%); touch-action:none; user-select:none; -webkit-user-select:none; }
.kid-harvest-tree { position:absolute; top:0; left:0; width:100%; height:90px; z-index:2; }
.kid-harvest-fruit { position:absolute; top:0; left:0; width:54px; height:54px; margin-left:-27px; border-radius:50% 50% 46% 46%; background:radial-gradient(circle at 35% 30%,#ffe08a,#f5a524); color:#5a2d0c; font:700 26px "Noto Sans Tamil",sans-serif; display:grid; place-items:center; box-shadow:0 3px 0 rgba(0,0,0,.14); z-index:1; }
.kid-harvest-fruit.is-caught { transition:transform .25s,opacity .25s; opacity:0; }
.kid-harvest-basket { position:absolute; bottom:14px; left:50%; width:100px; margin-left:-50px; z-index:3; transition:left .08s linear; }
.kid-harvest-basket svg { display:block; width:100%; }
.kid-harvest-basket b { position:absolute; top:14px; left:0; right:0; text-align:center; font-size:20px; font-weight:800; color:#fff; }
.kid-harvest-basket.is-wrong { animation:quest-wrong-shake .28s ease-in-out 2; }
.kid-harvest-basket.is-yum { animation:kid-stone-bob .35s; }
.kid-harvest-start { position:absolute !important; left:50%; top:55%; transform:translate(-50%,-50%); z-index:4; width:auto !important; padding:12px 26px !important; }
.kid-harvest-start[hidden] { display:none !important; }
.learning-slots.is-words .learning-slot b { font-size:30px; line-height:1.2; }
.kid-harvest-left { text-align:center; font-weight:800; color:var(--ink-2); margin:8px 0 0; min-height:1.2em; }
@media (prefers-reduced-motion:reduce) { .kid-river-row.is-now .kid-stone, .kid-river::before { animation:none; } }
/* Monster game: the sound to find sits in a speech bubble above the monster (12 Nov 2026). */
.feed-ask { position:relative; display:inline-flex; align-items:center; gap:10px; min-height:56px; padding:8px 18px 8px 8px; border:0; border-radius:999px; background:#fff6e9; color:#5a2d0c; font:inherit; font-weight:800; font-size:1rem; cursor:pointer; box-shadow:0 6px 14px rgba(90,45,12,.18); margin-bottom:-4px; }
.feed-ask::after { content:""; position:absolute; left:50%; bottom:-9px; width:18px; height:18px; background:inherit; transform:translateX(-50%) rotate(45deg); border-radius:3px; }
.feed-ask svg { width:28px; height:28px; padding:8px; box-sizing:content-box; border-radius:50%; background:#ff6737; color:#fff; animation:quest-listen-pulse 1.8s infinite; position:relative; z-index:1; }
.feed-ask span { position:relative; z-index:1; }
.feed-ask.audio-is-active svg { background:#24805a; }
@media (prefers-reduced-motion:reduce) { .feed-ask svg { animation:none; } }
/* « Continuer » at the top of a series page: straight to the next unfinished step. */
.theme-continue{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px;width:100%;min-height:58px;margin:16px 0 0;padding:10px 18px;text-align:left}
.theme-continue small{font-weight:700;opacity:.9;font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
/* « Tous les mots du thème »: recap of every word of a theme, to review before practising. */
.theme-recap{margin:14px 0 0;border:1px solid var(--line);border-radius:20px;background:var(--card,#fff);overflow:hidden}
.theme-recap summary{padding:14px 18px;font-weight:800;cursor:pointer;list-style:none;display:flex;gap:8px;align-items:center}
.theme-recap summary::-webkit-details-marker{display:none}
.theme-recap summary::after{content:"+";margin-left:auto;font-weight:800}
.theme-recap[open] summary::after{content:"–"}
.theme-recap ul{list-style:none;margin:0;padding:0 12px 12px;display:grid;gap:8px}
.theme-recap li{display:grid;grid-template-columns:48px 1fr auto;gap:12px;align-items:center;padding:8px;border-radius:14px;background:rgba(0,0,0,.03)}
.theme-recap-pic{width:48px;height:48px;display:grid;place-items:center}
.theme-recap-pic svg{width:44px;height:44px}
.theme-recap strong{font-size:20px;display:block}
.theme-recap small{display:block;opacity:.75;font-size:13px}
.theme-recap li button{flex:0 0 44px;width:44px;height:44px;border:1px solid var(--line);border-radius:50%;background:var(--card,#fff);color:var(--ink);display:grid;place-items:center}
.theme-recap li button svg{width:20px;height:20px}
html[data-theme=dark] .theme-recap li{background:rgba(255,255,255,.04)}
