/* =====================================================================
   Sign Educator — styles
   Mobile-first. Palette follows the KDLC (Kyazanga Discovery and Learning
   Center) brand: navy #12307A, royal blue #1F5FBF, warm amber #F0A04B,
   sand #EFB877, cream #FDF9F3, green #2F7D4F. Token names (--orange,
   --yellow, --blue) are kept from the first palette: --orange is now the
   amber accent, --yellow the sand, --blue the KDLC navy. White text on
   amber or sand fails WCAG AA, so those surfaces carry dark "ink" text,
   and amber is never used for body text (use --orange-dark).

   Contents
     1. Tokens            6. Header, nav & footer     11. Lesson screen
     2. Base              7. Layout & sections        12. Search
     3. Buttons           8. Feedback (flash, toast)  13. Parents & profile
     4. Forms             9. Landing & auth           14. Admin
     5. Chips & tags     10. Dashboard & cards        15. Motion preferences
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. Tokens
   --------------------------------------------------------------------- */
:root {
  --orange: #F0A04B;          /* KDLC amber accent: ink text only */
  --orange-dark: #7F430B;     /* AA as text on cream, white and the sand hero cards */
  --orange-edge: #C47A2C;     /* 3:1 on white, used for amber borders */
  --orange-soft: #FCE9D2;
  --blue: #12307A;            /* KDLC navy: white text */
  --blue-dark: #0B1F52;       /* KDLC navy-dark */
  --blue-edge: #081740;
  --blue-soft: #E6EFFF;
  --blue-bright: #1F5FBF;     /* KDLC royal blue: links */
  --yellow: #EFB877;          /* KDLC sand: ink text only */
  --yellow-edge: #D09553;
  --yellow-soft: #FBF0E2;     /* KDLC sand-soft */
  --cream: #FDF9F3;
  --white: #FFFFFF;
  --surface: #FFFFFF;
  --surface-2: #FFFCF8;
  --ink: #1D2433;
  --ink-soft: #4A5468;
  --green: #2F7D4F;
  --green-dark: #1F5A37;
  --green-soft: #E3F3E9;
  --red: #B91C1C;
  --red-dark: #7F1D1D;
  --red-soft: #FEE2E2;
  --purple-soft: #EDE9FE;
  --line: #E4E8F1;
  --line-strong: #C9D0DE;
  --field: #8A93A8;           /* form field borders: 3:1 on white */

  --r-sm: 12px;
  --r: 16px;
  --r-lg: 22px;
  --r-xl: 28px;
  --shadow-sm: 0 1px 2px rgba(11, 31, 82, .06);
  --shadow: 0 1px 2px rgba(11, 31, 82, .05), 0 6px 20px rgba(11, 31, 82, .07);
  --shadow-lg: 0 2px 4px rgba(11, 31, 82, .06), 0 16px 36px rgba(11, 31, 82, .14);

  --font-body: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Poppins', 'Nunito', system-ui, sans-serif;
  --tap: 48px;
  --bottom-nav: 76px;
  --gutter: 16px;
  --container: 1120px;
  --section-gap: 2.25rem;
}
.is-admin { --container: 1240px; }

/* Accessibility preferences (Profile → "Make it easier to see") */
html.pref-large-text { font-size: 118.75%; }
html.pref-high-contrast {
  --cream: #FFFFFF;
  --surface-2: #FFFFFF;
  --ink: #000000;
  --ink-soft: #000000;
  --line: #000000;
  --line-strong: #000000;
  --blue: #0B1F52;
  --orange-soft: #FFFFFF;
  --blue-soft: #FFFFFF;
  --yellow-soft: #FFFFFF;
  --shadow-sm: none;
  --shadow: none;
  --shadow-lg: none;
}
html.pref-high-contrast a:not(.btn):not(.chip):not(.main-nav__link) { text-decoration-thickness: 2px; }
html.pref-high-contrast :is(.panel, .sign-card, .lesson-card, .stat-card, .badge-tile, .sign-panel, .player-card) { border-width: 2px; }

/* ---------------------------------------------------------------------
   2. Base
   --------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.55;
  overflow-x: hidden;
}
body.has-nav { padding-bottom: calc(var(--bottom-nav) + env(safe-area-inset-bottom, 0px)); }

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; margin: 0 0 .5em; color: var(--ink); }
p { margin: 0 0 1em; }
img, video { max-width: 100%; display: block; }
a { color: var(--blue-bright); text-underline-offset: 3px; }
a:hover { color: var(--blue); }
ul, ol { padding-left: 1.25rem; }
small { font-size: .875rem; }
strong { font-weight: 800; }
[hidden] { display: none !important; }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  box-shadow: 0 0 0 7px var(--yellow);
  border-radius: 6px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem; top: -100px;
  z-index: 200;
  padding: .75rem 1.25rem;
  background: var(--yellow);
  color: var(--ink);
  font-weight: 800;
  border-radius: var(--r-sm);
}
.skip-link:focus { top: 1rem; }

.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Emoji at the start of a heading sits in a soft rounded tile, so icon-led
   headings line up the same way everywhere. */
:is(.page-title, .section__title, .panel__title, .auth-card__title) {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .6rem;
}
:is(.page-title, .section__title, .panel__title, .auth-card__title) > span[aria-hidden="true"]:first-child {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 2.1em;
  height: 2.1em;
  border-radius: .65em;
  background: var(--yellow-soft);
  font-size: .78em;
  line-height: 1;
}

/* Thin, rounded scrollbars for sideways shelves */
.scroller, .shelf, .chip-list--scroll, .child-tabs ul, .admin-tabs ul, .table-wrap {
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}
:is(.scroller, .shelf, .chip-list--scroll, .child-tabs ul, .table-wrap)::-webkit-scrollbar { height: 8px; }
:is(.scroller, .shelf, .chip-list--scroll, .child-tabs ul, .table-wrap)::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; }

/* ---------------------------------------------------------------------
   3. Buttons
   --------------------------------------------------------------------- */
.btn {
  --btn-bg: var(--surface);
  --btn-fg: var(--ink);
  --btn-border: var(--line-strong);
  --btn-edge: rgba(11, 31, 82, .10);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  min-height: var(--tap);
  padding: .6rem 1.25rem;
  border: 1.5px solid var(--btn-border);
  border-radius: var(--r);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: 800 1rem/1.2 var(--font-body);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 3px 0 var(--btn-edge);
  transition: transform .12s ease, box-shadow .12s ease, background-color .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { color: var(--btn-fg); transform: translateY(-1px); }
.btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--btn-edge); }
.btn:disabled, .btn.is-disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

.btn-primary   { --btn-bg: var(--orange); --btn-fg: var(--ink); --btn-border: var(--orange); --btn-edge: var(--orange-edge); }
.btn-primary:hover { --btn-bg: #F4AD5F; }
.btn-secondary { --btn-bg: var(--blue); --btn-fg: var(--white); --btn-border: var(--blue); --btn-edge: var(--blue-edge); }
.btn-secondary:hover { --btn-bg: var(--blue-dark); }
.btn-accent    { --btn-bg: var(--yellow); --btn-fg: var(--ink); --btn-border: var(--yellow); --btn-edge: var(--yellow-edge); }
.btn-ghost:hover { --btn-bg: var(--surface-2); --btn-border: var(--ink-soft); }
.btn-danger    { --btn-fg: var(--red); --btn-border: #F0C2C2; }
.btn-danger:hover { --btn-bg: var(--red-soft); --btn-fg: var(--red); }
.btn-success   { --btn-bg: var(--green); --btn-fg: var(--white); --btn-border: var(--green); --btn-edge: var(--green-dark); }

.btn-small { min-height: 40px; padding: .35rem .85rem; font-size: .92rem; border-radius: var(--r-sm); box-shadow: 0 2px 0 var(--btn-edge); }
.btn-lg    { min-height: 54px; padding: .7rem 1.4rem; font-size: 1.08rem; }
.btn-xl    { min-height: 62px; padding: .8rem 1.7rem; font-size: 1.2rem; border-radius: var(--r-lg); }
.btn-block { display: flex; width: 100%; }
.btn-icon  { min-width: var(--tap); padding-left: .5rem; padding-right: .5rem; }
.btn-small.btn-icon { min-width: 40px; }

html.pref-high-contrast .btn { --btn-border: #000; }

/* Small pill toggles (video options, offline save) */
.toggle {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  min-height: 44px;
  padding: .35rem 1rem;
  border: 1.5px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font: 800 .95rem var(--font-body);
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease;
}
.toggle:hover { border-color: var(--ink-soft); }
.toggle[aria-pressed="true"] { background: var(--blue-soft); border-color: var(--blue); color: var(--blue-dark); }

/* ---------------------------------------------------------------------
   4. Forms
   --------------------------------------------------------------------- */
.form { display: grid; gap: 1.1rem; }
.form--narrow { max-width: 720px; }
.form-actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.field { display: grid; gap: .35rem; min-width: 0; }
.field > label, fieldset > legend { font-weight: 800; font-size: .98rem; }
.field--xs { max-width: 120px; }

input[type="text"], input[type="email"], input[type="password"], input[type="search"],
input[type="number"], input[type="url"], input[type="date"], select, textarea {
  width: 100%;
  min-height: var(--tap);
  padding: .6rem .9rem;
  border: 1.5px solid var(--field);
  border-radius: var(--r-sm);
  background: var(--white);
  color: var(--ink);
  font: 600 1rem/1.4 var(--font-body);
  transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { resize: vertical; min-height: 88px; }
select { cursor: pointer; }
input[type="color"] { width: 64px; height: var(--tap); padding: 4px; border: 1.5px solid var(--field); border-radius: var(--r-sm); background: var(--white); }
input[type="file"] { font: 600 .95rem var(--font-body); max-width: 100%; }
input[type="file"]::file-selector-button {
  margin-right: .75rem;
  min-height: 40px;
  padding: .35rem .9rem;
  border: 1.5px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--surface-2);
  color: var(--ink);
  font: 800 .92rem var(--font-body);
  cursor: pointer;
}
input:hover, select:hover, textarea:hover { border-color: var(--ink-soft); }
input:focus-visible, select:focus-visible, textarea:focus-visible { border-color: var(--blue); }
input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--blue); }

.field__hint { margin: 0; color: var(--ink-soft); font-size: .9rem; }
.field__error { margin: 0; color: var(--red); font-weight: 800; font-size: .95rem; }
.field__error::before { content: '⚠️ '; }
.has-error input, .has-error select, .has-error textarea { border-color: var(--red); background: #FFF7F7; }
.optional { font-weight: 600; color: var(--ink-soft); font-size: .9em; }
.required { color: var(--red); }

.form-row { display: grid; gap: 1rem; }
.form-row:has(> .field:only-child) { grid-template-columns: 1fr !important; }
@media (min-width: 640px) {
  .form-row { grid-template-columns: 1fr 1fr; }
  .form-row--3 { grid-template-columns: repeat(3, 1fr); }
}

.checkbox-inline { display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; font-weight: 700; cursor: pointer; }
.password-field { display: flex; gap: .5rem; }
.password-field input { flex: 1; min-width: 0; }

fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset > legend { padding: 0; margin-bottom: .5rem; }

/* Picker grids built on radio inputs (avatar, role, difficulty) */
.avatar-picker__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; max-width: 560px; }
@media (min-width: 440px) { .avatar-picker__grid { grid-template-columns: repeat(8, 1fr); } }
.avatar-picker__option {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  min-height: 48px;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  font-size: 1.7rem;
  cursor: pointer;
  transition: transform .12s ease, border-color .12s ease;
}
.avatar-picker__option:hover { transform: scale(1.06); border-color: var(--orange); }
input:checked + .avatar-picker__option { border-color: var(--orange-edge); background: var(--yellow-soft); box-shadow: 0 0 0 3px var(--orange-edge); }
input:focus-visible + .avatar-picker__option,
input:focus-visible + .role-picker__option,
input:focus-visible + .pill { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 7px var(--yellow); }

.role-picker__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; }
.role-picker__option {
  display: grid;
  justify-items: center;
  gap: .25rem;
  padding: 1rem .5rem;
  border: 2px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--white);
  cursor: pointer;
  text-align: center;
  transition: border-color .15s ease, background-color .15s ease;
}
.role-picker__option:hover { border-color: var(--line-strong); }
.role-picker__icon { font-size: 2.5rem; line-height: 1; }
.role-picker__label { font-weight: 800; font-size: 1.05rem; }
input:checked + .role-picker__option { border-color: var(--orange-edge); background: var(--orange-soft); }

.pill-group { display: flex; flex-wrap: wrap; gap: .5rem; }
.pill-group > legend { width: 100%; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  min-height: 44px;
  padding: .35rem 1rem;
  border: 1.5px solid var(--line-strong);
  border-radius: 999px;
  background: var(--white);
  font-weight: 800;
  cursor: pointer;
}
input:checked + .pill { background: var(--blue); border-color: var(--blue); color: var(--white); }

/* Toggle switch */
.settings-group { display: grid; gap: .35rem; }
.switch { display: flex; align-items: center; gap: .75rem; min-height: var(--tap); cursor: pointer; font-weight: 700; position: relative; }
.switch input { position: absolute; opacity: 0; width: 60px; height: 34px; margin: 0; cursor: pointer; }
.switch__track {
  position: relative;
  flex: none;
  width: 58px; height: 34px;
  border-radius: 999px;
  background: #C9D0DE;
  border: 2px solid var(--ink-soft);
  transition: background-color .15s ease;
}
.switch__track::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .3);
  transition: transform .15s ease;
}
.switch input:checked + .switch__track { background: var(--green); border-color: var(--green); }
.switch input:checked + .switch__track::after { transform: translateX(24px); }
.switch input:focus-visible + .switch__track { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 7px var(--yellow); }

/* ---------------------------------------------------------------------
   5. Chips, tags & small labels
   --------------------------------------------------------------------- */
.chip-list { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0; }
.chip-list--scroll { flex-wrap: nowrap; overflow-x: auto; padding: .25rem .1rem .75rem; scroll-snap-type: x proximity; }
.chip-list--scroll li { flex: none; scroll-snap-align: start; }
.chip {
  --theme-color: var(--blue);
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  min-height: var(--tap);
  padding: .4rem 1rem;
  border: 1.5px solid var(--line-strong);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color .15s ease, background-color .15s ease;
}
a.chip:hover { border-color: var(--theme-color); color: var(--ink); }
.chip--theme { border-left: 6px solid var(--theme-color); }
.chip--small { min-height: 40px; padding: .25rem .85rem; font-size: .92rem; }
.chip--accent { background: var(--yellow-soft); border-color: #E6BC85; }
.chip[aria-current="page"] { background: var(--blue); border-color: var(--blue); color: var(--white); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .2rem .65rem;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-size: .82rem;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
}

.level {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: .15rem .6rem;
  border-radius: 999px;
  font-size: .8rem;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
}
.level--beginner { background: var(--green-soft); }
.level--intermediate { background: var(--yellow-soft); }
.level--advanced { background: var(--purple-soft); }

.count-badge {
  display: inline-grid;
  place-items: center;
  min-width: 2em;
  padding: .1em .55em;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--blue);
  font: 800 .85rem/1.4 var(--font-body);
  vertical-align: middle;
}

.done-chip {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .3rem .8rem;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green-dark);
  font-weight: 800;
  font-size: .88rem;
}

.soon-badge {
  display: inline-block;
  padding: .2rem .75rem;
  border-radius: 999px;
  background: var(--white);
  border: 1.5px solid #C9BCF5;
  font-weight: 800;
  font-size: .82rem;
  white-space: nowrap;
}

/* ---------------------------------------------------------------------
   6. Header, navigation & footer
   --------------------------------------------------------------------- */
.icon { width: 1.25em; height: 1.25em; flex: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  /* No backdrop-filter here: it would make the header the containing block
     for the fixed bottom nav inside it, pinning the nav under the header. */
  background: var(--white);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(11, 31, 82, .02), 0 4px 16px rgba(11, 31, 82, .04);
}
.site-header::before { content: ''; display: block; height: 3px; background: linear-gradient(90deg, var(--blue), var(--blue-bright), var(--yellow)); }
.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem .75rem;
  max-width: var(--container);
  min-height: 64px;
  margin: 0 auto;
  padding: .5rem var(--gutter);
}

.brand {
  order: 1;
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  min-height: var(--tap);
  color: var(--ink);
  text-decoration: none;
}
.brand__logo { width: 40px; height: 40px; }
.brand__name { font: 800 1.12rem/1 var(--font-display); color: var(--blue); letter-spacing: -.01em; }

.header-actions { order: 2; display: flex; align-items: center; gap: .5rem; }

/* Search field in the header */
.header-search { order: 3; flex: 1 1 100%; position: relative; display: flex; align-items: center; }
.header-search__icon { position: absolute; left: .85rem; display: flex; color: var(--ink-soft); pointer-events: none; }
.header-search__icon .icon { width: 1.1rem; height: 1.1rem; }
.header-search input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: .45rem 1rem .45rem 2.5rem;
  border: 1px solid var(--field);
  border-radius: 999px;
  background: var(--surface-2);
  font: 600 .98rem var(--font-body);
}
.header-search input:hover { border-color: var(--ink-soft); }
.header-search input:focus-visible { background: var(--white); }

/* Account menu (avatar button → dropdown) */
.account-menu { position: relative; }
.account-menu__trigger {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  min-height: var(--tap);
  padding: .25rem .5rem .25rem .25rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.account-menu__trigger:hover { color: var(--ink); border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.account-menu__trigger[aria-expanded="true"] { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.account-menu__who { display: none; text-align: left; line-height: 1.15; }
.account-menu__name { display: block; max-width: 12ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; font-size: .95rem; }
.account-menu__role { display: block; max-width: 16ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .75rem; font-weight: 700; color: var(--ink-soft); }
.account-menu__chevron { display: flex; color: var(--ink-soft); transition: transform .15s ease; }
.account-menu__chevron .icon { width: 1rem; height: 1rem; }
.account-menu__trigger[aria-expanded="true"] .account-menu__chevron { transform: rotate(180deg); }

.account-menu__panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 90;
  width: min(300px, calc(100vw - 2 * var(--gutter)));
  padding: .5rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  animation: menu-in .15s ease-out;
}
@keyframes menu-in { from { opacity: 0; transform: translateY(-4px); } }
.account-menu__head { display: flex; align-items: center; gap: .7rem; padding: .6rem .6rem .8rem; margin-bottom: .35rem; border-bottom: 1px solid var(--line); }
.account-menu__title { margin: 0; font: 700 1rem var(--font-display); }
.account-menu__sub { margin: 0; font-size: .82rem; font-weight: 700; color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 200px; }
.account-menu__section { margin: .5rem .6rem .2rem; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.account-menu__list { list-style: none; margin: 0; padding: 0; }
.account-menu__list form { margin: 0; }
.account-menu__item {
  display: flex;
  align-items: center;
  gap: .7rem;
  width: 100%;
  min-height: 44px;
  padding: .45rem .7rem;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--ink);
  font: 700 .95rem var(--font-body);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.account-menu__item .icon { width: 1.15rem; height: 1.15rem; color: var(--ink-soft); }
.account-menu__item:hover, .account-menu__item:focus-visible { background: var(--surface-2); color: var(--ink); }
.account-menu__item:hover .icon { color: var(--blue); }
.account-menu__avatar { display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--yellow-soft); font-size: 1rem; }
.account-menu__footer { margin: .35rem 0 0; padding-top: .35rem; border-top: 1px solid var(--line); }
.account-menu__item--danger, .account-menu__item--danger .icon { color: var(--red); }
.account-menu__item--danger:hover { background: var(--red-soft); color: var(--red); }
.account-menu__item--danger:hover .icon { color: var(--red); }

.avatar {
  display: inline-grid;
  place-items: center;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--yellow-soft);
  font-size: 1.3rem;
  line-height: 1;
  flex: none;
}
.avatar--md { width: 44px; height: 44px; font-size: 1.5rem; }
.avatar--xl { width: 80px; height: 80px; font-size: 2.8rem; border: 4px solid var(--white); background: var(--yellow-soft); box-shadow: var(--shadow); }

/* Main navigation: a bottom tab bar on phones/tablets, inline links on wide screens */
.main-nav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 70;
  background: var(--white);
  border-top: 1px solid var(--line);
  box-shadow: 0 -4px 18px rgba(11, 31, 82, .06);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.main-nav ul {
  display: flex;
  justify-content: space-around;
  margin: 0 auto;
  padding: .3rem .25rem .35rem;
  max-width: 640px;
  list-style: none;
}
.main-nav li { flex: 1; }
.main-nav__link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .2rem;
  min-height: 58px;
  padding: .2rem;
  border-radius: var(--r);
  color: var(--ink-soft);
  font-weight: 700;
  font-size: .75rem;
  text-decoration: none;
}
.main-nav__icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 30px;
  border-radius: 999px;
  transition: background-color .15s ease, color .15s ease;
}
.main-nav__icon .icon { width: 1.35rem; height: 1.35rem; }
.main-nav__link:hover { color: var(--ink); }
.main-nav__link:hover .main-nav__icon { background: var(--surface-2); }
.main-nav__link[aria-current="page"] { color: var(--blue); font-weight: 800; }
.main-nav__link[aria-current="page"] .main-nav__icon { background: var(--blue-soft); color: var(--blue); }

/* Admin section tabs */
.admin-tabs { background: var(--white); border-top: 1px solid var(--line); }
.admin-tabs ul {
  display: flex;
  gap: .25rem;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
  list-style: none;
  overflow-x: auto;
}
.admin-tabs a {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  min-height: 48px;
  padding: 0 .85rem;
  border-bottom: 3px solid transparent;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: .95rem;
  text-decoration: none;
  white-space: nowrap;
}
.admin-tabs a .icon { width: 1.1rem; height: 1.1rem; }
.admin-tabs a:hover { color: var(--ink); border-bottom-color: var(--line-strong); }
.admin-tabs a[aria-current="page"] { color: var(--blue); border-bottom-color: var(--blue); font-weight: 800; }

@media (min-width: 720px) {
  .brand { flex: 0 0 auto; }
  .header-search { order: 2; flex: 1 1 240px; max-width: 460px; }
  .header-actions { order: 3; margin-left: auto; }
  .account-menu__who { display: block; }
}
@media (min-width: 1180px) {
  body.has-nav { padding-bottom: 0; }
  .site-header__inner { flex-wrap: nowrap; min-height: 68px; }
  .main-nav { position: static; order: 2; flex: 0 0 auto; margin-left: 1.25rem; border: 0; box-shadow: none; padding: 0; background: none; }
  .main-nav ul { padding: 0; gap: .15rem; max-width: none; }
  .main-nav li { flex: none; }
  .main-nav__compact { display: none; }
  .main-nav__link { flex-direction: row; gap: .45rem; min-height: 42px; padding: 0 .8rem; border-radius: var(--r-sm); font-size: .95rem; }
  .main-nav__icon { width: auto; height: auto; background: none !important; }
  .main-nav__icon .icon { width: 1.15rem; height: 1.15rem; }
  .main-nav__link:hover { background: var(--surface-2); }
  .main-nav__link[aria-current="page"] { background: var(--blue-soft); }
  .header-search { order: 3; flex: 0 1 240px; margin-left: auto; }
  .header-actions { order: 4; margin-left: .25rem; flex: none; }
  .site-header__inner:not(:has(.header-search)) .header-actions { margin-left: auto; }
}
@media (max-width: 480px) {
  .hide-sm { display: none; }
  .header-actions .btn-small { padding: .3rem .75rem; font-size: .88rem; }
}
@media (max-width: 420px) {
  .brand__name { font-size: 1rem; }
}

.site-footer { margin-top: auto; border-top: 1px solid var(--line); background: var(--surface-2); }
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .25rem 1rem;
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.1rem var(--gutter);
  color: var(--ink-soft);
  font-size: .92rem;
}
.site-footer__brand { display: inline-flex; align-items: center; gap: .5rem; margin: 0; font: 700 .98rem var(--font-display); color: var(--blue); }
.site-footer__tagline { margin: 0; }
.site-footer__org { margin: 0; font-size: .9rem; }
.site-footer__org a { color: var(--blue); font-weight: 700; }
.brand__org { display: block; margin-top: 3px; font: 700 .68rem/1 var(--font-body); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }

/* ---------------------------------------------------------------------
   7. Layout & sections
   --------------------------------------------------------------------- */
.site-main { width: 100%; max-width: var(--container); margin: 0 auto; padding: 1.5rem var(--gutter) 3rem; }
.site-main:focus { outline: none; }

.section { margin: var(--section-gap) 0; }
.section--tight { margin-top: .75rem; }
.section__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; margin-bottom: 1rem; }
.section__head--center { justify-content: center; text-align: center; }
.section__title { font-size: 1.35rem; margin: 0; }
.section__title--small { font-size: 1.05rem; }
.section__meta { font-weight: 800; color: var(--ink-soft); font-size: .92rem; }
.link-more { display: inline-flex; align-items: center; gap: .3rem; min-height: 44px; font-weight: 800; }

.page-head { margin-bottom: 1.5rem; }
.page-head--row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.page-title { font-size: clamp(1.65rem, 5vw, 2.2rem); margin: 0 0 .3rem; }
.page-lead { color: var(--ink-soft); font-size: 1.05rem; margin: 0; }
.eyebrow { margin: 0 0 .4rem; font-weight: 800; color: var(--orange-dark); letter-spacing: .02em; }

.two-col { display: grid; gap: 1.25rem; margin: 1.25rem 0; }
.stack { display: grid; gap: 1.25rem; align-content: start; }
@media (min-width: 860px) {
  .two-col { grid-template-columns: 1fr 1fr; align-items: start; }
  .two-col--stretch { align-items: stretch; }
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.25rem;
}
.two-col > .panel, .stack > .panel { margin-bottom: 0; }
.panel__title { font-size: 1.15rem; margin: 0 0 1rem; }
.panel__lead { color: var(--ink-soft); }
.panel--highlight { border-color: #F2CB9B; background: linear-gradient(180deg, var(--orange-soft), var(--surface) 140px); }
.panel--blue { background: linear-gradient(180deg, var(--blue-soft), var(--surface) 160px); border-color: #C2D4F5; }
.panel--details > summary { cursor: pointer; list-style: none; min-height: var(--tap); margin: 0; }
.panel--details > summary::-webkit-details-marker { display: none; }
.panel--details > summary::after { content: '▾'; margin-left: auto; font-size: 1rem; color: var(--ink-soft); transition: transform .2s ease; }
.panel--details[open] > summary { margin-bottom: 1rem; }
.panel--details[open] > summary::after { transform: rotate(180deg); }
fieldset.panel { min-width: 0; }
fieldset.panel > legend { float: left; width: 100%; padding: 0; margin-bottom: 1rem; }
fieldset.panel > legend + * { clear: both; }

.empty-note { color: var(--ink-soft); font-weight: 700; margin: 0; }
.empty-state { text-align: center; padding: 2.5rem 1rem; max-width: 520px; margin: 0 auto; }
.empty-state__icon { font-size: 3.6rem; margin: 0 0 .5rem; }
.empty-state--small { padding: 1.5rem 1rem; }

.card-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.card-grid--signs { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .85rem; }
/* Lesson grids become a sideways shelf on phones so the page stays short. */
@media (max-width: 639px) {
  .card-grid--lessons { display: flex; gap: .85rem; overflow-x: auto; margin: 0 -.25rem; padding: .25rem .25rem 1rem; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
  .card-grid--lessons > * { flex: 0 0 80%; scroll-snap-align: start; }
}
@media (min-width: 640px) { .card-grid--signs { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 1rem; } }

.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .75rem; margin: 1.75rem 0 0; }
.pagination__info { font-weight: 800; color: var(--ink-soft); }

/* ---------------------------------------------------------------------
   8. Feedback: alerts, flash toasts, toasts
   --------------------------------------------------------------------- */
.alert {
  padding: .85rem 1.1rem;
  border-radius: var(--r);
  border: 1px solid;
  font-weight: 700;
  margin-bottom: 1rem;
}
.alert--success { background: var(--green-soft); border-color: #A5D3B5; color: var(--green-dark); }
.alert--error   { background: var(--red-soft); border-color: #F2B1B1; color: var(--red-dark); }
.alert--info    { background: var(--blue-soft); border-color: #BFD2F3; color: var(--blue-dark); }
.alert--warning { background: var(--yellow-soft); border-color: #E6BC85; color: #6A3F0C; }
.alert a { color: inherit; }

/* Server flash messages float as dismissible toasts instead of pushing the page down. */
.flash-stack {
  position: fixed;
  z-index: 130;
  left: 50%;
  bottom: calc(var(--bottom-nav) + 14px);
  transform: translateX(-50%);
  display: grid;
  gap: .5rem;
  width: min(calc(100vw - 2 * var(--gutter)), 460px);
}
.flash {
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .6rem .6rem .6rem 1rem;
  border-radius: var(--r);
  background: var(--ink);
  color: var(--white);
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  animation: flash-in .3s ease-out, flash-out .4s ease 6s forwards;
}
.flash:hover, .flash:focus-within { animation-play-state: paused; }
.flash--error { background: var(--red-dark); animation: flash-in .3s ease-out; }
.flash__icon { font-size: 1.2rem; }
.flash__text { flex: 1; }
.flash__close {
  flex: none;
  width: 40px; height: 40px;
  border: 0;
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, .14);
  color: var(--white);
  font-size: 1rem;
  cursor: pointer;
}
.flash__close:hover { background: rgba(255, 255, 255, .25); }
@keyframes flash-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes flash-out { to { opacity: 0; transform: translateY(10px); visibility: hidden; } }

.toast-region {
  position: fixed;
  left: 50%;
  bottom: calc(var(--bottom-nav) + 14px);
  transform: translateX(-50%);
  z-index: 120;
  display: grid;
  gap: .5rem;
  width: min(calc(100vw - 2 * var(--gutter)), 420px);
  pointer-events: none;
}
.toast {
  padding: .85rem 1.1rem;
  border-radius: var(--r);
  background: var(--ink);
  color: var(--white);
  font-weight: 800;
  box-shadow: var(--shadow-lg);
  animation: flash-in .25s ease-out;
}
.toast--error { background: var(--red-dark); }
@media (min-width: 1180px) {
  .toast-region { bottom: 24px; }
  .flash-stack { left: auto; right: 24px; bottom: auto; top: 92px; transform: none; }
}

/* ---------------------------------------------------------------------
   9. Landing & auth pages
   --------------------------------------------------------------------- */
.hero { display: grid; gap: 1.5rem; align-items: center; padding: .5rem 0 1rem; }
.hero__title { font-size: clamp(2.1rem, 7vw, 3.4rem); line-height: 1.08; margin-bottom: .4em; }
.hero__highlight { background: linear-gradient(transparent 62%, var(--yellow) 62%, var(--yellow) 92%, transparent 92%); padding: 0 .1em; }
.hero__lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 34ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
@media (max-width: 480px) { .hero__actions .btn { flex: 1 1 100%; } }
.hero__note { margin: 1rem 0 0; color: var(--ink-soft); font-weight: 700; font-size: .95rem; }
.hero__note span { color: var(--green); }
.hero__art { position: relative; height: 240px; }
.bubble {
  position: absolute;
  display: grid;
  place-items: center;
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
  animation: float 5s ease-in-out infinite;
}
.bubble--big { width: 200px; height: 200px; left: 50%; top: 50%; margin: -100px 0 0 -100px; background: radial-gradient(circle at 30% 30%, #F6BB74, var(--orange)); font-size: 6rem; }
.bubble--a { width: 84px; height: 84px; left: 6%; top: 8%; background: var(--yellow); font-size: 2.6rem; animation-delay: -1s; }
.bubble--b { width: 70px; height: 70px; right: 8%; top: 4%; background: var(--blue-soft); font-size: 2.2rem; animation-delay: -2s; }
.bubble--c { width: 92px; height: 92px; right: 10%; bottom: 0; background: var(--white); font-size: 2.8rem; animation-delay: -3s; }
@keyframes float { 50% { transform: translateY(-10px); } }
@media (min-width: 860px) {
  .hero { grid-template-columns: 1.15fr 1fr; padding: 1.5rem 0 1rem; }
  .hero__art { height: 360px; }
  .bubble--big { width: 260px; height: 260px; margin: -130px 0 0 -130px; font-size: 8rem; }
}

.steps { display: grid; gap: 1rem; list-style: none; padding: 0; margin: 0; counter-reset: step; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step {
  position: relative;
  padding: 1.5rem 1.25rem 1.25rem;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
}
.step__num {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  display: grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--blue);
  color: var(--white);
  font-weight: 800;
  font-size: .95rem;
}
.step__icon { display: block; font-size: 2.6rem; margin-bottom: .35rem; }
.step h3 { font-size: 1.2rem; margin-bottom: .3rem; }
.step p { margin: 0; color: var(--ink-soft); }

.audience-grid { display: grid; gap: 1rem; }
@media (min-width: 760px) { .audience-grid { grid-template-columns: repeat(3, 1fr); } }
.audience-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .35rem;
  padding: 1.4rem 1.3rem;
  border-radius: var(--r-xl);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.audience-card__icon { display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: .4rem; border-radius: 20px; background: var(--blue-soft); font-size: 2rem; }
.audience-card h3 { font-size: 1.2rem; margin: 0; }
.audience-card p { margin: 0 0 .6rem; color: var(--ink-soft); }
.audience-card__status { margin-top: auto; padding: .2rem .75rem; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line-strong); font-size: .82rem; font-weight: 800; }
.audience-card__status.is-live { background: var(--green-soft); border-color: #A5D3B5; color: var(--green-dark); }

/* "How it works": connected steps — a row on wide screens, a timeline on phones */
.how {
  margin: var(--section-gap) 0;
  padding: 1.75rem 1.35rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
}
.how--compact { margin-top: 0; }
.how__head { text-align: center; margin-bottom: 1.6rem; }
.how__head .eyebrow { margin-bottom: .25rem; text-transform: uppercase; letter-spacing: .1em; font-size: .78rem; }
.how__title { font-size: clamp(1.35rem, 4vw, 1.8rem); margin: 0; }
.how__steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.5rem; }
.how__step {
  --step-color: var(--orange);
  --step-ink: var(--ink);
  --step-soft: var(--orange-soft);
  position: relative;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 1rem;
  align-items: start;
}
.how__step--blue { --step-color: var(--blue); --step-ink: var(--white); --step-soft: var(--blue-soft); }
.how__step--green { --step-color: var(--green); --step-ink: var(--white); --step-soft: var(--green-soft); }
.how__marker { position: relative; z-index: 1; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 20px; background: var(--step-soft); }
.how__icon { font-size: 1.9rem; line-height: 1; }
.how__num {
  position: absolute;
  top: -8px; right: -8px;
  display: grid;
  place-items: center;
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 3px solid var(--white);
  background: var(--step-color);
  color: var(--step-ink);
  font: 800 .8rem/1 var(--font-body);
}
.how__text h3 { font-size: 1.15rem; margin: .35rem 0 .2rem; }
.how__text p { margin: 0; color: var(--ink-soft); }
.how__text strong { white-space: nowrap; }
/* Timeline connector (phones): dotted line down from each marker */
.how__step:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 31px;
  top: 72px;
  bottom: -1.3rem;
  width: 2px;
  background: repeating-linear-gradient(to bottom, var(--line-strong) 0 4px, transparent 4px 9px);
}
@media (min-width: 760px) {
  .how { padding: 2.25rem 2rem 2rem; }
  .how__steps { grid-template-columns: repeat(3, 1fr); gap: 2rem; }
  .how__step { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: .6rem; }
  .how__text p { max-width: 28ch; margin: 0 auto; }
  /* Row connector: dotted line from this marker to the next */
  .how__step:not(:last-child)::after {
    left: calc(50% + 46px);
    top: 31px;
    bottom: auto;
    width: calc(100% + 2rem - 92px);
    height: 2px;
    background: repeating-linear-gradient(to right, var(--line-strong) 0 4px, transparent 4px 9px);
  }
}

.feature-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.feature {
  padding: 1.25rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.feature__icon { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; background: var(--yellow-soft); font-size: 1.9rem; margin-bottom: .8rem; }
.feature h3 { font-size: 1.1rem; margin-bottom: .3rem; }
.feature p { margin: 0; color: var(--ink-soft); }

.theme-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: .75rem; list-style: none; padding: 0; margin: 0; }
.theme-tiles--center { max-width: 760px; margin: 0 auto; }
.theme-tile {
  --theme-color: var(--orange-edge);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .3rem;
  padding: 1rem .5rem;
  border-radius: var(--r-lg);
  background: var(--orange-soft);
  background: color-mix(in srgb, var(--theme-color) 11%, white);
  border: 1.5px solid color-mix(in srgb, var(--theme-color) 28%, white);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  transition: transform .15s ease, border-color .15s ease;
}
.theme-tile__icon { font-size: 2.1rem; line-height: 1.1; }
a.theme-tile:hover { transform: translateY(-2px); border-color: var(--theme-color); color: var(--ink); }

.cta-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  margin: var(--section-gap) 0 0;
  padding: 1.75rem;
  border-radius: var(--r-xl);
  background: var(--blue);
  color: var(--white);
  box-shadow: var(--shadow-lg);
}
.cta-band__title { color: var(--white); font-size: 1.5rem; margin: 0 0 .2rem; }
.cta-band__text { margin: 0; color: #D8E2FF; font-weight: 700; }

.auth-card {
  max-width: 480px;
  margin: .5rem auto;
  padding: 1.75rem 1.5rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
}
.auth-card__title { font-size: 1.7rem; margin-bottom: .25rem; }
.auth-card__lead { color: var(--ink-soft); margin-bottom: 1.25rem; }
.auth-card__footer { margin: 1.25rem 0 0; padding-top: 1rem; border-top: 1px solid var(--line); text-align: center; line-height: 2.3; font-weight: 700; }
.gate { text-align: center; }
.gate__icon { font-size: 3.6rem; margin: 0 0 .25rem; }
.gate .auth-card__title { justify-content: center; }
.gate__question { font-size: 1.35rem; font-family: var(--font-display); }
.gate input { text-align: center; font-size: 1.6rem; font-weight: 800; letter-spacing: .1em; }

/* ---------------------------------------------------------------------
   10. Child dashboard & shared cards
   --------------------------------------------------------------------- */
.hero-card {
  position: relative;
  display: grid;
  gap: 1.25rem;
  padding: 1.5rem;
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, #FDEBD3 0%, #F8D4A6 55%, #F2C285 100%);
  box-shadow: var(--shadow);
  overflow: hidden;
  isolation: isolate;
}
.hero-card::before, .hero-card::after {
  content: '';
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  background: rgba(255, 255, 255, .28);
}
.hero-card::before { width: 260px; height: 260px; right: -70px; top: -90px; }
.hero-card::after { width: 160px; height: 160px; right: 22%; bottom: -90px; }
.hero-card__title { font-size: clamp(1.9rem, 6vw, 2.7rem); margin: 0; }
.hero-card__lead { margin: .35rem 0 1rem; font-size: 1.15rem; font-weight: 700; }
.hero-card__lead strong { color: var(--orange-dark); }
.hero-card .progress-bar { background: rgba(255, 255, 255, .65); border-color: rgba(11, 31, 82, .12); }
.hero-card .stat-pill { background: rgba(255, 255, 255, .75); border-color: transparent; }
.hero-card__cta { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1rem; margin-top: 1.25rem; }
.hero-card__next { margin: 0; font-weight: 700; }
.hero-card__side { display: flex; justify-content: center; }
.hero-card__side:has(.mascot) { display: none; }
@media (min-width: 720px) {
  .hero-card { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 2rem 2.25rem; }
  .hero-card__side:has(.mascot) { display: flex; }
}
.wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.4s ease-in-out infinite; }
@keyframes wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20% { transform: rotate(-8deg); } 40% { transform: rotate(-4deg); } 50% { transform: rotate(10deg); } }

.greeting { margin: 0; text-align: center; }
.greeting video { width: 100%; max-width: 280px; border-radius: var(--r-lg); background: #0B1020; border: 4px solid var(--white); box-shadow: var(--shadow); }
.greeting figcaption { margin-top: .45rem; font-weight: 700; }
.mascot { position: relative; display: grid; place-items: center; width: 150px; height: 150px; border-radius: 50%; background: var(--white); box-shadow: var(--shadow-lg); }
.mascot__hand { font-size: 5rem; line-height: 1; }
.mascot__star { position: absolute; top: -4px; right: -6px; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--blue-soft); font-size: 1.6rem; box-shadow: var(--shadow); animation: float 4s ease-in-out infinite; }

.progress-bar {
  display: block;
  height: 18px;
  border-radius: 999px;
  background: var(--orange-soft);
  border: 1px solid var(--line-strong);
  overflow: hidden;
}
.progress-bar__fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--orange) repeating-linear-gradient(-45deg, transparent 0 10px, rgba(255, 255, 255, .18) 10px 20px);
  transition: width .6s ease;
}
.progress-bar--small { height: 12px; }
.progress-bar--small .progress-bar__fill { background: var(--theme-color, var(--orange)); }

.stat-pills { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 1rem 0 0; }
.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .4rem .9rem;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  font-weight: 700;
  color: var(--ink);
}
.stat-pill__icon { font-size: 1.15rem; }
.stat-pill strong { font: 800 1.1rem var(--font-display); }

/* Horizontal shelves: learning path and badges */
.scroller, .shelf { overflow-x: auto; margin: 0 -.25rem; padding: .25rem .25rem 1rem; scroll-snap-type: x mandatory; scroll-padding: .25rem; }
.scroller { display: flex; gap: 1rem; }
.scroller > * { flex: 0 0 min(78%, 250px); scroll-snap-align: start; }
.scroller:focus-visible, .shelf:focus-visible { box-shadow: none; outline-offset: 0; }

.lesson-card {
  --theme-color: var(--orange-edge);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: .2rem;
  padding: 1.25rem 1.1rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.lesson-card::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--theme-color); }
.lesson-card__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: .6rem; min-height: 64px; }
.lesson-card__icon {
  display: grid;
  place-items: center;
  width: 64px; height: 64px;
  border-radius: 20px;
  background: var(--orange-soft);
  background: color-mix(in srgb, var(--theme-color) 14%, white);
  font-size: 2.3rem;
}
.lesson-card__img { width: 84px; height: 64px; object-fit: cover; border-radius: 16px; }
.lesson-card__theme { margin: 0; font-size: .78rem; font-weight: 800; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .07em; }
.lesson-card__title { font-size: 1.18rem; margin: 0; }
.lesson-card__desc {
  margin: .15rem 0 0;
  color: var(--ink-soft);
  font-size: .92rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.lesson-card__count { margin: .5rem 0 .9rem; font-size: .88rem; font-weight: 800; color: var(--ink-soft); }
.lesson-card__cta { margin-top: auto; }

.ring { flex: none; }
.ring__track { fill: none; stroke: #E4E8F1; stroke-width: 4; }
.ring__fill { fill: none; stroke: var(--theme-color, var(--orange)); stroke-width: 4; stroke-linecap: round; transition: stroke-dasharray .6s ease; }
.ring.is-empty .ring__fill { stroke: none; }
.ring__text { font: 800 9px var(--font-body); fill: var(--ink); }

.badge-row { display: flex; gap: .75rem; list-style: none; padding: 0; margin: 0; }
.badge-row > * { flex: 0 0 136px; scroll-snap-align: start; }
.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: .75rem; list-style: none; padding: 0; margin: 0; }
.badge-grid--compact { grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); }
.badge-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .15rem;
  padding: 1rem .6rem .9rem;
  text-align: center;
  background: var(--surface);
  border: 1.5px solid #EDC48F;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
}
.badge-tile__icon { display: grid; place-items: center; width: 60px; height: 60px; margin-bottom: .35rem; border-radius: 50%; background: var(--yellow-soft); font-size: 2rem; }
.badge-tile__name { font-weight: 800; line-height: 1.25; }
.badge-tile__desc { font-size: .82rem; color: var(--ink-soft); line-height: 1.35; }
.badge-grid--compact .badge-tile__desc { display: none; }
.badge-tile.is-locked { border: 1.5px dashed var(--line-strong); box-shadow: none; background: transparent; }
.badge-tile.is-locked .badge-tile__icon { filter: grayscale(1); opacity: .45; background: var(--line); }

.game-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.game-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.25rem;
  border-radius: var(--r-lg);
  background: var(--purple-soft);
  border: 1.5px dashed #C9BCF5;
}
.game-card__icon { display: grid; place-items: center; flex: none; width: 56px; height: 56px; border-radius: 18px; background: var(--white); font-size: 2rem; }
.game-card > div { flex: 1; min-width: 0; }
.game-card h3 { font-size: 1.1rem; margin: 0 0 .15rem; }
.game-card p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* Sign "flash cards" */
.sign-card {
  --theme-color: var(--orange-edge);
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform .15s ease, box-shadow .15s ease;
}
.sign-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.sign-card:focus-within { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 7px var(--yellow); }
.sign-card__thumb {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  background: var(--orange-soft);
  background: color-mix(in srgb, var(--theme-color) 13%, white);
}
.sign-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.sign-card__letter {
  display: grid;
  place-items: center;
  width: 36%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--white);
  color: var(--theme-color);
  font: 800 clamp(1.8rem, 5.5vw, 2.5rem)/1 var(--font-display);
  box-shadow: var(--shadow);
}
.sign-card__theme, .sign-card__play {
  position: absolute;
  display: grid;
  place-items: center;
  border-radius: 50%;
}
.sign-card__theme { top: .55rem; right: .55rem; width: 32px; height: 32px; background: var(--white); font-size: 1rem; box-shadow: var(--shadow-sm); }
.sign-card__play { right: .55rem; bottom: .55rem; width: 38px; height: 38px; background: var(--orange); color: var(--ink); font-size: .85rem; box-shadow: 0 2px 0 var(--orange-edge); transition: transform .15s ease; }
.sign-card:hover .sign-card__play { transform: scale(1.12); }
.sign-card__learned, .sign-card__duration {
  position: absolute;
  padding: .15rem .55rem;
  border-radius: 999px;
  font-size: .76rem;
  font-weight: 800;
}
.sign-card__learned { left: .55rem; top: .55rem; background: var(--green); color: var(--white); }
.sign-card__duration { left: .55rem; bottom: .55rem; background: rgba(11, 31, 82, .85); color: var(--white); }
.sign-card__body { display: flex; flex-direction: column; gap: .2rem; padding: .75rem .9rem .9rem; flex: 1; }
.sign-card__word { font-size: 1.15rem; margin: 0; }
.sign-card__link { color: var(--ink); text-decoration: none; }
.sign-card__link::after { content: ''; position: absolute; inset: 0; }
.sign-card__link:hover { color: var(--ink); }
.sign-card__link:focus-visible { outline: none; box-shadow: none; }
.sign-card__phrase { margin: 0; color: var(--ink-soft); font-size: .9rem; font-weight: 700; line-height: 1.35; }
.sign-card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .5rem; margin: auto 0 0; padding-top: .45rem; font-size: .82rem; font-weight: 800; color: var(--ink-soft); }

/* ---------------------------------------------------------------------
   11. Lesson screen
   --------------------------------------------------------------------- */
.lesson { --theme-color: var(--orange-edge); }

.lesson-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem 1rem;
  margin-bottom: 1.25rem;
  padding: .65rem .9rem .65rem .65rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
}
.lesson-head__back {
  display: grid;
  place-items: center;
  flex: none;
  width: var(--tap); height: var(--tap);
  border-radius: var(--r);
  border: 1.5px solid var(--line-strong);
  color: var(--ink);
  font-size: 1.3rem;
  font-weight: 800;
  text-decoration: none;
}
.lesson-head__back:hover { background: var(--surface-2); color: var(--ink); border-color: var(--ink-soft); }
.lesson-head__title { display: flex; align-items: center; gap: .65rem; flex: 1 1 180px; min-width: 0; }
.lesson-head__icon { display: grid; place-items: center; flex: none; width: var(--tap); height: var(--tap); border-radius: var(--r); background: color-mix(in srgb, var(--theme-color) 14%, white); font-size: 1.55rem; }
.lesson-head__eyebrow { margin: 0; font-size: .74rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-soft); }
.lesson-head__name { margin: 0; font: 700 1.12rem/1.2 var(--font-display); }
.lesson-head__progress { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .9rem; }
.lesson-head__step { margin: 0; font-weight: 800; font-size: .9rem; color: var(--orange-dark); white-space: nowrap; }

.progress-dots { display: flex; flex-wrap: wrap; gap: .4rem; list-style: none; padding: 0; margin: 0; }
.dot {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 2px solid var(--line-strong);
  background: var(--white);
  color: var(--ink-soft);
  font-weight: 800;
  text-decoration: none;
  transition: transform .12s ease;
}
.dot:hover { border-color: var(--theme-color); color: var(--ink); }
.dot.is-done { background: var(--green); border-color: var(--green); color: var(--white); }
.dot.is-current { border-color: var(--ink); box-shadow: 0 0 0 3px var(--yellow); color: var(--ink); transform: scale(1.06); }
.dot.is-done.is-current { color: var(--white); }

.lesson__grid { display: grid; gap: 1.25rem; grid-template-areas: "player" "panel" "phrases"; }
@media (min-width: 960px) {
  .lesson__grid {
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
    grid-template-areas: "player panel" "phrases panel";
    grid-template-rows: auto 1fr;
    align-items: start;
  }
  .sign-panel { position: sticky; top: 96px; }
}

.player-card {
  grid-area: player;
  padding: .7rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
}
.player { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-lg); overflow: hidden; background: #0B1020; }
.player__video { width: 100%; height: 100%; object-fit: contain; background: #0B1020; }
.player__video::cue { font: 700 1.1rem var(--font-body); background: rgba(0, 0, 0, .8); color: #FFF; }
.player--placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  text-align: center;
  background: var(--orange-soft);
  background: radial-gradient(circle at 50% 38%, var(--white) 0 18%, transparent 19%), linear-gradient(160deg, color-mix(in srgb, var(--theme-color) 26%, white), color-mix(in srgb, var(--theme-color) 8%, white));
  color: var(--ink);
}
.player__letter {
  display: grid;
  place-items: center;
  width: clamp(76px, 18%, 120px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--white);
  color: var(--theme-color);
  font: 800 clamp(2.4rem, 7vw, 3.6rem)/1 var(--font-display);
  box-shadow: var(--shadow);
}
.player__word { font: 800 clamp(1.5rem, 5vw, 2.1rem)/1.1 var(--font-display); }
.player__soon { padding: .25rem .9rem; border-radius: 999px; background: var(--white); font-weight: 800; font-size: .92rem; box-shadow: var(--shadow-sm); }

.player-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; padding: .7rem .2rem .15rem; }
.player-controls__group { display: flex; flex-wrap: wrap; gap: .5rem; }
.segmented { display: inline-flex; padding: 3px; border: 1.5px solid var(--line-strong); border-radius: 999px; background: var(--white); }
.segmented__btn {
  min-height: 38px;
  padding: .3rem .9rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: 800 .95rem var(--font-body);
  cursor: pointer;
}
.segmented__btn[aria-pressed="true"] { background: var(--blue); color: var(--white); }
.offline-save { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.offline-save__status { margin: 0; font-size: .88rem; font-weight: 700; color: var(--ink-soft); }
.offline-save__status:empty { display: none; }

.sign-panel {
  grid-area: panel;
  display: flex;
  flex-direction: column;
  gap: .9rem;
  padding: 1.35rem 1.35rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
}
.sign-panel__word { font-size: clamp(2.3rem, 8vw, 3.2rem); line-height: 1.05; margin: 0; color: var(--blue); }
.sign-panel__phrase { margin: -.35rem 0 0; font-size: 1.2rem; font-weight: 800; }
.sign-panel__tags { display: flex; flex-wrap: wrap; gap: .35rem; margin: 0; }
.sign-panel__details { display: grid; gap: .8rem; margin: 0; padding: .9rem 1rem; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--line); }
.sign-panel__details dt { font-size: .85rem; font-weight: 800; color: var(--ink-soft); }
.sign-panel__details dd { margin: .1rem 0 0; font-size: 1.05rem; font-weight: 700; }
.sign-panel__actions { display: grid; gap: .75rem; }

.parent-note { padding: .9rem 1rem; border-radius: var(--r); background: var(--blue-soft); border: 1px solid #BFD2F3; }
.parent-note__title { margin: 0 0 .35rem; font-weight: 800; }
.parent-note p:last-child { margin: 0; }

.stars { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.stars__icons { font-size: 1.6rem; letter-spacing: .08em; color: #C47A2C; }
.stars__label { font-weight: 700; color: var(--ink-soft); font-size: .95rem; }
.stars__icons.is-popping { animation: pop .5s ease; }
.did-it { font-size: 1.45rem; min-height: 68px; }
.did-it.is-busy { opacity: .7; }
.lesson-nav { display: flex; gap: .6rem; }
.lesson-nav > * { flex: 1; }

.phrases-card { grid-area: phrases; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); }
.phrases-card__summary {
  display: flex;
  align-items: center;
  gap: .8rem;
  min-height: 64px;
  padding: .75rem 1rem;
  border-radius: var(--r-lg);
  list-style: none;
  cursor: pointer;
}
.phrases-card__summary::-webkit-details-marker { display: none; }
.phrases-card__summary:hover { background: var(--surface-2); }
.phrases-card__icon { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 14px; background: var(--yellow-soft); font-size: 1.3rem; }
.phrases-card__label { flex: 1; display: grid; }
.phrases-card__label small { color: var(--ink-soft); font-weight: 700; }
.phrases-card__chevron { color: var(--ink-soft); transition: transform .2s ease; }
.phrases-card[open] .phrases-card__chevron { transform: rotate(180deg); }
.phrases-card__body { padding: 0 1rem 1rem; }

.phrase-list { display: grid; gap: .5rem; list-style: none; padding: 0; margin: 0 0 .5rem; }
.phrase-item {
  display: flex;
  align-items: center;
  gap: .65rem;
  min-height: 54px;
  padding: .45rem .55rem .45rem .9rem;
  border-radius: var(--r);
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  transition: border-color .15s ease, transform .15s ease;
}
.phrase-item:hover { border-color: var(--orange); color: var(--ink); transform: translateX(2px); }
.phrase-item__icon { font-size: 1.25rem; }
.phrase-item__text { flex: 1; }
.phrase-item__go { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--orange); color: var(--ink); font-size: .85rem; }

/* Celebration dialog */
.celebrate {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(11, 31, 82, .55);
  animation: fade-in .2s ease;
}
.celebrate__card {
  width: min(100%, 420px);
  padding: 1.75rem 1.25rem 1.25rem;
  text-align: center;
  background: var(--white);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  animation: pop .45s cubic-bezier(.2, 1.4, .4, 1);
}
.celebrate__card:focus { outline: none; }
.celebrate__stars { font-size: 3rem; margin: 0; letter-spacing: .1em; }
.celebrate__title { font-size: 1.7rem; margin: .25rem 0; }
.celebrate__text { font-weight: 700; color: var(--ink-soft); }
.celebrate__badges { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .5rem; }
.celebrate__badges li { padding: .6rem; border-radius: var(--r); background: var(--yellow-soft); font-weight: 800; }
.celebrate__actions { display: grid; gap: .6rem; }
@keyframes pop { 0% { transform: scale(.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes fade-in { from { opacity: 0; } }

.confetti-piece {
  position: fixed;
  top: -16px;
  z-index: 160;
  width: 10px;
  height: 16px;
  border-radius: 3px;
  pointer-events: none;
  animation: confetti-fall 1.9s ease-in forwards;
}
@keyframes confetti-fall { to { transform: translate3d(var(--dx, 0), 105vh, 0) rotate(720deg); opacity: .9; } }

/* ---------------------------------------------------------------------
   12. Search
   --------------------------------------------------------------------- */
.search-panel { display: grid; gap: .75rem; margin-bottom: .25rem; }
.search-box {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .35rem .35rem .35rem 1.1rem;
  background: var(--white);
  border: 2px solid var(--orange-edge);
  border-radius: 999px;
  box-shadow: var(--shadow);
}
.search-box:focus-within { box-shadow: 0 0 0 5px var(--yellow); }
.search-box__icon { font-size: 1.3rem; }
.search-box input { flex: 1; min-width: 0; border: 0; background: transparent; font-size: 1.2rem; font-weight: 800; padding: .5rem 0; }
.search-box input:focus-visible { box-shadow: none; outline: none; }
.search-box .btn { border-radius: 999px; }
@media (max-width: 480px) { .search-box .btn { padding: .5rem .95rem; } }

.filters > summary {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  min-height: 44px;
  padding: .35rem 1rem;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: var(--white);
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}
.filters > summary::-webkit-details-marker { display: none; }
.filters[open] > summary { background: var(--blue); color: var(--white); border-color: var(--blue); }
.filters__grid { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin-top: .75rem; padding: 1rem; border-radius: var(--r-lg); background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }

.search-status { min-height: 1.6em; margin: .9rem 0 .5rem; font-weight: 800; font-size: 1.05rem; }
.search-status:empty { margin: .25rem 0; min-height: 0; }
.search-status.is-loading::after { content: ' …'; }
.search-more { text-align: center; color: var(--ink-soft); font-weight: 700; margin-top: 1rem; }

.search-start { display: grid; gap: 1.35rem; margin-top: .75rem; }
.search-start__title { display: flex; align-items: center; gap: .4rem; font: 800 1rem var(--font-body); color: var(--ink-soft); margin: 0 0 .6rem; }

.phrases-to-work {
  margin: var(--section-gap) 0 0;
  padding: 1.25rem;
  border-radius: var(--r-xl);
  background: var(--yellow-soft);
  border: 1px solid #F0D3AA;
}
.phrases-to-work .section__title > span[aria-hidden="true"]:first-child { background: var(--white); }
.phrase-groups { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.phrase-group { --theme-color: var(--orange-edge); }
.phrase-group__title { display: flex; align-items: center; gap: .4rem; margin: 0 0 .6rem; padding-left: .6rem; border-left: 5px solid var(--theme-color); font-size: .98rem; }

/* ---------------------------------------------------------------------
   13. Parents & profile
   --------------------------------------------------------------------- */
.child-tabs ul { display: flex; gap: .5rem; overflow-x: auto; list-style: none; padding: .25rem .1rem .75rem; margin: 0 0 .25rem; }
.child-tab {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  min-height: 52px;
  padding: .3rem 1rem .3rem .35rem;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: var(--white);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}
.child-tab:hover { border-color: var(--ink-soft); color: var(--ink); }
.child-tab[aria-current="page"] { background: var(--blue); border-color: var(--blue); color: var(--white); }
.child-tab--add { padding-left: 1rem; border-style: dashed; }

.child-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  margin-bottom: 1.25rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, #FDEBD3 0%, #F8D4A6 60%, #F2C285 100%);
  box-shadow: var(--shadow);
}
.child-hero__main { flex: 1 1 260px; min-width: 0; }
.child-hero__name { font-size: 1.75rem; margin: 0; }
.child-hero__age { font: 700 1.05rem var(--font-body); color: var(--ink-soft); }
.child-hero__summary { margin: .3rem 0 0; font-size: 1.05rem; }
.child-hero__words { display: block; margin-top: .15rem; color: var(--ink-soft); font-weight: 700; font-size: .95rem; }
.child-hero__play { flex: none; }
@media (max-width: 560px) { .child-hero__play, .child-hero__play .btn { width: 100%; } }

.stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; list-style: none; padding: 0; margin: 0 0 1.25rem; }
@media (min-width: 720px) {
  .stat-grid { grid-template-columns: repeat(4, 1fr); }
  .stat-grid--admin { grid-template-columns: repeat(3, 1fr); }
}
.stat-card {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: .75rem;
  align-items: center;
  padding: 1rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.stat-card__icon { grid-row: span 2; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 16px; background: var(--yellow-soft); font-size: 1.5rem; }
.stat-card__value { font: 800 1.7rem/1.1 var(--font-display); }
.stat-card__value small { font-size: .95rem; color: var(--ink-soft); }
.stat-card__label { font-weight: 800; color: var(--ink-soft); font-size: .9rem; }
.stat-card__sub { grid-column: 1 / -1; margin-top: .5rem; padding-top: .5rem; border-top: 1px dashed var(--line); font-size: .82rem; color: var(--ink-soft); }

.week-chart { display: flex; align-items: flex-end; justify-content: space-between; gap: .4rem; height: 170px; list-style: none; padding: 0; margin: 0; }
.week-chart__day { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: .35rem; height: 100%; }
.week-chart__bar {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  width: 100%;
  max-width: 42px;
  height: max(var(--h), 6px);
  max-height: calc(100% - 1.8rem);
  padding-top: .15rem;
  border-radius: 10px 10px 4px 4px;
  background: var(--orange);
  color: var(--ink);
  font-weight: 800;
  font-size: .82rem;
}
.week-chart__label { font-weight: 800; font-size: .82rem; color: var(--ink-soft); }

.recent-list { list-style: none; padding: 0; margin: 0; }
.recent-list li { display: flex; align-items: center; gap: .6rem; min-height: 46px; border-bottom: 1px dashed var(--line); font-weight: 700; }
.recent-list li:last-child { border-bottom: 0; }
.recent-list__stars { margin-left: auto; }

.lesson-progress-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.lesson-progress {
  --theme-color: var(--orange-edge);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .6rem .85rem;
  padding: .7rem .8rem;
  border-radius: var(--r);
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.lesson-progress__icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: color-mix(in srgb, var(--theme-color) 14%, white); font-size: 1.4rem; }
.lesson-progress__main { flex: 1 1 180px; display: grid; gap: .3rem; }
.lesson-progress__title { font-weight: 800; }
.lesson-progress__count { font-size: .85rem; color: var(--ink-soft); font-weight: 700; }

.tip-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .9rem; }
.tip { display: flex; gap: .8rem; align-items: flex-start; }
.tip__icon { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 15px; background: var(--yellow-soft); font-size: 1.45rem; }
.tip p { margin: .1rem 0 0; color: var(--ink-soft); }

.danger-zone { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px dashed var(--line-strong); }

.profile-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  margin-bottom: 1.25rem;
  padding: 1.25rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow);
}
.profile-hero__main { flex: 1 1 200px; min-width: 0; }
.profile-hero__name { font-size: 1.8rem; margin: 0; }
.profile-hero__role { margin: .15rem 0 0; font-weight: 700; color: var(--ink-soft); }
.profile-hero__stats { margin: 0; }
.switch-list, .offline-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.offline-list li { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .45rem .5rem .45rem .9rem; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--line); font-weight: 800; }

/* ---------------------------------------------------------------------
   14. Admin
   --------------------------------------------------------------------- */
.admin-list { list-style: none; padding: 0; margin: 0; }
.admin-list__item { display: flex; align-items: center; gap: .6rem; min-height: 50px; border-bottom: 1px dashed var(--line); }
.admin-list__item:last-child { border-bottom: 0; }
.admin-list__icon { font-size: 1.3rem; }
.admin-list__main { flex: 1; font-weight: 800; min-width: 0; }

.status { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .8rem; font-weight: 800; border: 1px solid; white-space: nowrap; }
.status--approved { background: var(--green-soft); border-color: #A5D3B5; color: var(--green-dark); }
.status--pending { background: var(--yellow-soft); border-color: #E6BC85; color: #6A3F0C; }
.status--rejected { background: var(--red-soft); border-color: #F2B1B1; color: var(--red-dark); }
.status--warning { background: #FCE9D2; border-color: #EDB677; color: #7A3E0A; }

.mini-table { width: 100%; border-collapse: collapse; }
.mini-table th, .mini-table td { text-align: left; padding: .5rem .35rem; border-bottom: 1px dashed var(--line); }
.mini-table tr:last-child td { border-bottom: 0; }
.mini-table th { font-size: .82rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .05em; }

.filter-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: .75rem 1rem;
  align-items: end;
  margin-bottom: 1rem;
  padding: 1rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
}
.filter-bar .checkbox-inline { align-self: end; }
.filter-bar__actions { display: flex; gap: .5rem; flex-wrap: wrap; }

.bulk-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-bottom: .75rem; font-weight: 800; }
.bulk-bar select { width: auto; min-height: 40px; }
.bulk-bar__count { color: var(--ink-soft); }

.table-wrap { overflow-x: auto; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { padding: .7rem .8rem; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table thead th { background: var(--surface-2); font-size: .8rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; }
.data-table tbody tr:hover { background: #FBF8F2; }
.data-table tr.is-muted { opacity: .6; }
.col-check { width: 48px; }
.video-cell { display: flex; align-items: center; gap: .75rem; }
.video-cell__thumb {
  --theme-color: var(--orange-edge);
  flex: none;
  display: grid;
  place-items: center;
  width: 64px; height: 48px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--orange-soft);
  background: color-mix(in srgb, var(--theme-color) 15%, white);
  font-size: 1.5rem;
}
.video-cell__thumb img { width: 100%; height: 100%; object-fit: cover; }
.row-actions { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.row-actions form { margin: 0; }

@media (max-width: 760px) {
  .table-wrap { border: 0; background: none; box-shadow: none; overflow: visible; }
  .data-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .data-table, .data-table tbody, .data-table tr, .data-table td { display: block; width: 100%; }
  .data-table tr { margin-bottom: 1rem; padding: .5rem; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--shadow); }
  .data-table td { display: flex; gap: .75rem; justify-content: space-between; align-items: center; border-bottom: 1px dashed var(--line); padding: .55rem .5rem; }
  .data-table tbody tr td:last-child { border-bottom: 0; }
  .data-table td::before { content: attr(data-label); font-weight: 800; color: var(--ink-soft); font-size: .82rem; flex: none; }
  .data-table td.col-check { justify-content: flex-start; }
}

.mode-tabs { display: inline-flex; gap: .25rem; padding: .3rem; margin-bottom: 1.25rem; border-radius: 999px; background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.mode-tabs [role="tab"] {
  min-height: 44px;
  padding: .35rem 1.2rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: 800 1rem var(--font-body);
  cursor: pointer;
}
.mode-tabs [aria-selected="true"] { background: var(--blue); color: var(--white); }

.upload-layout { display: grid; gap: 1.25rem; }
.upload-main > .panel:last-child { margin-bottom: 0; }
.upload-side { display: grid; gap: 1rem; align-content: start; }
.upload-side .panel { margin: 0; }
@media (min-width: 960px) {
  .upload-layout { grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); align-items: start; }
  .upload-side { position: sticky; top: 150px; }
}

.dropzone {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem;
  border: 2px dashed var(--line-strong);
  border-radius: var(--r-lg);
  background: var(--surface-2);
  cursor: pointer;
  font-weight: 600;
  transition: border-color .15s ease, background-color .15s ease;
}
.dropzone:hover, .dropzone.is-dragover { border-color: var(--orange); background: var(--orange-soft); }
.dropzone__icon { font-size: 2.3rem; }
.dropzone__file { margin-left: auto; font-weight: 800; color: var(--blue); word-break: break-all; }
.dropzone--big { min-height: 140px; justify-content: center; text-align: center; flex-direction: column; }
.dropzone--big .dropzone__file { margin: 0; }
/* The native file input is visually hidden; the whole drop zone is its label. */
.dropzone__input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; clip: rect(0 0 0 0); }
.dropzone:has(+ .dropzone__input:focus-visible) { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 7px var(--yellow); }
.dropzone__file:not(:empty) { padding: .2rem .7rem; border-radius: 999px; background: var(--blue-soft); }
.upload-preview { width: 100%; max-height: 320px; margin-top: .75rem; border-radius: var(--r); background: #0B1020; }
.subtle-details > summary { cursor: pointer; font-weight: 800; color: var(--blue); min-height: 44px; display: flex; align-items: center; }
.subtle-details[open] > summary { margin-bottom: .5rem; }

.thumb-preview {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  margin-bottom: .75rem;
  padding: .5rem;
  border-radius: var(--r);
  background: var(--surface-2);
  border: 2px dashed var(--line-strong);
  overflow: hidden;
  text-align: center;
  color: var(--ink-soft);
  font-weight: 700;
}
.thumb-preview img { width: 100%; height: 100%; object-fit: cover; }
.thumb-preview:has(img:not([hidden])) { padding: 0; border-style: solid; }

.upload-progress { display: flex; align-items: center; gap: .75rem; font-weight: 800; }
progress { flex: 1; width: 100%; height: 14px; accent-color: var(--orange); }

.bulk-list { list-style: none; padding: 0; margin: 1rem 0; display: grid; gap: .75rem; }
.bulk-row {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: .75rem;
  padding: .9rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.bulk-row > [data-remove-row] { grid-column: 1 / -1; justify-self: end; }
.bulk-row__thumb { display: grid; place-items: center; width: 96px; aspect-ratio: 4 / 3; border-radius: 14px; background: var(--surface-2); font-size: 2rem; overflow: hidden; }
.bulk-row__thumb img { width: 100%; height: 100%; object-fit: cover; }
.bulk-row__fields { display: grid; gap: .6rem; min-width: 0; }
.bulk-row__file { margin: 0; word-break: break-all; }
.bulk-row__status { display: flex; align-items: center; gap: .75rem; font-weight: 800; }
.bulk-row.is-done { border-color: #A5D3B5; background: var(--green-soft); }
.bulk-row.is-error { border-color: #F2B1B1; background: var(--red-soft); }
@media (min-width: 760px) {
  .bulk-row { grid-template-columns: 120px 1fr auto; align-items: start; }
  .bulk-row__thumb { width: 120px; }
  .bulk-row > [data-remove-row] { grid-column: auto; }
}
.bulk-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.bulk-actions__summary { margin: 0; font-weight: 800; }

.order-list { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .5rem; }
.order-list__item {
  --theme-color: var(--line-strong);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .6rem;
  padding: .6rem .75rem;
  border-radius: var(--r);
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-left: 5px solid var(--theme-color);
}
.order-list__pos { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--white); border: 1px solid var(--line-strong); font-weight: 800; font-size: .9rem; }
.order-list__icon { font-size: 1.5rem; }
.order-list__main { flex: 1 1 180px; min-width: 0; }

.inline-form { display: flex; flex-wrap: wrap; gap: .75rem; align-items: end; }
.inline-form .field { flex: 1 1 220px; }
.inline-form .field--xs { flex: 0 0 auto; }
.inline-form--wide { width: 100%; }
.inline-form--tight { gap: .35rem; align-items: center; flex-wrap: nowrap; }
.inline-form--tight select { min-width: 130px; min-height: 40px; }
.lesson-thumb-preview { width: 200px; border-radius: var(--r); margin-bottom: .5rem; }

/* ---------------------------------------------------------------------
   14b. Classes (teachers, learners, parents)
   --------------------------------------------------------------------- */
.class-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); margin-bottom: 1.25rem; }
.class-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: .25rem;
  padding: 1.2rem 1.2rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow);
  transition: transform .15s ease, box-shadow .15s ease;
}
.class-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.class-card:focus-within { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 7px var(--yellow); }
.class-card__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: .5rem; }
.class-card__icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--blue-soft); font-size: 1.7rem; }
.class-card__code { padding: .25rem .7rem; border-radius: 999px; background: var(--yellow-soft); font: 800 .95rem var(--font-display); letter-spacing: .08em; }
.class-card__name { font-size: 1.25rem; margin: 0; }
.class-card__link { color: var(--ink); text-decoration: none; }
.class-card__link::after { content: ''; position: absolute; inset: 0; }
.class-card__link:focus-visible { outline: none; box-shadow: none; }
.class-card__school { margin: 0; color: var(--ink-soft); font-weight: 700; font-size: .92rem; }
.class-card__meta { display: flex; flex-wrap: wrap; gap: .4rem 1rem; margin: .6rem 0 0; font-weight: 800; font-size: .92rem; color: var(--ink-soft); }

.class-head { margin-bottom: 1rem; }
.class-top { display: grid; gap: 1.25rem; margin-bottom: 1.25rem; }
@media (min-width: 900px) { .class-top { grid-template-columns: minmax(260px, 1fr) 2fr; align-items: stretch; } }
.class-stats { margin: 0; }
@media (min-width: 900px) { .class-stats { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1180px) { .class-stats { grid-template-columns: repeat(2, 1fr); } }

.join-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  padding: 1.35rem;
  text-align: center;
  border-radius: var(--r-xl);
  background: var(--blue);
  color: var(--white);
  box-shadow: var(--shadow-lg);
}
.join-card__label { margin: 0; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; color: #C7D5F5; }
.join-card__code { margin: 0; padding: .2rem 1rem; border-radius: var(--r); background: rgba(255, 255, 255, .1); font: 800 clamp(2.2rem, 7vw, 2.9rem)/1.2 var(--font-display); letter-spacing: .14em; }
.join-card__help { margin: .25rem 0 .6rem; color: #D8E2FF; font-size: .92rem; }
.join-card .btn-ghost { --btn-bg: transparent; --btn-fg: var(--white); --btn-border: rgba(255, 255, 255, .5); --btn-edge: rgba(0, 0, 0, .2); }
.join-card .btn-ghost:hover { --btn-bg: rgba(255, 255, 255, .12); --btn-border: var(--white); }

.assignment-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; }
.assignment {
  --theme-color: var(--orange-edge);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .6rem .9rem;
  padding: .75rem .85rem;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 5px solid var(--theme-color);
  box-shadow: var(--shadow-sm);
}
.panel .assignment { background: var(--surface-2); box-shadow: none; }
.assignment.is-finished { opacity: .8; }
.assignment__icon { display: grid; place-items: center; flex: none; width: 46px; height: 46px; border-radius: 14px; background: color-mix(in srgb, var(--theme-color) 14%, white); font-size: 1.5rem; }
.assignment__main { flex: 1 1 200px; min-width: 0; }
.assignment__title { margin: 0; font: 700 1.05rem var(--font-display); }
.assignment__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .75rem; margin: .2rem 0 0; font-size: .88rem; font-weight: 700; color: var(--ink-soft); }
.assignment__note { font-style: italic; }
.due { padding: .1rem .55rem; border-radius: 999px; font-weight: 800; font-size: .8rem; }
.due--late { background: var(--red-soft); color: var(--red-dark); }
.due--soon { background: var(--yellow-soft); color: #6A3F0C; }
.due--later { background: var(--blue-soft); color: var(--blue-dark); }

.assign-form {
  display: grid;
  gap: .75rem 1rem;
  align-items: end;
  margin-top: 1.1rem;
  padding-top: 1.1rem;
  border-top: 1px dashed var(--line-strong);
}
@media (min-width: 760px) { .assign-form { grid-template-columns: 2fr 1fr 2fr auto; } }

.table-wrap--flat { box-shadow: none; }
.progress-table__lesson { white-space: normal !important; min-width: 110px; }
.cell-progress { display: inline-flex; align-items: center; gap: .25rem; padding: .15rem .6rem; border-radius: 999px; font-weight: 800; font-size: .85rem; white-space: nowrap; }
.cell-progress--done { background: var(--green-soft); color: var(--green-dark); }
.cell-progress--started { background: var(--yellow-soft); color: #6A3F0C; }
.cell-progress--none { color: var(--ink-soft); }
.streak { color: var(--orange-dark); font-weight: 800; }
.muted { color: var(--ink-soft); }

.class-list li > span { display: grid; }
.class-list__teacher { font-weight: 700; color: var(--ink-soft); }
.class-summary { margin: .75rem 0 0; }
.join-form { display: grid; gap: .35rem; margin-top: 1rem; font-weight: 800; }
.join-form__row { display: flex; gap: .5rem; }
.join-form__input { flex: 1; min-width: 0; text-transform: uppercase; letter-spacing: .15em; font-weight: 800 !important; font-size: 1.1rem !important; }
.join-form__input::placeholder { letter-spacing: .15em; }

.steps--compact { margin-bottom: 1.5rem; }
a.audience-card__status { text-decoration: none; }
a.audience-card__status:hover { text-decoration: underline; }

/* ---------------------------------------------------------------------
   Line icons inside components (grown-up areas use icons, kids' areas emoji)
   --------------------------------------------------------------------- */
.btn .icon { width: 1.15em; height: 1.15em; }
.btn-small .icon { width: 1.05em; height: 1.05em; }
:is(.page-title, .section__title, .panel__title, .auth-card__title) > span[aria-hidden="true"]:first-child:has(.icon) { background: var(--blue-soft); color: var(--blue); }
:is(.page-title, .section__title, .panel__title) > span[aria-hidden="true"]:first-child .icon { width: 1.2em; height: 1.2em; }
.stat-card__icon:has(.icon) { background: var(--blue-soft); color: var(--blue); }
.stat-card__icon .icon { width: 1.4rem; height: 1.4rem; }
.class-card__icon, .lesson-head__icon:has(.icon) { color: var(--blue); }
.class-card__icon .icon { width: 1.6rem; height: 1.6rem; }
.lesson-head__icon:has(.icon) { background: var(--blue-soft); }
.lesson-head__icon .icon { width: 1.45rem; height: 1.45rem; }
.class-card__meta > span { display: inline-flex; align-items: center; gap: .3rem; }
.class-card__meta .icon { width: 1rem; height: 1rem; }
.admin-list__icon { display: flex; }
.admin-list__icon .icon { width: 1.25rem; height: 1.25rem; color: var(--blue); }
.dropzone__icon { display: grid; place-items: center; width: 56px; height: 56px; flex: none; border-radius: 18px; background: var(--white); color: var(--orange-dark); box-shadow: var(--shadow-sm); }
.dropzone__icon .icon { width: 1.7rem; height: 1.7rem; }
.mode-tabs [role="tab"] { display: inline-flex; align-items: center; gap: .45rem; }
.mode-tabs [role="tab"] .icon { width: 1.1rem; height: 1.1rem; }

/* Admin filter bars: fields first, then a right-aligned action row */
.filter-bar__actions { grid-column: 1 / -1; justify-content: flex-end; padding-top: .25rem; border-top: 1px dashed var(--line); }
.filter-bar .checkbox-inline { min-height: var(--tap); }

/* ---------------------------------------------------------------------
   15. Motion preferences
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .confetti-piece { display: none; }
}
