/* ==========================================================================
   Design system — base.css (brand v5, 24 Nov 2026)
   Red, ink, cream. One loud thing at a time. Archivo for everything you read
   and for headings (heavy and wide only for six words or fewer); Newsreader
   italic only for a Redditor's own words. Light and dark. Area files
   (creator.css, brand.css, admin.css, public.css, beta-form.css) build on
   these tokens and classes; the token names are the ones they already use.
   The earlier look is kept in app/history/base.css-before-brand-v5.
   ========================================================================== */

@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url('/fonts/archivo-latin-wght-wdth.woff2') format('woff2-variations'), url('/fonts/archivo-latin-wght-wdth.woff2') format('woff2');
}
@font-face {
  font-family: 'Newsreader';
  font-style: italic;
  font-display: swap;
  font-weight: 200 800;
  src: url('/fonts/newsreader-latin-opsz-italic.woff2') format('woff2-variations');
}

/* ---------------------------------------------------------------- tokens */
:root {
  color-scheme: light;
  --font-display: 'Archivo', 'Arial Black', 'Helvetica Neue', Arial, sans-serif;
  --font-sans: 'Archivo', 'Helvetica Neue', Helvetica, Arial, system-ui, sans-serif;
  /* The serif italic has one job: a Redditor's own words, in quote marks. */
  --font-quote: 'Newsreader', 'Iowan Old Style', Georgia, 'Times New Roman', serif;
  --font-mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  /* fixed brand colours (the same in light and dark) */
  --red: #f0282d;
  --cream: #fff3e2;
  --night: #0f0e11;
  --ghost-red: #e3232a;

  /* roles: light */
  --paper: #fff3e2; /* the page (cream) */
  --paper-2: #f1e3ce; /* sunk: switched-off parts, quiet panels */
  --card: #fffbf5; /* cards and fields (paper) */
  --ink: #0f0e11;
  --ink-2: #46424b;
  --ink-3: #5f5965;
  --rule: #e6d8c4;
  --rule-strong: #0f0e11;
  --field: #746b62; /* borders of inputs, choices, chips */
  --accent: #f0282d; /* red fields, one button, the thread */
  --accent-strong: #b3121b; /* small red words: links, labels, the * mark */
  --accent-ink: #0f0e11; /* text on red is ink */
  --accent-soft: #ffd9db; /* blush: "Here", a chosen option, marked words */
  --mark: #ffd9db; /* the yellow highlighter is retired; old uses get blush */
  --mark-ink: #0f0e11;
  --ok: #0b6b4a;
  --ok-soft: #d9f0e3;
  --warn: #7a4e00;
  --warn-soft: #fbe6b4;
  --bad: #8e1450; /* berry: errors. The brand red never means "wrong" */
  --bad-soft: #fbe3ee;
  --neutral-soft: #f1e3ce;
  --focus: #0f0e11;
  /* ink blocks: stats, footer, "not on offer" */
  --block: #0f0e11;
  --block-text: #fff3e2;
  --block-2: #cfc6bd;
  --block-line: #3a363e;
  --block-accent: #ff7b74;

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 18px;
  --radius-xl: 28px;
  /* No shadows except under the open menu. --ring is kept for area files that draw focus with box-shadow. */
  --shadow: 0 26px 44px -22px rgb(15 14 17 / 0.55);
  --shadow-sm: none;
  --ring: 0 0 0 2px var(--paper), 0 0 0 5px var(--focus);
  --max: 1200px;
  --gutter: clamp(16px, 3.4vw, 44px);

  /* the thread as a picture: weight 4, one wave 32 long, 10 high at the middle of the line */
  --wave-red: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='16' viewBox='0 0 32 16'%3E%3Cpath d='M-16 8q8 10 16 0t16 0t16 0t16 0' fill='none' stroke='%23F0282D' stroke-width='4'/%3E%3C/svg%3E");
  --wave-ink: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='16' viewBox='0 0 32 16'%3E%3Cpath d='M-16 8q8 10 16 0t16 0t16 0t16 0' fill='none' stroke='%230F0E11' stroke-width='4'/%3E%3C/svg%3E");
  --wave-cream: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='16' viewBox='0 0 32 16'%3E%3Cpath d='M-16 8q8 10 16 0t16 0t16 0t16 0' fill='none' stroke='%23FFF3E2' stroke-width='4'/%3E%3C/svg%3E");
  --wavev-red: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='32' viewBox='0 0 16 32'%3E%3Cpath d='M8-16q10 8 0 16t0 16t0 16t0 16' fill='none' stroke='%23F0282D' stroke-width='4'/%3E%3C/svg%3E");
  /* the bubble (round mark) in red, for step numbers and the alias letter */
  --bubble-red: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 112 100'%3E%3Cpath d='M56 2C83.6 2 106 19 106 40C106 61 83.6 78 56 78C50 78 44.3 77.3 39 75.7L18 91L20 66.4C11.5 60 6 50.5 6 40C6 19 28.4 2 56 2Z' fill='%23F0282D' stroke='%23F0282D' stroke-width='3' stroke-linejoin='round'/%3E%3C/svg%3E");
  /* the select arrow and the tick, drawn in the text colour of each theme */
  --select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 7.5l5 5 5-5' fill='none' stroke='%230F0E11' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.6 3.6L15.5 6.5' fill='none' stroke='%23FFF3E2' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    color-scheme: dark;
    --paper: #0f0e11;
    --paper-2: #29262d;
    --card: #1d1b20;
    --ink: #fff3e2;
    --ink-2: #d2c9c0;
    --ink-3: #a79e97;
    --rule: #37333b;
    --rule-strong: #fff3e2;
    --field: #948b93;
    --accent: #f0282d;
    --accent-strong: #ff7b74;
    --accent-ink: #0f0e11;
    --accent-soft: #3a1518;
    --mark: #3a1518;
    --mark-ink: #fff3e2;
    --ok: #5fd3a0;
    --ok-soft: #12301f;
    --warn: #f2b84b;
    --warn-soft: #33270c;
    --bad: #ff9cc2;
    --bad-soft: #3a1529;
    --neutral-soft: #29262d;
    --focus: #fff3e2;
    --block: #1d1b20;
    --block-text: #fff3e2;
    --block-2: #d2c9c0;
    --block-line: #37333b;
    --shadow: 0 26px 44px -22px rgb(0 0 0 / 0.85);
    --select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 7.5l5 5 5-5' fill='none' stroke='%23FFF3E2' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    --tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.6 3.6L15.5 6.5' fill='none' stroke='%230F0E11' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  }
}
:root[data-theme='dark'] {
  color-scheme: dark;
  --paper: #0f0e11;
  --paper-2: #29262d;
  --card: #1d1b20;
  --ink: #fff3e2;
  --ink-2: #d2c9c0;
  --ink-3: #a79e97;
  --rule: #37333b;
  --rule-strong: #fff3e2;
  --field: #948b93;
  --accent: #f0282d;
  --accent-strong: #ff7b74;
  --accent-ink: #0f0e11;
  --accent-soft: #3a1518;
  --mark: #3a1518;
  --mark-ink: #fff3e2;
  --ok: #5fd3a0;
  --ok-soft: #12301f;
  --warn: #f2b84b;
  --warn-soft: #33270c;
  --bad: #ff9cc2;
  --bad-soft: #3a1529;
  --neutral-soft: #29262d;
  --focus: #fff3e2;
  --block: #1d1b20;
  --block-text: #fff3e2;
  --block-2: #d2c9c0;
  --block-line: #37333b;
  --shadow: 0 26px 44px -22px rgb(0 0 0 / 0.85);
  --select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 7.5l5 5 5-5' fill='none' stroke='%23FFF3E2' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.6 3.6L15.5 6.5' fill='none' stroke='%230F0E11' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* A red field (home hero, the last call to action): the same in light and dark. Reading text, lines and
   the focus ring are ink; only big headlines are cream (3.79:1 is large-type only). */
.on-red {
  background: var(--red);
  color: #0f0e11;
  --ink: #0f0e11;
  --ink-2: #0f0e11;
  --ink-3: #0f0e11;
  --accent-strong: #0f0e11;
  --rule: rgb(15 14 17 / 0.3);
  --rule-strong: #0f0e11;
  --field: #0f0e11;
  --focus: #0f0e11;
  --paper: #fff3e2;
  --card: #fffbf5;
  --accent-soft: #ffd9db;
}
/* An ink block: stats, footer, "not on offer". In dark mode it is the night card. */
.on-ink {
  background: var(--block);
  color: var(--block-text);
  --ink: var(--block-text);
  --ink-2: var(--block-2);
  --ink-3: var(--block-2);
  --rule: var(--block-line);
  --rule-strong: var(--block-text);
  --accent-strong: var(--block-accent);
  --paper: var(--block);
  --focus: #fff3e2;
  --accent-soft: #3a1518;
}
/* A card that keeps the light roles wherever it sits (on red). */
.on-paper {
  --paper: #fff3e2;
  --card: #fffbf5;
  --paper-2: #f1e3ce;
  --ink: #0f0e11;
  --ink-2: #46424b;
  --ink-3: #5f5965;
  --rule: #e6d8c4;
  --rule-strong: #0f0e11;
  --field: #746b62;
  --accent-strong: #b3121b;
  --accent-soft: #ffd9db;
  --ok: #0b6b4a;
  --ok-soft: #d9f0e3;
  --focus: #0f0e11;
  color: #0f0e11;
}

/* ---------------------------------------------------------------- reset */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img,
svg {
  display: block;
  max-width: 100%;
}
svg.icon {
  display: inline-block;
  width: 1.1em;
  height: 1.1em;
  vertical-align: -0.18em;
  flex: none;
}
a {
  color: var(--accent-strong);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
a:hover {
  color: var(--accent-strong);
  text-decoration-thickness: 3px;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
::selection {
  background: var(--accent-soft);
  color: var(--ink);
}
hr {
  border: 0;
  border-top: 1.5px solid var(--rule);
  margin: 2rem 0;
}
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: 12px 16px;
  border-radius: var(--radius);
  font-weight: 700;
}
.skip-link:focus {
  top: 12px;
  color: var(--paper);
}
.js-only {
  display: none !important;
}
.has-js .js-only {
  display: inline-flex !important;
}

/* ---------------------------------------------------------------- type */
/* Headings: Archivo, heavy and a little wide, sentence case. */
h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 112%;
  line-height: 1.09;
  letter-spacing: -0.025em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 {
  font-size: clamp(30px, 4.2vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.028em;
}
h2 {
  font-size: clamp(25px, 3.2vw, 40px);
}
h3 {
  font-size: clamp(19px, 1.9vw, 23px);
  font-stretch: 108%;
  line-height: 1.16;
  letter-spacing: -0.015em;
}
h4 {
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  font-weight: 700;
  font-stretch: 100%;
  line-height: 1.35;
  letter-spacing: 0;
}
p {
  margin: 0 0 1em;
  text-wrap: pretty;
}
.lede {
  font-size: clamp(17px, 1.5vw, 19.5px);
  font-weight: 500;
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 60ch;
}
.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent-strong);
  margin-bottom: 14px;
}
.muted {
  color: var(--ink-3);
}
.small {
  font-size: 0.875rem;
  line-height: 1.5;
}
/* Nothing is set under 14 px except labels. */
.tiny {
  font-size: 0.875rem;
  line-height: 1.45;
}
.mono,
code,
kbd {
  font-family: var(--font-mono);
  font-size: 0.92em;
}
code {
  background: var(--paper-2);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}
/* Marked words: a blush mark behind two or three words. Not a thread, not italic. */
.mark {
  background: var(--accent-soft);
  color: inherit;
  font-style: normal;
  border-radius: var(--radius-sm);
  padding: 0.04em 0.28em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
/* A Redditor's own words only. */
.serif,
.quote {
  font-family: var(--font-quote);
  font-style: italic;
  font-weight: 400;
}
.nowrap {
  white-space: nowrap;
}
.prose {
  max-width: 70ch;
}
.prose h2 {
  margin-top: 2.2rem;
  font-size: clamp(22px, 2.4vw, 28px);
}
.prose h3 {
  margin-top: 1.6rem;
}
.prose ul,
.prose ol {
  padding-left: 1.3rem;
}
.prose li {
  margin: 0.35rem 0;
}
.prose table {
  border-collapse: collapse;
  width: 100%;
  margin: 1rem 0;
  font-size: 1rem;
}
.prose th,
.prose td {
  border-bottom: 1px solid var(--rule);
  padding: 0.5rem;
  text-align: left;
  vertical-align: top;
}
.prose thead th {
  border-bottom: 2px solid var(--rule-strong);
}

/* ---------------------------------------------------------------- the thread and the bubble */
/* A divider between sections: 4 px thick, as wide as the column. */
.thread {
  display: block;
  height: 16px;
  border: 0;
  margin: 0;
  background: var(--wave-red) repeat-x left center / 32px 16px;
}
.thread.ink {
  background-image: var(--wave-ink);
}
.thread.cream {
  background-image: var(--wave-cream);
}
/* One headline word on the thread: an inline drawing as wide as the word (OnThread in src/views/public-content.tsx). */
.on {
  position: relative;
  display: inline-block;
  white-space: nowrap;
}
/* Languages written without spaces cannot break a long phrase at a word: let the span wrap there. */
:lang(ja) .on,
:lang(zh) .on {
  white-space: normal;
}
.on > svg {
  position: absolute;
  left: 0;
  top: calc(100% - 0.1em);
  width: 100%;
  height: auto;
  max-width: none;
  overflow: visible;
  color: var(--thread-c, var(--red));
  pointer-events: none;
}
.has-on {
  padding-bottom: 0.28em;
}
/* The thread draws itself once, left to right, under the hero headline word only. Reduced motion: nothing draws. */
@media (prefers-reduced-motion: no-preference) {
  .hero .on > svg path,
  .page-hero .on > svg path {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: wott-draw 0.9s 0.35s cubic-bezier(0.6, 0, 0.2, 1) forwards;
  }
}
@keyframes wott-draw {
  to {
    stroke-dashoffset: 0;
  }
}
@media (forced-colors: active) {
  .thread {
    background: none;
    border-top: 3px solid CanvasText;
    height: 0;
  }
}

/* ---------------------------------------------------------------- layout */
.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.container.narrow {
  max-width: 760px;
}
.container.mid {
  max-width: 960px;
}
main {
  flex: 1;
}
/* Full-width pages keep a slot for a flash message; with none, it takes no room (the home page's red
   first screen starts right under the header). */
.flash-slot {
  padding-top: 1rem;
}
.flash-slot:empty {
  display: none;
}
.page {
  padding-top: clamp(28px, 4vw, 56px);
  padding-bottom: 80px;
}
.stack > * + * {
  margin-top: var(--stack, 1rem);
}
.stack-lg > * + * {
  margin-top: 2rem;
}
.row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
.row.between {
  justify-content: space-between;
}
.row.end {
  justify-content: flex-end;
}
.grid {
  display: grid;
  gap: 1.25rem;
}
.grid-2 {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
}
.grid-3 {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}
.grid-4 {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
}
.split {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 960px) {
  .split {
    grid-template-columns: minmax(0, 1fr) 340px;
    align-items: start;
  }
  .split.left {
    grid-template-columns: 280px minmax(0, 1fr);
  }
}
.sticky {
  position: sticky;
  top: 92px;
}

/* ---------------------------------------------------------------- logo */
/* The letters are the logo (v4, unchanged): heavy, wide capitals in one flat colour. */
.lg {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 900;
  font-stretch: 125%;
  text-transform: uppercase;
  letter-spacing: -0.035em;
  line-height: 0.8;
  white-space: nowrap;
  text-align: left;
  text-decoration: none;
}
.lg .r {
  display: block;
}
.lg .r1 {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.lg .sm {
  display: block;
}
.lg .smi {
  display: inline-block;
  font-size: 0.44em;
  line-height: 0.876;
  vertical-align: baseline;
}
.lg.one .sm {
  display: inline-block;
  margin: 0 0.2em 0 0.24em;
}
/* The two-line logo carries the .stack class: keep its rows touching, as on the board. */
.lg.stack > .r + .r {
  margin-top: 0;
}
.logo {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--ink);
  text-decoration: none;
}
.logo:hover {
  color: var(--ink);
  text-decoration: none;
}
.logo .lg.one {
  font-size: 23px;
}
.logo .lg.wott {
  display: none;
  font-size: 27px;
}
/* Kept for any page that still shows the old square mark: now the W tile. */
.logo-mark {
  width: 30px;
  height: 30px;
  border-radius: 7px;
  background: var(--red);
  color: #0f0e11;
  display: grid;
  place-items: center;
}
.logo-mark svg {
  width: 20px;
  height: 20px;
}

/* ---------------------------------------------------------------- header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--paper);
  border-bottom: 2px solid var(--rule-strong);
}
.site-header .bar {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 76px;
}
.site-header:not(.app-header) .logo {
  margin-right: auto;
}
.site-nav {
  display: flex;
  gap: 16px;
}
.site-nav a,
.menu-panel a.navlink {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  border-top: 3px solid transparent;
  border-bottom: 3px solid transparent;
}
/* Menu items get a straight line, never the thread: ink on hover, red for this page. */
.site-nav a:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
}
.site-nav a[aria-current='page'] {
  border-bottom-color: var(--red);
  font-weight: 800;
}
.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.app-header .header-actions {
  margin-left: auto;
}
.menu {
  display: none;
}
.menu > summary {
  list-style: none;
  cursor: pointer;
}
.menu > summary::-webkit-details-marker {
  display: none;
}
.menu[open] > summary {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
/* The open menu: the one shadow in the system. */
.menu-panel {
  position: absolute;
  left: 12px;
  right: 12px;
  top: calc(100% + 8px);
  max-width: 420px;
  margin-left: auto;
  background: var(--card);
  border: 2px solid var(--rule-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 10px;
  display: grid;
  gap: 2px;
  z-index: 5;
}
.menu-panel a.navlink {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  padding: 0 14px;
  border-radius: var(--radius);
  font-size: 1.0625rem;
}
.menu-panel a.navlink::after {
  content: '';
  width: 9px;
  height: 9px;
  border: solid var(--ink-3);
  border-width: 2.2px 2.2px 0 0;
  transform: rotate(45deg);
  margin-right: 4px;
}
.menu-panel a.navlink:hover {
  background: var(--paper-2);
}
.menu-panel a.navlink[aria-current='page'] {
  background: var(--accent-soft);
  font-weight: 800;
}
.menu-panel .menu-logout button {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 52px;
  padding: 0 14px;
  border: 0;
  border-radius: var(--radius);
  background: none;
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
}
.menu-panel .menu-logout button:hover {
  background: var(--paper-2);
}
.menu-panel .thread {
  margin: 8px 14px;
}
.menu-panel .btn {
  margin-top: 6px;
}
@media (max-width: 1340px) {
  .app-header .header-actions .hide-sm {
    display: none;
  }
  .app-header .menu {
    display: block;
  }
  .app-header.site-header .bar {
    min-height: 66px;
    gap: 12px;
  }
}
/* The public header gives way in four stages, per language, so the two apply buttons stay in the header on every
   laptop width (1 Dec 2026, header stages; before this the whole row went into the menu button below 1410 px in
   English, 1480 in Japanese and 1550 in German). Row widths measured on the build copy's dev server (Archivo
   loaded, portals open so "Log in" shows, language button shown):
     stage                                              EN     KO     JA     DE
     A  full row                          row width    1271   1206   1342   1409
                                          from         1410   1341   1480   1550 px
     B  globe-only language button,       row width    1177   1111   1249   1315
        tighter spacing                   from         1316   1247   1388   1454 px
     C  menus and links in the menu       row width     813    778    892    899
        button; Log in and both apply     from          927    890   1012   1020 px
        buttons stay in the header
     D  phone header: the buttons move into the menu button too (below C, as before)
   Each "from" leaves about 25 px to spare after a 17 px scrollbar, the gutters (44 px, or 3.4% of the screen below
   1294 px) and 9 px of margin over the measured width (stage A keeps the first review's thresholds, from widths of
   1280, 1211, 1348 and 1417). In A and B the header's column grows just enough to hold the row (the max-widths
   below), so the row never runs past the screen or its own column. So at 1280 and 1366 px every language shows
   both apply buttons, and at 1440 px English shows the full row. The signed-in header (.app-header) keeps its one
   fold at 1340 px. */
@media (min-width: 1410px) {
  html[lang='en'] .site-header:not(.app-header) .bar {
    max-width: 1400px;
  }
}
@media (min-width: 1341px) {
  html[lang='ko'] .site-header:not(.app-header) .bar {
    max-width: 1320px;
  }
}
@media (min-width: 1480px) {
  html[lang='ja'] .site-header:not(.app-header) .bar {
    max-width: 1460px;
  }
}
@media (min-width: 1550px) {
  html[lang='de'] .site-header:not(.app-header) .bar {
    max-width: 1530px;
  }
}
@media (min-width: 1316px) and (max-width: 1409px) {
  html[lang='en'] .site-header:not(.app-header) .bar {
    max-width: 1300px;
    gap: 12px;
  }
  html[lang='en'] .site-header:not(.app-header) .site-nav {
    gap: 12px;
  }
  html[lang='en'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 14px;
  }
  html[lang='en'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 10px;
  }
}
@media (min-width: 1247px) and (max-width: 1340px) {
  html[lang='ko'] .site-header:not(.app-header) .bar {
    max-width: 1235px;
    gap: 12px;
  }
  html[lang='ko'] .site-header:not(.app-header) .site-nav {
    gap: 12px;
  }
  html[lang='ko'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 14px;
  }
  html[lang='ko'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 10px;
  }
}
@media (min-width: 1388px) and (max-width: 1479px) {
  html[lang='ja'] .site-header:not(.app-header) .bar {
    max-width: 1372px;
    gap: 12px;
  }
  html[lang='ja'] .site-header:not(.app-header) .site-nav {
    gap: 12px;
  }
  html[lang='ja'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 14px;
  }
  html[lang='ja'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 10px;
  }
}
@media (min-width: 1454px) and (max-width: 1549px) {
  html[lang='de'] .site-header:not(.app-header) .bar {
    max-width: 1438px;
    gap: 12px;
  }
  html[lang='de'] .site-header:not(.app-header) .site-nav {
    gap: 12px;
  }
  html[lang='de'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 14px;
  }
  html[lang='de'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 10px;
  }
}
@media (min-width: 927px) and (max-width: 1409px) {
  html[lang='en'] .site-header:not(.app-header) .header-actions {
    gap: 6px;
  }
  html[lang='en'] .site-header:not(.app-header) .lang-menu > summary {
    width: 44px;
    padding: 0;
    gap: 0;
  }
  html[lang='en'] .site-header:not(.app-header) .lang-menu .lang-code,
  html[lang='en'] .site-header:not(.app-header) .lang-menu > summary::after {
    display: none;
  }
}
@media (min-width: 890px) and (max-width: 1340px) {
  html[lang='ko'] .site-header:not(.app-header) .header-actions {
    gap: 6px;
  }
  html[lang='ko'] .site-header:not(.app-header) .lang-menu > summary {
    width: 44px;
    padding: 0;
    gap: 0;
  }
  html[lang='ko'] .site-header:not(.app-header) .lang-menu .lang-code,
  html[lang='ko'] .site-header:not(.app-header) .lang-menu > summary::after {
    display: none;
  }
}
@media (min-width: 1012px) and (max-width: 1479px) {
  html[lang='ja'] .site-header:not(.app-header) .header-actions {
    gap: 6px;
  }
  html[lang='ja'] .site-header:not(.app-header) .lang-menu > summary {
    width: 44px;
    padding: 0;
    gap: 0;
  }
  html[lang='ja'] .site-header:not(.app-header) .lang-menu .lang-code,
  html[lang='ja'] .site-header:not(.app-header) .lang-menu > summary::after {
    display: none;
  }
}
@media (min-width: 1020px) and (max-width: 1549px) {
  html[lang='de'] .site-header:not(.app-header) .header-actions {
    gap: 6px;
  }
  html[lang='de'] .site-header:not(.app-header) .lang-menu > summary {
    width: 44px;
    padding: 0;
    gap: 0;
  }
  html[lang='de'] .site-header:not(.app-header) .lang-menu .lang-code,
  html[lang='de'] .site-header:not(.app-header) .lang-menu > summary::after {
    display: none;
  }
}
@media (max-width: 1315px) {
  html[lang='en'] .site-header:not(.app-header) .site-nav {
    display: none;
  }
  html[lang='en'] .site-header:not(.app-header) .menu {
    display: block;
  }
  html[lang='en'] .site-header:not(.app-header) .bar {
    min-height: 66px;
    gap: 12px;
  }
}
@media (max-width: 1246px) {
  html[lang='ko'] .site-header:not(.app-header) .site-nav {
    display: none;
  }
  html[lang='ko'] .site-header:not(.app-header) .menu {
    display: block;
  }
  html[lang='ko'] .site-header:not(.app-header) .bar {
    min-height: 66px;
    gap: 12px;
  }
}
@media (max-width: 1387px) {
  html[lang='ja'] .site-header:not(.app-header) .site-nav {
    display: none;
  }
  html[lang='ja'] .site-header:not(.app-header) .menu {
    display: block;
  }
  html[lang='ja'] .site-header:not(.app-header) .bar {
    min-height: 66px;
    gap: 12px;
  }
}
@media (max-width: 1453px) {
  html[lang='de'] .site-header:not(.app-header) .site-nav {
    display: none;
  }
  html[lang='de'] .site-header:not(.app-header) .menu {
    display: block;
  }
  html[lang='de'] .site-header:not(.app-header) .bar {
    min-height: 66px;
    gap: 12px;
  }
}
@media (min-width: 927px) and (max-width: 1315px) {
  html[lang='en'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 12px;
  }
  html[lang='en'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 8px;
  }
  html[lang='en'] .site-header:not(.app-header) .menu-cta {
    display: none;
  }
}
@media (min-width: 890px) and (max-width: 1246px) {
  html[lang='ko'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 12px;
  }
  html[lang='ko'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 8px;
  }
  html[lang='ko'] .site-header:not(.app-header) .menu-cta {
    display: none;
  }
}
@media (min-width: 1012px) and (max-width: 1387px) {
  html[lang='ja'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 12px;
  }
  html[lang='ja'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 8px;
  }
  html[lang='ja'] .site-header:not(.app-header) .menu-cta {
    display: none;
  }
}
@media (min-width: 1020px) and (max-width: 1453px) {
  html[lang='de'] .site-header:not(.app-header) .header-actions .btn-sm {
    padding: 0 12px;
  }
  html[lang='de'] .site-header:not(.app-header) .header-actions .btn-ghost.btn-sm {
    padding: 0 8px;
  }
  html[lang='de'] .site-header:not(.app-header) .menu-cta {
    display: none;
  }
}
@media (max-width: 926px) {
  html[lang='en'] .site-header:not(.app-header) .header-actions .hide-sm {
    display: none;
  }
}
@media (max-width: 889px) {
  html[lang='ko'] .site-header:not(.app-header) .header-actions .hide-sm {
    display: none;
  }
}
@media (max-width: 1011px) {
  html[lang='ja'] .site-header:not(.app-header) .header-actions .hide-sm {
    display: none;
  }
}
@media (max-width: 1019px) {
  html[lang='de'] .site-header:not(.app-header) .header-actions .hide-sm {
    display: none;
  }
}
.site-header .logo,
.site-nav a {
  white-space: nowrap;
}
/* Phones: WOTT in ink (write the full name first on a page: the link's label says it). */
@media (max-width: 560px) {
  .logo .lg.one {
    display: none;
  }
  .logo .lg.wott {
    display: inline-block;
  }
}
/* The signed-in header has more beside the logo: it takes the short form a little earlier. */
@media (max-width: 640px) {
  .app-header .logo .lg.one {
    display: none;
  }
  .app-header .logo .lg.wott {
    display: inline-block;
  }
}

/* The two top menus "For Redditors" and "For brands" (structure 3, 26 Nov 2026): <details> elements, no script
   needed. A closed details hides its panel by itself. */
.nav-menu {
  position: relative;
  display: inline-flex;
}
.nav-menu > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  color: var(--ink);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  white-space: nowrap;
  border-top: 3px solid transparent;
  border-bottom: 3px solid transparent;
}
.nav-menu > summary::-webkit-details-marker {
  display: none;
}
/* A small chevron drawn with a border; it turns when the menu is open. */
.nav-menu > summary::after {
  content: '';
  width: 7px;
  height: 7px;
  border: solid currentColor;
  border-width: 0 2px 2px 0;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.15s ease;
}
.nav-menu[open] > summary::after {
  transform: translateY(1px) rotate(-135deg);
}
.nav-menu > summary:hover {
  border-bottom-color: var(--ink);
}
.nav-menu > summary.is-current {
  border-bottom-color: var(--red);
  font-weight: 800;
}
.nav-menu-panel {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 20rem;
  margin-top: 8px;
  z-index: 30;
  background: var(--card);
  border: 2px solid var(--rule-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 14px 10px 10px;
}
.nav-menu-head {
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin: 0 0 0.5rem;
  padding: 0 12px;
}
.nav-menu-panel ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
}
.site-nav .nav-menu-panel a {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-height: 0;
  padding: 10px 12px;
  border: 0;
  border-radius: var(--radius);
  line-height: 1.25;
  white-space: normal;
}
.site-nav .nav-menu-panel a:hover {
  background: var(--paper-2);
}
.site-nav .nav-menu-panel a[aria-current='page'] {
  background: var(--accent-soft);
}
.nav-menu-panel small {
  display: block;
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--ink-2);
}
/* Phone menu: each group's heading above its plain links. */
.menu-panel .nav-menu-head {
  margin: 10px 0 2px;
  padding: 0 14px;
}
.menu-panel .nav-menu-head:first-child {
  margin-top: 4px;
}
/* The header is sticky, so a long open panel would run past the screen with no way to reach its end: the panel
   scrolls inside the screen instead (integration, 26 Nov 2026; the phone menu now holds the two groups). */
.site-header .menu-panel,
.nav-menu-panel {
  max-height: calc(100vh - 86px);
  max-height: calc(100dvh - 86px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

/* App shell (creator / brand / admin) */
.app-header .area-tag {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
  border-left: 1.5px solid var(--rule);
  padding-left: 0.9rem;
}
.app-header .who {
  font-size: 0.875rem;
  color: var(--ink-2);
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.subnav {
  border-bottom: 1.5px solid var(--rule);
  background: var(--paper);
}
.subnav .container {
  display: flex;
  gap: 0.15rem;
  overflow-x: auto;
  scrollbar-width: none;
}
.subnav .container::-webkit-scrollbar {
  display: none;
}
.subnav a {
  flex: none;
  color: var(--ink-2);
  text-decoration: none;
  padding: 0.85rem 0.8rem 0.7rem;
  border-bottom: 3px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
  min-height: 44px;
}
.subnav a:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
}
.subnav a[aria-current='page'] {
  color: var(--ink);
  font-weight: 800;
  border-bottom-color: var(--red);
}
.subnav .count {
  font-size: 0.75rem;
  background: var(--ink);
  color: var(--paper);
  border-radius: 999px;
  padding: 0.05rem 0.45rem;
  font-weight: 700;
}

/* ---------------------------------------------------------------- footer */
/* A fixed part: an ink block under a red thread. Footer redesign (1 Dec 2026, owner: "footer is way overwhelming"):
   calm and compact. The logo and one line; four short link groups in small type (muted, full cream on hover, a red
   underline); then one thin bottom bar with the (c) line, the Reddit line and small language pills.
   Wide screens: plain columns, always open (.ft-cols). Phones (640px and less): the same groups as closed <details>
   accordions (.ft-acc), a second copy of the lists. Only one copy is ever displayed (display: none hides the other
   from screen readers and the keyboard too), so each link is met once, no script is needed, and a phone never shows
   a "button" that does nothing on a desktop. */
.site-footer {
  background: var(--block);
  color: var(--block-text);
  --ink: var(--block-text);
  --ink-2: var(--block-2);
  --ink-3: var(--block-2);
  --rule: var(--block-line);
  --rule-strong: var(--block-text);
  --accent-strong: var(--block-accent);
  --paper: var(--block);
  --focus: #fff3e2;
  --accent-soft: #3a1518;
  padding: 0 0 22px;
  font-size: 0.875rem;
  line-height: 1.45;
}
.site-footer > .thread {
  margin-bottom: 0;
}
.site-footer .ft-main {
  display: grid;
  grid-template-columns: minmax(210px, 1.2fr) minmax(0, 4fr);
  gap: 48px;
  padding: 44px 0 36px;
}
.site-footer .ft-cols {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
}
.site-footer .ft-acc {
  display: none;
}
@media (max-width: 1023px) {
  .site-footer .ft-main {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}
@media (min-width: 641px) and (max-width: 760px) {
  .site-footer .ft-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.site-footer .logo {
  display: inline-block;
  color: var(--block-text);
}
.site-footer .lg {
  font-size: 24px;
}
.site-footer .tagline {
  margin: 14px 0 0;
  max-width: 30ch;
  color: var(--block-text);
  font-size: 0.9375rem;
  line-height: 1.4;
}
.site-footer .footer-reach,
.site-footer .footer-docs {
  margin: 6px 0 0;
  max-width: 32ch;
  color: var(--block-2);
  font-size: 0.8125rem;
}
.site-footer .footer-login {
  margin: 14px 0 0;
}
.site-footer .footer-login a {
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--block-accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
/* Footer column labels are styled text, not headings, so they never depend on the page's heading order. */
.site-footer h4,
.site-footer .footer-heading {
  font-family: var(--font-sans);
  font-weight: 700;
  font-stretch: 100%;
  line-height: 1;
  font-size: 11.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--block-2);
  margin: 0 0 16px;
}
.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 9px;
}
.site-footer a {
  color: var(--block-text);
  text-decoration: none;
}
.site-footer .ft-main li a,
.site-footer .ft-main .footer-linkbtn {
  color: var(--block-2);
  font-size: 0.875rem;
  line-height: 1.35;
}
.site-footer a:hover,
.site-footer .footer-linkbtn:hover {
  color: var(--block-text);
  text-decoration: underline;
  text-decoration-color: var(--block-accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}
/* "Cookie settings" in the Legal group: a button that looks like the links beside it. */
.site-footer .footer-linkbtn {
  align-items: center;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.site-footer .footer-linkbtn:focus-visible {
  outline: 3px solid var(--block-text);
  outline-offset: 2px;
}
/* The bottom bar: one thin row that wraps; the (c) and Reddit lines on the left, the language pills on the right. */
.site-footer .ft-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
  padding-top: 18px;
  border-top: 1px solid var(--block-line);
}
.site-footer .legal-line {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  /* It takes the room the pills leave and wraps inside it, so a long line (German) does not push the pills down. */
  flex: 1 1 22rem;
  min-width: 0;
  color: var(--block-2);
  font-size: 0.8125rem;
  line-height: 1.4;
}
/* The language pills (LangSwitch where="footer"): a small label with a globe, then four small pills; the current one
   is cream on ink. The pills' outline has its own value (--block-line is about 1.5:1 on the footer, too faint for a
   control's edge): #736c78 is 3:1 or more on both themes' footers (3.4:1 on the dark one). */
.lang-switch-footer {
  --lang-pill-line: #736c78;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.lang-switch-footer .lang-switch-head {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1;
  color: var(--block-2);
}
.lang-switch-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.site-footer .lang-switch-footer a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 30px;
  padding: 0 11px;
  border: 1px solid var(--lang-pill-line);
  border-radius: 999px;
  color: var(--block-text);
  font-size: 0.8125rem;
  line-height: 1;
}
.site-footer .lang-switch-footer a svg {
  width: 13px;
  height: 13px;
}
.site-footer .lang-switch-footer a .lang-native {
  font-weight: 600;
}
.site-footer .lang-switch-footer a:hover {
  border-color: var(--block-text);
  text-decoration: none;
}
.site-footer .lang-switch-footer a[aria-current='true'] {
  background: var(--block-text);
  border-color: var(--block-text);
  color: var(--block);
}
.site-footer .lang-switch-footer a[aria-current='true'] .lang-native {
  font-weight: 800;
}
/* Tablets (641 to 1023px): the brand block is one short row above the columns, the logo beside the tagline, and the
   "open to Redditors and brands in any country" line is left out, so the footer is not twice the desktop height. */
@media (min-width: 641px) and (max-width: 1023px) {
  .site-footer .ft-main {
    gap: 28px;
    padding: 36px 0 28px;
  }
  .site-footer .ft-brand {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 28px;
    align-items: center;
  }
  .site-footer .ft-brand > .logo {
    grid-row: 1 / span 3;
  }
  .site-footer .ft-brand > p {
    grid-column: 2;
    max-width: 60ch;
  }
  .site-footer .tagline {
    margin: 0;
  }
  .site-footer .footer-reach {
    display: none;
  }
  .site-footer .footer-docs {
    margin-top: 4px;
  }
  .site-footer .footer-login {
    margin-top: 8px;
  }
}
/* Phones: the brand block, then the groups as accordions (48px rows, a chevron that turns), then the bottom bar
   stacked. Links inside an open group get 44px rows for thumbs. */
@media (max-width: 640px) {
  .site-footer .ft-main {
    gap: 24px;
    padding: 32px 0 24px;
  }
  .site-footer .ft-cols {
    display: none;
  }
  .site-footer .ft-acc {
    display: block;
    border-top: 1px solid var(--block-line);
  }
  .site-footer .ft-group {
    border-bottom: 1px solid var(--block-line);
  }
  .site-footer .ft-group > summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 48px;
    color: var(--block-text);
    font-weight: 700;
    font-size: 0.9375rem;
    line-height: 1.2;
  }
  .site-footer .ft-group > summary::-webkit-details-marker {
    display: none;
  }
  .site-footer .ft-group > summary::after {
    content: '';
    flex: none;
    width: 7px;
    height: 7px;
    margin-right: 4px;
    border: solid var(--block-2);
    border-width: 0 2px 2px 0;
    transform: translateY(-2px) rotate(45deg);
    transition: transform 0.15s ease;
  }
  .site-footer .ft-group[open] > summary::after {
    transform: translateY(1px) rotate(-135deg);
    border-color: var(--block-accent);
  }
  .site-footer .ft-group > summary:focus-visible {
    outline: 3px solid var(--block-text);
    outline-offset: 2px;
  }
  .site-footer .ft-group ul {
    gap: 0;
    padding: 0 0 10px;
  }
  .site-footer .ft-group li a,
  .site-footer .ft-group .footer-linkbtn {
    display: flex;
    align-items: center;
    min-height: 44px;
    font-size: 0.9375rem;
  }
  .site-footer .ft-bottom {
    display: grid;
    justify-items: start;
    gap: 16px;
    padding-top: 0;
    border-top: 0;
  }
  .site-footer .legal-line {
    display: grid;
    gap: 4px;
  }
  .site-footer .lang-switch-footer a {
    min-height: 44px;
    padding: 0 14px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .site-footer .ft-group > summary::after {
    transition: none;
  }
}

/* ---------------------------------------------------------------- buttons */
/* Round, because you press them. One red button in a section; its label is ink. On hover a button
   swaps to its opposite, at once. */
.btn {
  --btn-bg: var(--red);
  --btn-fg: #0f0e11;
  --btn-border: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 2px solid var(--btn-border);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-weight: 700;
  font-stretch: 105%;
  font-size: 1rem;
  line-height: 1.15;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
  --btn-border: var(--ink);
  color: var(--btn-fg);
  text-decoration: none;
}
.btn:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
.btn[disabled],
.btn[aria-disabled='true'] {
  --btn-bg: var(--paper-2);
  --btn-fg: var(--ink-3);
  --btn-border: transparent;
  cursor: not-allowed;
  pointer-events: none;
}
.btn .icon {
  width: 18px;
  height: 18px;
}
/* Ink: the header button, and buttons on red. */
.btn-ink {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
}
.btn-ink:hover {
  --btn-bg: var(--red);
  --btn-fg: #0f0e11;
  --btn-border: var(--red);
}
/* Outline: every other button in a section. */
.btn-secondary {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-border: var(--ink);
}
.btn-secondary:hover {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
  --btn-border: var(--ink);
}
.btn-cream {
  --btn-bg: #fff3e2;
  --btn-fg: #0f0e11;
}
.btn-cream:hover {
  --btn-bg: #0f0e11;
  --btn-fg: #fff3e2;
  --btn-border: #0f0e11;
}
.btn-ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-border: transparent;
}
.btn-ghost:hover {
  --btn-bg: var(--paper-2);
  --btn-fg: var(--ink);
  --btn-border: transparent;
}
.btn-danger {
  --btn-bg: transparent;
  --btn-fg: var(--bad);
  --btn-border: var(--bad);
}
.btn-danger:hover {
  --btn-bg: var(--bad);
  --btn-fg: var(--paper);
  --btn-border: var(--bad);
}
.btn-ok {
  --btn-bg: var(--ok);
  --btn-fg: var(--paper);
  --btn-border: var(--ok);
}
.btn-ok:hover {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
  --btn-border: var(--ink);
}
.btn-sm {
  min-height: 44px;
  padding: 0 17px;
  font-size: 0.9375rem;
}
.btn-lg {
  min-height: 54px;
  padding: 0 26px;
  font-size: 1.0625rem;
}
.btn-block {
  display: flex;
  width: 100%;
}
.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid var(--field);
  background: transparent;
  color: var(--ink);
  display: inline-grid;
  place-items: center;
  /* .has-js .js-only turns the theme switch into inline-flex; this keeps its icon centred there too. */
  justify-content: center;
  padding: 0;
  cursor: pointer;
}
.icon-btn svg {
  width: 20px;
  height: 20px;
}
.icon-btn:hover {
  border-color: var(--ink);
  background: var(--paper-2);
  color: var(--ink);
}
.inline-form {
  display: inline;
}
.link-btn {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-weight: 600;
  color: var(--accent-strong);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  cursor: pointer;
}
.link-btn:hover {
  text-decoration-thickness: 3px;
}

/* ---------------------------------------------------------------- forms */
/* Label above, in bold. 48 px high, 16 px text so phones do not zoom. No red in a form except the send
   button; an error is berry with a mark and a sentence. */
.form {
  display: grid;
  gap: 1.35rem;
}
.form-section {
  display: grid;
  gap: 1.2rem;
  padding: clamp(20px, 2.6vw, 32px);
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-lg);
  background: var(--card);
}
.form-section > h2,
.form-section > h3 {
  margin: 0;
}
.form-row {
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}
.field {
  display: grid;
  gap: 0.45rem;
  min-width: 0;
}
.field > label,
.field > .label,
fieldset > legend {
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.35;
  color: var(--ink);
}
.req {
  color: var(--accent-strong);
  margin-left: 0.2rem;
}
.opt {
  color: var(--ink-3);
  font-weight: 400;
  font-size: 0.9em;
  margin-left: 0.3rem;
}
.hint {
  color: var(--ink-3);
  font-size: 0.875rem;
  line-height: 1.45;
}
/* Korean lines break between words, not inside them (as brand.css already does for .ko-help). */
.ko-help,
:lang(ko) {
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.error-text {
  color: var(--bad);
  font-size: 0.906rem;
  font-weight: 700;
  line-height: 1.35;
  display: flex;
  gap: 0.45rem;
  align-items: flex-start;
}
.error-text > svg {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  stroke-width: 2.2;
}
input[type='text'],
input[type='email'],
input[type='password'],
input[type='url'],
input[type='number'],
input[type='date'],
input[type='month'],
input[type='search'],
input[type='tel'],
input[type='file'],
select,
textarea {
  width: 100%;
  min-height: 48px;
  font: inherit;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--ink);
  background-color: var(--card);
  border: 1.5px solid var(--field);
  border-radius: var(--radius);
  padding: 11px 14px;
}
input[type='file'] {
  padding: 0.55rem;
}
textarea {
  min-height: 120px;
  resize: vertical;
  line-height: 1.5;
}
select {
  appearance: none;
  -webkit-appearance: none;
  background-image: var(--select-arrow);
  background-position: right 14px center;
  background-size: 18px 18px;
  background-repeat: no-repeat;
  padding-right: 44px;
}
input:hover,
select:hover,
textarea:hover {
  border-color: var(--ink);
}
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
input:focus,
select:focus,
textarea:focus {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-color: var(--ink);
  box-shadow: none;
}
input[disabled],
select[disabled],
textarea[disabled] {
  background-color: var(--paper-2);
  color: var(--ink-3);
  border-style: dashed;
  cursor: not-allowed;
}
input[aria-invalid='true'],
select[aria-invalid='true'],
textarea[aria-invalid='true'] {
  border-color: var(--bad) !important;
  border-width: 2.5px;
}
.input-prefix {
  position: relative;
}
.input-prefix > span {
  position: absolute;
  left: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-3);
  pointer-events: none;
}
.input-prefix > input {
  padding-left: 1.9rem;
}
fieldset {
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
  display: grid;
  gap: 0.6rem;
}
fieldset > legend {
  padding: 0;
  margin-bottom: 0.25rem;
}
/* Choices: the whole row is the target. The input sits on top of the row; the row is drawn by the span after it. */
.choices {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr));
}
.choices.cols-1 {
  grid-template-columns: 1fr;
}
.choice {
  position: relative;
  display: block;
  cursor: pointer;
  line-height: 1.3;
  min-width: 0;
}
.choice > input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 1;
}
.choice > input + span {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px 10px;
  height: 100%;
  min-height: 48px;
  padding: 9px 14px 9px 44px;
  position: relative;
  border: 1.5px solid var(--field);
  border-radius: var(--radius);
  background: var(--card);
  font-weight: 500;
}
.choice > input + span::before {
  content: '';
  position: absolute;
  left: 14px;
  top: 50%;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  background: var(--card);
}
.choice > input[type='checkbox'] + span::before {
  border-radius: 5px;
}
.choice:hover > input + span {
  border-color: var(--ink);
}
.choice > input:checked + span {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
  background: var(--accent-soft);
  font-weight: 700;
}
.choice > input[type='radio']:checked + span::before {
  background: radial-gradient(circle, var(--ink) 0 5px, var(--card) 5.7px);
}
.choice > input[type='checkbox']:checked + span::before {
  background: var(--ink) var(--tick) center / 15px no-repeat;
}
.choice > input:focus-visible + span {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.choice > input[disabled] + span {
  background: var(--paper-2);
  color: var(--ink-3);
  border-style: dashed;
}
.choice .choice-hint {
  display: block;
  flex-basis: 100%;
  color: var(--ink-3);
  font-size: 0.875rem;
  font-weight: 400;
  margin-top: 0.1rem;
}
.choice:has(.choice-hint) > input + span::before {
  top: 12px;
  margin-top: 0;
}
fieldset[aria-invalid='true'] .choice > input + span {
  border-color: var(--bad);
}
.check {
  position: relative;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  min-height: 44px;
  padding: 9px 0;
  line-height: 1.45;
  cursor: pointer;
}
.check input {
  appearance: none;
  -webkit-appearance: none;
  flex: none;
  width: 24px;
  height: 24px;
  margin: 0;
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-sm);
  background: var(--card);
  cursor: pointer;
}
.check input:checked {
  background: var(--ink) var(--tick) center / 16px no-repeat;
}
.check input:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.check input[aria-invalid='true'] {
  border-color: var(--bad);
  border-width: 2.5px;
}
.agreement {
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
  background: var(--paper-2);
  border: 1.5px solid transparent;
}
.agreement:has(input[aria-invalid='true']) {
  border-color: var(--bad);
}
.form-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  padding-top: 0.25rem;
}
.form-actions .spacer {
  flex: 1;
}
.counter {
  font-size: 0.875rem;
  color: var(--ink-3);
  text-align: right;
}
.counter.over {
  color: var(--bad);
  font-weight: 700;
}
/* Error summary: berry, a warning mark, a link to each field. */
.error-summary {
  border: 1.5px solid var(--bad);
  border-left-width: 5px;
  background: var(--card);
  border-radius: 4px var(--radius) var(--radius) 4px;
  padding: 14px 16px;
  color: var(--ink);
}
.error-summary h2,
.error-summary h3 {
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 700;
  font-stretch: 100%;
  letter-spacing: 0;
  margin: 0 0 0.4rem;
  color: var(--bad);
}
.error-summary ul {
  margin: 0;
  padding-left: 1.2rem;
}
.error-summary a {
  color: var(--bad);
  font-weight: 700;
}
.filters {
  display: grid;
  gap: 1rem;
}
.filters .field > label,
.filters fieldset > legend {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--ink-2);
}
.filters input,
.filters select {
  min-height: 44px;
  font-size: 1rem;
}

/* ---------------------------------------------------------------- surfaces */
/* Square things get read: cards 18 px, fields 10 px, chips 6 px. Lines are 1.5 or 2 px. */
.card {
  background: var(--card);
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-lg);
  padding: clamp(1.1rem, 2.5vw, 1.6rem);
  min-width: 0;
}
.card.flat {
  box-shadow: none;
}
.card.tight {
  padding: 1rem;
}
.card > :last-child {
  margin-bottom: 0;
}
.card-head {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.card-head h2,
.card-head h3 {
  margin: 0;
}
.card-title {
  font-family: var(--font-display);
  font-size: clamp(19px, 1.9vw, 23px);
  font-weight: 800;
  font-stretch: 108%;
  letter-spacing: -0.015em;
  line-height: 1.16;
  margin: 0;
}
a.card-link {
  display: block;
  color: inherit;
  text-decoration: none;
}
a.card-link:hover {
  border-color: var(--ink);
}
.panel {
  background: var(--card);
  border: 1.5px solid var(--rule);
  border-left: 5px solid var(--ink);
  border-radius: 4px var(--radius-lg) var(--radius-lg) 4px;
  padding: 1.25rem 1.4rem;
}
.callout {
  border-left: 5px solid var(--red);
  padding: 0.3rem 0 0.3rem 1rem;
  color: var(--ink-2);
}
.page-header {
  display: flex;
  gap: 1rem 2rem;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 2rem;
  padding-bottom: 1.4rem;
  border-bottom: 2px solid var(--rule-strong);
}
.page-header h1 {
  margin: 0;
}
.page-header .lede {
  margin: 0.6rem 0 0;
}
.page-header .actions {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.back-link {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  min-height: 44px;
  color: var(--ink-3);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.4rem;
}
.back-link:hover {
  color: var(--ink);
}
.section-title {
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin: 0 0 0.8rem;
}

/* ---------------------------------------------------------------- badges, pills, chips */
/* Pills and tags speak, so they are round; chips are read, so they are square. */
.badge {
  --b-bg: var(--neutral-soft);
  --b-fg: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--b-bg);
  color: var(--b-fg);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.2;
  white-space: nowrap;
}
.badge::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 99px;
  background: currentColor;
}
.badge.plain::before {
  display: none;
}
.badge.accent {
  --b-bg: var(--accent-soft);
  --b-fg: var(--accent-strong);
}
.badge.ok {
  --b-bg: var(--ok-soft);
  --b-fg: var(--ok);
}
.badge.warn {
  --b-bg: var(--warn-soft);
  --b-fg: var(--warn);
}
.badge.bad {
  --b-bg: var(--bad-soft);
  --b-fg: var(--bad);
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 0 13px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 0 1.5px var(--field);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink);
  background: transparent;
  white-space: nowrap;
}
/* A tint for a community, a line for a niche. */
.chip.strong {
  background: var(--accent-soft);
  box-shadow: none;
  color: var(--ink);
}
.chip.match {
  background: var(--ink);
  color: var(--paper);
  box-shadow: none;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
/* The alias is in mono: a code name, not a username. */
.alias {
  font-family: var(--font-mono);
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* ---------------------------------------------------------------- notices */
/* Each kind has its own edge, its own mark and its own words, so colour is never the only sign. */
.alert {
  --a-bg: var(--paper);
  --a-fg: var(--ink);
  --a-bar: var(--ink);
  --a-line: var(--rule);
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 4px var(--radius) var(--radius) 4px;
  background: var(--a-bg);
  color: var(--a-fg);
  border: 1.5px solid var(--a-line);
  border-left: 5px solid var(--a-bar);
}
.alert > svg {
  color: var(--a-bar);
  margin-top: 0.15rem;
  width: 22px;
  height: 22px;
}
.alert p:last-child {
  margin-bottom: 0;
}
.alert strong.alert-title {
  display: block;
  margin-bottom: 0.15rem;
}
.alert.ok {
  --a-bg: var(--ok-soft);
  --a-bar: var(--ok);
  --a-line: var(--ok);
}
.alert.warn {
  --a-bg: var(--warn-soft);
  --a-bar: var(--warn);
  --a-line: var(--warn);
}
.alert.bad {
  --a-bg: var(--card);
  --a-bar: var(--bad);
  --a-line: var(--bad);
}
.flash {
  margin-bottom: 1.5rem;
}

/* ---------------------------------------------------------------- tables */
.table-wrap {
  overflow-x: auto;
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-lg);
  background: var(--card);
}
table.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
}
.table th {
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding: 0.8rem 1rem;
  border-bottom: 2px solid var(--rule-strong);
  background: var(--card);
  white-space: nowrap;
}
.table td {
  padding: 0.8rem 1rem;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
.table tr:last-child td {
  border-bottom: 0;
}
.table tbody tr:hover td {
  background: var(--paper);
}
.table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.table a.row-link {
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}
.table a.row-link:hover {
  color: var(--accent-strong);
  text-decoration: underline;
}
@media (max-width: 640px) {
  table.table.stack-sm thead {
    display: none;
  }
  table.table.stack-sm tr {
    display: block;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--rule);
  }
  table.table.stack-sm td {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    border: 0;
    padding: 0.3rem 1rem;
  }
  table.table.stack-sm td[data-label]::before {
    content: attr(data-label);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ink-2);
    font-weight: 700;
  }
}

/* ---------------------------------------------------------------- key/value, stats */
dl.kv {
  display: grid;
  grid-template-columns: minmax(110px, max-content) 1fr;
  gap: 0.55rem 1.25rem;
  margin: 0;
}
dl.kv dt {
  color: var(--ink-3);
  font-size: 0.875rem;
}
dl.kv dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}
@media (max-width: 480px) {
  dl.kv {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }
  dl.kv dd {
    margin-bottom: 0.6rem;
  }
}
.stat {
  padding: 1.1rem 1.2rem;
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-lg);
  background: var(--card);
}
.stat .stat-value {
  font-family: var(--font-display);
  font-size: 2.2rem;
  line-height: 1;
  font-weight: 900;
  font-stretch: 112%;
  letter-spacing: -0.03em;
  display: block;
  font-variant-numeric: tabular-nums;
}
.stat .stat-label {
  color: var(--ink-3);
  font-size: 0.875rem;
  margin-top: 0.45rem;
  display: block;
}
a.stat {
  text-decoration: none;
  color: inherit;
}
a.stat:hover {
  border-color: var(--ink);
}
.scorebar {
  height: 6px;
  border-radius: 99px;
  background: var(--paper-2);
  overflow: hidden;
}
.scorebar > span {
  display: block;
  height: 100%;
  background: var(--ink);
  border-radius: 99px;
}
.score-pill {
  display: inline-grid;
  place-items: center;
  min-width: 46px;
  height: 46px;
  padding: 0 0.7rem;
  border-radius: 999px;
  border: 2px solid var(--ink);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  font-variant-numeric: tabular-nums;
}

/* ---------------------------------------------------------------- empty state, pagination, tabs, stepper */
.empty {
  text-align: center;
  padding: clamp(2rem, 5vw, 3.5rem) 1.5rem;
  border: 1.5px dashed var(--field);
  border-radius: var(--radius-lg);
  color: var(--ink-2);
}
.empty .empty-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 0.9rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--paper-2);
  color: var(--ink-2);
}
.empty h3 {
  margin-bottom: 0.35rem;
}
.empty p {
  max-width: 46ch;
  margin: 0 auto 1rem;
  color: var(--ink-2);
}
.pagination {
  display: flex;
  gap: 0.4rem;
  justify-content: center;
  align-items: center;
  margin-top: 2rem;
  flex-wrap: wrap;
}
.pagination a,
.pagination span {
  min-width: 44px;
  height: 44px;
  padding: 0 0.7rem;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  border: 1.5px solid var(--field);
  text-decoration: none;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 600;
}
.pagination a:hover {
  border-color: var(--ink);
  background: var(--paper-2);
}
.pagination [aria-current='page'] {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.pagination .disabled {
  color: var(--ink-3);
  border-style: dashed;
}
.tabs {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.tabs a {
  min-height: 44px;
  padding: 0 1rem;
  border-radius: 999px;
  border: 1.5px solid var(--field);
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 600;
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
}
.tabs a:hover {
  border-color: var(--ink);
  color: var(--ink);
}
.tabs a[aria-current='page'] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.tabs .n {
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}
.stepper {
  display: flex;
  gap: 0.4rem;
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  counter-reset: step;
  overflow-x: auto;
}
.stepper li {
  flex: 1;
  min-width: 92px;
  counter-increment: step;
}
.stepper a,
.stepper span {
  display: block;
  padding-top: 0.65rem;
  border-top: 4px solid var(--rule);
  color: var(--ink-2);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.3;
}
.stepper a::before,
.stepper span::before {
  content: counter(step, decimal-leading-zero) ' ';
  font-family: var(--font-display);
  font-weight: 800;
  margin-right: 0.15rem;
}
.stepper .done a,
.stepper .done span {
  border-top-color: var(--ink);
  color: var(--ink-2);
}
.stepper .current a,
.stepper .current span {
  border-top-color: var(--red);
  color: var(--ink);
  font-weight: 800;
}
/* Phones: every step keeps its bar and number; only the current step shows its label, on one line.
   The other labels stay in the markup (font-size 0) for screen readers. */
@media (max-width: 560px) {
  .stepper {
    gap: 0.3rem;
    overflow: visible;
  }
  .stepper li {
    flex: 1 1 0;
    min-width: 0;
  }
  .stepper li.current {
    flex: 3 1 auto;
  }
  .stepper li:not(.current) a,
  .stepper li:not(.current) span {
    font-size: 0;
  }
  .stepper li:not(.current) a::before,
  .stepper li:not(.current) span::before {
    font-size: 0.875rem;
    margin-right: 0;
  }
  .stepper li.current a,
  .stepper li.current span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .stepper a {
    min-height: 44px;
  }
}
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
}
.timeline li {
  position: relative;
  padding: 0 0 1.1rem 1.4rem;
  border-left: 2px solid var(--rule);
  margin-left: 5px;
}
.timeline li:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}
.timeline li::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 0.35rem;
  width: 12px;
  height: 12px;
  border-radius: 99px;
  background: var(--card);
  border: 2.5px solid var(--ink);
}
.timeline .when {
  color: var(--ink-3);
  font-size: 0.875rem;
}

/* ---------------------------------------------------------------- misc */
.divider {
  height: 1.5px;
  background: var(--rule);
  margin: 1.5rem 0;
}
.list-plain {
  list-style: none;
  padding: 0;
  margin: 0;
}
.list-check {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0;
}
.list-check li {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  padding: 10px 0;
  border-top: 1px solid var(--rule);
}
.list-check li:first-child {
  border-top: 0;
}
.list-check li > svg {
  color: var(--accent-strong);
  margin-top: 0.22rem;
  stroke-width: 2.6;
}
.code-box {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 0.7rem 1rem;
  border: 2px dashed var(--ink);
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--ink);
}
details.disclosure {
  border: 1.5px solid var(--rule);
  border-radius: var(--radius);
  background: var(--card);
}
details.disclosure > summary {
  cursor: pointer;
  padding: 0.85rem 1rem;
  min-height: 44px;
  font-weight: 700;
}
details.disclosure > div {
  padding: 0 1rem 1rem;
}
.text-right {
  text-align: right;
}
.mt-0 {
  margin-top: 0 !important;
}
.mb-0 {
  margin-bottom: 0 !important;
}
.mt-1 {
  margin-top: 1rem;
}
.mt-2 {
  margin-top: 2rem;
}
.mb-1 {
  margin-bottom: 1rem;
}
.mb-2 {
  margin-bottom: 2rem;
}
.w-full {
  width: 100%;
}
.error-page {
  text-align: center;
  padding: 80px 0;
}
/* A big number on cream: red is large type only (3.79:1). */
.error-page .code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 12vw, 8rem);
  line-height: 0.9;
  font-weight: 900;
  font-stretch: 125%;
  letter-spacing: -0.03em;
  color: var(--red);
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}
@media print {
  .site-header,
  .subnav,
  .site-footer {
    display: none;
  }
}

/* ---------------------------------------------------------------- auth pages (shared) */
.auth-wrap {
  max-width: 480px;
  margin: 0 auto;
  display: grid;
  gap: 1.2rem;
}
.auth-card.card {
  border: 2px solid var(--rule-strong);
  padding: clamp(20px, 2.6vw, 32px);
}
.auth-card h1 {
  font-size: clamp(28px, 3.4vw, 40px);
}
.center-text {
  text-align: center;
}

/* ---------------------------------------------------------------- creator card (shared, brand-facing) */
/* How a brand meets a Redditor: by an alias, never a username. Straight, never tilted, no sticker. */
.creator-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--card);
  color: var(--ink);
  border: 2px solid var(--rule-strong);
  border-radius: var(--radius-lg);
  padding: 20px 20px 18px;
  min-width: 0;
}
.creator-card:has(> a.creator-card-alias, .creator-card-head a):hover {
  border-color: var(--ink);
}
.creator-card.is-inactive {
  opacity: 0.6;
}
.creator-card-label {
  position: absolute;
  top: -13px;
  left: 18px;
  background: var(--ink);
  color: var(--paper);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 4px 11px;
  border-radius: 999px;
}
/* The example line stays attached in every size and crop: an ink strip across the top of the card. */
.creator-card-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -20px -20px 6px;
  padding: 10px 20px;
  border-radius: 16px 16px 0 0;
  background: var(--ink);
  color: var(--card);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.creator-card-note svg {
  flex: none;
}
.creator-card-head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: center;
}
.creator-card-id {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
/* The bubble holds the first letter of the alias. */
.creator-card-av {
  position: relative;
  flex: none;
  display: grid;
  place-items: center;
  width: 56px;
  height: 50px;
  background: var(--bubble-red) center / contain no-repeat;
}
.creator-card-av b {
  position: relative;
  top: -5px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 900;
  font-stretch: 112%;
  line-height: 1;
  color: #0f0e11;
}
.creator-card-alias {
  display: inline-block;
  font-size: 1.5rem;
  line-height: 1.05;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
a.creator-card-alias:hover {
  color: var(--accent-strong);
  text-decoration: underline;
}
.creator-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.6rem;
  align-items: center;
  margin-top: 6px;
  color: var(--ink-3);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.3;
}
/* The pitch is the person's own words: serif italic, with quote marks. */
.creator-card-pitch {
  font-family: var(--font-quote);
  font-style: italic;
  font-weight: 400;
  font-size: 1.3125rem;
  line-height: 1.32;
  color: var(--ink);
  margin: 4px 0 2px;
}
.creator-card-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 2px 0 0;
}
@media (min-width: 520px) {
  .creator-card-facts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.creator-card-facts.is-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.creator-card-facts > div {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 9px 11px;
  min-width: 0;
}
.creator-card-facts dt {
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink-3);
}
.creator-card-facts dd {
  margin: 3px 0 0;
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}
.creator-card-source {
  margin: 0;
  display: flex;
  gap: 7px;
  align-items: center;
  font-weight: 500;
}
/* "Our team's rating Strong / Good" (D7, step 5): the label only, never a number. */
.creator-card-rating {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: baseline;
}
.creator-card-rating strong {
  font-weight: 800;
}
.creator-card-offers {
  margin: 0;
  padding-top: 11px;
  border-top: 1px solid var(--rule);
  color: var(--ink);
  line-height: 1.45;
}
.creator-card-actions {
  margin-top: auto;
  padding-top: 0.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}
@media (max-width: 380px) {
  .creator-card {
    padding: 16px 14px 14px;
  }
  .creator-card-note {
    margin: -16px -14px 4px;
    padding: 9px 14px;
  }
  .creator-card-id {
    gap: 9px;
  }
  .creator-card-av {
    width: 44px;
    height: 39px;
  }
  .creator-card-av b {
    font-size: 15px;
    top: -4px;
  }
  .creator-card-alias {
    font-size: 1.25rem;
  }
}

/* ---------------------------------------------------------------- small phones */
@media (max-width: 480px) {
  .site-header .bar {
    gap: 10px;
  }
  .app-header .area-tag {
    padding-left: 0.6rem;
    letter-spacing: 0.06em;
  }
  .hide-xs {
    display: none;
  }
}

/* ---------------------------------------------------------------- brand v5 finish (24 Nov 2026): fixes first made in the area files, now for every page */
/* Choice tiles: wrapped lines do not stretch, so a hint sits under its title and tiles in a row line up. */
.choice > input + span { align-content: center; }
.choice:has(.choice-hint) > input + span { align-content: flex-start; }
/* The app header fits a 320 px phone. */
@media (max-width: 380px) {
  .app-header .header-actions { gap: 4px; }
  .app-header .header-actions .btn-sm { padding: 0 12px; }
}
/* Long button labels wrap on phones instead of running off the screen. */
@media (max-width: 480px) { .btn { white-space: normal; } }
/* Hidden labels inside a scrolling table stay inside it. */
.table-wrap { position: relative; }

/* ---------------------------------------------------------------- portals on apply (25 Nov 2026, integration) */
/* At 320 px the logo, the area tag ("Brand", "Redditor", "Account") and the three header buttons do not fit on
   one line, so the page scrolled sideways (brand pages 338 px, /account 357 px). Below 375 px the tag goes: the
   area nav and the H1 already say where you are. */
@media (max-width: 374px) {
  .app-header .area-tag {
    display: none;
  }
}

/* ---------------------------------------------------------------- language switch (redesign, 1 Dec 2026)
   English, 한국어, 日本語, Deutsch: plain links to the same page in each language, no script needed.
   Header (all widths): a globe button with the current code (EN / KO / JA / DE) opens a small card, in the
   same style as the "For Redditors" / "For brands" menus. Phone menu: a "Language" group, a 2 x 2 grid of pills.
   Footer: a labelled row of pills. The current language is marked with a check and a fill. */
.lang-switch ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.lang-switch a {
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.lang-switch a:hover {
  color: var(--ink);
  text-decoration: none;
}
.lang-switch .icon {
  flex: none;
}
.lang-switch-head {
  margin: 0;
}

/* The header button. */
.lang-menu {
  position: relative;
  display: inline-flex;
}
.lang-menu > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px 0 11px;
  border: 1.5px solid var(--field);
  border-radius: 999px;
  color: var(--ink);
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.04em;
  line-height: 1;
  white-space: nowrap;
  user-select: none;
  -webkit-user-select: none;
}
.lang-menu > summary::-webkit-details-marker {
  display: none;
}
.lang-menu > summary::after {
  content: '';
  width: 6px;
  height: 6px;
  margin-left: 1px;
  border: solid currentColor;
  border-width: 0 1.8px 1.8px 0;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.15s ease;
}
.lang-menu > summary:hover {
  border-color: var(--ink);
  background: var(--paper-2);
}
.lang-menu[open] > summary {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.lang-menu[open] > summary::after {
  transform: translateY(1px) rotate(-135deg);
}
.lang-menu > summary .icon {
  width: 18px;
  height: 18px;
  flex: none;
}

/* The open card: right edge under the button's right edge, never wider than the screen. */
.lang-menu-panel {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 8px;
  width: 15rem;
  max-width: calc(100vw - 24px);
  z-index: 30;
  background: var(--card);
  border: 2px solid var(--rule-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 12px 8px 8px;
}
.lang-switch-header .lang-switch-head {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding: 0 12px;
  margin-bottom: 6px;
}
.lang-switch-header ul {
  display: grid;
  gap: 2px;
}
.lang-switch-header a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  /* One height for every row: English has no second line, the other three do (1 Dec 2026). */
  min-height: 52px;
  padding: 7px 12px;
  border-radius: var(--radius);
  line-height: 1.2;
}
.lang-switch-header a:hover {
  background: var(--paper-2);
}
.lang-switch-header a[aria-current='true'] {
  background: var(--accent-soft);
}
/* Dark theme: the blush is close to the card, so the current row also gets a stronger tint and a 1.5 px red line
   (inset, so the rows keep their size). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .lang-switch-header a[aria-current='true'] {
    background: #4a1a1e;
    box-shadow: inset 0 0 0 1.5px var(--accent-strong);
  }
}
:root[data-theme='dark'] .lang-switch-header a[aria-current='true'] {
  background: #4a1a1e;
  box-shadow: inset 0 0 0 1.5px var(--accent-strong);
}
.lang-switch-header a[aria-current='true'] .icon {
  color: var(--accent-strong);
}
.lang-switch-header a:focus-visible {
  outline-offset: 0;
}
.lang-names {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.lang-native {
  font-weight: 700;
}
.lang-switch-header .lang-native {
  font-size: 1rem;
  font-weight: 600;
}
/* The current language's native name is the boldest word in the card, in both themes. */
.lang-switch-header a[aria-current='true'] .lang-native {
  font-weight: 800;
}
.lang-en {
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--ink-2);
}

/* Phones: a compact button (globe and code, no chevron); the card hangs from the header's right edge instead of
   the button's, so it never leaves a 320 px screen. */
@media (max-width: 600px) {
  .lang-menu {
    position: static;
  }
  .lang-menu > summary {
    gap: 4px;
    padding: 0 10px;
  }
  .lang-menu > summary::after {
    display: none;
  }
  .lang-menu-panel {
    top: calc(100% + 8px);
    right: 12px;
    margin-top: 0;
  }
}
/* The narrowest phones (340 px or less): the button is the globe alone (its label still names the language), so
   the logo, the button, the theme switch and the menu button fit a 300 px screen without sideways scrolling. */
@media (max-width: 340px) {
  .lang-menu > summary {
    width: 44px;
    padding: 0;
    gap: 0;
  }
  .lang-menu .lang-code {
    display: none;
  }
}

/* The phone menu: a "Language" group with four pills, two by two. */
.lang-switch-menu {
  padding: 4px 0 4px;
}
.lang-switch-menu .lang-switch-head {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin: 10px 0 8px;
  padding: 0 14px;
}
.lang-switch-menu ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 0 4px;
}
.lang-switch-menu a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 48px;
  padding: 0 12px;
  border: 1.5px solid var(--field);
  border-radius: 999px;
  font-weight: 600;
}
.lang-switch-menu a:hover {
  border-color: var(--ink);
  background: var(--paper-2);
}
.lang-switch-menu a[aria-current='true'] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.lang-switch-menu a[aria-current='true'] .lang-native {
  font-weight: 800;
}

/* The footer language pills and the footer notes live with the footer rules above (footer redesign, 1 Dec 2026). */

/* ---------------------------------------------------------------- cookie consent (1 Dec 2026) */
/* The Google Analytics banner (public/js/consent.js). It sits over the page, so nothing moves when it appears.
   Desktop: a small card bottom-right (bottom-left sat on the hero buttons at laptop heights). Phones: a bar along the bottom, gone as soon as a choice is made; while it is
   open, the page gets the same space at its end, so the footer and the last buttons can still be reached. */
.cc {
  position: fixed;
  z-index: 60;
  right: 20px;
  bottom: 20px;
  width: min(400px, calc(100vw - 40px));
  display: grid;
  gap: 12px;
  padding: 16px 18px;
  background: var(--card);
  color: var(--ink);
  border: 2px solid var(--rule-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.cc[hidden] {
  display: none;
}
.cc-text {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.45;
}
.cc-text a {
  color: var(--accent-strong);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cc-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.cc-actions .btn {
  width: 100%;
}
.cc-shown body {
  padding-bottom: var(--cc-space, 0px);
}
@media (max-width: 560px) {
  .cc {
    left: 0;
    right: 0;
    bottom: 0;
    width: auto;
    gap: 10px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
    border-width: 2px 0 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
  .cc-text {
    font-size: 0.875rem;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .cc:not([hidden]) {
    animation: cc-in 0.2s ease-out;
  }
}
@keyframes cc-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
/* "Cookie settings" in the footer: styled with the footer rules above (footer redesign, 1 Dec 2026). */
@media print {
  .cc {
    display: none !important;
  }
}
