/* punk.css — what THUD CORE's skins share (2026-10-11): Settings › The skin, the hero's living picture, the intro's scene.
   Each skin's faces and material are its own sheet (punk-steam.css, punk-cyber.css); its tokens are frap.css's, priced by
   verify_contrast.py in Night, Dawn and Field mode. Dieselpunk is THUD DEF's own look, untouched. */

/* ── Settings › The skin: six pictures, each a radio (Mobbin: Outlook’s, Binance’s and Matter’s theme pickers); two by two
   on a phone, three abreast where there is room ── */
.skins { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 14px; }
@media (min-width: 640px) { .skins { grid-template-columns: repeat(3, minmax(0, 1fr)); } }   /* six skins: two rows of three */
/* the two families, each a grid under its name and what it is (punk.js FAMILIES) */
.skins-fam + .skins-fam { border-top: 1px solid var(--line); }
.skins-fam__h { display: grid; gap: 2px; margin: 0; padding: 14px 16px 0; }
.skins-fam__h b { font-size: calc(15px + 15 * var(--tz, 0px)); font-weight: 650; color: var(--ink); }
.skins-fam__h span { font-size: calc(13px + 13 * var(--tz, 0px)); line-height: 1.35; color: var(--ink-2); }
.skin { -webkit-appearance: none; appearance: none; border: 0; margin: 0; padding: 0; background: none; color: var(--ink); font: inherit;
  text-align: center; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.skin__pv { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: 16px; overflow: hidden; background: var(--frost-off);
  box-shadow: 0 0 0 1px rgba(var(--tint), .14), var(--cast); transition: box-shadow .3s ease, transform .3s ease; }
.skin__pv img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.16, 1, .3, 1); }
.skin:hover .skin__pv img { transform: scale(1.045); }
.skin:active .skin__pv { transform: scale(.98); }
.skin[aria-checked="true"] .skin__pv { box-shadow: 0 0 0 2px var(--acc-3), 0 0 0 6px color-mix(in srgb, var(--acc-3) 20%, transparent), 0 14px 32px -12px var(--glow); }
.skin:focus-visible { outline: none; }
.skin:focus-visible .skin__pv { box-shadow: 0 0 0 3px var(--acc-ink), var(--cast); }
.skin__name { display: block; margin-top: 10px; font-weight: 700; font-size: calc(14px + 14 * var(--tz, 0px)); }
.skin[aria-checked="true"] .skin__name { color: var(--acc-ink); }
.skin__sub { display: block; margin-top: 2px; font-size: calc(12px + 12 * var(--tz, 0px)); line-height: 1.3; color: var(--ink-2); }

/* ── the hero alive (thud.js liveScene): the same picture as the still beneath, so the canvas fades in over it unseen ── */
.def-hero__field { opacity: 0; transition: opacity 1.2s ease; }
.def-hero__field.drawn { opacity: 1; }
/* run 4: every skin's hero is its opening scene (punk-scape.js), Dieselpunk's too: the still beneath sits as the canvas does,
   without THUD DEF's breath; THUD DEF's embers over it went on 2026-11-11 (sparks over a city at night read as fire) */
.def-hero__art img { object-position: 50% 50%; animation: none; }

/* ── the intro's scene (thud-intro.js scene()): the skin's still, alive, pushing in as the still does ── */
.intro__scene { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 1s ease, filter 1.1s ease .12s; }
.intro--still .intro__scene.drawn { opacity: 1; animation: def-push 4.4s linear both; }
.intro--hit .intro__scene { filter: brightness(.2) saturate(1.1) blur(7px); }
.intro--calm .intro__scene { display: none; }
/* the hero's slow breath belongs to the still alone: the living picture has its own motion, and both must stay one picture */
.def-hero__field { animation: none !important; }

/* ── the name in the intro, in each skin's light: engraved brass; neon ── */
html[data-palette="steam"] .intro__thud { font-family: "Playfair PUNK", Georgia, serif; font-weight: 900; letter-spacing: .02em;
  background-image: linear-gradient(180deg, #fff6dc 0%, #f4d98f 28%, #c9a04e 52%, #8a5a1c 70%, #e8c77a 86%, #7a5420 100%); }
html[data-palette="steam"] .intro__arms > i { background-image: linear-gradient(180deg, #fff6dc 0%, #f4d98f 28%, #c9a04e 52%, #8a5a1c 70%, #e8c77a 86%, #7a5420 100%); }
html[data-palette="steam"] .intro__def { font-family: "Playfair SC PUNK", Georgia, serif; font-weight: 400; text-transform: lowercase; letter-spacing: .5em; }
/* the faintest of the six names (HANDOFF, 2026-10-21): its small capitals have one weight, so it is set larger, in brass, lamplit */
html[data-palette="steam"] .intro__def { font-size: clamp(14px, 1.1vw + 10px, 22px); color: #f4d98f; text-shadow: 0 1px 0 rgba(0, 0, 0, .6), 0 0 14px rgba(255, 190, 90, .45); }
html[data-palette="steam"] .intro__rule { background: linear-gradient(90deg, transparent, #c9a04e, transparent); }
html[data-palette="cyber"] .intro__thud { font-family: "Inter DEF", "Inter", sans-serif; font-weight: 900; letter-spacing: .08em;
  background-image: linear-gradient(180deg, #ffffff 0%, #d2f7ff 30%, #45e3ff 55%, #8f7bff 76%, #ff5ad9 100%); }
html[data-palette="cyber"] .intro__arms > i { background-image: linear-gradient(180deg, #ffffff 0%, #d2f7ff 30%, #45e3ff 55%, #8f7bff 76%, #ff5ad9 100%); }
html[data-palette="cyber"] .intro--mark .intro__thud, html[data-palette="cyber"] .intro--mark .intro__arms > i { animation-name: punk-neon; }
html[data-palette="cyber"] .intro__arms { filter: drop-shadow(0 0 18px rgba(69, 227, 255, .45)); }
@keyframes punk-neon {
  0% { background-position: 0 0; filter: brightness(1.6) drop-shadow(0 0 30px rgba(69, 227, 255, .9)); }
  8% { filter: brightness(.6) drop-shadow(0 0 8px rgba(255, 90, 217, .6)); }
  14% { filter: brightness(1.5) drop-shadow(0 0 26px rgba(69, 227, 255, .85)); }
  100% { background-position: 0 70%; filter: brightness(1) drop-shadow(0 0 18px rgba(69, 227, 255, .45)) drop-shadow(0 0 2px rgba(255, 90, 217, .6)); } }
html[data-palette="cyber"] .intro__rule { background: linear-gradient(90deg, transparent, #45e3ff, #ff5ad9, transparent); }
/* the Debrief's eyebrow clears the cheering bird on a phone (thud.css .cheer stands at the top's right, 92 px wide, over the
   eyebrow's end): THUD CORE's own mend, in every skin; THUD DEF keeps the overlap until the owner carries this over */
/* QUIZ.md 6b: the bird stands beside the score now, under the eyebrow, which takes the width (the drill's name a chip) */
/* there the eyebrow is over the box, so the figure rises no higher than its box (thud.css .cheer img: 18 px over it elsewhere) */
@media (max-width: 560px) { .fr-res__top:has(> .cheer) > .eyebrow { padding-inline: 8px; text-wrap: balance; } .fr-res__top > .cheer { top: 78px; } .fr-res__top > .cheer img { max-height: 100%; } }

/* ── Words and Grammar, two modes (box G, 2026-10-16): the switch heading Learn, Review and Record (frap.js modesHtml);
   the mode in use filled with the accent, the other a word to tap, a dot on it when it has something due ── */
.modes { display: flex; flex-wrap: wrap; justify-content: center; width: max-content; max-width: 100%; margin: 2px auto 16px; padding: 4px; gap: 2px; border-radius: 999px; }
.modes__thumb { display: none; }
.modes__m { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 0 20px; border-radius: 999px; color: var(--ink-2);
  font-weight: 650; font-size: calc(15px + 15 * var(--tz, 0px)); letter-spacing: .01em; text-decoration: none; -webkit-tap-highlight-color: transparent;
  transition: color .2s ease, background-color .25s ease, box-shadow .25s ease; }
.modes__m[aria-current="page"] { color: var(--on-acc); background: var(--acc-2); box-shadow: 0 6px 16px -8px var(--glow); }
.modes__m:not([aria-current]):hover { color: var(--ink); }
.modes__m:focus-visible { outline: 2px solid var(--acc-ink); outline-offset: 2px; }
.modes__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--rwd-3); box-shadow: 0 0 8px var(--rwd-glow); }
/* on the home the header floats over the hero (thud-def.css .top--def): the switch is its second row, centred */
.top--def:has(.modes) { flex-wrap: wrap; row-gap: 10px; }
.top--def .modes { order: 9; margin: 0 auto; }
@media (prefers-reduced-motion: reduce) { .modes__m { transition: none; } }


/* the wallpapers' choice (frap-glass.js wallSeg): in Settings and in a set's options, under its row */
.set-wall, .group > .seg:has([data-wall]), .group > .seg:has([data-ram-set]) { margin: 0 12px 12px; }

/* your companion (thud.js ramTiles, Settings): the stork and the firebird, each in the seven materials, any in any skin:
   a row of four and a row of three; a calm skin's two birds side by side */
.rams { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 2px 12px 12px; }
.rams:has(> .ram-tile:nth-child(2):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ram-tile { -webkit-appearance: none; appearance: none; border: 0; margin: 0; padding: 8px 4px 6px; background: rgba(var(--tint), .05); color: var(--ink-2);
  border-radius: 14px; display: grid; justify-items: center; gap: 4px; font: inherit; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(var(--tint), .08); }
.ram-tile img { width: min(64px, 100%); height: auto; display: block; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .45)); }
.ram-tile__name { font-size: calc(12.5px + 12.5 * var(--tz, 0px)); font-weight: 650; }
.ram-tile__sub { font-size: calc(11px + 11 * var(--tz, 0px)); color: var(--ink-3); margin-top: -3px; }
.ram-tile[aria-checked="true"] { color: var(--ink); box-shadow: inset 0 0 0 2px var(--acc-3); background: rgba(var(--acc-rgb), .12); }
.rams__h { margin: 2px 16px 6px; font: 600 calc(11px + 11 * var(--tz, 0px))/1.3 var(--caps, var(--ui)); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.rams__own { display: block; margin: -4px auto 12px; border: 0; background: none; color: var(--acc-ink); font: inherit; font-size: calc(13px + 13 * var(--tz, 0px)); font-weight: 600; cursor: pointer; }

/* the briefing's Ready: the learner's name, optional (punk-cert.js, RUN4.md box N) */
.fl__name { display: grid; gap: 6px; width: min(100%, 22em); margin: 18px auto 0; text-align: left; }
.fl__name-l { font-size: calc(13px + 13 * var(--tz, 0px)); color: var(--ink-2); }
.fl__name-l i { font-style: normal; color: var(--ink-3); }
.fl__name-in { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line, rgba(255,255,255,.18));
  background: var(--field, rgba(255,255,255,.07)); color: var(--ink); font: inherit; font-size: calc(17px + 17 * var(--tz, 0px)); }
.fl__name-in:focus { outline: 2px solid var(--acc-ink); outline-offset: 1px; }

/* ── the look, one tap away (frap-look.js, 2026-10-19; Mobbin: Apple Books' «Themes & Settings»): the skin as pictures,
   the card's typeface as «Aa» in its own face, each a row that scrolls sideways, the selected one ringed ── */
.lk .ss__label { margin: 16px 0 8px; }
.lk-row { display: flex; gap: 10px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; scrollbar-width: none;
  margin: 0 -20px; padding: 4px 20px 6px; scroll-padding-inline: 20px; }
.lk-row::-webkit-scrollbar { display: none; }
/* the two families (punk.js FAMILIES): a caption over the first tile of each, travelling with the row; a hairline and
   a little air where the second begins. The caption takes no width, so the tiles keep their places in the row. */
.lk-row--fam { padding-top: 26px; }
.lk-fam { flex: 0 0 0; width: 0; margin-right: -10px; position: relative; pointer-events: none; }
.lk-fam i { position: absolute; left: 0; top: -21px; white-space: nowrap; font-style: normal; font-size: calc(11px + 11 * var(--tz, 0px)); font-weight: 650;
  letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.lk-fam:not(:first-child) { margin: 0 2px 0 12px; border-left: 1px solid var(--line); }
.lk-fam:not(:first-child) i { left: 12px; }
.lk-skin, .lk-face, .lk-wall { -webkit-appearance: none; appearance: none; border: 0; margin: 0; padding: 0; background: none; color: var(--ink);
  font: inherit; cursor: pointer; flex: 0 0 auto; scroll-snap-align: start; text-align: center; -webkit-tap-highlight-color: transparent; }
.lk-skin { width: 84px; }
.lk-skin__pv, .lk-wall__pv { position: relative; display: block; border-radius: 14px; overflow: hidden; background: var(--frost-off);
  box-shadow: 0 0 0 1px rgba(var(--tint), .16); transition: box-shadow .25s ease, transform .25s ease; }
.lk-skin__pv { aspect-ratio: 3 / 4; }
.lk-skin__pv img, .lk-wall__pv img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.lk-skin__name, .lk-wall__name, .lk-face__name { display: block; margin-top: 6px; font-size: calc(12px + 12 * var(--tz, 0px)); line-height: 1.25; color: var(--ink-2); white-space: nowrap; }
.lk-face { width: 76px; }
.lk-face__aa { display: grid; place-items: center; height: 64px; border-radius: 14px; font-size: calc(26px + 26 * var(--tz, 0px)); line-height: 1; color: var(--ink);
  background: var(--frost-off); box-shadow: 0 0 0 1px rgba(var(--tint), .16); transition: box-shadow .25s ease, transform .25s ease; }
.lk-face__name { overflow: hidden; text-overflow: ellipsis; }
.lk-wall { width: 64px; }
.lk-wall__pv { height: 80px; }
.lk-wall__pv i { position: absolute; inset: 0; }
.lk-wall--glow { background: var(--ground-plate) 50% 50% / cover no-repeat, var(--ground); }   /* the glow behind a round is THE GROUND, the scene blurred */
.lk-wall--aurora { background: linear-gradient(170deg, transparent 30%, var(--fld-2) 48%, transparent 62%), linear-gradient(190deg, transparent 45%, var(--fld-1) 60%, transparent 75%), var(--ground); }
.lk-wall--stars { background: radial-gradient(1px 1px at 20% 30%, #fff, transparent), radial-gradient(1px 1px at 70% 20%, #fff, transparent), radial-gradient(1.5px 1.5px at 45% 65%, #fff, transparent),
  radial-gradient(1px 1px at 80% 75%, #fff, transparent), radial-gradient(1px 1px at 30% 85%, #fff, transparent), radial-gradient(60% 50% at 30% 30%, var(--fld-1), transparent 70%), var(--ground); }
.lk-wall--rain { background: repeating-linear-gradient(100deg, transparent 0 9px, rgba(var(--tint), .22) 9px 10px), radial-gradient(70% 60% at 60% 40%, var(--fld-2), transparent 70%), var(--ground); }
.lk-skin[aria-checked="true"] .lk-skin__pv, .lk-face[aria-checked="true"] .lk-face__aa, .lk-wall[aria-checked="true"] .lk-wall__pv {
  box-shadow: 0 0 0 2px var(--acc-3), 0 0 0 5px color-mix(in srgb, var(--acc-3) 22%, transparent); }
.lk-skin[aria-checked="true"] .lk-skin__name, .lk-face[aria-checked="true"] .lk-face__name, .lk-wall[aria-checked="true"] .lk-wall__name { color: var(--acc-ink); font-weight: 700; }
.lk-skin:active .lk-skin__pv, .lk-face:active .lk-face__aa, .lk-wall:active .lk-wall__pv { transform: scale(.96); }
.lk-skin:focus-visible, .lk-face:focus-visible, .lk-wall:focus-visible { outline: none; }
.lk-skin:focus-visible .lk-skin__pv, .lk-face:focus-visible .lk-face__aa, .lk-wall:focus-visible .lk-wall__pv { outline: 2px dashed var(--acc-ink); outline-offset: 4px; }
.lk-pair { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 12px; }
.lk-pair .seg { width: 100%; }
.lk-more { -webkit-appearance: none; appearance: none; border: 0; background: none; font: inherit; font-size: calc(14px + 14 * var(--tz, 0px)); color: var(--acc-ink); cursor: pointer;
  margin: 16px 0 2px; padding: 6px 0; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.lk-btn svg { width: 22px; height: 22px; }
@media (prefers-reduced-motion: reduce) { .lk-skin__pv, .lk-face__aa, .lk-wall__pv { transition: none; } }
/* the chip beside «?»: the palette alone, as round as «?» */
.chip--look svg { width: 18px; height: 18px; }
/* on the home its row is full (the brand, Field, the level, «?»): on a phone or a tablet it stands at the end of the switch's
   row, the switch still centred; on a desk, where the header keeps only «?» and the switch (thud.css), beside «?» */
@media (max-width: 1099px) { .top--def:has(.modes) .chip--look { order: 10; position: absolute; right: calc(var(--gutter) + var(--sar)); bottom: 2px; } }
/* THE LEVEL AT THE SWITCH'S OTHER END (2026-11-25, docs/LEARN-RUN.md call 3): Find took its place beside «?» at the first
   row's end (with Field's chip, a calm skin's, that row had wrapped «?» onto the switch's); the level stands where
   the palette's twin would, what is studied and at which level on one row. Narrower than 424 px, beside the palette */
@media (max-width: 1099px) { .top--def:has(.modes) .chip--lv { order: 10; position: absolute; left: calc(var(--gutter) + var(--sal)); bottom: 2px; } }
/* on a phone the switch keeps clear of both chips (22 Oct: where «?» wraps onto the switch's row, as in Dieselpunk, Cyberpunk
   and Silkpunk at 428 px, the centred switch was pushed under the palette chip): it stands against the palette chip, its
   three modes drawn closer; narrower than 424 px (where the three cannot share a row) the two chips share a row and the
   switch takes its own */
@media (max-width: 480px) {
  .top--def:has(.modes):has(.chip--look) .modes { margin: 0 56px 0 auto; }
  .top--def .modes--3 .modes__m { padding: 0 11px; }
}
/* CENTRED AGAIN BETWEEN ITS TWO CHIPS (2026-11-25): since the level took the row's other end (call 3 above) a chip stands at
   each end, so the switch pushed against the palette stood 11 px from one and 35 px from the other at 428. «?» no longer
   wraps onto this row (walked at 428 in every skin, Field's chip shown): the switch stands in the middle, 23 px from each */
@media (min-width: 424px) and (max-width: 480px) {
  .top--def:has(.chip--lv):has(.chip--look) .modes { margin: 0 auto; }
}
/* FIELD'S CHIP AS ROUND AS ITS ROW (2026-11-25): by day the wordmark stands on glass now (thud-def.css), 29 px wider, and
   with Field's chip named in words (a calm skin's Blackout, always there) the first row had no room at 428: «?» wrapped
   onto the switch's row and lay over the level. On a phone the chip is its moon alone, 44 px as «?» and Find beside it
   are; its name stays in its label, and its light says when it is on */
@media (max-width: 480px) {
  .top--def .chip--watch { width: 44px; padding: 0 !important; }
  .top--def .chip--watch > span { display: none; }
}
/* the level as round as «?» where it shares the switch's row (its name stays in its label): with the bars it stood 5 px
   from the switch at 428, and under THUD ENG's longer names it ran under it. Narrower, it keeps its bars on the palette's row */
@media (min-width: 424px) and (max-width: 480px) {
  .top--def:has(.modes) .chip--lv { min-width: 44px; padding: 0 10px !important; justify-content: center; }
  .top--def:has(.modes) .chip--lv svg { display: none; }
}
@media (max-width: 423px) {
  .top--def:has(.modes):has(.chip--look) .chip--lv { position: static; order: 10; margin-left: auto; }
  .top--def:has(.modes):has(.chip--look) .chip--look { position: static; order: 10; margin-left: auto; }
  .top--def:has(.chip--lv):has(.modes) .chip--look { margin-left: 0; }   /* the two together at the row's end */
  .top--def:has(.modes):has(.chip--look) .modes { order: 11; margin: -10px auto 0; }   /* -10px: the empty row's gap given back */
  .top--def:has(.modes):has(.chip--look)::after { content: ""; order: 10; flex-basis: 100%; height: 0; }   /* the switch on a row of its own */
}
/* on a tablet the switch takes its own row whatever the first holds (2026-11-09): with Field's chip away (a learner who
   is not a defender) the first row had room for it at 720 px, and there the palette chip, at the row's end, stood over
   «Reading» */
@media (min-width: 481px) and (max-width: 1099px) {
  .top--def:has(.modes):has(.chip--look)::after { content: ""; order: 8; flex-basis: 100%; height: 0; }
  .top--def:has(.modes):has(.chip--look) .modes { margin-top: -10px; }   /* the empty row's gap given back */
}
/* and on a desk at the sidebar's foot too, beside the level (the foot is the desk's alone: .side, frap.css) */
@media (min-width: 1100px) {
  .side__foot:has(.chip--look) { display: flex; align-items: center; gap: 8px; }
  .side__foot .chip--look { flex: none; min-width: calc(36px + 6 * var(--sv, 0px)); padding: 0 !important; justify-content: center; }
}
.lk-row__ic svg { width: 18px; height: 18px; }

/* ── the primary key (RUN6.md B; its materials 2026-10-28): a button that is pressed, not a capsule that shrinks. Each
   skin's primary is a key in its own colours (--btn-1, --btn-2), smooth: the grains laid on it from 2026-10-28 went on
   2026-11-18 with every texture under a word (the owner: «modern, stylish frosted glass rather than a variety of weird
   looking backgrounds»). It is lit from above (--key-light, a light on its crown that is gone by
   32 %, above its label), its edge machined (a bright line along its top, a dark one along its foot), its label cut
   into it (--key-cut), and it stands on a lip of its own darker metal, onto which it goes down when pressed. Cyberpunk's
   is lit from within instead, and brightens. Flat in Field mode and under Low power.
   QUIETER (2026-11-25, the owner: «Hoping for a premium looking aesthetic and feel», and yes to «flatten it to a 2 px
   lip»): the lip stepped in four (4 px of darkening metal and a cast shadow under it) read as a game's button, and the
   crown's light a hard band. Now one lip of 2 px, a soft shadow, the crown's light a gradient that fades; pressed, the
   key goes down its 2 px. ── */
:root { --key-light: linear-gradient(180deg, rgba(255, 255, 255, .34), rgba(255, 255, 255, .1) 18%, rgba(255, 255, 255, 0) 34%); }
html:not([data-watch="on"]):not([data-low="on"]):not([data-palette="cyber"]) .btn--primary {
  isolation: isolate; text-shadow: var(--key-cut, 0 1px 0 rgba(255, 255, 255, .4));
  box-shadow: inset 0 1px 0 var(--btn-rim), inset 0 -1px 0 rgba(0, 0, 0, .14), inset 0 -10px 16px -10px var(--btn-deep),
    var(--key-ring, 0 0 transparent),
    0 2px 0 color-mix(in srgb, var(--btn-2, var(--acc)) 68%, #000),
    0 8px 14px -8px rgba(0, 0, 0, .3),
    0 16px 30px -14px var(--glow), 0 2px 5px rgba(var(--shade), calc(.22 * var(--sk)));
  transition: transform .12s ease, box-shadow .12s ease, filter var(--t) ease, opacity var(--t) ease;
}
html:not([data-watch="on"]):not([data-low="on"]):not([data-palette="cyber"]) .btn--primary::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  background-image: var(--key-light), var(--key-grain, none);
  background-size: 100% 100%, max(800px, 100%) auto;
  background-position: 0 0, 50% 50%;
  background-repeat: no-repeat;
  mix-blend-mode: soft-light;
}
html:not([data-watch="on"]):not([data-low="on"]):not([data-palette="cyber"]) :is(.btn--primary:active, a:active > .btn--primary) {
  transform: translateY(2px);
  box-shadow: inset 0 1px 0 var(--btn-rim), inset 0 -1px 0 rgba(0, 0, 0, .14), inset 0 -8px 14px -10px var(--btn-deep),
    var(--key-ring, 0 0 transparent),
    0 0 0 color-mix(in srgb, var(--btn-2, var(--acc)) 68%, #000), 0 3px 6px -3px rgba(0, 0, 0, .3), 0 6px 14px -10px var(--glow);
}
html:not([data-watch="on"]):not([data-low="on"])[data-palette="cyber"] .btn--primary {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6), inset 0 0 0 1px rgba(255, 255, 255, .25), 0 0 0 1px rgba(184, 246, 255, .45),
    0 0 26px -6px var(--neon-c, #45e3ff), 0 14px 30px -14px var(--glow);
}
html:not([data-watch="on"]):not([data-low="on"])[data-palette="cyber"] :is(.btn--primary:active, a:active > .btn--primary) { transform: scale(.975); filter: brightness(1.15) saturate(1.1); }
@media (prefers-reduced-motion: reduce) { :is(.btn--primary:active, a:active > .btn--primary) { transform: none !important; } }
/* a key set inside a link (the hero's, Learn's Today) goes down when the link is pressed: :active is the link's */

/* TODAY, AS THREE DOORS (2026-11-25; frap.js learn(), frap-day.js, docs/THEORY.md §4, docs/LEARN-RUN.md call 2): the day
   in a line over its parts, each a door wearing its part's marks (frap-figure.js door(): the figures' own inks,
   thud-def.css .ofig), its name and where it stands; a part done today lit and ticked, the words under way a thin bar.
   Three equal doors on a phone, under the hero; on a desk the same row, each its marks beside its words */
.def-day { margin: 14px 0 16px; }
.def-day__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin: 0 2px 8px; }
.def-day__k { color: var(--acc-ink); font-size: calc(11px + 11 * var(--tz, 0px)); letter-spacing: .22em; }
.def-day__say { color: var(--ink-2); font-size: calc(14px + 14 * var(--tz, 0px)); line-height: 1.35; }
.def-doors { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
.def-doors > li { display: flex; min-width: 0; }
.def-door { --r: 18px; position: relative; display: flex; flex-direction: column; gap: 2px; width: 100%; min-height: 108px; padding: 10px 11px 13px;
  border-radius: 18px; color: var(--ink); text-decoration: none; overflow: hidden; }
.def-door .ofig--door { flex: none; width: 40px; max-width: none; height: auto; margin: 0 0 6px -1px; }
.def-door__name { display: flex; align-items: center; gap: 5px; font-size: calc(15px + 15 * var(--tz, 0px)); font-weight: 700; line-height: 1.2; }
.def-door__name .i { flex: none; width: 15px; height: 15px; color: var(--acc-ink); }
.def-door__sub { color: var(--ink-2); font-size: calc(13px + 13 * var(--tz, 0px)); line-height: 1.3; overflow-wrap: anywhere; }
.def-door__sub .bk-n { color: var(--acc-ink); font-variant-numeric: tabular-nums; }
.def-door__bar { position: absolute; left: 11px; right: 11px; bottom: 7px; height: 3px; border-radius: 2px; background: rgba(var(--tint), .14); overflow: hidden; }
.def-door__bar::after { content: ""; display: block; height: 100%; border-radius: 2px; transform-origin: 0 50%; transform: scaleX(var(--p, 0)); background: var(--acc-ink); }
/* the ring is the next part (frap.js learn(), THE NEXT DOOR RINGED), as a way's card is ringed where the learner is; a part
   done today keeps its tick in the accent and nothing louder */
.def-door.is-next { box-shadow: inset 0 0 0 1.5px var(--acc-ink); }
.def-door.is-done .def-door__name { color: var(--ink-2); font-weight: 650; }
.def-door:active { transform: scale(.98); transition-duration: .1s; }
@media (min-width: 720px) {
  .def-day { margin: 18px 0 18px; }
  .def-doors { gap: 12px; }
  .def-door { display: grid; grid-template-columns: 46px minmax(0, 1fr); grid-template-rows: auto auto; align-content: center; column-gap: 12px; row-gap: 2px;
    min-height: 80px; padding: 12px 16px; }
  .def-door .ofig--door { grid-row: 1 / 3; align-self: center; width: 46px; margin: 0; }
  .def-door__bar { left: 74px; right: 16px; bottom: 9px; }
}

/* THE DAY IN PICTURES (2026-11-25, the owner: «This looks super primitive. We have 18 gigs of exceptional art»; frap.js
   dayDoor() `o`, picDoor()). Each door wears the painting of where it goes: the Way the words are on (as its page wears
   it), the learner's part of the book, the Journey's cover or the reading room; full bleed under the glass's rim, its
   words on a frosted plate at its foot (the desk's doors' plate, frap.css .side__door--pic): the part and, from a
   tablet, the Way; what it opens; where it stands. The next part ringed over the picture, a part done ticked on its
   corner. In Field mode and under Low power frap.js draws the glyph door; a mode turned on while Learn is open takes the
   picture away here and leaves the words on the glass */
.def-door.def-door--pic { justify-content: flex-end; gap: 0; min-height: 112px; padding: 0; }
.def-door--pic .def-door__pic { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.def-door__plate { display: flex; flex-direction: column; gap: 1px; min-width: 0; padding: 6px 9px 9px; color: #fff;
  background: rgba(8, 10, 16, .66); -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2); }
.def-door__k { color: rgba(255, 255, 255, .84); font-size: calc(11px + 11 * var(--tz, 0px)); letter-spacing: .16em; overflow-wrap: anywhere; }
.def-door__src, .def-door__wide { display: none; }
.def-door__what { font-size: calc(13.5px + 13.5 * var(--tz, 0px)); font-weight: 700; line-height: 1.25; overflow-wrap: break-word; text-wrap: balance; }   /* every word of a lesson's name, on as many lines as it takes: one line lost its last word on a phone, two cut it at 320 px (AUDIT unit 55) */
.def-door__plate .bk-n { color: inherit; font-weight: 700; font-variant-numeric: tabular-nums; }
.def-door--pic .def-door__sub { color: rgba(255, 255, 255, .86); font-size: calc(11.5px + 11.5 * var(--tz, 0px)); line-height: 1.3; }
.def-door__done { position: absolute; top: 6px; right: 6px; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 999px; color: #fff;
  background: rgba(8, 10, 16, .66); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.def-door__done .i { width: 14px; height: 14px; }
.def-door--pic .def-door__bar { left: 9px; right: 9px; bottom: 4px; background: rgba(255, 255, 255, .24); }
.def-door--pic .def-door__bar::after { background: #fff; }
.def-door--pic.is-next { outline: 2px solid var(--acc-ink); outline-offset: -2px; }
/* the next door is marked with the ring's own line: focused, the line steps out to where every ring stands (AUDIT unit 41) */
.def-door--pic.is-next:focus-visible { outline-offset: 3px; }
.def-door--pic.is-done .def-door__what { color: rgba(255, 255, 255, .86); font-weight: 650; }
@media (hover: hover) { .def-door--pic .def-door__pic { transition: transform .6s cubic-bezier(.2, .7, .2, 1); } .def-door--pic:hover .def-door__pic { transform: scale(1.04); } }
@media (prefers-reduced-motion: reduce) { .def-door--pic .def-door__pic { transition: none; } .def-door--pic:hover .def-door__pic { transform: none; } }
html:is([data-watch="on"], [data-low="on"]) .def-door--pic .def-door__pic { display: none; }
html:is([data-watch="on"], [data-low="on"]) .def-door--pic :is(.def-door__plate, .def-door__done) { background: none; -webkit-backdrop-filter: none; backdrop-filter: none; color: var(--ink); }
html:is([data-watch="on"], [data-low="on"]) .def-door--pic :is(.def-door__k, .def-door__sub, .def-door__what) { color: var(--ink-2); }
@media (min-width: 720px) {
  .def-door.def-door--pic { display: flex; min-height: 0; aspect-ratio: 4 / 3; padding: 0; }
  .def-door__plate { gap: 2px; padding: 9px 14px 12px; }
  .def-door__k { font-size: calc(11px + 11 * var(--tz, 0px)); letter-spacing: .18em; }
  .def-door__src, .def-door__wide { display: inline; }
  .def-door__what { font-size: calc(16px + 16 * var(--tz, 0px)); }
  .def-door--pic .def-door__sub { font-size: calc(13px + 13 * var(--tz, 0px)); }
  .def-door__done { top: 9px; right: 9px; width: 28px; height: 28px; }
  .def-door--pic .def-door__bar { left: 14px; right: 14px; bottom: 5px; }
}
@media (min-width: 1100px) { .def-door.def-door--pic { aspect-ratio: 16 / 9; } }

/* ── the round buttons (back, close, the look, the options): each skin's bezel round the glass ─────────────────── */
html:not([data-watch="on"]):not([data-low="on"]):is([data-palette="ember"], :not([data-palette])) .btn--round.glass { box-shadow: 0 0 0 1.5px rgba(10, 13, 20, .7), inset 0 0 0 1px rgba(190, 210, 240, .18), inset 0 1px 0 var(--hi), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="steam"] .btn--round.glass { box-shadow: inset 0 0 0 1.5px var(--brass), inset 0 2px 0 1px rgba(255, 226, 168, .3), 0 0 0 1px var(--brass-lo), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="cyber"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(69, 227, 255, .5), 0 0 14px -4px rgba(69, 227, 255, .55), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="ray"] .btn--round.glass { box-shadow: 0 0 0 2px rgba(230, 240, 245, .55), 0 0 0 3px rgba(70, 92, 102, .6), inset 0 1px 0 rgba(255, 255, 255, .3), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="west"] .btn--round.glass { box-shadow: inset 0 0 0 1.5px var(--brass, #c9984e), 0 0 0 1px rgba(60, 34, 16, .8), inset 0 1px 0 var(--hi), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="silk"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(233, 182, 74, .75), 0 0 0 1px rgba(122, 33, 17, .5), inset 0 1px 0 var(--hi), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="solar"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(245, 184, 46, .72), 0 0 0 1px rgba(201, 129, 58, .42), inset 0 1px 0 var(--hi), 0 0 14px -6px rgba(94, 176, 242, .5), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="moss"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(233, 182, 74, .7), 0 0 0 1px rgba(155, 42, 212, .42), inset 0 1px 0 var(--hi), 0 0 14px -6px rgba(124, 201, 85, .5), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="aqua"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(233, 182, 74, .7), 0 0 0 1px rgba(212, 65, 42, .4), inset 0 1px 0 var(--hi), 0 0 14px -6px rgba(85, 197, 201, .55), var(--cast); }
html:not([data-watch="on"]):not([data-low="on"])[data-palette="petryk"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(243, 238, 227, .42), 0 0 0 1px rgba(37, 70, 166, .6), inset 0 1px 0 var(--hi), var(--cast); }
html[data-look="milk"]:not([data-watch="on"]):not([data-low="on"])[data-palette="petryk"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(37, 70, 166, .3), 0 0 0 1px rgba(28, 34, 66, .1), inset 0 1px 0 var(--hi), var(--cast); }
html[data-look="milk"]:not([data-watch="on"]):not([data-low="on"])[data-palette="cyber"] .btn--round.glass { box-shadow: inset 0 0 0 1px rgba(10, 120, 150, .5), var(--cast); }
html[data-look="milk"]:not([data-watch="on"]):not([data-low="on"]):is([data-palette="ember"], :not([data-palette])) .btn--round.glass { box-shadow: 0 0 0 1.5px rgba(30, 44, 56, .26), inset 0 1px 0 var(--hi), var(--cast); }

/* ── the corners (PUNK.md call 42; the owner, 2026-10-26: «Consider, for every test surface, some kind of ar from
   firefly. The edges or subtly in the background»): each skin's Firefly ornament at two corners, the top left and the
   bottom right, of the question card and of the surfaces measured to have room round their words (the Review's hero, an
   empty state), cut by scripts/cut_corners.py (scripts/corners.json) into one sprite, art/<skin>/corners.webp, drawn as a
   border image sliced at its middle: the edges between them stay empty, and the surface's own fill, edge, light and words
   are untouched (the image lies over the fill, under the words). A corner sits inside its surface's rounded corner and
   3 px clear of every word and drawn thing in it (qa_sweep.py's CORNER ON TEXT); where both cannot hold (the answers, the
   Grammar's panels, the sheets, a story's pane), the surface goes without; so does a Write card, whose «Letters» chip
   (frap-drill.js) holds the card's corner (PETRYK.md P4: in every skin it lay over the ornament), and the Grammar's card
   below 1100 px, where it is only as tall as its words and its sentence runs to its edges (PETRYK.md P10: WebKit set «How
   do you say …» on one line under both corners, on a phone and at 720 px; the desk's card, 150 px tall at least and padded
   34 px, holds them). A question card whose fitted word comes that near the ink goes without for that card (frap-drill.js
   .frap-bare, read from the sprite as the sweep reads it: a phrase on two lines across a phone's card, 2026-11-09). None
   in Field mode or under Low power. --cs is a surface's corner: 0 draws none. */
html:not([data-palette]), html[data-palette="ember"] { --corners: url("art/ember/corners.webp"); }
html[data-palette="steam"] { --corners: url("art/steam/corners.webp"); }
html[data-palette="cyber"] { --corners: url("art/cyber/corners.webp"); }
html[data-palette="ray"] { --corners: url("art/ray/corners.webp"); }
html[data-palette="west"] { --corners: url("art/west/corners.webp"); }
html[data-palette="silk"] { --corners: url("art/silk/corners.webp"); }
html[data-palette="petryk"] { --corners: url("art/petryk/corners.webp"); }
html[data-palette="moss"] { --corners: url("art/moss/corners.webp"); }
html[data-palette="aqua"] { --corners: url("art/aqua/corners.webp"); }
html[data-palette="solar"] { --corners: url("art/solar/corners.webp"); }
/* PETRYK.md P21: Petrykivka's afternoon is the day's scene a little warmer and softer (the owner, 2026-11-20: «afternoon
   (slightly more relaxed)»), on the still and the living scene alike (FRAP.mood() puts it on <html data-mood>) */
html[data-palette="petryk"][data-mood="afternoon"] .def-hero__art img,
html[data-palette="petryk"][data-mood="afternoon"] .def-hero__live { filter: sepia(.14) saturate(1.1) brightness(.97); }
#card .prompt-box { --cs: 56px; }
.hero.glass { --cs: 44px; }
.empty.glass { --cs: 36px; }
@media (max-width: 1099px) { html.bk-drill #card .prompt-box { --cs: 0px; } }
html:not([data-watch="on"]):not([data-low="on"]) :is(#card .prompt-box:not(.frap-bare):not(:has(> #frap-kb-chip:not([hidden]))), .hero.glass:not(.bk-hero), .empty.glass) {
  border-image: var(--corners) 50% / var(--cs) / 0 stretch !important;
}
