/* The chapter tabs share the native app's quiet, persistent navigation. */
[hidden]{display:none!important}
.main-navigation{display:flex;border-bottom:1px solid var(--ms-cell-line);margin:20px 0 28px;position:sticky;top:0;background:var(--ms-bg);z-index:5}
.main-navigation .tab{flex:1;min-height:48px;padding:10px 4px;font:400 var(--ms-size-body)/1.3 var(--ms-font-display);letter-spacing:0;text-transform:none;border:0;border-bottom:2px solid transparent;background:none;color:var(--ms-text-3)}
.main-navigation .tab.active{color:var(--ms-text-bright);border-bottom-color:var(--ms-text-bright)}
.main-navigation .tab:focus-visible{outline:2px solid var(--ms-text-bright);outline-offset:-4px}
/* Home (W2, POLISH_2026_11 W-b 4-6). The next level's sheet is the page's one picture; the
   quantity, "2 of 10 levels", is its headline at the result's size, with a quiet line under it.
   The sheet is a button (Play) holding the player's still drawing; under it the level descriptor
   is the micro-caps register's second place. Then the strip of tiles, the primary and the last
   seven days. Section titles are sentences in Shippori Mincho at the title step on the shared
   hairline. No eyebrows, no cards. */
.home-layout{margin-top:0}
.home-headline{font:400 var(--ms-size-result)/1.2 var(--ms-font-display);margin:0;color:var(--ms-text-bright);text-wrap:balance}
.home-title{font:400 var(--ms-size-title)/1.3 var(--ms-font-display);margin:0;padding-bottom:var(--ms-space-3);border-bottom:var(--ms-rule);color:var(--ms-text-bright);text-wrap:balance}
.home-quiet{display:block;font:400 var(--ms-size-body)/1.5 var(--ms-font-display);margin:var(--ms-space-1) 0 0;color:var(--ms-text-2);font-variant-numeric:tabular-nums}
.home-instructions{font:400 var(--ms-size-body)/1.6 var(--ms-font-display);margin:0 0 var(--ms-space-3);color:var(--ms-text-2);text-wrap:pretty}
.home-figure{display:flex;flex-direction:column;align-items:center;margin:var(--ms-space-6) 0 var(--ms-space-5)}
.home-figure[hidden]{display:none}
/* The sheet is the Play control: the paper itself, no box; the ring is the keyboard's alone. */
.home-sheet{appearance:none;display:block;border:0;padding:0;background:none;color:inherit;cursor:pointer;
  touch-action:manipulation;-webkit-tap-highlight-color:transparent}
.home-sheet:active .still-frame{transform:scale(.99)}
.home-sheet:focus-visible{outline:var(--ms-focus-width) solid var(--ms-text);outline-offset:var(--ms-space-2)}
.home-descriptor{
  margin:var(--ms-space-4) 0 0;text-align:center;
  font:400 var(--ms-size-micro)/1.4 var(--ms-font-ui);letter-spacing:var(--ms-track-micro);text-transform:uppercase;
  color:var(--ms-text-4);font-variant-numeric:tabular-nums;
}
.home-sentence{font:400 var(--ms-size-body)/1.6 var(--ms-font-display);margin:0;color:var(--ms-text);text-wrap:pretty}
.home-day-complete{margin:var(--ms-space-1) 0 var(--ms-space-3)}
.home-strip{margin:0 calc(var(--ms-space-1) * -1) var(--ms-space-3)}
.home-play{width:100%;margin:0}
.home-share{display:block;margin:0 auto;padding-inline:var(--ms-space-2)}
/* The last seven days: a column per day, the day letter, its tile and the date, in the body face
   at the small step; the counts and the dates align as numerals. A perfect day wears the crane,
   a played day its count; today is ringed in ink, as the strip rings the next level. */
.home-week{margin-top:var(--ms-space-7)}.home-days{display:grid;grid-template-columns:repeat(7,1fr);gap:6px;margin:var(--ms-space-4) 0 0}
.home-day{appearance:none;background:none;border:0;padding:var(--ms-space-1) 0;display:flex;align-items:center;flex-direction:column;gap:var(--ms-space-3);color:var(--ms-text-2);font:400 var(--ms-size-small) var(--ms-font-display);font-variant-numeric:tabular-nums;min-height:var(--ms-hit-min);cursor:pointer;
  touch-action:manipulation;-webkit-tap-highlight-color:transparent}
.home-day.today{color:var(--ms-text-bright)}
.home-day .level-tile .paper-symbol{width:86%;height:86%}
.home-day.today .level-tile{outline:1.5px solid var(--ms-text-bright);outline-offset:3px}
.home-week .home-note{margin:var(--ms-space-2) 0 0}
.home-note{font:400 var(--ms-size-body)/1.6 var(--ms-font-display);color:var(--ms-text-2);margin:var(--ms-space-3) 0 var(--ms-space-6)}
.home-learning-row{display:block;width:100%;min-height:52px;padding:14px 0;text-align:left;background:none;border:0;border-bottom:var(--ms-rule);font:400 16px var(--ms-font-display);color:var(--ms-text);cursor:pointer}
.home-learning-row:disabled{opacity:.4;cursor:default}
@media (hover:hover){
  .home-day:not(:disabled):hover,.home-learning-row:not(:disabled):hover{color:var(--ms-text-bright)}
  .home-day:hover .level-tile{box-shadow:0 2px 5px var(--ms-shadow)}
}
.home-play:focus-visible,.home-share:focus-visible,.home-day:focus-visible,.home-learning-row:focus-visible,#customSize:focus-visible{outline:var(--ms-focus-width) solid var(--ms-text);outline-offset:var(--ms-focus-offset)}
.home-custom .home-head .home-note{margin-bottom:0}
.home-custom .home-figure{margin:var(--ms-space-5) 0 var(--ms-space-4)}

/* The core Learning tab (§3.2): the three teaching sheets by name, a finished one in the quiet
   tone; then the rule as three law strips, each a row of three squares of the core sheet (ink
   onto a square, the square it makes) and its sentence, on the shared hairline. The squares are
   drawn by the sheet (masugami-kagami-screen.js kagamiLawTile), so a pale mark is the material's. */
.home-learning-row.finished{color:var(--ms-text-2)}
.home-laws{margin-top:var(--ms-space-7)}
.home-law{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:var(--ms-space-4);padding:var(--ms-space-4) 0;border-bottom:var(--ms-rule)}
.home-law-eq{display:flex;align-items:center;gap:var(--ms-space-1)}
.home-law-eq .op{color:var(--ms-text-4);font:300 var(--ms-size-footnote)/1 var(--ms-font-display)}
.home-law p{margin:0;font:400 var(--ms-size-body)/1.5 var(--ms-font-display);color:var(--ms-text-2);text-wrap:pretty}
.home-law p b{color:var(--ms-text-bright);font-weight:400}
.kagami-law-tile{display:block;flex:none}
/* A tile is a scrap of the sheet, not a sheet: it keeps the paper's lift, at a tile's height. */
html .kagami-law-tile .kagami-paper.still-sheet{--ms-paper-lift:0 1px 2px var(--ms-shadow), 0 3px 6px var(--ms-shadow)}
/* The core Daily's five tiles stand at the column's edge, under the words, as Clean's ten do. */
.home-core .level-strip.home-strip.kagami-strip{margin:0 0 var(--ms-space-3) calc(var(--ms-space-1) * -1)}

/* Desktop (W-b 6): every Home tab is one 860px layout, the sheet at the left and the words in a
   378px column at the right. The header spans the layout; the tabs sit at the left, 378px wide,
   under the wordmark. How to play lays its demo stage (larger) beside its steps, and the
   Learning list and the laws continue in the words column. */
@media (min-width:900px){
  html[data-view="home"] .wrap{max-width:calc(860px + 2 * var(--ms-gutter))}
  /* At 378px the sticky band's own ground would read as a box over the glow; the desktop page
     is short enough that the tabs need not follow the scroll. */
  html[data-view="home"] .main-navigation{max-width:378px;position:static;background:transparent}
  html[data-view="home"][data-theme="kasure"] .main-navigation::before{content:none}
  .home-layout{display:grid;grid-template-columns:minmax(0,1fr) 378px;grid-template-rows:auto 1fr;
    grid-template-areas:"figure head" "figure words";column-gap:var(--ms-space-8);align-items:start}
  .home-head{grid-area:head;padding-top:var(--ms-space-7)}
  .home-words{grid-area:words;padding-top:var(--ms-space-6)}
  .home-figure{grid-area:figure;margin:0;padding:var(--ms-space-6) 0 var(--ms-space-8);position:sticky;top:var(--ms-space-8)}
  .home-custom .home-figure{margin:0}
  .home-custom .home-head{padding-top:0}
}
#customSize{display:block;width:100%;padding:14px;margin:var(--ms-space-3) 0 var(--ms-space-4);background:var(--ms-card);color:var(--ms-text-bright);border:var(--ms-rule);font:400 var(--ms-size-input) var(--ms-font-display)}
#customSize option{background:var(--ms-card);color:var(--ms-text-bright)}
/* The way home, in the game view's one row: the drawn chevron alone at the centre of a full hit
   square, which reaches into the gutter so the chevron sits near the column's edge. The
   destination stays its accessible name ("Back to Daily"). */
#gameBack{display:flex;align-items:center;justify-content:center;flex:none;width:var(--ms-hit-min);height:var(--ms-hit-min);margin:0 0 0 calc(var(--ms-space-4) * -1);padding:0}
#gameBack .back-chevron{flex:none;width:9px;height:15px}

/* The Milestones dialog (STANDINGS_WORK_ORDER §4.3): the four milestones from the visitor's own
   progress. Closes from the ×, Escape and the backdrop; the same shell the Settings panel uses.
   The summary is a sentence; each row is a title and its sentence beside the mark, and the count
   or the day it was earned is a quantity in Shippori Mincho with aligned numerals. */
.home-milestones-dialog{box-sizing:border-box;width:min(480px,calc(100% - 32px));max-height:calc(100dvh - 48px);overflow:auto;margin:auto;padding:24px;background:var(--ms-bg);color:var(--ms-text);border:var(--ms-rule)}
.home-milestones-dialog::backdrop{background:var(--ms-scrim-soft)}
.home-milestones-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin:-8px 0 8px}
.home-milestones-head .home-headline{margin:12px 0 0}
#achievementsTitle:focus{outline:0}
.home-milestones-close{appearance:none;border:0;background:transparent;color:var(--ms-text);font:400 24px/1 var(--ms-font-ui);cursor:pointer;min-width:46px;min-height:46px;margin-right:-12px}
.home-milestones-close:focus-visible{outline:2px solid var(--ms-text);outline-offset:-4px}
.home-milestones-summary{font:400 var(--ms-size-body)/1.65 var(--ms-font-display);font-variant-numeric:tabular-nums;margin:0 0 var(--ms-space-3);padding-bottom:var(--ms-space-3);border-bottom:var(--ms-rule);color:var(--ms-text)}
.home-milestone{margin:0;display:grid;grid-template-columns:24px minmax(0,1fr) auto;gap:var(--ms-space-4);align-items:start;padding:var(--ms-space-5) 0;border-bottom:1px solid var(--ms-text-faint)}
.home-milestone-mark{width:24px;height:24px;background:var(--ms-paper);position:relative;margin-top:2px;box-shadow:inset 0 0 0 1px var(--ms-cell-line)}
.home-milestone.earned .home-milestone-mark{box-shadow:none}
.home-milestone h3{text-transform:none;letter-spacing:0;border:0;padding:0;font:400 var(--ms-size-title)/1.3 var(--ms-font-display);color:var(--ms-text-2);margin:0 0 var(--ms-space-1)}
.home-milestone.earned h3{color:var(--ms-text-bright)}
.home-milestone .home-note{margin:0}
.home-milestone-status{margin:var(--ms-space-1) 0 0;font:400 var(--ms-size-small)/1.5 var(--ms-font-display);font-variant-numeric:tabular-nums;color:var(--ms-text-3);white-space:nowrap}
.home-milestones-note{margin:20px 0 0}
@media(max-width:360px){.home-milestones-dialog{padding:20px}.home-milestone{gap:12px}}

/* Kasure's verdigris room. The Daily's paper surface is now the next level's sheet itself
   (W-b 4), so the card that stood in for it is gone; navigation and the week stay on the teal
   ground. The result's room carries the same grain. */
[data-theme="kasure"] body::before{content:"";position:fixed;inset:0;pointer-events:none;background:url("/releases/0b51053c901639b393d3e503/assets/kasure-paper-grain.jpg") center/512px;opacity:.45;mix-blend-mode:multiply;z-index:0}
[data-theme="kasure"] #achievementsBtn{color:var(--ms-ornament-plum)}

[data-theme="kasure"] .wrap{position:relative}


[data-theme="kasure"] .counter{font-weight:400;color:var(--ms-text-3)}

/* Keep the approved logo lockup clear of all three controls on narrow phones. */
@media(max-width:380px){
  .wrap{padding-inline:20px}
  header{gap:8px}
  .brand{gap:8px}
  .brand .mark{width:28px;height:28px}
  .wordmark{font-size:20px;letter-spacing:1.5px}
}

[data-theme="kasure"] .main-navigation{isolation:isolate}
[data-theme="kasure"] .main-navigation::before{content:"";position:absolute;inset:0;background:url("/releases/0b51053c901639b393d3e503/assets/kasure-paper-grain.jpg") center/512px;opacity:.45;mix-blend-mode:multiply;pointer-events:none;z-index:-1}
/* The animated how-to in the core Learning tab (lane G6w), above the laws, as they stand. */
.home-howto.kagami-howto{margin-top:var(--ms-space-7)}
.home-howto .kagami-howto-stage{margin-top:var(--ms-space-4)}
.home-howto .kagami-howto-pause{margin-top:var(--ms-space-2);padding-inline:0}
@media (prefers-reduced-motion: reduce){.home-howto > .kagami-howto-pause{display:none}}
/* The crest gallery (lane G6w, C-O7): a quiet wall of the days' crests, each the day's fifth sheet
   finished, on the page's own paper. No card, chip or badge: the crest, the day and its date, and
   whether it was a perfect day, in the page's words. Each square is reserved before its crest is
   drawn (as it nears the viewport), so nothing moves. The link that opens it sits under the week. */
.home-crests-link{
  display:flex;width:fit-content;align-items:center;min-height:var(--ms-hit-min);margin-top:var(--ms-space-2);
  font:400 var(--ms-size-small)/1.4 var(--ms-font-display);color:var(--ms-text-2);
  text-decoration:underline;text-decoration-color:var(--ms-text-4);text-underline-offset:var(--ms-space-1);
}
@media (hover:hover){.home-crests-link:hover{color:var(--ms-text-bright);text-decoration-color:currentColor}}
.home-crests-link:focus-visible{color:var(--ms-text-bright);outline:var(--ms-focus-width) solid var(--ms-text);outline-offset:var(--ms-focus-offset)}
.home-crests{padding-block:var(--ms-space-2) var(--ms-space-8)}
.crest-wall{--crest-columns:3;display:grid;grid-template-columns:repeat(var(--crest-columns),minmax(0,1fr));gap:var(--ms-space-7) var(--ms-space-5);margin:0;padding:0;list-style:none}
@media (min-width:720px){.crest-wall{--crest-columns:4}}

.home-crest{appearance:none;background:none;border:0;padding:0;width:100%;display:flex;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;color:var(--ms-text-2);font:400 var(--ms-size-small)/1.4 var(--ms-font-display);font-variant-numeric:tabular-nums;cursor:pointer}
.home-crest{touch-action:manipulation;-webkit-tap-highlight-color:transparent}
@media (hover:hover){.home-crest:hover{color:var(--ms-text-bright)}}
.home-crest:focus-visible{outline:var(--ms-focus-width) solid var(--ms-text);outline-offset:var(--ms-focus-offset)}
/* The square is the core sheet's paper (its tokens, light, shade and lift); the crest drawn on it is
   one image of its creases and joined ink, filling it. */
.crest-sheet{position:relative;display:block;width:100%;aspect-ratio:1/1;margin-bottom:var(--ms-space-3);
  background-color:var(--ms-paper);background-image:var(--ms-paper-light),var(--ms-paper-shade);box-shadow:var(--ms-paper-lift)}
.crest-sheet img{position:absolute;inset:0;display:block;width:100%;height:100%;pointer-events:none}
.crest-day{color:var(--ms-text-bright)}
.home-crests-empty{max-width:34ch}
