/* cup.css — the calm skins' own (coffee, matcha, tea; THUD CUP's until 2026-11-11, CALM.md §12), for each of them
   (CALM.md step 3): Blackout and the arrival. A skin's own look is its sheet (cup-matcha.css); tokens are frap.css's.
   Nothing here applies in another skin: every rule asks for html[data-calm] (frap-app.js puts it there while a calm skin
   is worn) or for html[data-arrive], which only cup-arrival.js sets, and only in a calm skin.

   BLACKOUT (CALM.md call 4): a calm skin's Field mode, a light the learner holds (frap-app.js LIGHTS, Settings › The look;
   the header's chip). thud.js puts html[data-watch="on"] on it, so every guard Field mode keeps is kept (no motion, no
   film, no WebGL, no sound: verify_field_discipline.py), and frap.css gives it Chasen's black and warm gold
   (html[data-calm][data-watch="on"], priced by verify_contrast.py). Black needs no red veil, and no picture is
   drawn: the room, the covers, the paintings, the companion and the medals step aside, the words stay. */
html[data-calm] #watch-veil { display: none !important; }
html[data-calm][data-watch="on"] :is(img, video, picture) { visibility: hidden !important; }
html[data-calm][data-watch="on"] :is(.def-hero__art, .def-card__art, .def-wide__art, .def-month__art, .rd-card__art, .rd-banner__art, .peek, .cheer, .cup-flower) { display: none !important; }
/* the flower of the season (Chasen's .lb-flower; cup-room.js bloom()): beside the Continue card's title, a small print laid
   on the paper; the title and the line under it wrap round it only as far as they must */
html[data-calm] .def-hero__go .cup-flower { float: right; width: 4rem; height: 4rem; margin: 2px 0 6px 14px; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--line); background: var(--glass-fill, transparent); box-shadow: 0 8px 20px -12px rgba(0, 0, 0, .5); }
html[data-calm] .def-hero__go .cup-flower img { display: block; width: 100%; height: 100%; object-fit: cover; }
html[data-calm] .def-hero__go .def-hero__btn { clear: both; }
@media (min-width: 900px) { html[data-calm] .def-hero__go .cup-flower { width: 4.4rem; height: 4.4rem; } }
html[data-calm][data-watch="on"] .def-card { aspect-ratio: auto; min-height: 92px; }
html[data-calm][data-watch="on"] .def-card::after, html[data-calm][data-watch="on"] .def-wide::after { display: none; }
html[data-calm][data-watch="on"] :is(.def-card, .def-wide) { background: var(--glass-fill); color: var(--ink); }
html[data-calm][data-watch="on"] :is(.def-card__title, .def-wide__body b) { color: var(--ink); text-shadow: none; }
html[data-calm][data-watch="on"] :is(.def-card__st, .def-wide__body span:last-child, .def-wide .i--chev) { color: var(--ink-2); }
html[data-calm][data-watch="on"] :is(.def-card__n, .def-wide__body .caps) { color: var(--acc-ink); }
html[data-calm][data-watch="on"] .def-hero { min-height: 0; padding-top: 18px; }
html[data-calm][data-watch="on"] .def-hero__go { color: var(--ink); }

/* THE ARRIVAL (cup-arrival.js; CALM.md §3, call 5; Chasen's two sheets parting on its room, carried): a sheer curtain
   drawn aside on the room, its light coming up, the Tryzub and the name setting, then the card. No flash, no sparks, no
   jolt. The curtain is <body>'s two pseudo-elements, which take no tap, so the arrival never stands between a learner and
   the first thing they press; cup-arrival.js only says whether there is one (html[data-arrive]: «full», about 3.2 s, the
   first launch and «Play the arrival now»; «short», about 1 s, a launch after: the curtain already open, the light coming
   up and the card settling; «at», one frozen moment). The cloth is the skin's own photograph when it has one
   (--cup-curtain, its tall picture or, on a screen wider than tall, its wide one: --cup-ar), laid over the whole screen
   as one picture and split down its middle, each half drawn aside with its own side of it; the woven stripes under it
   stand in while it loads. */
html[data-calm] { --cup-cloth: 22, 28, 56; --cup-cloth-a: .94; --cup-fold: 236, 231, 220; --cup-fold-a: .05; --cup-hem: rgba(0, 0, 0, .3);
  --cup-curtain: none; --cup-ar: .5625; --cup-cw: max(100vw, calc(100vh * var(--cup-ar))); }
@media (min-aspect-ratio: 1/1) { html[data-calm] { --cup-ar: 1.75; } }
html[data-calm][data-look="milk"] { --cup-cloth: 247, 247, 243; --cup-cloth-a: .9; --cup-fold: 255, 255, 255; --cup-fold-a: .7; --cup-hem: rgba(60, 70, 80, .12); }
html[data-arrive] body::before, html[data-arrive] body::after { content: ""; position: fixed; top: 0; bottom: 0; z-index: 2147482000; width: 50.5%; pointer-events: none;
  left: auto; right: auto; height: auto; opacity: 1;   /* body::after is frap.css's light at the top (left 0, 70vh, .42) while no curtain hangs */
  background:
    var(--cup-curtain) var(--cup-x) 50% / var(--cup-cw) auto no-repeat,
    repeating-linear-gradient(90deg, rgba(var(--cup-fold), 0) 0, rgba(var(--cup-fold), var(--cup-fold-a)) 11px, rgba(var(--cup-fold), 0) 24px, rgba(0, 0, 0, .035) 34px, rgba(var(--cup-fold), 0) 44px),
    linear-gradient(180deg, rgba(var(--cup-cloth), var(--cup-cloth-a)) 0%, rgba(var(--cup-cloth), calc(var(--cup-cloth-a) - .05)) 88%, rgba(var(--cup-cloth), var(--cup-cloth-a)) 100%); }
html[data-arrive] body::before { left: 0; --cup-x: calc(50vw - var(--cup-cw) / 2); box-shadow: inset -14px 0 22px -18px var(--cup-hem); }
html[data-arrive] body::after { right: 0; --cup-x: calc(.5vw - var(--cup-cw) / 2); box-shadow: inset 14px 0 22px -18px var(--cup-hem); }
html[data-arrive="full"] body::before { animation: cup-part-l 1.2s cubic-bezier(.6, 0, .2, 1) .6s both; }
html[data-arrive="full"] body::after { animation: cup-part-r 1.2s cubic-bezier(.6, 0, .2, 1) .6s both; }
html[data-arrive="short"] body::before, html[data-arrive="short"] body::after { display: none; }
@keyframes cup-part-l { from { transform: none; } to { transform: translateX(-101%); } }
@keyframes cup-part-r { from { transform: none; } to { transform: translateX(101%); } }
/* the room's light comes up */
html[data-arrive="full"] .def-hero__art { animation: cup-light 1.6s ease .4s both; }
html[data-arrive="short"] .def-hero__art { animation: cup-light .9s ease both; }
@keyframes cup-light { from { filter: brightness(.72) saturate(.82); } to { filter: none; } }
/* the Tryzub sets, the name under it: the welcome's arms, or the bar's mark and name; then the card */
html[data-calm][data-arrive="full"] .brief .fl__world img.brief__eye.brief__arms,
html[data-arrive="full"] .def-brand { animation: cup-set .8s cubic-bezier(.2, .7, .2, 1) 1.8s both; }
html[data-arrive="full"] :is(.fl__hello > *, .def-hero__go) { animation: cup-settle .6s cubic-bezier(.2, .7, .2, 1) 2.6s both; }
html[data-arrive="short"] .def-hero__go { animation: cup-settle .6s cubic-bezier(.2, .7, .2, 1) .3s both; }
@keyframes cup-set { from { opacity: 0; transform: translateY(6px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes cup-settle { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
/* one frozen moment (?arrive=<t>, CUP_ARRIVAL.at(T)): cup-arrival.js works each part out, and nothing moves */
html[data-arrive="at"] body::before { transform: translateX(calc(-1 * var(--arrive-x, 0%))); }
html[data-arrive="at"] body::after { transform: translateX(var(--arrive-x, 0%)); }
html[data-arrive="at"] .def-hero__art { filter: brightness(var(--arrive-light, 1)) saturate(var(--arrive-sat, 1)); }
html[data-calm][data-arrive="at"] .brief .fl__world img.brief__eye.brief__arms,
html[data-arrive="at"] .def-brand { animation: none; opacity: var(--arrive-set, 1); transform: translateY(calc(6px * (1 - var(--arrive-set, 1)))); }
html[data-arrive="at"] :is(.fl__hello > *, .def-hero__go) { animation: none; opacity: var(--arrive-settle, 1); transform: translateY(calc(10px * (1 - var(--arrive-settle, 1)))); }
@media (prefers-reduced-motion: reduce) { html[data-arrive]:not([data-arrive="at"]) body::before, html[data-arrive]:not([data-arrive="at"]) body::after { display: none; } }
/* THE CUP'S FLOWER (punk-craft.js, 2026-11-15; the owner: «and perhaps one for the coffee»): in coffee's whole arrival a
   potter's combed flower (fliandrivka) is made in cream on a cup of coffee, under the room, over the parting curtain;
   its name and what it is made of under it, on a slip of the page's own paper so the words hold over curtain and room;
   gone as the card settles. It takes no tap, and is never there in Blackout or Field mode, under Low power or with less
   motion (the arrival's own guard, and these) */
.cup-craft { position: fixed; z-index: 2147482600; left: 50%; top: calc(50vh + min(15vh, 132px)); width: min(34vw, 20vh, 168px); transform: translateX(-50%);
  pointer-events: none; opacity: 0; transition: opacity .45s ease; }
.cup-craft.on { opacity: 1; }
html[data-arrive="at"] .cup-craft { transition: none; }   /* a held moment stands at once */
.cup-craft canvas { display: block; width: 100%; aspect-ratio: 1 / 1; filter: drop-shadow(0 10px 18px rgba(40, 24, 10, .28)); }
.cup-craft span { display: block; width: max-content; max-width: 78vw; margin: 12px 0 0 50%; transform: translateX(-50%); padding: 7px 12px; border-radius: 10px; text-align: center;
  font-size: 12.5px; line-height: 1.35; color: var(--ink-2); background: var(--ground); }
.cup-craft b { margin-right: .7em; font-size: 10.5px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--ink); }
html[data-low="on"] .cup-craft, html[data-watch="on"] .cup-craft { display: none; }
@media (prefers-reduced-motion: reduce) { html:not([data-arrive="at"]) .cup-craft { display: none; } }

/* A CALM ROUND MOVES QUIETLY (the owner, 2026-11-13: «Skins: A then B»; CALM.md call 23, which amends calls 6 and 10).
   Until then a calm round was a world's round with its burst and its pulse taken away: the answer still popped, a
   plate still swept across it, the verdict's seal still landed with a turn, a sheen still crossed Continue, a new card
   cut in, and the Debrief stood all at once. A room has a round of its own now, in §4's measure (slow and soft, 200 to
   600 ms, no overshoot, nothing travelling further than a few pixels):
     A RIGHT ANSWER  warms: the plate comes up through the paper where it lies (no pop, no sweep); the verdict's seal
                     comes up as the plate does (no landing); no sheen crosses a key (paper does not shine, call 16).
     A PAGE TURNED   the new card is laid down: the word, then its answers (or the line to type on), a breath apart. frap-drill.js tells the
                     sheets each question shown (<html data-turn>, «a» and «b» by turns, so the laying begins again).
     THE DEBRIEF     its arc is drawn once, and its lines come up one after another, none rising. The figures
                     stand at once (frap-app.js countUp), the companion stands still, the room does not quicken.
   STILLED, always: the worlds' pop, sweep, landing, sheen, the run's flare and the rise. GIVEN, only where anything may move: never in
   Blackout or Field mode (data-watch), under Low power (data-low) or reduced motion. No sound (thud-feel.js). The
   keyframes name only where a thing comes from: it ends as its own rule has it (a dimmed answer stays dimmed). */
html[data-calm] #options .opt-btn.correct { animation: none !important; }
html[data-calm] #options .opt-btn.correct::after { animation: none !important; transform: none !important; }
html[data-calm] #grammar-note .gn-verdict::before, html[data-calm] #grammar-note .gn-verdict::after { animation: none !important; }
html[data-calm] .btn--primary::after { animation: none !important; }
html[data-calm] #streak.flare :is(svg, #streak-count) { animation: none !important; }
html[data-calm] .ring__bar { transition: none !important; }
html[data-calm] :is(.cheer, .cheer img, .cheer .peek__burst, .cheer .petal) { animation: none !important; }
html[data-calm] .fr-res .fr-res__body > * { animation: none !important; }
html[data-calm] .fr-res > .fr-round > * { animation: none !important; }
@media (prefers-reduced-motion: no-preference) {
  html[data-calm]:not([data-watch="on"]):not([data-low="on"]) #options .opt-btn.correct::after { animation: cup-warm .52s ease-out backwards !important; }
  html[data-calm]:not([data-watch="on"]):not([data-low="on"]) #grammar-note .gn-verdict::before,
  html[data-calm]:not([data-watch="on"]):not([data-low="on"]) #grammar-note .gn-verdict::after { animation: cup-warm .4s ease-out .1s backwards !important; }
  html[data-calm][data-turn="a"]:not([data-watch="on"]):not([data-low="on"]) :is(#card .prompt-box, #options .opt-btn, #card #type-wrap) { animation: cup-lay-a .32s cubic-bezier(.2, .7, .2, 1) backwards !important; }
  html[data-calm][data-turn="b"]:not([data-watch="on"]):not([data-low="on"]) :is(#card .prompt-box, #options .opt-btn, #card #type-wrap) { animation: cup-lay-b .32s cubic-bezier(.2, .7, .2, 1) backwards !important; }
  html[data-calm][data-turn]:not([data-watch="on"]):not([data-low="on"]) #card #type-wrap { animation-delay: 70ms !important; }
  html[data-calm][data-turn]:not([data-watch="on"]):not([data-low="on"]) #options .opt-btn:nth-child(1) { animation-delay: 70ms !important; }
  html[data-calm][data-turn]:not([data-watch="on"]):not([data-low="on"]) #options .opt-btn:nth-child(2) { animation-delay: 110ms !important; }
  html[data-calm][data-turn]:not([data-watch="on"]):not([data-low="on"]) #options .opt-btn:nth-child(3) { animation-delay: 150ms !important; }
  html[data-calm][data-turn]:not([data-watch="on"]):not([data-low="on"]) #options .opt-btn:nth-child(n+4) { animation-delay: 190ms !important; }
  html[data-calm]:not([data-watch="on"]):not([data-low="on"]) .ring__bar { transition: stroke-dashoffset .6s cubic-bezier(.2, .7, .2, 1) !important; }
  html[data-calm]:not([data-watch="on"]):not([data-low="on"]) :is(.fr-res .fr-res__body > *, .fr-res > .fr-round > *) { animation: cup-warm .5s ease-out backwards !important; animation-delay: calc(var(--i, 0) * 80ms + 80ms) !important; }
}
@keyframes cup-warm { from { opacity: 0; } }
@keyframes cup-lay-a { from { opacity: 0; transform: translateY(6px); } }
@keyframes cup-lay-b { from { opacity: 0; transform: translateY(6px); } }
/* The Debrief's word is the part of the day (thud-def.css draws «Debrief» there): a calm end names its hour, as TIDE's
   does (CALM.md §7), and the room by the clock stands behind it. Blackout is the evening's. */
html[data-calm] .fr-res__top:not(:has(> .eyebrow))::before, html[data-calm] .fr-res__top > .eyebrow::before { content: "Morning"; }
html[data-calm][data-part="afternoon"] .fr-res__top:not(:has(> .eyebrow))::before, html[data-calm][data-part="afternoon"] .fr-res__top > .eyebrow::before { content: "Afternoon"; }
html[data-calm][data-part="evening"] .fr-res__top:not(:has(> .eyebrow))::before, html[data-calm][data-part="evening"] .fr-res__top > .eyebrow::before { content: "Evening"; }
/* FROSTED GLASS (the owner, 2026-11-18, of the paper the cards were: «terrible; let's stick with modern, stylish frosted
   glass rather than a variety of weird looking backgrounds»; Mobbin: TIDE's settings panel, GOAT's details and Crumbl's
   naming sheet, each a frosted panel over a photograph). A calm skin's cards are glass as every skin's: frap.css fills
   them a little fuller than the worlds' (.84, the strong .90), since behind them a room's window is brighter than a
   world's field, and the frost blurs the room through them. «Paper, not glass» (CALM.md call 16) went with its grain.
   The calm still does not shine: no specular under the finger, no sheen drifting. */
html[data-calm]:is([data-palette="coffee"], [data-palette="matcha"], [data-palette="tea"]) .glass::after { content: none; }
/* THE DEBRIEF ON THE ROOM (2026-11-17; punk-wall.css «THE DEBRIEF ON THE SCENE»): the round's sentence, the score's face,
   the drill's chip and the proverb stood on the room, whose window is bright by day and by night (Chrome read coffee's
   line under the head 2.3:1 by night, tea's course's day 2.3:1, the proverb 2.3:1, the "%" 2.4:1). They stand on a slip
   of the cards' own fill, as the cup's flower's name does. The sentence is three parts and one slip: each
   part's clip reaches a pixel over its top and foot (where two parts meet at a part of a pixel, two soft edges let a
   line of the room through) */
html.pw-on[data-calm] .fr-res :is(.fr-drill, .res-quote), html.pw-on[data-calm] .fr-res .fr-arc .ring, html.pw-on[data-calm] .fr-res .fr-res__top:has(> .fr-arc) > .eyebrow {
  background: var(--glass-fill); }
html.pw-on[data-calm] .fr-res :is(.rs-head, .rs-sub, .fr-course, .fr-res__top:not(:has(> .fr-arc)) > .eyebrow) { background: var(--glass-fill);
  clip-path: inset(-1px 0 round var(--slip-t, 0px) var(--slip-t, 0px) var(--slip-b, 0px) var(--slip-b, 0px)); }

/* THE LOOK SHEET (frap-look.js): a calm skin has five lights where the others have three, so Text size and Light each
   take a row of their own (the seg is frap.css's five-option one, .seg--5); side by side «Blackout» ran out of the sheet
   (found 2026-11-11, at every width). */
html[data-calm] .lk-pair { grid-template-columns: minmax(0, 1fr); }

