/* Report, status and start pages. Nothing is fetched from another host (REQ-242): the file
   imports nothing, and the only address it names is the file of the typeface inside
   `/static/`, which the server itself gives (REQ-251). The typeface is Inter; the former
   system set stands behind it as a reserve.

   Two themes, dark by default (REQ-238): the palette is declared twice — the twenty
   properties of the palette table 5.16 in `:root` with their dark values, the same twenty in
   `:root[data-theme="light"]` with their light ones. No line pins the values to that table
   any more (REQ-239 is withdrawn and REQ-257 took its place): what holds is the relation
   between them — the page, the card of a section and an inner element stand on three
   different surfaces in each theme. The `body` rule takes the background and the text colour
   only through `var(--page-bg)` and `var(--page-fg)`, and no other rule of this file gives
   them a literal, so the theme changes by one attribute of the `html` element. There is no
   `prefers-color-scheme` block on purpose: the page is dark until the reader switches it,
   not until the system says so (5.16).

   The colour of a link and of a navigation item comes from `--nav-fg`, not from
   `--accent`: on the dark background the accent gives 2.67:1, and that is the "menu is not
   visible" of the statement (REQ-241).

   Printing is light (REQ-206): the print block declares the light palette to `:root`
   itself, so that printing from the browser — which has no `print=1` — gives a light sheet
   too, and keeps `print-color-adjust: exact`, because the colour of a block tile and the
   green of the growth are content and not decoration (REQ-208). The sheet is painted to
   its four edges (REQ-291): `@page` takes its background from `--page-bg`, which the print
   block declares once, below both palettes of the screen, and the margins of `@page` carry
   the foot of the sheet (REQ-294) and are not white paper.

   Hints open by a click or a tap on a visible sign, and by hover over it where the device
   has a pointer (REQ-191, REQ-192). Paper carries no hint, no fold, no link and nothing to
   press (REQ-235, REQ-236, REQ-237): the printed markup does not hold them, and the print
   block below hides the same parts a second time, for a page printed from the browser, which
   has no `print=1`. The address of a button is in the markup of the screen and drawn nowhere;
   paper has none (REQ-197). */

/* The typeface of the page: Inter, the variable file that lies in `/static/` beside this file
   (REQ-251, decision 113 of the human). The server gives the file itself, so the page asks no
   other host for it, and every `url(…)` of this file points inside `/static/` (REQ-242). The
   weights 100 – 900 are the range of the variable file: every weight the page uses is drawn
   from it and none is made up by the browser. `font-display: swap` shows the text in the
   reserve typeface of `--font` until the file has come. */
@font-face {
  font-family: "Inter";
  src: url("/static/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --page-bg: #151718;
  --page-fg: #dcdcdc;
  --surface: #1a1c1d;
  /* the third surface (REQ-257): the fold, the wrap of a table and the card of an action stand
     on it, so that they do not merge with the card of the section they lie on */
  --surface-soft: #212426;
  --muted: #b9b9ba;
  --line: #212324;
  --line-strong: #2d3031;
  --accent: #761aeb;
  --accent-bright: #8a3eeb;
  --accent-light: #a77bf0;
  --accent-soft: #1f1b29;
  --good: #4fc917;
  --good-soft: #16240f;
  --warning-soft: #2a2410;
  --critical: #e0825f;
  --critical-soft: #2a1714;
  --radius: 12px;
  --radius-small: 8px;
  --shadow: none;
  --shadow-card: none;
  /* the shadow of a hint that floats over the page (REQ-261): the value of the mockup */
  --shadow-pop: 0 14px 38px rgba(0, 0, 0, 0.5);
  /* the colour of a link and of a navigation item: the value of the prototype
     (`--accent-light`), 5.77:1 to the page background (REQ-241) */
  --nav-fg: #a77bf0;
  /* "weak": amber instead of red, the prototype has no such name (5.15, 5.16) */
  --warning: #e8b84b;
  /* the mark of the free test: a calm pair instead of the former literals (REQ-213) */
  --test-fg: #bdf0a0;
  --test-bg: #1e3214;
  /* the stripe of an even row of a table (REQ-266): the white of the mockup at 2 % on the dark
     wrap. Each theme declares a value of its own, because the same 2 % on the light wrap moves
     a channel by less than one level and the stripe would not be seen */
  --row-even: rgba(255, 255, 255, 0.02);
  /* the size of the body text (REQ-252) */
  --font-size-base: 17px;
  /* the scale of the type sizes of the mockup (5.17); the floating ones are `clamp` between a
     narrow window and a wide one. Each of these is held by a line and taken by a rule:
     `--fs-h2` the title of a section (REQ-252), `--fs-h1` the domain of the head and
     `--fs-small` the item of the navigation (REQ-267), `--fs-hero` the verdict (REQ-254),
     `--fs-kpi` the number of a tile of the first screen (REQ-280), `--fs-h3` the three titles
     of the third level (REQ-279) */
  --fs-small: 14px;
  --fs-h3: clamp(17px, 1.3vw, 19px);
  --fs-h2: clamp(21px, 2.4vw, 27px);
  --fs-h1: clamp(24px, 3.2vw, 32px);
  --fs-hero: clamp(27px, 3.4vw, 38px);
  --fs-kpi: clamp(38px, 5vw, 56px);
  /* the rhythm of the mockup (5.17). `--gap-section` is the step between the cards of the
     sections: the rule of `[data-section]` takes it (REQ-256), and the phone block declares it
     again (REQ-268). It is declared here and not in the light palette on purpose: a rule of
     that palette would outrank the phone block. `--gap-group` is the step between the groups
     inside a card. It is declared and taken by no rule yet: the mockup applies it under the
     head of a section and above the tiles of the first screen, and no line of the document
     names either place. Whether to carry them is the human's choice, and he put it off until he
     sees the assembled page (question 78, decision 142) */
  --gap-section: 48px;
  --gap-group: 26px;
  /* Inter first, then the former system set as a reserve (REQ-251) */
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

:root[data-theme="light"] {
  --page-bg: #f4f5f7;
  --page-fg: #1f2328;
  --surface: #ffffff;
  --surface-soft: #f0f2f5;
  --muted: #5c6670;
  --line: #dfe3e8;
  --line-strong: #c3cad2;
  --accent: #0f4c9a;
  --accent-bright: #1766c8;
  --accent-light: #86b6ef;
  --accent-soft: #e8f0fb;
  --good: #0b7a3b;
  --good-soft: #e7f4ec;
  --warning-soft: #fdf3dc;
  --critical: #a8301f;
  --critical-soft: #fbeceb;
  --radius: 10px;
  --radius-small: 6px;
  --shadow: 0 1px 2px rgba(15, 20, 28, 0.06);
  --shadow-card: 0 1px 3px rgba(15, 20, 28, 0.08);
  --shadow-pop: 0 14px 38px rgba(15, 20, 28, 0.22);
  --nav-fg: #0f4c9a;
  --warning: #8a5a00;
  --test-fg: #0b5a2c;
  --test-bg: #d6ecdd;
  /* the white at 60 % lifts an even row above the grey wrap by 6 – 9 levels of a channel and
     keeps every text colour of the page on it at 5:1 or more; a dark tint of 4 % lowers the
     row by about as much and takes the green of the growth to 4.47:1 */
  --row-even: rgba(255, 255, 255, 0.6);
  --font-size-base: 17px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* the root size is declared here so that a length written in `rem` is read in pixels from
   this file alone */
html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  position: relative;
  margin: 0;
  background: var(--page-bg);
  color: var(--page-fg);
  font: 400 var(--font-size-base)/1.6 var(--font);
}

/* The decorative layer of the sample (REQ-194, decision 86 of the human), built by the measures of the
   prototype: a background highlight of three radial gradients behind everything. The layer
   is fixed, catches no clicks and lies below the content, which the next rule lifts. */
body::before {
  content: "";
  position: fixed;
  inset: -20vh -20vw;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(60vw 60vh at 18% 8%, rgba(118, 26, 235, 0.22), transparent 60%),
    radial-gradient(50vw 50vh at 88% 22%, rgba(93, 235, 26, 0.08), transparent 60%),
    radial-gradient(45vw 45vh at 70% 92%, rgba(217, 119, 87, 0.10), transparent 60%);
}

/* `overflow-x: clip` keeps what a floating hint throws beyond the window out of the width of
   the page (REQ-264, REQ-268): a hint is closed by `visibility`, not by `display`, so its box
   stays in the layout and, at a sign near the edge of a narrow window, reaches past it.
   `clip`, unlike `hidden`, makes no scroll container of the part and breaks no `sticky` */
body > * {
  position: relative;
  z-index: 1;
  overflow-x: clip;
}

h1, h2, h3, h4, p, ul, ol, dl, dd {
  margin: 0;
}

/* The tracking of an `<h1>` that sets none of its own: the title of the start page and of the
   status page (`.card__title`). The bare heading rules of the prototype (5.16, measured fact
   16) set a size, a weight and a leading as well, but every `<h1>`, `<h2>` and `<h3>` of the
   templates carries a class that sets its own — such as `.head__domain`, `.card__title`,
   `.section__title` (REQ-252) and the titles of the third level (REQ-279) — so those
   declarations were never seen, and they are gone together with the bare `h2` and `h3`
   rules. */
h1 {
  letter-spacing: -0.02em;
}

ul, ol {
  padding: 0;
  list-style: none;
}

/* a link and a navigation item take their colour from `--nav-fg` and never from
   `--accent`: on the dark background the accent gives 2.67:1 (REQ-241) */
a {
  color: var(--nav-fg);
  text-underline-offset: 0.18em;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible,
label:focus-within {
  outline: 2px solid var(--accent-light);
  outline-offset: 2px;
}

q {
  quotes: "\00ab" "\00bb";
  font-style: italic;
}

table {
  border-collapse: collapse;
}

.wrap {
  width: min(1120px, 100% - 32px);
  margin-inline: auto;
}

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

.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* the running text of the start form and of the status page; the report page does not hold
   this class, and the document leaves its measure at 52 characters (5.17). The measure of
   the reference, 43-53 characters, is cancelled for the report by REQ-250 */
.prose {
  max-width: 52ch;
}

.prose--lead {
  font-size: 16px;
}

/* The measure of the running text of a section: not narrower than 70 characters, one rule for
   the twelve elements of the list of REQ-250 (the five of the mockup, decision 116 of the
   human, and the seven former rules of 52 characters that decision 123 added). `ch` is
   measured by the size of the element itself, so the declaration is the measure in
   characters. The rules of these elements below carry no `max-width` of their own: a narrower
   one would win by its place in the file and not by intent. `.block__label` is the sixth
   selector of the mockup and is inert on purpose: it is an inline `span` inside a paragraph,
   and `max-width` does not apply to an inline element. `.audience` and `.objection` are
   paragraphs inside `.fold__body`; `.fold__body p` outranks their own 52 characters below.
   `.prose` is not in the list: it stands on the start form and the status page, not on the
   report. */
.section__lead,
.keyword-part__lead,
.fold__body p,
.stage__purpose,
.stage__checkpoint,
.self-proof,
.promise,
.stage__items,
.note,
.actions__age,
.actions__note,
.recommendation,
.block__label {
  max-width: 70ch;
}

/* --- head --------------------------------------------------------------- */

/* the glass head of the sample (REQ-194): the underlay is blurred, and the surface is let
   through by 28 % so that there is something to blur; where `color-mix` is not understood,
   the opaque surface of the first declaration stays */
.head {
  padding: 18px 0 12px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  background: color-mix(in srgb, var(--surface) 72%, transparent);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

.head__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px 16px;
}

.head__domain {
  font-size: var(--fs-h1);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}

.head__date {
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

.head__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin-top: 10px;
  font-size: 13px;
}

.head__nav a {
  padding: 3px 0;
  font-size: var(--fs-small);
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
}

.head__nav a:hover {
  border-bottom-color: var(--accent);
}

/* --- banner of a running rerun ------------------------------------------ */

.banner {
  padding: 8px 0;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 14px;
}

.banner--warning {
  background: var(--warning-soft);
  color: var(--critical);
}

/* --- sections ----------------------------------------------------------- */

/* Every section is drawn as a card of its own (REQ-212): the surface stands a tone lighter
   than the page, the border is a hairline, the radius is the one of the palette, and the
   depth comes from the surface and the border and not from a shadow (5.15). The card
   carries the measure of `.wrap` itself, because the markup puts `.wrap` inside the
   section. The step between the cards is the top margin and takes the property
   `--gap-section`: 48 px, and 30 px where the phone block declares it again (REQ-256,
   REQ-268). The former `margin: 12px auto 0` is replaced and not kept beside it: a shorthand
   that stood after `margin-top` would put the 12 px back while every check stayed green.
   The 12 pt of the reference (5.15) is no longer the source of the step — the mockup is
   (5.17). The padding of the card is as it was: no line names it (question 78, decision
   142). */
[data-section] {
  width: min(1120px, 100% - 32px);
  margin-inline: auto;
  margin-top: var(--gap-section);
  padding: 20px 24px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: none;
}

[data-section] > .wrap {
  width: 100%;
}

/* An element of a grid does not shrink below its content: without `min-width: 0` a wide table
   carries the whole text of the section off the edge of the window. The table scrolls inside
   its own wrap instead (REQ-264). */
[data-section],
[data-section] > .wrap,
.keyword-part,
.fold__body {
  min-width: 0;
}

.section__head {
  margin-bottom: 12px;
}

.section__title {
  font-size: var(--fs-h2);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.section__lead {
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
}

/* --- titles of the third level ------------------------------------------ */

/* The title of a part of the phrase list, the title of the tile of a block and the title of a
   stage of the map take their size from `--fs-h3` (REQ-279), in one rule at the top level and
   not inside a block of `@media`. None of the three rules of their own below carries a size,
   and the weight stays in each of them: no line names the weight or the tracking of the
   mockup (5.17). `--fs-h3` is a `clamp` between 17 px and 19 px and is declared once, in
   `:root`; a block that declared it again outside those bounds would break the line. */
.keyword-part__title,
.block__title,
.stage__title {
  font-size: var(--fs-h3);
}

/* --- inner surfaces ----------------------------------------------------- */

/* Three surfaces (REQ-257): the page (`--page-bg`), the card of a section (`--surface`) and an
   inner element (`--surface-soft`) — the fold, the wrap of a table and the card of an action.
   The background of these three and the border colour of the fold and of the card of an
   action are declared here and nowhere else, because a rule of their own that came later in
   the file would win over these by its place. Both rules stand above the rules of the variants
   and the states: `.cta--primary` below gives its own background and border colour with the
   same specificity, and a rule placed after it would put them out. The tile of a block is not
   here, because the human left it as it is (decisions 112 and 130), and neither is the card
   of a stage, which is transparent (REQ-262). The wrap of a table keeps the border of its own
   rule. */
.fold,
.table-scroll,
.cta {
  background: var(--surface-soft);
}

.fold,
.cta {
  border-color: var(--line-strong);
}

/* --- conclusion: verdict, output lines, tiles --------------------------- */

/* The first screen gives one element the win (5.17). The card of the section `conclusion` has
   a padding and a border of its own and a radial glow over its surface; the glow is the same
   decorative layer that REQ-194 holds for the page, and no line of its own holds it. The rule
   stands after the card rule above and wins over it by its place. */
[data-section="conclusion"] {
  padding: 44px 32px 38px;
  border-color: var(--line-strong);
  background:
    radial-gradient(120% 150% at 0% 0%, rgba(138, 62, 235, 0.16), transparent 58%),
    var(--surface);
}

/* The title of the section `conclusion` is an overline: 13 px, capitals, the colour of a
   second-rank text (REQ-253). The tag stays `h2` and the text stays the text of its key; only
   the look changes. */
[data-section="conclusion"] .section__title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* The verdict takes the hero size of the scale and a measure of 24 characters (REQ-254). The
   wide block below narrows the measure, and the phone block lifts it (REQ-268). */
.verdict {
  max-width: 24ch;
  font-size: var(--fs-hero);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.015em;
}

.lede {
  margin-top: 10px;
}

/* The first line of the output is set in the size of the body text at a measure of 58
   characters (REQ-255). `.lede` stands only inside the section `conclusion`, and the measure
   rule of REQ-250 does not list it. */
[data-section="conclusion"] .lede {
  font-size: 17px;
  line-height: 1.6;
  max-width: 58ch;
}

.kpi-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

/* A tile carries a bar along its bottom edge: the track and the bar are two pseudo-elements,
   and the bar is as wide as the share of the number of the tile, which the markup hands over
   in `--kpi-share` (REQ-258). `position: relative` is what anchors them to the tile — without
   it they would sit at the bottom of `main` — and `overflow: hidden` keeps them inside its
   rounded corners. The bar prints no text: the page shows the number already (decision R-110). */
.kpi {
  position: relative;
  overflow: hidden;
  flex: 1 1 220px;
  display: flex;
  flex-direction: column;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.kpi::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: var(--line-strong);
}

.kpi::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 1;
  height: 4px;
  width: var(--kpi-share);
  border-radius: 0 3px 3px 0;
}

.kpi-row .kpi:nth-child(1)::before {
  background: var(--critical);
}

.kpi-row .kpi:nth-child(2)::before {
  background: var(--good);
}

/* The number of a tile takes the largest size of the scale (REQ-280). The weight 800, the
   leading 1 and the tracking of the mockup are not carried: no line names them. */
.kpi__value {
  font-size: var(--fs-kpi);
  line-height: 1.05;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.kpi__caption {
  margin-top: 2px;
  font-size: 13px;
}

.kpi__base {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.self-proof {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

/* --- actions ------------------------------------------------------------ */

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

/* the surface and the border colour of the card come from the rules of the inner surfaces
   above (REQ-257): the border is set here by its width and style only, because the shorthand
   `border` would reset the colour those rules gave */
.cta {
  flex: 1 1 320px;
  padding: 14px;
  border-width: 1px;
  border-style: solid;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.cta--primary {
  border-color: var(--accent-light);
  background: var(--accent-soft);
}

.cta__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 10px 14px;
}

.cta__text {
  flex: 1 1 220px;
  min-width: 0;
}

.cta__reason {
  font-size: 14px;
  font-weight: 600;
}

.cta__after,
.cta__inactive {
  color: var(--muted);
  font-size: 13px;
}

/* the address of a button stands in the markup and is not drawn: on the screen the button
   carries it, and paper has no address of an action at all (REQ-197) */
.cta__address {
  display: none;
}

.statement {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.button {
  display: inline-block;
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-small);
  background: var(--accent-bright);
  color: #ffffff;
  font: inherit;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

/* `.button--outline` stands on a link of the page, and a link takes its colour from
   `--nav-fg`: on the dark surface the accent gives 2.54:1 (REQ-241) */
.button--outline,
.button--ghost {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--nav-fg);
}

.button--ghost {
  border-color: transparent;
}

.button--small {
  padding: 5px 10px;
  font-size: 13px;
  font-weight: 500;
}

.button:hover {
  border-color: var(--accent);
}

.button.is-disabled,
.button[disabled] {
  border-color: var(--line-strong);
  background: var(--surface-soft);
  color: var(--muted);
  cursor: default;
}

/* --- hints -------------------------------------------------------------- */

/* A hint floats over the page and moves nothing (REQ-261): the wrapper is the context the text
   is anchored to, and the text stands out of the flow, `absolute`, under the sign and centred
   on it. It is shown by `opacity` with `visibility` and never by `display`: a box that changes
   its `display` comes into the flow and the layout jumps. */
.hint {
  position: relative;
  display: inline-block;
  vertical-align: baseline;
  white-space: normal;
}

.hint__sign {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 17px;
  height: 17px;
  margin-left: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
  cursor: pointer;
  user-select: none;
}

.hint__switch {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
}

.hint__text {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  translate: -50% 0;
  z-index: 60;
  width: max-content;
  max-width: min(380px, 72vw);
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-pop);
  color: var(--page-fg);
  font-size: 13px;
  font-weight: 400;
  font-style: normal;
  line-height: 1.5;
  letter-spacing: 0;
  text-align: left;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

/* the corner of the hint: a square turned by 45 degrees with its two outer borders only, which
   points at the sign (REQ-261) */
.hint__text::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 50%;
  translate: -50% 0;
  width: 9px;
  height: 9px;
  rotate: 45deg;
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line-strong);
  background: var(--surface-soft);
}

/* the hint opens by its switch: a click or a tap on the sign turns it on, and the switch
   stands inside its label (5.14), so the hint is reached from the wrapper (REQ-191); and where
   the device has a pointer, the pointer over the sign opens it too, the text being a later
   sibling of the sign (REQ-191). An open hint takes the pointer back, so that a source link
   inside it can be pressed */
.hint__sign:hover ~ .hint__text,
.hint:has(.hint__switch:checked) .hint__text {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* a touch screen keeps the hover after a tap and would hold the hint open for good: where
   there is no hover, the hover opens nothing and only the tap does (REQ-192). The rule of
   the switch above is stronger than this one — its `:has` carries the specificity of
   `:checked` — so a hint that was tapped open stays open */
@media (hover: none) {
  .hint__sign:hover ~ .hint__text {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
}

/* a hint holds one line or several; every line stands apart from the next */
.hint__line {
  display: block;
}

.hint__line + .hint__line,
.hint__line + .hint__caption {
  margin-top: 4px;
}

.hint__line + .hint__caption {
  display: block;
}

.hint__caption {
  font-weight: 600;
}

.hint__text .record {
  display: block;
  margin-top: 3px;
}

.source {
  font-size: 12px;
}

/* --- folds -------------------------------------------------------------- */

/* the surface and the border colour of the fold come from the rules of the inner surfaces
   (REQ-257); the border is set here by its width and style only, like the one of `.cta` */
.fold {
  margin-top: 12px;
  border-width: 1px;
  border-style: solid;
  border-radius: var(--radius);
}

.fold__summary {
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

/* a fold printed open has no summary: its title is a heading of its own, standing where the
   summary stood and looking as it looked (REQ-236) */
.fold__title {
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 600;
}

.fold__body {
  padding: 0 14px 14px;
  border-top: 1px solid var(--line);
}

.fold__body > :first-child {
  margin-top: 12px;
}

/* --- keyword tables ----------------------------------------------------- */

.keyword-part {
  margin-top: 16px;
}

/* the air before the second part of the list (REQ-263): the first part keeps the 16 px above
   it, under the head of the section, and the second one stands 44 px below the first */
.keyword-part + .keyword-part {
  margin-top: 44px;
}

.keyword-part__title {
  font-weight: 650;
}

.keyword-part__lead {
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

/* a table wider than its wrap scrolls inside the wrap and never widens the page (REQ-264); the
   surface of the wrap comes from the rules of the inner surfaces (REQ-257), its border stays
   here */
.table-scroll {
  max-width: 100%;
  overflow-x: auto;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.table {
  width: 100%;
  font-size: 14px;
}

.table th,
.table td {
  padding: 6px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

/* The head of a table: capitals of 11 px in the second-rank colour, an opaque background and a
   line under it (REQ-265). `position: sticky` and `top: 0` stand as in the mockup but do
   nothing: the nearest scroll container is `.table-scroll`, which has no height limit and
   never scrolls vertically, so the head does not stick and no line asks it to. */
.table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 12px 10px;
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}

/* a hint opened from the head of a table is running text and not a head: it takes neither the
   capitals nor the tracking of the head it stands in, as it already takes neither its size,
   weight nor colour */
.table thead th .hint__text {
  text-transform: none;
  letter-spacing: normal;
}

/* a hint inside the wrap of a table does not leave the wrap (REQ-261): the head with the hint
   of the forecast is the last column, and a text centred on its sign would stand out over the
   right edge of the wrap — open or closed — and make the wrap scroll. The text hangs from the
   right edge of the sign towards the table, and the corner moves to the sign with it */
.table-scroll .hint__text {
  left: auto;
  right: 0;
  translate: none;
}

.table-scroll .hint__text::before {
  left: auto;
  right: 4px;
  translate: none;
}

.table tbody tr:last-child th,
.table tbody tr:last-child td {
  border-bottom: 0;
}

.table .col-index {
  width: 1%;
  color: var(--muted);
}

.table .cell-text {
  color: var(--muted);
  font-size: 12px;
  white-space: normal;
}

.table tr.is-test {
  background: var(--good-soft);
}

/* every even row of a table has a stripe of its own, except the rows of the free test, which
   keep the background of the rule above (REQ-266, REQ-213). The stripe is a property of the
   palette, `--row-even`, so that each theme and the printed sheet — always light (REQ-206) —
   has a value that is seen on its wrap */
.table tbody tr:nth-child(even):not(.is-test) td {
  background: var(--row-even);
}

/* the mark of the free test takes the pair of the palette instead of the former literals:
   the former lime with white on it was the "poisonous" of the statement (REQ-213) */
.test-mark {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 20px;
  background: var(--test-bg);
  color: var(--test-fg);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

/* the class of the forecast — a calculation, not a measure — is the first line of the hint at
   the head of the column and is never hidden by a rule of its own (REQ-196). It is a line of
   its own, 11 px, weight 400 and not in capitals, although the head it stands in is (REQ-265) */
.forecast-note {
  font-size: 11px;
  font-weight: 400;
  text-transform: none;
}

/* the growth of the forecast — how many places the position gains — stands beside the
   number of the cell (REQ-220) */
.forecast-gain {
  margin-left: 6px;
  font-weight: 600;
  white-space: nowrap;
}

/* the growth is shown in the colour of "found" (REQ-221) */
[data-trend="up"] {
  color: var(--good);
}

/* --- competitors -------------------------------------------------------- */

.competitor-list {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.competitor {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.competitor__name {
  font-size: 16px;
  font-weight: 650;
  overflow-wrap: anywhere;
}

.competitor__count {
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

.competitor__quote {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.competitor__block {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

/* --- blocks of the home page -------------------------------------------- */

.analyzed {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.block-list {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.block {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

/* The state of a block is the colour of its tile (REQ-246): the stripe on the left edge
   takes the colour of the state, and the sign of the state below takes the same one. The
   colour is never the only mark — the sign also stands as a text beside the title (REQ-153).
   `weak` is amber and not red: at the "bad" the intonation is "not done yet" and not "a
   failure", and red the reference has nowhere (5.15). `unchecked` is grey on purpose: the
   page says nothing about the home page there, and yellow would read as "weak" (5.16).
   A block that is not applicable has no tile, so there is no rule for it (REQ-244). */
[data-state="present"] {
  border-left-color: var(--good);
}

[data-state="weak"] {
  border-left-color: var(--warning);
}

[data-state="absent"] {
  border-left-color: var(--critical);
}

[data-state="unchecked"] {
  border-left-color: var(--muted);
}

.block__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 8px;
}

.block__title {
  flex: 1 1 60%;
  font-weight: 600;
}

.chip {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 20px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

/* the sign of the state takes the colour of the state on the soft tone of the same
   colour; the sign of `unchecked` stays as the base `.chip` above, muted on the soft
   surface. Every pair keeps 4.5:1 in both themes (REQ-241). */
[data-state="present"] .chip {
  background: var(--good-soft);
  color: var(--good);
}

[data-state="weak"] .chip {
  background: var(--warning-soft);
  color: var(--warning);
}

[data-state="absent"] .chip {
  background: var(--critical-soft);
  color: var(--critical);
}

.block__label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.quote,
.block__competitor,
.block__recommendation {
  margin-top: 6px;
  font-size: 13px;
}

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

/* The recommendation of a block is a plate of its own inside the tile: its own background,
   the soft surface, and its own border, the strong line, both unlike the tile (REQ-232).
   A block with no recommendation of its own has no plate; its typical line is the plain
   `.block__recommendation` above. */
[data-block="block-recommendation"] {
  margin-top: 8px;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-small);
  background: var(--surface-soft);
  font-size: 13px;
}

/* --- roadmap ------------------------------------------------------------ */

.promise {
  margin-bottom: 10px;
  padding: 8px 12px;
  border-left: 3px solid var(--accent-light);
  background: var(--surface);
  font-size: 14px;
}

/* The roadmap reads as a map (REQ-262): a vertical line of time runs along the list, every
   stage has a dot on it, and the number of a stage with its months is a plate. The list is the
   context of the line and the stage is the context of its dot: without `position: relative` on
   `.stage` the dot would be anchored to `main`. The card of a stage is gone — the stage is
   transparent, with no border, no corner and no shadow — and the air under it parts it from
   the next one. */
.stage-list {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 4px 0 0 36px;
  list-style: none;
}

.stage-list::before {
  content: "";
  position: absolute;
  top: 14px;
  bottom: 18px;
  left: 11px;
  width: 2px;
  background: linear-gradient(var(--accent-light), var(--line-strong));
}

.stage {
  position: relative;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 0 0 30px;
}

.stage::before {
  content: "";
  position: absolute;
  top: 8px;
  left: -33px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--page-bg);
  border: 3px solid var(--accent-light);
}

.stage__number {
  display: inline-block;
  margin: 0 0 10px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-light);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stage__title {
  margin-top: 2px;
  font-weight: 600;
}

.stage__purpose,
.stage__checkpoint,
.stage__items {
  margin-top: 4px;
  font-size: 13px;
}

.stage__checkpoint {
  margin-top: 12px;
  padding: 10px 12px;
  border-left: 3px solid var(--line-strong);
  border-radius: 0 8px 8px 0;
  background: var(--surface-soft);
  color: var(--muted);
}

.stage__label {
  margin-right: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.tag {
  display: inline-block;
  margin: 2px 3px 0 0;
  padding: 1px 7px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface-soft);
  font-size: 12px;
}

.metric-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin-top: 8px;
}

/* A metric of a stage is one row: the label at the left edge, the number at the right one,
   and a line above the row (REQ-260). The row takes the whole width of the list for the
   number to reach the right edge. */
.metric {
  flex: 1 1 100%;
  margin-top: 2px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.metric dl {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin: 0;
}

.metric dt {
  color: var(--muted);
  font-size: 13px;
}

.metric dd {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* --- block of the match of the home page (REQ-224 – REQ-229) ----------- */

/* the block stands open at the end of the section of queries, like a part of the list */
.relevance {
  margin-top: 16px;
}

.relevance__title {
  font-size: 16px;
  font-weight: 650;
}

.meter-row {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 8px;
}

/* A meter carries a bar along its bottom edge, as a tile of the first screen does: the track
   and the bar are two pseudo-elements, the bar is as wide as the percent the meter shows, and
   the markup hands that over in `--meter-share` (REQ-259). `position: relative` anchors them
   to the meter, `overflow: hidden` keeps them inside its rounded corners. */
.meter {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-small);
  background: var(--surface-soft);
}

.meter::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: var(--line-strong);
}

.meter::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 1;
  height: 3px;
  width: var(--meter-share);
  border-radius: 0 2px 2px 0;
  background: var(--accent-light);
}

.meter__label {
  color: var(--muted);
  font-size: 12px;
}

.meter__value {
  font-size: 22px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.meter__note {
  color: var(--muted);
  font-size: 12px;
}

.recommendation {
  margin-top: 10px;
  font-size: 14px;
  font-weight: 600;
}

/* the table of words: two columns of equal width, a word is an element with the mark of its
   set; the two marks take two different colours of the palette — the words the page already
   has are "found", the words it lacks are "not found" (REQ-228) */
.table--words th,
.table--words td {
  width: 50%;
}

.word-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
}

.word {
  padding: 1px 8px;
  border: 1px solid var(--line);
  border-radius: 20px;
  font-size: 13px;
  overflow-wrap: anywhere;
}

[data-word="present"] {
  color: var(--good);
}

[data-word="missing"] {
  color: var(--critical);
}

/* a secondary action under a table of the section keeps off the table (REQ-223, REQ-229) */
[data-section] .cta {
  margin-top: 12px;
}

.audience,
.objection {
  max-width: 52ch;
  font-size: 14px;
}

/* --- notes -------------------------------------------------------------- */

.note {
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: var(--radius-small);
  background: var(--surface-soft);
  font-size: 13px;
}

.note--unavailable {
  background: var(--warning-soft);
}

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

.actions {
  margin-top: 24px;
  padding: 14px 0 24px;
  border-top: 1px solid var(--line);
}

.actions__age {
  color: var(--muted);
  font-size: 13px;
}

.actions__row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.actions__note {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

/* --- status and start pages --------------------------------------------- */

.page-center {
  display: flex;
  min-height: 100vh;
}

.center {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 24px 16px;
}

.card {
  width: min(620px, 100%);
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-card);
}

.card__kicker {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.card__title {
  margin-top: 6px;
  font-size: clamp(22px, 4vw, 30px);
  line-height: 1.15;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.card__state {
  margin-top: 10px;
  font-size: 17px;
  font-weight: 650;
}

.card__state--failed {
  color: var(--critical);
}

.card .prose {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.stage-progress {
  display: grid;
  gap: 4px;
  margin-top: 14px;
}

.stage-progress li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 10px;
  border-radius: var(--radius-small);
  background: var(--surface-soft);
  font-size: 13px;
}

.stage-progress li[data-status="running"] {
  background: var(--accent-soft);
}

.stage-progress li[data-status="ok"] {
  background: var(--good-soft);
}

.stage-progress__name {
  font-weight: 600;
}

.stage-progress__status {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.start-form {
  margin-top: 16px;
}

.start-form__label {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.start-form__row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.start-form__input {
  flex: 1 1 240px;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-small);
  background: var(--surface);
  color: var(--page-fg);
  font: inherit;
}

.start-form__error {
  margin-top: 6px;
  color: var(--critical);
  font-size: 13px;
}

/* --- wide screens ------------------------------------------------------- */

/* On a window of 1000 px and wider the first screen is two columns (REQ-269): the title, the
   verdict and the first line of the output stand in the first one, the tiles in the second,
   one under another and beside all three rows. Only the layout changes: the order of the
   elements in the markup is the same (REQ-214). Outside this block `.kpi-row` is a flex
   container, so it becomes a grid here for its one column to mean something. */
@media (min-width: 1000px) {
  [data-section="conclusion"] .wrap {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
    column-gap: 44px;
    align-items: start;
  }

  [data-section="conclusion"] .section__head,
  [data-section="conclusion"] .verdict,
  [data-section="conclusion"] .lede {
    grid-column: 1;
  }

  [data-section="conclusion"] .kpi-row {
    display: grid;
    grid-template-columns: 1fr;
    grid-column: 2;
    grid-row: 1 / span 3;
    margin-top: 0;
  }

  .verdict {
    max-width: 20ch;
  }
}

/* --- narrow screens ----------------------------------------------------- */

@media (max-width: 640px) {
  /* the phone values of the step between the cards of the sections and of the step between
     the groups inside a card (REQ-268) */
  :root {
    --gap-section: 30px;
    --gap-group: 18px;
  }

  .wrap {
    width: calc(100% - 24px);
  }

  [data-section] {
    width: calc(100% - 24px);
    padding: 22px 18px 20px;
    border-radius: 14px;
  }

  [data-section="conclusion"] {
    padding: 28px 18px 24px;
  }

  .table th,
  .table td {
    padding: 6px 8px;
  }

  /* a wide table keeps its width and scrolls inside its wrap */
  .table {
    min-width: 560px;
  }

  .cta {
    flex-basis: 100%;
  }

  /* the tiles of the first screen stand one under another (REQ-268); outside this block
     `.kpi-row` is a flex container, so it becomes a grid here */
  .kpi-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }

  /* the verdict loses its measure: 24 characters would leave an empty strip on the right */
  .verdict {
    max-width: none;
    font-size: 25px;
  }

  /* An opened hint is a strip at the bottom edge of the window, as wide as the window less its
     margins (REQ-289): the bubble is up to 259 px wide at this layout and the room from a sign
     to the edge of the window is often less, so a bubble hung on the sign does not fit in
     half of the cases. The strip is still out of the flow, as the bubble was (REQ-261): it
     moves nothing, and `fixed` takes the window for its box, so the clip of `body > *`
     (REQ-287) does not cut it. The head of a table and the wrap of a table name the text of a
     hint by rules above that are stronger than the bare class, so they are named here once
     more: this block stands later in the file and wins at an equal strength. */
  .hint__text,
  .table thead th .hint__text,
  .table-scroll .hint__text {
    position: fixed;
    top: auto;
    right: 12px;
    bottom: 12px;
    left: 12px;
    width: auto;
    max-width: none;
    translate: none;
  }

  /* the corner pointed at the sign, and the strip has no sign to point at */
  .hint__text::before,
  .table-scroll .hint__text::before {
    display: none;
  }
}

/* --- print -------------------------------------------------------------- */

@media print {
  /* The sheet is A4, painted to its four edges (REQ-291), and it carries a foot (REQ-294).
     `@page` takes its background from `--page-bg`: `var()` works there, and a page box
     paints a colour only, so a gradient or a picture would not print in it. There are no
     side margins; the top and the bottom ones are the room the foot needs. The three boxes
     of the bottom edge take the domain and the age of the data from `--report-domain` and
     `--report-age`, which the page lays on `html` (REQ-297): a box of `@page` reads custom
     properties from the root element and not from `body`. The number of the sheet is the
     counter of the paper — the one thing in the foot that is not a text of the report — and
     the colour of the three is `--muted` of the palette below. */
  @page {
    size: A4;
    margin: 18.5px 0 34.4px;
    background: var(--page-bg);

    @bottom-left {
      content: var(--report-domain);
      width: 22%;
      padding-top: 8px;
      padding-left: 18px;
      vertical-align: top;
      color: var(--muted);
      font: 600 10px Inter, sans-serif;
    }

    @bottom-center {
      content: var(--report-age);
      width: 56%;
      padding-top: 6px;
      vertical-align: top;
      text-align: center;
      color: var(--muted);
      font: 400 8.6px/1.35 Inter, sans-serif;
    }

    @bottom-right {
      content: counter(page) " / " counter(pages);
      width: 22%;
      padding-top: 8px;
      padding-right: 18px;
      vertical-align: top;
      text-align: right;
      color: var(--muted);
      font: 600 10px Inter, sans-serif;
    }
  }

  /* The sheet is light whatever the reader has chosen on the screen (REQ-206). Two
     mechanisms, and the second one is needed: `report_view` puts `data-theme="light"` on
     the `html` element when the page is asked with `print=1`, and printing from the
     browser has no such parameter at all — so the light palette is declared here to
     `:root` itself. The colour of the sheet, `--page-bg`, is not in this rule but in the
     next one (REQ-291): a value here would lose to `:root[data-theme="light"]` of the
     screen, which `print=1` switches on and which is the stronger selector. */
  :root {
    --page-fg: #1f2328;
    --surface: #ffffff;
    --surface-soft: #f0f2f5;
    --muted: #5c6670;
    --line: #dfe3e8;
    --line-strong: #c3cad2;
    --accent: #0f4c9a;
    --accent-bright: #1766c8;
    --accent-light: #86b6ef;
    --accent-soft: #e8f0fb;
    --good: #0b7a3b;
    --good-soft: #e7f4ec;
    --warning-soft: #fdf3dc;
    --critical: #a8301f;
    --critical-soft: #fbeceb;
    --radius: 10px;
    --radius-small: 6px;
    --shadow: 0 1px 2px rgba(15, 20, 28, 0.06);
    --shadow-card: 0 1px 3px rgba(15, 20, 28, 0.08);
    --nav-fg: #0f4c9a;
    --warning: #8a5a00;
    --test-fg: #0b5a2c;
    --test-bg: #d6ecdd;
    --row-even: rgba(255, 255, 255, 0.6);

    /* The type of the sheet (REQ-292). The sheet is laid out as a wide screen and scaled
       down by `zoom` below, so the title of the cover, of a section and of the page are set
       larger than on the screen. `--fs-kpi` is one number here and not a `clamp`: the
       number of a tile lies between 72 and 80 px of the layout on the sheet, and REQ-280
       speaks of the screen. `--fs-h3` is not declared: the 17 px of the mockup are the
       lower bound of its `clamp` already, and a second declaration would break that line
       (REQ-279). */
    --fs-h1: 38px;
    --fs-hero: 54px;
    --fs-h2: 30px;
    --fs-kpi: 76px;
  }

  /* The colour of the sheet (REQ-291, REQ-296), declared once, and under `:root[data-theme]`.
     The page with `print=1` carries `data-theme="light"`, and `:root[data-theme="light"]`
     of the screen is stronger than a bare `:root`: a value in the palette above would lose
     to the grey of the light theme. This rule is as strong as that one and stands below it,
     so it wins on the page with `print=1` and on the page printed from the browser, with
     the theme the reader chose or with none. `@page` and `body` both take the colour
     through `var(--page-bg)`. */
  :root,
  :root[data-theme] {
    --page-bg: #e9ecf5;
  }

  /* `print-color-adjust: exact` stands on `html` and not on `body` alone: only there it
     prints the fill of `@page` and of the canvas when the window of the browser has the
     background graphics turned off (REQ-291, REQ-296). `zoom` lays the sheet out as a wide
     screen and not as paper (REQ-292): the width of A4, 793.7 px, divided by it is about
     1 200 px of layout, while the sheet stays A4 and nothing is shrunk on the printer. */
  html {
    scroll-behavior: auto;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    zoom: 0.6618;
  }

  /* the background of the sheet is not a literal here: `body` takes it through
     `var(--page-bg)`, and the declaration of that property in this block makes the value
     the colour of the sheet (REQ-238, REQ-291) */
  body {
    font-size: var(--font-size-base);
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* the clouds of the screen background do not lie on the sheet (REQ-291) */
  body::before {
    display: none;
  }

  .wrap {
    width: calc(100% - 56px);
  }

  /* On paper the card of a section is a panel that stands almost to the foot of the
     printable area (REQ-293): 28 px at each side and a minimum height, both in the pixels
     of the layout, and `box-decoration-break: clone`, which gives every sheet of a
     section longer than one its own paddings and rounded corners instead of cutting the
     panel by a straight line. The height stays below the printable area, which is about
     1 600 px of the layout: a panel higher than that would take two sheets. The card keeps
     its surface and its border, because they are the depth of the reference and not
     decoration (REQ-212). */
  [data-section] {
    width: calc(100% - 56px);
    min-height: 1580px;
    margin-top: 0;
    padding: 24px 30px 14px;
    box-sizing: border-box;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
  }

  /* the last section is lower than the rest, so that the statement and the name of the
     performer, which stand after it, find room under its panel on the same sheet
     (REQ-295) */
  [data-section]:last-of-type {
    min-height: 1400px;
  }

  /* The first sheet is a cover (REQ-293): the panel of the conclusion fills the rest of the
     sheet under the head and holds its content in the middle of it. */
  [data-section="conclusion"] {
    display: grid;
    align-content: center;
    min-height: 1500px;
    padding: 60px 56px 56px;
  }

  /* Every section but the first starts a sheet of its own (REQ-282). The head of the page and
     the tail after the last section stand outside `[data-section]` and are not touched: the
     head stays on the sheet of the first section, the tail on the sheet of the last. The first
     section loses the break because the head stands over it, and a break there would leave
     the head alone on the first sheet. The block is one for both ways of printing, so the rule
     acts on the page with `print=1` and on the page printed from the browser alike. A section
     longer than a sheet goes on to the next one: the rule does not forbid a break inside. */
  [data-section] {
    break-before: page;
  }

  [data-section]:first-of-type {
    break-before: auto;
  }

  /* There is no hint on paper (REQ-235): neither the sign nor the text. The printed markup
     holds none, and this rule hides each of the four parts of a hint by its own name a second
     time, for a page printed from the browser. */
  .hint,
  .hint__sign,
  .hint__text,
  [data-block="hint"] {
    display: none;
  }

  /* A link is not an interface by itself on paper (REQ-275): the address of the analyzed page
     is a link on the screen and a line of the report on paper, and it must stay on the sheet
     printed from the browser, which has no parameter and so keeps every `<a>` of the screen
     markup. This rule takes off what makes a link look like one, its colour and its underline,
     and hides no link as such; the links that are interface are hidden by their own names in
     the rule below. The price is named and accepted: the PDF printed from the browser keeps
     the annotation of this link, and the PDF made by the parameter has none. */
  a {
    color: inherit;
    text-decoration: none;
  }

  /* There is nothing to press and nothing to follow on paper (REQ-237): no button, no
     navigation, no link to the PDF, no link inside a hint, no strip of a rerun, no mark of the
     free test. The card of an action and the notes under the buttons of the footer go with
     them, and so does the address of an action: paper has no address and no contact (REQ-197).
     The printed markup does not hold these parts either; this rule is the second layer. */
  [data-cta],
  [data-action],
  nav,
  nav a,
  .head__nav,
  .head__pdf,
  .head__tools,
  .hint a,
  [data-block="hint"] a,
  .banner,
  .cta,
  .actions__row,
  .actions__note,
  .test-mark,
  [data-block="keyword-test"] {
    display: none;
  }

  /* The age of the data moved from the footer of the page into the foot of every sheet
     (REQ-294), so the footer is not printed; its element stays in the markup of both views
     (REQ-148). */
  footer.actions {
    display: none;
  }

  /* the row of a phrase of the free test is shaded on the screen and is not on paper */
  .table tr.is-test {
    background: transparent;
  }

  /* No word about the free test on paper (decision 80 of the human): the lead of the first
     part of the phrase list ends with "the marked ones go to the free test". The printed
     markup does not hold it; this rule is the second layer, for a page printed from the
     browser without the parameter. The first part only: the lead of the second part stays,
     as on the screen. */
  [data-block="keyword-part-ranked"] .keyword-part__lead {
    display: none;
  }

  /* The printed markup holds neither the line about the company nor a fold (REQ-278, REQ-283):
     `report_view` draws the line on the screen only, and the macro of the fold prints nothing
     with the parameter. A page printed from the browser has no parameter, so this rule is the
     second layer: the line, every fold and every `details` leave the sheet whole, the title
     and the body with them, and nothing here opens a closed one (REQ-288). */
  .self-proof,
  .fold,
  details {
    display: none;
  }

  /* second layer of REQ-284 for the Ctrl+P path (REQ-288); the limit 15 stands in
     report_view._PRINT_WORD_LIMIT too */
  .word-list > .word:nth-child(n+16) {
    display: none;
  }

  /* The head is one line on the sheet (REQ-293): the domain at the left, the date at the
     right, no line under it. The glass of the screen is off — a translucent surface with a
     blur would lay a lighter band over the colour of the sheet, and REQ-291 asks for one
     colour up to every edge. */
  .head {
    padding: 0 0 18px;
    border-bottom: 0;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .head .wrap {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
  }

  /* The first screen stands in two columns on the sheet (REQ-292), as it does on a window
     of 1000 px and wider (REQ-269). The query of that block does not fire in print — its
     width is the width of the paper, not of the layout — so its rules are repeated here on
     purpose: the same layout once more and not a second layout of the page. */
  [data-section="conclusion"] .wrap {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
    column-gap: 60px;
    align-items: center;
  }

  [data-section="conclusion"] .section__head,
  [data-section="conclusion"] .verdict,
  [data-section="conclusion"] .lede {
    grid-column: 1;
  }

  [data-section="conclusion"] .kpi-row {
    display: grid;
    grid-template-columns: 1fr;
    grid-column: 2;
    grid-row: 1 / span 3;
    gap: 20px;
    margin-top: 0;
  }

  [data-section="conclusion"] .kpi {
    padding: 26px 30px 28px;
  }

  [data-section="conclusion"] .lede {
    margin-top: 22px;
    font-size: 21px;
  }

  .verdict {
    max-width: 17ch;
  }

  .kpi,
  .competitor,
  .block,
  .stage,
  .fold,
  .card,
  .table-scroll {
    box-shadow: none;
  }

  .section__head,
  .fold__title,
  .relevance__title {
    break-after: avoid;
  }

  /* a card of a block, a stage of the roadmap, the block of the match of the home page and a
     row of a table are not torn between two sheets (REQ-290) */
  .verdict,
  .lede,
  .kpi,
  .competitor,
  .block,
  .stage,
  .fold,
  .note,
  .statement,
  .meter,
  .relevance,
  tr {
    break-inside: avoid;
  }

  .table-scroll {
    overflow: visible;
  }

  /* the head of a table is repeated on every sheet the table takes (REQ-290) */
  thead {
    display: table-header-group;
  }

  /* the head of a table is tinted on the sheet (REQ-293): the soft accent under the accent
     colour, in place of the surface and the muted grey of the screen */
  .table thead th {
    background: var(--accent-soft);
    color: var(--accent);
  }

  /* Each part of the phrase list starts a sheet of its own (REQ-290). The air of 44 px between
     the parts is a rule of the screen (REQ-263) and stays outside this block. A part longer
     than a sheet goes on without its sub-heading: print gives no running title. */
  .keyword-part + .keyword-part {
    break-before: page;
  }

  /* the tiles, the stages and the metrics of the roadmap stand closer on the sheet than on
     the screen: the look of the mockup of the sheet (REQ-293) */
  .block {
    padding: 10px 14px;
  }

  .stage {
    padding-bottom: 14px;
  }

  .stage__checkpoint {
    margin-top: 8px;
    padding: 8px 12px;
  }

  .metric {
    padding-top: 6px;
  }

  .stage__number {
    margin-bottom: 6px;
  }

  /* The statement of the product and the name of the performer are the tail of the report
     (REQ-295): the statement has no rule above it and little air, and neither of the two
     is torn from the last block of the last section — if they do not fit, they go to the
     next sheet together with that block. */
  .statement {
    margin-top: 8px;
    padding-top: 0;
    border-top: 0;
    font-size: 14px;
  }

  .statement,
  .author {
    break-before: avoid;
  }

  /* a fold reaches no sheet any more (REQ-283), so nothing takes this padding: the rule is what
     is left of the fold printed open, which the withdrawn REQ-236 asked for */
  .fold__body {
    padding-bottom: 8pt;
  }
}
