/* roster.sg's public pages: the K Moonlight look (docs/DESIGN-LOOK.md) opened on its Day face, Concept A "Moonlight on paper" (the owner's ruling of 5 October 2026), for plain HTML pages with no framework. */
/* The two token blocks are copied from platform/web/src/styles/theme.css with the same names; every literal colour in this file lives in them. Here Day is the bare :root and the default, and Night is :root[data-theme="dark"], stamped before the first paint by each page's inline script when this browser chose Night; the app keeps the opposite default in its own stylesheet. There is deliberately no prefers-color-scheme rule. Hex values that would read as five digits then a letter are written as rgb(). */

@font-face {
  font-family: "Onest";
  src: url("/fonts/onest-latin.woff2") format("woff2");
  font-weight: 300 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Geist Mono";
  src: url("/fonts/geist-mono-latin.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---- the tokens: day, warm paper, the public pages' default ---- */
:root {
  color-scheme: light;
  --rm-bg: #f4f2ed;
  --rm-s1: #faf9f6;
  --rm-s2: #ffffff;
  --rm-s3: #ebe8e1;
  --rm-line: rgba(22, 22, 26, 0.09);
  --rm-line-2: rgba(22, 22, 26, 0.15);
  --rm-edge: #8e8b84;
  --rm-text: rgb(24, 24, 27);
  --rm-text-2: rgb(85, 86, 91);
  --rm-text-3: rgb(102, 103, 108);
  --rm-day: #9a6a12;
  --rm-eve: #a44d3d;
  --rm-night: #3e4d8e;
  --rm-rest: #716d64;
  --rm-moon: #1d2230;
  --rm-on-moon: #f4f2ed;
  --rm-keep: #c49a45;
  --rm-win: #e3e0d8;
  --rm-mass: #ece9e2;
  --rm-focus: #1d2230;
  --rm-orb: var(--rm-day);
  --rm-stage: rgb(8, 9, 10);

  --rm-sans: "Onest", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --rm-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ---- the tokens: night, chosen on this browser ---- */
:root[data-theme="dark"] {
  color-scheme: dark;
  --rm-bg: rgb(8, 9, 10);
  --rm-s1: #0f1012;
  --rm-s2: rgb(22, 23, 26);
  --rm-s3: #1e1f23;
  --rm-line: rgba(255, 255, 255, 0.07);
  --rm-line-2: rgba(255, 255, 255, 0.12);
  --rm-edge: rgb(98, 101, 110);
  --rm-text: #e8e8e6;
  --rm-text-2: #a3a5ab;
  --rm-text-3: #8b8d94;
  --rm-day: #d8bf8e;
  --rm-eve: #cfa29b;
  --rm-night: #9ca6c8;
  --rm-rest: #9d998f;
  --rm-moon: #cfd5e2;
  --rm-on-moon: rgb(8, 9, 10);
  --rm-keep: #efe7cc;
  --rm-win: rgb(23, 24, 28);
  --rm-mass: #0d0e10;
  --rm-focus: #cfd5e2;
  --rm-orb: var(--rm-moon);
  --rm-stage: rgb(8, 9, 10);
}

/* ---- the type scale and the spacing rhythm (pass 4, outbox/PROMO-SEO/DESIGN-BRIEF_2026-10-05_polish.md): four sizes, 15, 17, 20 and 32 px (40 on a desk), in rem so a reader's own setting still works, plus the clip's caption line at 16 px by the owner's ruling; weights 400 and 500 only; every gap a step of the 4 px scale (4, 8, 12, 16, 24, 32, 48, 64, 96) ---- */
:root {
  --rm-fs-small: 0.9375rem;
  --rm-fs-body: 1.0625rem;
  --rm-fs-head: 1.25rem;
  --rm-fs-title: 2rem;
  --rm-fs-title-desk: 2.5rem;
  --rm-fs-caption: 1rem;
  --rm-section: 32px;
  --rm-section-desk: 48px;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--rm-bg);
  color: var(--rm-text);
  font-family: var(--rm-sans);
  font-size: var(--rm-fs-body);
  line-height: 1.6;
  font-weight: 400;
  overflow-x: hidden;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--rm-text);
  color: var(--rm-bg);
}

a,
button {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 2px solid var(--rm-focus);
  outline-offset: 2px;
}

a {
  color: var(--rm-text);
  text-decoration: underline;
  text-decoration-color: var(--rm-edge);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

/* The one page motion besides the clips: a hover colour over 150 ms, only where a pointer can hover, so a tap never sticks; instant under reduced motion. */
a,
button,
.pill,
.quiet {
  transition: color 150ms ease-out, background-color 150ms ease-out, text-decoration-color 150ms ease-out;
}

@media (prefers-reduced-motion: reduce) {
  a,
  button,
  .pill,
  .quiet {
    transition: none;
  }
}

@media (hover: hover) {
  a:hover {
    text-decoration-color: currentColor;
  }
}

/* Geist Mono only for figures, dates and the sheet's codes; never a sentence. */
code,
.fig {
  font-family: var(--rm-mono);
  font-size: 0.92em;
  font-variant-numeric: tabular-nums;
}

/* Visually hidden, still read aloud. */
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

[hidden] {
  display: none !important;
}

/* ---- the top band: the wordmark on the left, the Night and Day switch on the right, 64 px, closed by a hairline ---- */

.band {
  border-bottom: 1px solid var(--rm-line);
}

.band-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: calc(34rem + 32px);
  height: 64px;
  margin: 0 auto;
  padding: 0 16px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: var(--rm-fs-body);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--rm-text);
  text-decoration: none;
}

.wordmark .dot {
  color: var(--rm-text-3);
}

.switch {
  display: inline-flex;
  border: 1px solid var(--rm-line-2);
  border-radius: 999px;
}

.switch button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--rm-text-2);
  font: inherit;
  font-size: var(--rm-fs-small);
  min-height: 44px;
  min-width: 44px;
  padding: 0 16px;
  border-radius: 999px;
  cursor: pointer;
}

@media (hover: hover) {
  .switch button:hover {
    color: var(--rm-text);
  }
}

.switch button[aria-pressed="true"] {
  background: var(--rm-text);
  color: var(--rm-bg);
}

/* ---- the one column: at most 34rem, a 16 px gutter, sections split by a hairline with 32 px either side on a phone (64 in all) and 48 either side from 1024 px up (96), never boxed ---- */

.col {
  max-width: calc(34rem + 32px);
  margin: 0 auto;
  padding: 0 16px;
}

section {
  padding: var(--rm-section) 0;
}

section + section {
  border-top: 1px solid var(--rm-line);
}

h1,
h2,
h3 {
  font-family: var(--rm-sans);
  font-weight: 500;
  color: var(--rm-text);
  line-height: 1.25;
}

h1 {
  margin: 0 0 12px;
  font-size: var(--rm-fs-title);
  line-height: 1.15;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

h2 {
  margin: 0 0 12px;
  font-size: var(--rm-fs-head);
  line-height: 1.3;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

h3 {
  margin: 16px 0 8px;
  font-size: var(--rm-fs-body);
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 16px;
}

p:last-child {
  margin-bottom: 0;
}

.lede {
  font-size: var(--rm-fs-body);
  color: var(--rm-text-2);
}

.fine {
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
}

ol,
ul {
  margin: 0 0 16px;
  padding-left: 1.4em;
}

li + li {
  margin-top: 12px;
}

li::marker {
  color: var(--rm-text-2);
  font-variant-numeric: tabular-nums;
}

b {
  font-weight: 500;
}

/* ---- a guide's steps, GOV.UK's step by step: a numbered ring for each, a thin line joining them, the step's words beside ---- */

ol.steps {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  counter-reset: step;
}

ol.steps > li {
  position: relative;
  counter-increment: step;
  margin: 0;
  padding: 0 0 24px 48px;
}

ol.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -2px;
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  border: 1px solid var(--rm-edge);
  border-radius: 50%;
  background: var(--rm-bg);
  font-size: var(--rm-fs-small);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  color: var(--rm-text);
}

ol.steps > li::after {
  content: "";
  position: absolute;
  left: 15px;
  top: 33px;
  bottom: 2px;
  width: 1px;
  background: var(--rm-line-2);
}

ol.steps > li:last-child {
  padding-bottom: 0;
}

ol.steps > li:last-child::after {
  display: none;
}

/* ---- a fold (pass 1 of the word cut, 5 October 2026): a hairline above, a 44 px tap row with a small triangle and a short heading, no box; closed by default, its words still in the page ---- */

details {
  margin: 16px 0 0;
  border-top: 1px solid var(--rm-line);
}

details > summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  list-style: none;
  cursor: pointer;
  font-size: var(--rm-fs-body);
  font-weight: 500;
  color: var(--rm-text);
}

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

details > summary::before {
  content: "";
  flex: none;
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 7px solid var(--rm-text-2);
}

details[open] > summary::before {
  transform: rotate(90deg);
}

details[open] > :last-child {
  margin-bottom: 16px;
}

/* ---- The citing line as a reference at the foot, set apart by space alone (no hairline inside a section) ---- */

.ref {
  margin-top: 16px;
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
}

/* "You need" and "About" lines above a task's steps. */
.need {
  margin: 0 0 16px;
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
}

.need b {
  font-weight: 500;
  color: var(--rm-text);
}

/* The breadcrumb above a tool page's or a guide's title. */
.crumbs {
  margin: 0 0 8px;
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
}

.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.crumbs li {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.crumbs li + li {
  margin-top: 0;
}

.crumbs li + li::before {
  content: "/";
  margin-right: 8px;
  color: var(--rm-text-3);
}

.crumbs a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--rm-text-2);
}

/* ---- the clips (pass 3): one figure.clip for every loop and task clip, a 4:3 night stage the full column width with a hairline, then one caption line under it; site.js writes the clip's captions into that line and gives each loop its 44 px pause and play button there. Pass 4: 32 px of air above and below each figure, 8 px from stage to caption line ---- */

figure.clip {
  margin: 32px 0;
}

/* The tool pages' "What it does": each item a clip, then its one sentence, the clip the full column width. */
ol.shows {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
}

ol.shows figure.clip {
  margin: 32px 0 0;
}

ol.shows > li > p {
  margin: 4px 0 0;
  color: var(--rm-text-2);
}

/* A line with no loop of its own (pass 5) stands apart from the clip above it. */
ol.shows > li > p:only-child {
  margin-top: 24px;
}

.clip-stage {
  position: relative;
  aspect-ratio: 4 / 3;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: var(--rm-stage);
  border: 1px solid var(--rm-line-2);
}

.clip-stage video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.clip-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  margin: 8px 0 0;
  font-size: var(--rm-fs-caption);
  line-height: 1.4;
  color: var(--rm-text);
}

.clip-toggle {
  flex: none;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--rm-line-2);
  border-radius: 50%;
  background: var(--rm-s2);
  color: var(--rm-text);
  cursor: pointer;
}

@media (hover: hover) {
  .clip-toggle:hover {
    background: var(--rm-s3);
  }
}

.clip-toggle svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---- controls: the moonlight button and the quiet one, both at least 44 px ---- */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 0;
}

.pill,
.quiet {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 9px;
  font-family: var(--rm-sans);
  font-weight: 500;
  text-decoration: none;
}

.pill {
  padding: 0 24px;
  font-size: var(--rm-fs-body);
  line-height: 1.25;
  letter-spacing: -0.005em;
  color: var(--rm-on-moon);
  background: var(--rm-moon);
}

@media (hover: hover) {
  .pill:hover {
    background: var(--rm-text);
  }
}

.pill:focus-visible {
  outline-offset: 3px;
}

.quiet {
  padding: 0 16px;
  font-size: var(--rm-fs-small);
  line-height: 1.25;
  color: var(--rm-text-2);
  border: 1px solid var(--rm-line-2);
}

@media (hover: hover) {
  .quiet:hover {
    color: var(--rm-text);
    background: var(--rm-s2);
  }
}

/* ---- the tools as plain rows: no panel, a hairline above each row, each row wholly its link, a shift-coloured tick on each row's top rule ---- */

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

.tile {
  position: relative;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  column-gap: 16px;
  row-gap: 4px;
  min-height: 44px;
  padding: 16px 0;
  border-top: 1px solid var(--rm-line);
}

.tiles li + li {
  margin-top: 0;
}

.tile::before {
  content: "";
  position: absolute;
  left: 0;
  top: -1px;
  width: 24px;
  height: 2px;
  background: var(--rm-tone);
}

.tile:nth-child(4n + 1) {
  --rm-tone: var(--rm-day);
}

.tile:nth-child(4n + 2) {
  --rm-tone: var(--rm-eve);
}

.tile:nth-child(4n + 3) {
  --rm-tone: var(--rm-night);
}

.tile:nth-child(4n + 4) {
  --rm-tone: var(--rm-rest);
}

.tile-icon {
  grid-row: 1 / span 2;
  width: 24px;
  height: 24px;
  margin-top: 1px;
  color: var(--rm-tone);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tile-link {
  font-size: var(--rm-fs-body);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.01em;
  color: var(--rm-text);
  text-decoration: none;
}

@media (hover: hover) {
  .tile:hover .tile-link {
    text-decoration: underline;
    text-decoration-color: var(--rm-edge);
  }
}

/* The link's area stretches over the whole row. */
.tile-link::after {
  content: "";
  position: absolute;
  inset: 0;
}

.tile-link:focus-visible {
  outline: none;
}

.tile:has(.tile-link:focus-visible) {
  outline: 2px solid var(--rm-focus);
  outline-offset: 2px;
}

.tile-note {
  grid-column: 2;
  margin: 0;
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
  line-height: 1.5;
}

/* ---- the footer ---- */

.foot {
  padding-top: 24px;
  padding-bottom: 48px;
  border-top: 1px solid var(--rm-line);
  font-size: var(--rm-fs-small);
  color: var(--rm-text-2);
}

.foot ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 16px;
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
}

.foot li + li {
  margin-top: 0;
}

.foot a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--rm-text-2);
}

@media (hover: hover) {
  .foot a:hover {
    color: var(--rm-text);
  }
}

.foot p {
  margin: 0 0 4px;
}

/* The last thing in a section keeps no margin, so every section ends exactly on its own padding and the gaps stay even. */
section > :last-child {
  margin-bottom: 0;
}

/* ---- a desk: the headline at 40 px from 640 px up, and 96 px between sections from 1024 px up ---- */

@media (min-width: 640px) {
  h1 {
    font-size: var(--rm-fs-title-desk);
  }
}

@media (min-width: 1024px) {
  section {
    padding: var(--rm-section-desk) 0;
  }
}
