

@media screen {
  :root { color:#162747; background:#edf3f5; font-family:'Nunito Sans',Arial,sans-serif; }
  body {
    min-height:100vh;
    background:radial-gradient(circle at 8% 14%,rgba(206,232,242,.8),transparent 32%),
               radial-gradient(circle at 95% 40%,rgba(214,225,245,.7),transparent 35%),#f2f6f7;
  }
  .topbar {
    height:82px; background:#101d3a; color:#fff; border-bottom:1px solid #30436b;
    box-shadow:0 8px 28px rgba(10,26,57,.13);
  }
  .brand {gap:13px; letter-spacing:0; line-height:1}
  .brand-mark {
    width:42px;height:42px;border-radius:11px;display:grid;place-items:center;
    color:#16264c;background:#f5ba53;box-shadow:inset 0 1px rgba(255,255,255,.4);
    font-size:1.7rem;
  }
  .brand-text {display:flex;flex-direction:column;gap:3px}
  .brand-text small {font-size:.56rem;letter-spacing:.2em;font-weight:800;color:#9fb3d5}
  .brand-text strong {
    font:800 1.38rem/.9 'Nunito',Nunito,sans-serif;letter-spacing:.015em;
    color:#fff;
  }
  .brand-text strong span {color:#f6f8fc}
  .brand-text strong span:nth-child(3),.brand-text strong span:nth-child(7) {color:#f5bd59}
  .brand-text em {font-style:normal;font-size:.56rem;font-weight:800;letter-spacing:.16em;color:#a9c0df}
  .topbar-note {font-size:.69rem;letter-spacing:.17em;color:#b6c6dd;font-weight:800}
  .topbar-note span {color:#f5bd59;margin-left:9px;font-size:1rem}
  .workspace {
    max-width:1490px;grid-template-columns:minmax(330px,410px) minmax(0,1fr);
    gap:clamp(20px,2.4vw,38px);padding:clamp(22px,3vw,42px);
  }
  .builder {
    top:22px;padding:clamp(24px,2.5vw,36px);border:1px solid #d9e2ec;border-radius:22px;
    background:#fff;box-shadow:0 20px 50px rgba(24,48,90,.10),0 2px 6px rgba(24,48,90,.04);
  }
  .builder:before {
    content:'';position:absolute;top:0;left:34px;width:44px;height:4px;
    border-radius:0 0 4px 4px;background:#efb65a;
  }
  .eyebrow {
    font-size:.72rem;font-weight:800;letter-spacing:.16em;color:#2374ad;
  }
  .builder .eyebrow {margin:0 0 15px}
  .builder .eyebrow span {color:#9bb0c3;margin-left:5px}
  .builder h1 {
    font:800 clamp(2.1rem,2.7vw,2.7rem)/1.03 'Nunito',Nunito,sans-serif;
    letter-spacing:-.055em;color:#142544;margin:0 0 15px;max-width:340px;
  }
  .builder-intro>p:last-child {font-size:.97rem;line-height:1.55;color:#53647b;margin:0 0 27px}
  form label,fieldset legend {font-weight:800;color:#263b59;font-size:.86rem}
  .optional {font-size:.75rem;color:#8998aa}
  input:not([type=radio]),select {
    height:48px;border:1px solid #ced9e4;border-radius:9px;
    background:#f9fbfc;color:#172b4b;box-shadow:inset 0 1px 2px rgba(22,46,75,.02);
  }
  input:not([type=radio]):hover,select:hover {border-color:#a5b8cc}
  input:not([type=radio]):focus,select:focus {border-color:#2577b7;background:#fff}
  fieldset {margin:24px 0}
  .theme-grid {gap:9px}
  .theme-tile {
    min-height:88px;gap:7px;border:1px solid #d8e1e9;border-radius:10px;
    background:#fbfcfd;font-size:.77rem;font-weight:800;color:#435772;
    transition:transform .16s,border-color .16s,box-shadow .16s,background .16s;
  }
  .theme-tile:hover {transform:translateY(-2px);border-color:#a7bed1;box-shadow:0 6px 16px rgba(24,65,107,.08)}
  .theme-tile:has(input:checked) {
    border:2px solid #247eb1;background:#ecf8fd;color:#154d75;
    box-shadow:0 0 0 3px rgba(43,142,188,.09);
  }
  .theme-icon {
    font:700 1.45rem/1 'Nunito',sans-serif;
    width:34px;height:34px;border-radius:8px;display:grid;place-items:center;
    color:#fff;box-shadow:inset 0 1px rgba(255,255,255,.35);
  }
  .theme-tile:nth-child(1) .theme-icon {background:#208db6}
  .theme-tile:nth-child(2) .theme-icon {background:#7663ad}
  .theme-tile:nth-child(3) .theme-icon {background:#4b9b78}
  .theme-tile:nth-child(4) .theme-icon {background:#d68755}
  .theme-tile:has(input:checked) .theme-icon {color:#fff}
  .primary-button {
    min-height:56px;margin-top:25px;border:0;border-radius:10px;
    padding:12px 17px 12px 21px;
    background:#162d57;color:#fff;box-shadow:0 8px 18px rgba(12,35,76,.2);
    font:700 1rem 'Nunito',Nunito,sans-serif;letter-spacing:-.01em;
    transition:transform .16s,background .16s,box-shadow .16s;
  }
  .primary-button span[aria-hidden] {font:700 1.5rem 'Nunito Sans',sans-serif;color:#f5c264}
  .primary-button:hover {background:#214376;transform:translateY(-2px);box-shadow:0 10px 22px rgba(12,35,76,.23)}
  .primary-button:active {transform:translateY(0);box-shadow:0 4px 10px rgba(12,35,76,.2)}
  .builder-foot {
    margin-top:25px;padding:16px 0 0;background:none;border:0;border-top:1px solid #e3e9ef;
    border-radius:0;display:flex;gap:12px;
  }
  .builder-foot p {font-size:.78rem;color:#687c92;line-height:1.55}
  .builder-foot strong {color:#246d9e}
  .foot-icon {color:#e1a44a;font-size:1.35rem}
  .preview-hero {
    display:block;height:330px;min-height:0;border:1px solid #adc1d5;border-radius:21px;
    box-shadow:0 18px 40px rgba(24,55,94,.18);background:#2085bd;
  }
  .preview-hero .hero-art {
    position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;
  }
  .preview-hero:after {
    content:'';position:absolute;inset:0;pointer-events:none;
    background:linear-gradient(90deg,rgba(9,32,69,.89) 0%,rgba(11,49,91,.74) 28%,rgba(20,74,118,.14) 64%,transparent 100%);
  }
  .preview-hero .hero-copy {
    display:flex;flex-direction:column;justify-content:center;align-items:flex-start;
    position:relative;z-index:1;width:52%;min-height:100%;padding:32px 18px 34px 38px;
  }
  .preview-hero .eyebrow {color:#f5cb79;margin-bottom:13px}
  .preview-hero h2 {
    font:800 clamp(2.5rem,4.3vw,4.25rem)/.98 'Nunito',Nunito,sans-serif;
    letter-spacing:-.055em;color:#fff;margin:0 0 15px;max-width:400px;
    text-shadow:0 3px 14px rgba(5,24,52,.25);
  }
  .preview-hero p:last-of-type {font-size:1rem;color:#e7f2fa;font-weight:500;line-height:1.45;max-width:270px;margin:0}
  .hero-badge {
    margin-top:25px;border:1px solid rgba(255,255,255,.45);border-radius:5px;
    background:rgba(10,37,74,.28);backdrop-filter:blur(5px);
    padding:7px 10px;color:#ffdf9a;font-size:.65rem;font-weight:800;letter-spacing:.17em;
  }
  .preview-actions {
    margin:22px 0 19px;padding:15px 18px;min-height:74px;
    border:1px solid #d9e2ec;border-radius:13px;background:#fff;
    box-shadow:0 7px 22px rgba(29,60,102,.055);
  }
  .preview-actions strong {font:700 1rem 'Nunito',Nunito,sans-serif;color:#1e3554}
  .preview-actions span {color:#74859c}
  .secondary-button,.dark-button {
    min-height:43px;border-radius:8px;font-size:.86rem;font-weight:800;box-shadow:none;
  }
  .secondary-button {border:1px solid #cad7e3;background:#fff;color:#1d4269}
  .secondary-button:hover {background:#f3f8fb}
  .dark-button {border:1px solid #173b67;background:#176998;color:#fff}
  .dark-button:hover {background:#12537b}
  .dark-button span {color:#f9cc78}
  .sheet,.answers-screen {
    background:#fff;border:1px solid #d8e1e9;border-radius:14px;
    box-shadow:0 10px 30px rgba(27,56,94,.07);
  }
  .sheet {padding:31px 34px}
  .sheet-head {border-bottom:2px solid #203d63;padding-bottom:16px}
  .sheet-kicker {color:#2c799e;font-size:.72rem}
  .sheet h3,.answers-screen h3 {
    font-family:'Nunito',Nunito,sans-serif;font-weight:800;letter-spacing:-.035em;color:#193457;
  }
  .sheet h3 {font-size:1.9rem}
  .sheet-number {
    width:40px;height:40px;border-radius:8px;color:#173759;
    background:#f7ce7b;font:800 1.1rem 'Nunito',sans-serif;
  }
  .instructions {color:#465971}
  .puzzle-grid {border-color:#284265}
  .sheet-footer {color:#8190a4}
  .answer-item h4 {color:#286d95}
  .site-footer {color:#697f98;font-size:.68rem;font-weight:800;letter-spacing:.15em;padding:18px 20px 35px}
  .site-footer span {color:#c08b47;margin:0 9px}
}
@media screen and (max-width:1100px) {
  .workspace {grid-template-columns:315px minmax(0,1fr);gap:22px}
  .builder {padding:24px}
  .preview-hero {height:305px}
  .preview-hero .hero-copy {width:56%;padding-left:28px}
  .preview-hero h2 {font-size:3rem}
}
@media screen and (max-width:760px) {
  .topbar {height:74px}
  .workspace {display:block;padding:20px}
  .builder {position:static;margin-bottom:25px}
  .theme-grid {grid-template-columns:repeat(4,1fr)}
  .preview-hero {height:300px}
  .preview-hero .hero-copy {width:58%}
  .preview-actions {align-items:stretch}
}
@media screen and (max-width:470px) {
  .topbar {padding:0 18px}
  .brand-mark {width:38px;height:38px}
  .brand-text strong {font-size:1.15rem}
  .brand-text em {font-size:.48rem}
  .workspace {padding:15px}
  .builder {padding:23px}
  .builder h1 {font-size:2.25rem}
  .theme-grid {grid-template-columns:repeat(2,1fr)}
  .preview-hero {height:280px}
  .preview-hero .hero-art {object-position:59% center}
  .preview-hero:after {background:linear-gradient(90deg,rgba(7,30,65,.9),rgba(9,42,81,.65) 42%,rgba(7,39,79,.12) 86%)}
  .preview-hero .hero-copy {width:69%;padding:21px 9px 21px 20px}
  .preview-hero h2 {font-size:2.35rem}
  .preview-hero p:last-of-type {font-size:.84rem}
  .preview-hero .eyebrow {font-size:.62rem}
  .hero-badge {font-size:.54rem;margin-top:19px}
  .preview-actions {padding:14px}
  .sheet {padding:19px}
}
@media print {
  .sheet h3,.answer-sheet h3 {font-family:Arial,sans-serif;font-weight:800;letter-spacing:-.02em}
  .sheet-number {border:1.5px solid #111;background:#fff;color:#111;border-radius:5px}
  .sheet-head {border-bottom:2px solid #111}
  .sheet-kicker,.sheet h3,.instructions,.sheet-footer,.answer-item h4 {color:#111}
}

/* Family profile and personalized visual system */
[hidden] {display:none!important}
@media screen {
  body {--accent:#208db6;--accent-soft:#e8f7fb;--accent-deep:#165274;--cover-corner:18px}
  body[data-palette="sky"] {--accent:#238fbc;--accent-soft:#e7f6fc;--accent-deep:#125577}
  body[data-palette="coral"] {--accent:#cf6c72;--accent-soft:#fff0ef;--accent-deep:#904452}
  body[data-palette="violet"] {--accent:#8064b9;--accent-soft:#f2edff;--accent-deep:#564184}
  body[data-palette="forest"] {--accent:#479877;--accent-soft:#ebf8f1;--accent-deep:#286849}
  body[data-palette="gold"] {--accent:#ca8b3d;--accent-soft:#fff6e5;--accent-deep:#825a28}
  body[data-age-tier="junior"] {--cover-corner:25px}
  body[data-age-tier="epic"] {--cover-corner:8px}
  .builder:has(#profile-editor:not([hidden])) {position:static}
  .family-panel {padding:18px 0 22px;margin:0 0 23px;border-top:1px solid #e4ebf1;border-bottom:1px solid #e4ebf1}
  .family-heading {display:flex;align-items:flex-end;justify-content:space-between;gap:8px;margin-bottom:11px}
  .family-heading .eyebrow {font-size:.63rem;margin:0 0 5px;letter-spacing:.14em;color:var(--accent)}
  .family-heading h2 {font:800 1.34rem/1.1 'Nunito',Nunito,sans-serif;color:#193451;letter-spacing:-.03em;margin:0}
  .text-button {border:0;background:transparent;color:var(--accent-deep);padding:6px 0;font-weight:800;font-size:.78rem;text-decoration:underline;text-underline-offset:3px}
  .profile-loading,.profile-help {font-size:.8rem;line-height:1.4;color:#697d92}
  #family-greeting {font-size:.82rem;color:#5d7188;margin:0 0 11px}
  .child-picker {display:flex;flex-wrap:wrap;gap:8px}
  .child-chip {
    display:flex;align-items:center;gap:8px;padding:7px 11px 7px 7px;
    border:1px solid #d3e0e9;border-radius:10px;background:#fafcfd;color:#264260;
    min-height:49px;text-align:left;transition:transform .15s,border-color .15s,background .15s;
  }
  .child-chip:hover {transform:translateY(-1px);border-color:var(--accent)}
  .child-chip[aria-pressed="true"] {background:var(--accent-soft);border:2px solid var(--accent);padding:6px 10px 6px 6px}
  .chip-avatar {width:32px;height:32px;border-radius:8px;display:grid;place-items:center;background:var(--accent);color:#fff;font:800 1rem 'Nunito',sans-serif}
  .child-chip strong,.child-chip small {display:block;line-height:1.15}
  .child-chip strong {font-size:.8rem}.child-chip small {font-size:.68rem;color:#6f8296;margin-top:3px}
  #profile-editor {padding-top:2px}
  #profile-editor .field-row {grid-template-columns:1.6fr .7fr}
  #profile-editor input,#profile-editor select {background:#fff}
  .children-fields {display:grid;grid-template-columns:minmax(0,1fr);gap:11px;margin-top:17px;min-width:0}
  .child-fields {min-inline-size:0;padding:14px;border:1px solid #dce5ec;border-radius:12px;background:#fbfcfd;margin:0}
  .child-fields legend {padding:0 5px;font-size:.75rem;color:var(--accent-deep);letter-spacing:.07em;text-transform:uppercase}
  .child-fields label {display:block;font-size:.76rem;color:#405871}
  .child-fields input,.child-fields select {height:41px;margin-top:5px;font-size:.85rem}
  .child-field-grid {display:grid;grid-template-columns:1fr 1.3fr;gap:9px;margin:10px 0}
  .profile-help {margin:11px 0 0}
  .profile-error {color:#a8343d;background:#fff0ef;padding:9px 10px;border-radius:7px;font-size:.79rem;margin:12px 0 0}
  .profile-actions {display:flex;align-items:center;gap:14px;margin-top:16px}
  .save-profile {background:var(--accent-deep);color:#fff;border:0;border-radius:8px;padding:10px 15px;font-size:.84rem;font-weight:800}
  .save-profile:hover {filter:brightness(1.12)}
  .save-profile:disabled {opacity:.55;cursor:wait}
  #pack-form .field-row input[readonly],#pack-form .field-row select:disabled {background:var(--accent-soft);color:#203d59;opacity:1;border-color:#c7dae3}
  .theme-tile:has(input:checked) {border-color:var(--accent);background:var(--accent-soft);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 10%,transparent);color:var(--accent-deep)}
  .builder .eyebrow,.sheet-kicker {color:var(--accent)}
  .preview-hero {border-radius:var(--cover-corner)}
  .preview-hero:after {background:linear-gradient(90deg,rgba(9,32,69,.91) 0%,color-mix(in srgb,var(--accent-deep) 78%,transparent) 36%,rgba(20,74,118,.07) 69%,transparent 100%)}
  .primary-button {background:var(--accent-deep)}
  .primary-button:hover {background:color-mix(in srgb,var(--accent-deep) 80%,#101d3a)}
  .dark-button {background:var(--accent-deep);border-color:var(--accent-deep)}
  .dark-button:hover {background:color-mix(in srgb,var(--accent-deep) 80%,#101d3a)}
  .sheet-number {background:var(--accent-soft);color:var(--accent-deep)}
  body[data-age-tier="junior"] .sheet {border-radius:20px}
  body[data-age-tier="junior"] .sheet h3 {font-size:2.05rem}
  body[data-age-tier="epic"] .sheet {border-radius:8px}
  body[data-age-tier="epic"] .sheet-number {border-radius:5px}
  body[data-age-tier="epic"] .preview-hero h2 {text-transform:uppercase;font-size:clamp(2.25rem,3.7vw,3.8rem);letter-spacing:-.035em}
  .cover-sheet {min-height:610px;background:#fff;border:1px solid #d8e1e9;border-radius:14px;overflow:hidden;margin-bottom:18px;box-shadow:0 10px 30px rgba(27,56,94,.07)}
  .cover-art {height:375px;position:relative;background:#205f8d;overflow:hidden}
  .cover-art:after {content:'';position:absolute;inset:0;background:linear-gradient(0deg,rgba(8,28,60,.4),transparent 55%)}
  .cover-art img {display:block;width:100%;height:100%;object-fit:cover;object-position:center}
  .cover-art span {position:absolute;z-index:1;left:32px;bottom:26px;color:#fff;font-weight:800;letter-spacing:.16em;font-size:.8rem;text-shadow:0 2px 8px rgba(0,0,0,.5)}
  .cover-details {padding:30px 34px 35px;border-top:7px solid var(--accent)}
  .cover-details p {font-size:.74rem;font-weight:800;letter-spacing:.14em;color:var(--accent-deep);margin:0 0 8px}
  .cover-details h3 {font:800 clamp(2.5rem,4vw,4rem)/1 'Nunito',Nunito,sans-serif;letter-spacing:-.05em;color:#1a3154;margin:0 0 19px}
  .cover-rule {height:2px;background:#dce6ec;width:100%;margin-bottom:17px}
  .cover-details strong,.cover-details small {display:block}
  .cover-details strong {font-size:1rem;color:#273e5b}
  .cover-details small {font-size:.82rem;color:#72859b;margin-top:5px}
  body[data-age-tier="junior"] .cover-sheet {border-radius:25px}
  body[data-age-tier="epic"] .cover-sheet {border-radius:8px}
}
@media screen and (max-width:760px) {
  .builder:has(#profile-editor:not([hidden])) {position:static}
  .cover-art {height:280px}
  .cover-sheet {min-height:0}
}
@media screen and (max-width:470px) {
  .child-chip {flex:1 1 calc(50% - 4px)}
  .cover-art {height:220px}
  .cover-art span {left:18px;bottom:18px;font-size:.64rem}
  .cover-details {padding:22px}
  .cover-details h3 {font-size:2.55rem}
}
@media print {
  body {--accent:#2185ae;--accent-deep:#124c71}
  body[data-palette="coral"] {--accent:#c96972;--accent-deep:#904452}
  body[data-palette="violet"] {--accent:#8064b9;--accent-deep:#564184}
  body[data-palette="forest"] {--accent:#479877;--accent-deep:#286849}
  body[data-palette="gold"] {--accent:#ca8b3d;--accent-deep:#825a28}
  .cover-sheet {display:flex;flex-direction:column;width:8.5in;height:11in;padding:.55in;margin:0;break-after:page;page-break-after:always;background:#fff}
  .cover-art {height:6.1in;position:relative;overflow:hidden;background:#2276aa}
  .cover-art img {width:100%;height:100%;object-fit:cover}
  .cover-art span {position:absolute;left:.35in;bottom:.28in;color:#fff;font:bold 13pt Arial,sans-serif;letter-spacing:.12em;text-shadow:0 1px 4px #333}
  .cover-details {border-top:8pt solid var(--accent);padding:.32in .12in;flex:1}
  .cover-details p {font:bold 11pt Arial,sans-serif;letter-spacing:.12em;color:var(--accent-deep);margin:0 0 .12in}
  .cover-details h3 {font:bold 37pt/1 Arial,sans-serif;letter-spacing:-.03em;color:#152c4e;margin:0 0 .3in}
  .cover-rule {height:1pt;background:#b5c4d2;margin-bottom:.21in}
  .cover-details strong,.cover-details small {display:block}
  .cover-details strong {font:bold 13pt Arial,sans-serif}.cover-details small {font:10pt Arial,sans-serif;margin-top:.08in}
  .sheet {border:0;border-radius:0}
  .sheet-number {background:#fff;border:1.5px solid #111;color:#111}
}

/* Challenge mix, answer paths and scan card */
@media screen {
  .builder {position:static}
  .category-field {margin:22px 0}
  .category-field legend {font-size:.88rem}
  .field-help {font-size:.78rem;color:#6d8096;line-height:1.4;margin:3px 0 12px}
  .category-grid {display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .category-grid label {
    display:grid;grid-template-columns:30px 1fr;column-gap:7px;align-items:center;
    min-height:67px;padding:8px;border:1px solid #d8e3eb;border-radius:10px;
    background:#fbfcfd;cursor:pointer;position:relative;
  }
  .category-grid label:has(input:checked) {border:2px solid var(--accent);padding:7px;background:var(--accent-soft)}
  .category-grid input {position:absolute;opacity:0;inset:0;cursor:pointer}
  .category-grid label:focus-within {outline:3px solid #e8aa53;outline-offset:2px}
  .category-grid label>span {grid-row:1/3;width:29px;height:29px;display:grid;place-items:center;background:#e8eef4;color:#355a7b;border-radius:7px;font-size:1.2rem}
  .category-grid label:has(input:checked)>span {background:var(--accent);color:#fff}
  .category-grid strong {font-size:.75rem;line-height:1.1;color:#203d5b}
  .category-grid small {font-size:.63rem;line-height:1.25;color:#718499}
  .preview-actions {flex-wrap:wrap}
  .action-buttons {flex-wrap:wrap;justify-content:flex-end}
  .dark-button:disabled {opacity:.5;cursor:wait}
  .play-intro {display:flex;justify-content:space-between;gap:18px;align-items:center;padding:16px 18px;margin-bottom:17px;border:1px solid #dbe6ee;background:#fff;border-radius:12px}
  .play-intro strong {font:800 1rem 'Nunito',sans-serif;color:#19385c}
  .play-intro p {font-size:.82rem;color:#60768b;line-height:1.4;margin:4px 0 0;max-width:560px}
  .play-intro label {display:flex;align-items:center;gap:7px;min-width:150px;font-size:.75rem;font-weight:700;color:#48627b}
  .play-intro input {accent-color:var(--accent)}
  .checkpoint {border:1px solid #bcd5e3;background:var(--accent-soft);border-radius:10px;padding:17px;margin:22px 0 0}
  .checkpoint legend {padding:0 6px;text-transform:uppercase;letter-spacing:.12em;color:var(--accent-deep);font-size:.72rem;font-weight:800}
  .checkpoint p {margin:0 0 12px;font-weight:700;color:#25435e;font-size:.9rem}
  .choice-grid {display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .choice-grid label {display:flex;align-items:center;gap:8px;min-height:42px;border:1px solid #d3e0e8;border-radius:7px;padding:7px 9px;background:#fff;font-size:.8rem;line-height:1.25;color:#29435e;cursor:pointer}
  .choice-grid label:has(input:checked) {border:2px solid var(--accent);padding:6px 8px;background:#fff}
  .choice-grid input {accent-color:var(--accent);flex:none}
  .choice-letter {font-weight:800;color:var(--accent-deep)}
  .puzzle-hint {font-size:.8rem;text-align:center;color:#576f83}
  .discovery-card,.story-card {max-width:530px;margin:12px auto 24px;border:1px solid #c9dce7;border-left:5px solid var(--accent);border-radius:10px;background:#f8fbfd;padding:22px 25px}
  .discovery-card span,.story-card span {font-size:.7rem;font-weight:800;letter-spacing:.13em;color:var(--accent-deep)}
  .discovery-card p,.story-card p {font:700 1.25rem/1.4 'Nunito',sans-serif;color:#1d3a5a;margin:16px 0 0}
  .answer-card {background:#fff;border:1px solid #d8e1e9;border-radius:14px;padding:24px 30px;margin-bottom:18px;box-shadow:0 10px 30px rgba(27,56,94,.07)}
  .answer-card-screen strong {font:800 1.4rem 'Nunito',sans-serif;color:#1b385a}
  .answer-card-screen p {font-size:.86rem;color:#62798d;margin:5px 0 18px}
  .answer-card svg {display:block;max-width:650px;margin:auto;border:1px solid #cad7e3}
  .card-heading {font:bold 27px Arial,sans-serif;fill:#182e4d}
  .card-code {font:bold 21px Arial,sans-serif;fill:#173d66}
  .card-instruction,.card-foot {font:17px Arial,sans-serif;fill:#313c48}
  .card-number {font:bold 22px Arial,sans-serif;fill:#213958}
  .card-title {font:17px Arial,sans-serif;fill:#243c58}
  .card-bubble {fill:#fff;stroke:#1f2d3e;stroke-width:3}
  .card-letter {font:bold 19px Arial,sans-serif;fill:#152d4c}
  .online-panel {background:#fff;border:1px solid #d8e3eb;border-radius:15px;padding:24px;margin:0 0 20px;box-shadow:0 8px 26px rgba(24,58,97,.07)}
  .online-head {display:flex;justify-content:space-between;align-items:flex-start;gap:12px;border-bottom:1px solid #dce6ed;padding-bottom:16px;margin-bottom:19px}
  .online-head .eyebrow {font-size:.72rem;margin-bottom:5px}
  .online-head h3 {font:800 1.55rem/1.2 'Nunito',sans-serif;color:#173758;margin:0}
  .online-head p:last-child {color:#60768b;font-size:.84rem;margin:7px 0 0}
  .online-instruction {font-size:.95rem;line-height:1.5;color:#364b70;margin:0 0 17px}
  .online-panel .sheet-body {padding:7px 0 15px}
  .online-nav {display:flex;flex-wrap:wrap;gap:9px;margin-top:18px}
  .online-nav button:disabled {opacity:.45;cursor:default}
  .online-nav #score-online {margin-left:auto}
  .scan-panel,.results-panel {background:#fff;border:1px solid #d8e3eb;border-radius:15px;padding:24px;margin:0 0 20px;box-shadow:0 8px 26px rgba(24,58,97,.07)}
  .scan-head {display:flex;justify-content:space-between;gap:15px;align-items:flex-start}
  .scan-head .eyebrow {font-size:.67rem;margin:0 0 6px;color:var(--accent)}
  .scan-head h3,.results-panel h3 {font:800 1.8rem 'Nunito',sans-serif;letter-spacing:-.04em;color:#173758;margin:0}
  .scan-panel>p {font-size:.9rem;line-height:1.48;color:#5f7389}
  .scan-inputs {display:grid;grid-template-columns:1fr 1.5fr;gap:12px;margin:18px 0}
  .scan-inputs label {font-size:.8rem;font-weight:800;color:#2a4968}
  .scan-inputs input {display:block;width:100%;height:44px;border:1px solid #cbd9e4;border-radius:8px;padding:8px;margin-top:6px;background:#fbfdff}
  .scan-inputs input[type=file] {height:auto}
  .scan-status {background:var(--accent-soft);border-radius:8px;padding:10px 12px;color:var(--accent-deep)!important;font-weight:700}
  .scan-canvas-wrap {max-width:700px;margin:16px auto;background:#e4ebf0;border-radius:9px;overflow:hidden}
  #scan-canvas {display:block;width:100%;height:auto;cursor:default;touch-action:manipulation}
  #scan-review {border-top:1px solid #e2eaf0;margin-top:20px;padding-top:16px}
  #scan-review h4 {font:800 1.2rem 'Nunito',sans-serif;color:#23425f;margin:0}
  #scan-review>p {font-size:.8rem;color:#6a7d91}
  .review-grid {display:grid;grid-template-columns:1fr 1fr;gap:9px}
  .review-grid label {display:flex;align-items:center;justify-content:space-between;gap:8px;border:1px solid #dce6ed;border-radius:7px;padding:7px 10px;font-size:.78rem;color:#284660}
  .review-grid select {width:80px;height:36px;margin:0;flex:none}
  .scan-buttons {display:flex;gap:14px;align-items:center;margin-top:16px}
  .result-heading {display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #e2eaf1;padding-bottom:12px;margin-bottom:13px}
  .result-heading span {font-size:.74rem;letter-spacing:.14em;font-weight:800;color:var(--accent-deep)}
  .result-heading strong {font:800 2.3rem 'Nunito',sans-serif;color:#183a5a}
  .result-heading small {font-size:1rem;color:#7b8fa1}
  .results-panel>p {font-size:.9rem;color:#526d82}
  .result-list {list-style:none;padding:0;display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .result-list li {display:grid;grid-template-columns:1fr auto;gap:3px 9px;border:1px solid #dce6ec;border-radius:8px;padding:10px 12px;font-size:.83rem;color:#24435d}
  .result-list li strong {font-size:.76rem}.result-list li small {grid-column:1/-1;color:#697e8e;line-height:1.3}
  .result-list li.right strong {color:#197452}.result-list li.wrong strong {color:#a34a47}.result-list li.missing strong {color:#a2712b}
}
@media screen and (max-width:760px) {
  .play-intro {align-items:flex-start;flex-direction:column}
  .action-buttons {justify-content:stretch}
  .action-buttons button {flex:1 1 auto}
  .scan-inputs,.result-list {grid-template-columns:1fr}
}
@media screen and (max-width:470px) {
  .category-grid {gap:6px}
  .category-grid label {grid-template-columns:1fr;min-height:77px}
  .category-grid label>span {grid-row:auto;width:25px;height:25px;font-size:1rem}
  .category-grid strong {font-size:.72rem}
  .category-grid small {display:none}
  .choice-grid,.review-grid {grid-template-columns:1fr}
  .answer-card {padding:16px}
  .scan-panel,.results-panel,.online-panel {padding:18px}
  .online-nav #score-online {margin-left:0}
}
@media print {
  .play-intro,.online-panel,.scan-panel,.results-panel {display:none!important}
  .checkpoint {border:1.5px solid #333;padding:12pt;margin-top:14pt;break-inside:avoid}
  .checkpoint legend {font:bold 10pt Arial,sans-serif;letter-spacing:.06em;color:#111}
  .checkpoint p {font:bold 11pt Arial,sans-serif;margin:0 0 9pt}
  .choice-grid {display:grid;grid-template-columns:1fr 1fr;gap:6pt}
  .choice-grid label {display:flex;gap:6pt;font:10pt Arial,sans-serif;line-height:1.3}
  .choice-grid input {display:none}
  .choice-letter {font-weight:bold;border:1pt solid #111;border-radius:50%;width:16pt;height:16pt;text-align:center;flex:none}
  .puzzle-hint {font:10pt Arial,sans-serif;text-align:center}
  .discovery-card,.story-card {border:1pt solid #222;padding:20pt;margin:15pt auto}
  .discovery-card p,.story-card p {font:bold 17pt/1.35 Arial,sans-serif;margin-top:10pt}
  .answer-card {display:flex;flex-direction:column;align-items:center;width:8.5in;height:11in;padding:.45in;margin:0;break-after:page;page-break-after:always}
  .answer-card-screen {display:none}
  .answer-card svg {width:7.6in;height:9.65in;max-width:none}
  body:not(.print-answers) .answer-sheet {display:none!important}
  body.print-answers .answer-sheet {display:flex}
}

/* Guided family flow and subscription preview */
@media screen {
  html {scroll-behavior:smooth}
  #family,#choose-child,#pack-form,#plans {scroll-margin-top:20px}
  .journey {max-width:1490px;margin:23px auto -16px;padding:0 clamp(22px,3vw,42px);display:flex;align-items:center;gap:8px}
  .journey a {display:flex;align-items:center;gap:9px;padding:8px 13px 8px 8px;text-decoration:none;color:#526981;background:#fff;border:1px solid #d7e3ed;border-radius:999px;font-size:.87rem;font-weight:800;white-space:nowrap}
  .journey a b {display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:#e5edf5;color:#315778;font-size:.79rem}
  .journey a[aria-current="step"] {border-color:#207da7;color:#164e74;background:#e9f8fd;box-shadow:0 3px 12px rgba(29,91,131,.12)}
  .journey a[aria-current="step"] b {background:#176e9e;color:#fff}
  .journey-plan {margin-left:auto;padding:8px 12px;border-radius:999px;background:#102c63;color:#ffe1a1;font-size:.78rem;font-weight:800;white-space:nowrap}
  .account-email {margin:0;color:#74879b;font-size:.84rem;overflow-wrap:anywhere}
  .family-panel {margin-bottom:18px}
  .choose-panel {padding:17px 17px 18px;margin-bottom:23px;border:1px solid #d5e5ee;border-radius:13px;background:#f5fbfd}
  .choose-panel .eyebrow {margin:0 0 5px;font-size:.72rem}
  .choose-panel h2 {font:800 1.36rem/1.15 'Nunito',sans-serif;color:#193451;margin:0 0 5px}
  .choose-panel>p:not(.eyebrow) {color:#60758a;font-size:.88rem;line-height:1.45;margin:0 0 13px}
  .choose-panel .child-chip {min-width:136px;background:#fff}
  .choose-panel .child-chip strong {font-size:.9rem}
  .choose-panel .child-chip small {font-size:.76rem}
  .choose-panel .selected-note {color:#215b79!important;font-weight:700;margin:13px 0 0!important}
  #pack-form>.eyebrow {margin-top:0;margin-bottom:18px}
  #pack-form .primary-button:disabled {opacity:.58;cursor:wait}
  .preview-empty {padding:25px 28px;border:1px dashed #b9d4e5;border-radius:14px;background:#fff;margin-top:20px;box-shadow:0 7px 20px rgba(25,63,103,.04)}
  .preview-empty strong {font:800 1.32rem 'Nunito',sans-serif;color:#1b395a}
  .preview-empty p {max-width:590px;color:#5b7189;font-size:.96rem;line-height:1.5;margin:6px 0 0}
  .preview-empty .secondary-button {margin-top:17px}
  .plans-section {max-width:1490px;margin:26px auto 65px;padding:0 clamp(22px,3vw,42px)}
  .plans-heading {display:flex;justify-content:space-between;align-items:end;gap:20px;margin-bottom:18px}
  .plans-heading .eyebrow {margin-bottom:6px}
  .plans-heading h2 {font:800 clamp(1.8rem,2.8vw,2.45rem)/1.08 'Nunito',sans-serif;letter-spacing:-.04em;color:#132b50;margin:0 0 6px}
  .plans-heading p:last-child {margin:0;color:#5a718b;font-size:.96rem;line-height:1.5}
  .usage-note {color:#356988;background:#e5f3fa;border-radius:999px;padding:10px 15px;font-size:.83rem;font-weight:800;white-space:nowrap}
  .plans-scroll-hint {display:none}
  .plan-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:17px}
  .plan-card {display:flex;flex-direction:column;align-items:start;min-width:0;padding:26px 29px;min-height:350px;border:1px solid #d7e5ee;border-radius:18px;background:#fff;box-shadow:0 12px 29px rgba(24,56,96,.055)}
  .plan-card.current {border:2px solid #1b779f;padding:25px 28px}
  .plan-card.plus {background:#13274b;color:#fff;border-color:#13274b}
  .plan-card.plus.current {border-color:#f5cc78}
  .plan-tag {font-size:.72rem;letter-spacing:.14em;font-weight:800;color:#247ba5}
  .plan-card.plus .plan-tag {color:#f5cc78}
  .plan-card h3 {font:800 1.8rem/1.1 'Nunito',sans-serif;letter-spacing:-.04em;margin:10px 0 6px;color:#17375b}
  .plan-card.plus h3 {color:#fff}
  .plan-card p {font-size:.94rem;line-height:1.46;color:#546e86;margin:0}
  .plan-card.plus p {color:#c8d9e9}
  .plan-card .plan-price {font:800 1.14rem/1.3 'Nunito',sans-serif;color:#176e9e;margin:3px 0 13px}
  .plan-card.plus .plan-price {color:#ffdc97}
  .plan-card ul {padding:0;list-style:none;margin:20px 0 19px;color:#294864;font-size:.9rem;line-height:1.4}
  .plan-card li {position:relative;padding-left:24px;margin-bottom:9px}
  .plan-card li:before {content:'✓';position:absolute;left:0;color:#167aa4;font-weight:800}
  .plan-card.plus ul {color:#e3ecf5}
  .plan-card.plus li:before {color:#f5cc78}
  .plan-included {display:grid;place-items:center;width:100%;min-height:45px;margin-top:auto;border:1px solid #d5e2ec;border-radius:8px;background:#f1f7fa;color:#41637d;font-size:.87rem;font-weight:800;text-align:center}
  .plan-card .dark-button {display:inline-flex;align-items:center;justify-content:center;width:100%;margin-top:auto;border:1px solid #f4ca74;background:#f4ca74;color:#162c4c;font-size:.88rem;text-align:center;text-decoration:none}
  .plan-card .dark-button:hover {background:#ffe3a5}
  .plan-card .dark-button:disabled {background:#d7e5ec;border-color:#d7e5ec;color:#234866;cursor:default}
  .plan-card .plan-status {min-height:1.2em;margin-top:10px;font-size:.84rem}
  .plans-fine {color:#657c90;font-size:.81rem;line-height:1.45;margin:14px 2px 0}
  .site-footer a {color:#356c8e;text-decoration:underline;text-underline-offset:3px}
}
@media screen and (max-width:760px) {
  .journey {overflow-x:auto;margin:15px auto -5px;padding:0 20px 7px;scrollbar-width:thin}
  .journey-plan {margin-left:4px}
  .plans-section {padding:0 20px;margin-top:28px}
  .plans-heading {align-items:start;flex-direction:column;gap:10px}
  .plan-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media screen and (max-width:530px) {
  .topbar-links a[href="#family"],.topbar-links a[href="#builder-title"] {display:none}
  .journey a {font-size:.78rem;padding-right:10px}
  .plan-card {min-height:0;padding:22px}
  .plan-card.current {padding:21px}
  .plans-scroll-hint {display:block;margin:0 0 8px;color:#426d8a;font-size:.82rem;font-weight:800}
  .plan-grid {grid-template-columns:repeat(2,minmax(min(76vw,330px),1fr));gap:12px;overflow-x:auto;overscroll-behavior-inline:contain;scroll-snap-type:x mandatory;scroll-padding-inline:2px;padding:0 2px 15px 2px;scrollbar-width:thin}
  .plan-card {scroll-snap-align:start;min-height:400px}
  .choose-panel .child-chip {flex:1 1 calc(50% - 8px);min-width:0}
}
@media print {.journey,.preview-empty,.plans-section {display:none!important}}

/* Mobile-first app shell and route screens */
@media screen {
  .topbar {position:relative;z-index:5}
  .brand {color:#fff;text-decoration:none}
  .header-context {max-width:210px;padding:9px 13px;border:1px solid #526582;border-radius:999px;color:#ffe0a2;text-decoration:none;font-size:.82rem;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .header-context:hover {background:#263e63}
  .app-shell {display:grid;grid-template-columns:226px minmax(0,1fr);max-width:1680px;margin:auto;min-height:calc(100vh - 82px)}
  .app-sidebar {border-right:1px solid #dbe6ed;background:#fff;padding:27px 17px;display:flex;flex-direction:column;gap:20px}
  .side-label {padding:0 12px;color:#879aad;font-size:.72rem;letter-spacing:.14em;font-weight:800}
  .app-sidebar nav {display:grid;gap:5px}
  .app-sidebar nav a {display:flex;align-items:center;gap:12px;min-height:47px;padding:10px 12px;border-radius:10px;color:#385470;text-decoration:none;font-weight:800;font-size:.92rem}
  .app-sidebar nav a span {display:grid;place-items:center;width:25px;color:#2783ac;font-size:1.3rem;line-height:1}
  .app-sidebar nav a:hover {background:#f0f7fb}
  .app-sidebar nav a[aria-current="page"] {background:#e6f4fa;color:#125b83}
  .sidebar-foot {margin-top:auto;border-top:1px solid #e4ebf1;padding:20px 12px 0}
  .sidebar-foot strong {display:inline-block;background:#102c63;color:#ffe1a1;padding:8px 12px;border-radius:20px;font-size:.78rem}
  .sidebar-foot p {font-size:.81rem;color:#72869a;line-height:1.4}
  .sidebar-foot a {color:#287ba3;font-size:.8rem;font-weight:800}
  .app-main {min-width:0;padding:clamp(20px,2.7vw,38px)}
  .app-main .workspace {padding:0;margin:0;max-width:none;display:grid;grid-template-columns:minmax(0,1fr);gap:0}
  .app-main .builder,.app-main .preview {width:100%;max-width:950px;margin:0 auto}
  .app-main .builder {position:static}
  .child-fields label,.child-fields legend,.theme-tile,.category-grid strong {font-size:.88rem}
  .child-fields input,.child-fields select,#profile-editor input,#profile-editor select,.scan-inputs input,.plan-card.plus input {font-size:1rem}
  .online-nav button,.scan-head button,.pack-tools button {min-height:46px}
  .route-screen,.app-main .plans-section {max-width:1040px;margin:0 auto;padding:0}
  .bottom-nav {display:none}
  .route-loading {display:none;padding:26px;border-radius:13px;background:#fff;color:#59738a;font-size:1rem;font-weight:700}
  body[data-page="loading"] .route-loading {display:block}
  body[data-page="loading"] .home-screen,body[data-page="loading"] .workspace,body[data-page="loading"] .packs-screen,body[data-page="loading"] .plans-section {display:none!important}
  body:not([data-page="home"]) .home-screen,body:not([data-page="packs"]) .packs-screen,body:not([data-page="plans"]) .plans-section {display:none!important}
  body[data-page="home"] .workspace,body[data-page="packs"] .workspace,body[data-page="plans"] .workspace {display:none!important}
  body[data-page="family"] .preview,body[data-page="explorers"] .preview,body[data-page="build"] .preview {display:none!important}
  body[data-page="family"] .builder-intro,body[data-page="family"] .choose-panel,body[data-page="family"] #pack-form,body[data-page="family"] #builder-foot {display:none!important}
  body[data-page="explorers"] .builder-intro,body[data-page="explorers"] .family-panel,body[data-page="explorers"] #pack-form,body[data-page="explorers"] #builder-foot {display:none!important}
  body[data-page="build"] .family-panel,body[data-page="build"] .choose-panel {display:none!important}
  body[data-page="pack"] .builder,body[data-page="play"] .builder,body[data-page="scan"] .builder {display:none!important}
  body[data-page="pack"] .preview-empty,body[data-page="pack"] #online-panel,body[data-page="pack"] #scan-panel,body[data-page="pack"] #results {display:none!important}
  body[data-page="pack"] #pack .sheet,body[data-page="pack"] #pack .answer-card {display:flex}
  body[data-page="pack"] #pack .answer-card {display:block}
  body[data-page="play"] .preview-hero,body[data-page="play"] .preview-empty,body[data-page="play"] .preview-actions,body[data-page="play"] .play-intro,body[data-page="play"] .pack-tools,body[data-page="play"] .pack-overview,body[data-page="play"] #pack,body[data-page="play"] #answers,body[data-page="play"] #scan-panel {display:none!important}
  body[data-page="scan"] .preview-hero,body[data-page="scan"] .preview-empty,body[data-page="scan"] .preview-actions,body[data-page="scan"] .play-intro,body[data-page="scan"] .pack-tools,body[data-page="scan"] .pack-overview,body[data-page="scan"] #pack,body[data-page="scan"] #answers,body[data-page="scan"] #online-panel {display:none!important}
  .home-hero {position:relative;min-height:390px;display:flex;align-items:center;overflow:hidden;background:#102c63;color:#fff;border-radius:22px;box-shadow:0 18px 38px rgba(21,46,86,.14)}
  .home-hero img {position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:60% center}
  .home-hero:after {content:'';position:absolute;inset:0;background:linear-gradient(90deg,rgba(9,29,65,.94) 0%,rgba(13,43,85,.79) 43%,rgba(11,50,89,.08) 100%)}
  .home-hero>div {position:relative;z-index:1;max-width:540px;padding:clamp(27px,5vw,58px)}
  .home-hero .eyebrow {color:#ffd683}
  .home-hero h1 {font:800 clamp(2.45rem,5vw,4.4rem)/.99 'Nunito',sans-serif;letter-spacing:-.055em;margin:0 0 17px}
  .home-hero p:not(.eyebrow) {color:#e1eff8;line-height:1.5;font-size:1rem;max-width:420px}
  .home-cta {display:inline-flex;align-items:center;justify-content:space-between;gap:24px;background:#f4c363;color:#173252;text-decoration:none;border-radius:10px;padding:13px 17px;font-size:.94rem;font-weight:800;min-height:48px}
  .home-cta:hover {background:#ffda89}
  .family-continue {margin-top:18px}
  .family-members {display:flex;flex-wrap:wrap;gap:8px;margin-top:16px}
  .family-members>span {padding:9px 12px;border-radius:9px;background:#e9f6fb;color:#234d6d;font-size:.91rem;font-weight:800}
  .family-members small {color:#688299;font-weight:700}
  .home-cards {display:grid;grid-template-columns:1fr 1fr;gap:15px;margin:19px 0 29px}
  .home-cards a {display:flex;flex-direction:column;gap:7px;padding:23px;border:1px solid #d8e5ed;border-radius:15px;background:#fff;text-decoration:none;box-shadow:0 7px 20px rgba(26,58,94,.045)}
  .home-cards a:hover,.pack-card:hover {border-color:#8dbbd1;transform:translateY(-1px)}
  .home-cards span {font-size:.72rem;font-weight:800;color:#287fa8;letter-spacing:.12em}
  .home-cards strong {font:800 1.28rem 'Nunito',sans-serif;color:#173859}
  .home-cards small {font-size:.85rem;color:#60768b}
  .section-heading {display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:15px}
  .section-heading h1,.section-heading h2 {font:800 clamp(1.8rem,3vw,2.5rem) 'Nunito',sans-serif;letter-spacing:-.04em;color:#173353;margin:0}
  .section-heading a:not(.home-cta) {font-size:.86rem;color:#1972a0;font-weight:800}
  .packs-screen>p {font-size:.96rem;line-height:1.5;color:#60768b;margin:0 0 20px}
  .pack-list {display:grid;gap:10px}
  .pack-card {display:flex;align-items:center;gap:15px;min-height:83px;padding:13px 18px;border:1px solid #d7e4ed;border-radius:13px;background:#fff;text-decoration:none;transition:transform .15s,border-color .15s}
  .pack-card-mark {display:grid;place-items:center;flex:none;width:44px;height:44px;border-radius:10px;background:#e5f4fb;color:#197aa8;font-size:1.5rem}
  .pack-card>span:nth-child(2) {min-width:0;flex:1}
  .pack-card strong,.pack-card small {display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .pack-card strong {font-size:.98rem;color:#173856}
  .pack-card small {color:#74869a;font-size:.78rem;margin-top:5px}
  .pack-card b {color:#2581ab}
  .empty-packs {padding:26px;background:#fff;border:1px dashed #bad1e0;border-radius:13px;color:#61778d;font-size:.94rem}
  .packs-more {display:block;margin:17px auto 0;min-width:180px}
  .pack-tools {display:flex;flex-wrap:wrap;gap:9px;margin-bottom:18px}
  .pack-tools button {flex:1 1 160px}
  .pack-tools button:disabled {opacity:.5;cursor:default}
  .pack-overview {background:#fff;border:1px solid #d9e6ee;border-radius:15px;padding:24px;margin-bottom:18px}
  .pack-overview h3 {font:800 1.35rem 'Nunito',sans-serif;color:#19385c;margin:0 0 13px}
  .pack-overview ol {display:grid;grid-template-columns:1fr 1fr;gap:8px 18px;list-style:none;padding:0;margin:0}
  .pack-overview li {display:grid;grid-template-columns:32px minmax(0,1fr);gap:3px 8px;align-items:center;padding:9px 0;border-bottom:1px solid #edf1f4}
  .pack-overview li span {grid-row:1/3;color:#267ba5;font-weight:800;font-size:.81rem}
  .pack-overview li strong {color:#263f5a;font-size:.89rem}
  .pack-overview li small {color:#73869a;font-size:.75rem}
  .app-main .plans-section {margin:0 auto}
  #route-error {margin:0 0 15px}
}
@media screen and (max-width:940px) {
  .app-shell {grid-template-columns:1fr}
  .app-sidebar {display:none}
  .app-main {padding:18px 18px calc(89px + env(safe-area-inset-bottom))}
  .bottom-nav {position:fixed;z-index:20;left:0;right:0;bottom:0;display:grid;grid-template-columns:repeat(6,1fr);padding:7px max(9px,env(safe-area-inset-left)) calc(7px + env(safe-area-inset-bottom)) max(9px,env(safe-area-inset-right));background:#fff;border-top:1px solid #d7e3ec;box-shadow:0 -8px 23px rgba(22,49,87,.09)}
  .bottom-nav a {display:flex;align-items:center;justify-content:center;flex-direction:column;gap:2px;min-height:49px;border-radius:9px;text-decoration:none;color:#60758b;font-weight:800;font-size:.67rem}
  .bottom-nav a span {font-size:1.3rem;line-height:1;color:#4c819f}
  .bottom-nav a[aria-current="page"] {color:#145c83;background:#e8f5fb}
  .bottom-nav a[aria-current="page"] span {color:#1377a8}
  body[data-page="play"] .bottom-nav,body[data-page="scan"] .bottom-nav {display:none}
  body[data-page="play"] .app-main,body[data-page="scan"] .app-main {padding-bottom:18px}
  .site-footer {display:none}
}
@media screen and (max-width:590px) {
  .topbar {height:66px;padding:0 15px}
  .brand-mark {width:37px;height:37px}
  .brand-text strong {font-size:1.08rem}
  .brand-text em {font-size:.45rem}
  .header-context {max-width:117px;padding:8px 10px;font-size:.69rem}
  .app-main {padding:15px 15px calc(87px + env(safe-area-inset-bottom))}
  .app-main .builder {padding:22px 18px}
  .home-hero {min-height:380px;border-radius:17px}
  .home-hero img {object-position:58% center}
  .home-hero:after {background:linear-gradient(90deg,rgba(8,29,63,.94),rgba(10,39,75,.68) 62%,rgba(8,35,65,.18))}
  .home-hero>div {padding:24px;max-width:330px}
  .home-hero h1 {font-size:2.55rem}
  .home-cards {grid-template-columns:1fr;gap:10px}
  .home-cards a {padding:18px}
  .section-heading {align-items:start}
  .packs-screen .section-heading {display:block}
  .packs-screen .section-heading .home-cta {margin-top:13px}
  .pack-overview {padding:17px}
  .pack-overview ol {grid-template-columns:1fr}
  .preview-hero {height:280px}
  .preview-actions .action-buttons {display:grid;grid-template-columns:1fr 1fr;width:100%}
  .preview-actions .action-buttons button {min-width:0}
  .scan-inputs {grid-template-columns:1fr}
}
@media print {
  .app-shell,.app-main {display:block!important;padding:0!important;margin:0!important;max-width:none!important}
  .app-sidebar,.bottom-nav,.route-loading,.home-screen,.packs-screen,.pack-overview,.pack-tools,.plans-section,#route-error {display:none!important}
  #pack {display:block!important}
}

@media screen {
  body[data-page="account"] .workspace,body[data-page="account"] .home-screen,body[data-page="account"] .packs-screen,body[data-page="account"] .plans-section {display:none!important}
  body:not([data-page="account"]) .account-screen {display:none!important}
  .account-screen {max-width:680px;padding:clamp(12px,3vw,45px) 0}
  .account-card {background:#fff;border:1px solid #d9e3ed;border-radius:24px;box-shadow:0 18px 45px rgba(25,50,90,.1);padding:clamp(24px,4vw,42px)}
  .account-card h1 {font:800 clamp(2rem,4vw,2.8rem)/1.07 'Nunito',sans-serif;letter-spacing:-.04em;margin:0 0 12px;color:#142544}
  .account-card p {color:#52647d;line-height:1.5}
  .auth-tabs {display:grid;grid-template-columns:1fr 1fr;background:#edf3f7;border-radius:12px;padding:4px;margin:28px 0 22px}
  .auth-tabs button {border:0;border-radius:9px;background:transparent;color:#506682;font-weight:800;min-height:44px}
  .auth-tabs button[aria-pressed="true"] {background:#fff;color:#123d72;box-shadow:0 3px 12px rgba(24,48,90,.1)}
  #auth-form {display:grid;gap:17px}
  #auth-form label {display:block}
  #auth-form .dark-button {width:100%;margin-top:8px}
  #auth-status {min-height:1.5em;font-weight:700;color:#1b5b79}
  .account-note {border-top:1px solid #e4ebf2;padding-top:17px;font-size:.82rem}
  .account-identity {overflow-wrap:anywhere}
  .account-summary {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:25px 0}
  .account-summary>div {background:#f2f7fb;border:1px solid #dce8f2;border-radius:16px;padding:16px;min-width:0}
  .account-summary>div:first-child {grid-column:1/-1;background:#e9f4fa;border-color:#bfdae9}
  .account-field-label {display:block;color:#60758d;font-size:.75rem;letter-spacing:.08em;font-weight:800;margin-bottom:7px}
  .account-summary strong {display:block;color:#142c4c;font-size:1.1rem;line-height:1.25;overflow-wrap:anywhere}
  .account-summary small {display:block;color:#597089;font-size:.88rem;line-height:1.4;margin-top:5px}
  .account-actions {display:grid;gap:10px;margin:20px 0}
  .account-actions details {border:1px solid #d9e5ef;border-radius:15px;background:white;overflow:hidden}
  .account-actions summary {cursor:pointer;list-style:none;padding:16px 18px;display:flex;align-items:center;justify-content:space-between;gap:10px;color:#172f50}
  .account-actions summary::-webkit-details-marker {display:none}
  .account-actions summary::after {content:'+';font-size:1.4rem;line-height:1;color:#537491}
  .account-actions details[open] summary::after {content:'−'}
  .account-actions summary strong,.account-actions summary small {display:block}
  .account-actions summary strong {font-size:1rem}
  .account-actions summary small {color:#657b92;font-size:.85rem;line-height:1.4;margin-top:3px}
  .account-action-body {border-top:1px solid #e2eaf0;padding:17px 18px 19px}
  .account-action-body p {margin:0 0 16px;font-size:.94rem}
  .account-action-body form {display:grid;gap:12px}
  .account-action-body label {display:grid;gap:5px;color:#233d5e;font-size:.88rem;font-weight:700}
  .account-action-body input {width:100%;border:1px solid #bdcede;border-radius:9px;min-height:45px;padding:10px 12px;font:inherit}
  .account-action-body input:focus-visible,.account-actions summary:focus-visible {outline:3px solid #76b7dc;outline-offset:2px}
  .account-action-body button {justify-self:start;min-height:44px}
  .account-action-body form p[role="status"] {margin:0;min-height:1.2em;font-weight:700;color:#1b5b79}
  .account-link-button {display:inline-flex;align-items:center;text-decoration:none;min-height:44px}
  .account-danger {border-color:#edc9c7!important}
  .account-danger summary strong {color:#9c3134}
  .danger-button {border:0;border-radius:9px;background:#a7383c;color:white;padding:11px 16px;font:inherit;font-weight:800;cursor:pointer}
  .danger-button:hover {background:#86282c}
  .account-signout {margin-top:4px}
  @media (max-width:540px) {.account-summary {grid-template-columns:1fr}.account-summary>div:first-child {grid-column:auto}}
}

/* Personal interests and hands-on creative challenges */
@media screen {
  .likes-question {margin-top:14px}
  .likes-question>strong {display:block;font-size:.78rem;color:#304b68}
  .likes-question>small {display:block;font-size:.67rem;color:#73869a;margin:2px 0 7px}
  .likes-grid {display:flex;flex-wrap:wrap;gap:6px}
  .likes-grid label {display:inline-flex;align-items:center;gap:5px;padding:7px 9px;border:1px solid #d4e0e9;border-radius:8px;background:white;cursor:pointer;font-size:.74rem;line-height:1.1}
  .likes-grid label:has(input:checked) {border-color:var(--accent);background:var(--accent-soft);color:var(--accent-deep)}
  .likes-grid input {width:15px!important;height:15px!important;margin:0!important;accent-color:var(--accent);flex:none}
  .child-fields .favorite-thing {display:block;margin-top:14px}
  .category-subheading {display:flex;align-items:baseline;gap:7px;flex-wrap:wrap;font-size:.69rem;font-weight:800;letter-spacing:.1em;color:#78542b;margin:16px 0 8px}
  .category-subheading span {letter-spacing:0;font-weight:600;color:#738499}
  .plus-category-grid label {background:#fffaf2;border-color:#eadabf}
  .plus-category-grid em {display:inline-block;font-style:normal;font-size:.53rem;letter-spacing:.04em;color:#875b1d;background:#ffe6ba;border-radius:4px;padding:2px 4px;white-space:nowrap}
  .creative-workspace {position:relative;width:100%;max-width:720px;margin:0 auto;background:white;border-radius:12px;overflow:hidden}
  .creative-workspace svg {display:block;width:100%;height:auto}
  .creative-workspace .draw-layer {position:absolute;inset:0;width:100%;height:100%;touch-action:none;cursor:crosshair}
  .creative-note {font-size:.86rem;line-height:1.55;color:#435c73;margin:12px 0}
  .map-label,.comic-label {font:bold 14px Arial,sans-serif;fill:#36516b}
  .pixel-number {font:bold 15px Arial,sans-serif;fill:#405b76}
  .creative-tools {display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin:12px 0 4px;font-size:.76rem;font-weight:800;color:#4b6077}
  .creative-tools button.ink {width:28px;height:28px;padding:0;border:2px solid white;border-radius:50%;box-shadow:0 0 0 1px #b2c0cc;background:var(--ink);flex:none}
  .creative-tools button.ink[aria-pressed="true"] {box-shadow:0 0 0 3px #203b59}
  .creative-tools .black {--ink:#263b55}.creative-tools .gold {--ink:#e49b3e}.creative-tools .coral {--ink:#d06572}.creative-tools .blue {--ink:#4789be}.creative-tools .green {--ink:#5c9f73}
  .creative-tools .clear-drawing {border:1px solid #b9cbd8;border-radius:7px;background:white;color:#254661;padding:6px 9px;font-size:.72rem;font-weight:800}
}
@media screen and (max-width:470px) {
  .likes-grid label {font-size:.7rem;padding:7px}
  .plus-category-grid em {display:block;width:max-content;margin-top:3px}
}
@media print {
  .creative-workspace {width:100%;max-width:7in;margin:0 auto}
  .creative-workspace svg {display:block;width:100%;height:auto}
  .creative-workspace .draw-layer,.creative-tools {display:none!important}
  .creative-note {font:10pt/1.4 Arial,sans-serif;color:#222;margin:8pt 0}
  .map-label,.comic-label {font:bold 13px Arial,sans-serif;fill:#222}
  .pixel-number {font:bold 14px Arial,sans-serif;fill:#222}
}

/* Plan comparison, Plus identity, and individual activity controls */
@media screen {
  .header-actions {display:flex;align-items:center;justify-content:flex-end;gap:11px;min-width:0}
  .header-plus-badge {display:inline-flex;align-items:center;gap:5px;flex:none;padding:8px 11px;border:1px solid #f6c671;border-radius:999px;background:#f8d997;color:#20294a;box-shadow:0 0 0 3px rgba(248,217,151,.11);font-size:.79rem;letter-spacing:.09em;font-weight:900;white-space:nowrap}
  .header-plus-badge span {font-size:1.06rem;line-height:.8;color:#8c5a11}
  .header-plus-badge[hidden],.plan-card [hidden] {display:none!important}
  .plan-card {min-height:285px}
  .plan-card h3 {display:flex;align-items:center;gap:7px}
  .plan-ai-icon {display:inline-grid;place-items:center;width:27px;height:27px;flex:none;border-radius:8px;background:#f6c978;color:#533915;font-size:1.12rem;line-height:1}
  .plan-ai-label {display:inline-block;vertical-align:middle;padding:4px 6px;border-radius:5px;background:#f9db9e;color:#4d391e;font:900 .65rem/1 'Nunito Sans',sans-serif;letter-spacing:.08em}
  .plan-highlights {display:flex;flex-wrap:wrap;gap:7px;margin:19px 0 21px}
  .plan-highlights span {display:inline-block;padding:7px 9px;border:1px solid #cddfe9;border-radius:999px;background:#eff7fb;color:#315d77;font-size:.78rem;font-weight:800}
  .plan-card.plus .plan-highlights span {border-color:#526b91;background:#253e66;color:#e6effa}
  .plan-comparison {margin-top:22px;padding:23px;border:1px solid #d7e4ec;border-radius:18px;background:#fff;box-shadow:0 12px 29px rgba(24,56,96,.045)}
  .comparison-heading {display:flex;justify-content:space-between;align-items:baseline;gap:14px;margin:0 0 14px}
  .comparison-heading h3 {margin:0;color:#173556;font:800 1.37rem/1.14 'Nunito',sans-serif}
  .comparison-heading p {margin:0;color:#677d90;font-size:.8rem}
  .plan-table-scroll {max-width:100%;overflow-x:auto;overscroll-behavior-inline:contain;border:1px solid #dbe6ed;border-radius:12px;scrollbar-width:thin}
  .plan-table-scroll:focus-visible {outline:3px solid #e7a832;outline-offset:3px}
  .plan-table {width:100%;min-width:610px;border-collapse:separate;border-spacing:0;table-layout:fixed;color:#294862;font-size:.86rem;line-height:1.42;text-align:left}
  .plan-table th,.plan-table td {padding:13px 17px;border-bottom:1px solid #e7edf1;vertical-align:middle}
  .plan-table tr:last-child th,.plan-table tr:last-child td {border-bottom:0}
  .plan-table thead th {background:#edf5f9;color:#1e4763;font-size:.87rem;font-weight:900}
  .plan-table thead th:last-child {background:#1a355c;color:#fff}
  .plan-table thead th:last-child .plan-ai-icon {width:21px;height:21px;font-size:.9rem;margin-right:4px}
  .plan-table thead th:last-child .plan-ai-label {margin-left:4px}
  .plan-table tbody th {width:33%;color:#24435f;font-weight:800;background:#fff}
  .plan-table td:nth-child(2) {background:#f7fafc}
  .plan-table td:last-child {background:#fffaf0;color:#51412b;font-weight:700}
  .plan-table .ai-feature-row td:last-child {background:#fff1d4;color:#664514}
  .ai-feature-icon {display:inline-grid;place-items:center;margin-right:4px;width:21px;height:21px;border-radius:6px;background:#f1c476;color:#59401a;font-size:.88rem;vertical-align:middle}
  .sheet-actions {display:flex;align-items:center;gap:9px;flex:none}
  .activity-redo {display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;max-width:100%;padding:9px 12px;border:1px solid #b6cfdd;border-radius:9px;background:#f2f9fc;color:#195375;font-size:.81rem;font-weight:800;line-height:1.25;white-space:nowrap}
  .activity-redo:hover {background:#e3f3fa;border-color:#6aa6c4}
  .activity-redo:disabled {opacity:.65;cursor:wait}
  .activity-redo-status {margin:0 0 13px;color:#3e667e;font-size:.83rem;font-weight:700;line-height:1.4}
  .activity-redo-status:empty,.activity-redo-status[hidden] {display:none!important}
  .pack-overview li:has(.activity-redo) {grid-template-columns:32px minmax(0,1fr) auto}
  .pack-overview li .activity-redo {grid-column:3;grid-row:1/3;align-self:center;min-height:40px}
  .pack-overview li .activity-redo-status {grid-column:2/-1;grid-row:3;margin:2px 0 7px}
  .online-head-actions {display:flex;align-items:center;justify-content:flex-end;gap:9px;flex-wrap:wrap}
}
@media screen and (max-width:590px) {
  .header-actions {gap:6px}
  .header-plus-badge {padding:7px 8px;font-size:.68rem;letter-spacing:.04em}
  .header-plus-badge span {font-size:.9rem}
  .header-actions .header-context {max-width:100px}
  .plan-card {min-height:325px}
  .plan-comparison {padding:15px;margin-top:17px}
  .comparison-heading {display:block}
  .comparison-heading h3 {font-size:1.28rem}
  .comparison-heading p {margin-top:5px}
  .plan-table {min-width:510px;font-size:.8rem}
  .plan-table th,.plan-table td {padding:11px 12px}
  .plan-table thead th:first-child,.plan-table tbody th {position:sticky;left:0;z-index:1;width:147px;box-shadow:2px 0 6px rgba(25,48,75,.07)}
  .plan-table thead th:first-child {z-index:2}
  .activity-redo {font-size:.78rem;padding:8px 10px}
  .online-head {flex-wrap:wrap}
  .online-head-actions {width:100%;justify-content:space-between}
}
@media screen and (max-width:420px) {
  .pack-overview li:has(.activity-redo) {grid-template-columns:32px minmax(0,1fr)}
  .pack-overview li .activity-redo {grid-column:2;grid-row:3;justify-self:start;margin:5px 0}
  .pack-overview li .activity-redo-status {grid-column:2;grid-row:4}
}
@media screen and (max-width:430px) {
  .topbar:has(.header-plus-badge:not([hidden])) .header-context {display:none}
}
@media print {
  .activity-redo,.activity-redo-status {display:none!important}
}

/* Per-activity complexity controls */
@media screen {
  .activity-actions {display:flex;align-items:center;gap:8px;flex-wrap:wrap;min-width:0}
  .complexity-control {display:inline-flex;align-items:stretch;max-width:100%;min-height:44px;overflow:hidden;border:1px solid #bdcfdf;border-radius:10px;background:#fff;box-shadow:0 2px 6px rgba(23,57,89,.035)}
  .complexity-step {display:inline-flex;align-items:center;justify-content:center;gap:4px;min-height:44px;min-width:70px;padding:8px 9px;border:0;background:#eff7fb;color:#1a5b7b;font:800 .875rem/1.15 'Nunito Sans',sans-serif;white-space:nowrap;cursor:pointer;touch-action:manipulation}
  .complexity-step:hover:not(:disabled) {background:#dff0f8;color:#104466}
  .complexity-step:focus-visible {position:relative;z-index:1;outline:3px solid #e8ab39;outline-offset:-3px}
  .complexity-step:disabled {background:#f4f6f8;color:#9baab5;cursor:default}
  .complexity-level {display:inline-flex;align-items:center;justify-content:center;min-width:94px;padding:7px 8px;border-inline:1px solid #d5e2e9;color:#23435f;font:800 .875rem/1.15 'Nunito Sans',sans-serif;text-align:center;white-space:nowrap}
  .pack-overview li:has(.activity-actions) {grid-template-columns:32px minmax(0,1fr);align-content:start}
  .pack-overview li .activity-actions {grid-column:2;grid-row:3;margin:7px 0 3px}
  .pack-overview li .activity-actions .activity-redo {grid-column:auto;grid-row:auto;align-self:auto;justify-self:auto;margin:0}
  .pack-overview li .activity-actions .complexity-level {grid-row:auto;color:#23435f;font-size:.875rem}
  .pack-overview li .complexity-step span {font-size:inherit}
  .pack-overview li:has(.activity-actions) .activity-redo-status {grid-column:2;grid-row:4;margin:2px 0 6px}
  .sheet-head {flex-wrap:wrap}
  .sheet-head>div:first-child {flex:1 1 190px;min-width:0}
  .sheet-actions {flex-wrap:wrap;justify-content:flex-end;max-width:100%}
  .sheet-actions .activity-actions {justify-content:flex-end}
  .online-complexity-row {display:flex;align-items:center;justify-content:space-between;gap:11px 20px;flex-wrap:wrap;margin:0 0 12px;padding:11px 14px;border:1px solid #d8e6ed;border-radius:12px;background:#f7fbfd}
  .online-complexity-row .complexity-caption {color:#315672;font-size:.875rem;font-weight:800}
  .online-complexity-row .complexity-level {background:#fff}
  .complexity-status {margin:0 0 12px;color:#376782;font-size:.83rem;font-weight:700;line-height:1.4}
  .complexity-status:empty {display:none}
}
@media screen and (max-width:660px) {
  .sheet-head {flex-wrap:wrap}
  .sheet-head>div:first-child {flex:1 1 100%}
  .sheet-actions {width:100%;justify-content:space-between}
  .sheet-actions .sheet-number {order:-1}
  .sheet-actions .activity-actions {justify-content:flex-start}
}
@media screen and (max-width:400px) {
  .activity-actions {align-items:flex-start}
  .complexity-step {flex-direction:column;gap:0;min-width:54px;padding:5px 4px;font-size:.875rem}
  .complexity-level {min-width:82px;padding:5px 4px;font-size:.875rem;white-space:normal}
  .online-complexity-row {padding:11px}
  .online-complexity-row .complexity-control {width:100%}
  .online-complexity-row .complexity-step {flex:1}
  .online-complexity-row .complexity-level {flex:1.2}
}
@media print {
  .activity-actions,.complexity-control,.online-complexity-row,.complexity-status {display:none!important}
}

/* Interest-led quiz stationery: clean work area, illustrated world above it. */
.background-field {margin:24px 0;border:0;padding:0;min-width:0}
.background-choices {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:14px 0}
.background-choice {position:relative;isolation:isolate;overflow:hidden;min-height:176px;padding:0;border:2px solid #d4dedc;border-radius:16px;background:#f4f8f5;text-align:left;color:#183c3c;cursor:pointer;font:inherit}
.background-choice[aria-pressed="true"] {border-color:#126455;box-shadow:0 0 0 3px #12645525}
.background-choice:focus-visible {outline:3px solid #b86719;outline-offset:3px}
.template-scene {display:block;background-image:url('/quiz-worlds.webp');background-size:300% 200%;background-position:var(--scene-x,0%) var(--scene-y,0%);background-repeat:no-repeat}
[data-world="ocean"] {--scene-x:0%;--scene-y:0%;--quiz-accent:#087f91;--quiz-tint:#e8f6f8}
[data-world="space"] {--scene-x:50%;--scene-y:0%;--quiz-accent:#5952a5;--quiz-tint:#eeedf9}
[data-world="jungle"] {--scene-x:100%;--scene-y:0%;--quiz-accent:#387b45;--quiz-tint:#edf5e9}
[data-world="mystery"] {--scene-x:0%;--scene-y:100%;--quiz-accent:#89652a;--quiz-tint:#faf3e3}
[data-world="pirate"] {--scene-x:50%;--scene-y:100%;--quiz-accent:#9a543c;--quiz-tint:#fff0e8}
[data-world="magic"] {--scene-x:100%;--scene-y:100%;--quiz-accent:#99508c;--quiz-tint:#f8eaf6}
.background-choice .template-scene {height:100px;width:100%}
.template-caption {display:block;padding:12px;background:#fff;position:relative}
.template-caption strong,.template-caption small {display:block}
.template-caption strong {font-size:.87rem;line-height:1.3}
.template-caption small {font-size:.72rem;margin-top:4px;color:#526866}
.template-sample {position:absolute;top:48px;left:14px;background:#fff;padding:9px 15px;border-radius:4px;color:var(--quiz-accent);font-weight:800;box-shadow:0 3px 8px #0002}
.quiz-background {background:var(--quiz-tint,#f0f5f3);border-color:var(--quiz-accent,#cbd8d0)}
.quiz-scene {height:126px;position:relative;overflow:hidden;border-radius:12px;margin-bottom:18px;flex:none}
.quiz-scene .template-scene {position:absolute;left:0;top:50%;width:100%;aspect-ratio:1;transform:translateY(-50%)}
.scene-label {position:absolute;bottom:10px;left:12px;background:#fffffff2;color:#183c3c;padding:7px 12px;border-radius:20px;font-size:.72rem;font-weight:800;letter-spacing:.03em}
.quiz-background .sheet-body,.quiz-background .checkpoint {background:#fff;border-radius:12px;padding:16px;color:#172c37}
.quiz-background .sheet-head {border-color:var(--quiz-accent)}
.bg-trail {background-color:var(--quiz-tint);background-image:repeating-linear-gradient(0deg,transparent,transparent 27px,#5175670c 28px)}
.bg-trail .quiz-scene {height:96px;border-radius:3px;border-bottom:4px solid var(--quiz-accent)}
.bg-studio .quiz-scene {border-radius:70px 18px 70px 18px;border:5px solid #fff;height:135px}
.bg-studio .template-sample {border-radius:22px;transform:rotate(-5deg)}
.bg-postcard .quiz-scene {border:8px solid #fff;box-shadow:0 3px 8px #183c3c20;transform:rotate(-1deg);margin:7px 4px 22px;height:160px}
.bg-postcard .template-sample {border:4px double var(--quiz-accent);transform:rotate(5deg)}
.bg-starlight {background-color:#1d2946;background-image:radial-gradient(#ffffff35 1px,transparent 1px);background-size:21px 21px;color:#fff}
.bg-starlight .quiz-scene .template-scene,.bg-starlight.background-choice>.template-scene {filter:brightness(.7) saturate(1.15)}
.bg-starlight .sheet-kicker,.bg-starlight .sheet-head h3,.bg-starlight .instructions,.bg-starlight .online-instruction,.bg-starlight .sheet-footer {color:#fff}
.bg-starlight .complexity-level {color:#fff}
#online-activity.quiz-background {padding:20px;border-radius:18px}
#online-activity .sheet-body {padding:16px;margin-bottom:18px}
@media(max-width:600px){.background-choice{min-height:158px}.background-choice .template-scene{height:84px}.template-caption{padding:10px}.template-caption strong{font-size:.8rem}#online-activity.quiz-background{padding:12px}.quiz-scene,.bg-postcard .quiz-scene{height:112px}.quiz-background .sheet-body{padding:9px}.template-sample{top:34px}}
@media print {
  .quiz-background,.bg-starlight {background:#fff!important;color:#111!important}
  .quiz-scene,.bg-trail .quiz-scene,.bg-studio .quiz-scene,.bg-postcard .quiz-scene {height:22px!important;border:0!important;border-bottom:1px solid #bbb!important;transform:none;box-shadow:none;border-radius:0;margin:0 0 10px}
  .quiz-scene .template-scene {display:none!important}
  .scene-label {position:static;display:block;padding:0;background:none;color:#555;font-size:8pt}
  .quiz-background .sheet-body,.quiz-background .checkpoint {padding:0;border-radius:0}
  .bg-starlight .sheet-kicker,.bg-starlight .sheet-head h3,.bg-starlight .instructions,.bg-starlight .sheet-footer{color:#111}
}

.catalog-sudoku {width:min(100%,440px);margin:16px auto;border:2px solid #17345d}
.catalog-sudoku span {aspect-ratio:1;min-width:0;font-size:clamp(.85rem,3.4vw,1.4rem)}
.difficulty-spec {font-size:.8rem;font-weight:700;color:#344f60;background:#f0f5f6;padding:9px 12px;border-radius:8px;margin:0 0 14px}
.pattern-list small {display:block;font-size:.75rem;color:#47646e;margin-top:5px}
@media print {.catalog-sudoku {width:4.5in}.catalog-sudoku span {font-size:15pt}.difficulty-spec {background:none;border-bottom:1px solid #ccc;padding:4px 0;font-size:9pt}}

.difficulty-guide {margin:20px 0;padding:14px;border:1px solid #d5dfda;border-radius:12px;background:#fff}.difficulty-guide summary {font-weight:700;cursor:pointer}.difficulty-guide .plan-table-scroll {margin:12px 0}.difficulty-guide .plan-table {font-size:.75rem;min-width:480px}

.home-plan-options {margin:32px 0}.home-plan-grid {display:grid;grid-template-columns:1fr 1fr;gap:18px}.home-plan-grid article {padding:24px;border:1px solid #d5e3dc;background:#fff;border-radius:18px}.home-plan-grid h3 {font-size:1.3rem;margin:8px 0}.home-plan-grid p {line-height:1.6;color:#526a66;margin-bottom:20px}.home-plan-grid .home-plus {background:#eef4f0;border-color:#9bbcae}.home-plan-grid a {display:inline-flex;text-decoration:none}@media(max-width:600px){.home-plan-grid{grid-template-columns:1fr}.home-plan-grid article{padding:19px}}

.email-pack-setting,.email-delivery-summary {margin:18px 0;padding:16px;background:#edf5ef;border:1px solid #cddfd2;border-radius:12px}.email-pack-setting small,.email-delivery-summary p {display:block;font-size:.8rem;line-height:1.5;color:#486453;margin:8px 0}.email-delivery-summary li{margin:6px 0;font-size:.85rem}.child-chip:disabled{opacity:.55;cursor:not-allowed}

/* Plus previews stay discoverable, with a clear locked treatment. */
body[data-membership="plus"] .plus-upsell {display:none!important}
.plus-locked {color:#687174!important;background-color:#edf0f1!important;border-color:#ccd1d3!important}
.background-choice.plus-locked .template-scene,.background-choice.plus-locked .template-sample {filter:grayscale(1);opacity:.55}
.background-choice.plus-locked .template-caption {background:#eef0f1;color:#667174}
.plus-corner {position:absolute;top:8px;right:8px;padding:4px 8px;border-radius:6px;background:#e3e5e7;color:#62686f;font-size:.62rem;font-weight:900;letter-spacing:.06em;z-index:2;line-height:1.2}
.email-pack-setting.plus-locked select {background:#e3e6e7;color:#6b7376}
.locked-feature-link {display:flex;align-items:center;gap:8px;padding:12px;margin:8px 0 20px;border:1px dashed #c2c9cc;border-radius:10px;color:#68747a;background:#f1f3f4;font-size:.8rem;text-decoration:none}
.quiz-ai-upgrade {position:relative;display:flex;align-items:center;gap:8px;min-height:68px;padding:20px 10px 6px;border:1px dashed #c1c6cb;background:#eceff1;color:#68737d;border-radius:12px;text-decoration:none;font-size:.7rem;font-weight:700;flex:none}
.quiz-ai-upgrade .plus-corner {top:5px;right:8px;font-size:.55rem}
.ai-locked-icon {display:flex;align-items:center;font-size:1.4rem;gap:3px;color:#929ba5}
.ai-locked-icon b {font-size:1rem;letter-spacing:-.03em}
.quiz-ai-upgrade:hover,.locked-feature-link:hover {border-color:#778698;background:#e2e7ec}
#online-activity>.quiz-ai-upgrade {width:max-content;margin:0 0 12px auto}
@media screen {
  .sheet.activity-refreshing,#online-activity.activity-refreshing {position:relative;isolation:isolate;overflow-anchor:none}
  .activity-refreshing>* {filter:blur(6px);opacity:.58;pointer-events:none;transition:filter .18s ease,opacity .18s ease}
  .activity-refreshing::after {content:'✦ A little magic in progress…';position:absolute;inset:0;z-index:5;display:grid;place-items:center;padding:24px;background:linear-gradient(115deg,#eaf7ff65,#ffffffb0,#eaf7ff65);background-size:220% 100%;color:#154264;text-align:center;font-weight:800;font-size:clamp(1rem,2vw,1.25rem);text-shadow:0 1px 7px #fff;animation:activity-shimmer 1.8s ease-in-out infinite;pointer-events:none}
  .activity-reveal {animation:activity-reveal .38s ease-out both}
  @keyframes activity-shimmer {from{background-position:100% 0}to{background-position:-100% 0}}
  @keyframes activity-reveal {from{filter:blur(7px);opacity:.68;transform:scale(.995)}to{filter:blur(0);opacity:1;transform:scale(1)}}
  @media (prefers-reduced-motion:reduce) {.activity-refreshing::after,.activity-reveal {animation:none}.activity-refreshing>* {filter:none}}
}
.pack-upgrade-banner {display:grid;grid-template-columns:1.2fr 1fr;position:relative;isolation:isolate;overflow:hidden;border-radius:24px;background:#142d46;color:#fff;margin:28px 0 22px;box-shadow:0 16px 40px #142d461f}
.upgrade-banner-copy {padding:36px;position:relative;z-index:2}
.upgrade-eyebrow {font-size:.66rem;font-weight:800;letter-spacing:.15em;color:#f4c988}
.upgrade-banner-copy h2 {font-family:'Nunito',sans-serif;font-size:clamp(1.8rem,4vw,2.8rem);line-height:1.08;margin:16px 0}
.upgrade-banner-copy h2 span {color:#f8c57d}
.upgrade-banner-copy>p {font-size:.9rem;color:#d0deea;line-height:1.6}
.upgrade-banner-copy ul {padding:0;list-style:none;margin:20px 0;display:grid;gap:11px;font-size:.83rem;color:#dce7ee}
.upgrade-banner-copy li b {color:#fff}.upgrade-banner-copy li small {display:block;color:#a9bdcc;font-size:.7rem;margin-top:4px}
.upgrade-banner-cta {display:inline-flex;justify-content:space-between;align-items:center;gap:30px;padding:14px 22px;background:#f8c57d;border-radius:12px;color:#193248;font-weight:800;text-decoration:none;min-height:48px}
.upgrade-banner-cta:hover {background:#ffd99e}
.upgrade-preview-note {display:block;font-size:.68rem;color:#b1c5d4;margin-top:12px;line-height:1.5}
.upgrade-banner-art {position:relative;min-height:100%;overflow:hidden}
.upgrade-banner-art img {width:100%;height:100%;object-fit:cover;position:absolute;inset:0;opacity:.85}
.upgrade-banner-art:after {content:'';position:absolute;inset:0;background:linear-gradient(90deg,#142d46,transparent 65%)}
.upgrade-orbit {position:absolute;z-index:1;top:50%;left:50%;transform:translate(-50%,-50%) rotate(6deg);width:145px;height:145px;border-radius:35px;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#fffef1ed;color:#193b50;font-size:2rem;box-shadow:0 12px 40px #10283840;line-height:1}
.upgrade-orbit b {font-size:1.7rem;letter-spacing:.08em}.upgrade-orbit small {font-size:.65rem;margin-top:12px}
@media(max-width:640px){.pack-upgrade-banner{grid-template-columns:1fr}.upgrade-banner-copy{padding:26px}.upgrade-banner-art{min-height:150px;order:-1}.upgrade-banner-art:after{background:linear-gradient(0deg,#142d46,transparent 90%)}.upgrade-orbit{width:95px;height:95px;border-radius:23px}.upgrade-orbit b{font-size:1.15rem}.upgrade-orbit small{font-size:.5rem}.quiz-ai-upgrade{min-height:59px}.sheet-actions{align-items:center}}
@media print {.plus-upsell{display:none!important}}

.plans-single {padding:0;overflow:hidden;margin-top:0}.plans-single .plan-table-scroll {border:0;border-radius:17px}.plans-single .plan-table {min-width:650px}.plans-single thead th {vertical-align:top;padding:24px 18px}.plans-single thead h3 {font-size:1.65rem;margin:12px 0 6px}.plans-single .table-price {font-size:.85rem;margin:0 0 16px}.plans-single thead small {display:block;margin-top:12px;font-size:.7rem;line-height:1.5}.plans-single thead a,.plans-single thead button {text-decoration:none;display:inline-flex;justify-content:center;align-items:center;min-height:46px;width:100%;font-size:.82rem}.plans-single #plus-activate,.plans-single #plus-create {background:#f8c57d;color:#17364e;border:0}.plans-single #plus-create[hidden],.plans-single #plus-activate[hidden] {display:none}.plans-single #plus-status {color:#e1edf6;font-size:.72rem;font-weight:500}.plans-single .plan-tag {display:inline-block;font-size:.6rem;letter-spacing:.06em;padding:4px 7px;border-radius:5px;background:#dce8ec;color:#365262}.plans-single #plus-plan-card .plan-tag {background:#ffffff25;color:#fff}.plans-single tfoot td {background:#f5f8fa!important;color:#596e7c!important;font-size:.72rem;font-weight:400!important;line-height:1.6}.plans-single th.current {box-shadow:inset 0 4px #f5b75e}@media(max-width:640px){.plans-single .plan-table{min-width:610px}.plans-single .plan-table th:first-child{width:130px}.plans-single thead th{padding:18px 12px}.plans-single thead h3{font-size:1.45rem}}

.plans-single .plan-table {min-width:780px}.plans-single .plan-table thead th:first-child {position:static;width:auto;box-shadow:none}.plans-single #free-plan-card{background:#edf5f9;color:#1e4763}.plans-single #plus-plan-card{background:#1a355c;color:white}.plans-single #max-plan-card{background:#493563;color:white}.plans-single .plan-table td{width:33.333%;vertical-align:top;font-weight:400}.plans-single td:first-child{background:#f5f8fa}.plans-single td:nth-child(2){background:#eef5fa}.plans-single td:nth-child(3){background:#f6f0fb;color:#463456}.plans-single td small{display:block;margin-top:7px;font-size:.72rem}.plans-single #max-activate,.plans-single #max-create{background:#efd1ff;color:#342346;border:0}.plans-single #max-activate[hidden],.plans-single #max-create[hidden]{display:none}.plans-single #max-plan-card .plan-tag{background:#ffffff25;color:white}.bg-blueprint{background-color:#edf4fc;background-image:linear-gradient(#b8ccde44 1px,transparent 1px),linear-gradient(90deg,#b8ccde44 1px,transparent 1px);background-size:20px 20px}.bg-blueprint .quiz-scene{border:3px double #446d99;border-radius:0}.bg-blueprint .template-sample{border:2px dashed #446d99;border-radius:0}.bg-festival{background-color:#fff5de;background-image:radial-gradient(#e6b05755 2px,transparent 2px);background-size:24px 24px}.bg-festival .quiz-scene{border:5px solid #e7ba5f;border-radius:28px 28px 4px 4px}.bg-festival .template-sample{border-radius:50%;background:#ffe2a2;transform:rotate(-8deg)}

.subscription-card-track{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px;align-items:stretch;padding:8px 5px 24px}
.subscription-card{min-width:0;border:1px solid #d9e3e7;border-radius:22px;background:#fff;overflow:hidden;box-shadow:0 12px 28px #203e5310;display:flex;flex-direction:column}
.subscription-card.current{border:2px solid #d9ad62}
.subscription-card-head{padding:26px 22px;min-height:255px;background:#eef5f8;color:#1c425c}
.subscription-card-head h3{font:800 2rem 'Nunito',sans-serif;margin:16px 0 8px}
.subscription-card-head .table-price{font-size:.9rem;margin:0 0 20px}
.subscription-card-head .plan-tag{display:inline-block;padding:5px 8px;border-radius:6px;background:#dce8ed;font-size:.62rem;font-weight:800;letter-spacing:.06em}
.subscription-card-head a,.subscription-card-head button{width:100%;display:flex;justify-content:center;align-items:center;min-height:48px;text-decoration:none;font-size:.85rem}
.subscription-card-head [hidden]{display:none!important}
.subscription-card-head small{display:block;font-size:.73rem;line-height:1.5;margin-top:12px}
.subscription-card-head .plan-status{font-size:.75rem;line-height:1.5;margin-bottom:0;color:inherit}
.subscription-plus .subscription-card-head{background:#1a355c;color:#fff}
.subscription-max .subscription-card-head{background:#493563;color:#fff}
.subscription-plus .plan-tag,.subscription-max .plan-tag{background:#ffffff24;color:#fff}
.subscription-plus .dark-button{background:#f8c57d;color:#19344d;border:0}
.subscription-max .dark-button{background:#efd1ff;color:#342346;border:0}
.subscription-features{list-style:none;padding:8px 22px 20px;margin:0;display:flex;flex-direction:column;flex:1}
.subscription-features li{padding:17px 0;border-bottom:1px solid #e7edf0;font-size:.85rem;line-height:1.6;color:#42576a}
.subscription-features li:last-child{border-bottom:0}
.subscription-features li small{display:block;margin-top:5px;font-size:.72rem;color:#75818a}
.subscription-card-track:focus-visible{outline:3px solid #d9ad62;outline-offset:4px;border-radius:22px}
@media(max-width:1000px){.subscription-card-track{display:flex;gap:18px;overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-inline:contain;padding:8px 4px 24px;scroll-padding-left:4px}.subscription-card{flex:0 0 min(82vw,340px);scroll-snap-align:start}.plans-scroll-hint{display:block}.subscription-card-head{min-height:245px}}

.home-games{margin:38px 0}.home-games .section-heading{align-items:flex-end}.home-games h2{margin:5px 0 0}.home-games-intro{max-width:720px;color:#5a706e;line-height:1.65;font-size:.9rem;margin:12px 0 22px}.home-game-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:17px}.home-game-card{border:1px solid #dbe5df;border-radius:18px;overflow:hidden;background:#fff;box-shadow:0 7px 18px #193c3c08;display:flex;flex-direction:column;text-decoration:none;color:#23463e;transition:transform .15s,box-shadow .15s}.home-game-card:hover{transform:translateY(-3px);box-shadow:0 12px 25px #193c3c16}.home-game-card:focus-visible{outline:3px solid #c98d35;outline-offset:3px}.home-game-art{height:105px;position:relative;overflow:hidden;background:var(--quiz-tint)}.home-game-art .template-scene{position:absolute;top:50%;transform:translateY(-50%);width:100%;aspect-ratio:1;opacity:.85}.home-game-symbol{position:absolute;left:16px;bottom:12px;min-width:48px;height:46px;padding:0 10px;display:flex;align-items:center;justify-content:center;border-radius:12px;background:#ffffffed;color:var(--quiz-accent);font-weight:900;font-size:1.45rem;box-shadow:0 3px 10px #142b4a16}.home-game-copy{padding:17px;display:flex;flex-direction:column;flex:1}.home-game-copy h3{font-size:1rem;margin:0 0 8px;line-height:1.3}.home-game-copy p{font-size:.78rem;color:#647a74;line-height:1.55;margin:0 0 17px}.home-game-action{margin-top:auto;display:flex;justify-content:space-between;gap:8px;font-size:.75rem;font-weight:800;color:#37665a}.home-game-action b{font-size:1rem}@media(max-width:1100px){.home-game-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@media(max-width:650px){.home-game-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.home-game-copy{padding:13px}.home-game-copy h3{font-size:.92rem}.home-game-art{height:92px}.home-games .section-heading{align-items:flex-start;gap:10px}.home-games .section-heading>a{font-size:.72rem;max-width:95px}.home-games h2{font-size:1.55rem}.home-games-intro{font-size:.82rem}}@media(prefers-reduced-motion:reduce){.home-game-card{transition:none}.home-game-card:hover{transform:none}}

.premium-home[hidden]{display:none!important}
body[data-membership="plus"] .home-screen{display:flex;flex-direction:column}
body[data-membership="plus"] .home-hero{min-height:300px}
body[data-membership="plus"] .home-cards{display:none}
body[data-membership="plus"] .premium-home{order:1}
body[data-membership="plus"] .recent-section{order:2;margin-top:30px}
body[data-membership="plus"] .home-games{order:3}
body[data-membership="plus"] .home-plan-options{order:4}
.premium-home{margin:26px 0 0}
.premium-home .section-heading{align-items:end}
.premium-home .eyebrow{color:#407e9c;margin-bottom:5px}
.home-family-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:13px}
.home-explorer{display:flex;flex-direction:column;align-items:stretch;gap:12px;text-align:left;border:1px solid #d2e2e8;border-radius:16px;padding:18px;background:linear-gradient(145deg,#fff,#f4fafc);box-shadow:0 7px 20px #1738590a;color:#173859;cursor:pointer;font:inherit}
.home-explorer:hover{border-color:#62a9c7;transform:translateY(-2px)}
.home-explorer:focus-visible,.home-premium-actions a:focus-visible{outline:3px solid #bd8429;outline-offset:3px}
.home-explorer-identity{display:flex;flex-direction:column;gap:7px;min-width:0;font-weight:800;font-size:1.1rem}
.home-explorer-identity .child-identity{display:inline-flex;align-items:center;gap:8px}
.home-explorer-identity small{font-size:.88rem;color:#587187;font-weight:600}
.home-explorer-progress{font-size:.93rem;font-weight:800;color:#267b99}
.home-explorer-action{font-size:.9rem;font-weight:800;color:#164d70;margin-top:auto}
.home-family-empty{grid-column:1/-1;border:1px dashed #adcbd8;border-radius:16px;padding:20px;background:#f7fbfd}
.home-family-empty p{margin:0 0 14px;color:#496779;font-size:1rem}
.home-premium-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-top:16px}
.home-premium-actions a{display:flex;flex-direction:column;gap:5px;text-decoration:none;border-radius:14px;background:#eaf5fa;padding:17px;border:1px solid #d4e6ee}
.home-premium-actions a:hover{border-color:#70abc5;background:#e1f1f7}
.home-premium-actions strong{font-size:1rem;color:#173859}
.home-premium-actions small{font-size:.88rem;line-height:1.4;color:#496779}
@media(max-width:650px){body[data-membership="plus"] .home-hero{min-height:315px}.premium-home{margin-top:20px}.premium-home .section-heading{align-items:flex-start}.home-family-list,.home-premium-actions{grid-template-columns:1fr}.home-explorer{padding:16px}}

.activity-redo.icon-action,.complexity-step.icon-action {display:inline-flex;align-items:center;justify-content:center;width:44px;min-width:44px;height:44px;min-height:44px;padding:10px;flex:none;border-radius:12px}.icon-action svg {display:block;width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}.icon-action:focus-visible {outline:3px solid #c8943e;outline-offset:3px}.icon-action:disabled {opacity:.35}.complexity-control {gap:8px}

.print-help{padding:20px;margin:18px 0;background:#edf5f7;border:1px solid #c9dce5;border-radius:14px;color:#254758}.print-help p{font-size:.85rem;line-height:1.6}.print-help a{display:inline-flex;text-decoration:none}.print-help [hidden]{display:none!important}
@media print{
 @page{size:letter;margin:0}
 .account-screen,.print-help,.subscription-card-track,.home-games,.home-plan-options{display:none!important}
 html,body{margin:0!important;padding:0!important;overflow:visible!important}
 .sheet,.cover-sheet,.answer-card,.answer-sheet{box-sizing:border-box!important}
 .answer-sheet{break-after:page!important;page-break-after:always!important}
 .answer-sheet:last-child{break-after:auto!important;page-break-after:auto!important}
}
/* Printable mission surfaces and visible subscription gates. */
.modern-mission{border:1px solid #b9c8da;border-radius:18px;padding:18px;background:#f7faff;color:#172b46}.mission-kicker{font-size:12px;letter-spacing:.08em;font-weight:800;color:#456784;margin-bottom:16px}.mission-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.mission-cards>div{border:1px solid #c5d3df;border-radius:12px;padding:12px;background:white}.mission-cards p{margin:5px 0;overflow-wrap:anywhere}.mission-cards small{color:#53697b;font-weight:700}.command-strip{padding:16px;border:2px solid #708fae;border-radius:12px;font-size:21px;line-height:1.8;overflow-wrap:anywhere}.mission-board{display:grid;grid-template-columns:repeat(var(--cells),1fr);max-width:500px;margin:18px auto;border:1px solid #8da3b9}.mission-board>span{border:1px solid #8da3b9;aspect-ratio:1;display:flex;flex-direction:column;justify-content:center;align-items:center;font-size:22px;background:white}.mission-board small{font-size:12px;color:#526479}.exclusive-tag{display:inline-block;padding:4px 9px;border-radius:6px;background:#e9e1ff;color:#503c82;font-size:12px;font-weight:800}.category-locked{filter:grayscale(1);opacity:.65}.category-unlock{display:none;font-size:14px}.category-locked .category-unlock{display:block}.category-grid label[data-category-tier]{position:relative}.category-grid label small{line-height:1.5}.creative-workspace{margin-top:16px}@media(max-width:480px){.mission-cards{gap:8px}.mission-cards>div{padding:9px}.modern-mission{padding:10px}.mission-board>span{font-size:18px}.command-strip{font-size:18px}}@media print{.modern-mission{background:white;break-inside:avoid}.mission-cards>div{break-inside:avoid}}
.quiz-code{font-family:ui-monospace,monospace;font-size:12px;letter-spacing:.02em;overflow-wrap:anywhere;color:#435b73}.quiz-history-panel{margin:24px 0;padding:20px;border:1px solid #d5dce5;border-radius:16px;background:#f8faff}.quiz-history-list{list-style:none;padding:0;max-height:520px;overflow:auto}.quiz-history-list li{display:flex;justify-content:space-between;gap:12px;padding:14px 0;border-bottom:1px solid #d5dce5}.quiz-history-list code{font-size:12px;overflow-wrap:anywhere}.quiz-history-list a{font-size:14px;flex-shrink:0}.quiz-sync-notice{font-size:14px;margin:8px 0}.quiz-sync-notice:has(#quiz-sync-status:empty){display:none}@media print{.quiz-sync-notice,.quiz-history-panel{display:none!important}}
body[data-membership="free"] .premium-history{display:none!important}
/* Keep answer targets empty on screen, native print and PDF export. */
.answer-card .card-bubble{fill:#fff;stroke:#111;stroke-width:3}
@media print{
 .checkpoint,.choice-grid label,.choice-grid label:has(input:checked),.choice-letter{background:#fff!important;color:#111!important}
 .choice-grid label,.choice-grid label:has(input:checked){border:1pt solid #111;padding:6pt}
 .answer-card .card-bubble{fill:#fff!important;stroke:#111!important;stroke-width:3}
}
.scan-source-options{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:20px 0}.scan-source-card{position:relative;display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center;border:2px dashed #9eafc5;border-radius:18px;padding:22px 12px;background:#f6f9ff;cursor:pointer;color:#233e5e}.scan-source-card>span{font-size:32px;color:#426bb0}.scan-source-card strong{font-size:17px}.scan-source-card small{font-size:14px;line-height:1.4}.scan-source-card input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.scan-source-card:focus-within{outline:3px solid #bc8b25;outline-offset:3px}.scan-legacy{margin:12px 0;color:#516377;font-size:14px}.analyze-scan{width:100%;min-height:50px;margin:12px 0}.scan-feedback{position:relative;overflow:hidden;border-radius:20px;padding:26px 22px;margin:20px 0;background:linear-gradient(120deg,#e8faf1,#edf2ff);border:1px solid #a9ceb9;color:#203e42}.scan-feedback h3{font-size:26px;margin:12px 0}.scan-feedback p{font-size:16px;line-height:1.5}.explorer-reward{display:inline-block;padding:7px 12px;border-radius:30px;background:#ffe397;color:#61460e;font-size:12px;letter-spacing:.06em;font-weight:800}.scan-mark-legend{display:flex;gap:12px;flex-wrap:wrap;font-size:14px;margin:16px 0}.paper-party{position:absolute;right:12px;top:12px;display:flex;gap:10px;color:#bc811e;pointer-events:none}.paper-party span{font-size:22px;animation:paper-spark .8s ease-out both}.paper-party span:nth-child(2n){color:#3671ad;animation-delay:.15s}.scan-feedback small{font-size:13px}.review-grid .quiz-code{display:block;margin-top:5px}@keyframes paper-spark{from{transform:translateY(-25px) rotate(-45deg);opacity:0}to{transform:translateY(0) rotate(12deg);opacity:1}}@media(prefers-reduced-motion:reduce){.paper-party span{animation:none}}@media(max-width:480px){.scan-source-options{gap:10px}.scan-source-card{padding:18px 8px}.scan-source-card strong{font-size:16px}.scan-feedback{padding:22px 16px}.scan-feedback h3{font-size:23px}}@media print{.scan-feedback,.scan-source-options,.analyze-scan{display:none!important}}
.quiz-points{display:inline-flex;align-items:center;font-size:13px;font-weight:800;padding:5px 10px;margin:6px 0;border-radius:20px;color:#6c4a0c;background:#fff0ba}.child-reward-card{display:flex;flex-direction:column;gap:9px;flex:1;min-width:230px;padding:20px;border:1px solid #c6d9e5;border-radius:16px;background:#f6faff}.child-reward-card>strong{font-size:20px}.child-reward-card small{display:block;font-size:13px;color:#547083}.profile-points{display:block;font-size:23px;color:#21526a;margin:8px 0}.reward-badges{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0}.reward-badges span{display:inline-block;padding:7px 10px!important;border-radius:20px;background:#ffe8a7!important;color:#64481e!important;font-size:12px;font-weight:800}.child-reward-card progress{width:100%;height:12px;accent-color:#248173}.points-celebration{border:1px solid #d9bd66;border-radius:16px;background:linear-gradient(120deg,#fff7d2,#edf9ec);padding:20px;margin:18px 0;animation:reward-pop .4s ease-out}.points-celebration>strong{font-size:25px;color:#315c39}.points-celebration p{margin:8px 0;font-size:16px}.points-celebration small{display:block;font-size:13px;line-height:1.5}.result-rewards{margin:14px 0}@keyframes reward-pop{from{transform:scale(.96);opacity:.3}to{transform:scale(1);opacity:1}}@media(prefers-reduced-motion:reduce){.points-celebration{animation:none}}@media print{.quiz-points{background:white!important;color:#111;border:1px solid #777;font-size:9pt;padding:3pt 6pt}}
.rewards-locked{padding:18px;border:1px solid #d8dce2;border-radius:14px;background:#f3f4f6;color:#69717d}.rewards-locked strong{display:block;margin:10px 0;font-size:17px}.rewards-locked p{font-size:14px;line-height:1.5}.rewards-locked .exclusive-tag{filter:grayscale(1)}.plan-rewards-highlight{background:#fff4d2;border-radius:9px;padding:12px!important}.plan-rewards-unavailable{color:#747d89;background:#f3f4f6;border-radius:9px;padding:12px!important}body[data-membership="free"] .quiz-points{filter:grayscale(1);color:#747d89;background:#eceff2}@media print{body[data-membership="free"] .quiz-points{display:none!important}}

/* Picture-led activities for ages four through six. */
.early-builder-note{padding:14px 16px;margin:10px 0 18px;border:1px solid #acd1c1;border-radius:12px;background:#eefaf3;color:#244f43;font-size:.88rem;line-height:1.5}
.early-builder-note[hidden]{display:none}
body[data-age-tier="early"] .difficulty-guide{display:none}
.quiz-early .instructions{font-size:1.08rem;line-height:1.5}
.quiz-early .checkpoint p{font-size:1.05rem}
.quiz-early .choice-grid label{min-height:65px;font-size:1rem;line-height:1.35;border-radius:12px}
.early-mission{max-width:630px;margin:0 auto;color:#233e43}
.early-read-aloud{display:inline-block;margin:0 0 15px;padding:6px 11px;border-radius:99px;background:#e5f4e9;color:#2d6651;font-size:.69rem;font-weight:800;letter-spacing:.08em}
.early-tiles,.early-line{display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap;margin:16px auto}
.early-tile,.early-line>span,.early-grid>span{display:grid;place-items:center;min-width:64px;min-height:62px;padding:8px 10px;border:2px solid #b9d7d1;border-radius:13px;background:#f6fbf8;text-align:center;font-size:1.25rem;font-weight:800;line-height:1.25}
.early-tiles.early-count .early-tile{min-width:56px}
.early-grid{display:grid;grid-template-columns:repeat(var(--early-cols),minmax(0,1fr));gap:8px;max-width:450px;margin:15px auto}
.early-grid>span{min-width:0;min-height:75px;font-size:1.4rem}
.early-row-label{font-size:.72rem;font-weight:800;letter-spacing:.12em;color:#497366;text-align:center;margin:14px 0 0}
.early-row-label+.early-line{margin-top:6px}
.early-draw{border-radius:16px;box-shadow:0 0 0 2px #d1e5dc;max-width:540px}
@media(max-width:480px){.early-tile,.early-line>span{min-width:45px;min-height:52px;padding:7px;font-size:1.04rem}.early-grid>span{min-height:60px;font-size:1.16rem}.quiz-early .choice-grid{grid-template-columns:1fr 1fr}.quiz-early .choice-grid label{min-height:60px;font-size:.92rem}}
@media print{.quiz-early .choice-grid label{min-height:40pt;font-size:11pt}.early-read-aloud{border:1px solid #bbb;background:white;color:#222}.early-tile,.early-line>span,.early-grid>span{background:white;border-color:#777}.early-draw{box-shadow:none}.early-draw svg{max-height:2.65in}}
/* Personal collectible badge shelves */
.family-members .child-reward-card{flex:1 1 100%;min-width:0;background:#fff;padding:22px;border:1px solid #dce6ee;border-radius:24px}
.badge-shelf-title{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:20px;margin:18px 0 12px}.badge-shelf-title small{font-size:14px}
.badge-collection{display:grid;grid-template-columns:repeat(5,minmax(145px,1fr));gap:12px;overflow-x:auto;padding:8px 2px 18px;scroll-snap-type:x proximity;margin:4px 0 14px}
.collectible-badge{position:relative;min-width:0;text-align:center;scroll-snap-align:start;background:linear-gradient(155deg,#fff,var(--badge-wash));border:2px solid var(--badge-accent);border-radius:20px;padding:15px 10px;box-shadow:0 5px 0 color-mix(in srgb,var(--badge-accent) 18%,transparent);color:#20334b}
.collectible-badge[data-style=girl]{border-radius:30px 30px 18px 18px}.collectible-badge[data-style=boy]{border-radius:10px 22px 10px 22px}
.badge-edition{font-size:12px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:var(--badge-accent)}
.badge-art{aspect-ratio:1;display:grid;place-items:center;margin:7px auto;max-width:185px}.badge-art img{display:block;width:100%;height:100%;object-fit:contain;filter:drop-shadow(0 7px 5px #16294120);transition:transform .2s ease}
.collectible-badge.is-earned:hover .badge-art img{transform:translateY(-4px) rotate(-3deg)}
.badge-owner{display:inline-block;max-width:100%;overflow-wrap:anywhere;font-size:14px;font-weight:800;background:var(--badge-accent);color:white;padding:5px 13px;border-radius:7px}
.collectible-badge h4{font-size:16px;line-height:1.3;margin:12px 0 5px!important;color:#1c304b}.collectible-badge p{font-size:13px;line-height:1.4;overflow-wrap:anywhere;margin:0 0 12px;color:#4c6074}.badge-status{font-weight:800;font-size:13px;color:var(--badge-accent);padding:8px 2px;border-top:1px solid #b6c9d755}
.collectible-badge small{font-size:12px!important;line-height:1.5;font-weight:400!important;display:block;color:#506477!important}
.collectible-badge.is-locked:not(.is-preview){border-color:#c8d2dd;box-shadow:none}.collectible-badge.is-locked:not(.is-preview) .badge-art img{filter:grayscale(.85) opacity(.55)}
.collectible-badge[data-age=older] .badge-edition{letter-spacing:.1em}.collectible-badge[data-age=older]{background:linear-gradient(155deg,#fff,#f0f4f8,var(--badge-wash))}
.profile-badge-preview{grid-column:1/-1;min-width:0;margin-top:16px}.badge-preview-heading strong{font-size:18px;display:block}.badge-preview-heading small{font-size:14px;line-height:1.5;display:block;margin:5px 0 10px;color:#536579}
.celebration-badges{grid-template-columns:repeat(auto-fit,minmax(160px,230px));justify-content:center}.celebration-badges .collectible-badge{animation:reward-pop .45s ease-out}
@media(max-width:600px){.badge-collection{grid-template-columns:repeat(5,155px)}.celebration-badges{display:flex;flex-wrap:wrap}.celebration-badges .collectible-badge{width:180px}.family-members .child-reward-card{padding:16px}.badge-shelf-title{display:block}.badge-shelf-title small{margin-top:4px}}
@media(prefers-reduced-motion:reduce){.badge-art img{transition:none}.celebration-badges .collectible-badge{animation:none}}
.badge-collection:focus-visible{outline:3px solid #187fc4;outline-offset:3px;border-radius:12px}
.child-identity{display:inline-flex!important;align-items:center;gap:6px;vertical-align:middle;max-width:100%;padding:0!important;background:transparent!important;color:inherit!important;border-radius:0!important;font-size:inherit!important;font-weight:inherit!important}.child-identity-name{padding:0!important;background:transparent!important;color:inherit!important;font-size:inherit!important;font-weight:inherit!important;overflow-wrap:anywhere}.name-badge{display:inline-flex!important;align-items:center;justify-content:center;flex:0 0 38px;width:38px;height:38px;padding:0!important;margin:0;background:transparent!important;vertical-align:middle}.name-badge img{width:38px;height:38px;object-fit:contain;display:block}.starter-badge{display:grid!important;place-items:center;width:29px;height:29px;padding:0!important;border:1px solid currentColor;border-radius:50%!important;background:transparent!important;color:inherit!important;font-size:21px!important}.quiz-child-identity,.results-child{font-size:18px;font-weight:800;margin:5px 0 14px;color:#234d6d}.badge-owner .name-badge,.badge-owner .name-badge img{width:26px;height:26px;flex-basis:26px}.sheet-kicker .child-identity{text-transform:none}.sheet-footer .name-badge,.sheet-footer .name-badge img{width:25px;height:25px;flex-basis:25px}.pack-card .child-identity{white-space:normal}.badge-owner .starter-badge{width:22px;height:22px;font-size:16px!important}
@media print{.name-badge,.name-badge img{width:30px!important;height:30px!important;flex-basis:30px!important;print-color-adjust:exact;-webkit-print-color-adjust:exact}.child-identity{break-inside:avoid}.sheet-footer .name-badge,.sheet-footer .name-badge img{width:22px!important;height:22px!important;flex-basis:22px!important}}

/* Keep family content shrinkable; only badge shelves scroll horizontally. */
@media screen {
  #family,#family-summary,#profile-editor,.family-members,.child-reward-card>[data-child-rewards]{min-width:0;max-width:100%}
  #family .field-row{grid-template-columns:minmax(0,1.6fr) minmax(0,.7fr)}
  #family .child-field-grid{grid-template-columns:minmax(0,1fr) minmax(0,1.3fr)}
  #family label,#family .profile-badge-preview,#family .quiz-history-list li>div{min-width:0}
  #family input:not([type=checkbox]),#family select{min-width:0;max-width:100%}
  #family .badge-collection{width:100%;min-width:0;max-width:100%;overscroll-behavior-x:contain;scroll-padding-inline:2px}
  #family .child-identity-name{min-width:0;overflow-wrap:anywhere}
  #family .email-pack-setting,#family .email-delivery-summary,#family .quiz-history-list{overflow-wrap:anywhere}
  #family .badge-shelf-title{flex-wrap:wrap}
}
@media screen and (max-width:600px) {
  body[data-page="family"] .app-main .builder{padding:0;border:0;box-shadow:none;background:transparent}
  body[data-page="family"] .family-panel{padding:4px 0 0;margin:0;border:0}
  .family-heading{align-items:center;gap:12px;margin-bottom:18px}
  .family-heading h2{font-size:1.75rem;line-height:1.15}
  .family-heading .eyebrow{font-size:.75rem}
  #family .text-button{min-height:44px;font-size:.875rem}
  #edit-profile{flex-shrink:0;padding:8px 12px;border:1px solid #cbdcd8;border-radius:10px;background:#fff;text-decoration:none}
  #family-greeting{font-size:1rem;line-height:1.5}
  #family .account-email{font-size:.875rem;line-height:1.45}
  .family-members{gap:16px}
  .family-members .child-reward-card{width:100%;padding:16px;border-radius:18px}
  #family .child-reward-card>strong{font-size:1.25rem}
  #family .badge-shelf-title{font-size:1.125rem;line-height:1.4;margin-top:14px}
  #family .badge-collection{grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:min(180px,78%);gap:12px;scroll-snap-type:x proximity}
  #family .profile-points{font-size:1.5rem;margin:4px 0}
  #family .child-reward-card small:not(.collectible-badge small){font-size:.875rem;line-height:1.45}
  #family .quiz-history-panel{padding:16px;margin:20px 0;border-radius:18px}
  #family .quiz-history-panel h3{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-top:0}
  #family .quiz-history-list li{flex-direction:column;gap:8px}
  #family .quiz-history-list a{align-self:flex-start;display:inline-flex;align-items:center;min-height:44px}
  #family .email-delivery-summary{padding:16px}
  #family .email-delivery-summary ul{padding-left:20px}
  #family .email-delivery-summary p,#family .email-delivery-summary li{font-size:.875rem}
  #family .family-continue{width:100%;justify-content:center}
  #profile-editor .field-row{grid-template-columns:minmax(0,1fr) 100px;gap:12px}
  #family .children-fields{gap:18px}
  #family .child-fields{padding:16px 14px;border-radius:18px;background:#fff}
  #family .child-fields legend{font-size:.875rem}
  #family .child-fields input:not([type=checkbox]),#family .child-fields select,#parent-name,#child-count,#history-child{height:48px;font-size:16px}
  #family .likes-question>strong{font-size:.875rem;line-height:1.4}
  #family .likes-question>small{font-size:.8125rem}
  #family .likes-grid{gap:8px}
  #family .likes-grid label{min-height:44px;font-size:.875rem;padding:9px 10px}
  #family .email-pack-setting{padding:12px}
  #family .email-pack-setting small,#family .profile-help{font-size:.875rem;line-height:1.5}
  #family .profile-actions{flex-direction:column;align-items:stretch;gap:8px}
  #family .save-profile{min-height:48px;font-size:1rem;border-radius:12px}
}
@media screen and (max-width:360px) {
  #profile-editor .field-row,#family .child-field-grid{grid-template-columns:minmax(0,1fr)}
}

/* One child at a time in the family overview and editor. */
.family-child-tabs{display:flex;gap:10px;overflow-x:auto;max-width:100%;padding:4px 2px 12px;margin:18px 0 4px;scroll-snap-type:x proximity;overscroll-behavior-x:contain}
.family-child-tabs button{flex:0 0 auto;max-width:220px;min-width:115px;min-height:68px;padding:10px 14px;border:1px solid #cadcd6;border-radius:14px;background:#fff;color:#284c43;text-align:left;scroll-snap-align:start;font:inherit;font-weight:800}
.family-child-tabs button[aria-pressed="true"]{background:#e5f3ec;border:2px solid #26765e;padding:9px 13px;box-shadow:0 2px 8px #26765e15}
.family-child-tabs button small{display:block;margin:3px 0 0 44px;font-size:.8125rem;font-weight:600;color:#57756c}
.family-child-tabs .child-identity-name{min-width:0;overflow-wrap:anywhere}
#family .child-fields[hidden]{display:none!important}
.family-detail,.profile-badge-details{margin:16px 0;padding:16px;border:1px solid #d5e1db;border-radius:14px;background:#fff;min-width:0}
.family-detail>summary,.profile-badge-details>summary{cursor:pointer;font-size:1rem;font-weight:800;line-height:1.5;color:#284b40;min-height:28px}
.family-detail>summary .exclusive-tag{margin-left:6px}
.family-detail[open]>summary,.profile-badge-details[open]>summary{margin-bottom:12px}
#family .family-detail:not([open]){margin:12px 0}
.email-preferences-detail .email-delivery-summary{margin:0;border:0;padding:0;background:transparent}
.profile-badge-details{padding:12px;margin-bottom:0}
@media(max-width:600px){.family-child-tabs{margin-top:16px}.family-child-tabs button{min-width:110px;max-width:190px}.family-detail>summary,.profile-badge-details>summary{min-height:32px}.family-detail .exclusive-tag{font-size:.75rem}}

/* Compact pack options retain a visible summary of every selection. */
@media screen {
  #pack-form>.eyebrow{display:none}
  #pack-form .builder-option{border:1px solid #ccdcd5;border-radius:13px;margin:10px 0;background:#fff;min-width:0}
  #pack-form .builder-option>summary{position:relative;list-style:none;cursor:pointer;padding:13px 40px 13px 14px;min-height:64px;line-height:1.4}
  #pack-form .builder-option>summary::-webkit-details-marker{display:none}
  #pack-form .builder-option>summary:after{content:'+';position:absolute;right:16px;top:18px;font-size:22px;color:#326750}
  #pack-form .builder-option[open]>summary:after{content:'−'}
  #pack-form .builder-option>summary>span{display:block;font-size:.875rem;color:#546d62}
  #pack-form .builder-option>summary>strong{display:block;font-size:1rem;color:#203e33;overflow-wrap:anywhere}
  #pack-form .builder-option[open]>summary{border-bottom:1px solid #e0e9e3}
  #pack-form .builder-option-content{padding:12px;min-width:0}
  #pack-form .builder-option fieldset{margin:0;padding:0;min-inline-size:0;border:0}
  #pack-form .builder-option fieldset>legend{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
  #pack-form .theme-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:0}
  #pack-form .world-card{min-height:88px;padding:10px 8px;border-radius:12px}
  #pack-form .world-card-copy strong{font-size:.875rem}
  #pack-form .world-card-copy small{display:none}
  #pack-form .world-card-check{width:20px;height:20px;top:6px;right:6px;font-size:12px}
  #pack-form .background-choices{gap:8px;margin:10px 0}
  #pack-form .background-choice{min-height:0;border-radius:10px}
  #pack-form .background-choice .template-scene{height:62px}
  #pack-form .template-caption{padding:9px}
  #pack-form .template-caption strong{font-size:.875rem}
  #pack-form .template-sample{top:24px;padding:5px 8px;font-size:.75rem}
  #pack-form .category-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
  #pack-form .category-grid label{grid-template-columns:24px minmax(0,1fr);min-height:52px;padding:9px;gap:6px}
  #pack-form .category-grid label:has(input:checked){padding:8px}
  #pack-form .category-grid label>span{grid-row:1;width:24px;height:24px;font-size:1rem}
  #pack-form .category-grid strong{font-size:.875rem;line-height:1.3}
  #pack-form .category-grid small{display:none}
  #pack-form .category-unlock{grid-column:1/-1;font-size:.8125rem}
  #pack-form .builder-quick-options{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;margin-top:16px}
  #pack-form .builder-quick-options label{min-width:0;font-size:.875rem}
  #pack-form .builder-quick-options select{width:100%;min-width:0;font-size:1rem;padding-left:9px;padding-right:5px}
  #pack-form .early-builder-note{font-size:.875rem;padding:10px 12px;margin:12px 0}
  #pack-form .primary-button{margin-top:14px;min-height:48px}
  #pack-form .difficulty-guide{margin:12px 0 0;padding:10px;font-size:.875rem}
  body[data-page="build"] .builder-intro h1{font-size:clamp(1.7rem,4vw,2.4rem);margin-bottom:12px}
  body[data-page="build"] .builder-intro>p{display:none}
}
@media screen and (min-width:800px){#pack-form .theme-grid{grid-template-columns:repeat(6,minmax(0,1fr))}#pack-form .category-grid{grid-template-columns:repeat(3,minmax(0,1fr))}#pack-form .background-choices{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* Illustrated worlds and personal adventure stationery. */
.theme-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.theme-tile.world-card{isolation:isolate;overflow:hidden;min-height:156px;align-items:stretch;justify-content:flex-end;padding:14px 12px;border:2px solid transparent;border-radius:18px;background:#15304c;color:#fff;box-shadow:0 5px 14px #16344c1a;text-align:left;transition:transform .18s,box-shadow .18s}
.world-card-art{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:65% center;z-index:-2;transition:transform .3s}
.world-card:after{content:'';position:absolute;inset:0;z-index:-1;background:linear-gradient(180deg,#071c3200 20%,#071c3270 53%,#071c32f2)}
.world-card-copy{display:flex;flex-direction:column;gap:5px}
.world-card-copy strong{font-size:1.12rem;font-weight:800;line-height:1.15;color:#fff}
.world-card-copy small{font-size:.875rem;line-height:1.25;color:#e9f4ff;font-weight:500}
.world-card-check{position:absolute;top:9px;right:9px;display:none;background:#ffcf69;color:#17324e;border-radius:50%;width:26px;height:26px;place-items:center;font-weight:900}
.theme-tile.world-card:has(input:checked){border-color:#efb645;background:#15304c;color:#fff;box-shadow:0 0 0 3px #efb64538,0 8px 20px #17324e22}
.world-card:has(input:checked) .world-card-check{display:grid}
.world-card:hover .world-card-art{transform:scale(1.06)}
.world-card input{z-index:3;width:100%;height:100%;margin:0}
.home-hero>div{padding-bottom:82px}
.hero-scene-controls{position:absolute;z-index:3;right:18px;bottom:17px;left:auto;display:flex;align-items:center;gap:8px;padding:5px;border-radius:12px;background:#102440db;color:#fff;backdrop-filter:blur(10px);max-width:calc(100% - 36px)}
.hero-scene-controls button{border:0;border-radius:8px;min-width:38px;min-height:38px;background:#ffffff20;color:#fff;font-weight:800;font-size:1.1rem;padding:4px 10px}
.hero-scene-controls button:last-child{font-size:.875rem}
.hero-scene-controls button:hover{background:#ffffff38}
#hero-scene-label{font-size:.875rem;font-weight:700;text-align:center;line-height:1.3}
.home-hero #home-scene-image{object-position:65% center}
.personalized-scene img{display:block;width:100%;height:100%;object-fit:cover;object-position:65% 50%}
.quiz-background.child-tone-sky{--quiz-accent:#187fa6;--quiz-tint:#e8f5fc}
.quiz-background.child-tone-coral{--quiz-accent:#b94869;--quiz-tint:#fff0f3}
.quiz-background.child-tone-violet{--quiz-accent:#7650ac;--quiz-tint:#f3eefc}
.quiz-background.child-tone-forest{--quiz-accent:#257653;--quiz-tint:#eaf7ef}
.quiz-background.child-tone-gold{--quiz-accent:#936514;--quiz-tint:#fff7e0}
.quiz-background:not(.bg-starlight){background-color:var(--quiz-tint)}
.quiz-variation-1:not(.bg-starlight){background-image:radial-gradient(color-mix(in srgb,var(--quiz-accent) 13%,transparent) 1px,transparent 1px);background-size:18px 18px}
.quiz-variation-2:not(.bg-starlight){background-image:linear-gradient(135deg,color-mix(in srgb,var(--quiz-accent) 9%,transparent),transparent 60%)}
.quiz-age-younger .personalized-scene{border-radius:24px 24px 10px 10px;height:132px}
.quiz-age-older .personalized-scene{border-radius:8px;height:106px;border-bottom:3px solid var(--quiz-accent)}
.personalized-scene .scene-label{font-size:.875rem;max-width:calc(100% - 24px)}
.bg-starlight .personalized-scene img{filter:brightness(.82) saturate(1.1)}
@media(max-width:600px){.theme-tile.world-card{min-height:160px}.hero-scene-controls{right:12px;left:12px;bottom:12px;justify-content:space-between;max-width:none;gap:4px}#hero-scene-label{font-size:.875rem}.home-hero>div{padding-bottom:85px}.quiz-age-younger .personalized-scene,.quiz-age-older .personalized-scene{height:105px}}
@media(prefers-reduced-motion:reduce){.world-card-art,.theme-tile.world-card{transition:none}}
@media print{.personalized-scene img{display:none!important}.quiz-age-younger .personalized-scene,.quiz-age-older .personalized-scene{height:22px!important;border-radius:0}.hero-scene-controls{display:none!important}}
[data-world="ocean"]{--world-image:url('/scenes/ocean.webp')}
[data-world="space"]{--world-image:url('/scenes/space.webp')}
[data-world="jungle"]{--world-image:url('/scenes/jungle.webp')}
[data-world="mystery"]{--world-image:url('/scenes/mystery.webp')}
[data-world="pirate"]{--world-image:url('/scenes/pirate.webp')}
[data-world="magic"]{--world-image:url('/scenes/magic.webp')}
.template-scene{background-image:var(--world-image,url('/quiz-worlds.webp'));background-size:cover;background-position:65% center}
.max-visual-game{border:1px solid #b8afda;border-radius:18px;background:linear-gradient(145deg,#f8f7ff,#eef6fc);padding:14px;margin:10px 0;color:#17314c}
.max-visual-heading{display:flex;justify-content:space-between;gap:10px;letter-spacing:.07em;font-size:.875rem;font-weight:800;color:#59418a;padding:0 2px 10px;border-bottom:1px solid #d8d0eb}
.max-puzzle-diagram{display:block;width:100%;height:auto;max-height:470px;margin:12px auto 0;background:white;border-radius:12px}
.category-grid .max-visual-category{border-color:#bdb2dc;background:linear-gradient(145deg,#f9f6ff,#eef5fc)}
.home-game-art>img{width:100%;height:100%;object-fit:cover}
.home-game-card.max-visual-category{border-color:#c8b5e5;box-shadow:0 7px 20px #5c368b12}
@media print{.max-visual-game{padding:5px;border:1px solid #bbb;background:white}.max-puzzle-diagram{max-height:4.6in}.max-visual-heading{font-size:9pt}}

/* Twenty cover compositions per selected quiz background: five layouts × four color treatments. */
.cover-sheet.cover-design{--cover-color:var(--quiz-accent,#2185ae);--cover-paper:#fff;--cover-ink:#193453;display:flex;flex-direction:column;min-height:610px;background:var(--cover-paper);color:var(--cover-ink);isolation:isolate}
.cover-design .cover-art{height:390px;min-height:0;flex:none;background:var(--cover-color)}
.cover-design .cover-art img{object-fit:cover;object-position:var(--cover-crop,center);filter:var(--cover-filter,none)}
.cover-design .cover-art::before{content:'';position:absolute;inset:0;z-index:1;background:var(--cover-overlay,transparent);mix-blend-mode:soft-light;pointer-events:none}
.cover-design .cover-art::after{z-index:1;background:linear-gradient(0deg,#081d37a8,transparent 55%)}
.cover-design .cover-art .cover-kicker{z-index:2;left:30px;bottom:27px;right:auto;top:auto;color:#fff;font-size:.78rem;letter-spacing:.15em;line-height:1.4}
.cover-design .cover-art .cover-edition{z-index:2;left:auto;right:23px;top:22px;bottom:auto;padding:7px 10px;border:1px solid #ffffffb8;border-radius:99px;background:#0d2d4b8c;color:#fff;font-size:.72rem;letter-spacing:.08em}
.cover-design .cover-details{flex:1;border-top:7px solid var(--cover-color);background:var(--cover-paper);color:var(--cover-ink);padding:30px 34px 35px;position:relative;z-index:2}
.cover-design .cover-details p{color:var(--cover-color)}
.cover-design .cover-details h3{color:var(--cover-ink);font-size:clamp(2.4rem,4vw,4rem);overflow-wrap:anywhere}
.cover-design .cover-rule{background:color-mix(in srgb,var(--cover-color) 30%,#dce6ec)}
.cover-design .cover-details strong{color:var(--cover-ink)}
.cover-design .cover-details small{color:color-mix(in srgb,var(--cover-ink) 66%,#fff)}
.cover-design.cover-treatment-0{--cover-crop:48% 45%;--cover-filter:saturate(1.1);--cover-overlay:linear-gradient(125deg,#ffcf7255,transparent 50%,#0a477466)}
.cover-design.cover-treatment-1{--cover-crop:78% 50%;--cover-filter:brightness(.72) saturate(1.18);--cover-overlay:linear-gradient(145deg,#104a86aa,transparent 55%,#81198466)}
.cover-design.cover-treatment-2{--cover-crop:26% 42%;--cover-filter:contrast(.9) saturate(.74) brightness(1.12);--cover-overlay:radial-gradient(circle at 22% 24%,#fff1b6b0,transparent 52%)}
.cover-design.cover-treatment-3{--cover-crop:68% 65%;--cover-filter:contrast(1.19) saturate(1.32);--cover-overlay:linear-gradient(45deg,#183ca466 0 25%,transparent 25% 70%,#e7a43b77 70%)}
.cover-design.cover-layout-1{display:grid;grid-template-columns:48% 52%;min-height:610px}
.cover-design.cover-layout-1 .cover-art{grid-column:2;grid-row:1;height:100%}
.cover-design.cover-layout-1 .cover-details{grid-column:1;grid-row:1;border-top:0;border-left:8px solid var(--cover-color);padding:clamp(24px,4vw,40px);display:flex;flex-direction:column;justify-content:center}
.cover-design.cover-layout-1 .cover-details h3{font-size:clamp(2rem,3.7vw,3.7rem)}
.cover-design.cover-layout-1 .cover-art .cover-kicker{bottom:25px;left:20px;right:15px}
.cover-design.cover-layout-2{display:block;position:relative;min-height:610px}
.cover-design.cover-layout-2 .cover-art{height:610px}
.cover-design.cover-layout-2 .cover-art::after{background:linear-gradient(0deg,#0b2236fa 0%,#0b2236b0 34%,transparent 78%)}
.cover-design.cover-layout-2 .cover-details{position:absolute;bottom:0;left:0;right:0;border:0;background:transparent;padding:32px 42px 44px;color:#fff}
.cover-design.cover-layout-2 .cover-details p,.cover-design.cover-layout-2 .cover-details h3,.cover-design.cover-layout-2 .cover-details strong,.cover-design.cover-layout-2 .cover-details small{color:#fff}
.cover-design.cover-layout-2 .cover-details h3{font-size:clamp(3rem,6vw,5.4rem);max-width:650px}
.cover-design.cover-layout-2 .cover-art .cover-kicker{top:28px;bottom:auto}
.cover-design.cover-layout-2 .cover-rule{background:#ffffff8c}
.cover-design.cover-layout-3{padding:22px;background:var(--cover-paper);min-height:610px}
.cover-design.cover-layout-3 .cover-art{height:340px;border:9px solid #fff;border-radius:16px;box-shadow:0 8px 24px #102c6330;transform:rotate(-1.4deg)}
.cover-design.cover-layout-3 .cover-details{border-top:0;padding:35px 20px 20px;text-align:center}
.cover-design.cover-layout-3 .cover-details h3{margin-bottom:18px}
.cover-design.cover-layout-3 .cover-art .cover-kicker{left:23px}
.cover-design.cover-layout-4{min-height:610px;background:var(--cover-color)}
.cover-design.cover-layout-4 .cover-art{height:400px;clip-path:polygon(0 0,100% 0,100% 90%,0 100%)}
.cover-design.cover-layout-4 .cover-details{border:0;margin:-18px 24px 24px;padding:28px 32px;border-radius:17px;box-shadow:0 10px 24px #102b4b35}
.cover-design.bg-trail{--cover-paper:#f7f4e9;--cover-ink:#233f51}
.cover-design.bg-trail .cover-details{background-image:repeating-linear-gradient(0deg,transparent 0 28px,#49828716 29px)}
.cover-design.bg-studio{--cover-paper:#f5eafb;--cover-ink:#332958;border-radius:28px}
.cover-design.bg-studio .cover-art{border-radius:36px 0 36px 0}
.cover-design.bg-studio .cover-details{border-top-width:11px}
.cover-design.bg-postcard{--cover-paper:#fbf8f0;--cover-ink:#344350}
.cover-design.bg-postcard .cover-art{border:12px solid #fff;box-shadow:0 3px 15px #183c3c27}
.cover-design.bg-postcard .cover-details{border-top:5px double var(--cover-color)}
.cover-design.bg-starlight{--cover-paper:#182641;--cover-ink:#fff;--cover-color:#e7bc72}
.cover-design.bg-starlight .cover-details{background-image:radial-gradient(#ffffff1e 1px,transparent 1px);background-size:19px 19px}
.cover-design.bg-starlight .cover-details p,.cover-design.bg-starlight .cover-details small{color:#f1d6a7}
.cover-design.bg-blueprint{--cover-paper:#142c49;--cover-ink:#ecf9ff;--cover-color:#69d4e2}
.cover-design.bg-blueprint .cover-details{background-image:linear-gradient(#a8e8fa20 1px,transparent 1px),linear-gradient(90deg,#a8e8fa20 1px,transparent 1px);background-size:24px 24px}
.cover-design.bg-blueprint .cover-details h3{text-transform:uppercase;letter-spacing:-.035em}
.cover-design.bg-blueprint .cover-details p,.cover-design.bg-blueprint .cover-details small{color:#b6e5ec}
.cover-design.bg-festival{--cover-paper:#fff1f8;--cover-ink:#50264f;--cover-color:#c03a83}
.cover-design.bg-festival .cover-details{background-image:linear-gradient(135deg,#ffca6f29,transparent 45%,#a362d82b),repeating-linear-gradient(115deg,transparent 0 64px,#d05cbd13 65px 67px)}
.cover-design.bg-festival .cover-art{border-bottom:8px solid #f5af56}
@media screen and (max-width:760px){.cover-sheet.cover-design{min-height:0}.cover-design .cover-art{height:300px}.cover-design.cover-layout-1{min-height:430px}.cover-design.cover-layout-2{min-height:480px}.cover-design.cover-layout-2 .cover-art{height:480px}.cover-design.cover-layout-3 .cover-art{height:280px}.cover-design.cover-layout-4 .cover-art{height:300px}}
@media screen and (max-width:520px){.cover-design.cover-layout-1{display:flex;flex-direction:column}.cover-design.cover-layout-1 .cover-art{order:0;height:240px}.cover-design.cover-layout-1 .cover-details{order:1;border-left:0;border-top:7px solid var(--cover-color)}.cover-design.cover-layout-2 .cover-details{padding:24px}.cover-design.cover-layout-2 .cover-details h3{font-size:2.5rem}.cover-design.cover-layout-4 .cover-details{margin:-18px 12px 12px;padding:23px}.cover-design .cover-art .cover-kicker{left:17px;bottom:15px;font-size:.65rem}.cover-design .cover-art .cover-edition{right:13px;top:13px}.cover-design .cover-details{padding:23px}.cover-design .cover-details h3{font-size:2.45rem}}
@media print{.cover-sheet.cover-design{width:8.5in;height:11in;min-height:0;padding:.5in;background:var(--cover-paper)!important;color:var(--cover-ink)!important;print-color-adjust:exact;-webkit-print-color-adjust:exact;overflow:hidden}.cover-design .cover-art{height:6in}.cover-design.cover-layout-1{grid-template-columns:48% 52%}.cover-design.cover-layout-1 .cover-art{height:100%}.cover-design.cover-layout-2 .cover-art{height:100%}.cover-design.cover-layout-2 .cover-details{padding:.45in}.cover-design.cover-layout-2 .cover-details h3{font-size:42pt}.cover-design.cover-layout-3 .cover-art{height:5.8in}.cover-design.cover-layout-4 .cover-art{height:6in}.cover-design .cover-art .cover-kicker{left:.3in;bottom:.28in;font:bold 11pt Arial,sans-serif}.cover-design .cover-art .cover-edition{left:auto;right:.2in;top:.2in;bottom:auto;font:bold 10pt Arial,sans-serif}.cover-design .cover-details{padding:.32in}.cover-design .cover-details p{color:var(--cover-color)}.cover-design .cover-details h3{color:var(--cover-ink);font:bold 36pt/1 Arial,sans-serif}.cover-design .cover-details strong{color:var(--cover-ink)}.cover-design.cover-layout-2 .cover-details p,.cover-design.cover-layout-2 .cover-details h3,.cover-design.cover-layout-2 .cover-details strong,.cover-design.cover-layout-2 .cover-details small{color:#fff}}

.scan-canvas-wrap[aria-busy="true"] canvas{filter:blur(3px);opacity:.7;transition:filter .2s,opacity .2s}

/* Keep each child's name and full-color emblem together. */
.builder-name-input{display:flex;align-items:center;gap:8px;margin-top:8px;min-width:0}
.builder-name-input #builder-child-badge{display:flex;align-items:center;flex:none}
.builder-name-input #child-name{margin-top:0;min-width:0;flex:1}
.child-identity{min-width:0;line-height:1.2;gap:10px;flex-wrap:nowrap}
.child-identity-name{min-width:0;letter-spacing:normal}
.name-badge img{filter:none!important;opacity:1!important;print-color-adjust:exact;-webkit-print-color-adjust:exact}
.sheet-head>div:first-child{min-width:0}
.sheet-kicker .child-identity{font-size:1.65rem!important;font-weight:800!important;letter-spacing:normal}
.sheet-kicker .activity-position{display:block;font-size:.75rem;letter-spacing:.08em;margin-top:8px}
.sheet-kicker .name-badge,.sheet-kicker .name-badge img,.quiz-child-identity .name-badge,.quiz-child-identity .name-badge img{width:54px;height:54px;flex-basis:54px}
.quiz-child-identity{font-size:1.75rem;line-height:1.2}
.cover-personalization{margin-bottom:18px}
.cover-design .cover-personalization p{margin:0 0 9px;font-size:.8rem;letter-spacing:.08em}
.cover-child-name{font-size:clamp(2rem,4vw,3rem);font-weight:800;line-height:1.15;text-transform:none;color:inherit}
.cover-child-name .name-badge,.cover-child-name .name-badge img{width:76px;height:76px;flex-basis:76px}
.cover-layout-3 .cover-child-name .child-identity{justify-content:center}
.sheet-footer{align-items:center;gap:12px;flex-wrap:wrap}
@media(max-width:520px){.sheet-kicker .child-identity{font-size:1.4rem!important}.cover-child-name .name-badge,.cover-child-name .name-badge img{width:60px;height:60px;flex-basis:60px}.quiz-child-identity{font-size:1.5rem}}
@media print{
 .sheet-kicker .child-identity{font-size:20pt!important}
 .sheet-kicker .name-badge,.sheet-kicker .name-badge img{width:44pt!important;height:44pt!important;flex-basis:44pt!important}
 .cover-child-name{font-size:28pt}
 .cover-child-name .name-badge,.cover-child-name .name-badge img{width:54pt!important;height:54pt!important;flex-basis:54pt!important}
 .cover-design .cover-personalization p{font-size:10pt;margin-bottom:6pt}
 .cover-personalization{margin-bottom:12pt}
}

/* A playful six-stop adventure guide, using the existing collectible artwork. */
.home-how-to{margin:28px 0 36px;padding:28px;border:1px solid #c5dbed;border-radius:26px;background:linear-gradient(125deg,#edf7ff,#f4efff 62%,#fff5d7);color:#183d59}
.how-adventure-heading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:22px}
.how-adventure-heading .eyebrow{font-size:.75rem;color:#6345a3;margin:0 0 8px}
.how-adventure-heading h2{font-size:clamp(1.7rem,3vw,2.4rem);line-height:1.15;margin:0;color:#183d59}
.how-adventure-heading p:last-child{font-size:1rem;line-height:1.5;margin:10px 0 0;color:#496173}
.how-adventure-heading>img{width:112px;height:112px;object-fit:contain;flex:none;transform:rotate(7deg);filter:drop-shadow(0 7px 8px #503d7a26)}
.home-how-steps{counter-reset:adventure-step;list-style:none;padding:0;margin:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.home-how-steps li{--step-color:#226b9b;--step-wash:#e9f6ff;counter-increment:adventure-step;position:relative;padding:20px;border:1px solid color-mix(in srgb,var(--step-color) 25%,white);border-bottom:4px solid var(--step-color);border-radius:18px;background:linear-gradient(155deg,#fff 36%,var(--step-wash));box-shadow:0 4px 0 #203d5908;transition:transform .2s,box-shadow .2s}
.home-how-steps li:nth-child(2){--step-color:#7151b5;--step-wash:#f0eaff}
.home-how-steps li:nth-child(3){--step-color:#af651d;--step-wash:#fff1d5}
.home-how-steps li:nth-child(4){--step-color:#21806a;--step-wash:#e1f8ed}
.home-how-steps li:nth-child(5){--step-color:#ba456e;--step-wash:#ffe9f0}
.home-how-steps li:nth-child(6){--step-color:#95620d;--step-wash:#fff0b5}
.home-how-steps li::before{content:'0' counter(adventure-step);position:absolute;top:18px;right:18px;font-size:.875rem;line-height:1;font-weight:800;color:var(--step-color);padding:8px;border-radius:8px;background:var(--step-wash)}
.how-step-icon{display:flex;align-items:center;justify-content:center;width:64px;height:64px;margin-bottom:12px;border-radius:18px;background:var(--step-wash);font-size:2.25rem;line-height:1}
.how-step-icon img{display:block;width:64px;height:64px;object-fit:contain}
.home-how-steps strong{display:block;font-size:1.125rem;line-height:1.35;color:#19354d}
.home-how-steps p{margin:8px 0 0;font-size:1rem;line-height:1.5;color:#496173}
.home-how-note{font-size:.875rem;line-height:1.5;margin:20px 0 0;color:#59607a;text-align:center}
@media(hover:hover){.home-how-steps li:hover{transform:translateY(-4px);box-shadow:0 9px 18px #203d5910}}
@media(max-width:900px){.home-how-steps{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:560px){.home-how-to{padding:20px 14px}.how-adventure-heading{gap:8px}.how-adventure-heading>img{width:76px;height:76px}.how-adventure-heading .eyebrow{font-size:.75rem;letter-spacing:.05em}.home-how-steps{grid-template-columns:minmax(0,1fr);gap:12px}.home-how-steps li{display:grid;grid-template-columns:48px minmax(0,1fr);gap:12px;padding:16px}.home-how-steps li::before{top:12px;right:12px;font-size:.75rem;padding:5px}.how-step-icon,.how-step-icon img{width:48px;height:48px}.how-step-icon{font-size:1.8rem;border-radius:13px;margin:0}.home-how-steps strong{padding-right:28px}.home-how-steps p{margin-top:6px}}
@media(prefers-reduced-motion:reduce){.home-how-steps li{transition:none}.home-how-steps li:hover{transform:none}}

/* Compact, playful shortcuts for printing and scanning. */
.home-quick-actions{gap:12px;margin-top:16px;margin-bottom:20px}
.home-quick-actions a{--quick-accent:#286c9f;--quick-wash:#e6f5ff;display:flex;flex-direction:row;align-items:center;gap:12px;padding:14px 16px;border:1px solid color-mix(in srgb,var(--quick-accent) 30%,white);border-bottom:3px solid var(--quick-accent);border-radius:16px;background:linear-gradient(115deg,#fff,var(--quick-wash));text-decoration:none;box-shadow:0 4px 12px #203d5908;min-width:0;transition:transform .18s,box-shadow .18s}
.home-quick-actions a.quick-scan{--quick-accent:#7450ac;--quick-wash:#f1eaff}
.home-quick-actions a.quick-packs{--quick-accent:#9a651d;--quick-wash:#fff1d4}
.home-quick-actions .quick-action-icon{display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;border-radius:13px;background:var(--quick-wash);font-size:1.8rem;letter-spacing:0;line-height:1}
.quick-action-copy{min-width:0}
.home-quick-actions strong{display:block;font-size:1.0625rem;line-height:1.25;color:#203950}
.home-quick-actions small{display:block;margin-top:4px;font-size:.875rem;line-height:1.35;color:#53677c}
.home-quick-actions a:focus-visible{outline:3px solid #267bac;outline-offset:4px}
@media(hover:hover){.home-quick-actions a:hover{background:var(--quick-wash);border-color:var(--quick-accent);transform:translateY(-2px);box-shadow:0 7px 14px #203d5912}}
@media(max-width:650px){.home-cards.home-quick-actions{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.home-premium-actions.home-quick-actions{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.home-quick-actions a{flex-direction:column;align-items:flex-start;padding:12px;gap:8px}.home-quick-actions strong{font-size:1rem}.home-quick-actions .quick-action-icon{width:36px;height:36px;flex-basis:36px;font-size:1.5rem;border-radius:10px}}
@media(max-width:370px){.home-premium-actions.home-quick-actions{grid-template-columns:repeat(2,minmax(0,1fr))}.home-premium-actions .quick-packs{grid-column:1/-1;grid-row:2;flex-direction:row;align-items:center}}
@media(prefers-reduced-motion:reduce){.home-quick-actions a{transition:none}.home-quick-actions a:hover{transform:none}}

/* Retired online player; packs are printed and results are scanned. */
#online-panel{display:none!important}
