:root {
  --blue: #176fa5;
  --blue-deep: #125d8c;
  --blue-light: #e5f5fc;
  --ink: #244459;
  --muted: #7892a3;
  --green: #57aa50;
  --gold: #f5c443;
  --line: #e6eef2;
  --shadow: 0 26px 75px rgba(37, 95, 125, .15);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  color: var(--ink);
}

* { box-sizing: border-box; }
html { min-width: 320px; background: #e9f5fa; }
body {
  margin: 0;
  min-height: 100vh;
  padding: 26px 18px;
  background:
    radial-gradient(circle at 12% 15%, rgba(255,255,255,.8) 0 2px, transparent 3px) 0 0 / 38px 38px,
    radial-gradient(circle at 70% 38%, rgba(255,255,255,.62) 0 2px, transparent 3px) 0 0 / 46px 46px,
    linear-gradient(135deg, #e7f6fb, #f7fbfd 52%, #e6f3f8);
}
button, input { font: inherit; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid #ffcc4f; outline-offset: 3px; }

.app-shell {
  width: min(100%, 590px);
  min-height: calc(100vh - 52px);
  margin: 0 auto;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(255,255,255,.95);
  border-radius: 25px;
  box-shadow: var(--shadow);
  position: relative;
}
.topbar {
  min-height: 76px;
  padding: 12px 23px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  background-color: var(--blue);
  background-image:
    radial-gradient(ellipse at 10px 8px, rgba(255,255,255,.07) 0 3px, transparent 4px),
    radial-gradient(ellipse at 23px 18px, rgba(255,255,255,.06) 0 5px, transparent 6px),
    radial-gradient(ellipse at 41px 7px, rgba(255,255,255,.06) 0 3px, transparent 4px),
    linear-gradient(115deg, #1c79ac, #12618f);
  background-size: 54px 35px, 54px 35px, 54px 35px, auto;
}
.brand { display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 14px;
  background: rgba(255,255,255,.16);
  font-size: 24px;
}
.brand-copy { display: grid; gap: 1px; }
.brand-copy strong { font-size: 20px; line-height: 1.05; letter-spacing: .1px; }
.brand-copy small { color: rgba(255,255,255,.75); font-size: 10px; font-weight: 700; letter-spacing: .15px; }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.score-pill, .icon-button {
  height: 39px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,.33);
  border-radius: 14px;
  background: rgba(255,255,255,.13);
  color: #fff;
}
.score-pill { min-width: 62px; gap: 6px; padding: 0 10px; font-size: 13px; font-weight: 900; }
.score-pill span:first-child { font-size: 15px; }
.icon-button { width: 40px; font-size: 16px; transition: background .18s, transform .18s; }
.icon-button:hover { background: rgba(255,255,255,.22); transform: translateY(-1px); }
.settings-button { font-size: 17px; }

.settings-dialog {
  width: min(390px, calc(100% - 28px));
  max-width: none;
  padding: 0;
  border: 1px solid #dceaf0;
  border-radius: 18px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 24px 70px rgba(24,72,99,.25);
}
.settings-dialog::backdrop { background: rgba(20,54,72,.42); backdrop-filter: blur(2px); }
.settings-panel { display: grid; gap: 14px; padding: 18px; }
.settings-heading-row { display: flex; align-items: center; justify-content: space-between; }
.settings-heading-row h2 { margin: 0; color: #31566c; font-size: 18px; }
.settings-close { width: 32px; height: 32px; padding: 0; border: 1px solid #e5eef2; border-radius: 10px; color: #7892a3; background: #f8fbfc; font-size: 21px; line-height: 1; }
.settings-field { display: grid; gap: 7px; color: #41667b; font-size: 12px; font-weight: 900; }
.settings-field select { min-height: 42px; padding: 0 11px; border: 1px solid #d7e7ed; border-radius: 10px; color: #286f94; background: #f8fcfd; font: inherit; font-size: 12px; }
.settings-note { margin: 0; color: #8299a6; font-size: 10px; line-height: 1.45; font-weight: 700; }

main { min-height: calc(100vh - 150px); }
.screen { padding: 25px 25px 22px; animation: screen-in .28s ease-out; }
.is-hidden { display: none !important; }
@keyframes screen-in { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: translateY(0); } }

.welcome-panel {
  min-height: 207px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px 19px 22px;
  border-radius: 20px;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 15%, rgba(255,255,255,.38) 0 3px, transparent 4px) 0 0 / 30px 30px,
    linear-gradient(125deg, #eff9fd 0%, #e3f4fb 62%, #d2edf8 100%);
  position: relative;
}
.welcome-panel::after {
  content: "";
  position: absolute;
  width: 195px;
  height: 195px;
  right: -27px;
  bottom: -102px;
  border-radius: 50%;
  background: rgba(117, 195, 223, .14);
}
.welcome-copy { position: relative; z-index: 1; max-width: 340px; }
.eyebrow { color: #6f98ae; font-size: 9px; font-weight: 900; letter-spacing: 1.2px; }
.eyebrow-dot, .live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 5px;
  border-radius: 50%;
  background: #70c16a;
  vertical-align: 1px;
  box-shadow: 0 0 0 3px rgba(112,193,106,.14);
}
.welcome-copy h1 {
  margin: 8px 0 6px;
  color: #24516c;
  font-size: clamp(26px, 5vw, 34px);
  font-weight: 900;
  line-height: .99;
  letter-spacing: -.65px;
}
.welcome-copy h1 span { color: var(--blue); }
.welcome-copy p { max-width: 300px; margin: 9px 0 12px; color: #6c8798; font-size: 12px; line-height: 1.5; font-weight: 600; }
.welcome-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.welcome-tags span {
  padding: 4px 8px;
  color: #3e718c;
  border: 1px solid rgba(71,140,174,.14);
  border-radius: 999px;
  background: rgba(255,255,255,.62);
  font-size: 9px;
  font-weight: 800;
}
.welcome-mascot { position: relative; z-index: 1; display: grid; place-items: center; width: 116px; min-width: 116px; height: 132px; }
.mascot-cat {
  display: grid;
  place-items: center;
  width: 91px;
  height: 91px;
  border: 7px solid rgba(255,255,255,.7);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(50,122,158,.14);
  font-size: 57px;
  transform: rotate(5deg);
}
.mascot-caption {
  position: absolute;
  right: -2px;
  bottom: 7px;
  padding: 4px 10px 5px;
  color: #fff;
  border: 2px solid white;
  border-radius: 999px;
  background: #70b858;
  font-weight: 800;
  font-size: 13px;
  transform: rotate(-6deg);
}
.mascot-sparkle { position: absolute; color: #efbd36; font-size: 21px; }
.sparkle-one { top: 2px; right: 9px; }
.sparkle-two { left: 2px; bottom: 25px; color: #63b8d7; }

.progress-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 13px 0 22px; }
.summary-item {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 9px;
  border: 1px solid #edf2f4;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 4px 11px rgba(39,93,119,.035);
}
.summary-icon { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 30px; border-radius: 10px; font-size: 15px; }
.blue-icon { background: #e9f5fb; }
.yellow-icon { background: #fff7dd; }
.green-icon { background: #edf8e9; }
.summary-item strong, .summary-item small { display: block; white-space: nowrap; }
.summary-item strong { color: #31566c; font-size: 12px; font-weight: 900; }
.summary-item small { margin-top: 1px; color: #91a3ae; font-size: 8px; font-weight: 800; }

.course-picker {
  min-height: 44px;
  margin: -8px 0 18px;
  padding: 7px 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #e0edf2;
  border-radius: 13px;
  background: #fff;
}
.course-picker[hidden] { display: none; }
.course-picker > span { color: #8299a6; font-size: 9px; font-weight: 900; letter-spacing: .7px; }
.course-picker select { max-width: 58%; padding: 7px 28px 7px 10px; border: 1px solid #d7e7ed; border-radius: 9px; color: #286f94; background: #f8fcfd; font: inherit; font-size: 11px; font-weight: 800; }

.album-entry {
  width: 100%;
  margin: -8px 0 18px;
  padding: 9px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #e0edf2;
  border-radius: 14px;
  color: var(--ink);
  background: linear-gradient(110deg, #f8fcfd, #f0f8fb);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(39,93,119,.04);
  transition: transform .15s, border-color .15s, box-shadow .15s;
}
.album-entry:hover { transform: translateY(-1px); border-color: #c7e1eb; box-shadow: 0 7px 15px rgba(39,93,119,.09); }
.album-entry-icon { width: 38px; height: 38px; flex: 0 0 38px; display: grid; place-items: center; border-radius: 12px; background: #e4f3f8; font-size: 21px; }
.album-entry-copy { min-width: 0; flex: 1; display: grid; gap: 2px; }
.album-entry-copy strong { color: #286f94; font-size: 12px; font-weight: 900; }
.album-entry-copy small { color: #8299a6; font-size: 9px; line-height: 1.25; font-weight: 700; }
.album-entry-count { display: flex; align-items: center; gap: 8px; color: #6b94a7; font-size: 10px; font-weight: 900; white-space: nowrap; }
.album-entry-count span { font-size: 17px; }

.review-entry {
  width: 100%;
  min-height: 58px;
  margin: -8px 0 18px;
  padding: 9px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #d7e9d2;
  border-radius: 14px;
  color: var(--ink);
  background: linear-gradient(110deg, #f7fcf3, #edf8e9);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(39,93,119,.04);
  transition: transform .15s, border-color .15s, box-shadow .15s;
}
.review-entry[hidden] { display: none; }
.review-entry:hover { transform: translateY(-1px); border-color: #b9d9ae; box-shadow: 0 7px 15px rgba(39,93,119,.09); }
.review-entry-icon { width: 38px; height: 38px; flex: 0 0 38px; display: grid; place-items: center; border-radius: 12px; background: #e3f2dc; font-size: 19px; }
.review-entry-copy { min-width: 0; flex: 1; display: grid; gap: 2px; }
.review-entry-copy strong { color: #508b48; font-size: 12px; font-weight: 900; }
.review-entry-copy small { color: #82999a; font-size: 9px; line-height: 1.25; font-weight: 700; }
.review-entry-count { display: flex; align-items: center; gap: 8px; color: #5a9652; font-size: 10px; font-weight: 900; white-space: nowrap; }

.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 9px; }
.section-heading .eyebrow { margin-bottom: 2px; font-size: 8px; }
.section-heading h2 { margin: 0; color: #34566a; font-size: 21px; line-height: 1.1; }
.section-heading-actions { display: grid; justify-items: end; gap: 4px; flex: none; }
.map-view-settings-link { padding: 2px 0; border: 0; color: #3d829f; background: transparent; font: inherit; font-size: 9px; line-height: 1.2; font-weight: 800; text-align: right; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.map-view-settings-link:hover { color: #1e6788; }
.map-view-settings-link:focus-visible { outline: 2px solid #79b7d0; outline-offset: 3px; border-radius: 3px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.map-badge {
  padding: 6px 9px;
  color: #7390a0;
  border: 1px solid #edf2f4;
  border-radius: 10px;
  background: #fbfdfe;
  font-size: 9px;
  font-weight: 900;
}
.live-dot { width: 6px; height: 6px; margin-right: 4px; box-shadow: none; }
.category-lock-note {
  margin: 0 0 10px;
  padding: 9px 11px;
  color: #6c8798;
  border: 1px solid #e7f0f3;
  border-radius: 11px;
  background: #f8fcfd;
  font-size: 10px;
  line-height: 1.4;
  font-weight: 700;
}
.category-lock-note.is-open { color: #4f8750; border-color: #e2f0df; background: #f6fbf4; }
.pathway-list { display: grid; gap: 15px; }
.lesson-view-content { display: grid; gap: 10px; }
.lesson-grid-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(145px, .9fr); gap: 8px; }
.lesson-grid-search, .lesson-grid-category {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid #dceaf0;
  border-radius: 11px;
  color: #31566c;
  background: #fbfdfe;
  font-size: 11px;
}
.lesson-grid-search::placeholder { color: #91a6b0; }
.lesson-grid-count { margin: 0; color: #8199a6; font-size: 9px; font-weight: 800; }
.lesson-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lesson-tile {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 12px;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 66px;
  padding: 8px;
  border: 1px solid #e3edf1;
  border-radius: 12px;
  color: #31566c;
  background: #fff;
  text-align: left;
  transition: border-color .16s, background .16s, transform .16s;
}
.lesson-tile:hover { transform: translateY(-1px); border-color: #a9d2e1; background: #f8fcfd; }
.lesson-tile.completed { border-color: #dfedd9; background: #f8fcf6; }
.lesson-tile-number { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 10px; color: #337a9c; background: #eaf5f9; font-size: 9px; font-weight: 900; }
.lesson-tile.completed .lesson-tile-number { color: #56864d; background: #eaf5e4; }
.lesson-tile-copy { display: grid; gap: 4px; min-width: 0; }
.lesson-tile-title { display: -webkit-box; overflow: hidden; color: #31566c; font-size: 9px; line-height: 1.25; font-weight: 900; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.lesson-tile-state { overflow: hidden; color: #8ba0aa; font-size: 7px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.lesson-tile-marker { color: #91adba; font-size: 16px; font-weight: 900; text-align: center; }
.lesson-tile.completed .lesson-tile-marker { color: #5b9b50; }
.lesson-grid-empty { grid-column: 1 / -1; margin: 0; padding: 18px 12px; border: 1px dashed #dceaf0; border-radius: 12px; color: #8299a6; background: #fbfdfe; font-size: 10px; line-height: 1.45; text-align: center; }
.lesson-accordion { gap: 8px; }
.lesson-topic { overflow: hidden; border: 1px solid #e2edf1; border-radius: 13px; background: #fff; }
.lesson-topic summary { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto 14px; align-items: center; gap: 8px; min-height: 54px; padding: 8px 10px; cursor: pointer; list-style: none; }
.lesson-topic summary::-webkit-details-marker { display: none; }
.lesson-topic[open] summary { border-bottom: 1px solid #edf3f5; background: #fbfdfe; }
.topic-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: #eaf5f8; font-size: 17px; }
.lesson-topic[data-category="feelings"] .topic-icon { background: #edf7e9; }
.lesson-topic[data-category="food"] .topic-icon { background: #fff6df; }
.lesson-topic[data-category="social"] .topic-icon { background: #f4eefb; }
.lesson-topic[data-category="adventures"] .topic-icon { background: #eef1fb; }
.topic-title { min-width: 0; color: #31566c; font-size: 10px; line-height: 1.25; font-weight: 900; }
.topic-progress { color: #8299a6; font-size: 8px; font-weight: 900; white-space: nowrap; }
.topic-arrow { color: #87a2ae; font-size: 16px; transition: transform .16s; }
.lesson-topic[open] .topic-arrow { transform: rotate(180deg); }
.topic-lessons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; padding: 9px; }
.pathway-card { padding: 11px; border: 1px solid #e5eef2; border-radius: 17px; background: #fff; box-shadow: 0 4px 12px rgba(39,93,119,.045); }
.pathway-heading { display: flex; align-items: center; gap: 9px; margin: 0 2px 9px; }
.pathway-icon { width: 36px; height: 36px; flex: 0 0 36px; display: grid; place-items: center; border-radius: 11px; background: #e7f4f9; font-size: 20px; }
.pathway-card[data-category="feelings"] .pathway-icon { background: #edf7e9; }
.pathway-card[data-category="food"] .pathway-icon { background: #fff6df; }
.pathway-card[data-category="social"] .pathway-icon { background: #f4eefb; }
.pathway-card[data-category="adventures"] .pathway-icon { background: #eef1fb; }
.pathway-copy { flex: 1; min-width: 0; }
.pathway-title { margin: 0; color: #31566c; font-size: 12px; line-height: 1.2; font-weight: 900; }
.pathway-description { margin: 3px 0 0; color: #8299a6; font-size: 9px; line-height: 1.3; font-weight: 700; }
.pathway-progress { padding: 6px 8px; flex: 0 0 auto; border: 1px solid #e7f0f3; border-radius: 9px; color: #6d8c9d; background: #fbfdfe; font-size: 8px; font-weight: 900; white-space: nowrap; }
.journey-map {
  height: var(--journey-map-height, 1040px);
  margin: 0;
  position: relative;
  overflow: hidden;
  border-radius: 17px;
  background:
    radial-gradient(circle at 50% 50%, rgba(86,170,196,.05), transparent 66%),
    linear-gradient(180deg, #f9fcfd, #f5fafb);
  border: 1px solid #edf3f5;
}
.route-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.route-shadow, .route-line { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.route-shadow { stroke: #e1edf0; stroke-width: 15; }
.route-line { stroke: #b8d9e3; stroke-width: 5; stroke-dasharray: 2 11; }
.nodes-layer { position: absolute; inset: 0; }
.map-node {
  position: absolute;
  width: 74px;
  height: 76px;
  padding: 0;
  border: 0;
  background: transparent;
  transform: translate(-50%, -50%);
  z-index: 2;
  color: var(--ink);
}
.node-orb {
  width: 61px;
  height: 61px;
  margin: 0 auto;
  display: grid;
  place-items: center;
  border: 5px solid #fff;
  border-radius: 50%;
  background: #d9e3e8;
  box-shadow: 0 5px 0 #c8d9df, 0 8px 15px rgba(55,104,126,.12);
  color: #fff;
  font-size: 21px;
  font-weight: 900;
  transition: transform .16s, box-shadow .16s;
}
.map-node:hover:not(:disabled) .node-orb { transform: translateY(-3px) scale(1.04); box-shadow: 0 8px 0 #c8d9df, 0 12px 18px rgba(55,104,126,.17); }
.map-node.active .node-orb { background: #f2c34b; box-shadow: 0 5px 0 #d5a73a, 0 8px 18px rgba(213,167,58,.26); animation: node-pulse 2s ease-in-out infinite; }
.map-node.completed .node-orb { background: #66b75c; box-shadow: 0 5px 0 #448c43, 0 8px 16px rgba(68,140,67,.18); }
.map-node.unlocked .node-orb { background: #429bc3; box-shadow: 0 5px 0 #287da4, 0 8px 16px rgba(40,125,164,.18); }
.map-node:disabled { cursor: default; }
.map-node:disabled .node-orb { opacity: .84; }
.node-label {
  position: absolute;
  top: 63px;
  left: 50%;
  width: 142px;
  transform: translateX(-50%);
  color: #617f91;
  font-size: 9px;
  line-height: 1.1;
  font-weight: 900;
  text-shadow: 0 1px 0 #fff;
}
.map-node-label-right .node-label { left: 0; transform: none; text-align: left; }
.map-node-label-left .node-label { left: auto; right: 0; transform: none; text-align: right; }
.map-node.active .node-label { color: #b48722; }
.node-number {
  position: absolute;
  top: 1px;
  right: 2px;
  z-index: 1;
  width: 19px;
  height: 19px;
  display: grid;
  place-items: center;
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #70a2b8;
  font-size: 9px;
  font-weight: 900;
}
.map-node.active .node-number { background: #eeac2e; }
.map-node.completed .node-number { background: #438b43; }
@keyframes node-pulse { 0%,100% { box-shadow: 0 5px 0 #d5a73a, 0 8px 18px rgba(213,167,58,.22); } 50% { box-shadow: 0 5px 0 #d5a73a, 0 9px 25px rgba(213,167,58,.42); } }

.map-note {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 14px 0 0;
  padding: 12px 15px;
  border: 1px solid #e8f2ed;
  border-radius: 15px;
  background: #f5fbf5;
  position: relative;
}
.note-cat { width: 40px; height: 40px; flex: 0 0 40px; display: grid; place-items: center; border-radius: 12px; background: #e6f4e3; font-size: 24px; }
.map-note strong { color: #47734b; font-size: 11px; font-weight: 900; }
.map-note p { margin: 2px 0 0; color: #8aa08a; font-size: 9px; line-height: 1.35; font-weight: 700; }
.note-star { position: absolute; top: 10px; right: 14px; color: #e6bb44; font-size: 15px; }
.prototype-note { margin: 15px 0 0; color: #a5b4bd; text-align: center; font-size: 8px; font-weight: 700; letter-spacing: .2px; }

.album-screen { min-height: calc(100vh - 150px); }
.album-count { padding: 6px 9px; border: 1px solid #e7f0f3; border-radius: 10px; color: #7390a0; background: #f8fbfc; font-size: 9px; font-weight: 900; white-space: nowrap; }
.album-controls { display: grid; gap: 7px; margin: 0 0 11px; }
.album-search { width: 100%; min-height: 40px; padding: 0 11px; border: 1px solid #dce9ee; border-radius: 10px; color: #35596e; background: #fbfdfe; font: inherit; font-size: 11px; }
.album-actions { display: flex; justify-content: flex-end; gap: 6px; }
.album-shuffle { min-height: 36px; padding: 0 11px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid #e4eadb; border-radius: 10px; color: #718c56; background: #f8fbf2; font-size: 10px; font-weight: 900; }
.album-slideshow-start { min-height: 36px; padding: 0 11px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid #d8eaf1; border-radius: 10px; color: #347b9c; background: #f1f9fc; font-size: 10px; font-weight: 900; }
.album-slideshow-start:disabled { opacity: .5; cursor: default; }
.album-topic-filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.album-topic-filter { min-width: 0; min-height: 38px; padding: 5px 7px; display: flex; align-items: center; justify-content: space-between; gap: 4px; border: 1px solid #e0ebef; border-radius: 9px; color: #648294; background: #fff; text-align: left; font: inherit; font-size: 9px; line-height: 1.15; font-weight: 800; }
.album-topic-filter[aria-pressed="true"] { border-color: #aed5e7; color: #176fa5; background: #edf8fc; box-shadow: inset 0 0 0 1px #d3eaf4; }
.album-topic-filter span { overflow-wrap: anywhere; }
.album-topic-filter small { flex: none; color: #99aeb8; font-size: 8px; font-weight: 900; }
.album-result-count { min-height: 13px; margin: 0; color: #93a8b2; font-size: 9px; font-weight: 800; }
.album-empty { grid-column: 1 / -1; margin: 0; padding: 18px 10px; border: 1px dashed #d8e6eb; border-radius: 12px; color: #8198a5; text-align: center; font-size: 11px; }
.album-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.album-card { min-width: 0; overflow: hidden; border: 1px solid #e5edf1; border-radius: 13px; background: #fff; box-shadow: 0 4px 12px rgba(39,93,119,.055); }
.album-photo-open { display: block; width: 100%; padding: 0; overflow: hidden; border: 0; background: #edf6f8; text-align: left; cursor: zoom-in; }
.album-photo { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #edf6f8; }
.album-card-copy { min-height: 66px; padding: 9px 8px; display: grid; justify-items: center; gap: 7px; }
.album-card-text { min-width: 0; width: 100%; display: grid; justify-items: center; align-content: start; gap: 4px; text-align: center; }
.album-card-open { padding: 0; border: 0; color: inherit; background: transparent; text-align: center; cursor: zoom-in; }
.album-phrase { color: #286f9a; font-size: 12px; line-height: 1.2; font-weight: 900; overflow-wrap: anywhere; }
.album-meaning { color: #8198a5; font-size: 9px; line-height: 1.3; font-weight: 700; }
.album-audio { width: 36px; height: 36px; flex: 0 0 36px; padding: 0; border: 1px solid #dcecf3; border-radius: 9px; color: #3580a4; background: #f0f8fb; font-size: 15px; transition: background .15s, transform .15s; }
.album-audio:hover { background: #e2f3f9; transform: translateY(-1px); }
.album-audio.is-playing { border-color: #bfe1b9; background: #e6f5e3; }
.album-dialog { width: min(520px, calc(100% - 28px)); max-width: none; max-height: calc(100vh - 28px); max-height: calc(100dvh - 28px); margin: auto; padding: 0; overflow-y: auto; border: 1px solid #dceaf0; border-radius: 19px; color: var(--ink); background: #fff; box-shadow: 0 24px 70px rgba(24,72,99,.25); }
.album-dialog::backdrop { background: rgba(20,54,72,.52); backdrop-filter: blur(3px); }
.album-dialog-panel { padding: 13px; }
.album-dialog-toolbar { min-height: 34px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.album-dialog-position { color: #87a0ad; font-size: 10px; font-weight: 900; }
.album-dialog-close { width: 34px; height: 34px; padding: 0; border: 1px solid #e5eef2; border-radius: 10px; color: #7892a3; background: #f8fbfc; font-size: 22px; line-height: 1; }
.album-dialog-content { display: grid; gap: 14px; }
.album-dialog-photo { display: block; width: 100%; height: min(52vh, 420px); object-fit: contain; border: 1px solid #e4eef2; border-radius: 13px; background: #edf6f8; }
.album-dialog-copy { display: grid; justify-items: start; gap: 7px; padding: 0 2px 2px; }
.album-dialog-topic { color: #8aa2ae; font-size: 9px; font-weight: 900; letter-spacing: .45px; }
.album-dialog-copy h2 { margin: 0; color: #286f9a; font-size: clamp(19px, 5vw, 25px); line-height: 1.16; overflow-wrap: anywhere; }
.album-dialog-meaning { margin: 0; color: #6f8998; font-size: 14px; line-height: 1.4; font-weight: 700; }
.album-dialog-audio { min-height: 39px; margin-top: 3px; padding: 0 12px; display: inline-flex; align-items: center; gap: 8px; border: 1px solid #dcecf3; border-radius: 10px; color: #31799c; background: #f0f8fb; font-size: 12px; font-weight: 800; }
.album-dialog-audio.is-playing { border-color: #bfe1b9; background: #e6f5e3; }
.album-dialog-navigation { display: flex; justify-content: space-between; gap: 10px; margin-top: 13px; padding-top: 11px; border-top: 1px solid #edf2f4; }
.album-dialog-nav { min-height: 39px; padding: 0 11px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid #e0ebef; border-radius: 10px; color: #4e7588; background: #fff; font-size: 11px; font-weight: 900; }
.album-dialog-nav:disabled { color: #b4c1c7; background: #f8fafb; cursor: default; }
.album-slideshow-dialog { width: min(520px, calc(100% - 28px)); max-width: none; max-height: calc(100vh - 28px); max-height: calc(100dvh - 28px); margin: auto; padding: 0; overflow-y: auto; border: 1px solid #dceaf0; border-radius: 19px; color: var(--ink); background: #fff; box-shadow: 0 24px 70px rgba(24,72,99,.25); }
.album-slideshow-dialog::backdrop { background: rgba(20,54,72,.52); backdrop-filter: blur(3px); }
.album-slideshow-panel { padding: 12px; }
.album-slideshow-toolbar { min-height: 32px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px; }
.album-slideshow-position { color: #87a0ad; font-size: 10px; font-weight: 900; }
.album-slideshow-photo { display: block; width: 100%; height: min(48vh, 400px); object-fit: contain; border: 1px solid #e4eef2; border-radius: 13px; background: #edf6f8; touch-action: pan-y; }
.album-slideshow-copy { display: grid; justify-items: center; gap: 7px; padding: 11px 3px 4px; text-align: center; }
.album-slideshow-copy h2 { margin: 0; color: #286f9a; font-size: clamp(19px, 5vw, 25px); line-height: 1.16; overflow-wrap: anywhere; }
.album-slideshow-meaning { margin: 0; color: #55788a; font-size: 14px; line-height: 1.35; font-weight: 800; }
.album-slideshow-controls { display: flex; justify-content: space-between; align-items: center; gap: 6px; margin-top: 9px; padding-top: 9px; border-top: 1px solid #edf2f4; }
.album-slideshow-controls .album-dialog-nav { min-width: 0; padding: 0 8px; font-size: 10px; }
.album-slideshow-play { min-height: 39px; min-width: 82px; padding: 0 9px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid #d5e9f0; border-radius: 10px; color: #28789c; background: #eff8fb; font-size: 10px; font-weight: 900; }
.album-slideshow-play:disabled { color: #8ca0aa; background: #f6f9fa; cursor: default; }
.album-slideshow-footer { margin-top: 7px; display: flex; align-items: center; justify-content: space-between; gap: 7px; flex-wrap: wrap; }
.album-slideshow-speed { display: flex; align-items: center; gap: 5px; margin: 0; color: #89a0ac; font-size: 8px; font-weight: 800; white-space: nowrap; }
.album-slideshow-speed select { min-height: 26px; padding: 0 6px; border: 1px solid #e0ebef; border-radius: 7px; color: #55788a; background: #fff; font: inherit; font-size: 8px; }
.album-slideshow-meaning-setting { min-height: 24px; margin: 0; padding: 0; display: inline-flex; align-items: center; justify-content: flex-end; gap: 5px; border: 0; color: #628497; background: transparent; font-size: 8px; font-weight: 800; white-space: nowrap; cursor: pointer; }
.album-slideshow-meaning-setting input { appearance: none; width: 26px; height: 15px; flex: 0 0 26px; margin: 0; position: relative; border: 1px solid #d7e4e9; border-radius: 99px; background: #e9f0f3; cursor: pointer; transition: background .18s, border-color .18s; }
.album-slideshow-meaning-setting input::before { content: ""; position: absolute; top: 1px; left: 1px; width: 11px; height: 11px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(35,72,91,.2); transition: transform .18s; }
.album-slideshow-meaning-setting input:checked { border-color: #67b44c; background: #78bf57; }
.album-slideshow-meaning-setting input:checked::before { transform: translateX(11px); }
.album-slideshow-meaning-setting input:focus-visible { outline: 3px solid rgba(49,132,169,.3); outline-offset: 2px; }

.play-screen { padding-top: 20px; }
.lesson-toolbar { display: flex; align-items: center; gap: 12px; }
.back-button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  padding: 0;
  border: 1px solid #e7eef1;
  border-radius: 13px;
  color: #6790a5;
  background: #f8fbfc;
  font-size: 22px;
  transition: transform .15s, background .15s;
}
.back-button:hover { background: #edf7fb; transform: translateX(-2px); }
.lesson-heading { flex: 1; min-width: 0; }
.lesson-kicker { display: block; color: #93a8b5; font-size: 8px; letter-spacing: 1px; font-weight: 900; }
.lesson-heading h1 { margin: 1px 0 0; color: #31566c; font-size: 18px; line-height: 1.05; }
.question-counter { color: #a2b4be; font-size: 13px; font-weight: 900; }
.question-counter span { color: #c3cfd5; }
.lesson-progress-track { height: 8px; margin: 15px 0 14px; overflow: hidden; border-radius: 999px; background: #edf2f4; }
.lesson-progress-fill { width: 20%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #64b75c, #8dcf5d); transition: width .32s ease; }
.challenge-line { display: flex; align-items: center; justify-content: space-between; margin: 1px 0 10px; }
.challenge-chip { padding: 5px 8px; color: #2f7da0; border: 1px solid #dcedf4; border-radius: 7px; background: #eff8fb; font-size: 8px; font-weight: 900; letter-spacing: .7px; }
.hint-button { width: 36px; height: 36px; flex: 0 0 36px; padding: 0; border: 1px solid #e9eef0; border-radius: 50%; color: #9aafb9; background: #fff; font-weight: 900; font-size: 14px; }
.question-card { padding: 0 3px; }
.photo-frame {
  width: min(100%, 328px);
  aspect-ratio: 1 / .78;
  margin: 0 auto;
  padding: 7px;
  position: relative;
  overflow: hidden;
  border: 1px solid #dce8ed;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 16px rgba(52,101,124,.09);
}
.photo-frame img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 9px; background: #edf6f8; }
.photo-stamp {
  position: absolute;
  right: 13px;
  bottom: 13px;
  padding: 4px 7px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 6px;
  background: rgba(24,92,129,.7);
  font-size: 7px;
  letter-spacing: .5px;
  font-weight: 900;
  backdrop-filter: blur(4px);
}
.question-copy { padding: 11px 4px 7px; text-align: center; }
.prompt-label-row { min-height: 40px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px 8px; }
.prompt-label { color: #8ca5b2; font-size: 8px; font-weight: 900; letter-spacing: 1px; }
.audio-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 40px;
  padding: 6px 10px;
  border: 1px solid #dcecf3;
  border-radius: 9px;
  color: #3580a4;
  background: #f0f8fb;
  font-size: 9px;
  font-weight: 900;
  transition: background .15s, transform .15s;
}
.audio-button:hover { background: #e2f3f9; }
.audio-button:active { transform: scale(.97); }
.audio-button:disabled { opacity: .48; cursor: not-allowed; }
.audio-button span:first-child { font-size: 13px; }
.audio-button.is-playing { background: #e6f5e3; border-color: #bfe1b9; }
.phrase-line { min-height: 34px; margin: 2px 0 0; color: #286f9a; font-size: clamp(24px, 6vw, 30px); font-weight: 900; line-height: 1.05; }
.phrase-line.is-concealed { color: #abbac2; letter-spacing: 2px; }
.question-cue { margin: 2px 0 0; color: #899fab; font-size: 10px; font-weight: 700; }
.answer-area { display: grid; gap: 8px; margin: 10px 5px 0; }
.answer-button {
  min-height: 45px;
  padding: 9px 12px;
  border: 1px solid #17699b;
  border-radius: 10px;
  color: #fff;
  background: linear-gradient(180deg, #2581b7, #17699d);
  box-shadow: 0 3px 0 #0e5685, 0 6px 12px rgba(32,108,153,.12);
  font-size: 14px;
  line-height: 1.2;
  font-weight: 800;
  transition: transform .14s, filter .14s, box-shadow .14s;
}
.answer-button:hover:not(:disabled) { filter: brightness(1.06); transform: translateY(-1px); box-shadow: 0 4px 0 #0e5685, 0 8px 14px rgba(32,108,153,.16); }
.answer-button:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 #0e5685; }
.answer-button:disabled { cursor: default; }
.answer-button.is-correct { border-color: #4c9f47; background: linear-gradient(180deg, #6bb75e, #55a54b); box-shadow: 0 3px 0 #41813d; }
.answer-button.is-wrong { border-color: #d77a6e; background: linear-gradient(180deg, #e8907e, #d87868); box-shadow: 0 3px 0 #bd6357; }
.answer-button.was-correct { border-color: #63ad5b; background: linear-gradient(180deg, #71b967, #5eaa54); box-shadow: 0 3px 0 #458c41; }

.word-order-area { display: grid; gap: 12px; }
.word-bank, .word-answer { min-height: 43px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 7px; }
.word-answer { padding: 5px; border-bottom: 2px dashed #cddde4; }
.word-chip { min-height: 34px; padding: 5px 12px; border: 1px solid #c9e3ee; border-radius: 9px; color: #317a9f; background: #f1f9fc; font-size: 13px; font-weight: 900; box-shadow: 0 2px 0 #d9ebf1; }
.word-chip.selected { color: #fff; border-color: #3784aa; background: #3b91b8; box-shadow: 0 2px 0 #287395; }
.check-order-button, .typing-submit { min-height: 43px; border: 0; border-radius: 10px; color: white; background: #287fa9; box-shadow: 0 3px 0 #1b668b; font-size: 12px; font-weight: 900; }
.check-order-button:disabled { cursor: not-allowed; opacity: .45; }
.typing-area { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.typing-input { min-width: 0; min-height: 44px; padding: 0 12px; border: 1px solid #d9e8ee; border-radius: 10px; color: #31566c; background: #fbfdfe; font-size: 14px; font-weight: 700; }
.typing-input::placeholder { color: #a6b7c0; }
.typing-submit { padding: 0 15px; }
.typing-question-options { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.typing-skip-button { min-height: 36px; padding: 6px 0; border: 0; color: #64899b; background: transparent; font-size: 10px; font-weight: 900; text-decoration: underline; text-underline-offset: 2px; }
.typing-auto-skip { display: inline-flex; align-items: center; gap: 5px; color: #8299a6; font-size: 9px; line-height: 1.3; font-weight: 700; }
.typing-auto-skip input { width: 14px; height: 14px; margin: 0; accent-color: #58a750; }

.feedback-panel {
  min-height: 63px;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 12px 4px 0;
  padding: 9px 10px;
  border: 1px solid #dbeed7;
  border-radius: 13px;
  background: #f0f9ed;
  animation: feedback-in .2s ease-out;
}
.feedback-panel.is-wrong { border-color: #f1ddd8; background: #fff4f1; }
.feedback-icon { width: 30px; height: 30px; flex: 0 0 30px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: #64af57; font-size: 16px; font-weight: 900; }
.feedback-panel.is-wrong .feedback-icon { background: #df8172; }
.feedback-copy { flex: 1; min-width: 0; display: grid; gap: 1px; }
.feedback-copy strong { color: #4b9446; font-size: 13px; font-weight: 900; }
.feedback-panel.is-wrong .feedback-copy strong { color: #bf685b; }
.feedback-copy span { overflow: hidden; color: #78937b; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.feedback-panel.is-wrong .feedback-copy span { color: #a0837d; }
.continue-button { min-height: 36px; flex: 0 0 auto; padding: 0 12px; border: 0; border-radius: 9px; color: #fff; background: #59a84f; box-shadow: 0 2px 0 #438d3e; font-size: 10px; font-weight: 900; }
.feedback-panel.is-wrong .continue-button { background: #d77d6c; box-shadow: 0 2px 0 #bb6454; }
.continue-button span { margin-left: 3px; color: #fff; font-size: 14px; }
@keyframes feedback-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.lesson-footer { display: flex; justify-content: space-between; gap: 8px; margin: 13px 4px 0; color: #a1b2bb; font-size: 8px; font-weight: 800; }
.lesson-footer span:first-child span { color: #77aa76; }
.keyboard-hint { text-align: right; }

.result-screen { min-height: 620px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding-top: 35px; text-align: center; }
.result-confetti { margin: -10px 0 3px; color: #e9bd48; font-size: 22px; letter-spacing: 8px; }
.result-mascot { width: 102px; height: 102px; display: grid; place-items: center; margin: 4px 0 11px; border: 7px solid #fff; border-radius: 31px; background: #e8f6fb; box-shadow: 0 7px 20px rgba(43,113,146,.13); font-size: 61px; transform: rotate(-5deg); }
.result-screen h1 { margin: 5px 0 0; color: #24749c; font-size: 38px; line-height: 1; }
.result-subtitle { margin: 5px 0 3px; color: #879da9; font-size: 12px; font-weight: 700; }
.result-stars { margin: 13px 0 16px; font-size: 24px; letter-spacing: 7px; filter: drop-shadow(0 2px 1px rgba(198,151,50,.16)); }
.result-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; width: min(100%, 360px); margin: 0 0 20px; }
.result-stats div { padding: 13px; border: 1px solid #e8f0f3; border-radius: 14px; background: #fbfdfe; }
.result-stats strong, .result-stats span { display: block; }
.result-stats strong { color: #3b718e; font-size: 18px; font-weight: 900; }
.result-stats span { margin-top: 2px; color: #98aab4; font-size: 9px; font-weight: 800; }
.lesson-review { width: min(100%, 520px); margin: 0 0 18px; text-align: left; }
.lesson-review h2 { margin: 0; color: #24749c; font-size: 18px; }
.lesson-review-note { margin: 3px 0 10px; color: #879da9; font-size: 10px; font-weight: 700; }
.lesson-review-list { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.lesson-review-item { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; align-items: center; gap: 9px; padding: 9px; border: 1px solid #e8f0f3; border-radius: 14px; background: #fbfdfe; }
.lesson-review-photo { width: 42px; height: 42px; border-radius: 11px; object-fit: cover; }
.lesson-review-copy { min-width: 0; text-align: left; }
.lesson-review-label, .lesson-review-phrase, .lesson-review-meaning, .lesson-review-detail, .lesson-review-answer { display: block; }
.lesson-review-label { color: #91a6b1; font-size: 8px; font-weight: 900; letter-spacing: .35px; }
.lesson-review-phrase { overflow-wrap: anywhere; color: #347a9c; font-size: 12px; font-weight: 900; }
.lesson-review-meaning { color: #718b98; font-size: 10px; font-weight: 700; }
.lesson-review-detail { margin-top: 3px; }
.lesson-review-status { color: #708c99; font-size: 9px; font-weight: 900; }
.lesson-review-status.is-correct { color: #59984e; }
.lesson-review-status.is-wrong { color: #bd6a65; }
.lesson-review-status.is-skipped { color: #aa8b4c; }
.lesson-review-answer { overflow-wrap: anywhere; color: #8599a3; font-size: 9px; font-weight: 700; }
.lesson-review-retry { min-height: 34px; padding: 0 9px; color: #347a9c; border: 1px solid #dbe9ef; border-radius: 9px; background: #fff; font-size: 9px; font-weight: 900; }
.retry-notice { margin: 9px 0 0; padding: 8px 11px; color: #5d9856; border-radius: 10px; background: #eff8ec; font-size: 10px; font-weight: 800; }
.result-actions { display: grid; gap: 9px; width: min(100%, 330px); }
.primary-button, .secondary-button { min-height: 46px; border-radius: 11px; font-size: 12px; font-weight: 900; }
.primary-button { color: #fff; border: 1px solid #17699b; background: linear-gradient(180deg, #2581b7, #17699d); box-shadow: 0 3px 0 #0e5685; }
.primary-button span { margin-left: 5px; font-size: 16px; }
.secondary-button { color: #58819a; border: 1px solid #dbe9ef; background: #f7fbfd; }
.unlock-message { margin: 13px 0 0; padding: 8px 12px; color: #5d9856; border-radius: 10px; background: #eff8ec; font-size: 10px; font-weight: 800; }

.app-footer { display: flex; justify-content: space-between; padding: 12px 25px 14px; color: #a0b1bb; border-top: 1px solid #edf2f4; background: #fcfefe; font-size: 8px; font-weight: 800; }
.app-footer b { color: #e99482; }
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 20;
  max-width: calc(100% - 30px);
  padding: 10px 14px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 11px;
  background: rgba(35,78,99,.94);
  box-shadow: 0 10px 25px rgba(27,76,101,.2);
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity .2s, transform .2s;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 520px) {
  body { padding: 0; background: #fff; }
  .app-shell { width: 100%; min-height: 100vh; border: 0; border-radius: 0; box-shadow: none; }
  .topbar { min-height: 69px; padding: 10px 17px; }
  .brand-mark { width: 39px; height: 39px; border-radius: 12px; }
  .brand-copy strong { font-size: 18px; }
  .brand-copy small { font-size: 9px; }
  .screen { padding: 19px 17px 19px; }
  .welcome-panel { min-height: 193px; padding: 16px 13px 17px 16px; }
  .welcome-copy h1 { font-size: 29px; }
  .welcome-copy p { max-width: 250px; font-size: 11px; }
  .welcome-mascot { width: 91px; min-width: 91px; height: 114px; }
  .mascot-cat { width: 77px; height: 77px; border-width: 6px; border-radius: 24px; font-size: 48px; }
  .mascot-caption { right: -4px; bottom: 8px; font-size: 11px; }
  .progress-summary { gap: 6px; margin: 11px 0 19px; }
  .summary-item { gap: 6px; padding: 8px 6px; border-radius: 12px; }
  .summary-icon { width: 26px; height: 26px; flex-basis: 26px; border-radius: 8px; font-size: 13px; }
  .summary-item strong { font-size: 10px; }
  .summary-item small { font-size: 7px; }
  .journey-map { height: var(--journey-map-height, 1040px); }
  .section-heading { align-items: flex-start; flex-wrap: wrap; gap: 6px 10px; }
  .section-heading-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
  .map-view-settings-link { font-size: 8px; }
  .album-actions { justify-content: stretch; }
  .album-actions > button { width: auto; min-width: 0; flex: 1; justify-content: center; min-height: 40px; padding: 0 7px; font-size: 9px; }
  .album-topic-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .album-topic-filter { min-height: 42px; font-size: 10px; }
  .node-orb { width: 56px; height: 56px; border-width: 4px; font-size: 18px; }
  .node-label { top: 58px; font-size: 8px; }
  .play-screen { padding-top: 15px; }
  .photo-frame { width: min(100%, 330px); aspect-ratio: 1 / .75; }
  .question-copy { padding-top: 9px; }
  .phrase-line { font-size: 27px; }
  .answer-area { margin-top: 8px; gap: 7px; }
  .answer-button { min-height: 43px; font-size: 13px; }
  .feedback-panel { margin-top: 10px; }
  .lesson-footer { margin-top: 11px; }
  .result-screen { min-height: calc(100vh - 140px); }
  .audio-button { min-height: 44px; }
  .typing-input { font-size: 16px; }
  .word-chip { min-height: 40px; }
  .app-footer { padding-right: 17px; padding-left: 17px; }
}
@media (max-width: 370px) {
  .topbar { padding-right: 11px; padding-left: 11px; }
  .topbar-actions { gap: 5px; }
  .score-pill { min-width: 51px; padding-right: 7px; padding-left: 7px; }
  .topbar-actions .icon-button { width: 34px; }
  .brand { gap: 7px; }
  .brand-mark { width: 35px; height: 35px; }
  .brand-copy { min-width: 0; }
  .brand-copy strong { font-size: 15px; }
  .brand-copy small { display: none; }
  .welcome-mascot { width: 72px; min-width: 72px; }
  .mascot-cat { width: 68px; height: 68px; font-size: 41px; }
  .welcome-copy h1 { font-size: 26px; }
  .summary-icon { display: none; }
  .summary-item { justify-content: center; }
  .summary-item strong, .summary-item small { text-align: center; }
  .continue-button { padding: 0 9px; font-size: 9px; }
  .keyboard-hint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
