/* Reading Level Check: the arcade's grown-up page look (pages.css) plus the check's own screens. Calm and still:
   no animation here at all; the only motion is the pages' own. Letters and words use the school-shaped ABeeZee
   font (one-story a and g), like Spell the Picture's tiles. */
@font-face {
  font-family: 'ABeeZee';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../spell/abeezee.woff2) format('woff2');
}

.grow { flex: 1; }
.top .round { cursor: pointer; }
#sound .mute { display: none; }
#sound[aria-pressed='false'] .mute { display: inline; }
#sound[aria-pressed='false'] .waves { display: none; }
@media (max-width: 420px) { .brand-name { display: none; } }

/* Under the Child lock only the note shows (kids.css hides [data-unlocked-only]). */
.locked-note { display: none; }
body.locked .locked-note { display: grid; }

.screen { display: grid; gap: 18px; min-width: 0; }
.small { font-size: 15px; color: var(--soft); }
.kicker { font-size: 15px; font-weight: 600; color: var(--soft); text-transform: none; }
.btn { width: 100%; }
@media (min-width: 700px) { .btn { width: auto; justify-self: start; } }
.big-go { min-height: 72px; font-size: 24px; }
.btn.danger { color: #8a3b12; border-color: #8a3b12; box-shadow: 0 5px 0 #8a3b12; background: #fff7f0; }
.btn:disabled { opacity: 0.45; cursor: default; }

/* Setup */
.setup { gap: 14px; }
.name-field { display: grid; gap: 6px; font-weight: 600; }
.name-field small { font-weight: 400; color: var(--soft); }
.name-field input { min-height: 56px; border: 3px solid var(--ink); border-radius: 14px; padding: 6px 14px; font: 500 20px 'Fredoka', system-ui, sans-serif; background: #fff; color: var(--ink); width: 100%; }
.starts { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); }
.starts legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.starts button { min-height: 64px; display: grid; justify-items: start; align-content: center; gap: 0; text-align: left; padding: 6px 8px 6px 38px; position: relative;
  border: 3px solid var(--ink); border-radius: 16px; background: var(--card); color: var(--ink); font: 700 17px/1.2 'Fredoka', system-ui, sans-serif; cursor: pointer; }
.starts button small { font-size: 14px; font-weight: 500; color: var(--soft); }
.starts button::before { content: ''; position: absolute; left: 10px; top: 50%; width: 18px; height: 18px; margin-top: -9px; border: 3px solid var(--ink); border-radius: 50%; background: #fff; }
/* Picked: a filled check mark, not only a color. */
.starts button[aria-pressed='true'] { background: #dff3e1; border-color: var(--green-d); outline: 3px solid var(--green); outline-offset: 1px; }
.starts button[aria-pressed='true']::before { background: var(--green-d); border-color: var(--green-d); box-shadow: inset 0 0 0 3px #fff; }

.history-link { margin: 0; }
.table-wrap { overflow-x: auto; max-width: 100%; }
table.steps { border-collapse: collapse; width: 100%; font-size: 16px; background: var(--card); }
table.steps th, table.steps td { border: 2px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; }
table.steps th { background: #fbe9c6; }
.more-links { font-size: 16px; }

/* Between parts */
.part-done { background: #eef6ee; }
.outcome { font-size: 20px; font-weight: 600; }
.outcome .mark { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 2px solid currentColor; margin-right: 8px; font-size: 16px; vertical-align: -3px; }

/* An item: big letter or word, two big answers */
.item-top { display: grid; gap: 6px; }
.dots { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; flex-wrap: wrap; }
.dots li { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--ink); background: #fff; }
.dots li.on { background: var(--ink); }
.dots li.now { outline: 3px solid var(--blue); outline-offset: 2px; }
.ask { font-size: 18px; color: var(--soft); margin: 0; }
.card-read { background: #fffdf7; border: 3px solid var(--ink); border-radius: 26px; box-shadow: 0 6px 0 var(--ink); min-height: clamp(160px, 30dvh, 300px);
  display: grid; place-items: center; padding: 16px; }
.read-this { font: 400 clamp(64px, 20vw, 150px)/1.1 'ABeeZee', 'Comic Sans MS', sans-serif; color: var(--ink); text-align: center; overflow-wrap: anywhere; max-width: 100%;
  -webkit-user-select: none; user-select: none; }
.read-this.word { font-size: clamp(54px, 16vw, 130px); }
.read-this.long { font-size: clamp(44px, 12vw, 110px); }
.hint { font-size: 16px; color: var(--soft); min-height: 1.4em; margin: 0; }
.answer-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.answer { min-height: 88px; border: 3px solid var(--ink); border-radius: 22px; box-shadow: 0 5px 0 var(--ink); display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 700 24px 'Fredoka', system-ui, sans-serif; cursor: pointer; color: var(--ink); background: var(--card); padding: 6px; -webkit-user-select: none; user-select: none; }
.answer.yes { background: var(--green); border-color: var(--green-d); box-shadow: 0 5px 0 var(--green-d); color: #fff; }
.answer:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.item-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.item-tools .btn { width: 100%; justify-self: stretch; }
.small-btn { min-height: 52px; font-size: 17px; padding: 6px 10px; box-shadow: 0 3px 0 var(--ink); }
@media (min-width: 900px) {
  #item { max-width: 760px; width: 100%; justify-self: center; }
  #between, #finish, #history { max-width: 860px; width: 100%; justify-self: center; }
}

/* All done */
.cheer { font-size: clamp(32px, 8vw, 44px); margin: 0; }
.result { background: #eef6ee; }
.headline { font-size: 24px; font-weight: 700; line-height: 1.3; }
.parts { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.parts li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; padding: 8px 10px; border: 2px solid var(--line); border-radius: 12px; background: var(--card); }
.parts .how { font-weight: 600; }
.talk { font-size: 18px; background: #fff8e6; border-radius: 16px; padding: 12px 16px; margin: 0; }

/* Saved checks */
.child { display: grid; gap: 8px; margin-bottom: 14px; }
.child h3 { margin: 0; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.checks li { display: grid; gap: 2px; padding: 10px 12px; border: 2px solid var(--line); border-radius: 14px; background: var(--card); }
.checks .when { font-weight: 700; }
.checks .change { font-size: 15px; color: var(--green-d); font-weight: 600; }
.checks .change.same { color: var(--soft); }
.empty { color: var(--soft); }

/* Evening (rule 4): dimmer and warmer after 6 PM. */
body.evening main, body.evening .top { filter: brightness(.92) sepia(.08); }

@media print { .item-tools, .answer-row, #lock-slot, #sound { display: none !important; } }
