/*
 * Watermerken — design tokens and components.
 *
 * Light is the default. Dark applies when the visitor's OS asks for it, or when
 * they pick it explicitly (the toggle sets data-theme on <html>). An explicit
 * choice always beats the OS preference, in both directions.
 *
 * Every colour is declared in the :root blocks below, so a token always has a
 * value; the theme blocks only ever replace one.
 *
 * The palette is the Stijlgids page of the canvas "Nieuwe look voorstellen"
 * (S-kleuren): white, ink, water and deep water. Colour means something here:
 * the water blue is the drop, a link's underline and where you are, and
 * nothing else is coloured.
 *
 * --muted is the lightest grey any text may be: 4.5:1 (WCAG AA for text under
 * 24px) against every surface text stands on, the raised one in dark
 * included. --faint-2 is lighter still and so is never text, nor an icon that
 * is a button's only face: it is the dashed drop of a word with too few votes,
 * a separator, a disabled button.
 *
 */

:root {
  --ground: #FFFFFF;
  --ink: #111111;
  --muted: #5E5E5E;
  /* The one colour with a meaning: the drop, a link's underline, where you
     are. --on-water is what stands on it. As text it keeps 4.5:1 on the page
     and on --wash, not on --water-light (4.46:1), so it is never set as text
     on a panel of that. */
  --water: #1667D9;
  --on-water: #FFFFFF;
  /* The vote panel, Verder lezen, the preview in the drawer. */
  --water-light: #E2EDFB;
  /* The generic share of the vote bar once it shows the split. */
  --vote-fill: #B9D3F6;
  /* The foot of every page and the link previews, white on it. The drop on
     it is lighter, and so is its second text. Not redrawn in dark beyond the
     ground itself: deep water stays deep. */
  --deep: #123A73;
  --deep-drop: #7FB2FF;
  --deep-text: #C9D8EE;
  --deep-ink: #FFFFFF;
  --line: #E3E6EA;
  /* The edge of what is typed into or ticked: a text field, a text area, a
     select, a checkbox's box, a radio's dot. An empty field has nothing else
     to be seen by, so its edge keeps 3:1 (WCAG AA for a control's boundary)
     against every surface in its palette, the raised ones included — which is
     why it is not redrawn over the scrim. A button or a card says what it is
     in words and keeps the lighter --rule. */
  --input-line: #827E78;
  --faint-2: #8A919C;
  /* The short rule on the 404, and the edge of a button or a card. */
  --rule: #C9CED6;
  --danger: #B3261E;
  /* A neutral ground a step off the page: /admin's rows and panels, a row
     under the pointer. */
  --wash: #F3F4F6;
  /* The waterline over de lijst's tiles: lighter than the vote panel, so the
     words over it keep their contrast, and its surface line. */
  --hover-water: #EDF4FD;
  --hover-wave: #8DB6EE;

  /* The page's palette one rung up, for what lies over the scrim — the menu
     and every dialog, which redraw the tokens above with these (see the rule
     after the contrast blocks), so whatever stands inside follows without a
     rule of its own. In light they are the page's own: a white sheet over a
     dimmed page stands out already. In dark a shadow cannot darken a page
     that is nearly black, so what lies on top has to be lighter instead, and
     these are. */
  --raised-ground: var(--ground);
  --raised-wash: var(--wash);
  --raised-line: var(--line);
  --raised-rule: var(--rule);

  --scrim: oklch(0.2 0.02 255 / 0.42);
  /* A deeper scrim, for /submit's shadows. */
  --scrim-strong: oklch(0.2 0.02 255 / 0.6);

  /* What the browser paints itself: the date picker's icon and its dropdown,
     the scrollbars, a select's own list. Without it they stay light on a dark
     page. */
  color-scheme: light;
}

/* A chosen row on /admin: the page's own ground in light, and lighter than
   the page in dark (the dark blocks). Declared on :root alone, so a block
   that redraws --ground carries it with it. */
:root {
  --row-chosen: var(--ground);
}

/*
 * The tokens mixed from the ones above. A mix is worked out where it is
 * declared, so declared on :root alone it would keep the page's --ground
 * inside a sheet or a dialog that redraws it; declared on those as well, it is
 * worked out again from theirs. Where nothing is redrawn it comes out the same.
 */
:root,
.menu__sheet,
.dialog {
  /* The vote bar once it has been answered but has too few votes to show a
     split: the bar's own surface with a trace of the accent stirred into it.
     Mixed from two themed tokens rather than given a value per palette, so it
     follows both on its own — a dark accent on a light surface settles, a light
     accent on a dark one lifts. */
  --tint: color-mix(in oklab, var(--water) 16%, var(--ground));

  /* Its red twin: an import cell that is emptied or wrong. Mixed the same
     way, so it follows both palettes. */
  --danger-tint: color-mix(in oklab, var(--danger) 12%, var(--ground));

  /* The maintainer's own note in /admin's dialog (.form-field--private): a
     warm box, so it never reads as part of what the register shows. A fixed
     amber stirred into themed tokens, the way --tint is mixed, so it follows
     both palettes. */
  --private: color-mix(in oklab, oklch(0.8 0.12 80) 20%, var(--ground));
  --private-line: color-mix(in oklab, oklch(0.72 0.12 75) 45%, var(--rule));
  /* Its label, and the icon and language pill of the warm notice on /admin.
     Half amber, half ink: stirred into --muted it was 4.1:1 on the box in
     light and 2.8:1 in dark, under the 4.5:1 its small capitals need; into the
     ink it is darker in light and lighter in dark, and clears it in both. */
  --private-ink: color-mix(in oklab, oklch(0.6 0.12 65) 50%, var(--ink));
  /* The edge of the note's own field. The warm box is lighter than every
     surface --input-line is measured against in dark, so there the plain edge
     fell to 2.3:1; stirred a quarter towards the ink it is lighter in dark and
     darker in light, and keeps 3:1 against the box in both. */
  --private-input-line: color-mix(in oklab, var(--input-line) 75%, var(--ink));

  /* The area under the dashboard's chart line. The same trick as --tint, at
     the 13% the design uses, and its own token rather than a share of --tint's:
     that one is the vote bar's waiting state and the two should be free to
     move apart. */
  --chart-fill: color-mix(in oklab, var(--water) 13%, var(--ground));

  /* Under the chosen option of a switch (.switch__chip): the switch's own
     surface with a tenth of the ink stirred in, so it settles a step darker
     in light and lifts a step in dark — and in the menu's sheet, whose
     surface is a rung up, a rung up with it. */
  --chip: color-mix(in oklab, var(--ink) 10%, var(--ground));

  /* Deep water a step lighter, and its hairline: the foot's chosen switch
     option and its lines. */
  --deep-wash: color-mix(in oklab, var(--deep-ink) 14%, var(--deep));
  /* The foot's band of other lists (.elsewhere--band): deep water with a
     little of its drop in it, a lighter blue rather than a greyer one. */
  --deep-band: color-mix(in srgb, var(--deep-drop) 15%, var(--deep));
  --deep-line: color-mix(in oklab, var(--deep-ink) 24%, var(--deep));
}

:root {
  /* Not themed: each is cast against the surface it lifts off, and the design
     uses one value for either palette. Three, because a dialog, a sheet and a
     card the size of a paragraph do not throw the same shadow. */
  --shadow: 0 24px 60px -20px oklch(0.2 0.02 255 / 0.42);
  --shadow-sheet: 0 -20px 50px -24px oklch(0.2 0.02 255 / 0.5);
  --shadow-pop: 0 16px 36px -20px oklch(0.2 0.02 255 / 0.5);

  /* The fourth, and the shallowest: a bar lifting a few pixels off the page it
     is holding still, rather than a box standing over it. */
  --shadow-bar: 0 16px 24px -22px oklch(0.2 0.02 255 / 0.9);

  /* The fifth: a button the size of a fingertip, standing over the text it
     sits on — the review strip's offers. */
  --shadow-button: 0 6px 16px -8px oklch(0.2 0.02 255 / 0.45);

  /* The sixth and seventh, for the import's table: the edge its pinned
     columns cast over what scrolls under them, and the shade under its
     headings, a gradient's start rather than a shadow, since a shadow per
     cell stops short of every column's sides. */
  --shadow-edge: 8px 0 10px -8px oklch(0.2 0.02 255 / 0.35);
  --shade-under: oklch(0.2 0.02 255 / 0.12);

  /* The paper and the ink the theme switch's icons are drawn in. Not themed:
     an icon shows how a page will look, and a dark page is ink whichever
     theme is showing the icon. The light palette's own --ground and --ink. */
  --mode-paper: #FFFFFF;
  --mode-ink: #111111;

  /* Not a shadow at all: the ground, carried 12px past both sides of what
     stays pinned on /admin. A row there is lit on a band reaching 12px past
     the columns (.row--mark::before, .row--queue::before), and without this
     the ends of that band showed beside the band and the heading row as the
     row passed under them. Change one 12px and change the other. */
  --ground-reach: -12px 0 0 var(--ground), 12px 0 0 var(--ground);

  /* What /admin's band occupies: exact, because .row--head sticks directly
     under it and a gap or an overlap would both show — a tab strip is one
     line of pills at a fixed height inside a fixed padding, with overflow-x:
     auto making sure it can never wrap. */
  --admin-bar: 68px;

  /* Bodoni Moda carries the brands, wherever one stands, and the headings.
     Albert Sans carries everything else. */
  --display: "Bodoni Moda", Didot, "Bodoni 72", Georgia, serif;
  --body: "Albert Sans", ui-sans-serif, system-ui, "Segoe UI", sans-serif;

  /* How a sheet arrives and leaves. Named here because two different things
     use it — the menu's sheet, a <details> that opens in place, and the
     <dialog> behind /submit, /admin and a footnote, which is toggled in the
     top layer. The mechanisms cannot be shared; the
     distance and the timing are, so the two move alike. */
  --sheet-ease: cubic-bezier(0.32, 0.72, 0, 1);
  --sheet-rise: 0.26s;
  --sheet-fade: 0.24s;

  /* How a tile of de lijst fills with water while a mouse or the focus is on
     it, and drains again: slowly up, quickly down, so nothing trails behind
     the mouse. Every transition of the waterline reads these; without them
     each of those transitions is invalid and the water jumps. */
  --rise: 1000ms;
  --rise-ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --drain: 400ms;
  --drain-ease: cubic-bezier(0.45, 0, 0.55, 1);

  /* How the vote panel's words change once an answer comes in (vote.js;
     prototype "Stemvlak in beweging", 3 · na elkaar): the old ones fade out
     while the answer is on its way, the new ones come in a row at a time,
     each --vote-step after the one above it. vote.js reads --vote-leave, so
     the answer waits for the old words to go: write it in ms. */
  --vote-leave: 140ms;
  --vote-arrive: 280ms;
  --vote-step: 110ms;

  /* The width of every focus ring, so "Increase contrast" can thicken them all
     in one place (see the contrast blocks after the dark ones). */
  --focus-ring: 2px;

  --radius: 3px;
  --radius-lg: 5px;
  --page: 1120px;
  --gutter: 18px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --hover-water: #142439;
    --hover-wave: #3F6FB5;
    --ground: #0E1116;
    --ink: #F0F2F5;
    --muted: #A0A7B2;
    --water: #5B9DFF;
    --on-water: #0E1116;
    --water-light: #16263D;
    --vote-fill: #1E3A63;
    --deep: #0A1F40;
    --line: #262C35;
    --input-line: #6E7682;
    --faint-2: #6E7682;
    --rule: #3A414C;
    --danger: #FF8A80;
    --wash: #161B22;
    --row-chosen: #1E242D;
    --raised-ground: #161B22;
    --raised-wash: #1E242D;
    --raised-line: #2E3540;
    --raised-rule: #46505C;
    --scrim: oklch(0.07 0.01 255 / 0.76);
    --scrim-strong: oklch(0.16 0.02 255 / 0.8);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --hover-water: #142439;
  --hover-wave: #3F6FB5;
  --ground: #0E1116;
  --ink: #F0F2F5;
  --muted: #A0A7B2;
  --water: #5B9DFF;
  --on-water: #0E1116;
  --water-light: #16263D;
  --vote-fill: #1E3A63;
  --deep: #0A1F40;
  --line: #262C35;
  --input-line: #6E7682;
  --faint-2: #6E7682;
  --rule: #3A414C;
  --danger: #FF8A80;
  --wash: #161B22;
  --row-chosen: #1E242D;
  --raised-ground: #161B22;
  --raised-wash: #1E242D;
  --raised-line: #2E3540;
  --raised-rule: #46505C;
  --scrim: oklch(0.07 0.01 255 / 0.76);
  --scrim-strong: oklch(0.16 0.02 255 / 0.8);
  color-scheme: dark;
}

/*
 * "Increase contrast" (macOS, iOS: prefers-contrast: more), an accessibility
 * setting the visitor turns on themselves: the same palette with every grey a
 * rung nearer the ink. The text becomes black (white in dark), --muted and
 * --faint-2 take the next shade along, and the rules, button edges and the
 * vote bar's edge reach 3:1, which in the plain palette only a field's edge
 * does. The focus rings go from 2px to 3px. Surfaces stay as they are, so the
 * raised ones still stand off the page.
 *
 * The light block names only tokens the dark blocks name too, so in dark the
 * dark blocks (more specific) win it everywhere, as they win the plain light
 * one; --focus-ring is no colour and holds in both. Dark is written twice, as
 * above: for the system's dark and for an explicit choice of it.
 */
@media (prefers-contrast: more) {
  :root {
    --ink: #000000;
    --muted: #444444;
    --line: #7A818C;
    --input-line: #5E5A55;
    --faint-2: #6B7280;
    --rule: #827E78;
    --focus-ring: 3px;
  }
}

@media (prefers-contrast: more) and (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #FFFFFF;
    --muted: #C3C9D2;
    --line: #6E7682;
    --input-line: #8C94A0;
    --faint-2: #9AA1AC;
    --rule: #7E858F;
    --raised-line: #6E7682;
    --raised-rule: #7E858F;
  }
}

@media (prefers-contrast: more) {
  :root[data-theme="dark"] {
    --ink: #FFFFFF;
    --muted: #C3C9D2;
    --line: #6E7682;
    --input-line: #8C94A0;
    --faint-2: #9AA1AC;
    --rule: #7E858F;
    --raised-line: #6E7682;
    --raised-rule: #7E858F;
  }
}

/*
 * What lies over the scrim takes the palette one rung up (the --raised-*
 * tokens): the menu's sheet and every dialog at every width — /submit's
 * drawer among them. Redrawn here rather than at each line, foot and grip
 * inside them, so nothing added to one later can forget. A token declared on
 * the element is the one its own background and border read too, so the
 * edge follows as well. The mixes follow by being declared on the same two
 * (see the rule after :root).
 */
.menu__sheet,
.dialog {
  --ground: var(--raised-ground);
  --wash: var(--raised-wash);
  --line: var(--raised-line);
  --rule: var(--raised-rule);
}

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

/*
 * The gutter stays reserved whether or not the page happens to scroll, so
 * nothing shifts sideways when a dialog locks the page or a short list stops
 * needing a scrollbar. Reserving it only while locked would fix the long page
 * and break the short one, which would then shift the other way. A no-op where
 * the browser draws its scrollbars over the content.
 */
html {
  scrollbar-gutter: stable;
}

/* No -webkit-font-smoothing: antialiased. On a Mac it thins every stroke,
   and Bodoni's hairlines all but vanish; the design is drawn without it. */
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
}

a {
  color: var(--water);
  text-underline-offset: 3px;
}

button,
a,
[role="button"] {
  -webkit-tap-highlight-color: transparent;
}

::selection {
  background: var(--water);
  color: var(--on-water);
}

:focus-visible {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 3px;
  border-radius: var(--radius);
}

input,
textarea,
button {
  font: inherit;
  color: inherit;
}

input,
textarea,
select {
  font-family: inherit;
  color: var(--ink);
}

input::placeholder,
textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}

input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

/*
 * Shown only when JavaScript ran, or only when it did not; the head script adds
 * .js to <html>.
 *
 * Both are written as ":root(:not).js x" rather than the shorter ".js x" so
 * they outrank a component that sets its own display. A plain ".js-only" loses
 * to ".btn" on source order alone, which left "onthul alles" — a button that
 * does nothing without script — sitting in the header of a page that had none.
 *
 * These only ever hide. An element that is shown keeps whatever display its own
 * rules give it, so nothing here has to guess at "inline-flex".
 */
:root:not(.js) .js-only {
  display: none;
}

:root.js .no-js-only {
  display: none;
}

/* The hidden attribute always hides. The browser's own display: none for it
   loses to any class that sets a display, on source order alone, and fifteen
   rules once said it again one by one. Nothing here shows a [hidden] element
   on purpose. */
[hidden] {
  display: none !important;
}

/* Hidden from the eye, not from a screen reader or the keyboard: the
   utility, and the inputs whose label is what gets clicked and drawn — a
   form tab's radio, the import's segments and tabs, /submit's box and brand
   question. Clipped rather than faded out: an element at opacity 0 is a
   control some tooling stops reporting as one. */
.visually-hidden,
.form-tab__radio,
.import-segment__option input,
.import-tabs__tab input,
.credit__option input[type="checkbox"],
.quiz__input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- layout ---------- */

/* No room under the page's content: every page ends in its foot, which
   brings its own. */
.page {
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 32px;
}

/* On a phone the page runs edge to edge, and each part keeps the gutter
   itself — a header, a text's column, a list's rows — so a row can be drawn
   the screen's full width. */
@media (max-width: 743px) {
  .page {
    padding: 0;
  }
}

main {
  display: block;
}

/*
 * Only once there is something under it to lift off — and only under it: the
 * shadow of /admin's band, clipped at the band's two sides, so it stops where
 * the band stops. The clip is on a layer of its own and not on the band: a
 * clip-path clips everything inside the box, focus rings and the menu
 * included. z-index -1 keeps the layer under the band's content.
 */
.admin-bar.is-lifted::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  box-shadow: var(--shadow-bar);
  clip-path: inset(0 0 -200px 0);
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  padding: 40px 0 28px;
  border-bottom: 1px solid var(--line);
}

.site-header__brand {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.site-header__aside {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

/*
 * The navigation bar of every public page (_NavBar). Wide: the wordmark small
 * on the left, then the navigation and the switches on the right. The page
 * you are on is underlined in ink; the rest are underlined in the field line
 * when pointed at, so nothing shifts.
 */
/*
 * The header of every public page (_NavBar; canvas "Nieuwe look
 * voorstellen", B-start): 88px, the logo, the navigation and the black
 * button, and a hairline under it. The ground and the line run to both edges
 * of the window while what is in it keeps to the page's column: a border
 * image pushed out sideways, as the offer strip's, which paints outside the
 * box without making the page any wider.
 */
.site-header--nav {
  flex-wrap: nowrap;
  align-items: center;
  gap: 28px;
  min-height: 88px;
  padding: 0;
  border-bottom: 0;
  border-image:
    linear-gradient(
      var(--ground) calc(100% - 1px),
      var(--line) calc(100% - 1px)
    ) fill 0 // 0 100vmax;
}

.nav-mark {
  margin-right: auto;
  font-size: 29px;
  line-height: 1;
  color: var(--ink);
  text-decoration: none;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

/* Underlined in water where you are, in the rule's grey where pointed at, so
   nothing shifts. */
.site-nav a {
  padding: 4px 0 3px;
  border-bottom: 2px solid transparent;
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
}

.site-nav a:hover {
  border-bottom-color: var(--rule);
}

.site-nav a[aria-current="page"] {
  border-bottom-color: var(--water);
}

/* "Woord aandragen": the black button, on every page. Square, as every button
   of the new look but the switches. */
.nav-submit {
  display: inline-flex;
  flex: none;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--ink);
  background: var(--ink);
  font-size: 15px;
  font-weight: 500;
  color: var(--ground);
  text-decoration: none;
  white-space: nowrap;
}

.nav-submit:hover {
  border-color: var(--muted);
  background: var(--muted);
}

/* A page's own name under the navigation, as its h1: de lijst's and
   /submit's. /privacy and a page from /admin/pages have their own. */
.page-name {
  margin: 34px 0 0;
  font-family: var(--display);
  font-size: 44px;
  font-weight: 400;
  line-height: 1;
  color: var(--ink);
  text-wrap: balance;
}

/*
 * The header that is its own bar, on /privacy and /about. Neither page has a
 * list to steer, so what stays is the header itself — the name, the way back,
 * and the switches or the burger (design canvas "Watermerken", pvHeadStyle and
 * uxHeadStyle). At every width: on a phone it is what keeps the burger within
 * reach.
 *
 * z-index 8, as /admin's band: above the content that scrolls under it and
 * below a non-modal dialog (10). It makes the header a stacking context, and
 * that puts the menu's scrim and sheet, 75 and 80, inside it — harmless,
 * since nothing outside the header stands higher than 8.
 */
.site-header--stays {
  position: sticky;
  top: 0;
  z-index: 8;
  background: var(--ground);
}

/* A link focused from below is scrolled to the top edge, which is now under
   the header. A floor rather than a measurement: a little generous costs
   nothing, short hides the link. */
html:has(.site-header--stays) {
  scroll-padding-top: calc(160px + var(--offer-h));
}

/*
 * The strip that offers another language's list (_Offer): under the header.
 * Design canvas "De Nederlandse lijst voorstellen", 1b. It takes room rather than lying over the page; the script that picks it
 * runs before anything under it is drawn, so nothing moves when it appears.
 * It is not part of the header, but where the header stays it stays with it,
 * right under it, and the page scrolls under both (below); where the header
 * scrolls away, it goes with it.
 *
 * The tint runs to both edges of the window while what is in it keeps to the
 * page's column. It is a border image pushed out sideways: an outset paints
 * outside the box without making the page any wider, which a negative margin
 * of 50vw would, 100vw counting the scrollbar's gutter. The bottom pixel is
 * the strip's rule, drawn the same way so it runs edge to edge too.
 */
.offer {
  position: relative;
  border-image:
    linear-gradient(
      var(--water-light) calc(100% - 1px),
      var(--line) calc(100% - 1px)
    ) fill 0 // 0 100vmax;
}

/*
 * Under a header that stays (/privacy, the start page, a page from
 * /admin/pages), the strip stays too: sticky at the header's height, which
 * site.js measures (--nav-h), and under it, 7 under 8, so the header's point
 * reaches into it. Its rule stands for the header's line meanwhile, and the
 * shadow a lifted header casts falls from the strip instead. De lijst's
 * header stays only beside its card, which does the same there (see "the
 * card, wide").
 */
.site-header--stays + .offers {
  position: sticky;
  top: var(--nav-h);
  z-index: 7;
}





.offer__inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 0 13px;
}

.offer__inner > .flag {
  flex: none;
}

.offer__text {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--ink);
  text-wrap: pretty;
}

.offer__question {
  font-weight: 600;
  color: var(--ink);
}

.offer__brand {
  font-family: var(--display);
  font-size: 1.1em;
}

.offer__acts {
  display: flex;
  flex: none;
  align-items: center;
  gap: 20px;
  margin: 0;
}

.offer__stay {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 13px;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--faint-2);
  text-underline-offset: 3px;
  white-space: nowrap;
  cursor: pointer;
}

.offer__stay:hover {
  color: var(--ink);
  text-decoration-color: var(--ink);
}

/* 743px, the breakpoint site.css, site.js and stack.js share. The sentence
   over the two answers, and the point under the burger. */
@media (max-width: 743px) {
  .offer__inner {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 12px;
    padding: 14px var(--gutter) 16px;
  }

  .offer__inner > .flag {
    margin-top: 3px;
  }

  .offer__text {
    flex: 1 1 0;
  }

  .offer__acts {
    flex: 1 0 100%;
    gap: 18px;
  }

  .offer__acts .btn {
    flex: 1;
    height: 44px;
  }
}

/*
 * The foot of every page (_Footer; canvas "Nieuwe look voorstellen", B-start
 * and W-404, Uitwerking · de voet and · ook verwaterd in, B): deep water from
 * the column out to both edges of the window and down past the page's end.
 * At its top the other languages' lists in a band of lighter water
 * (.elsewhere--band); then the logo with its line and the white way back up;
 * under a rule the pages, side by side, and wide the theme's bubbles. The
 * deep ground is a border image pushed out, as the header's, which paints
 * outside the box without making the page any wider or longer.
 *
 * Inside it the page's palette is redrawn for deep water, the way a dialog
 * redraws it one rung up, so the logo's drop, the links and the band follow
 * without rules of their own.
 */
.site-foot {
  --ground: var(--deep);
  --wash: var(--deep-wash);
  --ink: var(--deep-ink);
  --muted: var(--deep-text);
  --line: var(--deep-line);
  --rule: var(--deep-text);
  --water: var(--deep-drop);
  --on-water: var(--deep);
  --chip: var(--deep-wash);
  display: flex;
  flex-direction: column;
  margin-top: 96px;
  padding: 0 0 52px;
  color: var(--ink);
  border-image: linear-gradient(var(--deep) 0 0) fill 0 // 0 100vmax 100vmax;
}

.site-foot__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 20px;
  padding: 44px 0 32px;
}

.site-foot__mark {
  font-size: 26px;
  line-height: 1;
  text-decoration: none;
}

.site-foot__line {
  max-width: 34em;
  margin: 12px 0 0;
  font-size: 15px;
  color: var(--muted);
}

/*
 * Back to the top: the white round button of deep water (canvas Uitwerking ·
 * terug naar boven, B, and · de voet). White in both palettes, its arrow in
 * the deep water it stands in. A link to #top, which a browser takes to the
 * top without script; site.js glides there instead.
 */
.site-foot__up {
  display: grid;
  flex: none;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--deep-ink);
  color: var(--deep);
}

.site-foot__up svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.site-foot__up:focus-visible {
  border-radius: 50%;
}

/* The theme's bubbles rise to where it stands: while they are up it steps
   aside, as the other circle did in the prototype. */
.site-foot__up {
  transition: opacity 0.2s ease;
}

.site-foot:has(.bubbles.is-open) .site-foot__up {
  opacity: 0;
  pointer-events: none;
}

.site-foot__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.site-foot__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 32px;
  font-size: 16px;
}

.site-foot__nav a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.site-foot__nav [aria-current] {
  color: var(--muted);
}

/*
 * "Ook verwaterd in" (_Elsewhere): the other languages' lists, each a submit
 * button set as a link. In the foot a band of its own in a lighter water
 * (--deep-band), running to both edges as the foot does, a
 * border image pushed out sideways; each list with its flag, its name and
 * under it how many words it has, two of them in Bodoni. In the menu's foot
 * the names alone.
 */
.elsewhere {
  margin: 0;
}

.elsewhere__label {
  margin: 0;
}

.elsewhere__lists {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
}

.elsewhere__list {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  text-align: start;
  cursor: pointer;
}

.elsewhere__text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.elsewhere__name {
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

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

.elsewhere__brand {
  font-family: var(--display);
  font-style: normal;
  font-size: 1.08em;
}

.elsewhere--band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 44px;
  padding: 16px 0 18px;
  border-image: linear-gradient(var(--deep-band) 0 0) fill 0 // 0 100vmax;
}

.elsewhere--band .elsewhere__label {
  font-size: 14px;
  font-weight: 600;
}

.elsewhere--band .elsewhere__lists {
  gap: 12px 44px;
}

.elsewhere--band .elsewhere__name {
  font-size: 15px;
}

/* In the menu's foot: a line as the theme's is, its label over the names. */
.elsewhere--menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 0;
}

.elsewhere--menu .elsewhere__label {
  font-size: 13px;
  line-height: 1.3;
  color: var(--muted);
}

.elsewhere--menu .elsewhere__lists {
  gap: 6px 22px;
  font-size: 16px;
  line-height: 1.3;
}

.elsewhere--menu + .menu__pref {
  border-top: 1px solid var(--line);
}

/* The list the strip at the top offers (_Offer), in the accent. */
.elsewhere__list.is-offered .elsewhere__name {
  color: var(--water);
}

/*
 * The theme in the wide foot (_ThemeBubbles; prototype "Rondje uitklappen",
 * B): a white circle with the mode in use, out of which the other two rise
 * as bubbles, each with its word to its left, and the one picked sinks back
 * in. site.js opens it (.is-open), numbers the two that rise (--k), and lets
 * the picked one land (.is-landing, the other .is-popping) before the theme
 * changes; .is-settling puts everything back without a movement.
 *
 * The circle and the bubbles are paper in both palettes, and the icons'
 * edges are drawn in ink on them, where the foot's own grey would vanish.
 */
.bubbles {
  position: relative;
  flex: none;
  width: 38px;
  height: 38px;
}

.bubbles__face,
.bubbles__bub {
  --muted: var(--mode-ink);
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--mode-paper);
}

.bubbles__face {
  position: relative;
  z-index: 1;
  padding: 0;
  border: 0;
  cursor: pointer;
}

.bubbles__face:focus-visible,
.bubbles__option:focus-visible {
  border-radius: 50%;
}

/* What is in use, read off data-theme-mode as the switch reads it. */
.bubbles__now {
  display: none;
}

:root[data-theme-mode="light"] .bubbles__now[data-mode="light"],
:root[data-theme-mode="dark"] .bubbles__now[data-mode="dark"],
:root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) .bubbles__now[data-mode="system"] {
  display: grid;
}

/* The ring a landing leaves, once. */
.bubbles__face::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 2px solid var(--mode-paper);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
}

.bubbles__face.is-rippled::after {
  animation: bubbles-ripple 0.7s ease-out;
}

@keyframes bubbles-ripple {
  from { opacity: 0.9; transform: scale(1); }
  to { opacity: 0; transform: scale(2.1); }
}

.bubbles__options {
  position: absolute;
  inset: 0;
}

.bubbles__option {
  position: absolute;
  right: 0;
  bottom: 0;
  display: block;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(0) scale(0.3);
  transition:
    transform 0.5s cubic-bezier(0.3, 1.5, 0.55, 1),
    opacity 0.2s ease,
    visibility 0s linear 0.5s;
  transition-delay: calc(var(--k, 0) * 0.09s), calc(var(--k, 0) * 0.09s), 0.5s;
}

/* The mode in use is the circle, and does not rise. */
:root[data-theme-mode="light"] .bubbles__option[data-theme-pick="light"],
:root[data-theme-mode="dark"] .bubbles__option[data-theme-pick="dark"],
:root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) .bubbles__option[data-theme-pick="system"] {
  display: none;
}

.bubbles.is-open .bubbles__option {
  opacity: 1;
  visibility: visible;
  transform: translateY(calc((var(--k, 0) + 1) * -48px)) scale(1);
  transition-delay: calc(var(--k, 0) * 0.09s), calc(var(--k, 0) * 0.09s), 0s;
}

.bubbles.is-open .bubbles__bub {
  animation: bubbles-sway 1.2s ease-in-out calc(var(--k, 0) * 0.09s) both;
}

@keyframes bubbles-sway {
  0% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  50% { transform: translateX(3px); }
  75% { transform: translateX(-1.5px); }
  100% { transform: translateX(0); }
}

.bubbles__word {
  position: absolute;
  top: 50%;
  right: calc(100% + 12px);
  font-size: 14px;
  white-space: nowrap;
  color: var(--ink);
  opacity: 0;
  transform: translateY(-50%);
  transition: opacity 0.2s ease;
}

.bubbles.is-open .bubbles__word {
  opacity: 1;
  transition-delay: calc(0.22s + var(--k, 0) * 0.09s);
}

.bubbles .bubbles__option.is-landing {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: transform 0.32s cubic-bezier(0.55, 0, 0.8, 0.4);
}

.bubbles .bubbles__option.is-popping {
  opacity: 0;
  transform: translateY(calc((var(--k, 0) + 1) * -48px)) scale(1.4);
  transition: transform 0.25s ease-out, opacity 0.25s ease-out;
}

.bubbles__option:is(.is-landing, .is-popping) .bubbles__word {
  opacity: 0;
  transition-delay: 0s;
}

.bubbles.is-settling .bubbles__option,
.bubbles.is-settling .bubbles__word {
  transition: none;
}

/* With less motion the bubbles stand where they rise to at once, and go. */
@media (prefers-reduced-motion: reduce) {
  .bubbles__option,
  .bubbles__word,
  .bubbles .bubbles__option:is(.is-landing, .is-popping) {
    transition: none;
  }

  .bubbles.is-open .bubbles__bub {
    animation: none;
  }
}

/* The logo (_Logo): "water" light and "merken" bold in Albert Sans, and the
   drop before them standing on the baseline, as tall as the k (0.72em, the
   k's height in Albert Sans) and a third of that from the w (the canvas page
   Logo, L-logo). Sized by the font size of where it stands. An inline SVG's
   baseline is its bottom edge, so aligning on the baseline stands the drop
   on the line; the hundredth of an em lowers it onto the letters' own. */
.logo {
  display: inline-flex;
  align-items: baseline;
  font-family: var(--body);
  letter-spacing: -0.01em;
  white-space: nowrap;
  color: var(--ink);
}

.logo__drop {
  flex: none;
  position: relative;
  top: 0.012em;
  width: 0.512em;
  height: 0.72em;
  margin-right: 0.21em;
  fill: var(--water);
}

.logo__light {
  font-weight: 300;
}

.logo__bold {
  font-weight: 700;
}

/*
 * A mark's drawing (_Drawing): the uploaded picture as a mask, painted in the
 * colour of the text around it, so one file follows light, dark and deep
 * water (canvas "Nieuwe look voorstellen", S-tekeningen). Its size is the
 * place's --size. Without a drawing there is no mask to paint through, so the
 * box keeps its place and paints nothing.
 */
.drawing {
  display: inline-block;
  flex: none;
  width: var(--size, 64px);
  height: var(--size, 64px);
  background: currentColor;
  -webkit-mask: var(--drawing) center / contain no-repeat;
  mask: var(--drawing) center / contain no-repeat;
}

.drawing:not([style]) {
  background: none;
}

/* ---------- controls ---------- */

/*
 * The burger's stand-in, in whichever bar stays: beside the search once the
 * register's bar is pinned, beside the tab strip once /admin's band is lifted.
 * The real one is a <details> in the header, and this opens it rather than
 * being a second one — so there is one open state, one sheet, one Escape.
 *
 * Sized where it is used, because both places have a neighbour to match: the
 * register's row is 46px, and /admin's is the height of
 * the tab strip, which is not the same at both widths.
 */
.bar-menu {
  display: none;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  color: var(--ink);
  cursor: pointer;
}

.bar-menu:hover {
  border-color: var(--ink);
}

/*
 * On /admin the stand-in arrives rather than appearing: it comes in from the
 * band's own edge as the header goes, widening out of nothing with its border
 * drawn on at the end (design canvas 2B, tabBurgerStyle). Which is why it is
 * laid out at all times and only its width is nought — display cannot be
 * animated, and a button that blinks into place is not what the canvas draws.
 *
 * It shrinks the strip beside it as it comes, which is the other half of the
 * movement: the tabs slide sideways under overflow-x rather than being pushed
 * off the edge.
 */
@media (max-width: 743px) {
  .admin-bar .bar-menu {
    display: flex;
    order: 1;
    width: 0;
    height: 48px;
    margin-left: 0;
    overflow: hidden;
    border-width: 0;
    opacity: 0;
    transition:
      width 0.3s var(--sheet-ease),
      border-width 0.3s var(--sheet-ease),
      opacity 0.22s ease,
      margin-left 0.3s var(--sheet-ease);
  }

  .admin-bar.is-lifted .bar-menu {
    width: 48px;
    margin-left: 10px;
    border-width: 1px;
    opacity: 1;
  }
}

/* De lijst's search (List.cshtml): an open field, 44px like the order button
   beside it, wide only; without script a button beside it sends it. */
.search {
  display: flex;
  align-items: center;
  gap: 10px;
}

.field {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 260px;
  height: 44px;
  padding: 0 12px 0 14px;
  border: 1px solid var(--input-line);
  background: var(--ground);
}

.field:focus-within {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 3px;
}

.field__icon {
  display: flex;
  color: var(--muted);
}

.field input {
  flex: 1;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  outline: none;
}

.field input::-webkit-search-cancel-button {
  display: none;
}

.field__clear {
  display: flex;
  color: var(--muted);
}

.field__clear:hover {
  color: var(--ink);
}

.field input:placeholder-shown ~ .field__clear {
  display: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 38px;
  padding: 0 15px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  color: var(--ink);
  font-size: 12.5px;
  letter-spacing: 0.06em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}

.btn:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.btn--accent {
  border-color: var(--water);
  background: var(--water);
  color: var(--on-water);
}

.btn--accent:hover {
  border-color: var(--water);
  color: var(--on-water);
  opacity: 0.9;
}

/* Outlined, not filled: this one is offered beside "opslaan", so it must not
   read as the louder of the two. */
.btn--danger {
  padding: 0 14px;
  background: transparent;
  color: var(--danger);
}

.btn--danger:hover {
  border-color: var(--danger);
  color: var(--danger);
}

/* Filled, and only ever on the button that does the deleting. */
.btn--danger-solid {
  border-color: var(--danger);
  background: var(--danger);
  color: var(--on-water);
}

.btn--danger-solid:hover {
  border-color: var(--danger);
  color: var(--on-water);
  opacity: 0.9;
}

/*
 * The theme switch (_ThemeSwitch): a pill with a button per mode, its icon
 * and its word (design canvas "Themaschakelaar voorstellen", c, and D10 E for
 * the menu). The wide foot draws the theme as bubbles instead (.bubbles).
 *
 * Drawn two ways (SwitchLook). Compact in /admin's header: a round button
 * with only the chosen option in it, which while open widens into every
 * option with its word and pushes the header aside — nothing lies over the
 * page. Full in the menu's foot: every option always, side by side, the
 * icons alone, with the label and the value beside it (_Menu).
 *
 * Under the chosen option lies the chip, the colour that says which one it
 * is: one element per switch, which site.js places from what it measures
 * (--chip-x, --chip-w) and slides to a new choice. How wide a word is, is not
 * the stylesheet's to know, and the options are as wide as their words.
 * Until it is placed (.has-chip) the chosen option carries the colour itself.
 *
 * "The chosen option" is one list of selectors, written out wherever it is
 * needed: data-theme-mode, which the head script sets before first paint —
 * so the switch is right before site.js runs. The last also covers a missing
 * attribute.
 */
.switch {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  height: 38px;
  border: 1px solid var(--rule);
  border-radius: 19px;
  background: var(--ground);
  overflow: hidden;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.switch__chip {
  position: absolute;
  top: 0;
  left: 0;
  width: var(--chip-w, 0px);
  height: 36px;
  border-radius: 18px;
  background: var(--chip);
  opacity: 0;
  transform: translateX(var(--chip-x, 0px));
  pointer-events: none;
  transition:
    transform 0.4s var(--sheet-ease),
    width 0.4s var(--sheet-ease),
    opacity 0.1s ease;
}

/* Placed for the first time, or again because the widths changed: put
   there, not slid there. Only a choice slides it. */
.switch.is-placing .switch__chip {
  transition: none;
}

.switch__option {
  position: relative;
  display: flex;
  flex: none;
  align-items: center;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.switch__option:hover,
.switch__option:is(
  :root[data-theme-mode="light"] [data-theme-set="light"],
  :root[data-theme-mode="dark"] [data-theme-set="dark"],
  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
) {
  color: var(--ink);
}

/* Inside the pill, which clips whatever reaches past its edge: the ring is
   drawn inwards, round the option's own corners. */
.switch__option:focus-visible {
  outline-offset: -2px;
  border-radius: 18px;
}

/* An option is its icon and its word, with room after the word to match the
   room the icon has round it. */
.switch__in {
  display: inline-flex;
  flex: none;
  align-items: center;
  padding-right: 13px;
}

.switch__icon {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
}

.switch__word {
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* The theme's icons are the page as it will be, in a paper and an ink that
   do not change with the theme: a dark page is drawn in ink in both. The
   edge first, so a circle that is paper or ink as well takes that fill. */
.mode__edge {
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.3;
}

.mode__paper {
  fill: var(--mode-paper);
}

.mode__ink {
  fill: var(--mode-ink);
}

.mode__ray {
  fill: none;
  stroke: var(--muted);
  stroke-width: 1.4;
  stroke-linecap: round;
}

/*
 * Compact, closed: a round button, 38px like everything else in a wide
 * header. Every option is in it, but only the chosen one has room; the others
 * are squeezed to nothing. They stay in the tab order on purpose: Tab from
 * the chosen one has to land on the next, and landing there opens the switch.
 */
.switch--compact .switch__option {
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  transition:
    max-width 0.34s var(--sheet-ease),
    opacity 0.2s ease,
    color 0.2s ease,
    background-color 0.2s ease;
}

/* :where, so the open rules below outweigh it: the list weighs more than
   they do, and the chosen option has to widen with the rest. */
.switch--compact .switch__option:where(
  :root[data-theme-mode="light"] [data-theme-set="light"],
  :root[data-theme-mode="dark"] [data-theme-set="dark"],
  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
) {
  max-width: 36px;
  opacity: 1;
}

/*
 * A link in the switches' shape, with one option and no chip: de lijst's
 * "Woord aandragen" and /admin's "Nieuw woord" and "Nieuwe pagina", all
 * standing open (.switch--accent, below). Focused, the link is the switch
 * itself, and the global ring would square its corners.
 */
.switch--link {
  color: var(--ink);
  text-decoration: none;
}

.switch--link:focus-visible {
  border-radius: 19px;
}

/*
 * Open. With script, while site.js says so (.is-open, from the pointer's own
 * events — site.js says why not :hover, under "the switches"; it also keeps a
 * switch open a moment after the pointer leaves) or while focus the keyboard
 * put there is on or inside it; without, while it is hovered or focused.
 *
 * Every option grows to the width site.js measured for it (--open-w), so the
 * widening eases out exactly where it ends; 160px is only for no script. The
 * chip fades in once the widening is under way, so it is not seen sliding to
 * where the chosen option is going.
 */
:root.js .switch--compact.is-open,
:root.js .switch--compact:focus-visible,
:root.js .switch--compact:has(:focus-visible),
:root:not(.js) .switch--compact:hover,
:root:not(.js) .switch--compact:focus-within {
  border-color: var(--ink);
  box-shadow: var(--shadow-pop);
}

:root.js .switch--compact.is-open .switch__option,
:root.js .switch--compact:focus-visible .switch__option,
:root.js .switch--compact:has(:focus-visible) .switch__option,
:root:not(.js) .switch--compact:hover .switch__option,
:root:not(.js) .switch--compact:focus-within .switch__option {
  max-width: var(--open-w, 160px);
  opacity: 1;
}

:root.js .switch--compact.is-open .switch__chip,
:root.js .switch--compact:has(:focus-visible) .switch__chip {
  opacity: 1;
  transition:
    transform 0.4s var(--sheet-ease),
    width 0.4s var(--sheet-ease),
    opacity 0.18s ease 0.18s;
}

/* No chip yet, or no script: the chosen option is coloured itself, open. */
:root.js .switch--compact:not(.has-chip):is(.is-open, :has(:focus-visible)) .switch__option:is(
  :root[data-theme-mode="light"] [data-theme-set="light"],
  :root[data-theme-mode="dark"] [data-theme-set="dark"],
  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
) {
  background: var(--chip);
}

/* De lijst's "Woord aandragen", /admin's "Nieuw woord" and "Nieuwe pagina":
   the same shape standing open — not compact, so site.js leaves them be — a
   pill with its plus and its words, filled in the accent as the buttons they
   replaced were. */
.switch--accent {
  border-color: var(--water);
  background: var(--water);
  color: var(--on-water);
  transition: opacity 0.2s ease;
}

.switch--accent .switch__option,
.switch--accent .switch__option:hover {
  color: var(--on-water);
}

.switch--accent:hover {
  opacity: 0.9;
}

/*
 * Open where the header has no room for the words (.is-bare, set by site.js
 * from what it measures: just above 743px, or with a long navigation) — the
 * icons alone, the words kept for a screen reader.
 */
.switch--compact.is-bare .switch__in {
  padding-right: 0;
}

.switch--compact.is-bare .switch__word {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

/*
 * Full, in the menu's foot (design canvas "Themaschakelaar voorstellen",
 * D10, E): the codes or the icons alone, side by side, each 44px for a
 * finger, with the label and the chosen value beside the switch (_Menu). The
 * words stay for a screen reader.
 */
.switch--full {
  height: 46px;
  padding: 3px;
  border-radius: 23px;
}

.switch--full .switch__chip {
  top: 3px;
  height: 38px;
  border-radius: 19px;
  opacity: 1;
}

.switch--full .switch__option {
  justify-content: center;
  width: 44px;
  height: 38px;
  border-radius: 19px;
}

.switch--full .switch__option:focus-visible {
  border-radius: 19px;
}

.switch--full .switch__in {
  padding-right: 0;
}

.switch--full .switch__icon {
  width: 44px;
  height: 38px;
}

.switch--full .switch__word {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

.switch--full:not(.has-chip) .switch__option:is(
  :root[data-theme-mode="light"] [data-theme-set="light"],
  :root[data-theme-mode="dark"] [data-theme-set="dark"],
  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
) {
  background: var(--chip);
}

/* A language's flag (_Flag): on the strip offering its list (_Offer) and in
   the foot's "Ook verwaterd in" (_Elsewhere). */
.flag {
  display: block;
  border-radius: 1px;
}

/* A language with no flag drawn in _Flag.cshtml yet. */
.flag--code {
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
}

/* ---------- de lijst ---------- */

/*
 * De lijst, under the front page's intro (List.cshtml, _SortMenu, _Register;
 * canvas "Nieuwe look voorstellen", K-tel-lijst and B-lijst-mix). No name of
 * its own, the intro says what it is: wide the search and the order at the
 * right, over the tiles; then the words, one link each: on a phone a row,
 * wide a tile of a grid.
 */
.list-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 20px 40px;
  padding-top: 32px;
}

.list-head__controls {
  display: flex;
  align-items: center;
  gap: 24px;
}

/* The count and the way back from a search: said on a phone, where the
   count stands beside the order; wide only to a screen reader. */
.list-results {
  display: flex;
  align-items: center;
  gap: 16px;
}

.list-results__count {
  margin: 0;
  font-size: 14px;
}

.list-results__all {
  font-size: 14px;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/*
 * The order (_SortMenu; U-volgorde A): one button, 44px like the search,
 * naming the order in use; it opens a list of all six with a check at the
 * one in use. A <details>, so it opens without script; list.js closes it on
 * Escape and on a click beside it.
 */
.order {
  position: relative;
}

.order__button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--input-line);
  background: var(--ground);
  font-size: 15px;
  color: var(--ink);
  list-style: none;
  white-space: nowrap;
  cursor: pointer;
}

.order__button::-webkit-details-marker {
  display: none;
}

.order[open] .order__chevron {
  transform: rotate(180deg);
}

.order__list {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  min-width: 200px;
  padding: 6px 0;
  border: 1px solid var(--ink);
  background: var(--ground);
}

.order__option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 44px;
  padding: 0 16px;
  font-size: 15px;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.order__option:hover {
  background: var(--wash);
}

.order__option[aria-current] {
  font-weight: 600;
}

.order__check {
  color: var(--water);
}

.register {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  margin-top: 18px;
  border-top: 1.5px solid var(--ink);
}

.register--empty {
  display: block;
  padding: 28px 0;
}

/*
 * A word: on a phone a row (K-tel-lijst) — the drawing, the brand over the
 * word, and the drop with its share in a column of its own, which stays empty
 * under the threshold.
 */
.tile {
  --size: 64px;
  --drop: 22px;
  position: relative;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 56px;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.tile:focus-visible {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: -4px;
}

.tile__top,
.tile__foot {
  display: contents;
}

.tile__words {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.tile__brand {
  font-family: var(--display);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.15;
}

.tile__term {
  font-size: 17px;
  overflow-wrap: break-word;
}

.tile__vote {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 12px;
  color: var(--muted);
}

.tile__vote--few {
  visibility: hidden;
}

.tile__excerpt,
.tile__share,
.tile__few,
.tile__hint,
.tile__water {
  display: none;
}

/* The place a word's way back lands: the tile's top edge, taking no room
   and no cell of a phone row's grid. */
.tile__anchor {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.tile__share b {
  font-weight: 600;
  color: var(--ink);
}

.tile__pct b {
  font-weight: inherit;
}

/* The level of the drop in a small tile while the water rises (below):
   registered, so it can move. */
@property --fill {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

/* How much of a small tile's words shows under its result (below): 1 all,
   0 none. Registered, so it can fade. */
@property --veil {
  syntax: "<number>";
  inherits: false;
  initial-value: 1;
}

/*
 * Wide (B-lijst-mix): a grid of tiles 196px high, three columns from 744px,
 * four from 960 and five from 1200. One tile a row is two columns wide, by
 * its place — 1, 4, 2, 3 and round again with five columns, 1, 3, 2 with
 * four, 1, 2 with three — so a different order makes different words big. A
 * big tile shows the start of the story beside its drawing and "86% vindt
 * het verwaterd", or "Te weinig stemmen" with the dashed drop, which a small
 * tile shows while it is pointed at. A search of fewer than five words has no
 * big tile (.register--few).
 */
@media (min-width: 744px) {
  .register {
    grid-auto-rows: 196px;
    margin-top: 28px;
  }

  /* Measured against the prototype "Waterlijn bij hover". The row above
     centres its parts; a tile's run from edge to edge, so the words stand at
     the padding and the result against the right.

     A tile always has room for three lines under its drawing, which stays
     84px: the brand on two at most, the term on one, each cut off with "…"
     past that. In 196px that leaves 4px between the drawing and a brand of
     two lines — the gap below — and more for every shorter one, which the
     space between top and foot takes up. */
  .tile {
    --size: 84px;
    --drop: 15px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: space-between;
    gap: 4px;
    padding: 18px 18px 20px;
    border-right: 1px solid var(--line);
  }

  .tile__top {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 18px;
    align-items: flex-start;
  }

  /* A drawing has air around its lines; this puts them, rather than the
     box, under the brand. */
  .tile__top .drawing {
    margin-left: -7px;
  }

  .tile__foot {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
  }

  /* Bodoni's p, g and y reach about 2px under its 1.1 line, which the
     clamp's overflow would cut off: the padding gives them room to clip in,
     and the margin takes it back. */
  .tile__brand {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    margin-block: -2px;
    padding-block: 2px;
    overflow: hidden;
    font-size: 23px;
    line-height: 1.1;
  }

  .tile__term {
    overflow: hidden;
    font-size: 15px;
    line-height: 1.2;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  /* Only a big tile shows it (below): four lines, clamped. */
  .tile__excerpt {
    font-size: 14px;
    line-height: 1.5;
    color: var(--muted);
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* A small tile: its drop and number come up with the water — or, under
     the threshold, the dashed drop and "Te weinig stemmen", with no water.
     It lies in the foot's corner over the words, so they keep the tile's
     whole width and are cut off only where the tile ends; while it shows,
     the words fade out under it (.tile__words, below). A big tile's stands
     beside them. */
  .tile__vote {
    position: absolute;
    right: 0;
    bottom: 0;
    flex: none;
    font-size: 13px;
    line-height: 1.2;
    opacity: 0;
    transition: opacity calc(var(--drain) * 0.5) ease;
  }

  .tile__vote--few {
    width: 56px;
    font-size: 12px;
    text-align: center;
    visibility: visible;
  }

  .tile__few {
    display: block;
  }

  .tile__pct b {
    font-weight: 600;
    color: var(--ink);
  }

  .tile:is(:hover, :focus-visible) .tile__vote {
    opacity: 1;
    transition: opacity 180ms ease calc(var(--rise) * 0.35);
  }

  /* The words under a small tile's result: a mask whose lower right corner,
     as wide and high as the result (--room, --under), loses its words as
     --veil goes to 0, on the result's own timing. The 2px above take in the
     brand's room for its accents. */
  .tile__words {
    --room: 36px;
    --under: 38px;
    flex: 1;
    margin-top: -2px;
    padding-top: 2px;
    -webkit-mask:
      linear-gradient(#000 0 0) top / 100% calc(100% - var(--under)) no-repeat,
      linear-gradient(to left, rgb(0 0 0 / var(--veil)) var(--room), #000 calc(var(--room) + 24px)) bottom / 100% var(--under) no-repeat;
    mask:
      linear-gradient(#000 0 0) top / 100% calc(100% - var(--under)) no-repeat,
      linear-gradient(to left, rgb(0 0 0 / var(--veil)) var(--room), #000 calc(var(--room) + 24px)) bottom / 100% var(--under) no-repeat;
    transition: --veil calc(var(--drain) * 0.5) ease;
  }

  .tile:has(.tile__vote--few) .tile__words {
    --room: 64px;
    --under: 50px;
  }

  .tile:is(:hover, :focus-visible) .tile__words {
    --veil: 0;
    transition: --veil 180ms ease calc(var(--rise) * 0.35);
  }

  /* The prototype's drop sits in an 18px box; the margin gives ours, drawn
     to its own outline, the same place. */
  .tile__vote .drop {
    margin: 2px 3.5px 1px;
  }

  /* And a small tile's drop fills as its water rises. A big tile's stands
     full (below). */
  .tile__vote .drop:not(.drop--few) {
    background: linear-gradient(to top, var(--water) var(--fill), transparent var(--fill));
    transition: --fill var(--drain) var(--drain-ease);
  }

  .tile:is(:hover, :focus-visible) .tile__vote .drop:not(.drop--few) {
    --fill: var(--p);
    transition: --fill var(--rise) var(--rise-ease);
  }

  /*
   * The waterline (U-hover; the prototype "Waterlijn", 4 with the result):
   * light water up to the share, rising in --rise while a mouse is on the
   * tile or the keyboard's focus is, a small wave moving on it meanwhile,
   * and draining in the shorter --drain, so nothing trails behind the mouse.
   * The wave is scaled inside its SVG: a scale on the HTML around it would
   * squash its line, which non-scaling-stroke does not undo.
   */
  .tile__water {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 0;
    display: block;
    height: var(--p);
    background: var(--hover-water);
    pointer-events: none;
    transform: translateY(calc(100% + 6px));
    transition: transform var(--drain) var(--drain-ease);
  }

  .tile__wave {
    position: absolute;
    top: -4px;
    left: 0;
    width: 100%;
    height: 8px;
  }

  .tile__wave svg {
    display: block;
    width: 200%;
    height: 8px;
    overflow: visible;
  }

  .tile__wave g {
    transform-box: view-box;
    transform-origin: 0 4px;
    transform: scaleY(0.05);
    transition: transform var(--drain) ease;
  }

  .tile__wave-fill {
    fill: var(--hover-water);
  }

  .tile__wave-line {
    fill: none;
    stroke: var(--hover-wave);
    stroke-width: 1.5;
    vector-effect: non-scaling-stroke;
  }

  .tile:is(:hover, :focus-visible) .tile__water {
    transform: none;
    transition: transform var(--rise) var(--rise-ease);
  }

  .tile:is(:hover, :focus-visible) .tile__wave g {
    transform: scaleY(0.6);
    transition: transform var(--rise) ease;
  }

  .tile:is(:hover, :focus-visible) .tile__wave svg {
    animation: tile-drift 2.6s linear infinite;
  }
}

@keyframes tile-drift {
  to {
    transform: translateX(-10%);
  }
}

@media (min-width: 744px) and (max-width: 959px) {
  .register {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) {
    grid-column: span 2;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__excerpt {
    display: -webkit-box;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__share,
  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__few {
    display: block;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__vote {
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    opacity: 1;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__words {
    -webkit-mask: none;
    mask: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__vote--few {
    display: flex;
    width: auto;
    font-size: 12px;
    text-align: start;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__vote .drop:not(.drop--few) {
    --fill: var(--p);
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .tile__pct {
    display: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(4n+1), :nth-child(4n+4)) .drawing:not([style]) {
    display: none;
  }
}

@media (min-width: 960px) and (max-width: 1199px) {
  .register {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) {
    grid-column: span 2;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__excerpt {
    display: -webkit-box;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__share,
  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__few {
    display: block;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__vote {
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    opacity: 1;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__words {
    -webkit-mask: none;
    mask: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__vote--few {
    display: flex;
    width: auto;
    font-size: 12px;
    text-align: start;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__vote .drop:not(.drop--few) {
    --fill: var(--p);
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .tile__pct {
    display: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(9n+1), :nth-child(9n+6), :nth-child(9n+8)) .drawing:not([style]) {
    display: none;
  }
}

@media (min-width: 1200px) {
  .register {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) {
    grid-column: span 2;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__excerpt {
    display: -webkit-box;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__share,
  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__few {
    display: block;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__vote {
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    opacity: 1;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__words {
    -webkit-mask: none;
    mask: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__vote--few {
    display: flex;
    width: auto;
    font-size: 12px;
    text-align: start;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__vote .drop:not(.drop--few) {
    --fill: var(--p);
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .tile__pct {
    display: none;
  }

  .register:not(.register--few) > .tile:is(:nth-child(16n+1), :nth-child(16n+8), :nth-child(16n+10), :nth-child(16n+15)) .drawing:not([style]) {
    display: none;
  }
}

/* On a phone the page runs edge to edge, so the head and every row carry
   the gutter themselves and the rules between the rows reach both edges
   (K-tel-lijst). */
@media (max-width: 743px) {
  .list-head {
    padding: 22px var(--gutter) 0;
  }

  .tile {
    padding-inline: var(--gutter);
  }

  .register--empty {
    padding-inline: var(--gutter);
  }

  .list-head__controls {
    flex: 1 1 100%;
    justify-content: space-between;
    padding-bottom: 10px;
  }

  .search {
    display: none;
  }

  .list-results {
    flex: 1;
    justify-content: space-between;
  }

  .register {
    margin-top: 0;
  }

  /*
   * One row in five is bigger (the canvas "Af en toe een grotere rij", A),
   * by its place as the wide grid's big tile is — the third, the eighth and
   * so on — and none under five words. It keeps the ordinary row's columns,
   * so its brand stands where every brand stands, and grows downwards: the
   * story's first lines under the words, then the result as a sentence.
   */
  .register:not(.register--few) > .tile:nth-child(5n+3) {
    --drop: 16px;
    grid-template-columns: 64px minmax(0, 1fr);
    align-items: start;
    row-gap: 10px;
    padding-block: 16px 18px;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) .drawing {
    grid-column: 1;
    grid-row: 1 / span 3;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) .tile__words {
    grid-column: 2;
    grid-row: 1;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) :is(.tile__excerpt, .tile__hint) {
    grid-column: 2;
    grid-row: 2;
    font-size: 14px;
    line-height: 1.5;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) .tile__excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--muted);
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) .tile__vote {
    grid-column: 2;
    grid-row: 3;
    flex-direction: row;
    gap: 8px;
    font-size: 14px;
    visibility: visible;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3):not(:has(.tile__excerpt, .tile__hint)) .tile__vote {
    grid-row: 2;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) :is(.tile__share, .tile__few) {
    display: inline;
  }

  .register:not(.register--few) > .tile:nth-child(5n+3) .tile__pct {
    display: none;
  }

  /*
   * Until this browser has opened a word, the second bigger row says that a
   * row opens, in place of its story: the head script sets .never-opened,
   * and a word's page (vote.js) ends it. Without script it never shows.
   */
  :root.never-opened .register:not(.register--few) > .tile:nth-child(8) .tile__hint {
    display: block;
  }

  /* In the light blue of "Mee eens?" and of /submit's example row, which on
     the site already means: this is for you to do. Never like the story,
     which stands grey and plain (canvas "De hulptekst, anders dan het
     verhaal", C). */
  .tile__hint {
    padding: 10px 12px;
    background: var(--water-light);
    color: var(--ink);
  }

  :root.never-opened .register:not(.register--few) > .tile:nth-child(8) .tile__excerpt {
    display: none;
  }
}

/* From 744px the count is the screen reader's: the canvas has none. And
   "Toon alle woorden" is the phone's: wide, the search field's cross clears
   the search, and the link appearing beside it pushed the order aside. */
@media (min-width: 744px) {
  .list-results__count {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .list-results__all {
    display: none;
  }
}

/* Without motion the water stands at its level at once, and nothing moves. */
@media (prefers-reduced-motion: reduce) {
  .tile__water {
    transform: none !important;
    opacity: 0;
    transition: opacity 150ms ease !important;
  }

  .tile:is(:hover, :focus-visible) .tile__water {
    opacity: 1;
  }

  .tile__wave g {
    transform: scaleY(0.05) !important;
    transition: none !important;
  }

  .tile__wave svg {
    animation: none !important;
  }

  .tile__vote .drop:not(.drop--few) {
    --fill: var(--p) !important;
    transition: none !important;
  }
}

/* ---------- markup ---------- */

/*
 * What a note may hold besides paragraphs and links: strong, lists and
 * quotes (Formatting/Markup.cs, drawn by _Markup). One set of rules for every
 * place that shows markup — a note in the register, on a card and in the
 * sheet, and a page from /admin/pages — each of which sets only its own size
 * and spacing.
 *
 * All :where(), so none of this weighs anything: .page-article puts its margin
 * on every block of the article, lists and quotes included, and has to win.
 */
:where(.word__notes, .page-article) strong {
  font-weight: 600;
}

:where(.word__notes, .page-article) :where(ul, ol) {
  margin: 0;
  padding-left: 1.3em;
}

:where(.word__notes, .page-article) li + li {
  margin-top: 0.3em;
}

:where(.word__notes, .page-article) li::marker {
  color: var(--muted);
}

/* A quote is somebody else's voice — a ruling, an advertisement — so it is
   set in the face the register gives the words themselves, against a rule
   of its own. */
:where(.word__notes, .page-article) blockquote {
  display: flex;
  flex-direction: column;
  gap: 0.5em;
  margin: 0;
  padding-left: 14px;
  border-left: 2px solid var(--line);
  font-family: var(--display);
  font-size: 1.08em;
  line-height: 1.5;
  color: var(--ink);
}

:where(.word__notes, .page-article) blockquote p {
  margin: 0;
}

/* An item with more than one block in it: a second paragraph or a quote
   stands a little further off than the next item does, a list of its own as
   far as the next item, so it reads as more items. Not :where, and the block
   named at the end: .word__notes p sets every paragraph's margin to nothing,
   and this has to outweigh it. */
:is(.word__notes, .page-article) li > * + :is(p, blockquote) {
  margin-top: 0.45em;
}

:is(.word__notes, .page-article) li > * + :is(ul, ol) {
  margin-top: 0.3em;
}

/* ---------- a word's page ---------- */

/*
 * A word on a page of its own (Word.cshtml; canvas "Nieuwe look
 * voorstellen", B-woord and K-tel-woord). Wide: the way back and the words
 * either side in a bar, then the drawing, the brand and how it is voted on
 * the left and the story and the vote panel on the right. Narrow: one
 * column, the neighbours as arrows, and the next word at the foot.
 */
.word-steps {
  display: flex;
  align-items: center;
  gap: 28px;
  min-height: 60px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.word-steps a {
  color: var(--ink);
  text-decoration: none;
}

.word-steps a:hover {
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.word-steps__back {
  margin-right: auto;
}

.word-steps__step--prev {
  color: var(--muted);
}

.word-steps__arrow {
  display: none;
}

.word__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 40px;
  margin-top: 40px;
}

.word__head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.word__head .drawing {
  --size: 132px;
  margin: 0 0 20px -10px;
}

/* No drawing: the brand stands at the top (U-zonder-tekening, A). */
.word__head .drawing:not([style]) {
  display: none;
}

.word__brand {
  margin: 0;
  font-family: var(--display);
  font-size: 52px;
  font-weight: 500;
  line-height: 0.95;
  overflow-wrap: anywhere;
}

/* The word under the brand, and the holder under the word, close to it: the
   brand and the word are the pair, "van …" a quiet line closing it (canvas
   Uitwerking · U-merkhouder, B). */
.word__term {
  margin: 18px 0 0;
  font-size: 26px;
  font-weight: 500;
}

.word__holder {
  margin: 4px 0 0;
  font-size: 16px;
  color: var(--muted);
}

.word__head .result {
  align-self: stretch;
  margin-top: 22px;
}

/* "Ook in": the same mark's word in the other lists, a row of its own under
   the result's, closed by the same hairline (canvas Uitwerking · andere
   talen, ronde 2). The label in grey, each word in the ink, underlined in
   water, after its language's label. */
.word__elsewhere {
  display: flex;
  flex-wrap: wrap;
  align-self: stretch;
  align-items: center;
  gap: 8px 18px;
  margin: 0;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  color: var(--muted);
}

.word__other {
  color: var(--ink);
  text-decoration: none;
}

.word__other .lang-pill {
  margin-right: 2px;
  vertical-align: 0.1em;
}

.word__other-term {
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/* Not on a phone, where the result's row is enough before the story; the
   foot names the other lists there. 743px: the breakpoint site.js shares. */
@media (max-width: 743px) {
  .word__elsewhere {
    display: none;
  }
}

.word__story {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  max-width: 620px;
}

/* The story is text as a page's is (.page-article): 16px, 15px on a
   phone. */
.word__notes {
  font-size: 16px;
  line-height: 1.7;
}

.word__byline {
  margin: 0;
  font-size: 15px;
  color: var(--muted);
}

/* On a phone, under the panel: on to the next word. */
.word-next {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 40px;
  padding: 18px 0;
  border-top: 1.5px solid var(--ink);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.word-next__label {
  font-size: 14px;
  color: var(--muted);
}

.word-next__brand {
  margin-right: auto;
  font-family: var(--display);
  font-size: 26px;
  font-weight: 500;
}

@media (min-width: 960px) {
  .word__body {
    grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
    gap: 72px;
    margin-top: 48px;
  }

  .word__head .drawing {
    --size: 200px;
    margin-left: -14px;
  }

  .word__brand {
    font-size: 76px;
  }

  .word__term {
    font-size: 30px;
  }

  .word-next {
    display: none;
  }
}

@media (max-width: 743px) {
  .word-steps {
    gap: 22px;
    padding: 0 var(--gutter);
  }

  .word-steps__name,
  .word-steps__step > span:not(.word-steps__arrow) {
    display: none;
  }

  .word-steps__arrow {
    display: inline;
    font-size: 18px;
  }

  .word__body,
  .word-next {
    padding-inline: var(--gutter);
  }

  .word__body {
    margin-top: 24px;
  }

  .word__term {
    margin-top: 14px;
  }

  .word__holder {
    font-size: 15px;
  }

  .word__notes {
    font-size: 15px;
    line-height: 1.65;
  }
}

/*
 * How a word is voted, under its term (_VoteResult): the drop and the
 * sentence between two hairlines, and "Stem mee" down to the panel — under
 * the threshold at every width, above it on a phone only, where the panel is
 * under the whole story.
 */
.result {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin: 0;
  padding: 14px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 16px;
  --drop: 22px;
}

.result__join {
  margin-left: auto;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

@media (min-width: 744px) {
  .result__join--phone {
    display: none;
  }
}

/*
 * The drop as a meter (_Drop): a box masked to the drop's shape, the water a
 * gradient up to --p, and the outline a second mask of the same path drawn
 * as a line. The dashed one, too few votes, is an SVG of its own.
 */
.drop {
  position: relative;
  display: inline-block;
  flex: none;
  width: calc(var(--drop, 22px) * 0.71);
  height: var(--drop, 22px);
  background: linear-gradient(to top, var(--water) var(--p, 0%), transparent var(--p, 0%));
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='5 2.5 14 19.7'%3E%3Cpath d='M12 2.5C12 2.5 5 10.8 5 15.2a7 7 0 0 0 14 0C19 10.8 12 2.5 12 2.5Z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='5 2.5 14 19.7'%3E%3Cpath d='M12 2.5C12 2.5 5 10.8 5 15.2a7 7 0 0 0 14 0C19 10.8 12 2.5 12 2.5Z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.drop::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--water);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='5 2.5 14 19.7'%3E%3Cpath d='M12 2.5C12 2.5 5 10.8 5 15.2a7 7 0 0 0 14 0C19 10.8 12 2.5 12 2.5Z' fill='none' stroke='black' stroke-width='2.6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='5 2.5 14 19.7'%3E%3Cpath d='M12 2.5C12 2.5 5 10.8 5 15.2a7 7 0 0 0 14 0C19 10.8 12 2.5 12 2.5Z' fill='none' stroke='black' stroke-width='2.6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.drop--few {
  width: calc(var(--drop, 22px) * 0.72);
  background: none;
  -webkit-mask: none;
  mask: none;
  fill: none;
  stroke: var(--faint-2);
  stroke-width: 1.2;
  stroke-dasharray: 2 2;
  vector-effect: non-scaling-stroke;
}

.drop--few path {
  vector-effect: non-scaling-stroke;
}

.drop--few::before {
  content: none;
}

/*
 * The vote panel (_Vote; canvas B-woord, K-tel-stemmen, K-tel-gestemd):
 * "Mee eens?" on water-light with the bar "Merk | Verwaterd" as two real
 * submit buttons; once answered "Jouw stem", the bar showing the split. The
 * split's place is --split, registered so it can move from the old answer
 * to the new one (site.js swaps in the new panel at the old place and sets
 * the new one).
 */
@property --split {
  syntax: "<percentage>";
  inherits: true;
  initial-value: 50%;
}

.vote {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
  padding: 28px 30px 30px;
  background: var(--water-light);
  scroll-margin-top: calc(var(--nav-h, 88px) + 16px);
}

.vote__heading {
  margin: 0;
  font-family: var(--display);
  font-size: 32px;
  font-weight: 400;
  line-height: 1.1;
}

/* Text beside the story, at the story's size: 16px, 15px on a phone.

   Once answered, the sentence stands where the question stood, with the
   question itself under it, unseen (.vote__room): the row keeps the
   question's height, so the bar under it does not move when a shorter
   sentence comes in (canvas Uitwerking · het stemvlak blijft staan, C). */
.vote__line {
  display: grid;
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
}

.vote__line > span {
  grid-area: 1 / 1;
}

.vote__room {
  visibility: hidden;
}

@media (max-width: 743px) {
  .vote__line {
    font-size: 15px;
  }
}

/* The line of links under the bar, the same height in both faces: "Wat is
   verwaterd?", and once answered .vote__after. */
.vote__why,
.vote__after {
  font-size: 15px;
  line-height: 1.6;
}

/* On a phone the answered line does not fit on one line — "Toch een merk?
   Wijzig je stem" and the count go under each other — so both faces keep
   room for two, and nothing under the panel moves when the answer comes. */
@media (max-width: 743px) {
  .vote__why,
  .vote__after {
    min-height: 3.2em;
  }
}

.vote__why > summary {
  display: inline;
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
  list-style: none;
}

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

.vote__lemma {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
  padding: 14px 16px;
  background: var(--ground);
  font-size: 15px;
  line-height: 1.5;
}

.vote__lemma p {
  margin: 0;
}

.vote__term {
  font-family: var(--display);
  font-size: 22px;
}

.vote__pos {
  font-style: italic;
  color: var(--muted);
}

.vote__case-label {
  font-weight: 600;
}

.vote__bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 56px;
  margin-top: 6px;
  border: 1px solid var(--ink);
  background: var(--ground);
}

.vote__half {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  border: 0;
  background: none;
  font: 500 17px var(--body);
  color: var(--ink);
  cursor: pointer;
}

.vote__half--brand {
  border-right: 1px solid var(--ink);
}

.vote__half--generic {
  justify-content: flex-end;
}

/* With a mouse only. Safari keeps :hover on whatever a finger last touched,
   and after "Wijzig je stem" the fresh bar lands under it: one half stood
   washed as if it were already the answer. */
@media (hover: hover) {
  button.vote__half:hover {
    background: var(--wash);
  }
}

/* Under the threshold, once answered: no split to show yet, so the bar shows
   the answer given — its half filled, the other quieter — and answers to
   nothing. */
.vote__bar--chosen .vote__half {
  cursor: default;
}

.vote__bar--chosen .vote__half:not(.is-mine) {
  color: var(--muted);
}

.vote__half.is-mine {
  background: var(--vote-fill);
}

.vote__drop {
  width: 12px;
  height: 17px;
  fill: var(--water);
}

/* The answer in progress: one at a time (vote.js). */
.vote.is-pending .vote__half {
  cursor: progress;
}

.vote__bar--split {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 16px;
  background: linear-gradient(to right, var(--ground) var(--split), var(--vote-fill) var(--split));
  font-size: 16px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  transition: --split 0.5s ease;
}

/* "Toch een merk? Wijzig je stem" at the left, the count — or "Nog te weinig
   stemmen." — at the right, below each other where both do not fit. */
.vote__after {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0 16px;
  margin: 0;
}

.vote__clear {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
}

.vote__count {
  margin: 0;
  font-size: 15px;
  color: var(--muted);
}

.vote__braked {
  margin: 0;
  font-size: 15px;
  color: var(--danger);
}

@media (max-width: 743px) {
  .vote {
    padding: 22px var(--gutter) 24px;
  }
}

/*
 * An answer coming in, with script (vote.js): the panel's words and the
 * result line's fade out while the answer is on its way (.is-leaving), and
 * the new ones come in a row at a time (.is-arriving) — the heading, the
 * sentence, the bar's words, and, once the bar's split has moved, the line
 * of links. Only the words move; every row keeps its place. A chosen half's
 * water fills with the bar's words. The times are --vote-leave and its kin
 * on :root.
 */
@keyframes vote-leave {
  to {
    opacity: 0;
  }
}

@keyframes vote-arrive {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
}

@keyframes vote-fill {
  from {
    background-color: transparent;
  }
}

@keyframes vote-unfill {
  to {
    background-color: transparent;
  }
}

.vote__heading {
  --vote-row: 0;
}

.vote__line {
  --vote-row: 1;
}

.vote__label,
.vote__share,
.vote__half.is-mine {
  --vote-row: 2;
}

.vote__why,
.vote__after {
  --vote-row: 5;
}

.vote.is-arriving :is(.vote__heading, .vote__line, .vote__label, .vote__share, .vote__why, .vote__after),
.result.is-arriving > :not(.drop) {
  animation: vote-arrive var(--vote-arrive) cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(var(--vote-row, 0) * var(--vote-step));
}

.vote.is-arriving .vote__half.is-mine {
  animation: vote-fill var(--vote-arrive) ease both;
  animation-delay: calc(var(--vote-row) * var(--vote-step));
}

.vote.is-leaving :is(.vote__heading, .vote__line, .vote__label, .vote__share, .vote__why, .vote__after),
.result.is-leaving > :not(.drop) {
  animation: vote-leave var(--vote-leave) ease-out forwards;
}

.vote.is-leaving .vote__half.is-mine {
  animation: vote-unfill var(--vote-leave) ease-out forwards;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --vote-leave: 0ms;
  }

  .vote__bar--split {
    transition: none;
  }

  .vote :is(.vote__heading, .vote__line, .vote__label, .vote__share, .vote__why, .vote__after, .vote__half),
  .result > * {
    animation: none !important;
  }
}

/* ---------- a sheet's movement ---------- */

/* While a finger is on it the surface follows the finger, so it must not also
   be easing towards a target. The menu's sheet says the same for itself. */
.dialog.is-dragging {
  transition: none;
}

/* How a sheet comes up and its scrim fades in: the menu's, and what the
   dialogs borrow. */
@keyframes sheet-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes sheet-rise {
  from { translate: 0 100%; }
  to { translate: 0 0; }
}

/* ---------- the menu (narrow) ---------- */

/*
 * Below 743px the header's row of controls goes into a sheet behind a burger:
 * one big line for "woord aandragen", two small ones, and the language and the
 * theme in a foot of their own. Design canvas "menu in smalle weergave", 6B.
 *
 * A <details> — see _Menu.cshtml for why. Everything that makes it a sheet is
 * here, and all of it holds without script: the scrim is the summary's
 * ::before spread over the screen, so a tap on it is a tap on the summary,
 * and the page behind is held still by a :has() on [open]. site.js only adds
 * the ways out a <details> does not have and the leaving movement.
 */
.menu {
  display: none;
}

.menu__burger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  list-style: none;
  background: var(--ground);
  border: 1px solid var(--ink);
  border-radius: 50%;
  color: var(--ink);
  cursor: pointer;
  transition:
    background-color 0.16s ease,
    border-color 0.16s ease,
    color 0.16s ease;
}

.menu__burger::-webkit-details-marker {
  display: none;
}

.menu__burger-shut,
.menu[open] > .menu__burger .menu__burger-open {
  display: none;
}

.menu[open] > .menu__burger .menu__burger-shut {
  display: block;
}

.menu[open] > .menu__burger {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--ground);
}

.menu[open] > .menu__burger::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 75;
  background: var(--scrim);
  cursor: default;
  transition: opacity var(--sheet-fade) ease;
  animation: sheet-fade 0.16s ease;
}

.menu__sheet {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 80;
  display: flex;
  flex-direction: column;
  padding: 0 var(--gutter);
  background: var(--ground);
  border-top: 1px solid var(--line);
  touch-action: none;
  transition: translate var(--sheet-rise) var(--sheet-ease);
  animation: sheet-rise var(--sheet-rise) var(--sheet-ease);
}

.menu__sheet.is-dragging {
  transition: none;
}

.menu.is-closing > .menu__burger::before {
  opacity: 0;
  animation: none;
}

.menu.is-closing .menu__sheet {
  translate: 0 100%;
  animation: none;
}

.menu__grip {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  cursor: grab;
}

.menu__actions {
  display: flex;
  flex-direction: column;
}

/*
 * A public line (canvas "Nieuwe look voorstellen", P-menu-a): the page's name
 * in Bodoni with its hint under it, the first under an ink rule and each
 * after it under a hairline. The drop stands before the name of the page you
 * are on, in the gutter the names leave for it, so no name moves.
 */
.menu__actions:has(.menu__page) {
  border-top: 1.5px solid var(--ink);
}

.menu__page {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 14px 0 15px 21px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.menu__name {
  display: flex;
  align-items: baseline;
  font-family: var(--display);
  font-size: 30px;
  line-height: 1.1;
}

.menu__drop {
  flex: none;
  width: 13px;
  height: 16px;
  margin: 0 8px 0 -21px;
  fill: var(--water);
}

.menu__page .menu__hint {
  font-size: 14px;
}

.menu__page:hover .menu__name {
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/* The header's black button, which has no room there on a phone. */
.menu__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 50px;
  margin-top: 18px;
  border: 1px solid var(--ink);
  background: var(--ink);
  font-size: 16px;
  font-weight: 500;
  color: var(--ground);
  text-decoration: none;
}

/* The icons stand in a gutter at the start of the line, the text beside them:
   the signs read down one column and the words start at the reading edge. */
.menu__item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 0;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

/* No rule over the first line, whichever it is: it stands under the grip, not
   under another line. Only the register's menu starts with the big one. */
.menu__item:first-child {
  border-top: 0;
}

.menu__item--big {
  padding: 12px 0 18px;
}

.menu__icon {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--muted);
}

.menu__item--big .menu__icon {
  color: var(--water);
}

.menu__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.menu__label {
  font-size: 15.5px;
  line-height: 1.3;
  color: var(--ink);
}

.menu__item--big .menu__label {
  font-family: var(--display);
  font-size: 30px;
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.menu__item:hover .menu__label {
  color: var(--water);
}

/* One line: a page's hint is the heading its text opens with, which can be
   longer than the sheet is wide. */
.menu__hint {
  overflow: hidden;
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
}

.menu__item--big .menu__hint {
  font-size: 12.5px;
}

/*
 * The settings sink into a foot: the page's own ground, a full rule over it,
 * and running out to both edges and down past the bottom one. What separates
 * doing from setting is the material, not only a line — a hairline between
 * "privacy" and "taal" read as one more line between buttons.
 */
.menu__foot {
  display: flex;
  flex-direction: column;
  margin: 8px calc(var(--gutter) * -1) 0;
  padding: 2px var(--gutter) calc(10px + env(safe-area-inset-bottom, 0px));
  background: var(--ground);
  border-top: 1px solid var(--line);
}

.menu__pref {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 0;
}

.menu__pref + .menu__pref {
  border-top: 1px solid var(--line);
}

.menu__pref-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.menu__cap {
  font-size: 13px;
  line-height: 1.3;
  color: var(--muted);
}

.menu__value {
  font-size: 16px;
  line-height: 1.3;
  color: var(--ink);
}

/* Every mode's word is in the markup and the one data-theme-mode names is
   shown. For auto the word says what the browser is asking for too, and that
   half is prefers-color-scheme's. */
.menu__theme-value [data-mode] {
  display: none;
}

:root[data-theme-mode="light"] .menu__theme-value [data-mode="light"],
:root[data-theme-mode="dark"] .menu__theme-value [data-mode="dark"],
:root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) .menu__theme-value [data-mode="system-light"] {
  display: inline;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) .menu__theme-value [data-mode="system-light"] {
    display: none;
  }

  :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) .menu__theme-value [data-mode="system-dark"] {
    display: inline;
  }
}

/*
 * 743px again, the breakpoint the register, the bottom sheet and site.js all
 * share. The header keeps its brand on the left and the burger on the right,
 * and everything else in it goes into the menu.
 */
@media (max-width: 743px) {
  .site-header--menu {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 14px;
    padding: 22px var(--gutter) 16px;
  }

  .site-header--menu .site-header__brand {
    flex: 1 1 auto;
    min-width: 0;
  }

  .site-header--menu .site-header__aside {
    display: none;
  }

  html:has(.site-header--stays) {
    scroll-padding-top: calc(120px + var(--offer-h));
  }

  /* The navigation bar folds into the phone's header: 60px, the logo and
     the round menu button, which holds the navigation and the button. */
  .site-header--nav {
    align-items: center;
    min-height: 60px;
    padding: 0 var(--gutter);
  }

  .nav-mark {
    font-size: 22px;
  }

  .site-nav,
  .nav-submit {
    display: none;
  }

  .page-name {
    margin-top: 24px;
    padding: 0 var(--gutter);
    font-size: 34px;
  }

  /* It keeps the gutter itself, as every part of a phone's page does — the
     start page, a word's page, de lijst and /submit run to the edge — and
     leaves it to main only where main keeps one (below). */
  .site-foot {
    margin-top: 72px;
    padding: 0 var(--gutter) 44px;
  }

  .site-foot__top {
    padding: 36px 0 28px;
  }

  .site-foot__up {
    width: 44px;
    height: 44px;
  }

  .site-foot__bottom {
    padding-top: 0;
    border-top: 0;
  }

  .site-foot__nav {
    flex-direction: column;
  }

  /* The lists under each other, the label over them. */
  .elsewhere--band,
  .elsewhere--band .elsewhere__lists {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  /* In the menu, on a phone. */
  .bubbles {
    display: none;
  }

  /* A text page, /privacy, the 404 and /admin keep the gutter on main. */
  :is(.text-page, .privacy, .lost, .page--wide) .site-foot {
    padding-inline: 0;
  }

  .menu {
    display: block;
    flex: 0 0 auto;
  }

  html:has(.menu[open]) {
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  .menu__sheet,
  .menu[open] > .menu__burger::before {
    animation: none;
    transition: none;
  }

  /* The admin band's burger still arrives and goes, it just stops fading
     and sliding. The shadow was never animated. */
  .admin-bar .bar-menu {
    transition: none;
  }
}

/* ---------- admin ---------- */

/*
 * /admin's tables need more room than a column of text, so the design gives
 * them a slightly wider canvas. The layout puts the modifier on .page.
 */
.page--wide {
  max-width: 1180px;
}

.admin-title {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(32px, 5vw, 44px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.022em;
  color: var(--ink);
}

/* Arrow and text on one centre line; as plain inline content the arrow would
   sit on the baseline. The underline is always there so nothing shifts when it
   colours in on hover. */
.back-link {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 7px;
  padding-bottom: 1px;
  border-bottom: 1px solid transparent;
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
}

.back-link:hover {
  color: var(--ink);
  border-bottom-color: var(--rule);
}

/* The count in each /admin header — entries, today's votes, rows waiting. */
.count {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

/*
 * The four admin pages, as one segmented control: a band a shade darker than
 * the ground with the page you are on filled in. Links, so they work with no
 * script — the design draws buttons because a canvas has no pages to go to.
 *
 * width: fit-content rather than the design's inline-flex. The two shrink to
 * the same size, but an inline-level box sits on a text line and drags a
 * descender's worth of space under it, which would put the margin below out by
 * a few pixels for no reason anyone could see in the markup.
 *
 * 4px around 3px is one radius, not two: the strip's padding is 1px wider than
 * its border, so the pill inside it stays concentric.
 */
/*
 * The bar that stays on /admin: the tab strip, and on a narrow screen the
 * burger that arrives once the header has gone. Sticky at the top, at z-index
 * 8: above the rows that scroll under it, below a non-modal dialog (10).
 *
 * The strip's own margin lives here. Left on .admin-tabs it would collapse
 * through a padding-less wrapper and stand the band eight pixels short of
 * where .row--head expects it.
 */
.admin-bar {
  position: sticky;
  top: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0 16px;
  background: var(--ground);
  box-shadow: var(--ground-reach);
}

/*
 * /admin's burger sits in the header, where the canvas draws it, and only
 * below 743px — the display rules it follows are .menu's own. Wide, the header
 * keeps its row of controls and there is nothing to fold away; narrow, the row
 * goes and the sheet carries the same things. Once the header scrolls away,
 * .bar-menu in the band takes over.
 */
.menu--admin {
  align-self: flex-start;
}

/* A band of pills, the chosen one filled: the tab strip, and the import's
   choice of what to do with the notes (.import-segment). */
.admin-tabs,
.import-segment {
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--wash);
}

.admin-tabs {
  display: flex;
  flex: 0 1 auto;
  align-items: center;
  gap: 4px;
  width: fit-content;
  min-width: 0;
  max-width: 100%;
  padding: 4px;
  overflow-x: auto;
}

/* It never grows — a strip stretched over 1180px would undo the band above,
   which is a ground shrunk to what it holds. It does shrink under its own
   content when the burger takes width beside it, and then overflow-x carries
   the tabs sideways rather than pushing the burger off the edge. */

.admin-tabs__tab {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 14px;
  border-radius: var(--radius);
  font-size: 14px;
  letter-spacing: 0.01em;
  white-space: nowrap;
  color: var(--muted);
  text-decoration: none;
}

.admin-tabs__tab:hover {
  color: var(--ink);
}

/* Filled, not coloured. The tab used to take the accent because it stood on
   the page's own ground with nothing but colour to say which one it was; on a
   band of its own the fill says it, and the accent goes back to meaning a
   link. */
.admin-tabs__tab[aria-current="page"],
.admin-tabs__tab[aria-current="page"]:hover,
.import-segment__option:has(input:checked) {
  background: var(--ink);
  color: var(--on-water);
}

.admin-tabs__badge {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

/* Quieter than the label without being a second colour: the same ink, thinned.
   Mixed from --on-water rather than given a value per palette, so it follows
   both from the one token it is made of. */
.admin-tabs__tab[aria-current="page"] .admin-tabs__badge {
  color: color-mix(in srgb, var(--on-water) 66%, transparent);
}

/*
 * The rule under the header and the strip are two edges a few pixels apart,
 * and only one of them is doing anything: the strip has a ground of its own
 * and separates the header from the page by being there. So on the pages that
 * carry it, the header stops at the words.
 *
 * Written as :has rather than a class on the headers because that is the
 * actual condition — the rule goes exactly where the strip replaces it, and a
 * new admin page cannot forget to say so. A general sibling and not the
 * next one, because .admin-float stands between the two.
 */
.site-header:has(~ main .admin-tabs) {
  padding-bottom: 14px;
  border-bottom: 0;
}

/*
 * The header's own row — the count, "nieuw woord", the theme — stays when the
 * header goes, and comes to rest at the right end of the band, level with the
 * tab strip (design canvas "Watermerken", admFloatStyle). It cannot be in the
 * header: nothing sticky outlives the box it is in, and the header scrolls
 * away. So it stands straight after it, a layer with no height, and puts the
 * row back where the header had it.
 *
 * Anchored to the header's foot and not its head, which is what keeps a header
 * height from being written down anywhere. The canvas measures one in script; this needs
 * none, and holds with the script off. The row stands on the header's bottom
 * padding, 14px above this layer, and the layer sticks at 63px: that puts the
 * row's 38px between 11 and 49, centred on the strip, whose middle is the
 * band's 8px padding and half of its 44px. Change the padding, the strip or
 * the buttons and this number moves with them. min-height holds the 38px when
 * the row has no button: without script /admin/votes and /admin/submissions
 * carry only their count, the theme toggle being js-only.
 *
 * Above the band, which is sticky too and later in the document. Below 10 for
 * .dialog's reason: "nieuw woord" opens one, and a no-script dialog is not
 * modal and has to cover this where the two meet.
 *
 * Wide only. Below 743px the row is folded into the menu, and the burger keeps
 * the arrangement it has always had — see .bar-menu.
 */
.admin-float {
  position: sticky;
  top: 63px;
  z-index: 9;
  height: 0;
}

.admin-float > .site-header__aside {
  position: absolute;
  right: 0;
  bottom: 14px;
  flex-wrap: nowrap;
  min-height: 38px;
}

/* The heading row carried the space under the header on its own. With the band
   above it that space is already there, and stacking the two opens a gap.
   The row is a nephew of the band rather than its sibling, because it sits
   inside the element a sort swaps the table into — the form the bulk bar posts
   on /admin/submissions, a plain div on /admin. Same gap, one selector
   further. The band is what this names, not the strip inside it: wrap either
   of the two in anything else and the gap comes back. */
.admin-bar + div > .row--head,
.admin-bar + form > .row--head {
  margin-top: 0;
}

/* ---------- the admin list ---------- */

/*
 * No card around the rows: they sit straight on the ground the way the
 * register's do, and the column headings are ruled off with the one heavy
 * line on the page.
 */
.row {
  display: grid;
  gap: 14px;
  align-items: center;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.18s ease;
}

/*
 * The register's own row: one trademark. Each row is a grid of its own, so
 * no column can follow what is in it; the widths are set here, and what does
 * not fit is reachable from the title on each cell.
 *
 * The name is fixed at 150px: the longest so far, Beautyblender, is about 130
 * at this size, and as a share of the width it stood in 200 to 240px of which
 * a hundred were empty, while the holders — often a sentence long — were cut
 * off. The holder and the words share the rest; the words have a floor that
 * keeps a long chip ("hook-and-loop fastener" and its share) whole from
 * 744px on, and the holder one that keeps it from vanishing beside them.
 *
 * The date's column is fixed, so its heading has to fit whole: "Toegevoegd"
 * in spaced capitals with the arrow's room after it is about 110px, and at
 * 108 it was always cut off. 120 leaves Firefox's metrics a little over.
 */
.row--mark {
  /* Holds the band every row is lit on, below. */
  position: relative;
  grid-template-columns:
    150px minmax(64px, 1fr)
    minmax(200px, 1.2fr) 120px 56px;
}

.row:hover {
  background: var(--wash);
}

/* The row the dialog is open on. */
.row--active {
  background: var(--wash);
}

/*
 * Pinned directly under the band, because sorting by a column you can no
 * longer see is the thing this phase is for. --admin-bar is exact rather than
 * a floor: a gap or an overlap would both show, and unlike a header a tab
 * strip cannot grow — one line of pills at a fixed height inside a fixed
 * padding, with overflow-x: auto making sure it never wraps. Wide and narrow
 * both come to 68px, from different numbers.
 *
 * Written .row.row--head so it outranks .row--mark's position: relative on
 * weight rather than on source order. That relative is only there to hold the
 * band the rows are lit on, which :not(.row--head) already keeps off this one.
 */
.row.row--head {
  position: sticky;
  top: var(--admin-bar);
  z-index: 7;
  margin-top: 26px;
  border-top: 1.5px solid var(--ink);
  border-bottom: 0;
  background: var(--ground);
  box-shadow: var(--ground-reach);
}

/* Its own ground, not none: transparent, the rows would show through it as
   they pass under. */
.row--head:hover {
  background: var(--ground);
}

/*
 * Every ground a row of /admin or of the queue can be on — under the pointer,
 * ticked (the queue's, below), or the one the dialog is open on — is one layer
 * behind it, reaching 12px past the columns at both ends.
 *
 * Wider than the columns because the first and the last control sit at the
 * ends of the grid: a band that stopped at the columns would run straight
 * through them and leave both against an edge. Behind rather than
 * as a background because the row's own box is where the rule under it is, and
 * widening that would rule the list off wider than the heading over it. Nothing
 * on this page paints between the two, so a negative z-index puts the band under
 * the content without burying it under the page.
 *
 * The layer replaces .row's own background, so the two rules the row inherits
 * are turned off here — both are outranked from this point on source order
 * alone.
 */
.row--mark:not(.row--head)::before,
.row--queue:not(.row--head)::before {
  content: "";
  position: absolute;
  inset: 0 -12px;
  z-index: -1;
  border-radius: var(--radius);
  transition: background 0.18s ease;
}

.row--mark:hover,
.row--mark.row--active,
.row--queue:hover,
.row--queue.row--active {
  background: transparent;
}

.row--mark:not(.row--head):hover::before,
.row--queue:not(.row--head):hover::before {
  background: var(--wash);
}

/* The row the dialog is open on. After the hover, so it does not tie with it:
   without script the dialog is not modal — the server renders it with [open]
   — and the list behind it can still be hovered, which would otherwise wipe
   this shade off the one row the dialog is about. */
.row--mark.row--active:not(.row--head)::before,
.row--queue.row--active:not(.row--head)::before {
  background: var(--wash);
}

/* With script a click anywhere on a mark's row opens it. Without, only the
   chips and the pencil do, and a pointer would promise the rest. */
:root.js .row--mark:not(.row--head) {
  cursor: pointer;
}

/* The column headings are the sort control; the arrow marks the active one. */
.row__sort {
  display: inline-flex;
  align-items: baseline;
  justify-self: start;
  /* A heading is as narrow as its column now that the column has a floor
     rather than a zero: it ellipsises like the cells under it, and carries the
     same title. */
  min-width: 0;
  max-width: 100%;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  font-size: 13px;
  white-space: nowrap;
  color: var(--muted);
  text-decoration: none;
}

.row__sort:hover {
  color: var(--ink);
}

.row__sort[aria-current="true"] {
  color: var(--ink);
  border-bottom-color: var(--water);
}

.row__sort-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Always in the flow and always as wide, so nothing shifts sideways when the
   arrow appears — the same trick the register's sort bar uses. Without the
   width the empty span was nothing, and in the narrow strip every heading
   after the one chosen moved over by an arrow. flex: 0 0 auto keeps it out of
   the ellipsis: it is the label that gives way, never the mark saying which
   way the column runs. */
.row__sort-arrow {
  flex: 0 0 auto;
  width: 0.7em;
  margin-left: 4px;
  font-size: 11px;
  color: var(--water);
}

.row__term {
  font-family: var(--display);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* The brand is what the register keeps covered. Here — the one page where it
   is never hidden — it carries the accent. A link, the review's, which a
   narrow card is opened by. */
.row__brand {
  font-size: 14.5px;
  color: var(--water);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* A submission's holder is on its narrow card only; wide there is no column
   for it. */
.row--queue .row__owner {
  display: none;
}

/*
 * Owner, category and year are three grid columns on a wide screen and one
 * wrapping line on a narrow one. display: contents lets the wrapper step out
 * of the way so the three spans land in their own columns; the narrow block
 * below turns it back into a real box.
 */
.row__facts {
  display: contents;
}

.row__owner {
  font-size: 14px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row__category {
  font-size: 13px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}


.row__added {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

/* An empty cell reads as an em dash, dimmer than a filled one. */
.row__none {
  color: var(--faint-2);
}

/* The full stamp spells out what a bare date would only mean under a column
   heading, so it belongs to the narrow row, which has none. */
.row__stamp {
  display: none;
}

.row__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.icon-btn {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
}

.icon-btn:hover {
  color: var(--ink);
  border-color: var(--rule);
}

.icon-btn--danger:hover {
  color: var(--danger);
  border-color: var(--danger);
}

.admin-empty {
  padding: 80px 0;
  text-align: center;
  font-size: 15px;
  color: var(--muted);
}

/* ---------- a trademark and its words ---------- */

/* The name and the holder: out of the way on a wide screen, a line of its own
   on a narrow one. */
.row__lead {
  display: contents;
}

/* The mark as registered, in the accent the brand carries on this page. A
   link, the pencil's, which a narrow card is opened by; it reads as a name. */
.row__mark {
  min-width: 0;
  font-family: var(--display);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--water);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row__words {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.row__words-head {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

/*
 * A word on its mark's row, and the way into it: the dialog, on that word's
 * register. Its code is small capitals rather than a .lang-pill — a filled box
 * inside a box — and comes first, so the ellipsis on a long term never takes it.
 *
 * The chip's ground is one rung up the row's own ladder, so it does not sink
 * into the band when the pointer lights the row, and it turns to the accent
 * under the pointer because it is the part of the row that answers a click.
 *
 * /admin/pages draws a page's languages with it too, as the one link it is
 * here; the marks' list has the two-part chip below.
 */
.word-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  height: 24px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--wash);
  font-size: 13px;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.row--mark:hover .word-chip {
  background: var(--row-chosen);
}

.word-chip:hover {
  border-color: var(--water);
  color: var(--water);
}

/*
 * A word on a mark's row: two halves in one edge, the word, a link, and after
 * a thin rule its percentage, a button with a card. Either under the pointer
 * lights the edge; only the half itself takes the accent, since the two answer
 * differently — so the word's half has its ink of its own rather than the
 * chip's. Its bottom edge is the split as a meter, which is why the chip is
 * 2px taller than its words need and the halves leave those 2px free.
 */
.word-chip--votes {
  position: relative;
  align-items: stretch;
  gap: 0;
  height: 26px;
  padding: 0;
}

.word-chip__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  padding: 0 8px 2px;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.18s ease;
}

.word-chip__link:hover {
  color: var(--water);
}

/* The number never shrinks: on a chip too narrow for both, the ellipsis is
   the term's. */
.word-chip__votes {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  padding: 0 8px 2px 7px;
  border: 0;
  border-left: 1px solid var(--line);
  background: none;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  cursor: help;
  transition: color 0.18s ease;
}

/* Under the threshold (VotingOptions): a number the visitor is not shown yet, resting
   on a handful of votes. */
.word-chip__votes--few {
  font-style: italic;
  color: var(--muted);
}

.word-chip__votes:hover {
  color: var(--water);
}

/*
 * A split drawn small, on the chip and in its card: from the left edge to
 * --split is "merk", from there to the right edge "verwaterd", the way
 * the vote bar fills. One element and a gradient with a hard stop, so there is
 * no seam to place.
 */
.vote-meter {
  --meter-ground: var(--rule);
  --meter-fill: var(--water);
  display: block;
  background: linear-gradient(to right, var(--meter-ground) var(--split), var(--meter-fill) var(--split));
}

/* Under the threshold (VotingOptions): the same split, lighter, as the number beside
   it is set apart. */
.vote-meter--few {
  --meter-fill: color-mix(in oklab, var(--water) 34%, var(--ground));
}

/* Over the chip's bottom edge, in the 2px the halves leave free. It takes no
   pointer, so a click on it is still the half's above it. */
.word-chip__meter {
  position: absolute;
  right: -1px;
  bottom: -1px;
  left: -1px;
  height: 3px;
  border-radius: 0 0 2px 2px;
  pointer-events: none;
}

/* The card behind the percentage. It hangs in the DOM inside the chip and
   would inherit the chip's line from there. A width of its own, so the meter
   in it is one length on every word, and the counts under it and the last
   vote each keep to one line — written with .markup-tip, whose max-content
   comes later in the file. On a phone site.js moves it along to fit rather
   than narrowing it. */
.markup-tip.vote-tip {
  width: 300px;
  font-size: 13px;
  font-style: normal;
  text-align: left;
  white-space: normal;
}

/* The share, and "Omstreden" against the right edge. */
.vote-tip__line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

/* The meter and what it is made of, closer together than the card's lines. */
.vote-tip__split {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.vote-tip__meter {
  --meter-ground: var(--line);
  height: 6px;
  border-radius: 1px;
}

.vote-tip__ends {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

/* The side the fill runs to, in the colour it runs in — as the lemma's cases. */
.vote-tip__for {
  color: var(--water);
}

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

/* The space after it is the card's 13px one, lost beside a number this size. */
.vote-tip__percent {
  margin-right: 0.12em;
  font-family: var(--display);
  font-size: 26px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}

.vote-tip__percent--few {
  font-style: italic;
  color: var(--muted);
}

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

.word-chip__code {
  flex: 0 0 auto;
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.word-chip__term {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/*
 * A language, labelled: the tag on a term in the queue, on a contested term and
 * in the review dialog's title, where it says which register that row is in.
 * First in the cell, so the ellipsis on a long term never takes it, and
 * followed by a real space rather than only a margin, so a screen reader says
 * "en hot tub" and not "enhot".
 */
.lang-pill {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 7px;
  border: 1px solid var(--ink);
  border-radius: 2px;
  background: var(--ink);
  /* Named because it also sits inside a term and a dialog title, both of which
     are set in the display face at 600. */
  font-family: var(--body);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  vertical-align: 0.25em;
  color: var(--ground);
}

/* ---------- the admin list on a narrow screen ---------- */

/*
 * The row stops being a table and becomes a card: its lead, its words, and
 * its stamp last; the actions go, and the card opens by its name's link,
 * stretched over it.
 *
 * 743px is the same breakpoint site.js asks. Keep the two in step.
 */
@media (max-width: 743px) {
  /* The register runs edge to edge here; the admin list keeps its gutter, so
     the page carries it and the header stops repeating it. */
  .page--wide {
    padding: 0 var(--gutter) 100px;
  }

  /* The same trade a public header makes: the row of controls goes into the
     sheet, and what is left — the title, the way back, the burger — stands on
     one line rather than in the column the generic rule stacks it into. */
  .page--wide .site-header {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 14px;
    padding: 28px 0 22px;
  }

  .page--wide .site-header__aside {
    display: none;
  }

  /* Same trade as the wide screen, a little tighter, and the taller pill a
     thumb needs. */
  .site-header:has(~ main .admin-tabs) {
    padding-bottom: 10px;
  }

  .admin-float {
    display: none;
  }

  .admin-bar {
    padding: 6px 0 14px;
  }

  .admin-tabs__tab {
    height: 38px;
    font-size: 14.5px;
  }

  /* The counts and the strip's badges are two ways of saying the same number,
     and on a phone only one of them fits. The tab keeps its word. */
  .admin-tabs__badge {
    display: none;
  }

  .row {
    row-gap: 3px;
    column-gap: 14px;
    padding: 16px 0;
  }

  /*
   * A row is a card here (design canvas "Stembalk in beheer", rounds 3–6):
   * one per mark, submission or page, on the ground with room between them,
   * where rows that ran into each other made it hard to tell which line
   * belonged to which. No buttons: the name is the card's link, stretched
   * over it below. Written .row.row--… so it outranks the bands the wide
   * rows are lit on, which come later in the file — a card has its own
   * ground and needs none.
   */
  .row.row--mark:not(.row--head),
  .row.row--queue:not(.row--head) {
    margin-top: 10px;
    padding: 14px 16px 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--ground);
  }

  .row.row--mark:not(.row--head)::before,
  .row.row--queue:not(.row--head)::before {
    content: none;
  }

  /* The one the dialog is open on, which only shows without script, where
     the dialog is not modal. */
  .row.row--mark.row--active:not(.row--head),
  .row.row--queue.row--active:not(.row--head) {
    border-color: var(--water);
  }

  /* The name or the brand is the card's way in, with script and without:
     a link over the whole card, under the chips and the page's one button,
     which are links of their own. */
  .row--mark .row__mark::after,
  .row--queue .row__brand::after {
    content: "";
    position: absolute;
    inset: 0;
  }

  /* Over the link, but only where a chip is: the room beside the chips is
     the card's. */
  .row--mark .row__words {
    position: relative;
    z-index: 1;
    pointer-events: none;
  }

  .row--mark .row__words > * {
    pointer-events: auto;
  }

  .row--mark .row__actions,
  .row--queue .row__actions,
  .row__edit {
    display: none;
  }

  /* The queue's card as a mark's: the brand and its holder, the term with
     its language under them, and the foot. */
  .row--queue {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "lead"
      "term"
      "stamp";
  }

  /* The mark with its holder after it, then its words, then the foot. */
  .row--mark {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "lead"
      "words"
      "stamp";
  }

  /* The holder beside the name on their shared baseline, and under it only
     when the two do not fit. */
  .row__lead {
    grid-area: lead;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 2px 12px;
    min-width: 0;
  }

  .row__lead > .row__owner {
    font-size: 14px;
    color: var(--muted);
    overflow: visible;
    white-space: normal;
  }

  .row__mark,
  .row--queue .row__brand {
    font-family: var(--display);
    font-size: 26px;
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.018em;
    white-space: normal;
  }

  .row__words {
    grid-area: words;
    margin-top: 8px;
  }

  /* Something a thumb aims at now, not only something to read — both
     halves of a mark's word. */
  .word-chip {
    height: 32px;
    padding: 0 11px;
    font-size: 14px;
  }

  .word-chip--votes {
    height: 34px;
    padding: 0;
  }

  .word-chip__link {
    padding: 0 11px 2px;
  }

  .word-chip__votes {
    padding: 0 11px 2px 10px;
    font-size: 13px;
  }

  .word-chip__code {
    font-size: 10px;
  }

  /* An em-dash under no column heading says nothing, so an empty cell simply
     goes. The queue's category is not on its card. */
  .row--mark .row__none,
  .row--queue .row__facts {
    display: none;
  }

  .row--head .row__words-head {
    display: none;
  }

  .row--head .row__sort-first {
    order: -1;
  }

  /* Sorts on what a card does not show: the queue's category and sender, a
     page's lead. Wide they are columns and keep their headings. */
  .row--head .row__sort-wide {
    display: none;
  }

  /* The queue's first heading cell holds the column of boxes, which has
     gone; left in, it stood as a gap after the brand that now leads. */
  .row--head.row--queue > span:first-child {
    display: none;
  }

  /* The term under the brand, in the body face: the brand is what a card
     is about, as on /admin, and the black label keeps the language small. */
  .row__term {
    grid-area: term;
    margin-top: 6px;
    font-family: var(--body);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.4;
    letter-spacing: normal;
    color: var(--ink);
    white-space: normal;
  }

  .row__term .lang-pill {
    vertical-align: 0.1em;
  }

  .row--queue .row__owner {
    display: inline;
  }

  /* Back to a real box, so the three facts share one line instead of one
     column each. The 5px lifts the gap from the 3px above to the 8px the
     design puts between the name and the facts. */
  .row__facts {
    grid-area: facts;
    display: flex;
    flex-wrap: wrap;
    gap: 4px 14px;
    margin-top: 5px;
  }

  .row__facts > span {
    font-size: 13px;
    color: var(--muted);
    overflow: visible;
    white-space: normal;
  }

  /* The long forms take over; there are no column headings to lean on. */
  .row__added {
    display: none;
  }

  /* The card's foot, under a dotted rule: one quiet line in sentence case,
     where it was a second line in capitals; the queue's badge at its end. */
  .row__stamp {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    grid-area: stamp;
    margin-top: 12px;
    padding-top: 9px;
    border-top: 1px dotted var(--line);
    font-size: 12px;
    line-height: 1.45;
    color: var(--muted);
  }

  .row__actions {
    grid-area: actions;
    align-self: start;
  }

  .row__actions .icon-btn {
    width: 42px;
    height: 42px;
  }

  .row__actions .icon-btn svg {
    width: 18px;
    height: 18px;
  }

  /* Stacked rows label themselves, so the heading row drops the grid and keeps
     only its links — a compact sort strip, and the one way to sort here. */
  .row--head {
    display: flex;
    align-items: center;
    gap: 16px;
    overflow-x: auto;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
  }

  .row--head > span:last-child {
    display: none;
  }
}

/* ---------- dialog ---------- */

/*
 * While the dialog is open the page behind it holds still; only the dialog's
 * own middle scrolls. Keyed off [open], which the server sets on the no-script
 * path and showModal() sets on the scripted one, so one rule covers both and
 * none of it needs script.
 *
 * The gutter is held open for every page further up, so the page behind does
 * not shift sideways by a scrollbar width as the dialog arrives.
 */
html:has(.dialog[open]) {
  overflow: hidden;
}

.dialog {
  width: min(660px, calc(100vw - 32px));
  max-height: 88vh;
  padding: 0;
  /*
   * clip rather than hidden. Both cut the corners off the head and the foot,
   * but `hidden` leaves the box a scroll container — one nothing can reach by
   * hand, and one the browser will still scroll itself to bring a focused
   * descendant into view. That is what let a click on a chip drag the head out
   * of the box and leave a band of empty surface under the foot. `clip` makes
   * no scroll container at all, so there is nothing to scroll; the middle,
   * which is meant to scroll, has its own overflow.
   */
  overflow: clip;
  background: var(--ground);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

/*
 * The insides are swapped in one piece, so admin.js needs one element to put
 * them in — and that element must not become a box. As a box it is the dialog's
 * only flex child, and the head, the body and the foot stop being flex items:
 * the body no longer shrinks to fit and everything under it is clipped away by
 * the overflow above. Same reason [data-results] is display: contents on the
 * register.
 */
.dialog > [data-dialog-content] {
  display: contents;
}

/* The delete question stands on its own and needs far less room. */
.dialog--confirm {
  width: min(460px, calc(100vw - 32px));
}

/*
 * On a phone the drawer stops short of the top, so the page it was opened from
 * is still standing behind it and it is clear where this goes back to. Design canvas "Aandragen smal 5d": three short steps exist so that this is
 * possible at all. Only the drawer — /admin's dialogs open over a list that has
 * nothing to show above them, and they keep the 94vh the narrow block gives.
 *
 * dvh rather than vh, because Safari's floating toolbar is exactly the thing
 * that would otherwise eat the gap this is reserving.
 */
@media (max-width: 743px) {
  .dialog--drawer {
    max-height: calc(100dvh - 64px);
  }
}

.dialog::backdrop {
  background: var(--scrim);
}

/*
 * Without JavaScript the dialog renders inline with [open]; centre it by hand
 * so the no-script path looks the same as showModal().
 *
 * `display` is the only one of these that hangs on [open], and it has to: the
 * browser's own stylesheet hides a closed <dialog> with display: none, and an
 * author rule on .dialog would outrank it and leave the thing on screen.
 *
 * Everything that *places* the box sits on .dialog instead, because [open] is
 * gone the instant it closes — and a box that loses its position, its offsets
 * and its stacking order in that instant is somewhere else entirely by the time
 * it starts to leave, however long the transition below holds it on screen.
 * None of it applies until it opens anyway: a closed dialog is display: none.
 */
.dialog {
  flex-direction: column;
  position: fixed;
  top: 12vh;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  z-index: 10;
}

.dialog[open] {
  display: flex;
}

/*
 * A dialog arrives and leaves the way the register's sheet does. It cannot use
 * the sheet's own animation: that one runs on an element being put into the
 * document and taken out of it, while a <dialog> is toggled in the top layer
 * and close() would otherwise take it off screen in the same frame. So the
 * mechanism is the one this element actually has — @starting-style for the way
 * in, and for the way out a class (.is-closing) that site.js waits on before
 * it closes the dialog — and what is shared with the sheet is the distance and
 * the timing above.
 *
 * The movement is written as `translate` and not as `transform`, because the
 * transform is already spent on centring the thing.
 */
.dialog {
  opacity: 0;
  translate: 0 12px;
  transition:
    opacity var(--sheet-fade) ease,
    translate var(--sheet-rise) var(--sheet-ease);
}

.dialog[open] {
  opacity: 1;
  translate: 0 0;
}

/*
 * On its way out, put there by site.js — which then waits for this to finish
 * before closing the dialog for real. Discrete transitions of display and
 * overlay could do the same, but only in Chrome, where they also kept a
 * closed dialog on screen, still taking clicks, a moment longer; this way it
 * leaves alike everywhere. It has to sit after the rule above: same weight,
 * so it is source order that lets it win while the dialog is still open.
 */
.dialog.is-closing {
  opacity: 0;
  translate: 0 12px;
}

@starting-style {
  .dialog[open] {
    opacity: 0;
    translate: 0 12px;
  }
}

/* The scrim fades with it rather than snapping on. */
.dialog::backdrop {
  opacity: 0;
  transition:
    opacity var(--sheet-fade) ease;
}

.dialog[open]::backdrop {
  opacity: 1;
}

/* And fades again on the way out. Below the rule above rather than beside the
   rest of .is-closing: the two weigh the same, so this only wins from here —
   above it, the scrim stayed put until the dialog had gone and then dropped in
   one frame, which is the one thing this whole arrangement is against. */
.dialog.is-closing::backdrop {
  opacity: 0;
}

@starting-style {
  .dialog[open]::backdrop {
    opacity: 0;
  }
}

/*
 * Wide, Woord aandragen is a drawer: it stands the window's full height against
 * the right edge and comes in from there, so the page it was opened from stays
 * in sight beside it (canvas "Nieuwe look voorstellen", B-aandragen). The way
 * in and out are the dialog's own, turned sideways; each rule weighs what the
 * one it answers weighs, so it is source order that lets these win. On a phone
 * the drawer is a sheet like every other dialog.
 */
@media (min-width: 744px) {
  .dialog--drawer {
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    transform: none;
    width: min(520px, 100vw);
    max-width: none;
    height: 100dvh;
    max-height: none;
    border: 0;
    border-left: 1px solid var(--line);
    border-radius: 0;
    translate: 100% 0;
  }

  .dialog--drawer[open] {
    translate: 0 0;
  }

  .dialog--drawer.is-closing {
    translate: 100% 0;
  }

  @starting-style {
    .dialog--drawer[open] {
      translate: 100% 0;
    }
  }
}

/*
 * Without motion the dialog drops the movement and the fade. After the
 * transition it takes away: before it, the same weight lost, and every dialog
 * still slid and faded.
 */
@media (prefers-reduced-motion: reduce) {
  .dialog {
    transition: none;
  }

  .dialog::backdrop {
    transition: none;
  }
}

/*
 * The grabber, defined once for both surfaces that draw one. The menu has a
 * real element for it; the dialog draws it as a pseudo-element, because
 * otherwise both pages that open one would have to grow a div for it in
 * markup. Same pill either way.
 */
.menu__grip::after,
.dialog::before {
  content: "";
  width: 54px;
  height: 5px;
  border-radius: 3px;
  background: var(--rule);
}

/* A dialog is only a sheet on a narrow screen, so its grip only exists there. */
.dialog::before {
  display: none;
}

.dialog__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid var(--line);
}

.dialog__title {
  margin: 0;
  font-family: var(--display);
  font-size: 28px;
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.018em;
  color: var(--ink);
}

.dialog__subject {
  display: block;
  margin-top: 4px;
  font-size: 13.5px;
  color: var(--muted);
}

/* The title with a line beside it rather than under it: a page's address and
   where it stands, a review's mark and what publishing it will do. */
.dialog__heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 14px;
}

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

/* Over the title rather than under it. /admin names the dialog and then says
   which mark it holds; the review says which of its two steps this is. */
.dialog__kicker {
  display: block;
  margin-bottom: 4px;
  font-size: 13px;
  color: var(--muted);
}

.icon-btn--close {
  width: 34px;
  height: 34px;
}

/* The form itself is the dialog's scrolling middle, so the head and the foot
   stay put while a long note scrolls. */
.dialog__body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px 24px;
  overflow-y: auto;
  /* The wheel stops here. Without it, scrolling past the end of a long note
     carries on into the page behind — which the lock on <html> does not catch,
     because chaining is not the visitor scrolling the document. */
  overscroll-behavior: contain;
}

/* The foot, and the question a dialog asks before letting go of something
   unsaved (below), which takes its place and is drawn the same way, so the
   dialog does not change shape while it asks. */
.dialog__foot,
.dialog__unsaved {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 24px 20px;
  border-top: 1px solid var(--line);
  background: var(--wash);
}

.dialog__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/*
 * The question takes the foot's place rather than sitting under it or over the
 * form: the buttons that would have saved or cancelled are what it stands in
 * for, and a second row of buttons under them would ask two things at once.
 */
.dialog__unsaved {
  flex: 0 0 auto;
}

.dialog.is-unsaved .dialog__foot,
.dialog.is-unsaved .submit__foot {
  display: none;
}

.dialog--drawer .dialog__unsaved {
  padding: 14px 26px 18px;
}

.dialog__unsaved-text {
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink);
}

/* The same 743px as the sheet itself: a thumb gets two whole-width buttons. */
@media (max-width: 743px) {
  .dialog__unsaved {
    flex-direction: column;
    align-items: stretch;
  }

  .dialog__unsaved .dialog__actions .btn {
    flex: 1 1 auto;
  }
}

/*
 * The delete question replaces the form rather than sitting under it, so the
 * dialog never shows the thing it is about to throw away — and so the question
 * is never read across a form scrolled to some arbitrary point, which is what
 * putting it under the foot turned out to mean once the dialog had a height to
 * run out of.
 */
.confirm {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 24px 20px;
}

.confirm__heading {
  margin: 0;
  font-family: var(--display);
  font-size: 26px;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.018em;
  color: var(--ink);
}

.confirm p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

/* The trademark's three fields, which are short and belong on one line. */
.form-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/*
 * The mark form's fields (_MarkForm): each one three rows of one subgrid —
 * label, input, a line under it — so that across a row of fields the three
 * line up. A label that wraps must not drop its input below its neighbours',
 * and a line appearing under one field (a refused save's message, a note)
 * must not lift it either. Which label wraps, if any, changes with the
 * language, the width and the marks beside it, so no fixed height would do.
 *
 * One gap for every row, which the subgrid takes over from the grid. A gap of
 * its own would differ from the grid's, and Chromium and Firefox settle that
 * difference a few pixels apart. The third row carries 4px of margin, so an
 * empty one leaves the 16px between one input and the next label that
 * .form-grid has everywhere else; the grid gives back the 10px it would add
 * under its last row.
 */
.form-grid--rows {
  row-gap: 6px;
  margin-bottom: -10px;
}

.form-grid--rows > .form-field {
  grid-row: span 3;
  display: grid;
  grid-template-rows: subgrid;
}

/* A grid item keeps its content's minimum width; a field may be narrower. */
.form-grid--rows > .form-field > input {
  min-width: 0;
}

/* Set as every label in a form is, and as tall as the mark beside it whether
   or not the mark is showing, so typing into a field never moves its input. */
.form-grid--rows > .form-field > label {
  align-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 17px;
  font-size: 13px;
  color: var(--muted);
}

.form-field__after {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
  margin-bottom: 4px;
}

/* A line under a field that is a way on rather than a message: the review's
   "laat het … weten". */
.field-note {
  font-size: 12.5px;
  line-height: 1.45;
}

/* Beside the label, in a thin box — it belongs to the field and not to the
   value, so it must not read as one. */
.field-tag {
  display: inline-flex;
  align-items: center;
  height: 17px;
  padding: 0 6px;
  border: 1px solid var(--rule);
  border-radius: 2px;
  background: var(--ground);
  font-size: 12px;
  color: var(--muted);
}

/* Nothing to say, and nothing to take up room either — otherwise every label
   would carry an empty box. */
.field-tag:empty {
  display: none;
}

/* The notes' label sits in a head beside "opmaak", and carries the same mark. */
.form-field__head > label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* What holds for every register, set apart from the panels that do not. */
.dialog__section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ---------- one panel per register ---------- */

/*
 * Tabs without a line of script. Each tab is a <label> wrapping its own radio,
 * and the panel it opens is its sibling, so both the strip and the panel follow
 * :checked, as many things on this site follow :has() rather than a script.
 *
 * Nothing here names a language. The wrapper is display: contents so that a
 * head and its body are both flex items of the strip; the heads take the first
 * line, the open body takes the second on its own, and the filler span carries
 * the rule on to the right of the last tab, which the heads cannot do between
 * them because they stop where their labels do.
 */
.form-tabs {
  display: flex;
  flex-wrap: wrap;
  column-gap: 2px;
}

.form-tab {
  display: contents;
}

.form-tab__head {
  order: 1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  margin-bottom: -1px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: var(--radius) var(--radius) 0 0;
  color: var(--muted);
  font-size: 13.5px;
  white-space: nowrap;
  cursor: pointer;
}

/* The tab sits over the rule the panel below draws, and the open one covers its
   own stretch of it in its own colour. That is what attaches a tab to its
   panel, and it is why the rule is the panel's and not a filler element's: a
   filler has to be the last thing on the strip's line, and a strip that wraps
   leaves it on the wrong one. */
.form-tab__head:has(.form-tab__radio:checked) {
  /* Lifted, or the panel paints its rule over it: a flex item is painted in
     the order its `order` gives it, and the panel's comes after the heads'. */
  position: relative;
  z-index: 1;
  background: var(--ground);
  border-color: var(--rule);
  border-bottom-color: var(--ground);
  color: var(--ink);
}

/* Filled where the register has a word; a plus where it has none. */
.form-tab__dot {
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ink);
}

.form-tab__plus {
  flex: 0 0 auto;
  color: var(--muted);
}

/* A register with no word yet is drawn as an outline rather than as a warning:
   missing is often the right answer. */
.form-tab__head--empty {
  color: var(--muted);
}

.form-tab__head--empty:has(.form-tab__radio:checked) {
  border-style: dashed;
  border-bottom-style: solid;
}

.form-tab__head:has(.form-tab__radio:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* The radio is the state and nothing else; the label is what is seen. */
.form-tab__note {
  font-size: 13px;
  color: var(--muted);
}

/* A step up on the open tab, as its name is: faint is as light as text goes,
   so the step is to muted rather than up from something lighter. */
.form-tab__head:has(.form-tab__radio:checked) .form-tab__note {
  color: var(--muted);
}

/* The open register's panel is set off from the mark above it: on the ground,
   from one edge of the dialog to the other and down to its foot, its tab
   standing on it in the same colour. The strip is the last thing in the
   dialog's scrolling middle in every dialog that has one, so it can reach
   over that middle's padding (22px 24px, .dialog__body) on three sides. */
.form-tabs {
  margin-bottom: -22px;
}

.form-tab__body {
  order: 2;
  flex: 0 0 calc(100% + 48px);
  display: none;
  flex-direction: column;
  gap: 16px;
  margin: 0 -24px;
  padding: 18px 24px 24px;
  background: var(--ground);
  border-top: 1px solid var(--rule);
}

.form-tab:has(> .form-tab__head > .form-tab__radio:checked) > .form-tab__body {
  display: flex;
}

/* The panel's foot: the 404 lines, folded away (_MarkForm, /admin only). */
.form-tab__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px 16px;
  padding-top: 2px;
}

/* The maintainer's own note under the explanation (_MarkForm, /admin only).
   It is warm; the stamp under the foot is not, because the register does
   show when a word came in. */
.form-field--private {
  padding: 12px 14px 14px;
  background: var(--private);
  border: 1px solid var(--private-line);
  border-radius: var(--radius);
}

.form-field--private .form-field__head > label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--private-ink);
}

/* The 404 lines, folded away behind a label holding a hidden checkbox
   (_MarkForm), and what it opens a line of the foot of its own under the
   label, shown while its box is ticked. Opening it changes the width of
   nothing on the row: a <details> did, being as wide as what it held. The
   count is the label's resting colour, so only the label darkens on hover. */
.fold-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 38px;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}

.fold-toggle:hover {
  color: var(--ink);
}

.fold-toggle svg {
  transition: transform 0.15s ease;
}

.fold-toggle:has(> [data-fold-toggle]:checked) svg {
  transform: rotate(90deg);
}

.fold-toggle:has(> [data-fold-toggle]:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
  border-radius: 2px;
}

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

.form-tab__foot > .lines-fold__field {
  display: none;
  flex: 0 0 100%;
}

.form-tab__foot:has(> .lines-toggle > [data-fold-toggle]:checked) > .lines-fold__field {
  display: flex;
}

/* A word's two example sentences, folded away beside the 404 lines
   (_MarkForm). The toggles share the foot's first line, and whatever
   they open comes under both, in the order they stand. */
.form-tab__foot > .fold-toggle {
  order: 0;
}

.form-tab__foot > .lines-fold__field,
.form-tab__foot > .examples-fold__field {
  order: 1;
}

.form-tab__foot > .examples-fold__field {
  display: none;
  flex: 0 0 100%;
  flex-direction: column;
  gap: 14px;
}

.form-tab__foot:has(> .examples-toggle > [data-fold-toggle]:checked) > .examples-fold__field {
  display: flex;
}

/*
 * When the word came in and when it last changed, one line under a dotted
 * rule at the end of the panel (_MarkForm), the way a mark's card on a phone
 * ends (.row__stamp). Each fact keeps to one line, so a narrow panel breaks
 * the line at the dot between them.
 *
 * The first date can be set and seldom is, so nothing points it out: no
 * chevron, the date only underlined while the pointer is on it. It is a label
 * holding a hidden checkbox, and ticked, the field stands where the date was.
 * The field is a .form-field, so it is drawn, coloured when empty, raised to
 * the 16px floor and stripped of Safari's own shape as every other one is;
 * hence the two classes on every rule here that has to outrank those.
 */
.word-stamp {
  padding-top: 9px;
  border-top: 1px dotted var(--line);
}

.word-stamp__line {
  margin: 0;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

.word-stamp__fact {
  white-space: nowrap;
}

.word-stamp__toggle {
  cursor: pointer;
}

.word-stamp__toggle:hover .word-stamp__date,
.word-stamp__toggle:has(:focus-visible) .word-stamp__date {
  color: var(--ink);
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

.word-stamp__toggle:has(:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
  border-radius: 2px;
}

.word-stamp__toggle:has(:checked) .word-stamp__date,
.form-field.word-stamp__field {
  display: none;
}

.word-stamp__fact:has(> .word-stamp__toggle :checked) > .form-field.word-stamp__field {
  display: inline-block;
  vertical-align: middle;
}

.form-field.word-stamp__field input {
  width: 160px;
  height: 30px;
  padding: 0 8px;
  font-size: 13px;
}

.word-stamp > .validation {
  display: block;
  margin-top: 4px;
}

.word-stamp > .validation:empty {
  display: none;
}

/*
 * A word's delete button, drawn in the dialog's foot beside Annuleren and
 * Opslaan though it stays in its own panel (_MarkForm): the foot is shared by
 * every register and could only be told which word is showing with language
 * codes written in here, while a button in a closed panel is hidden with it.
 * Placed against the dialog itself — nothing between the two is positioned,
 * and the scrolling middle does not clip what is placed against a box outside
 * it — at the foot's padding (16px 24px 20px, .dialog__foot), whose height its
 * buttons decide, as tall as this one at every width. Put anything positioned
 * between them, or change that padding, and it lands somewhere else. Not while
 * the dialog asks about unsaved changes: that question stands in the foot's
 * place.
 */
.form-tab__delete {
  position: absolute;
  left: 24px;
  bottom: 20px;
}

.dialog.is-unsaved .form-tab__delete {
  display: none;
}

/* Narrow it is the bin alone beside the two, square, its words kept for a
   screen reader. */
@media (max-width: 743px) {
  .form-tab__delete {
    aspect-ratio: 1;
    padding: 0;
  }

  .form-tab__delete-words {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

.lines-fold__rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* With script and no lines, only "zin toevoegen" shows; the empty row that
   stands in for it without script is there but hidden, and the box around
   nothing would still take the field's gap. */
:root.js .lines-fold__rows:not(:has(> .lines-fold__row:not([hidden], .no-js-only))) {
  display: none;
}

.lines-fold__row {
  display: flex;
  gap: 8px;
}

.lines-fold__row input {
  flex: 1;
  min-width: 0;
}

.lines-fold__remove {
  width: 38px;
  height: 38px;
  border-color: var(--rule);
  background: var(--ground);
  color: var(--muted);
}

.lines-fold__add {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 7px;
  padding: 0 0 1px;
  border: 0;
  border-bottom: 1px solid transparent;
  background: none;
  font-family: inherit;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}

.lines-fold__add:hover {
  border-bottom-color: var(--rule);
  color: var(--ink);
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

/* The label, and only the label: the hint and the validation message are
   spans in here too, and neither is set in capitals. A field with something
   beside its label (the notes and their "opmaak") has a head instead. */
.form-field > span:first-child,
.form-field__head > label {
  font-size: 13px;
  color: var(--muted);
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  height: 38px;
  padding: 0 11px;
  background: var(--ground);
  border: 1px solid var(--input-line);
  border-radius: var(--radius);
  color: var(--ink);
  font-size: 14.5px;
  outline: none;
}

.form-field textarea {
  height: auto;
  padding: 10px 11px;
  line-height: 1.6;
  resize: vertical;
}

/* In the warm box of the maintainer's own note (see --private-input-line).
   After the rule above, which weighs the same; focus still outweighs both. */
.form-field--private textarea {
  border-color: var(--private-input-line);
}

/*
 * A date field writes its own placeholder — dd/mm/yyyy — and that is the
 * browser's text rather than ours. ::placeholder never reaches it, and neither
 * does ::-webkit-datetime-edit: on this engine those pseudo-elements take no
 * colour at all, not even a forced one. What the text does follow is the
 * input's own colour, so the input is what changes — marked by the server on
 * render, and kept right by admin.js while somebody is typing into it, which is
 * the only part a page load would not already have got right.
 */
.form-field input[type="date"].is-empty {
  color: var(--muted);
}

/*
 * Half a date is not a placeholder. Typing one subfield leaves the value empty
 * — so the mark above is still on — but the control is then holding input it
 * cannot turn into a date, which is what badInput says and what :invalid reads
 * back. Nothing else here can make one of these invalid: they carry no
 * required, no min and no max.
 */
.form-field input[type="date"].is-empty:invalid {
  color: var(--ink);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--water);
}

/*
 * The category in the mark form (_MarkForm): the text field it always was,
 * with the register's categories in a list under it (site.js). The list hangs
 * over what follows rather than pushing it down, so the notes do not jump while
 * it is open; it stays inside the dialog's scrolling middle, which grows to
 * hold it, and site.js scrolls that far when it opens. The arrow lies over the
 * field's right edge, so the text stops short of it.
 *
 * A grid item keeps its content's minimum width, and this box is one in the
 * field's subgrid now, in the place the input had.
 */
.category-field {
  position: relative;
  min-width: 0;
}

.form-field .category-field input {
  padding-right: 36px;
}

.category-field__toggle {
  position: absolute;
  top: 1px;
  right: 1px;
  bottom: 1px;
  display: grid;
  place-items: center;
  width: 34px;
  padding: 0;
  border: 0;
  border-radius: 0 var(--radius) var(--radius) 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
}

.category-field__toggle:hover {
  color: var(--water);
}

.category-field__toggle svg {
  transition: rotate 0.15s ease;
}

.category-field.is-open .category-field__toggle svg {
  rotate: 180deg;
}

/* As wide as the field and never narrower than a name with its count, which
   the field in a narrow panel would be. The field is the panel's left column,
   so the extra width runs into the panel and not off it. */
.category-field__list {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 3;
  width: 100%;
  min-width: 230px;
  max-height: min(260px, 40dvh);
  padding: 4px 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
}

/* Lit by the arrow keys and by the mouse alike, through one class, so the two
   never light two rows at once. Chosen is what the field holds, down the edge
   as in the review's list. */
.category-field__option {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 12px 7px 10px;
  border-left: 2px solid transparent;
  font-size: 14.5px;
  color: var(--ink);
  cursor: pointer;
}

.category-field__option.is-active {
  background: var(--wash);
}

.category-field__option.is-chosen {
  border-left-color: var(--water);
}

.category-field__name {
  min-width: 0;
  overflow-wrap: anywhere;
}

/* The part of a name that matches what is typed. */
.category-field__name mark {
  background: none;
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-underline-offset: 3px;
}

.category-field__count {
  flex: 0 0 auto;
  font-size: 12px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* What is typed, offered as a new category: last, and set apart from the
   names above it only when there are any. */
.category-field__option--new {
  justify-content: flex-start;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-left: 0;
  font-size: 14px;
  color: var(--water);
}

.category-field__option:not([hidden]) ~ .category-field__option--new {
  margin-top: 4px;
  border-top: 1px solid var(--line);
}

.category-field__note {
  color: var(--water);
}

/* Says what the notes field does with what is typed into it. */
/* The mark's drawing in /admin's dialog: what it is now, the field that
   replaces it, and taking it away. */
.drawing-field {
  margin-top: 14px;
}

.drawing-field__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
}

.drawing-field .drawing {
  --size: 64px;
  color: var(--ink);
}

/* Not a text field: .form-field input sizes every input as one. */
.drawing-field input[type="file"] {
  flex: 1 1 16rem;
  width: auto;
  min-width: 0;
  height: auto;
  padding: 6px 0;
  border: 0;
  background: none;
  font-size: 14px;
}

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

/* ---------- a page and its versions (/admin/pages) ---------- */

/* A box to tick with its words beside it. Named again because
   .form-field input sizes every input as a text field. */
.form-check {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 38px;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
}

.form-check input[type="checkbox"] {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: var(--water);
}

/* The place face (?place=): per place the box for this page, then the place
   as it runs on the site, one chip per page. */
.place-show {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

/* Closer together than a form's fields: the box, the row it changes and the
   line saying how to use the row are one thing. */
.place-face {
  gap: 0;
}

.place-show .form-check {
  min-height: 0;
}

/* Under the row it explains, close enough to be read as its caption. */
.place-face > .form-hint {
  margin: 6px 0 0;
}

.place-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.place-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px 0 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ground);
  font-family: var(--display);
  font-size: 17px;
  font-weight: 500;
  color: var(--water);
}

/* A chip of a page is picked up: no text selection, no pan of the page
   under the finger — follow() decides what the movement is. */
:root.js .place-chip[data-id] {
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.place-chip__grip {
  color: var(--faint-2);
}

/* The page the dialog is about. */
.place-chip--own {
  border-color: var(--water);
  background: var(--tint);
}

/* privacy and beheer: in the colofon always, at its end. */
.place-chip--fixed {
  padding-left: 12px;
  border-style: dashed;
  background: transparent;
  font-family: var(--body);
  font-size: 14px;
  font-weight: 400;
  color: var(--muted);
}

/* In the hand: over the others, which move aside as it passes them. */
.place-chip.is-dragging {
  position: relative;
  z-index: 1;
  border-color: var(--ink);
  box-shadow: 0 6px 18px rgb(0 0 0 / 0.16);
  cursor: grabbing;
}

/* One block per place on the face "plaats op de site…": the box and what
   the place is, then its chips, then — under Verder lezen — the row as the
   start page will draw it. The blocks are the face's rows, divided by a
   dotted rule as the canvas draws them. */
.place-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 0;
  border-bottom: 1px dotted var(--rule);
}

.place-block:last-of-type {
  border-bottom: 0;
}

.place-block__where {
  font-size: 13px;
  white-space: nowrap;
  color: var(--muted);
}

.place-preview {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--wash);
}

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

.place-preview__title {
  font-family: var(--display);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.place-preview__lead {
  display: -webkit-box;
  overflow: hidden;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

/*
 * The list of pages: a mark's row with columns of its own — the address, the
 * title, the start of the lead, the languages, and two buttons where a mark
 * has one.
 *
 * Wide, each row is a subgrid of the table, so a column is as wide as its
 * widest cell in any row rather than a share of the width: the address and
 * the title up to a cap, past which they are cut off as a mark's name is, the
 * languages and the buttons exactly. The lead takes what is left, and is the
 * one that gives way, cut off at its column's end with its whole text in the
 * cell's title. The room between the columns is the gap, one for the table,
 * which the subgrid takes over (column-gap: normal) rather than .row's 14px.
 */
@media (min-width: 744px) {
  .page-table {
    display: grid;
    grid-template-columns:
      fit-content(220px) fit-content(240px) minmax(200px, 1fr)
      max-content max-content;
    column-gap: 40px;
  }

  .page-table > * {
    grid-column: 1 / -1;
  }

  .row--page {
    grid-template-columns: subgrid;
    column-gap: normal;
  }
}

.row__excerpt {
  min-width: 0;
  font-size: 13.5px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Narrow, a line of its own under the address and the title, two lines at
   most; a page live nowhere has none, and the line goes (.row__none). */
@media (max-width: 743px) {
  .row--page {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "lead    actions"
      "excerpt excerpt"
      "words   words";
  }

  /* A page's card keeps one button, its page on the site, at the top right
     and without an edge; over the card's own link, as the chips are. The
     pencil goes (.row__edit), the address being the way in. */
  .row--page .row__actions {
    display: flex;
    position: relative;
    z-index: 1;
    margin: -8px -10px 0 0;
  }

  .row--page .row__actions .icon-btn {
    width: 36px;
    height: 36px;
    border-color: transparent;
  }

  .row__excerpt {
    grid-area: excerpt;
    display: -webkit-box;
    margin-top: 5px;
    font-size: 13px;
    line-height: 1.5;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }
}

/* ---------- the page dialog's form (/admin/pages) ---------- */

/*
 * Wider than a mark's dialog: most of it is a page of text being written.
 * And with the form showing, as tall as the dialog may be, so that the
 * dialog never scrolls and the text field takes the room that is left —
 * one scroll, the text's own, where there used to be two.
 */
.dialog--page {
  width: min(840px, calc(100vw - 32px));
}

/* A question (.confirm) stands on its own and needs far less, whichever face
   it was asked from: the class on the dialog is only set by the server. */
.dialog--page:has(.confirm) {
  width: min(460px, calc(100vw - 32px));
}

.dialog--page:has(.page-form) {
  height: 88vh;
}

@media (max-width: 743px) {
  .dialog--page:has(.page-form) {
    height: 94vh;
  }
}

/*
 * The form fills the dialog, the tabs fill the form, the open panel fills the
 * row under its tab heads, and the text fills what the panel has left over
 * its title and its bar. Each a flex item that may shrink (min-height: 0), or
 * the text would push the bar out of the dialog instead of scrolling.
 *
 * The strip is a grid here rather than the wrapping row a mark's dialog has:
 * a wrapped row shares out its height between its two lines, and the panel
 * has to have all of it. One column per head (--tabs, set by the view), one
 * more for the rule to run on in, and the open panel spans them all.
 */
.page-form {
  flex: 1 1 auto;
  min-height: 0;
}

.page-form .form-tabs {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(var(--tabs, 2), max-content) minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
}

.page-form .form-tab__head {
  grid-row: 1;
}

.page-form .form-tab__body {
  grid-row: 2;
  grid-column: 1 / -1;
  min-height: 0;
  /* The bar reaches down over exactly this much (.page-bar). */
  padding-bottom: 22px;
}

.page-form__slug {
  max-width: 360px;
}

/* Fields standing on their own rather than in a grid of rows, set as every
   label in a form is (.form-grid--rows > .form-field > label). */
.page-form .form-field > label,
.page-note .form-field > label,
.examples-fold__field > .form-field > label,
.address-field > label {
  font-size: 13px;
  color: var(--muted);
}

.page-form__text {
  flex: 1 1 auto;
  min-height: 0;
}

.page-form__text textarea.page-body {
  flex: 1 1 auto;
}

/*
 * The panel's bar, which stands at the dialog's foot: where the language
 * stands on the left, its buttons on the right. It reaches out over the
 * form's padding to the dialog's edges, so it reads as the foot it replaces.
 */
.page-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  margin: auto -24px -22px;
  padding: 12px 24px;
  border-top: 1px solid var(--line);
  background: var(--wash);
}

.page-bar .page-state {
  flex: 1 1 220px;
}

.page-bar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

/* The unsaved question takes the foot's place, so the bar's buttons go. */
.dialog.is-unsaved .page-bar__actions {
  display: none;
}

.btn--icon {
  width: 38px;
  padding: 0;
}

/* Publishing and the arrow beside it: one button in two. */
.split {
  display: inline-flex;
  gap: 1px;
}

.split > .btn:first-child {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.split > .btn:last-child {
  width: 32px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

/*
 * The bar's menus — "⋯" and the arrow beside "publiceren" — and the note
 * asked for before publishing. Popovers, so they open without script and sit
 * over the dialog; without script the browser centres them, with it pages.js
 * stands them against their button, above it.
 */
.page-menu {
  min-width: 220px;
  max-width: calc(100vw - 16px);
  padding: 6px 0;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  color: var(--ink);
  font-size: 13.5px;
}

:root.js .page-menu {
  inset: auto;
  margin: 0;
}

.page-menu:popover-open {
  display: flex;
  flex-direction: column;
}

.page-menu::backdrop {
  background: transparent;
}

.page-menu__item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.page-menu__item:hover,
.page-menu__item:focus-visible {
  background: var(--wash);
}

.page-menu__item--danger {
  color: var(--danger);
}

.page-menu__rule {
  margin: 5px 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.page-note {
  gap: 12px;
  width: min(340px, calc(100vw - 16px));
  padding: 16px;
}

.page-note__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* The address face: the field with its slash before it, and what changing
   it does, in a margin note that carries the address being typed. */
.address-field {
  max-width: 420px;
}

.address-field__input {
  display: flex;
}

.address-field__slash {
  display: flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid var(--input-line);
  border-right: 0;
  border-radius: var(--radius) 0 0 var(--radius);
  background: var(--ground);
  color: var(--muted);
}

.address-field__input input {
  flex: 1 1 auto;
  min-width: 0;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.address-effect {
  margin: 4px 0 0;
  padding: 10px 14px;
  border-left: 2px solid var(--water);
  background: var(--wash);
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--muted);
}

.address-effect strong {
  font-weight: 600;
  color: var(--ink);
}

/* "bewaard", in the place face's foot once a change there has been saved. */
.page-saved {
  font-size: 12.5px;
  color: var(--muted);
}

/* What just happened, said once under the title when the dialog comes back
   after a save, a publish or a restore. */
.dialog__done {
  color: var(--water);
}

/* Where one language stands — live, a draft after it, or neither — and the
   two ways to what it was: the preview, and every version. */
.page-state {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 16px;
  font-size: 13px;
  color: var(--muted);
}

.page-state__line {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px 8px;
}

.page-state__live {
  color: var(--water);
}

/* A draft waiting to be published: the accent dot the review's strip uses
   for something on offer (.strip__row.is-offering), on a language's chip in
   the list and on its tab in the dialog. */
.draft-dot {
  display: inline-block;
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  margin-left: 2px;
  border-radius: 50%;
  background: var(--water);
}

.page-state__draft {
  color: var(--ink);
}

/* A save refused because another tab saved first (_PageConflict): the
   reason, and the two ways on under it, on a line of their own in the bar. */
.page-conflict {
  display: flex;
  flex: 1 0 100%;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  margin-top: 4px;
}

.page-conflict > .validation {
  flex: 1 1 260px;
  margin: 0;
}

.page-conflict__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/*
 * A notice about the page rather than part of it (design canvas "Ontbrekende
 * teksten in beheer", A and 2a): an icon, a sentence per thing, a language as
 * its label. Warm where something is missing — /admin's list, when a language
 * has no word to draw the 404's joke from, in the
 * maintainer's own note's colours — and blue where it only says what this
 * is: a page's preview. Both tones are mixed from themed tokens, so they
 * follow dark by themselves. The label is .lang-pill, outlined here in the
 * notice's colour rather than filled.
 */
.notice {
  --notice-ground: var(--tint);
  --notice-line: color-mix(in oklab, var(--water) 35%, var(--rule));
  --notice-ink: var(--water);

  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 16px;
  padding: 10px 14px;
  border: 1px solid var(--notice-line);
  border-radius: var(--radius);
  background: var(--notice-ground);
  color: var(--ink);
  font-size: 13.5px;
  line-height: 1.5;
}

.notice--attention {
  --notice-ground: var(--private);
  --notice-line: var(--private-line);
  --notice-ink: var(--private-ink);
}

.notice__icon {
  flex: none;
  margin-top: 1px;
  color: var(--notice-ink);
}

/* From nothing, not from its text's width: where the notice wraps (a preview's
   bar, narrow) a long sentence would otherwise leave its icon alone on the
   first line. */
.notice__body {
  display: flex;
  flex: 1 1 0%;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.notice__body > p {
  margin: 0;
}

.notice .lang-pill {
  height: 18px;
  margin-right: 2px;
  padding: 0 5px;
  border-color: var(--notice-line);
  background: none;
  color: var(--notice-ink);
  vertical-align: 0.1em;
}

/* _LinkedFrom: the pages that link to what is about to go, a row each — the
   address, its languages, how many links — in columns as wide as their
   widest cell, so the pills and the counts stay beside the addresses. */
.linked-from__rows {
  display: grid;
  grid-template-columns: repeat(3, max-content);
  align-items: center;
  gap: 4px 14px;
  margin: 2px 0;
  padding: 0;
  list-style: none;
}

.linked-from__row {
  display: contents;
}

.linked-from__page {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 12.5px;
}

.linked-from__languages {
  display: inline-flex;
  gap: 4px;
}

.linked-from__languages .lang-pill {
  margin-right: 0;
}

/* The address face with pages linking to it (2.4b) has two buttons on the
   right, "alleen adres bewaren" and "bewaren en links aanpassen"; where they
   do not fit beside each other they go under each other, at the right. */
.dialog--page .dialog__actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Where even folded (.btn__fold) the three do not fit on one line, the way
   back and the address alone share the first, and the button pages link
   here for takes the second, as wide as the foot. */
@container review-foot (width < 430px) {
  .dialog--page .dialog__foot .dialog__actions {
    display: contents;
  }

  .dialog--page .dialog__foot .dialog__actions .btn--accent {
    flex: 1 0 100%;
  }
}

/* Above a preview: what is being looked at, and the way back. The page under
   it is drawn as visitors will see it, so this is the one thing that is not.
   It stood flush against the window's top edge; now 16px under it, in the
   page's column, and the header's own padding is the room below it. */
.preview-bar {
  align-items: center;
  margin: 16px 0 0;
}

.preview-bar__back {
  flex: none;
  font-size: 13px;
}

@media (max-width: 743px) {
  /* The page has no side padding narrow, so the bar takes the gutters the
     header has; the way back goes under the sentence, level with it. */
  .preview-bar {
    flex-wrap: wrap;
    align-items: flex-start;
    row-gap: 4px;
    margin: 12px var(--gutter) 0;
  }

  .preview-bar__back {
    flex-basis: 100%;
    padding-left: 30px;
  }
}

/* Markdown is written in it, so it reads like the source it is. Its height
   is what the dialog has left (.page-form); this is the least it takes when
   a short screen has little to give. */
.form-field textarea.page-body {
  min-height: 160px;
  resize: none;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 13.5px;
  line-height: 1.65;
}

.btn--small {
  height: 30px;
  padding: 0 11px;
  font-size: 11.5px;
}

/* One language's history, newest first: a version per line, ruled off like
   the list it is, with what can be done to it at the end. */
.versions {
  margin: 0;
  padding: 0;
  list-style: none;
}

.version {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "head    actions"
    "title   actions"
    "note    actions";
  align-items: center;
  column-gap: 16px;
  row-gap: 3px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.version__head {
  grid-area: head;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
}

.version__number {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
}

.version__badge {
  display: inline-flex;
  align-items: center;
  height: 19px;
  padding: 0 7px;
  border: 1px solid var(--rule);
  border-radius: 2px;
  font-size: 12px;
  color: var(--muted);
}

.version__badge--live {
  border-color: var(--water);
  background: var(--water);
  color: var(--on-water);
}

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

.version__title {
  grid-area: title;
  font-size: 14px;
  color: var(--ink);
}

.version__note {
  grid-area: note;
  font-size: 13px;
  color: var(--muted);
}

.version__actions {
  grid-area: actions;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

@media (max-width: 743px) {
  .version {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "head"
      "title"
      "note"
      "actions";
  }

  .version__actions {
    justify-content: flex-start;
    margin-top: 8px;
  }

  .btn--small {
    height: 38px;
    padding: 0 14px;
    font-size: 12.5px;
  }
}

/* ---------- the pictures pages show (/admin/pages) ---------- */

.images {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 56px;
  scroll-margin-top: calc(var(--admin-bar) + 16px);
}

.images__title {
  margin: 0;
  padding-bottom: 10px;
  border-bottom: 1.5px solid var(--ink);
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
}

.images__upload {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  font-size: 13.5px;
}

/* The browser's own file button, dressed as every other button here. */
.images__upload input[type="file"] {
  min-width: 0;
  font-size: 13px;
  color: var(--muted);
}

.images__upload input[type="file"]::file-selector-button {
  height: 38px;
  margin-right: 12px;
  padding: 0 15px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  color: var(--ink);
  font: inherit;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  cursor: pointer;
}

.images__upload input[type="file"]::file-selector-button:hover {
  border-color: var(--ink);
}

.images__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.image-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ground);
  overflow: hidden;
}

/* Just uploaded, so the eye finds it among the rest. */
.image-card--new {
  border-color: var(--water);
}

.image-card__thumb {
  display: block;
  width: 100%;
  height: 150px;
  object-fit: contain;
  background: var(--wash);
}

.image-card__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 14px 14px;
  min-width: 0;
}

.image-card__name {
  font-size: 14px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

/* The line a page writes to show it, selectable whole with or without script. */
.image-card__line {
  padding: 6px 8px;
  border-radius: 2px;
  background: var(--wash);
  font-size: 12px;
  color: var(--ink);
  overflow-wrap: anywhere;
  user-select: all;
}

.image-card__question {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink);
}

.image-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

/* The two small buttons beside a page's text: "afbeelding" and "opmaak". */
.form-field__tools {
  display: inline-flex;
  align-items: center;
  gap: 16px;
}

/* The picker: the library in a popover over the dialog, centred by the
   browser, since unlike the formatting card it is something to choose from
   rather than something to glance at beside a button. */
.image-picker {
  width: min(560px, calc(100vw - 32px));
  max-height: min(70vh, 560px);
  padding: 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.5;
  overflow-y: auto;
}

.image-picker:popover-open {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.image-picker::backdrop {
  background: transparent;
}

.image-picker__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.image-picker__item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ground);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.image-picker__item:hover,
.image-picker__item:focus-visible {
  border-color: var(--water);
}

.image-picker__item img {
  display: block;
  width: 100%;
  height: 90px;
  object-fit: contain;
  background: var(--wash);
}

.image-picker__item code {
  font-size: 11px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

/*
 * _PageLinks: how many of a text's links do not work, beside "Afbeelding" and
 * "Opmaak", and the card it opens (design canvas "Linkcontrole bij
 * publiceren", 2.1). The line is the tools' shape in the maintainer's note
 * colours, which /admin's notices use for something missing. The card is a
 * popover like the picker's; pages.js stands it under its button, and
 * without script the browser centres it.
 */
.page-links {
  display: contents;
}

.page-links__open {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 0;
  border: 0;
  background: none;
  color: var(--private-ink);
  font-size: 12.5px;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

/* Three tools beside the label do not fit a phone's panel: they go under it,
   to the right, rather than breaking the line in two. */
.form-field__head:has(.page-links__open) {
  flex-wrap: wrap;
  row-gap: 6px;
}

.form-field__head:has(.page-links__open) .form-field__tools {
  margin-left: auto;
}

.page-links__open:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.page-links__card {
  width: min(420px, calc(100vw - 32px));
  max-height: min(70vh, 560px);
  margin: 0;
  padding: 14px 16px 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  color: var(--ink);
  font-size: 13.5px;
  line-height: 1.45;
  overflow-y: auto;
}

/* Without script there is no one to stand it, and the browser's own margin
   is what centres it. */
:root:not(.js) .page-links__card {
  margin: auto;
}

.page-links__card:popover-open {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.page-links__card::backdrop {
  background: transparent;
}

.page-links__group {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.page-links__group:not(:first-child) {
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px dotted var(--rule);
}

.page-links__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.page-links__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  column-gap: 12px;
}

.page-links__what {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  color: var(--muted);
}

.page-links__what code {
  font-size: 12.5px;
  color: var(--ink);
  overflow-wrap: anywhere;
}

/* Opened by a refused "publiceren" (2.2): what publishing would do on top,
   "toch publiceren" in a foot drawn as the dialog's is, edge to edge. */
.page-links__lead {
  margin: 0;
  color: var(--ink);
}

.page-links__lead + .page-links__group {
  margin-top: 2px;
  padding-top: 0;
  border-top: 0;
}

/* Sticks to the card's foot while a long list scrolls under it: the button
   the card was opened for stays in sight. */
.page-links__foot {
  position: sticky;
  bottom: -16px;
  display: flex;
  justify-content: flex-end;
  margin: 6px -16px -16px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  background: var(--wash);
}

/* The same without script, where nothing opens the card: a line of its own
   in the panel's bar, as _PageConflict's choice stands there. */
.page-links__block {
  display: flex;
  flex: 1 0 100%;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
  font-size: 13.5px;
  line-height: 1.45;
}

.page-links__block .page-links__foot {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  justify-content: flex-start;
}

/* ---------- what a note may say ---------- */

.form-field__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

/* A word with a mark before it, not a button with a border: it sits on the
   label's line and should weigh no more than the label does. */
.markup-help {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 0;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1;
  cursor: help;
}

.markup-help:hover {
  color: var(--water);
}

/*
 * _MarkupHelp. The browser's own stylesheet gives a popover a border, a
 * padding and a place in the middle of the screen; the first two are replaced
 * here, the third only with script, which puts the card against its button
 * (site.js sets top or bottom, left or right and a max-height). Without script
 * it stays in the middle, where it can at least be read. site.js also sets
 * --tip-room, what is left from that edge to the far side of the screen, which
 * every card's max-width here and below keeps to.
 */
.markup-tip {
  width: max-content;
  max-width: min(300px, var(--tip-room, calc(100vw - 16px)));
  padding: 14px 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.5;
}

/* A page's card has more rows, and longer ones: a table, a picture. */
.markup-tip--page {
  max-width: min(380px, var(--tip-room, calc(100vw - 16px)));
}

:root.js .markup-tip {
  inset: auto;
  margin: 0;
  overflow-y: auto;
}

.markup-tip:popover-open {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.markup-tip__intro {
  margin: 0;
  color: var(--muted);
  text-wrap: pretty;
}

/* The examples take what they need, up to 60% of the card: a page's picture
   (`![tekst](/images/k7q2mx9p/naam.png)`) is longer than the card is wide,
   and an auto column gave it all of it, squeezing the words beside it to a
   few letters a line. Past that it breaks, anywhere — it is an address. */
.markup-tip__rows {
  display: grid;
  grid-template-columns: fit-content(60%) minmax(0, 1fr);
  align-items: baseline;
  gap: 4px 14px;
  margin: 0;
}

.markup-tip__rows dd {
  margin: 0;
}

.markup-tip__rows code {
  font-size: 12.5px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.markup-tip__rows strong {
  font-weight: 600;
  color: var(--ink);
}

.validation:not(:empty) {
  font-size: 12.5px;
  color: var(--danger);
}

/* The summary renders its errors as a list. */
.validation ul {
  margin: 0;
  padding-left: 18px;
}

/* A field's message is rendered whether or not anything is wrong with it, and
   an empty span would still take a gap in the column it sits in. */
.form-field .validation:empty {
  display: none;
}

/* ---------- the dialog on a narrow screen ---------- */

/*
 * A sheet against the bottom edge, and the iOS clamp. Here rather than under
 * "dialog" because it narrows rules of the panels and forms above it too, and
 * has to come after them.
 */
@media (max-width: 743px) {
  /*
   * Here the lock further up is not enough on its own. `overflow: hidden` stops
   * the visitor scrolling but leaves the document its full height, and Safari on
   * iPhone scrolls it itself to clear a field for the keyboard — dragging the
   * sheet up off the bottom edge and showing what the document holds down
   * there: the register, undimmed, because ::backdrop only ever covers the
   * viewport. Clamping the document to the fold leaves nothing to show.
   *
   * `:focus-within` and not [open], because the clamp is not free: a document
   * ending at the fold is one Safari stops running under its own bottom bar, so
   * the sheet gives up a bar's height of the edge it is drawn to meet. Tied to
   * the focus it lasts exactly as long as the keyboard that is the reason for
   * it, and every other moment the sheet reaches the edge.
   *
   * Only at this width, too, where the sheet covers the screen and nobody can
   * see the page behind it move. Wide, the dialog is centred with the register
   * in view all around it, and clamping would jump the list to the top in plain
   * sight for a keyboard that never comes.
   *
   * It costs the scroll offset, since a document that cannot scroll is at the
   * top, and site.js puts that back when the dialog closes — which covers a
   * field blurred without closing too, the clamp lifting on an offset already
   * spent. Without script there is nothing to put back: a dialog is a page load
   * away there.
   *
   * Not the sheet a footnote opens in (_NoteSheet): it has no field and so no
   * keyboard, but showModal() puts the focus on its link, and the clamp cut the
   * page off under the scrim at one screen's height.
   */
  html:has(.dialog[open]:not(.dialog--note):focus-within),
  html:has(.dialog[open]:not(.dialog--note):focus-within) body {
    height: 100%;
    overflow: hidden;
  }

  /*
   * Clamped, there is nothing under the sheet to show — but empty is not the
   * same as invisible. Safari still drags the sheet up off the bottom edge and
   * what stands under it then is the canvas, in the register's own ground,
   * which reads as a gap the design does not have. So while the clamp holds it
   * takes the colour the sheet's foot is, and the sheet simply carries on past
   * the bottom of the screen.
   *
   * On <body>, whose background is what the canvas is painted from — <html>
   * was tried and does not reach it. Which means the register behind takes the
   * same colour, a step of two per cent under a scrim, and nowhere it shows
   * but the sliver above the sheet.
   */
  html:has(.dialog[open]:not(.dialog--note):focus-within) body {
    background: var(--wash);
  }

  /* The dialog meets the bottom edge, the way the register's sheet does. */
  .dialog,
  .dialog--confirm {
    width: 100%;
    max-width: 100%;
    max-height: 94vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .dialog {
    top: auto;
    bottom: 0;
  }

  /* Meeting that edge, it comes up off it — the whole height rather than the
     12px a centred dialog rises, which is the sheet's own way in. */
  .dialog {
    translate: 0 100%;
  }

  @starting-style {
    .dialog[open] {
      translate: 0 100%;
    }
  }

  /* It came up off the edge, so it goes back down to it. */
  .dialog.is-closing {
    translate: 0 100%;
  }

  .dialog::before {
    display: block;
    flex: 0 0 auto;
    align-self: center;
    margin: 10px 0 2px;
  }

  /* The surface takes the downward drag and its scrolling middle keeps it.
     Without the second rule the drawer could not be scrolled by thumb at all. */
  .dialog {
    touch-action: none;
  }

  .dialog__body,
  .submit__body {
    touch-action: pan-y;
  }

  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* Safari on a phone draws a date field in its own shape, as wide as that
     shape wants whatever the width says: it stuck out past the column's
     edge. Without the native look it is a field like the others, and a tap
     still opens the date wheel. */
  .form-field input[type="date"] {
    -webkit-appearance: none;
    appearance: none;
  }

  /* And its date starts where every other field's text does. */
  .form-field input[type="date"]::-webkit-date-and-time-value {
    text-align: left;
  }

  /*
   * The term under a tab's name is what makes the strip too wide for a phone,
   * and a wrapped strip breaks the rule that runs on past the last tab: the
   * filler carrying it wraps too and the line comes out in pieces. The term is
   * in the panel's own first field two lines below, so here the tab is just the
   * register's name.
   */
  .form-tab__note {
    display: none;
  }
}

/* ---------- the vote dashboard ---------- */

/*
 * Four numbers, a chart and the terms that are still too close to call. Every
 * number on this page is a count over the Votes table; nothing here is per
 * visitor, and nothing here needed a column that did not already exist.
 */
.kpi {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1.5px solid var(--ink);
  border-bottom: 1px solid var(--line);
}

.kpi__cell {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 20px 22px;
}

.kpi__cell + .kpi__cell {
  border-left: 1px solid var(--line);
}

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

.kpi__value {
  font-family: var(--display);
  font-size: 44px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* A note that only reports takes no colour; one that says which way a number
   went takes the accent for up and the muted ink for down. */
.kpi__note {
  font-size: 12.5px;
  color: var(--muted);
}

.kpi__note--up {
  color: var(--water);
}

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

/* Both panels below the numbers: same card, different padding. */
.panel {
  margin-top: 22px;
  background: var(--ground);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.panel--chart {
  padding: 22px 24px;
}

.panel--contested {
  padding: 20px 24px 22px;
}

.panel__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding-bottom: 14px;
}

.panel__heading {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

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

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

.panel__empty {
  margin: 0;
  padding: 24px 0 8px;
  font-size: 14px;
  color: var(--muted);
}

.panel__controls {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.seg {
  display: flex;
  align-items: center;
  gap: 2px;
}

.seg__option {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 2px;
  font-size: 13px;
  white-space: nowrap;
  color: var(--muted);
  text-decoration: none;
}

.seg__option:hover {
  color: var(--ink);
}

.seg__option[aria-current="true"] {
  border-color: var(--water);
  background: var(--wash);
  color: var(--ink);
}

/* ---------- the chart ---------- */

/*
 * One server-rendered geometry, two layouts. The SVG holds nothing but the
 * area and the line, in a 0 0 100 100 viewBox stretched to whatever box this
 * gives it; every axis label, dot and guide is HTML on the same percentages.
 * That is what lets a phone and a desktop share one set of coordinates — see
 * the note in AGENTS.md before putting a <text> or <circle> back in.
 *
 * The padding is the plot's margin, and it is CSS rather than viewBox units
 * for the one reason that matters: it holds text at a real font size, which
 * does not scale with the box.
 */
.chart {
  --chart-pad-t: 18px;
  --chart-pad-r: 12px;
  --chart-pad-b: 26px;
  --chart-pad-l: 56px;
  --chart-ratio: 932 / 238;
  --chart-line: 2px;
  --chart-dot: 6.4px;
  --chart-guide: 9px;
  --chart-axis: 11px;
  --chart-gap: 10px;
}

.chart__readout {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
  padding-top: 14px;
  border-top: 1px dotted var(--line);
}

.chart__value {
  font-family: var(--display);
  font-size: 46px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.022em;
  color: var(--water);
  font-variant-numeric: tabular-nums;
}

.chart__reading {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.chart__unit {
  font-size: 13.5px;
  color: var(--ink);
}

.chart__date {
  font-size: 12.5px;
  color: var(--muted);
}

.chart__delta {
  margin-left: auto;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--water);
}

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

.chart__plot {
  padding: var(--chart-pad-t) var(--chart-pad-r) var(--chart-pad-b) var(--chart-pad-l);
}

/* The plot rectangle itself. Every overlay below is positioned against this
   box, so the coordinates are the raw percentages with nothing to subtract. */
.chart__area {
  position: relative;
  aspect-ratio: var(--chart-ratio);
}

.chart__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.chart__fill {
  fill: var(--chart-fill);
  stroke: none;
}

/* non-scaling-stroke is what makes preserveAspectRatio="none" safe: the stroke
   is drawn after the viewport transform, so the line stays this thick and its
   joins stay round however the box is stretched. */
.chart__line {
  fill: none;
  stroke: var(--water);
  stroke-width: var(--chart-line);
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

/* Dashed in CSS pixels rather than as a stroke-dasharray, which a stretched
   viewBox would stretch along with everything else. */
.chart__grid {
  position: absolute;
  left: 0;
  right: 0;
  top: var(--y);
  border-top: 1px dashed var(--line);
}

.chart__grid--base {
  border-top-style: solid;
  border-top-color: var(--rule);
}

/* Out into the gutter the padding reserved. */
.chart__tick {
  position: absolute;
  top: var(--y);
  right: calc(100% + var(--chart-gap));
  transform: translateY(-50%);
  font-size: var(--chart-axis);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.chart__x-labels {
  position: absolute;
  inset: 0;
}

.chart__x {
  position: absolute;
  left: var(--x);
  top: calc(100% + var(--chart-gap));
  transform: translateX(-50%);
  font-size: var(--chart-axis);
  color: var(--muted);
  white-space: nowrap;
}

/* The two ends would hang off the axis if they stayed centred. */
.chart__x--first {
  transform: none;
}

.chart__x--last {
  transform: translateX(-100%);
}

/* A span rather than a <circle>: under preserveAspectRatio="none" a circle
   comes out an ellipse, and a border-radius cannot. */
.chart__dot {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--chart-dot);
  height: var(--chart-dot);
  border: var(--chart-line) solid var(--water);
  border-radius: 50%;
  background: var(--ground);
  transform: translate(-50%, -50%);
}

.chart__guide {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--x);
  border-left: 1px dashed var(--water);
}

.chart__guide-dot {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--chart-guide);
  height: var(--chart-guide);
  border-radius: 50%;
  background: var(--water);
  transform: translate(-50%, -50%);
}

/* One column per day, standing over the whole plot so the pointer never has to
   find the line itself. */
.chart__hits {
  position: absolute;
  inset: 0;
}

.chart__hit {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--x);
  width: var(--w);
}

/* ---------- omstreden termen ---------- */

.contested__row {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.5fr) 80px;
  gap: 26px;
  align-items: center;
  padding: 16px 0;
  border-top: 1px dotted var(--line);
}

.contested__names {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.contested__brand {
  font-family: var(--display);
  font-size: 30px;
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.018em;
  color: var(--ink);
}

.contested__term {
  font-size: 13.5px;
  color: var(--water);
}

.contested__meter {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

/* The same shape as the vote bar, cut at --split: the fill runs from there to
   the right edge, so the left of the seam is "merk". */
.contested__bar {
  position: relative;
  height: 10px;
  border: 1px solid var(--rule);
  background: var(--ground);
  overflow: hidden;
}

.contested__fill {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: var(--split);
  background: var(--water);
}

.contested__seam {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--split);
  border-left: 1px solid var(--rule);
}

.contested__labels {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

.contested__pct {
  justify-self: end;
  font-family: var(--display);
  font-size: 30px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* ---------- the vote dashboard on a narrow screen ---------- */

/*
 * 743px, the same breakpoint the register, the admin list and site.js use.
 * The chart needs nothing here but a different set of custom properties: one
 * geometry, two layouts.
 */
@media (max-width: 743px) {
  .kpi {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi__cell {
    padding: 15px 14px;
  }

  /* Two up: the left border belongs to the right-hand cell of each pair, and
     the second row is ruled off from the first. */
  .kpi__cell + .kpi__cell {
    border-left: 0;
  }

  .kpi__cell:nth-child(even) {
    border-left: 1px solid var(--line);
  }

  .kpi__cell:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }

  .kpi__value {
    font-size: 34px;
  }

  .panel--chart {
    padding: 16px 14px 18px;
  }

  .panel--contested {
    padding: 16px 14px 18px;
  }

  .panel__head {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  /* Taller against its width than the wide chart, and shorter in real pixels:
     a phone screen has room the other way round. */
  .chart {
    --chart-pad-t: 16px;
    --chart-pad-r: 8px;
    --chart-pad-b: 30px;
    --chart-pad-l: 46px;
    --chart-ratio: 466 / 284;
    --chart-line: 2.4px;
    --chart-dot: 8px;
    --chart-guide: 11px;
    --chart-axis: 12px;
    --chart-gap: 12px;
  }

  /* Six dates fit across a desktop panel and not across a phone, where the
     same six run into each other at the right-hand end. Every second one goes,
     counted back from the newest so that one always stays. */
  .chart__x-labels span:nth-child(even) {
    display: none;
  }

  .chart__value {
    font-size: 38px;
  }

  .chart__delta {
    margin-left: 0;
  }

  .contested__row {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    padding: 14px 0;
  }

  .contested__brand {
    font-size: 26px;
  }

  .contested__pct {
    justify-self: start;
    font-size: 26px;
  }
}
/* ---------- aandragen ---------- */

/*
 * The submission form. On its own page this panel is the page; with script the
 * register lifts the same markup into a <dialog>, which is the drawer the
 * design draws — so everything here is written to sit in either, and the
 * .dialog rules further up supply the box when it is the second one.
 *
 */
/*
 * The three narrower pages keep the navigation bar and the foot at the
 * page's width, as every page has them, so the bar does not change width
 * from one page to the next; what is narrower is the column inside main —
 * everything in it but the foot. It used to be the whole page, header and
 * colofon too, until the header became the same navigation bar everywhere
 * (canvas "Introductie zonder onthullen", round "Eindronde").
 */
.page--narrow main > :not(.site-foot) {
  max-width: 656px;
  margin-inline: auto;
}

/* /submit's name, with the form's room under it. */
.page--narrow .page-name {
  margin-bottom: 24px;
}

/*
 * /privacy and a page from /admin/pages, /about among them: one column of
 * running text, 680px, standing where the page's content starts — under the
 * logo — with the margin beside it, which from 1240px holds a page's notes
 * (canvas "Nieuwe look voorstellen", W-uitleg).
 */
:is(.page--reading, .page--text) main > :not(.site-foot) {
  max-width: 680px;
  margin-inline: 0 auto;
}

/*
 * Woord aandragen (canvas "Nieuwe look voorstellen", P-aandragen-1,
 * P-aandragen-3, P-aandragen-klaar and W-aandragen). On its own page the panel
 * is a box in the column; with script it is the drawer, against the right edge
 * wide and a sheet on a phone (the dialog's rules), and the box is the
 * dialog's own.
 */
.submit {
  display: flex;
  flex-direction: column;
  max-width: 680px;
  margin: 0 auto;
  background: var(--ground);
  border: 1px solid var(--line);
  overflow: hidden;
}

/* Inside a dialog the box is the dialog's own, so the panel stops drawing one
   and lets it scroll instead — and the centring goes with the box. In a column
   flex container left and right are the cross axis, where an auto margin stops
   an item stretching and eats the slack instead: the panel would sit at its own
   content width with the dialog's surface showing down both sides. */
.dialog .submit {
  max-width: none;
  margin: 0;
  border: 0;
  min-height: 0;
  flex: 1 1 auto;
}

.submit form {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

/* The wide drawer stands the window's full height, and the form fills it, so
   the foot meets the bottom edge. A sheet is only as tall as what it holds, and
   there this changes nothing. */
.dialog .submit form {
  flex: 1 1 auto;
}

/* ---- the head: the drawer's name and the ways out, then the step ---- */

.submit__head {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 28px 40px 0;
}

.submit__bar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.submit__name {
  font-size: 15px;
  font-weight: 600;
}

/* On its own page the page's heading names the form already. */
.submit:not(.dialog .submit) .submit__name {
  display: none;
}

/* The cross, the arrow back on a phone and the pencil on the box of what is on
   its way: one round button, as the header's are. */
.submit__round {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--ground);
  color: var(--ink);
  cursor: pointer;
}

.submit__round:hover {
  background: var(--wash);
}

.submit__close {
  margin-left: auto;
}

/* A phone's: wide, the foot has the way back in words. */
.submit__step-back {
  display: none;
}

.submit__head-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

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

/* An <h2>, so the margin is written whole: the browser's own would put 0.83em
   of nothing between the title and the form. */
.submit__title {
  margin: 0;
  font-family: var(--display);
  font-size: 31px;
  font-weight: 400;
  line-height: 1.1;
  color: var(--ink);
}

/* ---- the middle and the foot ---- */

/* The scrolling middle, so the head and the foot stay put while a long note
   scrolls under them. */
.submit__body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 22px 40px 28px;
  overflow-y: auto;
  min-height: 0;
}

.submit__foot {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px 20px;
  padding: 18px 40px 30px;
  border-top: 1px solid var(--line);
}

/* The rule of step one, and the way back on the two after it, stand at the
   left, apart from the way on. */
.submit__rule,
.submit__foot-back {
  margin-right: auto;
}

.submit__rule {
  font-size: 14px;
  color: var(--muted);
}

.submit__foot .btn {
  height: 50px;
  padding: 0 24px;
  border-color: var(--ink);
  border-radius: 0;
  background: var(--ground);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0;
}

.submit__foot .btn:hover {
  background: var(--wash);
}

/* "Verder", "Regel indienen", "Terug naar de lijst": the black button of the
   new look, as in the header. */
.submit__foot .btn--accent {
  padding: 0 34px;
  background: var(--ink);
  color: var(--ground);
}

.submit__foot .btn--accent:hover {
  border-color: var(--muted);
  background: var(--muted);
  color: var(--ground);
  opacity: 1;
}

/* Only ever set by submit.js — the server never renders this button disabled,
   because that is a step nobody without script could leave. */
.submit__foot .btn--accent[disabled] {
  border-color: var(--line);
  background: var(--wash);
  color: var(--muted);
  cursor: not-allowed;
}

/* ---- step one: the row as it will stand, and three fields ---- */

.draft {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.draft__preview {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

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

/* The brand and the word side by side; on a phone one under the other. */
.draft__pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 16px;
}

.draft__field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
}

/* The label, and at the far end of its line whether it may be left empty. */
.draft__field label,
.submit .form-field > span:first-child {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
}

.draft__mark,
.form-field__optional {
  font-size: 13px;
  font-style: normal;
  font-weight: 400;
  color: var(--muted);
}

.draft__field input,
.draft__field textarea,
.submit .form-field input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--input-line);
  border-radius: 0;
  background: var(--ground);
  font: inherit;
  font-size: 16px;
  color: var(--ink);
}

.draft__field textarea {
  height: auto;
  min-height: 120px;
  padding: 12px 14px;
  line-height: 1.5;
  resize: vertical;
}

.draft__field :is(input, textarea):focus,
.submit .form-field input:focus {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 3px;
}

.draft__limit {
  margin-top: 2px;
}

/*
 * The row as it will stand (_SubmitDock): the brand over the word on
 * water-light, and beside it the drop as a word with too few votes has it.
 */
.submit__dock {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 56px;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--water-light);
}

.submit__dock-words {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.submit__dock-word {
  font-size: 17px;
  overflow-wrap: anywhere;
}

.submit__dock-word--brand {
  font-family: var(--display);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.15;
}

.submit__dock-word.is-empty {
  color: var(--muted);
}

.submit__dock-vote {
  --drop: 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  line-height: 1.2;
  color: var(--muted);
  text-align: center;
}

/*
 * A field no person ever sees, and the reason it is moved off-screen rather
 * than given display: none — that is the first thing an automated form-filler
 * learns to skip, and this one is meant to be filled in.
 */
.trap {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* The word is already in the register. A find, not an error, so it is not
   styled like one. */
.found {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 14px 16px;
  border: 1px solid var(--line);
}

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

.found__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  font-family: var(--display);
  font-size: 21px;
  color: var(--ink);
  text-decoration: none;
}

.found__row:hover .found__term {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.found__brand {
  color: var(--water);
}

/* ---- the box of what is on its way (_SubmitSummary) ---- */

.summary {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 16px 8px;
  border: 1px solid var(--line);
}

.summary__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 6px;
}

.summary__words {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.summary__brand {
  font-family: var(--display);
  font-size: 28px;
  font-weight: 500;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.summary__term {
  font-size: 17px;
  overflow-wrap: anywhere;
}

.summary__lines {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
}

.summary__line {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
  font-size: 15px;
  line-height: 1.4;
}

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

/* A long story is the visitor's own, still on the first step: four lines of
   it say which one it is. */
.summary__line dd {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
}

/* ---- step two: who sends it ---- */

.submit .form-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}

/* The name and the address with the link to /privacy under them, closer to
   the fields than the body's gap would put it: it is about those two fields,
   not a block of its own. */
.submit__person {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.submit .form-field {
  gap: 7px;
}

.submit__privacy {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

.submit__privacy a {
  color: var(--muted);
  text-decoration-color: var(--rule);
  text-decoration-thickness: 1px;
}

.submit__privacy a:hover {
  color: var(--ink);
  text-decoration-color: currentColor;
}

.submit .form-hint {
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

/* Scoped like the rule above, which it would otherwise lose to. */
.submit .form-hint--warn {
  color: var(--danger);
}

/*
 * Whether a name goes on the row. One box and not two options: it is one thing
 * being agreed to, and the line under it says what agreeing means. It is only
 * asked once there is a name to ask it about; submit.js takes it away again
 * when the name goes, and stands the sentence explaining why there is no box in
 * its place.
 */
.credit {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-width: 0;
}

.credit__none {
  max-width: 46ch;
  font-size: 14px;
  line-height: 1.55;
  color: var(--muted);
}

.credit__option {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  cursor: pointer;
}

.credit__option:has(input:focus-visible) .credit__box {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* The tick is drawn at all times and shown only when it is true, so the box
   does not change size as it is ticked. Hidden rather than coloured away: a
   forced palette would paint a transparent tick back in. */
.credit__box {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: 1px solid var(--input-line);
  background: var(--ground);
  color: var(--ground);
}

.credit__box svg {
  visibility: hidden;
}

.credit__option:has(input:checked) .credit__box {
  border-color: var(--ink);
  background: var(--ink);
}

.credit__option:has(input:checked) .credit__box svg {
  visibility: visible;
}

.credit__text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  text-align: left;
}

.credit__label {
  font-size: 15px;
  line-height: 1.3;
  color: var(--ink);
}

.credit__note {
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}

/*
 * Both of them are rendered and the stylesheet shows the one the box is in. A
 * script choosing between them would be a script choosing a Dutch sentence,
 * which is the one thing no script here does.
 */
.credit__note--on,
.credit__option:has(input:checked) .credit__note--off {
  display: none;
}

.credit__option:has(input:checked) .credit__note--on {
  display: block;
}

/* ---- step three: the brand question ---- */

/*
 * The word's drawing beside the question, and the three brands as rows to
 * pick from. Nothing here ever says whether the answer was right: there is no
 * state below for a correct or an incorrect row, because there is no such
 * thing on this screen.
 */
.quiz {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz__lead {
  font-size: 14px;
  color: var(--muted);
}

.quiz__question {
  --size: 48px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.3;
}

.quiz__options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz__option {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 46px;
  padding: 4px 14px;
  border: 1px solid var(--input-line);
  font-family: var(--display);
  font-size: 21px;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
}

.quiz__option:hover {
  background: var(--wash);
}

.quiz__radio {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: 1px solid var(--input-line);
  border-radius: 50%;
  background: var(--ground);
}

.quiz__input:checked + .quiz__option {
  border-color: var(--ink);
  background: var(--water-light);
}

.quiz__input:checked + .quiz__option .quiz__radio::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ink);
}

.quiz__input:focus-visible + .quiz__option {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

.quiz__reroll {
  align-self: flex-start;
  padding: 2px 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 14px;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
}

/* ---- the receipt ---- */

/* No step: the cross alone over a larger title, and what happens next straight
   under it. */
.submit--sent .submit__head-lines {
  gap: 10px;
}

.submit--sent .submit__title {
  font-size: 34px;
}

.submit--sent .submit__body {
  gap: 20px;
  padding-top: 10px;
}

.submit__sent {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 48ch;
}

.submit__sent p {
  margin: 0;
  font-size: 16px;
  line-height: 1.55;
  text-wrap: pretty;
}

@media (max-width: 743px) {
  .submit__sent p {
    font-size: 15px;
  }
}

/*
 * A submission in the review on /admin/submissions, in the shape of the row it
 * wants to become: two columns and a seam, on the ground.
 */
.receipt {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  background: var(--ground);
}

.receipt__cell {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.receipt__cell--l {
  align-items: flex-end;
  padding: 14px 20px 14px 14px;
  text-align: right;
}

.receipt__cell--r {
  padding: 14px 14px 14px 20px;
  border-left: 1px solid var(--line);
}

.receipt__cell--head {
  border-top: 1.5px solid var(--ink);
}

.receipt__cell--rule {
  gap: 4px;
  padding-top: 13px;
  padding-bottom: 15px;
  border-top: 1px dotted var(--line);
}

.receipt__term,
.receipt__brand {
  font-family: var(--display);
  font-size: 26px;
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.018em;
}

.receipt__term {
  color: var(--ink);
}

.receipt__brand {
  color: var(--water);
}

.receipt__category,
.receipt__meta {
  font-size: 13px;
}

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

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

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

.receipt__notes {
  max-width: 60ch;
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink);
  text-wrap: pretty;
}

/*
 * 743px, the same breakpoint the register, the admin list, the dialog and
 * site.js use. On a phone the drawer is a sheet from the bottom edge
 * (P-aandragen-1): less air round everything, the brand and the word one under
 * the other, the arrow back in the head, and the foot stacked with what you
 * came to do as a button the sheet's full width.
 */
@media (max-width: 743px) {
  /* The sheet runs to both edges. Said again here because this width is
     declared after the dialog's own narrow block and would otherwise hold. */
  .dialog--drawer {
    width: 100%;
    max-width: 100%;
  }

  .submit__head {
    gap: 20px;
    padding: 18px 20px 0;
  }

  .submit__step-back {
    display: flex;
  }

  .submit__body {
    gap: 20px;
    padding: 20px 20px 24px;
  }

  .submit--sent .submit__body {
    padding-top: 10px;
  }

  .draft,
  .submit .form-grid {
    gap: 20px;
  }

  .draft__pair {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  /* De lijst's phone rows leave the drop's column empty. */
  .submit__dock-vote {
    visibility: hidden;
  }

  /*
   * Stacked, with what you came to do as the widest thing on it. Reversed
   * rather than reordered by hand: the foot reads left-to-right as
   * secondary-then-primary on a wide screen, and top-to-bottom as
   * primary-then-secondary here — except step one's rule, which stands above
   * its button.
   */
  .submit__foot {
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 10px;
    padding: 14px 20px 26px;
  }

  .submit__foot .btn {
    height: 52px;
  }

  .submit__rule {
    order: 1;
    margin: 0;
    font-size: 13px;
    text-align: center;
  }

  /* The arrow in the head goes back here. */
  .submit__foot-back {
    display: none;
  }
}

/* ---------- de wachtrij ---------- */

/*
 * What has been proposed, in the shape the register is managed in: one sortable
 * list on the ground, ruled off with the same heavy line. .row and everything
 * hanging off it does the work — this section only says where the eight columns
 * fall and draws the three cells /admin has no use for.
 *
 * The two queues the brand question sorts into used to be two headings with a
 * list under each. They are a column now, which is what lets the rest of the
 * queue be ordered by anything else and still show, per row, which ones want a
 * second look.
 */
.row--queue {
  /* Holds the band every row is lit on, below. */
  position: relative;
  grid-template-columns:
    22px minmax(72px, 1.24fr) minmax(64px, 0.86fr) minmax(88px, 0.62fr)
    minmax(60px, 0.74fr) 68px 96px 140px;
}

/* A ticked row is lit the way the row the dialog is open on is (the band,
   under /admin's rows). */
.row--queue:has(.row__pick:checked)::before {
  background: var(--wash);
}

/*
 * Chosen and under the pointer. A row that is already lit has to answer the
 * pointer with something, so hover goes one rung further up the same ladder
 * rather than repeating the shade the row is already wearing — which is what
 * made a chosen row feel dead to the mouse. It takes a token of its own
 * because the rung above --wash is a different one in each palette; see
 * --row-chosen.
 */
.row--queue:has(.row__pick:checked):hover::before {
  background: var(--row-chosen);
}

/* With script a click anywhere on a row opens its review, as on /admin. */
:root.js .row--queue:not(.row--head) {
  cursor: pointer;
}

/* The register's own accent, so the eye can pick the box out of a column of
   ellipsised words without it having to be big. */
.row__pick {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--water);
  cursor: pointer;
}

.row__who {
  font-size: 14px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row__when {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

/* Outlined rather than filled: this sits in a column of plain text and only has
   to be legible as a category, not as a warning. The accent is the ordinary
   case and the ink the one asking for a look — which is the right way round,
   because ink is what the rest of the row is set in and therefore what a glance
   does not skip. */
.queue-tag {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 7px;
  border: 1px solid var(--water);
  border-radius: 2px;
  font-size: 12px;
  color: var(--water);
  white-space: nowrap;
}

.queue-tag--extra {
  border-color: var(--ink);
  color: var(--ink);
}

/*
 * .btn is built for the foot of a dialog, where 38px is right. In a row it
 * stands next to a 32px square, and two controls of different heights side by
 * side read as two different kinds of thing.
 */
.row__open-text {
  height: 32px;
  padding: 0 12px;
}

/* Two spellings of one link; the narrow block below swaps them. */
.row__open-icon {
  display: none;
}

/*
 * Out of the way until something is ticked. :has() can see a checked box where
 * a stylesheet otherwise cannot, which is what keeps the whole bulk path free
 * of script — the same reason the dialog's scroll lock is written as
 * html:has(.dialog[open]) rather than put in admin.js.
 */
.bulk-bar {
  display: none;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-top: 16px;
}

/* The number is a counter, not script. counter-increment sees a checked box
   the same way the :has() below does, and the bar is drawn after every row, so
   by the time it is reached the count is complete. That is the whole of why the
   bulk bar now reads the same with script and without.

   It is also why the label lost its plural. CSS can count but it cannot choose
   between "regel" and "regels": asking whether two rows are ticked would need
   :has() inside :has(), which is invalid, and the checkboxes are never
   siblings of each other to be counted any other way. So the wording is one
   that does not inflect, and nothing has to decide.

   The reset is on main because that is what the rule below already reaches
   for, and .row__pick exists on no other page. */
main {
  counter-reset: picked;
}

.row__pick:checked {
  counter-increment: picked;
}

.bulk-bar__tally::before {
  content: counter(picked);
}

main:has(.row__pick:checked) .bulk-bar {
  display: flex;
}

.bulk-bar__count {
  font-size: 13.5px;
  color: var(--muted);
}

.bulk-bar__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.bulk-bar__clear {
  font-size: 13.5px;
  color: var(--water);
}

/* ---------- de wachtrij op een smal scherm ---------- */

/*
 * The row stacks into the card /admin's does (the generic narrow block, which
 * also takes every row's band away). What falls away here is the selection: a
 * column of checkboxes beside a stacked card is a column of nothing, and the
 * bar it feeds would never have anything to say.
 *
 * 743px is the shared breakpoint again. Keep it in step with site.js.
 */
@media (max-width: 743px) {
  .row__pick,
  .bulk-bar,
  main:has(.row__pick:checked) .bulk-bar {
    display: none;
  }

  /* The badge's column goes with the columns; the card's foot carries the
     same badge at its end. */
  .row__queue {
    display: none;
  }

  .row__open-text {
    display: none;
  }

  .row__open-icon {
    display: flex;
  }
}

/* ---------- nakijken ---------- */

/*
 * Reviewing a submission, in two steps — design "Nakijken scenarios", 3a–3c
 * and 4a–4c. Step 1 asks which trademark it belongs to; step 2 is /admin's
 * mark form (_MarkForm) with the submission in a strip beside it
 * (_SubmissionStrip).
 */

/* The submission's own register: its tab carries the accent, the way the
   strip's offers are addressed to it. */
.form-tab__dot--own {
  background: var(--water);
}

/* The word the form is about to publish is already in this register, under
   another mark — a heads-up with the way to that word in it, where a refused
   save would otherwise have been the first to say so. */
.review__elsewhere {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid var(--danger);
  border-radius: var(--radius);
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink);
}

/* Filling in a word can end without a change, and then the button says so.
   Both are rendered; submissions.js says which applies, and without it the
   plain one stands. */
:root.js .dialog:not(.is-changed) .publish__changed,
:root.js .dialog.is-changed .publish__same,
:root:not(.js) .publish__same {
  display: none;
}

/*
 * The review's foot holds three buttons, and on a phone they only fit on one
 * line when "weggooien" and "terug" give up their words and keep their icons,
 * a bin and an arrow — the two an icon says on its own. The words stay for a
 * screen reader.
 *
 * Asked of the foot's own width, not the screen's: this is about the room the
 * buttons have, and the 743px breakpoint says nothing about that. The number
 * is the widest foot the review draws: step 2 filling in a word nothing has
 * changed in yet — "weggooien" 119, the gap 12, "terug" 84, the actions' gap
 * 10, "afhandelen zonder wijziging" 205. Folded, the same foot needs 303,
 * which a 375px phone has. Change a word or a button's padding and the sums
 * move.
 */
.dialog__foot:has(.btn__fold) {
  container: review-foot / inline-size;
}

@container review-foot (width < 430px) {
  .btn:has(> .btn__fold) {
    width: 38px;
    padding: 0;
  }

  .btn__fold {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

/* ---- step 1: which mark ---- */

.choose__sent {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

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

/* A note keeps its paragraphs, as plain text. */
.choose__notes {
  margin: 0;
  font-size: 14.5px;
  white-space: pre-line;
}

.choose {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

/* A card per answer, the radio laid over the whole of it — hidden by being
   invisible rather than displaced: a radio parked in a corner is somewhere the
   browser scrolls to when it takes focus. */
.choose__option {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  cursor: pointer;
}

.choose__radio,
.combo__radio {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  appearance: none;
  opacity: 0;
  cursor: pointer;
}

.choose__option:has(> .choose__radio:checked),
.choose__option--other:has(.combo__radio:checked) {
  border-color: var(--water);
  box-shadow: inset 0 0 0 0.5px var(--water);
  background: var(--ground);
}

.choose__option:has(> .choose__radio:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* The card holding the list is chosen by what is ticked in the list. It is
   not a control itself, so it does not look like one. */
.choose__option--other {
  cursor: default;
}

.choose__dot {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  border: 1.5px solid var(--input-line);
  border-radius: 50%;
  background: var(--ground);
}

.choose__option:has(> .choose__radio:checked) .choose__dot,
.choose__option--other:has(.combo__radio:checked) .choose__dot {
  border: 5px solid var(--water);
}

.choose__text {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.choose__option--other .choose__text {
  gap: 6px;
}

.choose__line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
}

.choose__name {
  font-size: 15px;
  color: var(--ink);
}

.choose__tag {
  font-size: 12px;
  color: var(--water);
}

.choose__sub {
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
  text-wrap: pretty;
}

/*
 * Every other mark: a <details>, so it opens without script, holding more of
 * the same radio group. Not a <select> — a mark needs its holder and its words
 * beside its name to be told apart.
 *
 * The list opens upwards, over the answers above it, with its search field
 * against the button — design 3a–3c. Upwards because it is the last answer and
 * the foot is right under it; over the others rather than in the flow, so the
 * answers do not move away while one is being looked for. It stays inside the
 * dialog's scrolling middle, which would cut off anything hanging past it, and
 * there is always more above the last answer than the list is tall: the
 * submission and the answers before it. submissions.js scrolls the middle to
 * the list's top edge when it opens.
 */
.combo {
  position: relative;
  max-width: 300px;
}

.combo__button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: 36px;
  padding: 0 10px 0 11px;
  border: 1px solid var(--input-line);
  border-radius: var(--radius);
  background: var(--ground);
  font-size: 14px;
  color: var(--muted);
  cursor: pointer;
  list-style: none;
}

.combo__button::-webkit-details-marker {
  display: none;
}

.combo__button:hover {
  border-color: var(--water);
}

.combo:has(.combo__radio:checked) .combo__label {
  color: var(--ink);
}

.combo__label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Reversed, so the search field — first in the markup and in the tab order —
   is drawn at the bottom, next to the button. */
.combo__panel {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 0;
  z-index: 2;
  display: flex;
  flex-direction: column-reverse;
  width: 340px;
  max-width: calc(100vw - 32px);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
}

.combo__search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.combo__search input {
  flex: 1;
  min-width: 0;
  height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 14px;
  color: var(--ink);
  outline: none;
}

.combo__list {
  display: flex;
  flex-direction: column;
  max-height: 236px;
  padding: 4px 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.combo__option {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 12px 8px 10px;
  border-left: 2px solid transparent;
}

.combo__option.is-active,
.combo__option:hover {
  background: var(--wash);
}

.combo__option:has(.combo__radio:checked) {
  border-left-color: var(--water);
}

.combo__option:has(.combo__radio:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: -2px;
}

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

.combo__name {
  font-size: 14.5px;
  color: var(--ink);
}

.combo__owner {
  font-size: 12.5px;
  color: var(--muted);
}

.combo__words {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--muted);
}

.combo__none {
  padding: 10px 12px;
  font-size: 13px;
  color: var(--muted);
}

/* On a phone the row is half the width /submit gives it wide, and a long
   word broke wherever it ran out of room ("hogedrukrei-niger"). Smaller, and
   broken where the language breaks it — the term carries its lang. */
@media (max-width: 743px) {
  .choose__sent .receipt__term,
  .choose__sent .receipt__brand {
    font-size: 22px;
    -webkit-hyphens: auto;
    hyphens: auto;
  }

  /* The card's own width, which is less than the screen's by the card's
     indent: 340px from there ran off the right edge. */
  .combo__panel {
    right: 0;
    width: auto;
  }
}

/* ---- step 2: the strip ---- */

/*
 * The strip is the form's first child, and on a wide screen it hangs outside
 * the dialog's right edge: positioned against the dialog, which is fixed,
 * rather than against the form, which scrolls — so it neither scrolls with the
 * form nor is clipped by it, and has a scroll of its own.
 *
 * Folded or open is --strip-folded, which submissions.js reads to know which
 * way a click goes. Open by default beside a wide dialog, folded by default at
 * the top of a narrow one; data-folded is a click saying otherwise.
 */
.strip {
  --strip-folded: 0;
  display: flex;
  flex-direction: column;
  background: var(--ground);
  border: 1px solid var(--line);
}

.strip[data-folded="true"] {
  --strip-folded: 1;
}

.strip__rail {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}

.strip__rail:hover {
  color: var(--water);
}

.strip[data-folded="true"] .strip__rail {
  display: flex;
}

.strip[data-folded="true"] .strip__panel {
  display: none;
}

.strip__count {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 10px;
  background: var(--water);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--on-water);
}

.strip__panel {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
}

.strip__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 18px 18px 12px;
  border-bottom: 1.5px solid var(--ink);
}

.strip__who {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

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

.strip__name {
  font-size: 13.5px;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.strip__when {
  font-size: 12.5px;
  color: var(--muted);
}

.strip__fold {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
}

.strip__rows {
  flex: 1;
  min-height: 0;
  margin: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.strip__row {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 9px 18px 10px;
  border-bottom: 1px dotted var(--line);
}

.strip__row dt {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}

/* A row with something left to take over says so beside its label, so the
   offers can wait out of sight until the row is pointed at. The class is
   submissions.js's, which knows whether an offer still applies. */
.strip__row.is-offering dt::after {
  content: "";
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--water);
}

.strip__row dd {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  white-space: pre-line;
  overflow-wrap: anywhere;
  text-wrap: pretty;
}

/* The offers: a button per offer at the row's top right, an icon with its
   words in a tooltip — design 4a–4c. */
.strip__takes {
  position: absolute;
  top: 6px;
  right: 10px;
  display: flex;
  gap: 6px;
}

.strip__take {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ground);
  color: var(--water);
  box-shadow: var(--shadow-button);
  cursor: pointer;
}

.strip__take:hover {
  border-color: var(--water);
}

/*
 * Placed against the row's offers rather than against its own button, so its
 * right edge is the last button's: against the first of the notes' two, the
 * longest words ran out of the strip on the left. Above the button, except on
 * the first row, where above is the strip's head — outside the rows' scroll,
 * which would cut it off.
 */
.strip__tip {
  position: absolute;
  right: 0;
  bottom: calc(100% + 6px);
  z-index: 1;
  display: none;
  width: max-content;
  max-width: 236px;
  padding: 6px 9px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  font-size: 12.5px;
  line-height: 1.3;
  text-align: left;
  color: var(--ink);
  pointer-events: none;
}

.strip__row:first-child .strip__tip {
  top: calc(100% + 6px);
  bottom: auto;
}

.strip__take:focus-visible .strip__tip {
  display: block;
}

/*
 * With a mouse the offers show while the row is pointed at, or holds the
 * focus — the buttons can be tabbed to while unseen, and appear as they are.
 * A finger has no hover, so on a touch screen they are always there, and the
 * label is as tall as they are, so the value starts underneath them.
 */
@media (hover: hover) {
  .strip__takes {
    opacity: 0;
    pointer-events: none;
    transition: opacity 120ms;
  }

  .strip__row:hover .strip__takes,
  .strip__row:focus-within .strip__takes {
    opacity: 1;
    pointer-events: auto;
  }

  .strip__row.is-offering:hover,
  .strip__row.is-offering:focus-within {
    background: var(--wash);
  }

  .strip__take:hover .strip__tip {
    display: block;
  }
}

@media (hover: none) {
  .strip__row.is-offering dt {
    min-height: 25px;
  }
}

/* An offer for the submission's own register stands down while another
   register's tab is open: it would fill a field that is not on screen. The
   tab is found by its --own class, so no language is named here. */
.dialog:has(.form-tab__head--own .form-tab__radio:not(:checked)) [data-scope="word"] {
  display: none;
}

/*
 * Wide, the strip beside the dialog. The dialog stops clipping what it holds,
 * so it draws the foot's corners itself.
 *
 * The form stands in the middle, where every dialog does, and the strip hangs
 * off its right edge — until the strip would run past the screen's edge. Then
 * the form moves left just far enough, and below that, from where it is up
 * against the left edge, it narrows. Both are worked out from the open strip's
 * width, so folding it never moves the form.
 */
@media (min-width: 744px) {
  .dialog:has(.strip) {
    --strip-w: 260px;
    --form-w: min(660px, calc(100% - 32px - var(--strip-w)));
    left: min(50%, calc(100% - 16px - var(--strip-w) - var(--form-w) / 2));
    width: var(--form-w);
    overflow: visible;
    box-shadow: none;
  }

  /*
   * The form's shadow falls over the strip, as if the strip were tucked under
   * it. The dialog's own shadow is drawn beneath everything it holds, and the
   * strip is inside it, so the shadow moves to a layer over the strip: its
   * box is the dialog's, and a box shadow is only ever drawn outside the box,
   * so all it covers is the strip and the backdrop.
   *
   * On the right the box stops at the padding edge, where the strip begins
   * (left: 100%), not at the border's outer edge: one pixel further and the
   * strip's first column lay inside the box, never shaded — a thin light line
   * between the form and the shaded strip.
   */
  .dialog:has(.strip)::after {
    content: "";
    position: absolute;
    inset: -1px 0 -1px -1px;
    z-index: 1;
    border-radius: inherit;
    box-shadow: var(--shadow);
    pointer-events: none;
  }

  .dialog:has(.strip) .dialog__foot {
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  }

  .strip {
    position: absolute;
    top: 18px;
    bottom: 18px;
    left: 100%;
    width: var(--strip-w);
    border-left: 0;
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    box-shadow: var(--shadow);
    /* Its own shadow stops at the dialog's edge: cast over the form, it drew
       a dark seam between the two. */
    clip-path: inset(-100px -100px -100px 0);
  }

  .strip[data-folded="true"] {
    width: 40px;
  }

  /* Folded, a rail down the dialog's edge: the way back in, and how many
     offers are left. */
  .strip__rail {
    flex: 1;
    flex-direction: column;
    padding: 16px 0;
  }

  .strip__rail-label {
    writing-mode: vertical-rl;
  }
}

/*
 * Narrow, the strip stands at the top of the form, folded to one bar that
 * says how many offers are left — design 1d. Open, it runs in the form's own
 * flow: a second scroll inside a sheet is one a thumb keeps missing — Safari
 * handed the swipe to the form. Without script there is no way to fold or
 * unfold it, so it stands open.
 */
@media (max-width: 743px) {
  .strip {
    flex: 0 0 auto;
    border-radius: var(--radius);
  }

  :root.js .strip:not([data-folded="false"]) {
    --strip-folded: 1;
  }

  :root.js .strip:not([data-folded="false"]) .strip__rail {
    display: flex;
  }

  :root.js .strip:not([data-folded="false"]) .strip__panel {
    display: none;
  }

  .strip__rail {
    width: 100%;
    height: 44px;
    padding: 0 14px;
  }

  /* It folds up and down here rather than sideways, and its arrows say so. */
  .strip__chevron,
  .strip__fold svg {
    rotate: 90deg;
  }

  .strip__rows {
    overflow: visible;
  }

  /* Open, the whole head folds it again, as the whole bar opened it: the
     fold button is stretched over the head, and the name's link lies on top. */
  .strip__head {
    position: relative;
  }

  .strip__fold::after {
    content: "";
    position: absolute;
    inset: 0;
  }

  .strip__name a {
    position: relative;
    z-index: 1;
  }
}


/* ---------- het bonnetje ---------- */

/*
 * What publishing did, in three lines. It exists because the submission is gone
 * by the time this renders: there is no row to go back and look at, so the
 * screen has to say what became of it — including the one thing that cannot be
 * looked up afterwards, the address to write to.
 */
.done {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 26px 24px 28px;
}

.done__head {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

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

.done__title {
  margin: 0;
  font-family: var(--display);
  font-size: 29px;
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.done__lines {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--line);
}

.done__line {
  display: flex;
  gap: 14px;
  padding: 11px 0;
  border-bottom: 1px dotted var(--line);
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  text-wrap: pretty;
}

.done__label {
  flex: 0 0 92px;
  padding-top: 3px;
  font-size: 13px;
  color: var(--muted);
}

.done__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.done__link {
  font-size: 14px;
  color: var(--water);
}

@media (max-width: 743px) {
  .done__line {
    flex-direction: column;
    gap: 2px;
  }

  .done__label {
    flex: 0 0 auto;
    padding-top: 0;
  }
}

/* ---------- privacy ---------- */

/*
 * What the site keeps about a visitor (canvas "Nieuwe look voorstellen",
 * P-privacy): the heading and the lead as a text page has them, then one
 * section per subject, each under a rule, its title in the text face.
 */
.privacy__title {
  margin: 64px 0 0;
  font-family: var(--display);
  font-size: 54px;
  font-weight: 400;
  line-height: 1.08;
  color: var(--ink);
  text-wrap: balance;
}

/* The same size as every lead (.page-article). */
.privacy__lead {
  margin: 0;
  padding: 24px 0 0;
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink);
  text-wrap: pretty;
}

.privacy__rows {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 32px;
  padding-bottom: 80px;
}

.privacy__row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.privacy__label {
  margin: 0;
  font-size: 21px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink);
  text-wrap: balance;
}

.privacy__text {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.privacy__text p {
  margin: 0;
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  text-wrap: pretty;
}

/* "toon het adres": a button, because it posts, set as the link it stands in
   for, because it sits in a sentence — as every link in running text is. Font
   and colour come from the base button rule; this only takes the button off
   it. */
.privacy__reveal {
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
}

.privacy__reveal:hover {
  text-decoration-color: currentColor;
}

/* The button and the full stop after it, on one line. A button is an atomic
   inline, and Firefox may wrap after one whatever stands beside it — the full
   stop alone on the next line; Chromium does not, so the preview never shows
   it. The span itself is an ordinary inline: the space before it is still a
   place to wrap. */
.privacy__keep {
  white-space: nowrap;
}

@media (max-width: 743px) {
  /* The page runs edge to edge below this width, so the text carries the
     gutter itself — the header already carries its own. */
  .privacy {
    padding: 0 var(--gutter);
  }

  .privacy__title {
    margin-top: 28px;
    font-size: 38px;
    line-height: 1.1;
  }

  .privacy__lead {
    padding-top: 20px;
    font-size: 16px;
  }

  .privacy__rows {
    gap: 20px;
    margin-top: 20px;
    padding-bottom: 40px;
  }

  .privacy__row {
    gap: 8px;
    padding-top: 18px;
  }

  .privacy__label {
    font-size: 19px;
  }

  .privacy__text p {
    font-size: 15px;
    line-height: 1.6;
  }
}

/* ---------- a page from /admin/pages ---------- */

/*
 * /about, and every page written in /admin/pages (canvas "Nieuwe look
 * voorstellen", W-uitleg and P-uitleg): one column of text, 680px, the heading
 * in the display face and the paragraph straight after it, the lead, larger.
 * Nothing in it carries a class, because the maintainer writes it in Markup
 * and can ask for none: everything is set by the element it is.
 *
 * Every block takes the article's 24px above it; a heading takes more, so a
 * section reads as one. Lists, quotes and strong come from the shared rules
 * with .word__notes, which are all :where() so these win.
 */
/* The text the start page's size (16px, 15px on a phone), as its lead is,
   not the 19px of W-uitleg and P-uitleg. */
.page-article {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 64px 0 80px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
}

.page-article > * {
  margin: 24px 0 0;
  text-wrap: pretty;
}

.page-article > :first-child {
  margin-top: 0;
}

.page-article > h1 {
  font-family: var(--display);
  font-size: 54px;
  font-weight: 400;
  line-height: 1.08;
  color: var(--ink);
}

/* The paragraph under the heading is the lead: the start page's size (18px,
   16px on a phone), not the 23px of W-uitleg and P-uitleg. */
.page-article > h1 + p {
  font-size: 18px;
  line-height: 1.55;
}

.page-article > h2 {
  margin-top: 44px;
  font-family: var(--display);
  font-size: 32px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--ink);
}

/* The small heading in the text face, set off by its weight. */
.page-article > h3 {
  margin-top: 32px;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink);
}

.page-article > h3 + * {
  margin-top: 10px;
}

/* A link in running text — a page's, a word's story, /privacy's — in the text's
   own colour, underlined in water. The other links in a page — a brand, a
   note's number, the link beside a heading — carry a class or stand in one,
   and set themselves. */
:is(.page-article, .word__notes, .privacy__text) a:where(:not([class])) {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

:is(.page-article, .word__notes, .privacy__text) a:where(:not([class])):hover {
  text-decoration-color: currentColor;
}

/* ":label[verwaterd]" in a page: the vote bar's word, in a thin box set in
   the running text — the start page's vote sentence names the bar's two
   answers this way. Also the formatting card's example. */
.markup-label {
  display: inline-block;
  padding: 0 0.42em;
  border: 1px solid var(--line);
  background: var(--ground);
  font-size: 0.82em;
  font-weight: 500;
  line-height: 1.55;
  white-space: nowrap;
  vertical-align: 0.06em;
  color: var(--ink);
}

/* A table scrolls in its own box, so a wide one on a phone never moves the
   page. Set like a list of facts, not a spreadsheet: a rule over every row
   and the head quiet over them. No column is bold of itself, as W-uitleg's
   archive has its years: a cell is bold where its writer put **…**. */
.markup-table {
  max-width: 100%;
  overflow-x: auto;
}

/* A step under the page's 16px text; on a phone as large as it. */
.markup-table table {
  min-width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.55;
}

.markup-table :is(th, td) {
  padding: 14px 16px 14px 0;
  text-align: left;
  vertical-align: top;
}

.markup-table td {
  border-top: 1px solid var(--line);
}

/* Every column but the last as narrow as what it holds, and the last the
   rest, as the archive's year column is. Left to the browser, a table of
   short cells split its width into halves, and a pair read as two things
   with a gap between them. A cell there does not wrap, so a table too wide
   for its column scrolls in its box. */
.markup-table :is(th, td):not(:last-child) {
  width: 1%;
  white-space: nowrap;
}

.markup-table :is(th, td):last-child {
  padding-right: 0;
}

.markup-table th {
  padding-top: 0;
  padding-bottom: 8px;
  font-size: 14px;
  font-weight: 400;
  color: var(--muted);
  white-space: nowrap;
}

.markup-table .markup-brand {
  font-size: 1.12em;
}

.markup-table .is-center {
  text-align: center;
}

.markup-table .is-right {
  text-align: right;
}

.markup-figure img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ---------- a page's brands, notes and headings ---------- */

/*
 * What a page's markup gained with Markup.Directives.cs and
 * Markup.Footnotes.cs: a brand named in the text, a card about one,
 * footnotes and the link beside a heading. Three widths for the notes: up to
 * 743px, the site's breakpoint; from there to 1239px, where they stand at the
 * foot of the page; and from 1240px, where the margin beside the column holds
 * them (W-uitleg): the page's 1056px of content less the column and the 56px
 * between, 320px. That third width is this stylesheet's alone: site.js never
 * asks for it, it asks whether a note in the margin is drawn.
 */

/* ":brand[Aspirin]": the brand in the display face, in the running text. A
   link to its page when de lijst has it, underlined in water as a link in
   running text is; the card a mouse brings up over it is _BrandCards'. Line
   height 1: at the paragraph's own, the other face made its line a few pixels
   taller than the rest. */
.markup-brand {
  font-family: var(--display);
  font-weight: 500;
  line-height: 1;
  color: var(--ink);
}

a.markup-brand {
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

a.markup-brand:hover {
  text-decoration-color: currentColor;
}

/* The card: the brand over its holder, the word it became under a rule, and
   the way to its page. Placed by site.js against the word, as the formatting
   card is against its button. */
.brand-tip {
  width: 300px;
  max-width: calc(100vw - 16px);
  padding: 16px 16px 12px;
  border: 1px solid var(--line);
  background: var(--ground);
  box-shadow: var(--shadow-pop);
  color: var(--ink);
}

:root.js .brand-tip {
  inset: auto;
  margin: 0;
}

.brand-tip__row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
}

.brand-tip__side {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.brand-tip__side--term {
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.brand-tip__name {
  font-family: var(--display);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.brand-tip__word {
  font-size: 17px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.brand-tip__caps {
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}

.brand-tip__foot {
  display: flex;
  justify-content: flex-end;
  margin: 12px 0 0;
  font-size: 14px;
  line-height: 1.4;
}

.brand-tip__foot a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/*
 * ":::brand[…]", a card about a brand, between the paragraphs at every
 * width: under a rule of ink, the year over the brand, its story, and the
 * ways on.
 */
.brand-card {
  padding: 18px 0 4px;
  border-top: 2px solid var(--ink);
}

.brand-card__year {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--muted);
}

.brand-card__name {
  margin: 4px 0 0;
  font-family: var(--display);
  font-size: 32px;
  font-weight: 500;
  line-height: 1.15;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.brand-card__text {
  margin: 8px 0 0;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink);
}

.brand-card__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 14px 0 0;
  font-size: 15px;
  line-height: 1.4;
}

.brand-card__foot a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

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

/* With no source before it, the way to the page still stands at the right. */
.brand-card__list {
  margin-left: auto;
}

/* With its mark's drawing (canvas Uitwerking · een tekening in de merkkaart,
   A): wide, the drawing at the top left and the head and the story running
   round it and on under it; the ways on below it, however short the story.
   On a phone (B, further down) it stands beside the head instead. */
.brand-card--drawn {
  display: flow-root;
}

.brand-card__drawing {
  --size: 112px;
  float: left;
  margin: 0 20px 6px 0;
}

.brand-card--drawn .brand-card__foot {
  clear: left;
}

/* The number a footnote is referred to by, in water. Raised by position
   rather than vertical-align, which made the line it stands on a few pixels
   taller than the others. */
.note-ref {
  position: relative;
  top: -0.6em;
  margin-left: 1px;
  font-family: var(--body);
  font-size: 0.62em;
  font-style: normal;
  line-height: 0;
  vertical-align: baseline;
}

.note-ref a {
  position: relative;
  padding: 0 1px;
  font-weight: 600;
  color: var(--water);
  text-decoration: none;
}

/* A digit is a small thing to hit with a finger: the link reaches a little
   further than it is drawn. Not so far that a tap on the word before it,
   often a link of its own, lands here instead. */
.note-ref a::after {
  content: "";
  position: absolute;
  inset: -12px -8px;
}

/* While its note is open in the sheet, below 744px. */
.note-ref a.is-open {
  background: var(--water-light);
  box-shadow: 0 0 0 2px var(--water-light);
}

/* The note beside its line, from 1240px; nowhere else. */
.note-side {
  display: none;
}

/* The notes at the foot of the page, under a rule. Each item's "Noot 2" is
   for the sheet, which copies the item; here the number in front says it. */
.page-article > .notes {
  margin-top: 48px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.notes__heading {
  margin: 0;
  font-family: var(--body);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--ink);
}

.notes__list {
  margin: 10px 0 0;
  padding-left: 1.4em;
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}

.notes__list li::marker {
  font-weight: 600;
  color: var(--water);
}

.notes__item + .notes__item {
  margin-top: 6px;
}

/* The note a number jumped to, lit on water-light. */
.notes__item:target {
  background: var(--water-light);
  box-shadow: 0 0 0 6px var(--water-light);
}

.notes__label {
  display: none;
}

.notes__back {
  color: var(--water);
  text-decoration: none;
}

/*
 * The link to copy beside an h2 or an h3: a small icon in the left margin,
 * only where there is a mouse to point at the heading with and a margin to
 * stand in — at the narrowest the page's own 32px, which it fits in. site.js
 * copies the address and turns it into a tick for a moment; without script it
 * is a link to the heading.
 */
.page-article :is(h2, h3) {
  position: relative;
}

.heading-link {
  display: none;
  position: absolute;
  right: calc(100% + 2px);
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--water);
  text-decoration: none;
  opacity: 0;
  transition: opacity 0.12s ease;
}

/* Level with the heading's first line: half its line, less half the icon. */
h2 > .heading-link {
  top: calc(0.6em - 14px);
}

h3 > .heading-link {
  top: calc(0.7em - 14px);
}

.heading-link__done,
.heading-link.is-copied .heading-link__link {
  display: none;
}

.heading-link.is-copied .heading-link__done {
  display: block;
}

@media (hover: hover) and (min-width: 744px) {
  .heading-link {
    display: flex;
  }

  :is(h2, h3):hover > .heading-link,
  .heading-link:focus-visible,
  .heading-link.is-copied {
    opacity: 1;
  }
}

/* The sheet a footnote opens in below 744px (_NoteSheet): a narrow dialog,
   holding a copy of the note's item and the way to the list. */
.dialog--note {
  padding: 0 var(--gutter) 24px;
}

.note-sheet__body {
  padding: 8px 0 18px;
}

/* It takes the focus only so the link under it does not (_NoteSheet). */
.note-sheet__body:focus {
  outline: none;
}

.note-sheet__body .notes__label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--water);
}

/* A phone's text size, as the page the sheet lies over. */
.note-sheet__body .notes__text {
  display: block;
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
}

.note-sheet__all {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.note-sheet__icon {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--muted);
}

.note-sheet__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.note-sheet__label {
  font-size: 16px;
  line-height: 1.3;
}

.note-sheet__hint {
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
}

/*
 * Wide, the margin beside the column holds the notes, each floated out to
 * the right from its number's line and stacked in the order of the text when
 * they meet (clear). The number hangs before the note's text. A float only
 * reaches out of the block it stands in when that is not a formatting context
 * of its own, so here the article is a flow-root rather than the flex column
 * it is at every other width, and a quote is a block: a flex item contains its
 * floats, and the paragraph around a note grew to the note's height.
 */
@media (min-width: 1240px) {
  .page-article {
    display: flow-root;
  }

  .page-article blockquote {
    display: block;
  }

  .page-article blockquote > * + * {
    margin-top: 0.5em;
  }

  .note-side {
    position: relative;
    display: block;
    float: right;
    clear: right;
    width: 320px;
    margin: 0 -376px 16px 0;
    padding-left: 18px;
    /* Scrolled into view by its number (site.js), it stops short of the
       window's bottom edge rather than against it. */
    scroll-margin-bottom: 24px;
    font-family: var(--body);
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.5;
    text-align: left;
    color: var(--muted);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
  }

  .note-side__number {
    position: absolute;
    left: 0;
    font-weight: 600;
    color: var(--water);
  }

  /* A number clicked lights its note, which is right there, rather than
     jumping to a list a sighted reader does not see at this width. */
  .note-side.is-lit {
    background: var(--water-light);
    box-shadow: 0 0 0 6px var(--water-light);
  }

  /* The notes stand beside their lines; the list is a screen reader's. */
  .page-article > .notes {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

@media (max-width: 743px) {
  /* The page runs edge to edge below this width, as on /privacy. */
  .text-page {
    padding: 0 var(--gutter);
  }

  .page-article {
    padding: 28px 0 40px;
    font-size: 15px;
    line-height: 1.65;
  }

  .page-article > * {
    margin-top: 20px;
  }

  .page-article > h1 {
    font-size: 34px;
    line-height: 1.1;
  }

  .page-article > h1 + p {
    font-size: 16px;
  }

  .page-article > h2 {
    margin-top: 36px;
    font-size: 26px;
  }

  .page-article > h3 {
    margin-top: 28px;
    font-size: 17px;
  }

  .markup-table table {
    font-size: 15px;
  }

  .brand-card__name {
    font-size: 28px;
  }

  /* The drawing beside the year and the name, level with them, and the
     story under both over the full width (canvas Uitwerking · een tekening
     in de merkkaart, B): three short lines beside a drawing would be all a
     column this narrow has room for. */
  .brand-card--drawn {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 14px;
    align-items: center;
  }

  .brand-card--drawn > * {
    grid-column: 1 / -1;
  }

  .brand-card--drawn > .brand-card__drawing {
    --size: 64px;
    grid-column: 1;
    float: none;
    margin: 0;
  }

  .brand-card--drawn > .brand-card__head {
    grid-column: 2;
  }
}

/* ---------- the front page's intro ---------- */

/*
 * The intro (_StartHero; canvas "Nieuwe look voorstellen", Uitwerking · de
 * lijst als voorpagina, intro eerst): the words of /start, large, filling the
 * first screen under the header and the strip that stays with it, and under
 * them the two ways down. --nav-h and --offer-h are site.js's measurements;
 * before it has run, the header's own height stands in.
 */
.hero {
  display: grid;
  align-content: center;
  min-height: calc(100svh - var(--nav-h, 88px) - var(--offer-h, 0px));
  padding: 40px 0 56px;
}

.hero__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
}

.hero__text h1 {
  max-width: 900px;
  margin: 0;
  font-family: var(--display);
  font-size: clamp(44px, 5.9vw, 76px);
  font-weight: 400;
  line-height: 1.04;
  text-wrap: balance;
}

/* Not as B-start has it: there the lead is 20px and the lines under it are
   grey, and once the text was drawn at its full weight the lead stood too
   loud above a line that faded away. Now 18px over lines in the ink. */
.hero__text p {
  max-width: 620px;
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
}

.hero__text h1 + p {
  font-size: 18px;
  line-height: 1.55;
}

/* "Naar de lijst ↓" as the black button, "Verder lezen ↓" beside it, a
   smaller link; wrapping under it where there is no room. */
.hero__ways {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 24px;
  margin-top: 10px;
}

.hero__to-list {
  padding: 14px 22px;
  border: 1px solid var(--ink);
  background: var(--ink);
  font-size: 16px;
  font-weight: 500;
  color: var(--ground);
  text-decoration: none;
}

.hero__to-list:hover {
  border-color: var(--muted);
  background: var(--muted);
}

.hero__read {
  font-size: 15px;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/* Where the ways down land: a place, not a control, so the focus the
   keyboard is handed there draws no ring around the whole of it. */
.list-section:focus,
.read-more:focus {
  outline: none;
}

/* Verder lezen: the pages placed there, on water-light. */
.read-more {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 40px;
  margin: 56px 0 0;
  padding: 32px 36px;
  background: var(--water-light);
}

.read-more__head h2 {
  margin: 0;
  padding-top: 6px;
  font-size: 14px;
  font-weight: 600;
}

.read-more__rows {
  display: flex;
  flex-direction: column;
  gap: 28px;
  max-width: 680px;
}

.read-more__row {
  color: var(--ink);
  text-decoration: none;
}

.read-more__body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.read-more__name,
.read-more__go {
  display: none;
}

.read-more__title {
  font-family: var(--display);
  font-size: 30px;
  line-height: 1.15;
}

.read-more__lead {
  font-size: 16px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.read-more__more {
  align-self: flex-start;
  font-size: 16px;
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

@media (max-width: 899px) {
  .read-more {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }
}

@media (max-width: 743px) {
  .hero {
    padding: 28px var(--gutter) 32px;
  }

  .hero__text h1 {
    font-size: 44px;
  }

  .hero__text h1 + p {
    font-size: 16px;
  }

  .hero__text p {
    font-size: 15px;
  }

  .read-more {
    margin: 24px var(--gutter) 0;
    padding: 18px 18px 20px;
  }

  .read-more__head h2 {
    padding: 0;
    font-size: 13px;
  }

  .read-more__title {
    font-size: 22px;
  }

  .read-more__lead {
    font-size: 15px;
  }
}

/* ---------- the 404 (/not-found) ---------- */

/*
 * Canvas "Nieuwe look voorstellen", W-404 and P-404. Wide, two columns: the
 * empty drop on the left and the text beside it; on a phone the drop above
 * the text, small, and the ways out the column's full width. The foot spans
 * both.
 */
.lost {
  display: grid;
  grid-template-columns: 360px minmax(0, 640px);
  align-items: start;
  column-gap: 72px;
  padding-top: 80px;
}

.lost .site-foot {
  grid-column: 1 / -1;
}

/* The drop as a word with too few votes has it, drawn large: its dashes are
   lengths on the screen (the stroke does not scale), so they are set for
   this size. */
.lost__mark {
  display: flex;
  justify-content: center;
  padding-top: 10px;
}

.lost__mark .drop--few {
  --drop: 340px;
  stroke-width: 5;
  stroke-dasharray: 14 11;
}

.lost__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
  padding-bottom: 80px;
}

.lost__kicker {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

.lost__heading {
  margin: 0;
  font-family: var(--display);
  font-size: 52px;
  font-weight: 400;
  line-height: 1.12;
  color: var(--ink);
}

/* The address on water-light, in the text face: it is what was typed. Breaks
   after a slash (a <wbr> in the view), and anywhere in a piece too long for
   the column. Cut off at 50 characters before it gets here. */
.lost__address {
  padding: 0 6px;
  background: var(--water-light);
  font-family: var(--body);
  font-size: 0.8em;
  font-weight: 500;
  overflow-wrap: anywhere;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.lost__rule {
  width: 48px;
  height: 2px;
  margin: 4px 0;
  background: var(--rule);
}

.lost__joke {
  margin: 0;
  font-family: var(--display);
  font-size: 24px;
  font-style: italic;
  line-height: 1.45;
}

/* The word the joke is about, as a link to its page: its drawing, the brand
   underlined as a link in running text is, and the word under it. There even
   when the joke names it. */
.lost__word {
  --size: 48px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}

.lost__words {
  display: flex;
  flex-direction: column;
}

.lost__brand {
  font-family: var(--display);
  font-size: 28px;
  font-weight: 500;
  line-height: 1.25;
  text-decoration: underline;
  text-decoration-color: var(--water);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.lost__word:hover .lost__brand {
  text-decoration-color: currentColor;
}

.lost__term {
  font-size: 15px;
}

.lost__ways {
  display: flex;
  gap: 14px;
  margin-top: 18px;
}

.lost__way {
  height: 50px;
  padding: 0 22px;
  border-color: var(--ink);
  border-radius: 0;
  background: var(--ground);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0;
}

.lost__way:hover {
  background: var(--wash);
}

.lost__way--start {
  padding: 0 26px;
  background: var(--ink);
  color: var(--ground);
}

.lost__way--start:hover {
  border-color: var(--muted);
  background: var(--muted);
  color: var(--ground);
}

/* Between the phone and the wide page the drop gives way first. */
@media (max-width: 1100px) {
  .lost {
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    column-gap: 48px;
  }

  .lost__mark .drop--few {
    --drop: 240px;
    stroke-width: 4;
    stroke-dasharray: 11 9;
  }
}

/* One column, the drop small above the text, and the ways out the column's
   full width at its foot. The page runs edge to edge below this width, as on
   a text page. */
@media (max-width: 743px) {
  .lost {
    display: block;
    padding: 36px var(--gutter) 0;
  }

  .lost__mark {
    justify-content: flex-start;
    padding: 0 0 18px;
  }

  .lost__mark .drop--few {
    --drop: 120px;
    stroke-width: 2;
    stroke-dasharray: 6 4;
  }

  .lost__text {
    align-items: stretch;
    gap: 18px;
    padding-bottom: 32px;
  }

  .lost__kicker,
  .lost__rule,
  .lost__word {
    align-self: flex-start;
  }

  .lost__heading {
    font-size: 34px;
  }

  .lost__joke {
    font-size: 20px;
  }

  .lost__brand {
    font-size: 24px;
  }

  .lost__ways {
    flex-direction: column;
    gap: 10px;
    margin-top: 22px;
  }

  .lost__way {
    justify-content: center;
    height: 52px;
  }
}

/* ---------- the import dialog ---------- */

/*
 * Importing and exporting words on /admin (Index.Import.cs, _ImportDialog,
 * _ImportTable, _ImportFoot). Design canvas "Importeren en exporteren": 2, 2B,
 * 2C and 2D for the upload, 3D for the preview, 4 for what it did, 5A for
 * narrow.
 */

/* The way in, in the header's row beside "Nieuw woord": a round icon the
   size of the theme switch, which it stands next to, and which unlike it
   stays an icon — its name is the browser's tooltip. It opens the dialog,
   and exporting is done from inside it. */
.import-open {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: var(--ground);
  border: 1px solid var(--rule);
  border-radius: 50%;
  color: var(--muted);
  transition:
    border-color 0.2s ease,
    color 0.2s ease;
}

.import-open:hover {
  color: var(--ink);
  border-color: var(--ink);
}

.import-open:focus-visible {
  border-radius: 50%;
}

/*
 * The preview needs the room a table of nine columns takes, and a height of
 * its own so its middle scrolls and its head and foot stay. Set by what the
 * dialog holds, as .dialog--page is: the upload and the done face keep a
 * mark's width.
 */
.dialog:has(.import) {
  width: min(1320px, calc(100vw - 32px));
  height: 88vh;
}

.dialog__title.import__file {
  overflow-wrap: anywhere;
}

/*
 * The scrolling middle: no padding of its own, since the table and the tabs'
 * rule run to its edges. It scrolls both ways once the table is wider than
 * the dialog — always on a phone, and on a screen too narrow for nine columns
 * — and the headings have to stay at its top and the row number and "hoort
 * bij" at its left. Two sticky directions only work inside one box that
 * scrolls both ways, so this is that box, and what stands above the table is
 * pinned to its left edge at its width (100cqi) rather than scrolling away.
 */
.import {
  gap: 0;
  padding: 0;
  overflow: auto;
  container-type: inline-size;
}

/* As wide as the table when that is wider than the dialog: something has to
   be, for what is pinned at the left to have room to stay there. */
.import__sheet {
  width: max-content;
  min-width: 100%;
}

.import__summary,
.import__swipe,
.import__refused,
.import-tabs {
  position: sticky;
  left: 0;
  box-sizing: border-box;
  width: 100cqi;
}

.import__summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px 32px;
  padding: 16px 24px 18px;
  border-bottom: 1px solid var(--line);
}

.import-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 7px;
  min-width: 0;
}

.import-block__title {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.import-block__say {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
  text-wrap: pretty;
}

.import-block__columns {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13.5px;
  color: var(--ink);
}

/* A column as the file names it, drawn as a small label. */
.import-colname {
  display: inline-block;
  margin-right: 6px;
  padding: 0 0.42em;
  border: 1px solid var(--rule);
  border-radius: 2px;
  background: var(--ground);
  font-size: 13px;
  line-height: 1.55;
  white-space: nowrap;
  vertical-align: 0.1em;
  color: var(--ink);
}

/* An ⓘ and its card (_ImportInfo): a button, opening a popover like the
   legend's and the notes' "opmaak". */
.import-info {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  vertical-align: -0.12em;
  color: var(--muted);
  cursor: help;
}

.import-info:hover {
  color: var(--water);
}

.import-info:focus-visible {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* The card hangs in the DOM where its button is — in an uppercase heading,
   in a red reason — and inherits from there; it speaks plainly
   whatever stands around it. */
.import-tip {
  max-width: min(340px, var(--tip-room, calc(100vw - 16px)));
  font-size: 12.5px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: normal;
  text-align: left;
  text-transform: none;
  white-space: normal;
  color: var(--ink);
}

/* The notes' choice, drawn as a band of two, the tab strip's pills smaller
   (the band and the chosen pill are drawn with the tabs'). */
.import-segment {
  display: inline-flex;
  gap: 3px;
  padding: 3px;
}

.import-segment__option {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 12px;
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  cursor: pointer;
}

.import-segment__option:has(input:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* Only narrow, where the table is wider than the screen. */
.import__swipe {
  display: none;
}

.import__refused {
  margin: 0;
  padding: 12px 24px 0;
}

/* ----- the tabs ----- */

.import-tabs {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  padding: 12px 24px 0;
  border-bottom: 1px solid var(--line);
}

.import-tabs__tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: var(--radius) var(--radius) 0 0;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  cursor: pointer;
}

.import-tabs__tab b {
  font-size: 11px;
  font-weight: 400;
  color: var(--muted);
}

.import-tabs__tab:hover {
  color: var(--ink);
}

/* The open tab stands on the table, its bottom edge over the rule. */
.import-tabs__tab:has(input:checked) {
  top: 1px;
  border-color: var(--line);
  background: var(--ground);
  color: var(--ink);
}

.import-tabs__tab:has(input:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: -2px;
}

.import-tabs__help {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  align-self: center;
  margin-left: auto;
}

/* "keuzes terugzetten": as quiet as "labels" beside it, but a button that
   does something rather than one that explains. */
.import-reset {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 12.5px;
  line-height: 1;
  color: var(--muted);
  white-space: nowrap;
  cursor: pointer;
}

.import-reset:hover {
  color: var(--water);
}

.import-reset:focus-visible {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

/* Under any tab but "alles" a row's label would only repeat the tab. */
.import:has(.import-tabs__tab input:checked:not([value="all"])) .import-act__tag {
  display: none;
}

.import:has(#import-tab-error:checked) .import-row:not([data-outcome="error"]),
.import:has(#import-tab-newMark:checked) .import-row:not([data-outcome="newMark"]),
.import:has(#import-tab-newWord:checked) .import-row:not([data-outcome="newWord"]),
.import:has(#import-tab-change:checked) .import-row:not([data-outcome="change"]),
.import:has(#import-tab-same:checked) .import-row:not([data-outcome="same"]),
.import:has(#import-tab-skip:checked) .import-row:not([data-outcome="skip"]) {
  display: none;
}

/* The legend: the labels, then the two colours a cell can have. */
.import-legend {
  max-width: min(340px, var(--tip-room, calc(100vw - 16px)));
}

.import-legend__head {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.import-legend__head--rule {
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.import-legend__rows {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 6px 14px;
  margin: 0;
}

.import-legend__rows dt,
.import-legend__rows dd {
  margin: 0;
}

.import-legend__swatch {
  display: block;
  width: 14px;
  height: 14px;
  border: 1px solid var(--line);
  border-radius: 2px;
}

.import-legend__swatch--changed {
  background: var(--tint);
}

.import-legend__swatch--cleared {
  background: var(--danger-tint);
}

.import-legend__outro {
  margin: 0;
  color: var(--muted);
}

/* ----- the labels ----- */

.import-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 19px;
  padding: 0 4px;
  border: 1px solid var(--water);
  border-radius: 2px;
  font-size: 12px;
  white-space: nowrap;
  color: var(--water);
}

.import-tag--ink {
  border-color: var(--ink);
  color: var(--ink);
}

.import-tag--stop {
  border-color: var(--danger);
  color: var(--danger);
}

.import-tag--quiet {
  border-color: var(--line);
  color: var(--muted);
}

.import-tag--dash {
  border-color: transparent;
  font-size: 13px;
  letter-spacing: 0;
  color: var(--faint-2);
}

/* ----- the table ----- */

/*
 * Separate borders rather than collapsed: a cell that sticks — the headings
 * at the top, and narrow the first two columns at the left — keeps its own
 * rule only that way.
 *
 * The columns every file has share out --base: their percentages are of
 * that, not of the table. A column the full format added later — Merknaam,
 * Aangedragen door, the 404 lines and the two sentences — has a width of its
 * own and widens the table by it, so the others keep their room and the own
 * note, which takes what is left, is not squeezed to nothing. Each is 0
 * until the view says the file has it.
 */
.import-table {
  --base: max(1100px, calc(100cqi - 48px));
  --with-markname: 0px;
  --with-credit: 0px;
  --with-notfound: 0px;
  --with-examplefor: 0px;
  --with-exampleagainst: 0px;
  width: calc(var(--base) + var(--with-markname) + var(--with-credit) + var(--with-notfound) + var(--with-examplefor) + var(--with-exampleagainst));
  margin: 0 24px 24px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  font-size: 13px;
  line-height: 1.4;
}

/*
 * The headings stay at the top of the scrolling middle. All of them stand in
 * a line 20px high with their text at its foot — the language pill included,
 * whose box is the line's: on the select's own baseline a browser sets "NL" a
 * couple of pixels under the other headings.
 */
.import-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 10px 8px 8px;
  border-bottom: 1px solid var(--line);
  background: var(--ground);
  font-size: 13px;
  font-weight: 400;
  line-height: 20px;
  text-align: left;
  vertical-align: bottom;
  white-space: nowrap;
  color: var(--muted);
}

/* The rows slide under the headings: a soft edge under them, drawn per cell
   but edge to edge, so it runs on unbroken where a shadow per cell would
   stop short of every column's sides. Only once rows are under them
   (.is-stuck, from import.js): standing there at rest, it said rows were
   hidden above the first and made the table look scrolled. */
.import-table thead th::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  height: 8px;
  margin-top: 1px;
  background: linear-gradient(var(--shade-under), transparent);
  opacity: 0;
  transition: opacity 0.15s ease;
  pointer-events: none;
}

.import.is-stuck .import-table thead th::after {
  opacity: 1;
}

.import-table td {
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  color: var(--ink);
}

.import-table th:first-child,
.import-table td:first-child {
  padding-left: 0;
}

.import-table__line {
  width: 38px;
}

.import-table__mark {
  width: 196px;
}

.import-table__owner {
  width: calc(var(--base) * 0.11);
}

.import-table__lang {
  width: 52px;
}

.import-table__brand {
  width: calc(var(--base) * 0.1);
}

.import-table__term {
  width: calc(var(--base) * 0.1);
}

.import-table__category {
  width: calc(var(--base) * 0.08);
}

.import-table__since {
  width: 84px;
}

.import-table__added {
  width: 96px;
}

.import-table__notes {
  width: calc(var(--base) * 0.15);
}

.import-table--markname {
  --with-markname: 150px;
}

.import-table--credit {
  --with-credit: 160px;
}

.import-table--notfound {
  --with-notfound: 240px;
}

.import-table--examplefor {
  --with-examplefor: 200px;
}

.import-table--exampleagainst {
  --with-exampleagainst: 200px;
}

.import-table__markname {
  width: var(--with-markname);
}

.import-table__credit {
  width: var(--with-credit);
}

.import-table__notfound {
  width: var(--with-notfound);
}

.import-table__examplefor {
  width: var(--with-examplefor);
}

.import-table__exampleagainst {
  width: var(--with-exampleagainst);
}

/* The row number and "hoort bij" stay at the left while the rest scrolls
   past: on their own surface, and the corner they make with the headings
   over both. */
.import-table .import-table__line,
.import-table .import-cell--mark,
.import-table thead .import-table__mark {
  position: sticky;
  z-index: 1;
  background: var(--ground);
}

.import-table .import-table__line {
  left: 0;
}

.import-table .import-cell--mark,
.import-table thead .import-table__mark {
  left: 38px;
}

.import-table thead .import-table__line,
.import-table thead .import-table__mark {
  z-index: 3;
}

.import-table .import-cell--mark.is-changed {
  background: var(--tint);
}

.import-table .import-cell--mark.is-error {
  background: var(--danger-tint);
}

.import-table thead .import-table__line {
  padding-right: 10px;
  text-align: right;
}

.import-table td.import-table__line {
  padding-top: 9px;
  padding-right: 10px;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  text-align: right;
  color: var(--muted);
}

/* A heading that sorts: a submit button without script, the plan swapped
   in with it (import.js). */
.import-sort {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  color: inherit;
  cursor: pointer;
}

.import-sort:hover,
.import-sort[aria-current="true"] {
  color: var(--ink);
}

.import-sort__label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.import-sort__arrow {
  letter-spacing: 0;
  color: var(--water);
}

.import-table th .import-info {
  margin-left: 4px;
}

/* ----- a row ----- */

.import-act {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  min-width: 0;
}

.import-pick {
  position: relative;
  display: block;
  align-self: stretch;
  min-width: 0;
}

.import-pick select {
  width: 100%;
  height: 30px;
  padding: 0 30px 0 10px;
  border: 1px solid var(--input-line);
  border-radius: var(--radius);
  background: var(--ground);
  font: inherit;
  font-size: 12.5px;
  color: var(--ink);
  text-overflow: ellipsis;
  appearance: none;
  cursor: pointer;
}

.import-pick svg {
  position: absolute;
  top: 50%;
  right: 10px;
  margin-top: -5px;
  pointer-events: none;
  color: var(--muted);
}

/* Chosen by the maintainer rather than proposed: in the accent, the way
   anything chosen on /admin is. */
.import-pick.is-chosen select {
  border-color: var(--water);
  color: var(--water);
}

.import-pick select:focus-visible,
.import-lang select:focus-visible {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 1px;
}

/* The language: the black pill of /admin/submissions, as a choice. */
.import-lang {
  position: relative;
  display: inline-flex;
  vertical-align: top;
}

.import-lang select {
  height: 20px;
  margin-top: 1px;
  padding: 0 17px 0 6px;
  border: 1px solid var(--ink);
  border-radius: 2px;
  background: var(--ink);
  font: inherit;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ground);
  appearance: none;
  cursor: pointer;
}

.import-lang svg {
  position: absolute;
  top: 8px;
  right: 5px;
  width: 7px;
  height: 7px;
  pointer-events: none;
  color: var(--ground);
}

.import-lang.is-chosen select {
  border-color: var(--water);
  background: var(--water);
  color: var(--on-water);
}

.import-lang.is-chosen svg {
  color: var(--on-water);
}

/* A language the site has no file for: an outline in red round "?". */
.import-cell--lang.is-error .import-lang select {
  border-color: var(--danger);
  background: var(--ground);
  color: var(--danger);
}

.import-cell--lang.is-error .import-lang svg {
  color: var(--danger);
}

/* The heading's pill, which sets every row: outlined, and standing in the
   headings' 20px line with its text in the middle of it. */
.import-lang--all select {
  display: block;
  height: 20px;
  margin: 0;
  background: transparent;
  font-size: 10.5px;
  line-height: 18px;
  color: var(--ink);
}

.import-lang--all svg {
  top: 7px;
  color: var(--ink);
}

/* ----- a cell ----- */

/* One line, cut off: the whole text, and what it was, is in the title. */
.import-cell__value {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* The explanation, when nothing about it changes, gets two lines. */
.import-cell__value--two {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  white-space: normal;
}

/* A word's 404 lines one under the other, each cut off at the column's
   edge: three at most, and every one of them in the title. */
.import-cell__lines {
  display: block;
}

.import-cell__lines > :nth-child(n + 4) {
  display: none;
}

.import-cell__was,
.import-cell__note {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  font-family: var(--body);
  font-size: 12px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
}

.import-cell__was {
  text-decoration: line-through;
  text-decoration-color: var(--faint-2);
}

.import-cell__why {
  display: block;
  margin-top: 3px;
  font-family: var(--body);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.35;
  white-space: normal;
  color: var(--danger);
}

.import-cell__why .import-info {
  color: var(--danger);
}

.import-cell--brand {
  font-family: var(--display);
  font-size: 15.5px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--water);
}

.import-cell--term {
  font-family: var(--display);
  font-size: 15px;
  line-height: 1.3;
}

/* A word as it is, compared with what the file says: grey where nothing
   changes, tinted where something does with what is there now struck out
   under it, a red tint where it is emptied. */
.import-table .import-cell.is-same {
  color: var(--muted);
}

.import-cell.is-changed {
  background: var(--tint);
}

.import-cell.is-cleared {
  background: var(--danger-tint);
}

.import-cell__value--cleared {
  color: var(--danger);
}

/* Wrong as it is: outlined in red, the reason under it on as many lines as
   it needs. */
.import-cell.is-error {
  background: var(--danger-tint);
  box-shadow: inset 0 0 0 1px var(--danger);
}

.import-cell.is-error .import-cell__value {
  white-space: normal;
}

/* A row without a term: not looked into yet, and quiet. */
.import-row.is-quiet td {
  color: var(--muted);
}

.import-row.is-quiet .import-cell--brand {
  font-weight: 400;
  color: var(--muted);
}

/* ----- the foot ----- */

.import-foot__say {
  flex: 1 1 320px;
  min-width: 0;
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
  text-wrap: pretty;
}

.import-foot__say.is-stop {
  color: var(--danger);
}

.btn--quiet {
  border-color: transparent;
  background: transparent;
}

.btn--quiet:hover {
  border-color: var(--rule);
}

/* Off while there is an error or nothing to do, and while an import or a
   new calculation is on its way. */
.import-foot .btn[disabled],
.btn[data-import-submit][disabled] {
  border-color: var(--rule);
  background: var(--wash);
  color: var(--faint-2);
  cursor: not-allowed;
  opacity: 1;
}

/* ----- the upload ----- */

.import-upload {
  gap: 20px;
}

.import-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

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

/*
 * The drop zone, in its four states, every one of them in the markup and
 * one shown here: empty, with a file, refused, and with a file held over it.
 * Without script it is the file field itself, which the browser draws.
 *
 * The states lie in one grid cell, and the one held over the zone only ever
 * takes the visibility of the others, never their room: a box that shrank
 * as a file came over it left the pointer outside, which put it back, which
 * brought the pointer inside again — it flickered along its lower edge.
 */
.import-drop {
  position: relative;
  display: grid;
  align-items: center;
  padding: 22px 16px;
  border: 1.5px dashed var(--rule);
  border-radius: 4px;
  background: var(--wash);
}

.import-drop__empty,
.import-drop__over,
.import-drop__chosen {
  grid-area: 1 / 1;
}

.import-drop__empty,
.import-drop__over {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}

.import-drop__chosen {
  display: none;
  align-items: center;
  gap: 12px;
  min-width: 0;
  text-align: left;
}

.import-drop__icon {
  flex: none;
  color: var(--muted);
}

.import-drop__say {
  font-size: 14px;
  color: var(--ink);
}

.import-drop__or {
  font-size: 12.5px;
  color: var(--muted);
}

.import-drop__name {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.import-drop__name b {
  overflow: hidden;
  font-size: 14px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
}

.import-drop__name > span {
  font-size: 12px;
  color: var(--muted);
}

.import-drop--file {
  padding: 12px 14px;
}

.import-drop--file .import-drop__chosen {
  display: flex;
}

:root.js .import-drop--file .import-drop__empty {
  display: none;
}

/* Lower than the file's own line when the zone holds one, so it fits in
   the room that line takes: in one row. */
.import-drop--file .import-drop__over {
  flex-direction: row;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px 10px;
}

.import-drop__over {
  visibility: hidden;
}

.import-drop.is-over {
  border-style: solid;
  border-color: var(--water);
  background: var(--tint);
}

.import-drop.is-over .import-drop__over {
  visibility: visible;
}

.import-drop.is-over .import-drop__empty,
.import-drop.is-over .import-drop__chosen {
  visibility: hidden;
}

.import-drop.is-over .import-drop__icon,
.import-drop.is-over .import-drop__say {
  color: var(--water);
}

.import-drop--bad {
  border-style: solid;
  border-color: var(--danger);
  background: var(--danger-tint);
}

/* With script the zone is the field: the input itself goes out of sight and
   its two labels open it, while the keyboard still reaches it. */
:root.js .import-drop input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

:root.js .import-drop:has(input:focus-visible) {
  outline: var(--focus-ring) solid var(--water);
  outline-offset: 2px;
}

.import-upload__bad {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--danger);
}

.import-start {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--wash);
}

.import-start__say {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.import-start__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.import-columns__summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink);
  list-style: none;
  cursor: pointer;
}

.import-columns__summary::-webkit-details-marker {
  display: none;
}

.import-columns__summary svg {
  color: var(--muted);
  transition: rotate 0.15s ease;
}

.import-columns[open] .import-columns__summary svg {
  rotate: 90deg;
}

.import-columns__hint {
  margin: 10px 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
}

.import-columns__list {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  margin: 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.import-columns__list dt,
.import-columns__list dd {
  margin: 0;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
}

.import-columns__list dt {
  font-weight: 500;
  color: var(--ink);
}

.import-columns__list dd {
  color: var(--muted);
}

.import-columns__list .is-missing {
  color: var(--danger);
}

.import-columns__required {
  margin-left: 6px;
  font-size: 13px;
  font-weight: 400;
  color: var(--water);
}

/* ----- what it did ----- */

.import-done {
  padding-top: 6px;
}

.import-done__list {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  margin: 0;
}

.import-done__list dt,
.import-done__list dd {
  margin: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.import-done__list dt {
  padding-top: 13px;
  font-size: 13px;
  color: var(--muted);
}

.import-done__list dd {
  font-size: 14px;
  color: var(--ink);
}

/*
 * Narrow (design canvas 5A): the dialog comes up from the bottom edge like
 * every dialog on /admin, and the table scrolls sideways with the row number
 * and "hoort bij" held at its left. The headings have to stay at the top as
 * well, and two sticky directions only work inside one box that scrolls both
 * ways — so the middle does, and what stands above the table is pinned to its
 * left edge at the width of the screen instead of scrolling away with it.
 */
@media (max-width: 743px) {
  /* Edge to edge like every /admin sheet: the wide width above outweighs
     the narrow dialog's own 100%. */
  .dialog:has(.import) {
    width: 100%;
    height: 94vh;
  }

  .import.dialog__body {
    touch-action: pan-x pan-y;
  }

  .import__summary {
    grid-template-columns: minmax(0, 1fr);
    padding: 14px 16px 16px;
  }

  .import__swipe {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 8px 16px;
    border-bottom: 1px solid var(--line);
    font-size: 12px;
    color: var(--muted);
  }

  .import__refused {
    padding: 12px 16px 0;
  }

  /* The tabs scroll on their own when they do not fit, as /admin's own strip
     does. */
  .import-tabs {
    padding: 10px 16px 0;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .import-tabs__tab {
    height: 38px;
    padding: 0 12px;
    font-size: 13.5px;
  }

  .import-table {
    --base: 1040px;
    margin: 0 16px 16px 0;
  }

  .import-table__line {
    width: 46px;
  }

  .import-table__mark {
    width: 150px;
  }

  .import-table__owner {
    width: 150px;
  }

  .import-table__lang {
    width: 60px;
  }

  .import-table__brand,
  .import-table__term {
    width: 120px;
  }

  .import-table__category {
    width: 110px;
  }

  .import-table__since {
    width: 64px;
  }

  .import-table__notes {
    width: 200px;
  }

  .import-table .import-table__line {
    padding-left: 16px;
  }

  .import-table .import-cell--mark,
  .import-table thead .import-table__mark {
    left: 46px;
  }

  /* 5A draws the edge the rest slides under — once something has slid
     under it (.is-slid, from import.js), as the headings' shade does. */
  .import.is-slid .import-table .import-cell--mark,
  .import.is-slid .import-table thead .import-table__mark {
    box-shadow: var(--shadow-edge);
  }

  .import.is-slid .import-table .import-cell--mark.is-error {
    box-shadow: inset 0 0 0 1px var(--danger), var(--shadow-edge);
  }

  .import-pick select {
    height: 36px;
  }

  .import-lang select {
    height: 28px;
  }

  /* 5A: importing over the whole width, going back and cancelling under it. */
  .import-foot {
    flex-direction: column;
    align-items: stretch;
  }

  .import-foot__say {
    flex: none;
  }

  .import-foot__actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .import-foot__actions .btn {
    height: 44px;
  }

  .import-foot__apply {
    grid-column: 1 / -1;
    order: -1;
  }

  .import-columns__list {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .import-done__list {
    grid-template-columns: 110px minmax(0, 1fr);
  }
}

/* ---------- the contrast mode (forced colours) ---------- */

/*
 * Windows' contrast themes, and Firefox's "Override colors" (forced-colors:
 * active), an accessibility setting the visitor turns on themselves: the
 * browser throws the site's colours away, paints in a handful the visitor
 * chose (Canvas, CanvasText, LinkText, Highlight, HighlightText…) and drops
 * every shadow. Nothing is designed here; this section keeps what would
 * vanish, of three kinds:
 *
 * - A line that is there or not. The browser draws a transparent border in the
 *   text's colour, so every sort, tab and navigation link looked current. Out
 *   of its state such a line takes Canvas, the ground.
 * - A state that is only a background: the vote's split, a switch's chosen
 *   option, a list's lit row, the phone's open row. These take Highlight, with
 *   HighlightText on them, and opt out of the forcing (forced-color-adjust:
 *   none) so the system colours named here stay. It is inherited, so what
 *   stands on them is named too (the `*`).
 * - A focus shown by a field's edge or ground. Forced, both states are one
 *   colour, so a field that has the focus takes a ring in Highlight.
 *
 * Chrome's emulation (DevTools, Rendering: forced-colors) shows it in its own
 * palettes, which are not Windows' own.
 */
@media (forced-colors: active) {
  /* De lijst's hint is a box only by its background: an edge keeps it one. */
  .tile__hint {
    border: 1px solid CanvasText;
  }

  /* The foot's white circles — the way to the top, the theme and its
     bubbles — are round only by their ground: an edge keeps them round. */
  .site-foot__up,
  .bubbles__face,
  .bubbles__bub {
    border: 1px solid ButtonText;
  }

  /* A drawing is a mask over a background, which the forcing would take
     away: painted in the text's own system colour instead. */
  .drawing[style] {
    forced-color-adjust: none;
    background: CanvasText;
  }

  .site-nav a:not([aria-current="page"], :hover),
  .row__sort:not([aria-current="true"]),
  .seg__option:not([aria-current="true"]),
  .form-tab__head:not(:has(.form-tab__radio:checked)),
  .import-tabs__tab:not(:has(input:checked)),
  .category-field__option:not(.is-chosen),
  .combo__option:not(:has(.combo__radio:checked)),
  .back-link:not(:hover),
  .lines-fold__add:not(:hover) {
    border-color: Canvas;
  }

  /* The open tab stands on its panel with no line between, as it does in
     colour. */
  .form-tab__head:has(.form-tab__radio:checked) {
    border-bottom-color: Canvas;
  }

  /* The split, once it is shown: the part that says "verwaterd", with its
     share standing on it at the right end. */
  .vote__bar--split {
    forced-color-adjust: none;
    background: linear-gradient(to right, Canvas var(--split), Highlight var(--split));
    color: CanvasText;
  }

  .vote__share--generic {
    color: HighlightText;
  }

  /* Under the threshold, the half that was answered. */
  .vote__half.is-mine {
    forced-color-adjust: none;
    background: Highlight;
    color: HighlightText;
  }

  /* A switch's chosen option, wherever it is drawn: on the chip once it is
     placed (always in the menu's foot, while open in a header), or on itself
     before that and without script — the selectors the chip's rules use. */
  .switch__chip {
    forced-color-adjust: none;
    background: Highlight;
  }

  .switch--full.has-chip .switch__option:is(
    :root[data-theme-mode="light"] [data-theme-set="light"],
    :root[data-theme-mode="dark"] [data-theme-set="dark"],
    :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
  ),
  :root.js .switch--compact.has-chip:is(.is-open, :has(:focus-visible)) .switch__option:is(
    :root[data-theme-mode="light"] [data-theme-set="light"],
    :root[data-theme-mode="dark"] [data-theme-set="dark"],
    :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
  ) {
    forced-color-adjust: none;
    color: HighlightText;
  }

  .switch--full:not(.has-chip) .switch__option:is(
    :root[data-theme-mode="light"] [data-theme-set="light"],
    :root[data-theme-mode="dark"] [data-theme-set="dark"],
    :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
  ),
  :root.js .switch--compact:not(.has-chip):is(.is-open, :has(:focus-visible)) .switch__option:is(
    :root[data-theme-mode="light"] [data-theme-set="light"],
    :root[data-theme-mode="dark"] [data-theme-set="dark"],
    :root:not([data-theme-mode="light"]):not([data-theme-mode="dark"]) [data-theme-set="system"]
  ) {
    forced-color-adjust: none;
    background: Highlight;
    color: HighlightText;
  }

  /* The row the arrow keys or the pointer light in the category list and in
     the review's list of marks; a chosen one keeps its edge on it. */
  .category-field__option.is-active,
  .combo__option:is(.is-active, :hover) {
    forced-color-adjust: none;
    background: Highlight;
    border-left-color: Highlight;
    color: HighlightText;
  }

  .category-field__option.is-active *,
  .combo__option:is(.is-active, :hover) * {
    forced-color-adjust: none;
    color: HighlightText;
  }

  .category-field__option.is-active.is-chosen,
  .combo__option:is(.is-active, :hover):has(.combo__radio:checked) {
    border-left-color: HighlightText;
  }

  /* /admin's tab strip says which page this is by a filled tab. */
  .admin-tabs__tab[aria-current="page"],
  .admin-tabs__tab[aria-current="page"] .admin-tabs__badge {
    forced-color-adjust: none;
    color: HighlightText;
  }

  .admin-tabs__tab[aria-current="page"] {
    background: Highlight;
  }

  /* A field with the focus. The second selector weighs what /submit's own
     focus rule weighs, which takes the outline away. */
  :is(input, textarea, select):focus-visible,
  .submit .form-field input:focus-visible {
    outline: var(--focus-ring) solid Highlight;
    outline-offset: 1px;
  }

  /* The chosen brand's dot is a background, which a forced palette paints
     away. */
  .quiz__input:checked + .quiz__option .quiz__radio::after {
    forced-color-adjust: none;
    background: CanvasText;
  }
}


/* ---------- the 16px floor ---------- */

/*
 * Safari on iPhone zooms the page in when the text control it is about to
 * focus is set smaller than 16px. That is not only a change of scale: a zoomed
 * page has a visual viewport smaller than its layout, and that viewport pans —
 * over the whole document, the page behind an open dialog included. No scroll
 * lock reaches it, because panning a zoomed page is not scrolling, and both
 * locks are about scrolling. Tapping "term" in the nieuw-merk sheet left the
 * register loose behind it, and the search field did the same to the register
 * itself.
 *
 * The floor goes on the controls and not in the viewport meta. Writing
 * `maximum-scale=1` there buys the same quiet by taking pinch-zoom away from
 * everybody, which is not a trade to make on somebody else's behalf.
 *
 * 743px is the shared breakpoint again — wider than the phones this is about,
 * which costs a narrowed desktop window slightly larger fields and nothing
 * else. The size each field is given where it is defined stays the wide
 * screen's, so this has to outrank all of them, which is why the section sits
 * last and why `.submit .form-field input` and a page's source field
 * (`.page-body`) are named again: each carries two classes, and a shorter
 * selector would lose to it however late it came.
 *
 * Every control has to be named, and the list is longer than it looks, because
 * the drawer's first step does not use .form-field at all: its fields are
 * .draft__field.
 */
@media (max-width: 743px) {
  .field input,
  .form-field input,
  .form-field select,
  .form-field textarea,
  .form-field textarea.page-body,
  .submit .form-field input,
  .combo__search input,
  .draft__field input,
  .draft__field textarea,
  .import-pick select,
  .import-lang select,
  .form-field.word-stamp__field input {
    font-size: 16px;
  }
}
