/* defstyles base */
:root{
    --bg: light-dark(#fff, #111);
    --text: light-dark(#1c1c1c, #ddd);
    --muted: light-dark(#777, #999);
    --surface: light-dark(#fff, #1a1a1a);
    --surface-2: light-dark(#f2f2f2, #2a2a2a);
    --surface-3: light-dark(#e8e8e8, #343434);
    --border: light-dark(#c4c4c4, #555);
    --border-subtle: light-dark(#e8e8e8, #333);
    --accent: #0a6;
    --accent-contrast: #fff;
    --link: var(--accent);
    --danger: light-dark(#c33, #e88);
    --warn: light-dark(#fe8, #5c4a00);
    --warn-contrast: light-dark(#530, #fe8);
    --radius: 8px;
}

html{
    font-family: system-ui, sans-serif;
    line-height: 1.5;
    color-scheme: light dark;
    background: var(--bg);
    color: var(--text);
}

body{
    max-width: 42rem;
    margin: 2rem auto;
    padding: 0 1rem;
}

a{
    color: var(--link);
}

code{
    background: var(--surface-2);
    padding: 0.1em 0.3em;
    border-radius: 3px;
}

input, select, textarea, button{
    font-family: inherit;
    font-size: 1rem;
    box-sizing: border-box;
    max-width: 100%;
}

button, select, input:not([type=checkbox]):not([type=radio]){
    min-height: 2.75rem;
}

button, input[type=submit]{
    padding: 0.4em 0.9em;
    cursor: pointer;
}

input[type=checkbox], input[type=radio]{
    width: 1.2em;
    height: 1.2em;
}

textarea{
    display: block;
    width: 100%;
    resize: vertical;
}

input:not([type=checkbox]):not([type=radio]):not([type=range]), select, textarea{
    padding: 0.55em 0.7em;
    background: var(--surface);
    color: inherit;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

textarea{
    padding: 0.6em 0.7em;
}

button, input[type=submit]{
    background: var(--surface-2);
    color: inherit;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

button:hover, input[type=submit]:hover{
    background: var(--surface-3);
}

button.quiet, input[type=submit].quiet{
    min-height: 2.2rem;
    padding: 0.2em 0.5em;
    background: transparent;
    border: none;
    font-size: 0.85rem;
    color: var(--muted);
}

button.quiet:hover, button.quiet:focus,
input[type=submit].quiet:hover, input[type=submit].quiet:focus{
    background: transparent;
    color: light-dark(#444, #ccc);
    text-decoration: underline;
}

button.quiet.danger:hover, button.quiet.danger:focus,
input[type=submit].quiet.danger:hover, input[type=submit].quiet.danger:focus{
    color: var(--danger);
}

input:focus-visible, select:focus-visible, textarea:focus-visible,
button:focus-visible, a:focus-visible, summary:focus-visible{
    outline: 2px solid var(--accent);
    outline-offset: 1px;
}

input:focus, select:focus, textarea:focus{
    border-color: var(--accent);
}

.muted{
    color: var(--muted);
}

.error{
    color: var(--danger);
}

.spinner{
    display: inline-block;
    animation: athanor-pulse 1s infinite;
}

@keyframes athanor-pulse{
    from{
        opacity: 1;
    }
    to{
        opacity: 0.2;
    }
}

.problems{
    color: var(--danger);
    margin: 0.5em 0;
    padding-left: 1.2em;
}

.flash-notices:empty{
    display: none;
}

.flash{
    margin: 0 0 1em;
    padding: 0.6em 1em;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-left: 4px solid var(--muted);
    border-radius: var(--radius);
}

.flash.success{
    border-left-color: var(--accent);
}

.flash.error{
    border-left-color: var(--danger);
    color: var(--danger);
}

.or{
    display: flex;
    align-items: center;
    gap: 0.8em;
    color: var(--muted);
    font-size: 0.9rem;
}

.or::before, .or::after{
    content: "";
    flex: 1 1 auto;
    border-top: 1px solid var(--border);
}

.pager{
    display: flex;
    flex-wrap: wrap;
    gap: 1em;
    align-items: baseline;
    margin: 1em 0;
}

div.more, tbody.more td{
    text-align: center;
    padding: 0.6rem;
}

.more a{
    font-weight: 600;
}

.badge{
    display: inline-block;
    padding: 0.05em 0.55em;
    margin-left: 0.4em;
    font-size: 0.8em;
    border-radius: 999px;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
}

.badge.ok{
    background: var(--accent);
    color: var(--accent-contrast);
    border-color: transparent;
}

.badge.warn{
    background: var(--warn);
    color: var(--warn-contrast);
    border-color: transparent;
}

.badge.bad{
    background: var(--danger);
    color: var(--bg);
    border-color: transparent;
}

.image-preview{
    max-width: 100%;
    margin: 0.7em 0;
    border-radius: var(--radius);
}

.image-preview:not([hidden]){
    display: block;
}

.image-previews{
    display: flex;
    flex-wrap: wrap;
    gap: 0.4em;
    margin: 0.7em 0;
}

.image-previews img{
    width: 4.5em;
    height: 4.5em;
    object-fit: cover;
    border-radius: var(--radius);
    border: 1px solid var(--border-subtle);
}

.autosave-status{
    font-size: 0.85rem;
    color: var(--muted);
    white-space: nowrap;
}

.autosave-status.error{
    color: var(--danger);
    white-space: normal;
}

.breadcrumbs ol{
    display: flex;
    flex-wrap: wrap;
    gap: 0 0.4em;
    list-style: none;
    padding: 0;
    margin: 0 0 1em;
    color: var(--muted);
}

.breadcrumbs li + li::before{
    content: "/";
    margin-right: 0.4em;
}

.breadcrumbs a{
    text-decoration: none;
}

.breadcrumbs a:hover, .breadcrumbs a:focus-visible{
    text-decoration: underline;
}

svg.icon{
    width: 1.15em;
    height: 1.15em;
    vertical-align: -0.22em;
    flex: none;
}

svg.icon:not(:only-child){
    margin-right: 0.35em;
}

.ticked{
    background: color-mix(in srgb, var(--accent) 14%, transparent);
}

kbd{
    font-family: ui-monospace, monospace;
    font-size: 0.85em;
    padding: 0 0.35em;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    border-radius: 4px;
    white-space: nowrap;
}

dialog.athanor-keys{
    padding: 0;
    width: min(92vw, 64rem);
    max-height: calc(100vh - 4rem);
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    -moz-box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    -o-box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    -webkit-box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    -ms-box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

dialog.athanor-keys::backdrop{
    background: rgba(0, 0, 0, 0.55);
}

.athanor-keys-box{
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 0.7rem 1rem 1rem;
    max-height: calc(100vh - 4rem);
    box-sizing: border-box;
}

.athanor-keys-head{
    display: flex;
    gap: 0.7rem;
    align-items: baseline;
}

.athanor-keys-head button{
    margin-left: auto;
}

.athanor-keys-groups{
    display: grid;
    gap: 0.8rem 2rem;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
}

.athanor-keys-groups h3{
    margin: 0 0 0.4rem;
    font-size: 0.9rem;
}

.athanor-keys-list{
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.3rem 0.7rem;
    margin: 0;
    font-size: 0.85rem;
    align-items: baseline;
}

.athanor-keys-list dt{
    white-space: nowrap;
}

.athanor-keys-list dd{
    margin: 0;
    color: var(--muted);
}
/* defstyles overlay */
.overlay-backdrop{
    position: fixed;
    inset: 0;
    z-index: 50;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.overlay-sheet{
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 34rem;
    max-height: 85vh;
    overflow-y: auto;
    padding: 0.7em 1em 1em;
    background: var(--surface);
    color: inherit;
    border-radius: 12px 12px 0 0;
    -moz-box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.25);
    -o-box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.25);
    -webkit-box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.25);
    -ms-box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.25);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.25);
}

.overlay-head{
    display: flex;
    align-items: center;
    gap: 0.5em;
    margin-bottom: 0.5em;
}

.overlay-head strong{
    flex: 1 1 auto;
    min-width: 0;
}

.overlay-close{
    flex: 0 0 auto;
    min-width: 2.75rem;
    font-size: 1.3rem;
    line-height: 1;
    background: transparent;
    border: none;
    color: inherit;
}

@media (min-width: 40rem){
    .overlay-backdrop{
        align-items: center;
        padding: 2rem;
    }
    .overlay-sheet{
        border-radius: 12px;
        -moz-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        -o-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        -webkit-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        -ms-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    }
}

.search-field{
    display: flex;
    gap: 0.5em;
    margin: 0 0 0.5em 0;
}

.search-field input[type=search]{
    flex: 1 1 auto;
    min-width: 0;
}
/* defstyles feedback */
.athanor-feedback{
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin: 2rem 0 0.5rem;
}

.athanor-version{
    margin-right: auto;
    font-family: monospace;
    font-size: 0.75rem;
    opacity: 0.7;
}

.athanor-under-construction{
    display: none;
    margin-right: 0.5rem;
    image-rendering: pixelated;
}

.athanor-feedback:has(#athanor-agent [data-working]) .athanor-under-construction{
    display: inline-block;
}

#athanor-feedback{
    width: min(26rem, calc(100vw - 2rem));
    padding: 0.7em 1em 1em;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 12px;
    -moz-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    -o-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    -webkit-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    -ms-box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

#athanor-feedback::backdrop{
    background: rgba(0, 0, 0, 0.3);
}

.athanor-feedback-head{
    display: flex;
    align-items: center;
    margin-bottom: 0.5em;
}

.athanor-feedback-head strong{
    flex: 1 1 auto;
}

.athanor-feedback-head button.athanor-feedback-close{
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    min-height: 0;
    padding: 0;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    -moz-box-shadow: none;
    -o-box-shadow: none;
    -webkit-box-shadow: none;
    -ms-box-shadow: none;
    box-shadow: none;
}

.athanor-feedback-head button.athanor-feedback-close:hover{
    background: var(--border);
}

.athanor-feedback-kinds{
    border: none;
    padding: 0;
    margin: 0 0 0.7em;
    display: flex;
    flex-wrap: wrap;
    gap: 0.3em 1em;
}

.athanor-feedback-kinds legend{
    padding: 0;
    margin-bottom: 0.3em;
}

.athanor-feedback-kinds label{
    display: flex;
    align-items: center;
    gap: 0.35em;
}

.athanor-feedback-sent{
    margin: 0 0 0.7em;
    font-weight: 600;
}

#athanor-feedback-form > label{
    display: block;
    margin-bottom: 0.3em;
}

#athanor-feedback-form textarea{
    margin-bottom: 0.7em;
}

#athanor-feedback-mine{
    padding: 0.3em 1em 0;
}

#athanor-feedback-mine h4{
    margin: 0 0 0.3em;
    font-size: 0.9rem;
}

.athanor-feedback-mine{
    list-style: none;
    padding: 0;
    margin: 0 0 0.6em;
    max-height: 30vh;
    overflow-y: auto;
}

.athanor-feedback-mine li{
    padding: 0.35em 0;
    border-bottom: 1px solid var(--border);
}

.athanor-feedback-mine q{
    display: block;
    font-size: 0.85rem;
}

.athanor-feedback-state{
    display: block;
    font-size: 0.8rem;
    opacity: 0.8;
}

.athanor-feedback-needs-you .athanor-feedback-state{
    opacity: 1;
    font-weight: 600;
}

.athanor-feedback-working .athanor-feedback-state{
    font-style: italic;
}

.athanor-feedback-answer, .athanor-feedback-undo{
    display: flex;
    gap: 0.4em;
    align-items: flex-start;
    margin-top: 0.3em;
}

.athanor-feedback-answer textarea, .athanor-feedback-undo input{
    flex: 1 1 auto;
    margin: 0;
}

.athanor-feedback-problem{
    margin: 0 0 0.5em;
    font-weight: 600;
}

.athanor-feedback-wants{
    margin: 0.3em 0;
    font-size: 0.85rem;
}

.athanor-feedback-allow{
    display: flex;
    gap: 0.4em;
    margin: 0.3em 0;
}

#athanor-agent{
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2147483000;
    background: var(--surface);
    color: var(--text);
    border-top: 1px solid var(--border);
    -moz-box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
    -o-box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
    -webkit-box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
    -ms-box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
    font-size: 0.85rem;
}

#athanor-agent:not(:has([data-working], [data-asks], [data-mine])){
    display: none;
}

#athanor-agent details:not(:has([data-working], [data-mine])){
    display: none;
}

#athanor-agent details:not(:has([data-working])) .athanor-agent-feed{
    display: none;
}

body:has(#athanor-agent [data-working], #athanor-agent [data-mine]){
    padding-bottom: var(--athanor-agent-height, 2.6rem);
}

#athanor-agent-asks:not([data-asks]){
    display: none;
}

#athanor-agent-asks{
    padding: 0.5em 1em;
    max-height: 40vh;
    overflow-y: auto;
    border-bottom: 1px solid var(--border);
}

body:has(#athanor-agent [data-asks]){
    padding-bottom: var(--athanor-agent-height, 12rem);
}

.athanor-agent-ask{
    padding: 0.3em 0;
}

.athanor-agent-ask + .athanor-agent-ask{
    border-top: 1px solid var(--border);
}

#athanor-agent summary{
    padding: 0.45em 1em;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.athanor-agent-step{
    font-family: monospace;
    opacity: 0.8;
    margin-left: 0.6em;
}

.athanor-agent-feed{
    list-style: none;
    margin: 0;
    padding: 0 1em 0.6em;
    max-height: 50vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column-reverse;
}

.athanor-agent-feed li{
    padding: 0.15em 0;
    border-bottom: 1px solid var(--border);
    font-family: monospace;
    overflow-wrap: anywhere;
}

.athanor-agent-feed b{
    font-weight: 600;
    margin-right: 0.5em;
}

.athanor-agent-feed .athanor-agent-tool b{
    font-weight: 500;
    padding: 0 0.4em;
    border-radius: 3px;
    background: rgba(127, 127, 127, 0.18);
}

.athanor-agent-feed .athanor-agent-tool span{
    opacity: 0.75;
}

.athanor-agent-feed .athanor-agent-said{
    font-family: inherit;
    line-height: 1.4;
    padding: 0.35em 0.6em;
    margin: 0.2em 0;
    border-left: 3px solid #2e86de;
    background: rgba(46, 134, 222, 0.08);
}

.athanor-agent-feed .athanor-agent-said b{
    color: #2e86de;
}

.athanor-agent-ask, .athanor-agent-feed .athanor-agent-said, .athanor-feedback-mine li{
    max-width: 40rem;
}

.athanor-agent-failed, .athanor-agent-refused{
    color: #c0392b;
}
/* defstyles numbat */
:root{
    --accent: #ff7a1a;
    --accent-contrast: #fff;
    --link: #d95f00;
    --pop: #7c4dff;
    --gold: #f5b301;
    --silver: #b8c2cc;
    --bronze: #c47a3d;
    --good: #22c55e;
    --bad: #ef4444;
    --rung-1: #bbf7d0;
    --rung-2: #86efac;
    --rung-3: #4ade80;
    --rung-4: #22c55e;
    --rung-5: #15803d;
    --rung-miss: #fdba74;
}

body{
    max-width: 34rem;
    margin: 0 auto;
    padding: 0 1rem 3rem;
}

h1{
    font-size: 1.8rem;
    margin: 0.6rem 0 0.4rem;
    letter-spacing: -0.02em;
}

h2{
    font-size: 1.1rem;
    margin: 1.6rem 0 0.5rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

nav{
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 0.6rem;
}

nav .brand{
    display: inline-flex;
    align-items: center;
    flex: 0 1 auto;
    min-width: 0;
}

nav .brand img{
    display: block;
    max-width: 100%;
    height: auto;
}

nav .spacer{
    flex: 1 1 auto;
}

nav .who{
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 600;
}

svg.face{
    display: block;
    border-radius: 24%;
    width: 100%;
    height: auto;
    aspect-ratio: 1;
}

nav .who a{
    display: block;
    width: 2rem;
    flex: none;
}

nav .who .lvl{
    font-size: 0.75rem;
    color: var(--accent-contrast);
    background: var(--pop);
    border-radius: 999px;
    padding: 0.1em 0.5em;
}

nav form.inline{
    display: inline;
}

nav .account{
    text-decoration: none;
    color: var(--muted);
    font-size: 1.4rem;
    line-height: 1;
    padding: 0 0.2rem;
}

nav .account:hover, nav .account:focus-visible{
    text-decoration: none;
    color: var(--text);
}

.auth p{
    font-size: 1.05rem;
}

.auth form p{
    margin: 0.6rem 0;
}

.auth input{
    width: 100%;
    box-sizing: border-box;
}

.auth button:not(.quiet):not(.primary){
    width: 100%;
    font-weight: 700;
    padding: 0.7rem 1rem;
}

.auth .or{
    margin: 1.2rem 0;
}

.auth .magic-code input{
    font-size: 2rem;
    text-align: center;
    letter-spacing: 0.4em;
    font-variant-numeric: tabular-nums;
    font-family: ui-monospace, monospace;
    padding: 0.4rem 0;
}

.auth .magic-code input::placeholder{
    color: var(--border);
}

.auth form:not(.magic-code) button.quiet{
    display: block;
    margin: 0 auto;
}

nav button.quiet{
    min-height: 2.75rem;
    padding: 0 0.8rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
    border: 1.5px solid var(--border);
    border-radius: 999px;
}

nav button.quiet:hover, nav button.quiet:focus{
    color: var(--text);
    text-decoration: none;
    border-color: var(--accent);
}

.primary, a.primary{
    display: block;
    text-align: center;
    background: var(--accent);
    color: var(--accent-contrast);
    border: none;
    border-radius: 1rem;
    font-size: 1.4rem;
    font-weight: 800;
    padding: 0.8rem 1.2rem;
    text-decoration: none;
    -moz-box-shadow: 0 6px 0 #c95a00;
    -o-box-shadow: 0 6px 0 #c95a00;
    -webkit-box-shadow: 0 6px 0 #c95a00;
    -ms-box-shadow: 0 6px 0 #c95a00;
    box-shadow: 0 6px 0 #c95a00;
    width: 100%;
    box-sizing: border-box;
    cursor: pointer;
    -moz-transition: transform 0.05s;
    -o-transition: transform 0.05s;
    -webkit-transition: transform 0.05s;
    -ms-transition: transform 0.05s;
    transition: transform 0.05s;
}

.primary:focus-visible{
    outline: 3px solid var(--pop);
    outline-offset: 3px;
}

.primary:active{
    -moz-transform: translateY(4px);
    -o-transform: translateY(4px);
    -webkit-transform: translateY(4px);
    -ms-transform: translateY(4px);
    transform: translateY(4px);
    -moz-box-shadow: 0 2px 0 #c95a00;
    -o-box-shadow: 0 2px 0 #c95a00;
    -webkit-box-shadow: 0 2px 0 #c95a00;
    -ms-box-shadow: 0 2px 0 #c95a00;
    box-shadow: 0 2px 0 #c95a00;
}

.primary:hover{
    background: #ff8c3a;
}

.players{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
    gap: 0.8rem;
}

.players form{
    display: contents;
}

.players button.card{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    padding: 1rem 0.5rem;
    border-radius: 1rem;
    border: 2px solid var(--border-subtle);
    background: var(--surface);
    font-weight: 700;
    cursor: pointer;
}

.players button.card:hover{
    border-color: var(--accent);
    background: var(--surface);
}

.players .face{
    width: 4.5rem;
}

.players .lvl{
    font-size: 0.8rem;
    color: var(--muted);
    font-weight: 400;
}

.new-player{
    margin-top: 1.5rem;
    padding: 1rem;
    border-radius: 1rem;
    background: var(--surface-2);
}

.new-player .row{
    display: flex;
    gap: 0.5rem;
}

.new-player .row input{
    flex: 1 1 auto;
}

.hero{
    display: flex;
    align-items: center;
    gap: 0.9rem;
    margin: 0.8rem 0 1rem;
}

.hero .about{
    flex: 1 1 auto;
    min-width: 0;
}

.hero .stats{
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    margin-top: 0.5rem;
}

.pill{
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--text);
    white-space: nowrap;
}

.pill.hot{
    background: #fff1e6;
    color: #c2410c;
}

.hero a.me{
    position: relative;
    display: block;
    width: 5rem;
    flex: none;
    text-decoration: none;
}

.hero .pencil{
    position: absolute;
    right: -0.3rem;
    bottom: -0.3rem;
    font-size: 0.9rem;
    background: var(--surface);
    border-radius: 999px;
    padding: 0.15rem;
    -moz-box-shadow: 0 1px 3px rgba(0,0,0,0.25);
    -o-box-shadow: 0 1px 3px rgba(0,0,0,0.25);
    -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.25);
    -ms-box-shadow: 0 1px 3px rgba(0,0,0,0.25);
    box-shadow: 0 1px 3px rgba(0,0,0,0.25);
    line-height: 1;
}

.wardrobe .preview{
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.6rem 0;
    background: var(--bg);
}

.wardrobe .preview .face{
    width: 7.5rem;
    flex: none;
    -moz-box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    -o-box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    -webkit-box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    -ms-box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    box-shadow: 0 3px 10px rgba(0,0,0,0.15);
}

.wardrobe .preview h1{
    margin-top: 0;
}

.wardrobe .preview .row{
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.wardrobe fieldset{
    border: none;
    padding: 0;
    margin: 1rem 0 0;
    scroll-margin-top: 9rem;
}

.wardrobe legend{
    font-weight: 800;
    font-size: 0.85rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0;
    margin-bottom: 0.4rem;
}

.wardrobe .options{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(4.6rem, 1fr));
    gap: 0.5rem;
}

.wardrobe .skin .options, .wardrobe .hair-color .options, .wardrobe .shirt .options, .wardrobe .buddy .options{
    grid-template-columns: repeat(auto-fill, minmax(3.4rem, 1fr));
}

.wardrobe .option{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    cursor: pointer;
    text-align: center;
}

.wardrobe .option input{
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.wardrobe .option small{
    font-size: 0.7rem;
    line-height: 1.15;
    color: var(--muted);
}

.wardrobe .thumb, .wardrobe .swatch, .wardrobe .emoji{
    display: block;
    width: 100%;
    border-radius: 24%;
    border: 3px solid transparent;
    box-sizing: border-box;
}

.wardrobe .swatch, .wardrobe .emoji{
    aspect-ratio: 1;
    -moz-box-shadow: inset 0 0 0 1px rgba(0,0,0,0.12);
    -o-box-shadow: inset 0 0 0 1px rgba(0,0,0,0.12);
    -webkit-box-shadow: inset 0 0 0 1px rgba(0,0,0,0.12);
    -ms-box-shadow: inset 0 0 0 1px rgba(0,0,0,0.12);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.12);
}

.wardrobe .emoji{
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    background: var(--surface-2);
}

.wardrobe .option input:checked + span{
    border-color: var(--accent);
}

.wardrobe .option input:focus-visible + span{
    outline: 3px solid var(--pop);
    outline-offset: 2px;
}

.wardrobe .option input:checked ~ small{
    color: var(--text);
    font-weight: 700;
}

.wardrobe .locked{
    cursor: not-allowed;
}

.wardrobe .locked > span{
    opacity: 0.35;
    -moz-filter: grayscale(0.7);
    -o-filter: grayscale(0.7);
    -webkit-filter: grayscale(0.7);
    -ms-filter: grayscale(0.7);
    filter: grayscale(0.7);
}

.wardrobe .locked small{
    font-weight: 700;
}

.hero .name{
    font-size: 1.5rem;
    font-weight: 800;
}

.hero .level{
    color: var(--muted);
    font-size: 0.9rem;
}

.xp{
    height: 0.7rem;
    border-radius: 999px;
    background: var(--surface-2);
    overflow: hidden;
    margin-top: 0.3rem;
}

.xp i{
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--pop), var(--accent));
    border-radius: 999px;
    -moz-transition: width 0.8s ease-out;
    -o-transition: width 0.8s ease-out;
    -webkit-transition: width 0.8s ease-out;
    -ms-transition: width 0.8s ease-out;
    transition: width 0.8s ease-out;
}

.today-card{
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem 1rem;
    margin: 0 0 0.4rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--pop);
    color: var(--text);
    text-decoration: none;
}

a.today-card:hover{
    background: var(--surface);
}

.today-card .icon{
    font-size: 2rem;
    line-height: 1;
}

.today-card .what{
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.today-card .what b{
    font-size: 1.2rem;
}

.today-card .what small{
    color: var(--muted);
}

.track{
    scroll-margin-top: 1rem;
}

.track-head{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.track-head form{
    margin: 0;
}

.track-head button{
    font-size: 0.8rem;
    padding: 0.2rem 0.6rem;
}

.track.off h2{
    color: var(--muted);
}

.stone.off{
    opacity: 0.55;
    color: var(--muted);
}

.track .stones{
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.stone{
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    border: 2px solid var(--border-subtle);
    background: var(--surface-2);
    color: var(--text);
    text-decoration: none;
    font-size: 0.9rem;
}

a.stone:hover{
    background: var(--surface);
}

.stone .mark{
    font-weight: 800;
    font-size: 0.8rem;
    min-width: 1.4rem;
    text-align: center;
}

.stone.done{
    border-color: var(--gold);
}

.stone.skipped{
    color: var(--muted);
}

.stone.open{
    border-color: var(--accent);
}

.stone.open .mark{
    color: var(--accent);
}

.stone.locked{
    opacity: 0.55;
    border-style: dashed;
}

.stone.next{
    border-color: var(--pop);
    -moz-box-shadow: 0 0 0 3px color-mix(in srgb, var(--pop) 25%, transparent);
    -o-box-shadow: 0 0 0 3px color-mix(in srgb, var(--pop) 25%, transparent);
    -webkit-box-shadow: 0 0 0 3px color-mix(in srgb, var(--pop) 25%, transparent);
    -ms-box-shadow: 0 0 0 3px color-mix(in srgb, var(--pop) 25%, transparent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--pop) 25%, transparent);
}

.stone-progress{
    font-weight: 700;
    color: var(--pop);
}

.stone-progress.done{
    color: var(--gold);
    font-size: 1.1rem;
}

.stone .badge{
    background: var(--pop);
    color: var(--accent-contrast);
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 0.05rem 0.45rem;
}

.start{
    display: grid;
    gap: 0.7rem;
    margin: 0 0 0.8rem;
}

.ways{
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    gap: 0.5rem;
}

@media (max-width: 32rem){
    .ways{
        grid-auto-flow: row;
        grid-template-columns: 1fr 1fr;
    }
    .ways .way:last-child:nth-child(odd){
        grid-column: 1 / -1;
    }
}

.way{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.1rem;
    min-width: 0;
    padding: 0.55rem 0.5rem;
    border-radius: 0.9rem;
    background: var(--surface-2);
    border: 2px solid var(--border-subtle);
    color: var(--text);
    text-decoration: none;
    text-align: center;
}

a.way:hover{
    background: var(--surface);
    border-color: var(--pop);
}

a.way:focus-visible{
    outline: 3px solid var(--pop);
    outline-offset: 2px;
}

.way .icon{
    font-size: 1.4rem;
    line-height: 1.2;
}

.way b{
    font-size: 0.95rem;
}

.way small{
    color: var(--muted);
    font-size: 0.75rem;
    line-height: 1.25;
    max-width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hint{
    color: var(--muted);
    font-size: 0.85rem;
    text-align: center;
    margin: 0 0 0.4rem;
}

.primary .goal{
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    font-weight: 700;
    opacity: 0.95;
}

.goal .ring{
    display: inline-flex;
    gap: 0.2rem;
}

.goal .ring i{
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.35);
}

.goal .ring i.on{
    background: #fff;
}

.progress-link{
    display: block;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--pop);
    margin: 0.2rem 0 0.4rem;
}

.rung-key{
    color: var(--muted);
    font-size: 0.8rem;
    margin: 0.2rem 0 0.6rem;
    text-align: center;
}

.rung-key > summary{
    cursor: pointer;
    display: inline-block;
    padding: 0.2rem 0.4rem;
}

.rung-key[open]{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
}

.rung-key .swatches{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.2rem 0.6rem;
}

.rung-key .swatches > span{
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.rung-key i{
    width: 0.8rem;
    height: 0.8rem;
    border-radius: 3px;
    background: var(--surface-2);
    -moz-box-shadow: inset 0 0 0 1px var(--border-subtle);
    -o-box-shadow: inset 0 0 0 1px var(--border-subtle);
    -webkit-box-shadow: inset 0 0 0 1px var(--border-subtle);
    -ms-box-shadow: inset 0 0 0 1px var(--border-subtle);
    box-shadow: inset 0 0 0 1px var(--border-subtle);
}

.subject{
    border: 1px solid var(--border-subtle);
    border-radius: 1rem;
    margin: 0 0 0.6rem;
    background: var(--surface);
}

.subject > summary{
    list-style: none;
    cursor: pointer;
    padding: 0.7rem 0.9rem;
    display: grid;
    gap: 0.45rem;
    border-radius: 1rem;
}

.subject > summary::-webkit-details-marker{
    display: none;
}

.subject > summary:hover{
    background: var(--surface-2);
}

.subject > summary:focus-visible{
    outline: 3px solid var(--pop);
    outline-offset: 2px;
}

.subject .head{
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.3rem 0.6rem;
}

.subject .head h2, .subject .head h3{
    margin: 0;
    flex: 1 1 auto;
}

.subject .head h3{
    font-size: 1.05rem;
    font-weight: 800;
}

h2.family{
    margin-top: 1.4rem;
}

.subject .meta{
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-left: auto;
}

.subject .head h2::before, .subject .head h3::before{
    content: "▸";
    display: inline-block;
    width: 1em;
    color: var(--muted);
    -moz-transition: transform 0.15s;
    -o-transition: transform 0.15s;
    -webkit-transition: transform 0.15s;
    -ms-transition: transform 0.15s;
    transition: transform 0.15s;
}

.subject[open] .head h2::before, .subject[open] .head h3::before{
    -moz-transform: rotate(90deg);
    -o-transform: rotate(90deg);
    -webkit-transform: rotate(90deg);
    -ms-transform: rotate(90deg);
    transform: rotate(90deg);
}

.subject > .recent{
    padding: 0 0.9rem 0.6rem;
}

.recent-card{
    margin-top: 1.2rem;
}

.mixups{
    margin-bottom: 1.2rem;
}

.mixups .patterns, .mixups .hint{
    margin: 0 0.9rem 0.6rem;
}

.mixups .patterns{
    padding-left: 1.1rem;
    font-size: 0.95rem;
}

.mixups .patterns li{
    margin-bottom: 0.35rem;
}

.mixups .advice{
    color: var(--muted);
}

.badge-strip{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin: 0 0 0.9rem;
    color: var(--muted);
    font-size: 0.85rem;
    text-decoration: none;
}

.badge-strip .icons{
    font-size: 1.3rem;
    letter-spacing: 0.1em;
}

.badge-strip:hover{
    color: var(--text);
}

.subject .verdict{
    color: var(--muted);
    font-size: 0.8rem;
    white-space: nowrap;
}

.subject.done .verdict{
    color: var(--gold);
    font-weight: 700;
}

.subject .verdict b{
    color: var(--gold);
}

.subject .practise{
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
    text-decoration: none;
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    color: var(--accent);
    border: 1.5px solid var(--accent);
}

.subject .practise:hover{
    background: var(--accent);
    color: #fff;
}

.rungs{
    display: flex;
    gap: 2px;
    height: 0.6rem;
    border-radius: 999px;
    overflow: hidden;
}

.rungs i{
    background: var(--surface-2);
    min-width: 3px;
}

.subject > .mastery{
    padding: 0 0.9rem 0.8rem;
}

.mastery{
    display: grid;
    gap: 0.35rem;
}

.mastery .row{
    display: grid;
    grid-template-columns: 3.4rem 4.2rem 1fr;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
}

a.row{
    color: inherit;
    text-decoration: none;
    border-radius: 0.5rem;
    padding: 0.1rem 0;
}

a.row:hover{
    background: var(--surface-2);
}

a.row:focus-visible{
    outline: 2px solid var(--pop);
    outline-offset: 2px;
}

.mastery .t{
    font-weight: 800;
    text-align: right;
}

.mastery .row.tier{
    margin-top: 0.3rem;
    padding-top: 0.35rem;
    border-top: 1px dashed var(--border-subtle);
}

.mastery .row.tier .t{
    font-size: 0.8rem;
    color: var(--pop);
}

.mastery .stars{
    letter-spacing: -0.1em;
    font-size: 0.9rem;
}

.mastery .stars.s0{
    color: var(--border);
}

.mastery .stars.s1{
    color: var(--bronze);
}

.mastery .stars.s2{
    color: var(--silver);
}

.mastery .stars.s3{
    color: var(--gold);
}

.heat{
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    gap: 2px;
    height: 0.9rem;
}

.heat i{
    border-radius: 3px;
    background: var(--surface-2);
}

.heat i.b1, .rungs i.b1, .rung-key i.b1{
    background: var(--rung-1);
}

.heat i.b2, .rungs i.b2, .rung-key i.b2{
    background: var(--rung-2);
}

.heat i.b3, .rungs i.b3, .rung-key i.b3{
    background: var(--rung-3);
}

.heat i.b4, .rungs i.b4, .rung-key i.b4{
    background: var(--rung-4);
}

.heat i.b5, .rungs i.b5, .rung-key i.b5{
    background: var(--rung-5);
}

.heat i.miss, .rungs i.miss, .rung-key i.miss{
    background: var(--rung-miss);
}

.heat.played{
    display: flex;
    align-items: center;
    height: auto;
    flex-wrap: wrap;
}

.heat.played i{
    flex: 0 0 1.4rem;
    height: 0.9rem;
}

.heat.played small{
    color: var(--muted);
    font-size: 0.75rem;
    margin-left: 0.35rem;
    white-space: nowrap;
}

.shelf{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(6.2rem, 1fr));
    gap: 0.5rem;
}

.near-head{
    font-size: 0.95rem;
    margin: 1rem 0 0.4rem;
}

.near{
    display: grid;
    gap: 0.4rem;
}

.near-badge{
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.5rem 0.8rem;
    border-radius: 0.9rem;
    background: var(--surface-2);
}

.near-badge .icon{
    font-size: 1.8rem;
    line-height: 1;
}

.near-badge .what{
    flex: 1 1 auto;
    display: grid;
    gap: 0.15rem;
    min-width: 0;
}

.near-badge b{
    font-size: 0.95rem;
}

.near-badge small{
    color: var(--muted);
    font-size: 0.8rem;
}

.near-badge .meter{
    display: block;
    height: 0.45rem;
    border-radius: 999px;
    background: var(--border-subtle);
    overflow: hidden;
}

.near-badge .meter i{
    display: block;
    height: 100%;
    border-radius: 999px;
    background: var(--gold);
}

.more-badges{
    margin-top: 0.8rem;
}

.more-badges > summary{
    cursor: pointer;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
    padding: 0.3rem 0;
}

.more-badges .shelf{
    margin-top: 0.4rem;
}

.award{
    position: relative;
    display: block;
    width: 100%;
    min-height: 0;
    margin: 0;
    text-align: center;
    padding: 0.6rem 0.3rem;
    border: none;
    border-radius: 0.9rem;
    background: var(--surface-2);
    color: inherit;
    font: inherit;
    font-size: 0.75rem;
    line-height: 1.2;
    cursor: pointer;
}

.award:hover{
    background: var(--surface-3);
}

.award:focus-visible{
    outline: 3px solid var(--pop);
    outline-offset: 2px;
}

.award .icon{
    display: block;
    font-size: 1.8rem;
    margin-bottom: 0.2rem;
}

.award b{
    display: block;
    font-size: 0.8rem;
}

.award.locked > .icon, .award.locked > b{
    opacity: 0.45;
    -moz-filter: grayscale(1);
    -o-filter: grayscale(1);
    -webkit-filter: grayscale(1);
    -ms-filter: grayscale(1);
    filter: grayscale(1);
}

.award.new{
    -moz-box-shadow: inset 0 0 0 2px var(--gold);
    -o-box-shadow: inset 0 0 0 2px var(--gold);
    -webkit-box-shadow: inset 0 0 0 2px var(--gold);
    -ms-box-shadow: inset 0 0 0 2px var(--gold);
    box-shadow: inset 0 0 0 2px var(--gold);
}

.award .sticker{
    position: absolute;
    top: -0.45rem;
    right: -0.3rem;
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    background: var(--pop);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 800;
    -moz-transform: rotate(8deg);
    -o-transform: rotate(8deg);
    -webkit-transform: rotate(8deg);
    -ms-transform: rotate(8deg);
    transform: rotate(8deg);
}

.badge-strip .new{
    color: var(--pop);
    font-weight: 800;
}

.award .detail{
    display: none;
    position: fixed;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 20;
    padding: 1rem 1.2rem;
    border-radius: 1.2rem;
    background: var(--surface);
    border: 2px solid var(--pop);
    -moz-box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    -o-box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    -webkit-box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    -ms-box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    font-size: 1rem;
    line-height: 1.3;
    pointer-events: none;
    animation: nb-rise 0.18s ease-out;
}

.award:hover .detail, .award:focus .detail{
    display: block;
}

.award .detail .icon{
    font-size: 3.6rem;
    line-height: 1.1;
    margin-bottom: 0.3rem;
}

.award.locked .detail .icon{
    -moz-filter: grayscale(1);
    -o-filter: grayscale(1);
    -webkit-filter: grayscale(1);
    -ms-filter: grayscale(1);
    filter: grayscale(1);
    opacity: 0.6;
}

.award .detail strong{
    display: block;
    font-size: 1.25rem;
}

.award .detail .what{
    display: block;
    margin: 0.2rem 0 0.4rem;
}

.award .detail small{
    display: block;
    color: var(--muted);
    font-size: 0.85rem;
}

.award:not(.locked) .detail small{
    color: var(--good);
    font-weight: 700;
}

@media (hover: hover) and (min-width: 44rem){
    .award .detail{
        position: absolute;
        left: 50%;
        right: auto;
        bottom: calc(100% + 0.5rem);
        width: 15rem;
        margin-left: -7.5rem;
    }
}

@keyframes nb-rise{
    from{
        opacity: 0;
        -moz-transform: translateY(0.5rem);
        -o-transform: translateY(0.5rem);
        -webkit-transform: translateY(0.5rem);
        -ms-transform: translateY(0.5rem);
        transform: translateY(0.5rem);
    }
    to{
        opacity: 1;
        -moz-transform: none;
        -o-transform: none;
        -webkit-transform: none;
        -ms-transform: none;
        transform: none;
    }
}

.recent{
    list-style: none;
    padding: 0;
    margin: 0;
}

.recent li{
    display: flex;
    gap: 0.6rem;
    align-items: baseline;
    padding: 0.4rem 0;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.95rem;
}

.recent .score{
    font-weight: 800;
    min-width: 3.5rem;
}

.recent .when{
    margin-left: auto;
    color: var(--muted);
    font-size: 0.8rem;
}

.subjects{
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin: 0.5rem 0 0.8rem;
}

.subjects label{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35em;
    padding: 0.6rem 0.3rem;
    border-radius: 999px;
    border: 2px solid var(--border-subtle);
    cursor: pointer;
    font-weight: 800;
    font-size: 1.05rem;
    background: var(--surface);
    white-space: nowrap;
}

@media (max-width: 32rem){
    .subjects{
        gap: 0.35rem;
    }
    .subjects label{
        flex-direction: column;
        gap: 0.1rem;
        border-radius: 1rem;
        padding: 0.45rem 0.2rem;
        font-size: 0.82rem;
    }
    .subjects .icon{
        font-size: 1.3rem;
        line-height: 1;
    }
}

.subjects label:has(input:checked){
    background: var(--pop);
    color: #fff;
    border-color: var(--pop);
}

.subject-group h3{
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0.6rem 0 0.1rem;
}

.subject-group .subjects{
    margin: 0.3rem 0 0.4rem;
}

.setup h2.step{
    margin: 1rem 0 0.3rem;
}

.setup.single-kind .kinds-title, .setup.single-mode .modes-title{
    display: none;
}

.subjects input{
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.setup.geo .math-only, .setup.reading .math-only, .setup.tricks .math-only, .setup.time .math-only, .setup.fractions .math-only, .setup.life .math-only, .setup.count .math-only, .setup.letters .math-only, .setup.language .math-only, .setup.money .math-only, .setup.puzzles .math-only, .setup.share .math-only, .setup.story .math-only, .setup.writing .math-only, .setup.calligraphy .math-only{
    display: none;
}

.setup:not(.geo) .geo-only, .setup:not(.reading) .reading-only, .setup:not(.tricks) .tricks-only, .setup:not(.time) .time-only, .setup:not(.fractions) .fractions-only, .setup:not(.life) .life-only, .setup:not(.count) .count-only, .setup:not(.letters) .letters-only, .setup:not(.language) .language-only, .setup:not(.money) .money-only, .setup:not(.puzzles) .puzzles-only, .setup:not(.share) .share-only, .setup:not(.story) .story-only, .setup:not(.writing) .writing-only, .setup:not(.calligraphy) .calligraphy-only, .setup:not(.writing):not(.calligraphy) .pen-only{
    display: none;
}

.setup:not(.tricks):not(.time):not(.fractions):not(.money):not(.puzzles):not(.share):not(.story):not(.writing):not(.calligraphy) .lesson-only{
    display: none;
}

.kinds.clocks{
    grid-template-columns: 1fr;
}

.kinds.clocks b{
    white-space: normal;
}

.setup.life .modes label:not(.life-only), .setup.count .modes label:not(.count-only), .setup.letters .modes label:not(.letters-only), .setup.share .modes label:not(.share-only), .setup.story .modes label:not(.story-only), .setup.writing .modes label:not(.pen-only), .setup.calligraphy .modes label:not(.pen-only){
    display: none;
}

.kinds.routines, .kinds.counters, .kinds.alphabets{
    grid-template-columns: 1fr;
}

.kinds.routines b, .kinds.counters b, .kinds.alphabets b{
    white-space: normal;
}

.chips.ranges label, .chips.sets label{
    min-width: 0;
    height: 2.6rem;
    padding: 0 0.9rem;
    font-size: 0.95rem;
}

.chips.sets label{
    letter-spacing: 0.12em;
}

.chips.themes label{
    min-width: 0;
    height: 2.8rem;
    padding: 0 1rem;
    font-size: 1.05rem;
}

.kinds.tricks{
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 32rem){
    .kinds.tricks{
        grid-template-columns: 1fr 1fr;
    }
}

.kinds.tricks b{
    white-space: normal;
    font-size: 0.98rem;
}

.kinds.tricks small{
    display: block;
    font-size: 0.75rem;
    line-height: 1.3;
}

.setup .modes label[hidden], .setup .chips.levels[hidden]{
    display: none;
}

.setup.fixed-level .levels{
    display: none;
}

.setup.tricks .modes{
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
}

.chips.levels label{
    min-width: 0;
    height: 2.6rem;
    padding: 0 0.9rem;
    font-size: 0.95rem;
}

.kinds.atlases, .kinds.lexicons{
    grid-template-columns: repeat(2, 1fr);
}

.kinds.readers{
    grid-template-columns: 1fr;
}

.chips.regions label, .chips.bands label, .chips.topics label{
    min-width: 0;
    height: 2.6rem;
    padding: 0 0.9rem;
    font-size: 0.95rem;
}

.chips.regions[hidden], .chips.bands[hidden], .chips.topics[hidden]{
    display: none;
}

.forms{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    gap: 0.6rem;
    margin: 0.5rem 0 1rem;
}

@media (max-width: 32rem){
    .forms{
        grid-template-columns: 1fr 1fr;
    }
}

.forms label[hidden]{
    display: none;
}

.forms label{
    display: block;
    padding: 0.7rem 0.5rem;
    border-radius: 1rem;
    text-align: center;
    border: 2px solid var(--border-subtle);
    cursor: pointer;
    background: var(--surface);
}

.forms label:has(input:checked){
    border-color: var(--pop);
    background: #f3eeff;
}

.forms input{
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.forms b{
    display: block;
    font-size: 1.05rem;
}

.forms small{
    color: var(--muted);
}

.kinds, .modes{
    display: grid;
    gap: 0.6rem;
    margin: 0.5rem 0 1rem;
}

.kinds{
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 32rem){
    .kinds{
        grid-template-columns: 1fr 1fr;
    }
}

.modes{
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
}

@media (max-width: 32rem){
    .modes label{
        padding: 0.6rem 0.55rem;
    }
    .modes b{
        font-size: 1.05rem;
    }
    .modes small{
        display: block;
        font-size: 0.85rem;
        line-height: 1.3;
    }
}

.kinds label, .modes label{
    display: block;
    padding: 0.9rem;
    border-radius: 1rem;
    border: 2px solid var(--border-subtle);
    cursor: pointer;
    background: var(--surface);
}

.kinds label:has(input:checked), .modes label:has(input:checked){
    border-color: var(--pop);
    background: #f3eeff;
}

.kinds input, .modes input{
    position: absolute;
    opacity: 0;
}

.kinds b, .modes b{
    display: block;
    font-size: 1.2rem;
}

.kinds b{
    font-size: 1.05rem;
    white-space: nowrap;
}

.kinds label{
    padding: 0.7rem 0.3rem;
    text-align: center;
}

.kinds small, .modes small{
    color: var(--text);
    opacity: 0.75;
}

.kinds small{
    font-variant-numeric: tabular-nums;
}

.chips{
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 0.5rem 0;
}

.chips label{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 3rem;
    height: 3rem;
    border-radius: 999px;
    border: 2px solid var(--border-subtle);
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    background: var(--surface);
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.chips label:has(input:checked){
    background: var(--pop);
    color: #fff;
    border-color: var(--pop);
}

.chips input{
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.chips.big{
    display: none;
}

.chips.big.open{
    display: flex;
}

.quick{
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0.4rem 0 1rem;
}

.quick button{
    min-height: 0;
    padding: 0.45rem 0.9rem;
    font-size: 0.95rem;
    border-radius: 999px;
    border: 2px solid var(--border-subtle);
}

.grown-ups{
    margin-top: 1.2rem;
}

.grown-ups summary{
    cursor: pointer;
    color: var(--muted);
    font-weight: 700;
    font-size: 0.95rem;
}

.grown-ups .options{
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    margin-top: 0.6rem;
}

.grown-ups .tier{
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    border: 2px solid var(--border-subtle);
    font-weight: 700;
    font-size: 0.85rem;
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.grown-ups .tier:has(input:checked){
    background: var(--pop);
    color: #fff;
    border-color: var(--pop);
}

.grown-ups .tier input{
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.setup.two-digit .chips, .setup.two-digit .quick, .setup.two-digit #toggle-big{
    opacity: 0.35;
    pointer-events: none;
}

.setup.munch .grown-ups .tier, .setup.munch #pick-weak{
    opacity: 0.35;
    pointer-events: none;
}

.setup.hop .practise, .setup.hop .forms{
    display: none;
}

.setup .primary{
    margin-top: 1rem;
}

.primary.go{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.1rem;
}

.primary.go .summary{
    font-size: 0.85rem;
    font-weight: 700;
    opacity: 0.9;
}

.primary.go .summary:empty{
    display: none;
}

#pick-weak{
    width: 100%;
    margin-top: 1rem;
    padding: 0.7rem;
    border-radius: 1rem;
    border: 2px solid var(--pop);
    background: transparent;
    color: var(--pop);
    font-weight: 800;
    font-size: 1.05rem;
}

.setup.single-kind .kinds, .setup.single-mode .modes{
    margin: 0.6rem 0 0.8rem;
}

.setup.single-kind .kinds label, .setup.single-mode .modes label{
    border: none;
    background: none;
    padding: 0;
    text-align: left;
    cursor: default;
}

.setup.single-kind .kinds b{
    display: none;
}

.setup.single-kind .kinds small{
    font-size: 0.95rem;
}

.shortcuts{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    gap: 0.6rem;
    margin: 0.6rem 0 0;
}

.shortcuts .today-card{
    margin: 0;
    border-color: var(--accent);
}

.again-card{
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem 1rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--accent);
    color: var(--text);
    text-decoration: none;
}

a.again-card:hover{
    background: var(--surface);
}

.again-card .icon{
    font-size: 1.6rem;
    line-height: 1;
    color: var(--accent);
}

.again-card .what{
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.again-card .what b{
    font-size: 1.2rem;
}

.again-card .what small{
    color: var(--muted);
}

.game{
    position: relative;
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-user-select: none;
}

.game .top{
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.4rem 0;
    min-height: 2.4rem;
}

.game .score{
    font-weight: 800;
    font-size: 1.4rem;
    min-width: 4rem;
}

.game .combo{
    font-weight: 800;
    color: var(--pop);
    opacity: 0;
    -moz-transition: opacity 0.2s, transform 0.2s;
    -o-transition: opacity 0.2s, transform 0.2s;
    -webkit-transition: opacity 0.2s, transform 0.2s;
    -ms-transition: opacity 0.2s, transform 0.2s;
    transition: opacity 0.2s, transform 0.2s;
    -moz-transform: scale(0.8);
    -o-transform: scale(0.8);
    -webkit-transform: scale(0.8);
    -ms-transform: scale(0.8);
    transform: scale(0.8);
}

.game .combo.on{
    opacity: 1;
    -moz-transform: scale(1);
    -o-transform: scale(1);
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
}

.game .combo.x2{
    color: #f59e0b;
}

.game .combo.x3{
    color: #ef4444;
}

.game .combo.x4{
    color: #7c4dff;
}

.game .clock{
    margin-left: auto;
    font-variant-numeric: tabular-nums;
    font-weight: 700;
    color: var(--muted);
}

.game .clock.low{
    color: var(--bad);
}

.bar{
    height: 0.5rem;
    background: var(--surface-2);
    border-radius: 999px;
    overflow: hidden;
}

.bar i{
    display: block;
    height: 100%;
    background: var(--accent);
    width: 100%;
    border-radius: 999px;
    -moz-transition: width 0.25s linear;
    -o-transition: width 0.25s linear;
    -webkit-transition: width 0.25s linear;
    -ms-transition: width 0.25s linear;
    transition: width 0.25s linear;
}

.bar i.low{
    background: var(--bad);
}

.pips{
    display: flex;
    gap: 3px;
    height: 0.5rem;
}

.pips i{
    flex: 1 1 0;
    border-radius: 3px;
    background: var(--surface-2);
}

.pips i.ok{
    background: var(--good);
}

.pips i.no{
    background: var(--bad);
}

.card{
    position: relative;
    margin: 1rem 0 0.6rem;
    padding: 1.2rem 0.5rem;
    border-radius: 1.4rem;
    background: var(--surface);
    border: 2px solid var(--border-subtle);
    text-align: center;
    min-height: 9rem;
    -moz-box-shadow: 0 8px 24px rgba(0,0,0,0.06);
    -o-box-shadow: 0 8px 24px rgba(0,0,0,0.06);
    -webkit-box-shadow: 0 8px 24px rgba(0,0,0,0.06);
    -ms-box-shadow: 0 8px 24px rgba(0,0,0,0.06);
    box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.card .q{
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    line-height: 1.1;
}

.card .ans{
    font-size: 2.6rem;
    font-weight: 800;
    min-height: 1.2em;
    color: var(--pop);
    font-variant-numeric: tabular-nums;
}

.card .ans:empty::after{
    content: "_";
    color: var(--border);
}

.card .hint{
    font-size: 0.8rem;
    color: var(--muted);
    min-height: 1.2em;
    margin-top: 0.2rem;
}

.card.good{
    border-color: var(--good);
    animation: nb-pop 0.25s;
}

.card.bad{
    border-color: var(--bad);
    animation: nb-shake 0.35s;
}

.card.bad .ans{
    color: var(--bad);
}

.card .fix{
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--good);
}

.card .clue{
    position: absolute;
    right: 0.5rem;
    top: 0.5rem;
    min-height: 0;
    padding: 0.2rem 0.6rem;
    font-size: 0.85rem;
    border-radius: 999px;
    background: var(--surface-2);
    opacity: 0.85;
}

.card .clue[hidden]{
    display: none;
}

.card .say{
    position: absolute;
    left: 0.5rem;
    top: 0.5rem;
    min-height: 0;
    padding: 0.2rem 0.6rem;
    font-size: 1.1rem;
    border-radius: 999px;
    background: var(--surface-2);
    opacity: 0.85;
}

.card .say[hidden]{
    display: none;
}

.card .clue-text{
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--pop);
}

.card .next{
    display: block;
    margin: 0.6rem auto 0;
    min-height: 0;
    padding: 0.35rem 1.1rem;
    font-weight: 700;
    border-radius: 999px;
    background: var(--surface-2);
}

.card .next[hidden]{
    display: none;
}

.card .offer{
    display: flex;
    gap: 0.6rem;
    justify-content: center;
    margin-top: 0.6rem;
}

.card .offer[hidden]{
    display: none;
}

.card .offer button{
    min-height: 0;
    padding: 0.45rem 1.1rem;
    font-weight: 700;
    border-radius: 999px;
    background: var(--surface-2);
}

.card .offer .again{
    background: var(--pop);
    color: #fff;
}

.card .extra .face{
    margin: 0.2rem 0.6rem;
}

.card .extra:has(.face){
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.face .dial{
    fill: var(--surface);
    stroke: var(--text);
    stroke-width: 2;
}

.face .tick{
    stroke: var(--muted);
    stroke-width: 1;
}

.face .tick.big{
    stroke: var(--text);
    stroke-width: 2;
}

.face .num{
    font-size: 9px;
    font-weight: 700;
    fill: var(--text);
    font-family: inherit;
}

.face .hand{
    stroke: var(--text);
    stroke-linecap: round;
}

.face .hand.hour{
    stroke-width: 4.5;
}

.face .hand.minute{
    stroke-width: 2.5;
    stroke: var(--pop);
}

.face .pin{
    fill: var(--pop);
}

.choices button .face{
    display: block;
    margin: 0.2rem auto 0;
}

.choices button.good .face .dial, .choices button.bad .face .dial{
    fill: #fff;
}

.card .extra .pie{
    margin: 0.2rem 0.6rem;
}

.card .extra:has(.pie){
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

.pie .slice{
    fill: var(--surface);
    stroke: var(--text);
    stroke-width: 2;
    stroke-linejoin: round;
}

.pie .slice.on{
    fill: var(--pop);
}

.pie .rim{
    fill: none;
    stroke: var(--text);
    stroke-width: 2.5;
}

.choices button .pie{
    display: block;
    margin: 0.2rem auto 0;
}

.choices button .pie + small{
    font-size: 1rem;
    font-weight: 700;
    opacity: 1;
}

.choices button.good .pie .slice, .choices button.bad .pie .slice{
    fill: #fff;
    stroke: #fff;
}

.choices button.good .pie .slice.on, .choices button.bad .pie .slice.on{
    fill: rgba(0,0,0,0.35);
}

.choices button.good .pie .rim, .choices button.bad .pie .rim{
    stroke: #fff;
}

.purse{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.3rem;
    max-width: 22rem;
    margin: 0 auto;
}

.card .extra .purse{
    margin-bottom: 0.3rem;
}

.coin, .bill{
    display: block;
    -moz-filter: drop-shadow(0 1px 1.5px rgba(0,0,0,0.35));
    -o-filter: drop-shadow(0 1px 1.5px rgba(0,0,0,0.35));
    -webkit-filter: drop-shadow(0 1px 1.5px rgba(0,0,0,0.35));
    -ms-filter: drop-shadow(0 1px 1.5px rgba(0,0,0,0.35));
    filter: drop-shadow(0 1px 1.5px rgba(0,0,0,0.35));
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.coin{
    border-radius: 50%;
}

.bill{
    border-radius: 2px;
}

.choices button .purse{
    max-width: 100%;
    gap: 0.15rem;
    margin: 0.2rem auto;
}

.card .extra:has(.puzzle){
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin: 1.6rem 0 0.3rem;
}

.choices button .puzzle{
    display: block;
    margin: 0.2rem auto 0;
    max-width: 100%;
}

.choices button .puzzle + small{
    font-size: 1rem;
    font-weight: 700;
    opacity: 1;
}

table.machine, table.chart{
    border-collapse: collapse;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto;
    font-variant-numeric: tabular-nums;
}

table.machine th, table.chart th{
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted);
    padding: 0 0.6rem;
}

table.machine td{
    padding: 0.1rem 0.7rem;
    text-align: center;
}

table.machine td.gear{
    font-size: 1rem;
    font-weight: 400;
    color: var(--muted);
    white-space: nowrap;
}

table.machine td.ask{
    color: var(--pop);
}

table.chart td{
    border: 2px solid var(--text);
    padding: 0.2rem 0.9rem;
    text-align: center;
}

.blocks rect{
    stroke: var(--text);
    stroke-width: 0.12;
}

.blocks .flat rect{
    fill: #f6c35b;
}

.blocks .rod rect{
    fill: #7db8f0;
}

.blocks .cube{
    fill: #f28c6b;
}

.blocks line{
    stroke: var(--text);
    stroke-width: 0.05;
    opacity: 0.5;
}

.numline .axis, .numline .tick{
    stroke: var(--text);
    stroke-width: 0.6;
    stroke-linecap: round;
}

.numline .tick.half{
    stroke-width: 0.8;
}

.numline text{
    font-size: 6px;
    font-weight: 700;
    fill: var(--text);
    font-family: inherit;
}

.numline .at{
    fill: var(--pop);
}

.numline .mark{
    fill: var(--pop);
}

.plot .bed{
    fill: #8fd17f;
}

.plot .bed.square{
    stroke: #3f7d36;
    stroke-width: 0.05;
}

.plot .fence{
    fill: none;
    stroke: #8b5a2b;
    stroke-width: 0.18;
    stroke-linejoin: round;
}

.plot .side{
    font-size: 0.9px;
    font-weight: 700;
    fill: var(--text);
    font-family: inherit;
}

.choices button.good .puzzle, .choices button.bad .puzzle{
    opacity: 0.85;
}

@keyframes nb-pop{
    from{
        -moz-transform: scale(1);
        -o-transform: scale(1);
        -webkit-transform: scale(1);
        -ms-transform: scale(1);
        transform: scale(1);
    }
    50%{
        -moz-transform: scale(1.04);
        -o-transform: scale(1.04);
        -webkit-transform: scale(1.04);
        -ms-transform: scale(1.04);
        transform: scale(1.04);
    }
    to{
        -moz-transform: scale(1);
        -o-transform: scale(1);
        -webkit-transform: scale(1);
        -ms-transform: scale(1);
        transform: scale(1);
    }
}

@keyframes nb-shake{
    0%, 100%{
        -moz-transform: translateX(0);
        -o-transform: translateX(0);
        -webkit-transform: translateX(0);
        -ms-transform: translateX(0);
        transform: translateX(0);
    }
    25%{
        -moz-transform: translateX(-8px);
        -o-transform: translateX(-8px);
        -webkit-transform: translateX(-8px);
        -ms-transform: translateX(-8px);
        transform: translateX(-8px);
    }
    75%{
        -moz-transform: translateX(8px);
        -o-transform: translateX(8px);
        -webkit-transform: translateX(8px);
        -ms-transform: translateX(8px);
        transform: translateX(8px);
    }
}

.game.geo .card{
    min-height: 4.5rem;
    padding: 0.8rem 0.5rem;
    margin-bottom: 0.5rem;
}

.game.geo .card .q{
    font-size: 1.8rem;
}

.game.geo .card .ans{
    display: none;
}

.map{
    position: relative;
    border-radius: 1rem;
    background: var(--surface-2);
    padding: 0.3rem;
    margin: 0 0 0.6rem;
}

.map svg{
    display: block;
    width: 100%;
    height: auto;
}

.map g.state path{
    fill: #cbd5e1;
    stroke: #fff;
    stroke-width: 1;
    -moz-transition: fill 0.15s;
    -o-transition: fill 0.15s;
    -webkit-transition: fill 0.15s;
    -ms-transition: fill 0.15s;
    transition: fill 0.15s;
}

.map.tappable g.state path{
    cursor: pointer;
}

.map.tappable g.state path:hover{
    fill: #a9b8cb;
}

.map g.state path.dot{
    fill: #94a3b8;
}

.map.tappable g.state path.dot:hover{
    fill: #7c8ca1;
}

.map g.state path.target{
    fill: var(--pop);
}

.map g.state path.good{
    fill: var(--good);
}

.map g.state path.bad{
    fill: var(--bad);
}

.map g.state path.dot.target, .map g.state path.dot.good, .map g.state path.dot.bad{
    stroke-width: 30;
    stroke-opacity: 0.4;
    paint-order: stroke;
}

.map g.state path.dot.target{
    stroke: var(--pop);
    animation: nb-beacon 1.4s ease-in-out infinite;
}

.map g.state path.dot.good{
    stroke: var(--good);
}

.map g.state path.dot.bad{
    stroke: var(--bad);
}

@keyframes nb-beacon{
    from, to{
        stroke-width: 18;
    }
    50%{
        stroke-width: 44;
    }
}

@media (prefers-reduced-motion: reduce){
    .map g.state path.dot.target{
        animation: none;
    }
}

.map g.outside path{
    fill: #e2e8f0;
    stroke: #fff;
    stroke-width: 1;
    pointer-events: none;
}

.card .q .flag{
    display: block;
    width: min(100%, 13rem);
    aspect-ratio: 4 / 3;
    margin: 0 auto 0.4rem;
    border-radius: 0.5rem;
    -moz-box-shadow: 0 0 0 1px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
    -o-box-shadow: 0 0 0 1px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
    -webkit-box-shadow: 0 0 0 1px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
    -ms-box-shadow: 0 0 0 1px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
    box-shadow: 0 0 0 1px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.15);
}

.card .q .words{
    display: block;
}

.choices.flags button{
    padding: 0.5rem 0.6rem 0.3rem;
}

.choices button .flag{
    display: block;
    width: 100%;
    max-width: 9rem;
    aspect-ratio: 4 / 3;
    margin: 0 auto;
    border-radius: 0.3rem;
    -moz-box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
    -o-box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
    -webkit-box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
    -ms-box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
    box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
}

.choices button.good .flag, .choices button.bad .flag{
    -moz-box-shadow: 0 0 0 2px #fff;
    -o-box-shadow: 0 0 0 2px #fff;
    -webkit-box-shadow: 0 0 0 2px #fff;
    -ms-box-shadow: 0 0 0 2px #fff;
    box-shadow: 0 0 0 2px #fff;
}

.map .zooms{
    position: absolute;
    right: 0.5rem;
    top: 0.5rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.3rem;
    max-width: 60%;
}

.map .zoom{
    min-height: 0;
    padding: 0.2rem 0.6rem;
    font-size: 0.85rem;
    border-radius: 999px;
    background: var(--surface);
    opacity: 0.85;
}

.game.reading .card{
    min-height: 7rem;
    padding: 1.1rem 1rem;
    margin-bottom: 0.6rem;
}

.game.reading .card .q{
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.45;
    letter-spacing: normal;
    text-wrap: pretty;
}

.game.reading .card .ans{
    display: none;
}

.game.reading .card .hint{
    min-height: 1.4em;
}

.game.reading .card .fix{
    display: block;
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.45;
    color: var(--text);
}

.card .fix b{
    color: var(--good);
}

.card .gap{
    display: inline-block;
    min-width: 3.5rem;
    border-bottom: 0.2rem solid var(--pop);
    vertical-align: baseline;
}

.game.reading .choices button{
    font-size: 1.25rem;
    min-height: 3.6rem;
}

.game.language .card{
    min-height: 6rem;
    padding: 1rem 1rem 0.8rem;
    margin-bottom: 0.6rem;
}

.game.language .card .ask, .game.today .card .ask{
    font-size: 0.85rem;
    color: var(--muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.2rem;
}

.game.language .card .q{
    font-size: clamp(1.6rem, 8vw, 2.4rem);
    letter-spacing: normal;
    line-height: 1.2;
}

.game.language .card .ans{
    display: none;
}

.game.language .card .fix{
    font-size: 1.3rem;
}

.game.language .choices button{
    font-size: 1.25rem;
    min-height: 3.6rem;
}

.choices{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin: 0 auto;
}

.choices button{
    font-size: 1.1rem;
    font-weight: 700;
    min-height: 3.4rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    touch-action: manipulation;
    padding: 0.4rem 0.6rem;
}

.choices button:active{
    background: var(--surface-3);
    -moz-transform: translateY(2px);
    -o-transform: translateY(2px);
    -webkit-transform: translateY(2px);
    -ms-transform: translateY(2px);
    transform: translateY(2px);
}

.choices button.good{
    background: var(--good);
    color: #fff;
    border-color: var(--good);
}

.choices button.bad{
    background: var(--bad);
    color: #fff;
    border-color: var(--bad);
}

.choices button small{
    display: block;
    font-size: 0.7rem;
    font-weight: 400;
    opacity: 0.6;
}

.mastery.geo .row{
    grid-template-columns: 7.6rem 4.2rem 1fr;
}

.mastery.geo .t{
    font-size: 0.85rem;
    text-align: left;
}

.mastery.geo .heat{
    grid-auto-columns: minmax(0, 1.4rem);
    justify-content: start;
}

.pad{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    max-width: 22rem;
    margin: 0 auto;
}

.pad button{
    font-size: 1.7rem;
    font-weight: 700;
    min-height: 3.6rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 1px solid var(--border-subtle);
    touch-action: manipulation;
}

.pad button:active{
    background: var(--surface-3);
    -moz-transform: translateY(2px);
    -o-transform: translateY(2px);
    -webkit-transform: translateY(2px);
    -ms-transform: translateY(2px);
    transform: translateY(2px);
}

.pad button.go{
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.pad button.del{
    font-size: 1.3rem;
}

.float{
    position: absolute;
    right: 0.9rem;
    top: 0.5rem;
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--good);
    pointer-events: none;
    animation: nb-float 0.8s forwards;
}

.float.bonus{
    color: var(--pop);
}

@keyframes nb-float{
    from{
        opacity: 1;
        -moz-transform: translateY(0);
        -o-transform: translateY(0);
        -webkit-transform: translateY(0);
        -ms-transform: translateY(0);
        transform: translateY(0);
    }
    to{
        opacity: 0;
        -moz-transform: translateY(-2.5rem);
        -o-transform: translateY(-2.5rem);
        -webkit-transform: translateY(-2.5rem);
        -ms-transform: translateY(-2.5rem);
        transform: translateY(-2.5rem);
    }
}

.toast{
    position: fixed;
    left: 50%;
    top: 0.5rem;
    -moz-transform: translateX(-50%) scale(0.6);
    -o-transform: translateX(-50%) scale(0.6);
    -webkit-transform: translateX(-50%) scale(0.6);
    -ms-transform: translateX(-50%) scale(0.6);
    transform: translateX(-50%) scale(0.6);
    padding: 0.5rem 1.2rem;
    border-radius: 999px;
    background: var(--pop);
    color: #fff;
    font-weight: 800;
    font-size: 1.3rem;
    opacity: 0;
    pointer-events: none;
    -moz-transition: all 0.25s;
    -o-transition: all 0.25s;
    -webkit-transition: all 0.25s;
    -ms-transition: all 0.25s;
    transition: all 0.25s;
    z-index: 5;
}

.toast.on{
    opacity: 1;
    -moz-transform: translateX(-50%) scale(1);
    -o-transform: translateX(-50%) scale(1);
    -webkit-transform: translateX(-50%) scale(1);
    -ms-transform: translateX(-50%) scale(1);
    transform: translateX(-50%) scale(1);
}

.confetti{
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 4;
}

.confetti i{
    position: absolute;
    top: -1rem;
    width: 0.6rem;
    height: 0.9rem;
    border-radius: 2px;
    animation: nb-fall 1.6s ease-in forwards;
}

@keyframes nb-fall{
    to{
        -moz-transform: translateY(110vh) rotate(720deg);
        -o-transform: translateY(110vh) rotate(720deg);
        -webkit-transform: translateY(110vh) rotate(720deg);
        -ms-transform: translateY(110vh) rotate(720deg);
        transform: translateY(110vh) rotate(720deg);
        opacity: 0.6;
    }
}

.screen{
    text-align: center;
    padding: 1rem 0;
}

.screen p.muted{
    color: var(--text);
    opacity: 0.8;
}

.screen .big{
    font-size: 3.4rem;
    font-weight: 800;
    line-height: 1;
    color: var(--accent);
    margin: 0.4rem 0;
}

.screen .pb{
    display: inline-block;
    background: var(--gold);
    color: #5a3d00;
    font-weight: 800;
    padding: 0.2rem 0.8rem;
    border-radius: 999px;
    margin: 0.3rem 0;
}

.screen .stats{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: 1rem 0;
}

.screen .stats div{
    background: var(--surface-2);
    border-radius: 0.8rem;
    padding: 0.5rem;
}

.screen .stats b{
    display: block;
    font-size: 1.4rem;
}

.screen .stats small{
    color: var(--muted);
    font-size: 0.7rem;
}

.screen .levelup{
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--pop);
}

.screen .earned{
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin: 0.6rem 0;
}

.screen .earned .award{
    width: auto;
    min-width: 6rem;
    animation: nb-pop 0.6s;
}

.screen .weak{
    color: var(--muted);
    font-size: 0.95rem;
}

.screen .missed{
    text-align: left;
    margin: 0.6rem 0;
    padding: 0.5rem 0.8rem;
    border-radius: 0.8rem;
    background: var(--surface-2);
}

.screen .missed summary{
    cursor: pointer;
    font-weight: 700;
}

.screen .missed ul{
    margin: 0.4rem 0 0.2rem;
    padding-left: 1.2rem;
}

.screen .missed li{
    padding: 0.15rem 0;
}

.screen .missed .fix b{
    color: var(--good);
}

.screen .actions{
    display: grid;
    gap: 0.6rem;
    margin-top: 1.2rem;
}

.screen .actions a.secondary{
    display: block;
    text-align: center;
    padding: 0.7rem;
    border-radius: 1rem;
    border: 2px solid var(--border-subtle);
    text-decoration: none;
    color: var(--text);
    font-weight: 700;
}

.screen .actions a.fix{
    background: var(--pop);
    -moz-box-shadow: 0 6px 0 #4c2bb3;
    -o-box-shadow: 0 6px 0 #4c2bb3;
    -webkit-box-shadow: 0 6px 0 #4c2bb3;
    -ms-box-shadow: 0 6px 0 #4c2bb3;
    box-shadow: 0 6px 0 #4c2bb3;
}

.screen .actions a.fix:hover{
    background: #8f66ff;
}

.screen .actions a.fix:active{
    -moz-box-shadow: 0 2px 0 #4c2bb3;
    -o-box-shadow: 0 2px 0 #4c2bb3;
    -webkit-box-shadow: 0 2px 0 #4c2bb3;
    -ms-box-shadow: 0 2px 0 #4c2bb3;
    box-shadow: 0 2px 0 #4c2bb3;
}

.screen .actions a.fix small{
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 0.85;
}

.screen .fixed{
    display: inline-block;
    background: var(--pop);
    color: #fff;
    font-weight: 800;
    padding: 0.2rem 0.8rem;
    border-radius: 999px;
    margin: 0.3rem 0;
}

.game .clock.phase{
    color: var(--pop);
}

.game.review .card{
    border-color: var(--pop);
}

.flawless{
    position: fixed;
    inset: 0;
    z-index: 6;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    overflow: hidden;
    pointer-events: none;
    text-align: center;
    background: radial-gradient(circle at 50% 42%, rgba(245,179,1,0.75), rgba(28,12,54,0.94) 68%);
    animation: nb-fade-in 0.3s both, nb-fade-out 0.6s 2.4s forwards;
}

.flawless .rays{
    position: absolute;
    left: 50%;
    top: 42%;
    width: 200vmax;
    height: 200vmax;
    margin: -100vmax 0 0 -100vmax;
    border-radius: 50%;
    background: repeating-conic-gradient(from 0deg, rgba(255,255,255,0.10) 0 9deg, transparent 9deg 24deg);
    animation: nb-spin 14s linear infinite;
}

.flawless .gem{
    position: relative;
    font-size: 5rem;
    line-height: 1;
    -moz-filter: drop-shadow(0 0 18px rgba(255,255,255,0.8));
    -o-filter: drop-shadow(0 0 18px rgba(255,255,255,0.8));
    -webkit-filter: drop-shadow(0 0 18px rgba(255,255,255,0.8));
    -ms-filter: drop-shadow(0 0 18px rgba(255,255,255,0.8));
    filter: drop-shadow(0 0 18px rgba(255,255,255,0.8));
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.flawless .word{
    position: relative;
    display: flex;
    gap: 0.04em;
    font-weight: 900;
    font-size: clamp(2.4rem, 13vw, 5.2rem);
    letter-spacing: 0.06em;
    color: #fff;
    text-shadow: 0 0 24px var(--gold), 0 5px 0 #b45309;
}

.flawless .word span{
    display: inline-block;
    animation: nb-letter 0.55s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.flawless .sub{
    position: relative;
    color: var(--gold);
    font-weight: 800;
    font-size: 1.3rem;
    animation: nb-letter 0.5s 1.1s both;
}

.flawless .sparks{
    position: absolute;
    left: 0;
    top: 0;
    width: 0;
    height: 0;
}

.flawless .sparks i{
    position: absolute;
    left: -0.25rem;
    top: -0.25rem;
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    animation: nb-spark 0.9s ease-out forwards;
}

@keyframes nb-fade-in{
    from{
        opacity: 0;
    }
    to{
        opacity: 1;
    }
}

@keyframes nb-fade-out{
    to{
        opacity: 0;
    }
}

@keyframes nb-spin{
    to{
        -moz-transform: rotate(360deg);
        -o-transform: rotate(360deg);
        -webkit-transform: rotate(360deg);
        -ms-transform: rotate(360deg);
        transform: rotate(360deg);
    }
}

@keyframes nb-gem{
    from{
        -moz-transform: scale(0) rotate(-40deg);
        -o-transform: scale(0) rotate(-40deg);
        -webkit-transform: scale(0) rotate(-40deg);
        -ms-transform: scale(0) rotate(-40deg);
        transform: scale(0) rotate(-40deg);
    }
    to{
        -moz-transform: scale(1) rotate(0);
        -o-transform: scale(1) rotate(0);
        -webkit-transform: scale(1) rotate(0);
        -ms-transform: scale(1) rotate(0);
        transform: scale(1) rotate(0);
    }
}

@keyframes nb-letter{
    from{
        opacity: 0;
        -moz-transform: translateY(1.2em) scale(0.4) rotate(-12deg);
        -o-transform: translateY(1.2em) scale(0.4) rotate(-12deg);
        -webkit-transform: translateY(1.2em) scale(0.4) rotate(-12deg);
        -ms-transform: translateY(1.2em) scale(0.4) rotate(-12deg);
        transform: translateY(1.2em) scale(0.4) rotate(-12deg);
    }
    to{
        opacity: 1;
        -moz-transform: none;
        -o-transform: none;
        -webkit-transform: none;
        -ms-transform: none;
        transform: none;
    }
}

@keyframes nb-spark{
    to{
        -moz-transform: translate(var(--dx), var(--dy)) scale(0.2);
        -o-transform: translate(var(--dx), var(--dy)) scale(0.2);
        -webkit-transform: translate(var(--dx), var(--dy)) scale(0.2);
        -ms-transform: translate(var(--dx), var(--dy)) scale(0.2);
        transform: translate(var(--dx), var(--dy)) scale(0.2);
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce){
    .flawless .rays, .flawless .sparks{
        display: none;
    }
    .flawless .word span, .flawless .gem, .flawless .sub{
        animation-duration: 0.01s;
        animation-delay: 0s;
    }
}

.badge-show{
    position: fixed;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow: hidden;
    background: radial-gradient(circle at 50% 45%, rgba(124,77,255,0.55), rgba(28,12,54,0.92) 70%);
    animation: nb-fade-in 0.25s both;
}

.badge-show.leaving{
    animation: nb-fade-out 0.25s forwards;
}

.badge-show .rays{
    position: absolute;
    left: 50%;
    top: 45%;
    width: 200vmax;
    height: 200vmax;
    margin: -100vmax 0 0 -100vmax;
    border-radius: 50%;
    pointer-events: none;
    background: repeating-conic-gradient(from 0deg, rgba(255,255,255,0.09) 0 9deg, transparent 9deg 24deg);
    animation: nb-spin 18s linear infinite;
}

.badge-show .card{
    position: relative;
    width: min(22rem, 100%);
    padding: 1.4rem 1.2rem 1.2rem;
    border-radius: 1.6rem;
    text-align: center;
    background: var(--surface);
    border: 3px solid var(--gold);
    -moz-box-shadow: 0 0 0 6px rgba(245,179,1,0.25), 0 20px 50px rgba(0,0,0,0.4);
    -o-box-shadow: 0 0 0 6px rgba(245,179,1,0.25), 0 20px 50px rgba(0,0,0,0.4);
    -webkit-box-shadow: 0 0 0 6px rgba(245,179,1,0.25), 0 20px 50px rgba(0,0,0,0.4);
    -ms-box-shadow: 0 0 0 6px rgba(245,179,1,0.25), 0 20px 50px rgba(0,0,0,0.4);
    box-shadow: 0 0 0 6px rgba(245,179,1,0.25), 0 20px 50px rgba(0,0,0,0.4);
    animation: nb-gem 0.5s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.badge-show .kicker{
    margin: 0;
    color: var(--pop);
    font-weight: 900;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.badge-show .kicker small{
    color: var(--muted);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0;
    text-transform: none;
}

.badge-show .icon{
    font-size: 5.5rem;
    line-height: 1.15;
    margin: 0.4rem 0 0.2rem;
    -moz-filter: drop-shadow(0 0 14px rgba(245,179,1,0.7));
    -o-filter: drop-shadow(0 0 14px rgba(245,179,1,0.7));
    -webkit-filter: drop-shadow(0 0 14px rgba(245,179,1,0.7));
    -ms-filter: drop-shadow(0 0 14px rgba(245,179,1,0.7));
    filter: drop-shadow(0 0 14px rgba(245,179,1,0.7));
    animation: nb-gem 0.7s 0.15s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.badge-show h2{
    margin: 0.2rem 0;
    color: var(--text);
    font-size: 1.7rem;
    text-transform: none;
    letter-spacing: -0.01em;
}

.badge-show .what{
    margin: 0.2rem 0 0.8rem;
    font-size: 1.1rem;
}

.badge-show .parts{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.3rem 0.6rem;
    margin: 0 0 0.9rem;
    padding: 0.5rem;
    border-radius: 0.9rem;
    background: var(--surface-2);
}

.badge-show .parts small{
    flex: 1 0 100%;
    color: var(--muted);
}

.badge-show button{
    width: 100%;
}

.badge-show .burst{
    position: absolute;
    left: 50%;
    top: 40%;
    width: 0;
    height: 0;
    pointer-events: none;
}

.badge-show .burst i{
    position: absolute;
    left: -0.3rem;
    top: -0.3rem;
    width: 0.6rem;
    height: 0.6rem;
    border-radius: 50%;
    animation: nb-spark 1s ease-out forwards;
}

@media (prefers-reduced-motion: reduce){
    .badge-show .rays{
        display: none;
    }
    .badge-show, .badge-show .card, .badge-show .icon{
        animation-duration: 0.01s;
        animation-delay: 0s;
    }
}

.munch .lives{
    margin-left: auto;
    font-size: 1.05rem;
    letter-spacing: 0.08em;
}

.munch .rule{
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.7rem;
    margin: 0.3rem 0 0.6rem;
    padding: 0.45rem 0.8rem;
    border-radius: 1rem;
    background: var(--pop);
    color: #fff;
}

.munch .rule b{
    font-size: 1.6rem;
    font-weight: 800;
}

.munch .rule small{
    font-size: 0.85rem;
    opacity: 0.85;
    white-space: nowrap;
}

.board{
    position: relative;
    display: grid;
    grid-template-columns: repeat(var(--cols), 1fr);
    grid-template-rows: repeat(var(--rows), 1fr);
    aspect-ratio: var(--cols) / var(--rows);
    overflow: hidden;
    border-radius: 1rem;
    border: 2px solid var(--border-subtle);
    background: var(--surface);
    touch-action: manipulation;
}

.board.caught{
    animation: nb-shake 0.35s;
}

.board .cell{
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    border: 1px solid var(--border-subtle);
    background: var(--surface-2);
    font-weight: 800;
    font-size: clamp(0.78rem, 3.7vw, 1.35rem);
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    cursor: pointer;
    -moz-transition: background 0.15s;
    -o-transition: background 0.15s;
    -webkit-transition: background 0.15s;
    -ms-transition: background 0.15s;
    transition: background 0.15s;
}

.board .cell.eaten{
    background: var(--surface);
}

.board .cell.bad{
    background: var(--bad);
    color: #fff;
    animation: nb-shake 0.35s;
}

.board .sprite{
    position: absolute;
    left: 0;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: calc(100% / var(--cols));
    height: calc(100% / var(--rows));
    pointer-events: none;
    -moz-transition: transform 0.12s ease-out;
    -o-transition: transform 0.12s ease-out;
    -webkit-transition: transform 0.12s ease-out;
    -ms-transition: transform 0.12s ease-out;
    transition: transform 0.12s ease-out;
}

.board .me{
    z-index: 2;
    box-sizing: border-box;
    border: 3px solid var(--accent);
    border-radius: 0.6rem;
    -moz-box-shadow: 0 0 0 2px rgba(255,122,26,0.25);
    -o-box-shadow: 0 0 0 2px rgba(255,122,26,0.25);
    -webkit-box-shadow: 0 0 0 2px rgba(255,122,26,0.25);
    -ms-box-shadow: 0 0 0 2px rgba(255,122,26,0.25);
    box-shadow: 0 0 0 2px rgba(255,122,26,0.25);
}

.board .me .face{
    position: absolute;
    left: -0.35rem;
    top: -0.45rem;
    width: clamp(1.3rem, 6vw, 1.9rem);
    line-height: 1;
}

.board .me .face svg{
    -moz-box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    -o-box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    -webkit-box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    -ms-box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.board .me.chomp .face{
    animation: nb-chomp 0.22s;
}

.board .me.hurt{
    animation: nb-blink 0.25s 6;
}

.board .troggle{
    z-index: 3;
    font-size: clamp(1.4rem, 7vw, 2.3rem);
    -moz-transition: transform 0.3s linear, opacity 0.3s;
    -o-transition: transform 0.3s linear, opacity 0.3s;
    -webkit-transition: transform 0.3s linear, opacity 0.3s;
    -ms-transition: transform 0.3s linear, opacity 0.3s;
    transition: transform 0.3s linear, opacity 0.3s;
}

.board .troggle.arriving{
    opacity: 0.4;
}

.board .float{
    right: auto;
    text-align: center;
    z-index: 4;
}

.munch .why, .hop .why{
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.3rem 0.8rem;
    min-height: 3rem;
    padding: 0.4rem 0;
    text-align: center;
    font-weight: 700;
    font-size: 1.1rem;
}

.munch .why.good, .hop .why.good{
    color: var(--good);
}

.munch .why.bad, .hop .why.bad{
    color: var(--bad);
}

.munch .why .next, .hop .why .next{
    min-height: 0;
    padding: 0.35rem 1.1rem;
    font-weight: 700;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--text);
}

.munch .why .next[hidden], .hop .why .next[hidden]{
    display: none;
}

@keyframes nb-chomp{
    50%{
        -moz-transform: scale(1.5) rotate(-10deg);
        -o-transform: scale(1.5) rotate(-10deg);
        -webkit-transform: scale(1.5) rotate(-10deg);
        -ms-transform: scale(1.5) rotate(-10deg);
        transform: scale(1.5) rotate(-10deg);
    }
}

.hop .trip{
    margin-left: auto;
    font-weight: 700;
    color: var(--muted);
}

.game.hop .card{
    min-height: 0;
    padding: 0.6rem 0.8rem;
    margin: 0.3rem 0 0.5rem;
}

.hop .leg{
    display: flex;
    align-items: baseline;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.1rem 0.6rem;
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.2;
}

.hop .leg .from{
    color: var(--pop);
}

.hop .leg .to{
    color: #0284c7;
}

.hop .leg .arrow{
    color: var(--muted);
}

.hop .steps{
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 0.45rem;
}

.hop .steps .pips{
    flex: 1 1 auto;
}

.hop .pips i.spare{
    opacity: 0.4;
}

.hop .pips i.spare.ok, .hop .pips i.spare.no{
    opacity: 1;
}

.hop .steps .par{
    white-space: nowrap;
    color: var(--muted);
    font-weight: 700;
}

.hop .map svg{
    max-height: 56vh;
}

.hop .map g.state path.home{
    fill: var(--pop);
}

.hop .map g.state path.asking{
    fill: var(--accent);
}

.hop .map g.state path.on{
    fill: var(--good);
}

.hop .map g.state path.missed{
    fill: var(--gold);
}

.hop .map g.state path.route{
    fill: #c4b5fd;
}

.hop .map g.state path.goal{
    fill: #0ea5e9;
    animation: nb-goal 0.9s ease-in-out 3;
}

.hop .map g.state path.nope{
    animation: nb-nope 0.4s;
}

.hop .map g.labels text{
    text-anchor: middle;
    font-weight: 800;
    fill: #1e293b;
    paint-order: stroke;
    stroke: #fff;
    stroke-linejoin: round;
    pointer-events: none;
}

.hop .why{
    min-height: 2.4rem;
    padding: 0.2rem 0;
    font-size: 1rem;
}

.hop .choices{
    min-height: 7.3rem;
    align-content: start;
}

.hop .hints{
    text-align: center;
    margin-top: 0.4rem;
}

.hop .hint{
    min-height: 0;
    padding: 0.3rem 0.9rem;
    font-size: 0.9rem;
    border-radius: 999px;
}

.hop .hint[hidden]{
    display: none;
}

@keyframes nb-goal{
    50%{
        opacity: 0.35;
    }
}

@keyframes nb-nope{
    50%{
        fill: var(--bad);
    }
}

@keyframes nb-blink{
    50%{
        opacity: 0.2;
    }
}

@media (prefers-reduced-motion: reduce){
    .board .sprite{
        -moz-transition: none;
        -o-transition: none;
        -webkit-transition: none;
        -ms-transition: none;
        transition: none;
    }
}

.game.trick .card .q, .lesson .card .q{
    font-size: clamp(1.5rem, 8vw, 2.5rem);
}

.card .ans[hidden]{
    display: none;
}

.steps{
    list-style: none;
    padding: 0;
    margin: 0.6rem auto 0.2rem;
    max-width: 22rem;
    text-align: left;
}

.steps:empty{
    display: none;
}

.steps li{
    display: grid;
    grid-template-columns: auto auto 1fr;
    align-items: baseline;
    gap: 0.5rem;
    padding: 0.25rem 0.6rem;
    border-radius: 0.6rem;
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--muted);
}

.steps li .value{
    font-variant-numeric: tabular-nums;
    color: var(--text);
}

.steps li .note{
    grid-column: 1 / -1;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--muted);
}

.steps li.now{
    color: var(--text);
    background: var(--surface-2);
    -moz-box-shadow: inset 0 0 0 2px var(--pop);
    -o-box-shadow: inset 0 0 0 2px var(--pop);
    -webkit-box-shadow: inset 0 0 0 2px var(--pop);
    -ms-box-shadow: inset 0 0 0 2px var(--pop);
    box-shadow: inset 0 0 0 2px var(--pop);
}

.steps li.now .value:empty::after{
    content: "?";
    color: var(--border);
}

.steps li.done .value{
    color: var(--good);
}

.steps li.bad .value{
    color: var(--bad);
}

.choices[hidden], .pad[hidden]{
    display: none;
}

.choices.many{
    grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr));
}

.card .fix .why{
    display: block;
    font-size: 0.9rem;
    color: var(--bad);
}

.card .extra:empty{
    display: none;
}

.card .extra{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.3rem;
    font-size: 1.6rem;
}

.card .rival{
    flex: 0 1 12rem;
    height: 0.6rem;
    border-radius: 999px;
    background: var(--surface-2);
    overflow: hidden;
}

.card .rival i{
    display: block;
    height: 100%;
    width: 0;
    background: #64748b;
    -moz-transition-property: width;
    -o-transition-property: width;
    -webkit-transition-property: width;
    -ms-transition-property: width;
    transition-property: width;
    -moz-transition-timing-function: linear;
    -o-transition-timing-function: linear;
    -webkit-transition-timing-function: linear;
    -ms-transition-timing-function: linear;
    transition-timing-function: linear;
}

.card .date{
    display: block;
}

.card .event{
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: var(--muted);
    margin-top: 0.3rem;
    letter-spacing: 0;
}

.card .word{
    display: inline-block;
    margin: 0.15rem;
    padding: 0.1rem 0.5rem;
    border-radius: 0.5rem;
    background: var(--surface-2);
    font-size: clamp(1.1rem, 6vw, 1.8rem);
}

.munch.statements .board .cell, .munch.fib .board .cell{
    white-space: normal;
    text-align: center;
    padding: 0.2rem;
    line-height: 1.2;
    font-size: clamp(0.72rem, 3.3vw, 1.05rem);
}

.munch.statements .board, .munch.fib .board{
    aspect-ratio: auto;
}

.munch.statements .board .cell, .munch.fib .board .cell{
    min-height: 3.6rem;
}

.lesson-words{
    text-align: left;
}

.lesson-words .icon{
    font-size: 3rem;
    text-align: center;
}

.lesson-words h1, .lesson-words .level{
    text-align: center;
}

.lesson-words .level{
    color: var(--pop);
    font-weight: 800;
    margin-top: 0;
}

.lesson-words p{
    font-size: 1.08rem;
    line-height: 1.5;
}

.lesson .mode{
    margin: 0.5rem 0 0;
    text-align: center;
}

.lesson .card .clue{
    position: absolute;
    right: 0.5rem;
    top: 0.5rem;
    min-height: 0;
    padding: 0.2rem 0.6rem;
    font-size: 0.85rem;
    border-radius: 999px;
}

.lesson .card .clue[hidden], .lesson .card .next[hidden]{
    display: none;
}

.mute{
    position: fixed;
    right: 0.8rem;
    bottom: 0.8rem;
    min-height: 0;
    padding: 0.3rem 0.6rem;
    border-radius: 999px;
    font-size: 1rem;
    opacity: 0.7;
}

.routine{
    --r-pop: var(--pop);
    --r-deep: #4c2bb3;
    --r-bg: var(--surface-2);
    --r-card: var(--surface);
    --r-gold: #e8b84a;
    --r-gold-deep: #b8860b;
    --r-frame: var(--r-gold);
    --r-skin: #f4c9a5;
    --r-skin-deep: #d9a079;
    --r-sleeve: var(--r-pop);
    --r-trim: #fff;
    --r-mud: #7c4a1e;
    --r-font: inherit;
    --r-confetti: #ff7a1a, #7c4dff, #22c55e, #f5b301, #38bdf8, #ec4899;
}

.routine.princess{
    --r-pop: #e85d9f;
    --r-deep: #9d174d;
    --r-card: #fffafd;
    --r-bg: linear-gradient(170deg, #ffe3f1 0%, #ead9ff 55%, #ffeedd 100%);
    --r-sleeve: #f9a8d4;
    --r-trim: #fff;
    --r-mud: #7c4a1e;
    --r-font: Georgia, 'Palatino Linotype', 'Book Antiqua', 'Iowan Old Style', serif;
    --r-confetti: #f472b6, #f9a8d4, #fcd34d, #c4b5fd, #ffffff, #fb7185;
}

.routine.pirate{
    --r-pop: #0ea5e9;
    --r-deep: #0c4a6e;
    --r-card: #fffdf7;
    --r-bg: linear-gradient(170deg, #d6f0ff 0%, #bfe3f5 50%, #fde9bf 100%);
    --r-sleeve: #b91c1c;
    --r-trim: #fcd34d;
    --r-mud: #1f2937;
    --r-font: Georgia, 'Palatino Linotype', 'Book Antiqua', 'Iowan Old Style', serif;
    --r-confetti: #0ea5e9, #fcd34d, #ef4444, #ffffff, #22c55e, #f59e0b;
}

.routine.superhero{
    --r-pop: #ef4444;
    --r-deep: #1e3a8a;
    --r-card: #fffdf5;
    --r-bg: linear-gradient(170deg, #dbeafe 0%, #c7d2fe 50%, #fde68a 100%);
    --r-sleeve: #2563eb;
    --r-trim: #fcd34d;
    --r-mud: #4d7c0f;
    --r-font: 'Trebuchet MS', 'Segoe UI', Verdana, sans-serif;
    --r-confetti: #ef4444, #2563eb, #fcd34d, #ffffff, #22c55e, #f97316;
}

.routine .screen h1, .routine .say, .routine .things button, .routine .journey, .routine .sing .spot, .routine .go{
    font-family: var(--r-font);
}

.routine .screen h1{
    color: var(--r-deep);
    font-size: 2rem;
    letter-spacing: 0;
}

.routine .intro .who, .routine .scene .who{
    font-size: 4.2rem;
    line-height: 1.2;
}

.routine .who .art{
    display: block;
    margin: 0 auto;
    object-fit: cover;
    object-position: 50% 15%;
    border: 4px solid var(--r-frame);
    -moz-box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(0,0,0,0.18);
    -o-box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(0,0,0,0.18);
    -webkit-box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(0,0,0,0.18);
    -ms-box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(0,0,0,0.18);
    box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(0,0,0,0.18);
    background: var(--r-card);
}

.routine .intro .who .art{
    width: min(100%, 15rem);
    height: 15rem;
    border-radius: 1.6rem;
}

.routine .scene .who .art{
    width: 5.8rem;
    height: 5.8rem;
    border-radius: 50%;
}

.routine .who .figure{
    position: relative;
    display: block;
    animation: nb-breathe 3.4s ease-in-out infinite;
}

.routine .intro .who .figure{
    animation: nb-gem 0.6s cubic-bezier(0.2, 1.4, 0.4, 1) both, nb-breathe 3.4s ease-in-out 0.6s infinite;
}

.routine .who .figure .pose{
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    margin: 0 auto;
    opacity: 0;
    -moz-transition: opacity 0.05s;
    -o-transition: opacity 0.05s;
    -webkit-transition: opacity 0.05s;
    -ms-transition: opacity 0.05s;
    transition: opacity 0.05s;
}

.routine .who .figure.blink .pose.blink, .routine .who .figure.talk .pose.talk{
    opacity: 1;
}

@keyframes nb-breathe{
    50%{
        -moz-transform: translateY(-3px) rotate(0.6deg);
        -o-transform: translateY(-3px) rotate(0.6deg);
        -webkit-transform: translateY(-3px) rotate(0.6deg);
        -ms-transform: translateY(-3px) rotate(0.6deg);
        transform: translateY(-3px) rotate(0.6deg);
    }
}

.routine .intro .who .film{
    position: relative;
    display: block;
    width: min(100%, 15rem);
    margin: 0 auto;
    animation: nb-gem 0.6s cubic-bezier(0.2, 1.4, 0.4, 1) both;
}

.routine .intro .who .film .play{
    position: absolute;
    left: 50%;
    top: 50%;
    -moz-transform: translate(-50%, -50%);
    -o-transform: translate(-50%, -50%);
    -webkit-transform: translate(-50%, -50%);
    -ms-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);
    width: 4.6rem;
    height: 4.6rem;
    padding: 0;
    border-radius: 50%;
    border: 4px solid #fff;
    background: var(--r-pop);
    color: #fff;
    font-size: 2rem;
    line-height: 1;
    text-indent: 0.2rem;
    cursor: pointer;
    -moz-box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    -o-box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    -webkit-box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    -ms-box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    animation: nb-breathe 3.4s ease-in-out infinite;
    -moz-transition: opacity 0.3s;
    -o-transition: opacity 0.3s;
    -webkit-transition: opacity 0.3s;
    -ms-transition: opacity 0.3s;
    transition: opacity 0.3s;
}

.routine .intro .who .film.playing .play{
    opacity: 0;
    pointer-events: none;
}

.routine .say{
    position: relative;
    margin: 0.6rem auto;
    max-width: 26rem;
    padding: 0.7rem 1rem;
    border-radius: 1.2rem;
    background: var(--r-card);
    color: var(--text);
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.35;
    border: 2px solid rgba(232,184,74,0.55);
    -moz-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -o-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -webkit-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -ms-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    min-height: 2.4em;
}

.routine .intro .say{
    font-size: 1.2rem;
}

.routine .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.routine .scene{
    position: relative;
    overflow: hidden;
    padding: 0.9rem 0.6rem 0.4rem;
    margin: 0.4rem 0;
    border-radius: 1.6rem;
    background: var(--r-bg);
    text-align: center;
    border: 2px solid rgba(232,184,74,0.35);
}

.routine .scene .sky{
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, rgba(255,255,255,0.95) 0 1.5px, transparent 2.5px), radial-gradient(circle, rgba(255,255,255,0.8) 0 1px, transparent 2px), radial-gradient(circle, var(--r-gold) 0 1.2px, transparent 2.2px);
    background-size: 90px 70px, 60px 50px, 120px 90px;
    background-position: 10px 8px, 30px 25px, 50px 40px;
    animation: nb-shimmer 3s ease-in-out infinite alternate;
}

@keyframes nb-shimmer{
    from{
        opacity: 0.45;
    }
    to{
        opacity: 1;
    }
}

.routine .scene > :not(.sky){
    position: relative;
}

.routine .hands{
    position: relative;
    display: flex;
    justify-content: center;
    gap: 0.3rem;
    width: min(100%, 18rem);
    height: 9.5rem;
    margin: 0.4rem auto 0.2rem;
    line-height: 1;
    touch-action: none;
    cursor: pointer;
    border-radius: 1.2rem;
}

.routine .hands .hand{
    display: block;
    height: 100%;
    width: auto;
    overflow: visible;
    -moz-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -o-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -webkit-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -ms-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
}

.routine .hand .skin{
    fill: var(--r-skin);
}

.routine .hand .creases{
    fill: none;
    stroke: var(--r-skin-deep);
    stroke-width: 1.6;
    stroke-linecap: round;
    opacity: 0.6;
}

.routine .hand .sleeve{
    fill: var(--r-sleeve);
}

.routine .hand .sleeve .trim{
    fill: var(--r-trim);
    opacity: 0.9;
}

.routine .stage.wait{
    animation: nb-beckon 1s ease-in-out infinite;
}

.routine .mouth{
    position: relative;
    display: block;
    width: min(100%, 18rem);
    height: 9.5rem;
    margin: 0.4rem auto 0.2rem;
    line-height: 1;
    touch-action: none;
    cursor: pointer;
    border-radius: 1.2rem;
}

.routine .mouth svg.face{
    display: block;
    width: 100%;
    height: 100%;
    overflow: visible;
    -moz-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -o-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -webkit-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    -ms-filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
    filter: drop-shadow(0 4px 4px rgba(0,0,0,0.15));
}

.routine .mouth .lips{
    fill: var(--r-lips);
}

.routine .mouth .inside{
    fill: #5b1f2e;
}

.routine .mouth .tongue{
    fill: #f28ca0;
    stroke: #d9607a;
    stroke-width: 1.5;
}

.routine .mouth .tooth{
    fill: #fffdf5;
    stroke: #d6cfc0;
    stroke-width: 1.5;
    -moz-transition: fill 0.3s, stroke 0.3s;
    -o-transition: fill 0.3s, stroke 0.3s;
    -webkit-transition: fill 0.3s, stroke 0.3s;
    -ms-transition: fill 0.3s, stroke 0.3s;
    transition: fill 0.3s, stroke 0.3s;
}

.routine .mouth .tooth.now, .routine .mouth .tongue.now{
    stroke: var(--r-pop);
    stroke-width: 3;
    animation: nb-glow 0.9s ease-in-out infinite alternate;
}

.routine .mouth .tooth.clean{
    fill: #fff;
}

@keyframes nb-glow{
    from{
        -moz-filter: brightness(1);
        -o-filter: brightness(1);
        -webkit-filter: brightness(1);
        -ms-filter: brightness(1);
        filter: brightness(1);
    }
    to{
        -moz-filter: brightness(1.25);
        -o-filter: brightness(1.25);
        -webkit-filter: brightness(1.25);
        -ms-filter: brightness(1.25);
        filter: brightness(1.25);
    }
}

.routine .mouth .germ{
    width: 1.2rem;
    height: 1.2rem;
    margin: -0.6rem 0 0 -0.6rem;
}

.routine .mouth .germ .mud{
    fill: var(--r-plaque, #e3c25a);
}

.routine .tool{
    position: absolute;
    left: -20%;
    top: 30%;
    width: 3.6rem;
    height: 3.6rem;
    margin: -1.8rem 0 0 -1.8rem;
    font-size: 3rem;
    line-height: 1;
    pointer-events: none;
    -moz-transition: left 0.6s ease-in-out, top 0.6s ease-in-out, opacity 0.4s;
    -o-transition: left 0.6s ease-in-out, top 0.6s ease-in-out, opacity 0.4s;
    -webkit-transition: left 0.6s ease-in-out, top 0.6s ease-in-out, opacity 0.4s;
    -ms-transition: left 0.6s ease-in-out, top 0.6s ease-in-out, opacity 0.4s;
    transition: left 0.6s ease-in-out, top 0.6s ease-in-out, opacity 0.4s;
    z-index: 2;
}

.routine .tool.held{
    left: 8%;
    top: 50%;
}

.routine .tool.away{
    left: 120%;
    top: 50%;
    opacity: 0;
}

.routine .tool.brushing{
    -moz-transition: none;
    -o-transition: none;
    -webkit-transition: none;
    -ms-transition: none;
    transition: none;
}

.routine .tool .art{
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--r-frame);
    -moz-box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    -o-box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    -webkit-box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    -ms-box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.routine .tool .dab{
    position: absolute;
    right: -0.3rem;
    top: -0.3rem;
    width: 1.1rem;
    height: 1.1rem;
    border-radius: 50% 50% 50% 0;
    background: linear-gradient(135deg, #fff, #9ad8ff);
    border: 2px solid #fff;
    -moz-box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    -o-box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    -webkit-box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    -ms-box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    animation: nb-bubble-in 0.4s both;
}

.routine.princess{
    --r-lips: #e0607d;
    --r-plaque: #e9c46a;
}

.routine.pirate{
    --r-lips: #b84a3c;
    --r-plaque: #a3a380;
}

.routine.superhero{
    --r-lips: #d14d5f;
    --r-plaque: #9bc53d;
}

@keyframes nb-beckon{
    50%{
        -moz-transform: scale(1.05);
        -o-transform: scale(1.05);
        -webkit-transform: scale(1.05);
        -ms-transform: scale(1.05);
        transform: scale(1.05);
    }
}

.routine .germs, .routine .foam, .routine .fx{
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.routine .germ{
    position: absolute;
    width: 1.5rem;
    height: 1.5rem;
    margin: -0.75rem 0 0 -0.75rem;
    -moz-transition: transform 0.4s, opacity 0.4s;
    -o-transition: transform 0.4s, opacity 0.4s;
    -webkit-transition: transform 0.4s, opacity 0.4s;
    -ms-transition: transform 0.4s, opacity 0.4s;
    transition: transform 0.4s, opacity 0.4s;
}

.routine .germ .mud{
    display: block;
    width: 100%;
    height: 100%;
    fill: var(--r-mud);
    opacity: 0.85;
}

.routine .germ .mud .shine{
    fill: #fff;
    opacity: 0.35;
}

.routine .germ.wet{
    opacity: 0.6;
    -moz-transform: scale(0.85);
    -o-transform: scale(0.85);
    -webkit-transform: scale(0.85);
    -ms-transform: scale(0.85);
    transform: scale(0.85);
}

.routine .germ.gone{
    opacity: 0;
    -moz-transform: scale(0) rotate(180deg);
    -o-transform: scale(0) rotate(180deg);
    -webkit-transform: scale(0) rotate(180deg);
    -ms-transform: scale(0) rotate(180deg);
    transform: scale(0) rotate(180deg);
}

.routine .bubble{
    position: absolute;
    width: var(--size, 1.4rem);
    height: var(--size, 1.4rem);
    margin: calc(var(--size, 1.4rem) / -2) 0 0 calc(var(--size, 1.4rem) / -2);
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.95);
    background: radial-gradient(circle at 32% 30%, rgba(255,255,255,0.98) 0 18%, rgba(255,255,255,0.45) 45%, rgba(186,230,253,0.55) 100%);
    -moz-box-shadow: 0 2px 6px rgba(14,165,233,0.25);
    -o-box-shadow: 0 2px 6px rgba(14,165,233,0.25);
    -webkit-box-shadow: 0 2px 6px rgba(14,165,233,0.25);
    -ms-box-shadow: 0 2px 6px rgba(14,165,233,0.25);
    box-shadow: 0 2px 6px rgba(14,165,233,0.25);
    animation: nb-bubble-in 0.4s both;
}

.routine .bubble.pop{
    animation: nb-bubble-up 0.9s ease-out forwards;
}

.routine .foam.gone .bubble{
    animation: nb-bubble-down 1.2s ease-in forwards;
}

@keyframes nb-bubble-in{
    from{
        -moz-transform: scale(0);
        -o-transform: scale(0);
        -webkit-transform: scale(0);
        -ms-transform: scale(0);
        transform: scale(0);
    }
    to{
        -moz-transform: scale(1);
        -o-transform: scale(1);
        -webkit-transform: scale(1);
        -ms-transform: scale(1);
        transform: scale(1);
    }
}

@keyframes nb-bubble-up{
    to{
        -moz-transform: translateY(-3rem) scale(1.5);
        -o-transform: translateY(-3rem) scale(1.5);
        -webkit-transform: translateY(-3rem) scale(1.5);
        -ms-transform: translateY(-3rem) scale(1.5);
        transform: translateY(-3rem) scale(1.5);
        opacity: 0;
    }
}

@keyframes nb-bubble-down{
    to{
        -moz-transform: translateY(6rem);
        -o-transform: translateY(6rem);
        -webkit-transform: translateY(6rem);
        -ms-transform: translateY(6rem);
        transform: translateY(6rem);
        opacity: 0;
    }
}

.routine .drops i{
    position: absolute;
    top: -1rem;
    width: 0.35rem;
    height: 1rem;
    border-radius: 999px;
    background: #38bdf8;
    animation: nb-drip 0.7s linear infinite;
}

@keyframes nb-drip{
    to{
        -moz-transform: translateY(11rem);
        -o-transform: translateY(11rem);
        -webkit-transform: translateY(11rem);
        -ms-transform: translateY(11rem);
        transform: translateY(11rem);
        opacity: 0.3;
    }
}

.routine .wipe{
    position: absolute;
    left: -20%;
    top: 20%;
    font-size: 4rem;
    line-height: 1;
    animation: nb-wipe 1.2s ease-in-out forwards;
}

.routine .wipe .art{
    width: 5rem;
    height: 5rem;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--r-frame);
    -moz-box-shadow: 0 6px 14px rgba(0,0,0,0.2);
    -o-box-shadow: 0 6px 14px rgba(0,0,0,0.2);
    -webkit-box-shadow: 0 6px 14px rgba(0,0,0,0.2);
    -ms-box-shadow: 0 6px 14px rgba(0,0,0,0.2);
    box-shadow: 0 6px 14px rgba(0,0,0,0.2);
}

@keyframes nb-wipe{
    30%{
        -moz-transform: translate(7rem, 1rem) rotate(-10deg);
        -o-transform: translate(7rem, 1rem) rotate(-10deg);
        -webkit-transform: translate(7rem, 1rem) rotate(-10deg);
        -ms-transform: translate(7rem, 1rem) rotate(-10deg);
        transform: translate(7rem, 1rem) rotate(-10deg);
        opacity: 1;
    }
    65%{
        -moz-transform: translate(13rem, -0.5rem) rotate(10deg);
        -o-transform: translate(13rem, -0.5rem) rotate(10deg);
        -webkit-transform: translate(13rem, -0.5rem) rotate(10deg);
        -ms-transform: translate(13rem, -0.5rem) rotate(10deg);
        transform: translate(13rem, -0.5rem) rotate(10deg);
        opacity: 1;
    }
    to{
        -moz-transform: translate(20rem, 1rem);
        -o-transform: translate(20rem, 1rem);
        -webkit-transform: translate(20rem, 1rem);
        -ms-transform: translate(20rem, 1rem);
        transform: translate(20rem, 1rem);
        opacity: 0;
    }
}

.routine .sparkle{
    position: absolute;
    width: 1.8rem;
    height: 1.8rem;
    margin: -0.9rem 0 0 -0.9rem;
    background: linear-gradient(180deg, #fff7c2, var(--r-gold));
    clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
    animation: nb-twinkle 1.1s ease-out both;
}

@keyframes nb-twinkle{
    from{
        -moz-transform: scale(0);
        -o-transform: scale(0);
        -webkit-transform: scale(0);
        -ms-transform: scale(0);
        transform: scale(0);
    }
    50%{
        -moz-transform: scale(1.3);
        -o-transform: scale(1.3);
        -webkit-transform: scale(1.3);
        -ms-transform: scale(1.3);
        transform: scale(1.3);
        opacity: 1;
    }
    to{
        -moz-transform: scale(0.6);
        -o-transform: scale(0.6);
        -webkit-transform: scale(0.6);
        -ms-transform: scale(0.6);
        transform: scale(0.6);
        opacity: 0;
    }
}

.routine .things{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.6rem;
    margin: 0.7rem 0;
}

.routine .things.five{
    grid-template-columns: repeat(5, 1fr);
    gap: 0.4rem;
}

@media (max-width: 32rem){
    .routine .things.five{
        grid-template-columns: repeat(3, 1fr);
    }
}

.routine .things.five button{
    padding: 0.5rem 0.15rem;
    font-size: 0.82rem;
    min-height: 5.8rem;
}

.routine .things.five button .pic .art{
    width: 3.6rem;
    height: 3.6rem;
}

.routine .things.five button .pic .icon{
    font-size: 2.4rem;
}

.routine .things[hidden], .routine .sing[hidden]{
    display: none;
}

.routine .things button{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    min-height: 6.5rem;
    padding: 0.6rem 0.3rem;
    border-radius: 1.3rem;
    border: 3px solid var(--border-subtle);
    background: var(--r-card);
    color: var(--text);
    font: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    -moz-transition: transform 0.1s;
    -o-transition: transform 0.1s;
    -webkit-transition: transform 0.1s;
    -ms-transition: transform 0.1s;
    transition: transform 0.1s;
}

.routine .things button:active{
    -moz-transform: scale(0.95);
    -o-transform: scale(0.95);
    -webkit-transform: scale(0.95);
    -ms-transform: scale(0.95);
    transform: scale(0.95);
}

.routine .things button .pic{
    display: block;
    line-height: 1;
}

.routine .things button .pic .icon{
    font-size: 3rem;
    line-height: 1;
}

.routine .things button .pic .art{
    display: block;
    width: 4.6rem;
    height: 4.6rem;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--r-frame);
    -moz-box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(0,0,0,0.15);
    -o-box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(0,0,0,0.15);
    -webkit-box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(0,0,0,0.15);
    -ms-box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(0,0,0,0.15);
    box-shadow: 0 0 0 2px #fff, 0 4px 10px rgba(0,0,0,0.15);
}

.routine .things button.hint{
    border-color: var(--r-pop);
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.routine .things button.good{
    border-color: var(--good);
    background: #f0fdf4;
}

.routine .things button.wrong{
    animation: nb-wobble 0.5s;
}

@keyframes nb-wobble{
    25%{
        -moz-transform: translateX(-0.4rem) rotate(-3deg);
        -o-transform: translateX(-0.4rem) rotate(-3deg);
        -webkit-transform: translateX(-0.4rem) rotate(-3deg);
        -ms-transform: translateX(-0.4rem) rotate(-3deg);
        transform: translateX(-0.4rem) rotate(-3deg);
    }
    75%{
        -moz-transform: translateX(0.4rem) rotate(3deg);
        -o-transform: translateX(0.4rem) rotate(3deg);
        -webkit-transform: translateX(0.4rem) rotate(3deg);
        -ms-transform: translateX(0.4rem) rotate(3deg);
        transform: translateX(0.4rem) rotate(3deg);
    }
}

.routine .sing{
    display: flex;
    align-items: center;
    gap: 0.9rem;
    margin: 0.7rem 0;
    padding: 0.6rem 0.9rem;
    border-radius: 1.3rem;
    background: var(--surface-2);
}

.routine .ring{
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 4.6rem;
    height: 4.6rem;
    border-radius: 50%;
    background: conic-gradient(var(--r-pop) var(--p, 0%), var(--border-subtle) 0);
}

.routine .ring b{
    display: grid;
    place-items: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 50%;
    background: var(--surface);
    font-size: 1.4rem;
    font-variant-numeric: tabular-nums;
}

.routine .sing .spot{
    flex: 1 1 auto;
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.25;
}

.routine .spots{
    display: grid;
    gap: 0.3rem;
}

.routine .spots i{
    width: 0.8rem;
    height: 0.8rem;
    border-radius: 50%;
    background: var(--border);
    -moz-transition: transform 0.2s, background 0.2s;
    -o-transition: transform 0.2s, background 0.2s;
    -webkit-transition: transform 0.2s, background 0.2s;
    -ms-transition: transform 0.2s, background 0.2s;
    transition: transform 0.2s, background 0.2s;
}

.routine .spots i.now{
    background: var(--r-pop);
    -moz-transform: scale(1.3);
    -o-transform: scale(1.3);
    -webkit-transform: scale(1.3);
    -ms-transform: scale(1.3);
    transform: scale(1.3);
}

.routine .spots i.ok{
    background: var(--good);
}

.routine .results .reward{
    font-size: 5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.routine .results .reward .art{
    display: block;
    margin: 0 auto;
    width: 8.5rem;
    height: 8.5rem;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--r-frame);
    -moz-box-shadow: 0 0 0 3px #fff, 0 0 0 7px rgba(232,184,74,0.35), 0 10px 24px rgba(0,0,0,0.18);
    -o-box-shadow: 0 0 0 3px #fff, 0 0 0 7px rgba(232,184,74,0.35), 0 10px 24px rgba(0,0,0,0.18);
    -webkit-box-shadow: 0 0 0 3px #fff, 0 0 0 7px rgba(232,184,74,0.35), 0 10px 24px rgba(0,0,0,0.18);
    -ms-box-shadow: 0 0 0 3px #fff, 0 0 0 7px rgba(232,184,74,0.35), 0 10px 24px rgba(0,0,0,0.18);
    box-shadow: 0 0 0 3px #fff, 0 0 0 7px rgba(232,184,74,0.35), 0 10px 24px rgba(0,0,0,0.18);
}

.routine .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.routine .results .stars.s1, .routine .results .stars.s2, .routine .results .stars.s3{
    color: var(--gold);
}

.routine .results .say{
    font-size: 1.2rem;
}

.routine .results .trivia{
    position: relative;
    max-width: 26rem;
    margin: 0.8rem auto;
    padding: 0.7rem 3rem 0.7rem 1rem;
    border-radius: 1rem;
    background: var(--r-card);
    border: 2px solid rgba(232,184,74,0.55);
    text-align: left;
    font-family: var(--r-font);
}

.routine .results .trivia b{
    display: block;
    color: var(--r-deep);
    margin-bottom: 0.2rem;
}

.routine .results .trivia p{
    margin: 0;
    line-height: 1.4;
}

.routine .results .trivia .read{
    position: absolute;
    right: 0.5rem;
    top: 0.5rem;
    width: 2.2rem;
    height: 2.2rem;
    padding: 0;
    border-radius: 50%;
    border: 2px solid var(--r-frame);
    background: #fff;
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
}

.routine .journey{
    margin: 0.8rem auto 0.4rem;
    max-width: 26rem;
    padding: 0.5rem 0.4rem 0.6rem;
    border-radius: 1.2rem;
    background: var(--r-card);
    -moz-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -o-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -webkit-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    -ms-box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    box-shadow: 0 4px 0 rgba(0,0,0,0.08);
    border: 2px solid rgba(232,184,74,0.55);
}

.routine .map{
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.routine .map text{
    font-size: 15px;
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.routine .map .road{
    fill: none;
    stroke: var(--border);
    stroke-width: 5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1 9;
}

.routine .map .trail{
    fill: none;
    stroke: var(--r-pop);
    stroke-width: 5;
    stroke-linecap: round;
    stroke-linejoin: round;
    -moz-transition: all 0.9s ease-in-out;
    -o-transition: all 0.9s ease-in-out;
    -webkit-transition: all 0.9s ease-in-out;
    -ms-transition: all 0.9s ease-in-out;
    transition: all 0.9s ease-in-out;
}

.routine .map .stop circle{
    fill: var(--r-card);
    stroke: var(--border);
    stroke-width: 3;
}

.routine .map .stop.done circle{
    fill: var(--r-pop);
    stroke: var(--r-pop);
}

.routine .map .stop.here circle{
    stroke: var(--r-deep);
    stroke-width: 4;
}

.routine .map .stop:last-child circle, .routine .map .stop.done:last-child circle{
    fill: var(--gold);
    stroke: var(--gold);
}

.routine .map .walker{
    -moz-transition: transform 0.9s ease-in-out;
    -o-transition: transform 0.9s ease-in-out;
    -webkit-transition: transform 0.9s ease-in-out;
    -ms-transition: transform 0.9s ease-in-out;
    transition: transform 0.9s ease-in-out;
}

.routine .map .walker text{
    font-size: 26px;
}

.routine .map .walker image{
    clip-path: circle(50%);
}

.routine .map .walker .rim{
    fill: none;
    stroke: var(--r-frame);
    stroke-width: 2.5;
}

.routine .journey .where{
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    margin: 0.2rem 0 0;
    font-size: 1.05rem;
    line-height: 1.3;
}

.routine .journey .where small{
    color: var(--muted);
}

.count .scene{
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    margin: 0.4rem 0;
    border-radius: 1.2rem;
    -moz-box-shadow: 0 6px 0 rgba(0,0,0,0.08), inset 0 0 0 3px rgba(255,255,255,0.5);
    -o-box-shadow: 0 6px 0 rgba(0,0,0,0.08), inset 0 0 0 3px rgba(255,255,255,0.5);
    -webkit-box-shadow: 0 6px 0 rgba(0,0,0,0.08), inset 0 0 0 3px rgba(255,255,255,0.5);
    -ms-box-shadow: 0 6px 0 rgba(0,0,0,0.08), inset 0 0 0 3px rgba(255,255,255,0.5);
    box-shadow: 0 6px 0 rgba(0,0,0,0.08), inset 0 0 0 3px rgba(255,255,255,0.5);
    --c-top: #bfe9ff;
    --c-bottom: #e3f6ff;
    --c-far: #a3d977;
    --c-near: #74c25a;
    --c-pond: #4fb3e8;
    --c-sun: #ffd54a;
}

.count .scene .sky{
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, var(--c-top), var(--c-bottom));
}

.count .scene .land-box, .count .scene .land{
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
}

.count .scene.pond{
    --c-top: #bfe9ff;
    --c-bottom: #e3f6ff;
    --c-far: #9ad48a;
    --c-near: #6fbf5c;
    --c-pond: #4fb3e8;
}

.count .scene.meadow{
    --c-top: #cdeeff;
    --c-bottom: #eaf7ff;
    --c-far: #a3d977;
    --c-near: #74c25a;
}

.count .scene.balloons{
    --c-top: #9fd3ff;
    --c-bottom: #dff1ff;
}

.count .scene.night{
    --c-top: #0f1b4d;
    --c-bottom: #2a3a8a;
    --c-far: #1d2d6b;
    --c-near: #142257;
}

.count .scene.orchard{
    --c-top: #d6f0ff;
    --c-bottom: #f3fbff;
}

.count .scene.beach{
    --c-top: #bfe6ff;
    --c-bottom: #e8f6ff;
}

.count .scene.garden{
    --c-top: #e2f7d8;
    --c-bottom: #f6fde9;
    --c-far: #7cc96c;
    --c-near: #5db24d;
}

.count .scene.space{
    --c-top: #0b0f2e;
    --c-bottom: #2c1a5c;
}

.count .scene.sea{
    --c-top: #1e8fd6;
    --c-bottom: #0b5fa8;
}

.count .scene.farm{
    --c-top: #ffe9b8;
    --c-bottom: #fff7df;
    --c-far: #e0c56e;
    --c-near: #c9a94a;
}

.count .scene.bakery{
    --c-top: #ffd6e8;
    --c-bottom: #fff0f6;
}

.count .scene.lilies{
    --c-top: #c8f0d8;
    --c-bottom: #ecfbf0;
    --c-far: #7fcf8a;
    --c-near: #56b86a;
    --c-pond: #3aa6a0;
}

.count .land .sun{
    fill: var(--c-sun);
}

.count .land .cloud{
    fill: rgba(255,255,255,0.85);
}

.count .land .hills .far{
    fill: var(--c-far);
}

.count .land .hills .near{
    fill: var(--c-near);
}

.count .land .pond{
    fill: var(--c-pond);
}

.count .land .reeds path{
    fill: none;
    stroke: #3f7a2f;
    stroke-width: 1.2;
    stroke-linecap: round;
}

.count .land .dot{
    fill: #fff;
}

.count .land .moon{
    fill: #fff6c2;
}

.count .land .moon-shadow{
    fill: var(--c-top);
}

.count .land .planet{
    fill: #f59e0b;
}

.count .land .planet.far{
    fill: #f472b6;
}

.count .land .ring{
    fill: none;
    stroke: #fde68a;
    stroke-width: 1;
}

.count .land .trunk{
    fill: #8b5a2b;
}

.count .land .canopy circle{
    fill: #5aae4e;
}

.count .land .grass{
    fill: #8fd36f;
}

.count .land .wave{
    fill: #4fb6e6;
}

.count .land .foam{
    fill: none;
    stroke: #fff;
    stroke-width: 1;
}

.count .land .beach{
    fill: #f6d98b;
}

.count .land .bubble{
    fill: rgba(255,255,255,0.5);
}

.count .land .weed{
    fill: none;
    stroke: #2f9e6b;
    stroke-width: 2;
    stroke-linecap: round;
}

.count .land .sandbed{
    fill: #e9d59a;
}

.count .things{
    position: absolute;
    left: 6%;
    right: 6%;
    top: 10%;
    bottom: 16%;
    font-size: 3.6rem;
}

.count .things.n10{
    font-size: 2.8rem;
}

.count .things.n14{
    font-size: 2.3rem;
}

.count .things.n20{
    font-size: 1.9rem;
}

@media (max-width: 32rem){
    .count .things{
        font-size: 2.9rem;
    }
    .count .things.n10{
        font-size: 2.3rem;
    }
    .count .things.n14{
        font-size: 1.9rem;
    }
    .count .things.n20{
        font-size: 1.6rem;
    }
}

.count .thing{
    position: absolute;
    width: 1.3em;
    height: 1.3em;
    margin: -0.65em 0 0 -0.65em;
    padding: 0;
    border: none;
    background: none;
    font-size: inherit;
    line-height: 1;
    cursor: pointer;
    touch-action: manipulation;
    display: block;
    min-height: 0;
}

.count .thing .pic{
    display: block;
    line-height: 1.3em;
    text-align: center;
    -moz-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -o-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -webkit-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -ms-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    animation: nb-pop-in 0.45s cubic-bezier(0.2, 1.4, 0.4, 1) var(--delay, 0s) both, nb-bob var(--bob, 2.4s) ease-in-out calc(var(--delay, 0s) + 0.45s) infinite alternate;
}

.count .thing.still .pic{
    animation: nb-bob var(--bob, 2.4s) ease-in-out infinite alternate;
}

.count .thing.counted .pic{
    animation: nb-boing 0.5s cubic-bezier(0.2, 1.6, 0.4, 1);
}

.count .thing.cheer .pic{
    animation: nb-cheer 0.6s ease-in-out var(--delay, 0s) infinite;
}

.count .thing.wrong .pic{
    animation: nb-wobble 0.5s;
}

.count .thing .badge{
    position: absolute;
    right: -0.2em;
    top: -0.2em;
    min-width: 0.95em;
    height: 0.95em;
    padding: 0 0.15em;
    box-sizing: border-box;
    border-radius: 999px;
    display: grid;
    place-items: center;
    font-size: 0.42em;
    font-weight: 800;
    line-height: 1;
    background: var(--accent);
    color: #fff;
    border: 0.08em solid #fff;
    opacity: 0;
    -moz-transform: scale(0);
    -o-transform: scale(0);
    -webkit-transform: scale(0);
    -ms-transform: scale(0);
    transform: scale(0);
    -moz-transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1), opacity 0.2s;
    -o-transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1), opacity 0.2s;
    -webkit-transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1), opacity 0.2s;
    -ms-transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1), opacity 0.2s;
    transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1), opacity 0.2s;
}

.count .thing.counted .badge{
    opacity: 1;
    -moz-transform: scale(1);
    -o-transform: scale(1);
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
}

.count .thing.chosen::before{
    content: "";
    position: absolute;
    inset: -0.05em;
    border-radius: 50%;
    border: 0.1em solid #fff;
    -moz-box-shadow: 0 0 0 0.08em var(--accent), 0 0 0.4em rgba(0,0,0,0.2);
    -o-box-shadow: 0 0 0 0.08em var(--accent), 0 0 0.4em rgba(0,0,0,0.2);
    -webkit-box-shadow: 0 0 0 0.08em var(--accent), 0 0 0.4em rgba(0,0,0,0.2);
    -ms-box-shadow: 0 0 0 0.08em var(--accent), 0 0 0.4em rgba(0,0,0,0.2);
    box-shadow: 0 0 0 0.08em var(--accent), 0 0 0.4em rgba(0,0,0,0.2);
}

.count .ask{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.3rem 0;
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.2;
    min-height: 2.8rem;
}

.count .ask .big-n{
    font-size: 2.8rem;
    color: var(--accent);
    line-height: 1;
}

.count .ask .icon{
    font-size: 1.8rem;
    line-height: 1;
}

.count .numbers{
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    margin: 0.5rem 0;
}

.count .numbers.wide{
    grid-template-columns: repeat(10, 1fr);
    gap: 0.35rem;
}

@media (max-width: 32rem){
    .count .numbers.wide{
        grid-template-columns: repeat(5, 1fr);
    }
}

.count .numbers button{
    font-size: 1.9rem;
    font-weight: 800;
    min-height: 3.6rem;
    padding: 0;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--border-subtle);
    touch-action: manipulation;
    cursor: pointer;
    -moz-transition: transform 0.05s;
    -o-transition: transform 0.05s;
    -webkit-transition: transform 0.05s;
    -ms-transition: transform 0.05s;
    transition: transform 0.05s;
}

.count .numbers.wide button{
    font-size: 1.4rem;
    min-height: 3rem;
    border-radius: 0.7rem;
}

.count .numbers button:active{
    -moz-transform: translateY(2px);
    -o-transform: translateY(2px);
    -webkit-transform: translateY(2px);
    -ms-transform: translateY(2px);
    transform: translateY(2px);
}

.count .numbers button.hint, .count .tick.hint{
    border-color: var(--accent);
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.count .numbers button.good{
    border-color: var(--good);
    background: #f0fdf4;
    color: #15803d;
}

.count .numbers button.wrong, .count .tick.wrong{
    animation: nb-wobble 0.5s;
}

.count .numbers[hidden], .count .tick[hidden]{
    display: none;
}

.count .tick{
    display: grid;
    place-items: center;
    margin: 0.5rem auto;
    width: 5rem;
    height: 5rem;
    padding: 0;
    border-radius: 50%;
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1;
    color: #fff;
    background: var(--good);
    border: 3px solid #fff;
    -moz-box-shadow: 0 6px 0 #15803d;
    -o-box-shadow: 0 6px 0 #15803d;
    -webkit-box-shadow: 0 6px 0 #15803d;
    -ms-box-shadow: 0 6px 0 #15803d;
    box-shadow: 0 6px 0 #15803d;
    cursor: pointer;
    touch-action: manipulation;
    -moz-transition: transform 0.05s;
    -o-transition: transform 0.05s;
    -webkit-transition: transform 0.05s;
    -ms-transition: transform 0.05s;
    transition: transform 0.05s;
}

.count .tick:active{
    -moz-transform: translateY(4px);
    -o-transform: translateY(4px);
    -webkit-transform: translateY(4px);
    -ms-transform: translateY(4px);
    transform: translateY(4px);
    -moz-box-shadow: 0 2px 0 #15803d;
    -o-box-shadow: 0 2px 0 #15803d;
    -webkit-box-shadow: 0 2px 0 #15803d;
    -ms-box-shadow: 0 2px 0 #15803d;
    box-shadow: 0 2px 0 #15803d;
}

.count .tick.good{
    background: #16a34a;
}

.count .said{
    min-height: 1.7rem;
    text-align: center;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--pop);
}

.count .intro .scene.preview{
    max-width: 17rem;
    margin: 0.4rem auto 0.8rem;
}

.count .intro .label{
    color: var(--muted);
}

.count .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.count .results .reward{
    font-size: 4.5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.count .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.count .results .stars.s1, .count .results .stars.s2, .count .results .stars.s3{
    color: var(--gold);
}

@keyframes nb-pop-in{
    from{
        -moz-transform: scale(0);
        -o-transform: scale(0);
        -webkit-transform: scale(0);
        -ms-transform: scale(0);
        transform: scale(0);
    }
    to{
        -moz-transform: scale(1);
        -o-transform: scale(1);
        -webkit-transform: scale(1);
        -ms-transform: scale(1);
        transform: scale(1);
    }
}

@keyframes nb-bob{
    from{
        -moz-transform: translateY(-4%);
        -o-transform: translateY(-4%);
        -webkit-transform: translateY(-4%);
        -ms-transform: translateY(-4%);
        transform: translateY(-4%);
    }
    to{
        -moz-transform: translateY(4%);
        -o-transform: translateY(4%);
        -webkit-transform: translateY(4%);
        -ms-transform: translateY(4%);
        transform: translateY(4%);
    }
}

@keyframes nb-boing{
    30%{
        -moz-transform: scale(1.35) rotate(-8deg);
        -o-transform: scale(1.35) rotate(-8deg);
        -webkit-transform: scale(1.35) rotate(-8deg);
        -ms-transform: scale(1.35) rotate(-8deg);
        transform: scale(1.35) rotate(-8deg);
    }
    60%{
        -moz-transform: scale(0.92);
        -o-transform: scale(0.92);
        -webkit-transform: scale(0.92);
        -ms-transform: scale(0.92);
        transform: scale(0.92);
    }
    to{
        -moz-transform: scale(1);
        -o-transform: scale(1);
        -webkit-transform: scale(1);
        -ms-transform: scale(1);
        transform: scale(1);
    }
}

@keyframes nb-cheer{
    50%{
        -moz-transform: translateY(-18%) rotate(6deg);
        -o-transform: translateY(-18%) rotate(6deg);
        -webkit-transform: translateY(-18%) rotate(6deg);
        -ms-transform: translateY(-18%) rotate(6deg);
        transform: translateY(-18%) rotate(6deg);
    }
}

@media (prefers-reduced-motion: reduce){
    .count .thing .pic, .count .thing.cheer .pic, .count .numbers button.hint, .count .tick.hint, .count .results .reward{
        animation: none;
    }
}

.share .ask{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.3rem 0;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.2;
    min-height: 2.6rem;
    text-align: center;
}

.share .ask .sign{
    font-size: 2.6rem;
    color: var(--pop);
    letter-spacing: 0.04em;
}

.share .ask .hear{
    min-height: 0;
    width: 2.4rem;
    height: 2.4rem;
    padding: 0;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    background: var(--surface-2);
}

.share .sum-hint{
    text-align: center;
    font-weight: 700;
    color: var(--muted);
    min-height: 1.3rem;
}

.share .cloth{
    position: relative;
    height: 9.5rem;
    margin: 0.4rem 0;
    border-radius: 1.2rem;
    border: 3px solid #fff;
    -moz-box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    -o-box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    -webkit-box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    -ms-box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    box-shadow: 0 2px 10px rgba(0,0,0,0.12);
    background: repeating-conic-gradient(#fbd5d5 0 25%, #fff5f5 0 50%) 0 0 / 2.4rem 2.4rem;
    font-size: 3rem;
}

.share .cloth.n12{
    font-size: 2.5rem;
}

.share .cloth.n20{
    font-size: 2.1rem;
    height: 10.5rem;
}

.share .pips{
    flex: 1 1 auto;
}

.share .cloth.wrong{
    animation: nb-wobble 0.5s;
}

.share .thing{
    position: absolute;
    width: 1.4em;
    height: 1.4em;
    margin: -0.7em 0 0 -0.7em;
    padding: 0;
    border: none;
    background: none;
    font-size: inherit;
    line-height: 1.4em;
    min-height: 0;
    cursor: pointer;
    touch-action: none;
    text-align: center;
    -moz-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -o-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -webkit-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -ms-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    animation: nb-pop-in 0.4s cubic-bezier(0.2, 1.4, 0.4, 1) var(--delay, 0s) both;
}

.share .thing.gone{
    visibility: hidden;
}

.share .thing.lifted, .share .item.lifted{
    -moz-transform: translateY(-0.25em) scale(1.25);
    -o-transform: translateY(-0.25em) scale(1.25);
    -webkit-transform: translateY(-0.25em) scale(1.25);
    -ms-transform: translateY(-0.25em) scale(1.25);
    transform: translateY(-0.25em) scale(1.25);
    -moz-filter: drop-shadow(0 0.3em 0.25em rgba(0,0,0,0.35));
    -o-filter: drop-shadow(0 0.3em 0.25em rgba(0,0,0,0.35));
    -webkit-filter: drop-shadow(0 0.3em 0.25em rgba(0,0,0,0.35));
    -ms-filter: drop-shadow(0 0.3em 0.25em rgba(0,0,0,0.35));
    filter: drop-shadow(0 0.3em 0.25em rgba(0,0,0,0.35));
}

.share .thing.dragging, .share .item.dragging{
    position: fixed;
    left: var(--dx);
    top: var(--dy);
    margin: -0.7em 0 0 -0.7em;
    pointer-events: none;
    z-index: 10;
    font-size: 2.4rem;
}

.share .basket{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    font-size: 1.6rem;
    min-height: 2.4rem;
    margin: 0.2rem auto;
    padding: 0.2rem 0.8rem;
    border-radius: 999px;
    background: #f6e3c4;
    width: fit-content;
}

.share .basket[hidden]{
    display: none;
}

.share .basket .item{
    font-size: 1.6rem;
}

.share .table{
    display: grid;
    grid-template-columns: repeat(var(--plates), 1fr);
    gap: 0.4rem;
    margin: 0.4rem 0;
}

.share .plate{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
    padding: 0.3rem 0.2rem;
    border-radius: 1rem;
    cursor: pointer;
    touch-action: manipulation;
    -moz-transition: background 0.2s;
    -o-transition: background 0.2s;
    -webkit-transition: background 0.2s;
    -ms-transition: background 0.2s;
    transition: background 0.2s;
}

.share .plate .face{
    font-size: 2.3rem;
    line-height: 1;
    -moz-transition: transform 0.2s;
    -o-transition: transform 0.2s;
    -webkit-transition: transform 0.2s;
    -ms-transition: transform 0.2s;
    transition: transform 0.2s;
}

.share .plate .name{
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--muted);
}

.share .plate .dish{
    display: flex;
    flex-wrap: wrap;
    align-content: center;
    justify-content: center;
    width: 100%;
    max-width: 6.5rem;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle, #fff 55%, #e8eef5 56%, #fff 70%);
    border: 2px solid #d5dde8;
    box-sizing: border-box;
    padding: 12%;
    gap: 0.05rem;
}

.share .plate.turn{
    background: #fff3e6;
}

.share .plate.turn .face{
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.share .plate.got .face{
    animation: nb-boing 0.4s;
}

.share .plate.happy .face{
    -moz-transform: scale(1.15);
    -o-transform: scale(1.15);
    -webkit-transform: scale(1.15);
    -ms-transform: scale(1.15);
    transform: scale(1.15);
}

.share .plate.happy .face::after{
    content: "😊";
    font-size: 0.5em;
    position: relative;
    top: -0.9em;
}

.share .plate.sad .face{
    -moz-filter: grayscale(0.5);
    -o-filter: grayscale(0.5);
    -webkit-filter: grayscale(0.5);
    -ms-filter: grayscale(0.5);
    filter: grayscale(0.5);
}

.share .plate.sad .face::after{
    content: "😢";
    font-size: 0.5em;
    position: relative;
    top: -0.9em;
}

.share .plate.cheer .face{
    animation: nb-cheer 0.6s ease-in-out infinite;
}

.share .plate.counting{
    background: #ede7ff;
}

.share .item{
    position: relative;
    padding: 0;
    border: none;
    background: none;
    min-height: 0;
    font-size: 1.6rem;
    line-height: 1.15;
    cursor: pointer;
    touch-action: none;
    -moz-filter: drop-shadow(0 0.06em 0.06em rgba(0,0,0,0.25));
    -o-filter: drop-shadow(0 0.06em 0.06em rgba(0,0,0,0.25));
    -webkit-filter: drop-shadow(0 0.06em 0.06em rgba(0,0,0,0.25));
    -ms-filter: drop-shadow(0 0.06em 0.06em rgba(0,0,0,0.25));
    filter: drop-shadow(0 0.06em 0.06em rgba(0,0,0,0.25));
}

.share .item.flying{
    -moz-transition: transform 0.35s cubic-bezier(0.3, 1.2, 0.5, 1);
    -o-transition: transform 0.35s cubic-bezier(0.3, 1.2, 0.5, 1);
    -webkit-transition: transform 0.35s cubic-bezier(0.3, 1.2, 0.5, 1);
    -ms-transition: transform 0.35s cubic-bezier(0.3, 1.2, 0.5, 1);
    transition: transform 0.35s cubic-bezier(0.3, 1.2, 0.5, 1);
}

.share .badge{
    position: absolute;
    right: -0.35em;
    top: -0.35em;
    min-width: 1.1rem;
    height: 1.1rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    font-size: 0.7rem;
    font-weight: 800;
    line-height: 1;
    background: var(--accent);
    color: #fff;
    border: 2px solid #fff;
}

.share .item.counted{
    animation: nb-boing 0.5s cubic-bezier(0.2, 1.6, 0.4, 1);
}

.share .table.rows{
    grid-template-columns: 1fr;
}

.share .table.rows .plate{
    flex-direction: row;
    justify-content: flex-start;
    gap: 0.6rem;
    padding: 0.15rem 0.5rem;
}

.share .table.rows .plate .face{
    font-size: 1.6rem;
}

.share .table.rows .plate .name{
    display: none;
}

.share .table.rows .plate .dish{
    max-width: none;
    aspect-ratio: auto;
    border-radius: 0.6rem;
    background: #fff;
    justify-content: flex-start;
    padding: 0.2rem 0.4rem;
}

.share .table.rows .item{
    font-size: 1.5rem;
}

.share .table.boxes{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
}

.share .box{
    position: relative;
    padding: 0.35rem;
    border-radius: 0.6rem;
    background: #e7c99a;
    border: 3px solid #b98d4f;
    -moz-transition: transform 0.2s;
    -o-transition: transform 0.2s;
    -webkit-transition: transform 0.2s;
    -ms-transition: transform 0.2s;
    transition: transform 0.2s;
}

.share .box .slots{
    display: grid;
    grid-template-columns: repeat(auto-fill, 2rem);
    gap: 0.15rem;
    width: fit-content;
    max-width: 10.5rem;
}

.share .box .slots i{
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    border-radius: 0.4rem;
    background: #f6e3c4;
    font-style: normal;
}

.share .box .slots .item{
    font-size: 1.4rem;
}

.share .box .lid{
    position: absolute;
    inset: -3px;
    border-radius: 0.6rem;
    background: #c9995a;
    border: 3px solid #8f6a35;
    -moz-transform: scaleY(0);
    -o-transform: scaleY(0);
    -webkit-transform: scaleY(0);
    -ms-transform: scaleY(0);
    transform: scaleY(0);
    -moz-transform-origin: top;
    -o-transform-origin: top;
    -webkit-transform-origin: top;
    -ms-transform-origin: top;
    transform-origin: top;
    -moz-transition: transform 0.3s cubic-bezier(0.3, 1.4, 0.5, 1);
    -o-transition: transform 0.3s cubic-bezier(0.3, 1.4, 0.5, 1);
    -webkit-transition: transform 0.3s cubic-bezier(0.3, 1.4, 0.5, 1);
    -ms-transition: transform 0.3s cubic-bezier(0.3, 1.4, 0.5, 1);
    transition: transform 0.3s cubic-bezier(0.3, 1.4, 0.5, 1);
    pointer-events: none;
}

.share .box.full .lid{
    -moz-transform: scaleY(1);
    -o-transform: scaleY(1);
    -webkit-transform: scaleY(1);
    -ms-transform: scaleY(1);
    transform: scaleY(1);
}

.share .box.full .lid::after{
    content: "🎀";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 1.6rem;
}

.share .box.cheer{
    animation: nb-cheer 0.6s ease-in-out infinite;
}

.share .box .badge{
    z-index: 2;
    font-size: 0.85rem;
    min-width: 1.4rem;
    height: 1.4rem;
}

.share .fair{
    display: block;
    margin: 0.4rem auto;
    font-size: 1.4rem;
    font-weight: 800;
    padding: 0.6rem 1.6rem;
    border-radius: 999px;
    background: var(--good);
    color: #fff;
    border: 3px solid #fff;
    -moz-box-shadow: 0 5px 0 #15803d;
    -o-box-shadow: 0 5px 0 #15803d;
    -webkit-box-shadow: 0 5px 0 #15803d;
    -ms-box-shadow: 0 5px 0 #15803d;
    box-shadow: 0 5px 0 #15803d;
    touch-action: manipulation;
    cursor: pointer;
}

.share .fair[hidden]{
    display: none;
}

.share .fair.ready{
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.share .question{
    text-align: center;
    font-weight: 800;
    font-size: 1.2rem;
    margin: 0.3rem 0 0;
    min-height: 1.4rem;
}

.share .numbers{
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.4rem;
    margin: 0.4rem 0;
}

.share .numbers[hidden]{
    display: none;
}

.share .numbers button{
    font-size: 1.8rem;
    font-weight: 800;
    min-height: 3.4rem;
    padding: 0;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--border-subtle);
    touch-action: manipulation;
    cursor: pointer;
}

.share .numbers button.guess{
    border-color: var(--pop);
    background: #ede7ff;
}

.share .numbers button.hint{
    border-color: var(--accent);
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.share .numbers button.good{
    border-color: var(--good);
    background: #f0fdf4;
    color: #15803d;
}

.share .numbers button.wrong{
    animation: nb-wobble 0.5s;
}

.share .said{
    min-height: 1.7rem;
    text-align: center;
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--pop);
}

.share .intro .taster{
    font-size: 2.6rem;
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    margin: 0.6rem 0;
}

.share .intro .level-name{
    font-weight: 800;
    color: var(--pop);
}

.share .intro .intro-words{
    font-size: 1.1rem;
    max-width: 26rem;
    margin: 0.4rem auto 0.8rem;
}

.share .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.share .results .reward{
    font-size: 4.5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.share .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.share .results .stars.s1, .share .results .stars.s2, .share .results .stars.s3{
    color: var(--gold);
}

@media (prefers-reduced-motion: reduce){
    .share .thing, .share .plate .face, .share .box.cheer, .share .fair.ready, .share .numbers button.hint, .share .results .reward{
        animation: none;
    }
}

@media (prefers-color-scheme: dark){
    .share .plate.turn{
        background: #3a2a14;
    }
    .share .plate.counting{
        background: #241a3d;
    }
    .share .numbers button.guess{
        background: #241a3d;
    }
    .share .numbers button.good{
        background: #14321f;
        color: #86efac;
    }
}

.story .pips{
    flex: 1 1 auto;
}

.story .book{
    margin: 0.6rem 0;
    padding: 0.9rem 1.1rem 1rem;
    border-radius: 1rem;
    background: #fffdf6;
    border: 2px solid #eadfc4;
    -moz-box-shadow: 0 3px 0 #eadfc4;
    -o-box-shadow: 0 3px 0 #eadfc4;
    -webkit-box-shadow: 0 3px 0 #eadfc4;
    -ms-box-shadow: 0 3px 0 #eadfc4;
    box-shadow: 0 3px 0 #eadfc4;
    color: #2a2418;
}

.story .book.turn{
    animation: nb-page 0.4s ease-out;
}

@keyframes nb-page{
    from{
        opacity: 0;
        -moz-transform: translateY(0.6rem);
        -o-transform: translateY(0.6rem);
        -webkit-transform: translateY(0.6rem);
        -ms-transform: translateY(0.6rem);
        transform: translateY(0.6rem);
    }
    to{
        opacity: 1;
        -moz-transform: none;
        -o-transform: none;
        -webkit-transform: none;
        -ms-transform: none;
        transform: none;
    }
}

.story .book .title{
    margin: 0 0 0.4rem;
    font-size: 1.05rem;
    font-weight: 800;
    color: #8a6d2f;
    letter-spacing: 0.02em;
}

.story .book .text{
    margin: 0;
    font-size: 1.45rem;
    line-height: 1.65;
    font-weight: 600;
}

.story .line{
    border-radius: 0.35rem;
    padding: 0.05rem 0.1rem;
    -moz-transition: background 0.25s, box-shadow 0.25s;
    -o-transition: background 0.25s, box-shadow 0.25s;
    -webkit-transition: background 0.25s, box-shadow 0.25s;
    -ms-transition: background 0.25s, box-shadow 0.25s;
    transition: background 0.25s, box-shadow 0.25s;
    box-decoration-break: clone;
}

.story .line.pickable{
    cursor: pointer;
    background: #dde8ff;
    -moz-box-shadow: inset 0 -3px 0 #6f93e0;
    -o-box-shadow: inset 0 -3px 0 #6f93e0;
    -webkit-box-shadow: inset 0 -3px 0 #6f93e0;
    -ms-box-shadow: inset 0 -3px 0 #6f93e0;
    box-shadow: inset 0 -3px 0 #6f93e0;
}

.story .line.clue{
    background: #ffe27a;
    -moz-box-shadow: inset 0 -3px 0 #e0a200;
    -o-box-shadow: inset 0 -3px 0 #e0a200;
    -webkit-box-shadow: inset 0 -3px 0 #e0a200;
    -ms-box-shadow: inset 0 -3px 0 #e0a200;
    box-shadow: inset 0 -3px 0 #e0a200;
}

.story .line.found{
    background: #b4ecc4;
    -moz-box-shadow: inset 0 -3px 0 #22c55e;
    -o-box-shadow: inset 0 -3px 0 #22c55e;
    -webkit-box-shadow: inset 0 -3px 0 #22c55e;
    -ms-box-shadow: inset 0 -3px 0 #22c55e;
    box-shadow: inset 0 -3px 0 #22c55e;
}

.story .line.missed{
    background: #ffd0d0;
}

.story .ask{
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    margin: 0.8rem 0 0.5rem;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.3;
}

.story .ask .n{
    flex: none;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--muted);
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: var(--surface-2);
}

.story .choices{
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.45rem;
}

.story .choice{
    text-align: left;
    font-size: 1.25rem;
    font-weight: 700;
    min-height: 3.2rem;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--border-subtle);
    touch-action: manipulation;
    cursor: pointer;
}

.story .choice:disabled{
    opacity: 0.55;
    cursor: default;
}

.story .choice.good{
    opacity: 1;
    border-color: var(--good);
    background: #f0fdf4;
    color: #15803d;
}

.story .choice.wrong{
    opacity: 1;
    border-color: var(--bad);
    animation: nb-wobble 0.5s;
}

.story .said{
    min-height: 1.6rem;
    margin: 0.6rem 0 0.3rem;
    text-align: center;
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--pop);
}

.story .said.good{
    color: #15803d;
}

.story .said.miss{
    color: var(--text);
    font-weight: 700;
}

.story .next{
    display: block;
    margin: 0.4rem auto;
    font-size: 1.3rem;
    padding: 0.7rem 2rem;
}

.story .next[hidden]{
    display: none;
}

.story .intro .taster{
    font-size: 3.4rem;
    margin: 0.6rem 0;
}

.story .intro .level-name{
    font-weight: 800;
    color: var(--pop);
}

.story .intro .intro-words{
    font-size: 1.1rem;
    max-width: 26rem;
    margin: 0.4rem auto 0.8rem;
}

.story .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.story .results .reward{
    font-size: 4.5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.story .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.story .results .stars.s1, .story .results .stars.s2, .story .results .stars.s3{
    color: var(--gold);
}

.story .results .clues-found{
    font-weight: 800;
    color: var(--pop);
}

@media (prefers-reduced-motion: reduce){
    .story .book.turn, .story .choice.wrong, .story .results .reward{
        animation: none;
    }
}

@media (prefers-color-scheme: dark){
    .story .book{
        background: #2a2418;
        border-color: #4a3f28;
        -moz-box-shadow: 0 3px 0 #4a3f28;
        -o-box-shadow: 0 3px 0 #4a3f28;
        -webkit-box-shadow: 0 3px 0 #4a3f28;
        -ms-box-shadow: 0 3px 0 #4a3f28;
        box-shadow: 0 3px 0 #4a3f28;
        color: #f5ecd7;
    }
    .story .book .title{
        color: #e0c27a;
    }
    .story .line.pickable{
        background: #1d2b45;
        -moz-box-shadow: inset 0 -2px 0 #4b6fb5;
        -o-box-shadow: inset 0 -2px 0 #4b6fb5;
        -webkit-box-shadow: inset 0 -2px 0 #4b6fb5;
        -ms-box-shadow: inset 0 -2px 0 #4b6fb5;
        box-shadow: inset 0 -2px 0 #4b6fb5;
    }
    .story .line.clue{
        background: #4a3a0a;
    }
    .story .line.found{
        background: #14321f;
    }
    .story .line.missed{
        background: #3d1a1a;
    }
    .story .choice.good{
        background: #14321f;
        color: #86efac;
    }
    .story .said.good{
        color: #86efac;
    }
}

.sounds .ask{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.3rem 0;
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.2;
    min-height: 2.8rem;
}

.sounds .ask .hear{
    min-height: 0;
    width: 2.4rem;
    height: 2.4rem;
    padding: 0;
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    background: var(--surface-2);
}

.sounds .card{
    min-height: 8rem;
    padding: 0.8rem 0.5rem;
    margin: 0.4rem 0 0.6rem;
}

.sounds .card .letter{
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.4rem;
    font-size: 6rem;
    font-weight: 800;
    line-height: 1;
    color: var(--pop);
    font-family: 'Comic Sans MS', 'Chalkboard SE', 'Segoe Print', 'Andika', sans-serif;
}

.sounds .card .letter small{
    font-size: 3rem;
    font-weight: 700;
    color: var(--muted);
}

.sounds .card .shown{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.sounds .card .shown .pic{
    font-size: 5rem;
    line-height: 1.2;
    -moz-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -o-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -webkit-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -ms-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
}

.sounds .card .shown .name{
    font-size: 1.6rem;
    font-weight: 800;
}

.sounds .card .shown .pic.many{
    display: grid;
    grid-template-columns: repeat(5, auto);
    justify-content: center;
    gap: 0.1em 0.15em;
    font-size: 3rem;
    line-height: 1.15;
}

.sounds .card .shown .pic.many i{
    font-style: normal;
}

.sounds .card .shown .pic.many.some{
    font-size: 2.5rem;
}

.sounds .card .shown .pic.many.lots{
    font-size: 1.9rem;
}

.sounds .card .listen{
    font-size: 4.5rem;
    line-height: 1.4;
}

.sounds .tiles.names{
    grid-template-columns: repeat(3, 1fr);
}

.sounds .tiles.names .glyph{
    font-size: 4.6rem;
}

.sounds .tiles{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    margin: 0.5rem 0;
}

.sounds .tiles button{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    min-height: 6.5rem;
    padding: 0.5rem 0.3rem;
    border-radius: 1.3rem;
    border: 3px solid var(--border-subtle);
    background: var(--surface);
    color: var(--text);
    font: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    touch-action: manipulation;
    -moz-transition: transform 0.1s;
    -o-transition: transform 0.1s;
    -webkit-transition: transform 0.1s;
    -ms-transition: transform 0.1s;
    transition: transform 0.1s;
}

.sounds .tiles button:active{
    -moz-transform: scale(0.95);
    -o-transform: scale(0.95);
    -webkit-transform: scale(0.95);
    -ms-transform: scale(0.95);
    transform: scale(0.95);
}

.sounds .tiles button .pic{
    font-size: 3.4rem;
    line-height: 1.2;
    -moz-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -o-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -webkit-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    -ms-filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
    filter: drop-shadow(0 0.08em 0.1em rgba(0,0,0,0.25));
}

.sounds .tiles button .glyph{
    font-size: 3.6rem;
    font-weight: 800;
    line-height: 1;
    color: var(--pop);
    font-family: 'Comic Sans MS', 'Chalkboard SE', 'Segoe Print', 'Andika', sans-serif;
}

.sounds .tiles button.hint{
    border-color: var(--accent);
    animation: nb-beckon 0.8s ease-in-out infinite;
}

.sounds .tiles button.good{
    border-color: var(--good);
    background: #f0fdf4;
}

.sounds .tiles button.wrong{
    animation: nb-wobble 0.5s;
}

.sounds .tiles button.cheer .pic, .sounds .tiles button.cheer .glyph{
    animation: nb-cheer 0.6s ease-in-out infinite;
}

.sounds .said{
    min-height: 1.7rem;
    text-align: center;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--pop);
}

.sounds .intro .abc{
    font-size: 3.2rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    color: var(--pop);
    font-family: 'Comic Sans MS', 'Chalkboard SE', 'Segoe Print', 'Andika', sans-serif;
}

.sounds .intro .label{
    color: var(--muted);
}

.sounds .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.sounds .results .reward{
    font-size: 4.5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.sounds .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.sounds .results .stars.s1, .sounds .results .stars.s2, .sounds .results .stars.s3{
    color: var(--gold);
}

@media (prefers-reduced-motion: reduce){
    .sounds .tiles button.hint, .sounds .tiles button.cheer .pic, .sounds .tiles button.cheer .glyph, .sounds .results .reward{
        animation: none;
    }
}

@media (prefers-color-scheme: dark){
    .sounds .tiles button.good{
        background: #14321f;
    }
}

@media (prefers-color-scheme: dark){
    .count .numbers button.good{
        background: #14321f;
        color: #86efac;
    }
}

@media (prefers-reduced-motion: reduce){
    .routine .stage.wait, .routine .things button.hint, .routine .results .reward, .routine .who .figure, .routine .mouth .tooth.now, .routine .mouth .tongue.now{
        animation: none;
    }
    .routine .map .walker, .routine .map .trail{
        -moz-transition: none;
        -o-transition: none;
        -webkit-transition: none;
        -ms-transition: none;
        transition: none;
    }
    .routine .drops, .routine .bubble.pop{
        display: none;
    }
}

@media (prefers-color-scheme: dark){
    .routine.princess{
        --r-card: #2a1830;
        --r-bg: linear-gradient(160deg, #3b1030, #2a1b4d);
    }
    .routine.pirate{
        --r-card: #102a3a;
        --r-bg: linear-gradient(160deg, #0b2a3a, #3a2a10);
    }
    .routine.superhero{
        --r-card: #111c3a;
        --r-bg: linear-gradient(160deg, #0f1f4d, #3a1a0b);
    }
    .routine .things button.good{
        background: #14321f;
    }
    .pill.hot{
        background: #3a1f0a;
        color: #fdba74;
    }
    .kinds label:has(input:checked), .modes label:has(input:checked){
        background: #241a3d;
    }
    .forms label:has(input:checked){
        background: #241a3d;
    }
    .map g.state path{
        fill: #475569;
        stroke: #1e293b;
    }
    .map g.outside path{
        fill: #2b3648;
        stroke: #1e293b;
    }
    .map g.state path.dot{
        fill: #7c8ca1;
    }
    .map.tappable g.state path:hover{
        fill: #64748b;
    }
    .hop .map g.state path.route{
        fill: #4c3d7a;
    }
    .hop .map g.labels text{
        fill: #f1f5f9;
        stroke: #0f172a;
    }
}
/* defstyles numbat-landing */
body.front{
    max-width: none;
    padding: 0;
}

body.front main{
    padding: 0;
}

body.front footer.athanor-feedback{
    max-width: 62rem;
    margin: 0 auto;
    padding: 1rem 1.25rem;
}

.landing{
    --pond: #2f9bd6;
    --pond-deep: #1b6fa8;
    --pad: #43b04a;
    --ink-on-pond: #fff;
}

.landing .wrap{
    max-width: 62rem;
    margin: 0 auto;
    padding: 0 1.25rem;
    box-sizing: border-box;
}

.landing section{
    padding: 3.5rem 0;
}

.landing section.wrap{
    padding: 3.5rem 1.25rem;
}

.landing h2{
    font-size: clamp(1.6rem, 3.6vw, 2.2rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    text-transform: none;
    color: var(--text);
    margin: 0 0 0.6rem;
    text-wrap: balance;
}

.landing h3{
    font-size: 1.15rem;
    margin: 0 0 0.3rem;
}

.landing p{
    font-size: 1.05rem;
    margin: 0 0 0.8rem;
    max-width: 38rem;
}

.landing .sub{
    color: var(--muted);
    margin-bottom: 1.6rem;
}

.landing .tint{
    background: var(--surface-2);
}

.landing .pond{
    color: var(--ink-on-pond);
    position: relative;
    overflow: hidden;
    background: linear-gradient(170deg, var(--pond), var(--pond-deep));
}

.landing .pond .wrap{
    position: relative;
    z-index: 1;
}

.landing .pad{
    position: absolute;
    fill: var(--pad);
    -moz-filter: drop-shadow(0 5px 0 rgba(10,50,80,0.28));
    -o-filter: drop-shadow(0 5px 0 rgba(10,50,80,0.28));
    -webkit-filter: drop-shadow(0 5px 0 rgba(10,50,80,0.28));
    -ms-filter: drop-shadow(0 5px 0 rgba(10,50,80,0.28));
    filter: drop-shadow(0 5px 0 rgba(10,50,80,0.28));
}

.landing .pad.one{
    width: 13rem;
    right: -4rem;
    bottom: -1.6rem;
    -moz-transform: rotate(-4deg);
    -o-transform: rotate(-4deg);
    -webkit-transform: rotate(-4deg);
    -ms-transform: rotate(-4deg);
    transform: rotate(-4deg);
}

.landing .pad.two{
    width: 7rem;
    left: 3%;
    bottom: 0.6rem;
    -moz-transform: rotate(8deg) scaleX(-1);
    -o-transform: rotate(8deg) scaleX(-1);
    -webkit-transform: rotate(8deg) scaleX(-1);
    -ms-transform: rotate(8deg) scaleX(-1);
    transform: rotate(8deg) scaleX(-1);
}

.landing .pad.three{
    width: 3.5rem;
    left: 40%;
    bottom: 1.6rem;
    opacity: 0.85;
}

.landing .pond h1, .landing .pond h2{
    color: var(--ink-on-pond);
}

.landing .pond a:not(.primary){
    color: var(--ink-on-pond);
}

.landing .top{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
}

.landing .brand{
    display: inline-flex;
}

.landing .brand img{
    display: block;
}

.landing .login{
    font-weight: 700;
    text-decoration: none;
    padding: 0.45rem 1rem;
    border: 2px solid rgba(255,255,255,0.7);
    border-radius: 999px;
}

.landing .login:hover{
    background: rgba(255,255,255,0.16);
}

.landing .hero-grid{
    display: grid;
    gap: 2rem;
    padding: 1.5rem 0 4.5rem;
}

.landing h1{
    font-size: clamp(2.4rem, 6.4vw, 4rem);
    line-height: 1.02;
    letter-spacing: -0.035em;
    margin: 0 0 1rem;
    text-wrap: balance;
}

.landing .lede{
    font-size: clamp(1.1rem, 2.2vw, 1.3rem);
    line-height: 1.45;
    margin-bottom: 1.4rem;
}

.landing .pitch .primary, .landing .last .primary{
    max-width: 22rem;
}

.landing .pitch .primary{
    margin-top: 1.6rem;
}

.landing .have{
    font-size: 0.95rem;
    margin: 1rem 0 0;
    opacity: 0.92;
}

.landing .facts{
    list-style: none;
    padding: 0;
    margin: 1.4rem 0 0;
    display: grid;
    gap: 0.3rem;
    font-weight: 600;
}

.landing .facts li{
    display: flex;
    gap: 0.5em;
}

.landing .facts li::before{
    content: "✓";
    font-weight: 800;
}

.landing .try-label{
    font-weight: 800;
    margin: 0 0 0.5rem;
    font-size: 1rem;
}

.demo{
    background: var(--bg);
    color: var(--text);
    border-radius: 1.6rem;
    padding: 1rem;
    -moz-box-shadow: 0 18px 40px rgba(8,40,70,0.35);
    -o-box-shadow: 0 18px 40px rgba(8,40,70,0.35);
    -webkit-box-shadow: 0 18px 40px rgba(8,40,70,0.35);
    -ms-box-shadow: 0 18px 40px rgba(8,40,70,0.35);
    box-shadow: 0 18px 40px rgba(8,40,70,0.35);
    max-width: 26rem;
}

.demo-head{
    display: flex;
    align-items: center;
    gap: 0.7rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.demo-combo.hot{
    color: #c2410c;
}

.demo-xp{
    color: var(--pop);
}

.demo-pips{
    flex: 1 1 auto;
    display: flex;
    gap: 3px;
    height: 0.5rem;
}

.demo-pips i{
    flex: 1 1 0;
    border-radius: 3px;
    background: var(--surface-2);
}

.demo-pips i.ok{
    background: var(--good);
}

.demo-pips i.no{
    background: var(--bad);
}

.demo-card{
    margin: 0.8rem 0;
    padding: 1.3rem 0.5rem 1rem;
    border-radius: 1.3rem;
    text-align: center;
    border: 2px solid var(--border-subtle);
    background: var(--surface);
}

.demo-card.good{
    border-color: var(--good);
    animation: nb-pop 0.25s;
}

.demo-card.bad{
    border-color: var(--bad);
    animation: nb-shake 0.35s;
}

.demo-q{
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.demo-say{
    min-height: 1.5em;
    margin-top: 0.3rem;
    font-weight: 700;
    color: var(--muted);
}

.demo-card.good .demo-say{
    color: var(--good);
}

.demo-card.bad .demo-say{
    color: var(--bad);
}

.demo-choices{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
}

.demo-choices button{
    font-size: 1.7rem;
    font-weight: 800;
    padding: 0.7rem 0;
    border-radius: 1rem;
    border: 2px solid var(--border-subtle);
    background: var(--surface-2);
    color: var(--text);
    cursor: pointer;
    font-variant-numeric: tabular-nums;
    -moz-box-shadow: 0 4px 0 var(--border-subtle);
    -o-box-shadow: 0 4px 0 var(--border-subtle);
    -webkit-box-shadow: 0 4px 0 var(--border-subtle);
    -ms-box-shadow: 0 4px 0 var(--border-subtle);
    box-shadow: 0 4px 0 var(--border-subtle);
}

.demo-choices button:hover:not(:disabled){
    border-color: var(--pop);
}

.demo-choices button:focus-visible{
    outline: 3px solid var(--pop);
    outline-offset: 2px;
}

.demo-choices button:active:not(:disabled){
    -moz-transform: translateY(3px);
    -o-transform: translateY(3px);
    -webkit-transform: translateY(3px);
    -ms-transform: translateY(3px);
    transform: translateY(3px);
    -moz-box-shadow: 0 1px 0 var(--border-subtle);
    -o-box-shadow: 0 1px 0 var(--border-subtle);
    -webkit-box-shadow: 0 1px 0 var(--border-subtle);
    -ms-box-shadow: 0 1px 0 var(--border-subtle);
    box-shadow: 0 1px 0 var(--border-subtle);
}

.demo-choices button.good{
    background: var(--good);
    border-color: var(--good);
    color: #fff;
    -moz-box-shadow: 0 4px 0 #15803d;
    -o-box-shadow: 0 4px 0 #15803d;
    -webkit-box-shadow: 0 4px 0 #15803d;
    -ms-box-shadow: 0 4px 0 #15803d;
    box-shadow: 0 4px 0 #15803d;
}

.demo-choices button.bad{
    background: var(--bad);
    border-color: var(--bad);
    color: #fff;
    -moz-box-shadow: 0 4px 0 #b91c1c;
    -o-box-shadow: 0 4px 0 #b91c1c;
    -webkit-box-shadow: 0 4px 0 #b91c1c;
    -ms-box-shadow: 0 4px 0 #b91c1c;
    box-shadow: 0 4px 0 #b91c1c;
}

.demo-end{
    text-align: center;
    padding: 0.4rem 0.4rem 0.2rem;
}

.demo-end[hidden], .demo-choices[hidden], .demo-card[hidden]{
    display: none;
}

.demo-score{
    font-size: 1.7rem;
    font-weight: 800;
    margin: 0.8rem 0 0.4rem;
}

.landing .demo-end p{
    font-size: 0.95rem;
    color: var(--muted);
    margin: 0 auto 1rem;
}

.demo-again{
    display: block;
    margin: 1rem auto 0;
}

.landing .groups{
    display: grid;
    gap: 1.2rem;
}

.landing .group{
    padding: 1.3rem;
    border-radius: 1.3rem;
    border: 2px solid var(--border-subtle);
}

.landing .group p{
    font-size: 0.98rem;
    color: var(--muted);
}

.landing .chips{
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.landing .chips li{
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-weight: 700;
    font-size: 0.92rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    background: var(--surface-2);
}

.landing .reasons{
    display: grid;
    gap: 1.2rem;
    margin-top: 1.4rem;
}

.landing .reason{
    background: var(--bg);
    border-radius: 1.3rem;
    padding: 1.3rem;
}

.landing .reason p{
    font-size: 0.98rem;
    margin: 0;
}

.landing .ladder, .landing .badges, .landing .clock{
    min-height: 5.2rem;
    margin-bottom: 1rem;
}

.landing .ladder{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.35rem;
}

.landing .ladder span{
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    border-radius: 0.6rem;
    color: #14321f;
    font-variant-numeric: tabular-nums;
}

.landing .ladder .b1{
    background: var(--rung-1);
}

.landing .ladder .b2{
    background: var(--rung-2);
}

.landing .ladder .b3{
    background: var(--rung-3);
}

.landing .ladder .b4{
    background: var(--rung-4);
}

.landing .ladder .b5{
    background: var(--rung-5);
    color: #fff;
}

.landing .ladder .miss{
    background: var(--rung-miss);
    color: #7c2d12;
}

.landing .clock{
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.5rem;
}

.landing .clock b{
    font-size: 2.2rem;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.landing .clock i{
    display: block;
    height: 0.7rem;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent) 72%, var(--surface-2) 72%);
}

.landing .badges{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.35rem;
}

.landing .badges span{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    border-radius: 0.6rem;
    background: var(--surface-2);
    padding: 0.25rem 0.1rem;
}

.landing .badges i{
    font-style: normal;
    font-size: 1.25rem;
    line-height: 1.2;
}

.landing .split{
    display: grid;
    gap: 1.8rem;
    align-items: center;
}

.landing .faces{
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.6rem;
}

.landing .faces svg.face{
    -moz-box-shadow: 0 4px 12px rgba(0,0,0,0.14);
    -o-box-shadow: 0 4px 12px rgba(0,0,0,0.14);
    -webkit-box-shadow: 0 4px 12px rgba(0,0,0,0.14);
    -ms-box-shadow: 0 4px 12px rgba(0,0,0,0.14);
    box-shadow: 0 4px 12px rgba(0,0,0,0.14);
}

.landing .faces svg.face:nth-child(odd){
    -moz-transform: rotate(-3deg);
    -o-transform: rotate(-3deg);
    -webkit-transform: rotate(-3deg);
    -ms-transform: rotate(-3deg);
    transform: rotate(-3deg);
}

.landing .faces svg.face:nth-child(even){
    -moz-transform: rotate(3deg) translateY(0.5rem);
    -o-transform: rotate(3deg) translateY(0.5rem);
    -webkit-transform: rotate(3deg) translateY(0.5rem);
    -ms-transform: rotate(3deg) translateY(0.5rem);
    transform: rotate(3deg) translateY(0.5rem);
}

.landing .cast{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.6rem;
}

.landing .cast img{
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 1.2rem;
}

.landing .parents{
    list-style: none;
    padding: 0;
    margin: 1.2rem 0 0;
    display: grid;
    gap: 1rem;
}

.landing .parents li{
    padding: 1.1rem 1.3rem;
    border-radius: 1.3rem;
    background: var(--surface-2);
    font-size: 1rem;
}

.landing .last{
    text-align: center;
    padding: 4rem 0 6rem;
}

.landing .last p{
    margin-left: auto;
    margin-right: auto;
}

.landing .last .primary{
    margin: 1.4rem auto 0;
}

@media (min-width: 48rem){
    .landing .hero-grid{
        grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
        align-items: center;
        gap: 3rem;
        padding: 2.5rem 0 6rem;
    }
    .landing .pad.one{
        width: 30rem;
        right: -7rem;
        bottom: -3.5rem;
    }
    .landing .pad.two{
        width: 11rem;
        bottom: 1.2rem;
    }
    .landing .pad.three{
        width: 5.5rem;
        left: 34%;
        bottom: 3.4rem;
    }
    .demo{
        margin-left: auto;
    }
    .landing .try-label{
        max-width: 26rem;
        margin-left: auto;
    }
    .landing .reasons, .landing .parents{
        grid-template-columns: repeat(3, 1fr);
    }
    .landing .groups{
        grid-template-columns: 2fr 1fr 1fr;
    }
    .landing .split{
        grid-template-columns: 1fr 1fr;
        gap: 3rem;
    }
    .landing .split.flip > :first-child{
        order: 2;
    }
}

@media (prefers-reduced-motion: reduce){
    .demo-card.good, .demo-card.bad{
        animation: none;
    }
}
/* defstyles plot */
.setup .print-sheet{
    display: block;
    margin: 1rem auto 0;
}

.toolbar{
    margin: 0.8rem 0 1.2rem;
}

.toolbar .row{
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 0.9rem;
    flex-wrap: wrap;
}

.sheet .page{
    margin-bottom: 2rem;
}

.sheet h1{
    margin-bottom: 0.2rem;
}

.sheet .who{
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    color: var(--muted);
    border-bottom: 1px dashed var(--border);
    padding-bottom: 0.3rem;
}

.sheet .who b{
    color: var(--text);
}

.sheet .how{
    margin: 0.6rem 0;
    line-height: 1.4;
}

.sheet .grids{
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: center;
    margin: 0.6rem 0;
}

.sheet figure{
    margin: 0;
    text-align: center;
}

.sheet.picture figure{
    width: 100%;
    max-width: 26rem;
}

.sheet.word figure{
    width: 7rem;
}

.sheet figcaption{
    font-size: 0.8rem;
    color: var(--muted);
}

svg.grid{
    display: block;
    width: 100%;
    height: auto;
    background: #fff;
}

svg.grid line{
    stroke: #c8ccd2;
    stroke-width: 0.5;
}

svg.grid line.axis{
    stroke: #555;
    stroke-width: 0.9;
}

svg.grid text{
    fill: #555;
    font-size: 5px;
    font-family: system-ui, sans-serif;
}

svg.grid .ink{
    fill: none;
    stroke: #222;
    stroke-width: 1.4;
    stroke-linejoin: round;
    stroke-linecap: round;
}

svg.grid .dot{
    fill: #222;
}

svg.grid text.dot-n{
    fill: var(--pop);
    font-size: 4px;
    font-weight: 700;
}

.sheet .dots{
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1.2rem;
}

.sheet .dots .panel{
    flex: 1 1 100%;
}

.sheet.word .dots .panel{
    flex: 1 1 14rem;
}

.sheet .dots h3{
    font-size: 0.9rem;
    margin: 0.4rem 0 0.2rem;
}

.sheet .dots ul{
    list-style: none;
    padding: 0;
    margin: 0;
    columns: 2;
    column-gap: 1.2rem;
}

.sheet.word .dots ul{
    columns: 1;
}

.sheet .dots li{
    padding: 0.25rem 0;
    break-inside: avoid;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.sheet .dots .n{
    display: inline-block;
    min-width: 1.6rem;
}

.sheet .dots .hand{
    margin-right: 0.2rem;
}

.sheet .dots .way{
    font-size: 0.8em;
    margin: 0 0.2rem 0 0.5rem;
}

.sheet .dots .back{
    color: var(--muted);
    font-style: italic;
}

.sheet .blank{
    display: inline-block;
    width: 1.8rem;
    height: 1.1em;
    vertical-align: -0.2em;
    border: 1.5px solid var(--border);
    border-radius: 0.25rem;
    margin: 0 0.15rem;
}

.sheet .key .dots li{
    padding: 0.1rem 0;
}

@media print{
    nav, .toolbar, footer.athanor-feedback{
        display: none;
    }
    body{
        max-width: none;
        margin: 0;
        padding: 0;
        background: #fff;
        color: #000;
        font-size: 11pt;
    }
    .sheet .page{
        break-after: page;
        margin: 0;
    }
    .sheet .page:last-child{
        break-after: auto;
    }
    .sheet h1{
        font-size: 18pt;
        margin-top: 0;
    }
    .sheet.picture figure{
        max-width: 11cm;
    }
    .sheet .dots li{
        padding: 0.15rem 0;
    }
    .sheet.word figure{
        width: 3.6cm;
    }
    .sheet .who, .sheet .dots .back, .sheet figcaption{
        color: #333;
    }
    .sheet .blank{
        border-color: #555;
    }
}
/* defstyles writing-probe */
.probe .how{
    margin: 0.4rem 0 0.8rem;
    line-height: 1.4;
}

.probe .grips{
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-bottom: 0.8rem;
}

.probe .grip{
    border: 3px solid var(--ink);
    background: var(--surface, white);
    color: var(--text);
}

.probe .grip.on{
    background: var(--ink);
    color: white;
}

.probe .writer{
    border: 3px solid #475569;
    background: var(--surface, white);
    color: var(--text);
}

.probe .writer.on{
    background: #475569;
    color: white;
}

.probe .paper{
    display: block;
    width: 100%;
    height: 60vh;
    min-height: 20rem;
    background: white;
    border: 1px solid var(--border);
    border-radius: 0.8rem;
    touch-action: none;
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.probe .row{
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin: 0.8rem 0;
}

.probe .live{
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 0.2rem 1rem;
    font-variant-numeric: tabular-nums;
    margin: 0.6rem 0;
}

.probe .live dt{
    color: var(--muted);
}

.probe .live dd{
    margin: 0;
    font-weight: 700;
}

.probe .summary{
    border-collapse: collapse;
    font-variant-numeric: tabular-nums;
    display: block;
    overflow-x: auto;
    max-width: 100%;
}

.probe .summary th, .probe .summary td{
    padding: 0.3rem 0.5rem;
    text-align: right;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

.probe .summary tbody th{
    text-align: left;
}

.probe .caps{
    font-size: 0.8rem;
    word-break: break-word;
}
/* defstyles writing */
.write .pips{
    flex: 1 1 auto;
}

.write .intro .taster{
    font-size: 3.4rem;
    margin: 0.6rem 0;
}

.write .intro .level-name{
    font-weight: 800;
    color: var(--pop);
}

.write .intro .intro-words{
    font-size: 1.1rem;
    max-width: 28rem;
    margin: 0.4rem auto 0.8rem;
}

.write .pinch{
    max-width: 28rem;
    margin: 0.4rem auto 1rem;
    padding: 0.8rem 1rem 1rem;
    border-radius: 1rem;
    background: var(--surface-2);
    border: 2px solid var(--border-subtle);
    text-align: left;
}

.write .pinch h2{
    margin: 0 0 0.4rem;
    font-size: 1.1rem;
    text-align: center;
}

.write .pinch ol{
    list-style: none;
    margin: 0 0 0.8rem;
    padding: 0;
    display: grid;
    gap: 0.45rem;
}

.write .pinch li{
    display: flex;
    gap: 0.6rem;
    align-items: center;
    font-size: 1.05rem;
    font-weight: 600;
}

.write .pinch .icon{
    font-size: 1.8rem;
    flex: none;
    width: 2.2rem;
    text-align: center;
}

.write .thumbs{
    display: block;
    width: 100%;
    font-size: 1.05rem;
    padding: 0.6rem 0.8rem;
    border-radius: 0.8rem;
    border: 2px dashed var(--border);
    background: var(--surface);
    color: var(--text);
    cursor: pointer;
}

.write .thumbs.on{
    border: 2px solid #22c55e;
    background: #f0fdf4;
    color: #15803d;
    font-weight: 800;
}

.write .go{
    font-size: 1.6rem;
    padding: 1rem 1.2rem;
}

.write .task{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin: 0.6rem 0 0.4rem;
}

.write .ask{
    margin: 0;
    font-size: 1.4rem;
    font-weight: 800;
    text-align: center;
}

.write .hear{
    font-size: 1.4rem;
    padding: 0.2rem 0.5rem;
}

.write .paper{
    display: block;
    position: relative;
    left: 50%;
    -moz-transform: translateX(-50%);
    -o-transform: translateX(-50%);
    -webkit-transform: translateX(-50%);
    -ms-transform: translateX(-50%);
    transform: translateX(-50%);
    width: min(96vw, 64rem);
    height: min(64vh, 36rem);
    min-height: 18rem;
    background: white;
    border: 2px solid var(--border-subtle);
    border-radius: 1rem;
    touch-action: none;
    -moz-user-select: none;
    -o-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.write .paper.sentence{
    height: min(48vh, 28rem);
    min-height: 16rem;
}

.write .said{
    min-height: 1.7rem;
    margin: 0.6rem 0 0.3rem;
    text-align: center;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--pop);
}

.write .checks{
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin: 0.6rem 0 0;
}

.write .checks[hidden]{
    display: none;
}

.write .checks span{
    padding: 0.25rem 0.8rem;
    border-radius: 999px;
    font-weight: 800;
    border: 2px solid var(--border-subtle);
    color: var(--muted);
}

.write .checks .ok{
    border-color: #22c55e;
    background: #f0fdf4;
    color: #15803d;
}

.write .checks .no{
    border-color: #ef4444;
    background: #fef2f2;
    color: #b91c1c;
}

.write .said.good{
    color: #15803d;
}

.write .said.miss{
    color: var(--text);
    font-weight: 700;
}

.write .said .stars{
    color: var(--gold);
    letter-spacing: 0.05em;
}

.write .row{
    display: flex;
    gap: 0.8rem;
    justify-content: center;
    flex-wrap: wrap;
}

.write .row button{
    font-size: 1.2rem;
    padding: 0.6rem 1.4rem;
}

.write .row button[hidden]{
    display: none;
}

.write .results .reward{
    font-size: 4.5rem;
    line-height: 1;
    animation: nb-gem 0.7s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}

.write .results .stars{
    font-size: 2.6rem;
    letter-spacing: 0.05em;
    color: var(--border);
}

.write .results .stars.s1, .write .results .stars.s2, .write .results .stars.s3{
    color: var(--gold);
}

@media (prefers-reduced-motion: reduce){
    .write .results .reward{
        animation: none;
    }
}

@media (prefers-color-scheme: dark){
    .write .thumbs.on{
        background: #14321f;
        color: #86efac;
    }
}