/* Herzensstimme: written for the folder-and-fields site (DESIGN.md). Warm white with a breath of rose, dark grey
   text, Georgia headings, the logo's rose as the one accent. Phone first; light start, the visitor's sun/moon switch
   at the top right (scheme.js). Sizes, spacing and shadows follow the old site (DESIGN.md › Decisions). Layers per
   frontend.md › Starter contract; token names per the role token contract. */
@layer tokens, base, compositions, components, utilities;

@layer tokens {
  :root {
    color-scheme: light;
    --bg: light-dark(oklch(0.99 0.004 10), oklch(0.2 0.014 10));
    --surface: light-dark(oklch(0.97 0.009 10), oklch(0.235 0.016 10));
    --surface-2: light-dark(oklch(0.995 0.002 10), oklch(0.27 0.018 10));
    --text: light-dark(oklch(0.33 0.012 10), oklch(0.93 0.007 10));
    --text-heading: light-dark(oklch(0.25 0.014 10), oklch(0.97 0.006 10));
    --text-quiet: light-dark(oklch(0.48 0.014 10), oklch(0.77 0.014 10));
    --text-on-action: light-dark(oklch(0.99 0.004 10), oklch(0.18 0.02 10));
    --border: light-dark(oklch(0.9 0.012 10), oklch(0.35 0.02 10));
    --border-control: light-dark(oklch(0.6 0.04 10), oklch(0.6 0.04 10));
    --edge: light-dark(oklch(0.92 0.012 10), oklch(0.33 0.02 10));
    --action: light-dark(oklch(0.5 0.18 10), oklch(0.77 0.12 10));
    --action-strong: light-dark(oklch(0.42 0.16 10), oklch(0.85 0.09 10));
    --action-soft: light-dark(oklch(0.95 0.025 10), oklch(0.3 0.05 10));
    --focus: var(--action);
    /* The head over the scrolling page: translucent and blurred. */
    --glass: light-dark(oklch(1 0.005 10 / 0.72), oklch(0.18 0.02 10 / 0.84));
    --glass-edge: light-dark(oklch(0.9 0.012 10 / 0.6), oklch(1 0.01 10 / 0.12));
    /* light-dark() takes colours only, so it sits in the shadow's colour (frontend.md › Solved pitfalls). */
    --shadow-color: light-dark(oklch(0.42 0.04 10 / 0.12), oklch(0 0 0 / 0.4));
    --shadow-1: 0 1px 3px var(--shadow-color);
    --shadow-2: 0 4px 12px var(--shadow-color);
    --shadow-3: 0 12px 32px var(--shadow-color);

    --font-body: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    --font-heading: Georgia, 'Iowan Old Style', 'Times New Roman', serif;
    --step--1: clamp(0.875rem, 0.82rem + 0.28vw, 1rem);
    --step-0: clamp(1rem, 0.94rem + 0.3vw, 1.125rem);
    --step-1: clamp(1.125rem, 1.05rem + 0.38vw, 1.3125rem);
    --step-2: clamp(1.25rem, 1.1rem + 0.75vw, 1.625rem);
    --step-3: clamp(1.5rem, 1.25rem + 1.25vw, 2.125rem);
    --step-4: clamp(1.875rem, 1.5rem + 1.88vw, 2.875rem);
    --step-5: clamp(1.875rem, 6vw, 5rem);
    --leading: 1.6;

    --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s6: 24px; --s8: 32px; --s12: 48px; --s16: 64px;
    /* Fluid spacing for text and sections, as on the old site. */
    --space-s: clamp(0.75rem, 0.6rem + 0.75vw, 1.25rem);
    --space-m: clamp(1rem, 0.8rem + 1vw, 1.75rem);
    --space-l: clamp(1.5rem, 1.2rem + 1.5vw, 2.5rem);
    --space-xl: clamp(2rem, 1.5rem + 2.5vw, 4rem);
    --space-2xl: clamp(3rem, 2rem + 5vw, 6rem);
    --radius-s: 0.5rem;
    --radius-m: 0.75rem;
    --radius-l: 1rem;
    --radius-xl: 1.5rem;
    --measure: 45rem;
    --wide: 65rem;
    --max: 80rem;
    --head: 5rem;
    --gutter: max(var(--s4) + env(safe-area-inset-left), min(5vw, var(--s8)));
    --duration: 160ms;

    --player-accent: var(--action);
    --player-bg: var(--surface-2);
    --player-radius: var(--radius-m);
    --player-focus: var(--focus);
  }
  :root:has(input[name='scheme'][value='dark']:checked),
  :root[data-scheme='dark'] { color-scheme: dark; }
  :root:has(input[name='scheme'][value='light']:checked),
  :root[data-scheme='light'] { color-scheme: light; }
}

@layer base {
  *, *::before, *::after { box-sizing: border-box; }
  /* The sticky head never covers a focused or targeted element (frontend.md › Accessibility floor). */
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--head) + var(--s4)); }
  body {
    margin: 0;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--text);
    font: var(--step-0) / var(--leading) var(--font-body);
    overflow-wrap: break-word;
  }
  main { flex: 1; }
  h1, h2, h3 {
    font-family: var(--font-heading);
    font-weight: 400;
    color: var(--text-heading);
    line-height: 1.15;
    margin: 0;
    text-wrap: balance;
  }
  h1 { font-size: var(--step-4); }
  h2 { font-size: var(--step-4); }
  h3 { font-size: var(--step-3); }
  p, ul, ol, dl, blockquote, figure { margin: 0; }
  img { max-width: 100%; height: auto; display: block; }
  a { color: var(--action); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
  a:hover { color: var(--action-strong); text-decoration-thickness: 2px; }
  :focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
  hr { border: 0; border-top: 1px solid var(--border); margin: var(--space-l) 0; }
  strong { font-weight: 650; }
  [hidden] { display: none !important; }
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  }
}

/* Page to page a soft cross-fade where the browser has it (Chrome, Safari), not under reduced motion. */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
}

@layer compositions {
  /* The page column: text at a readable measure, bands and rows wider. */
  .seite, .band { width: min(100% - 2 * var(--gutter), var(--wide)); margin-inline: auto; }
  .seite { width: min(100% - 2 * var(--gutter), var(--max)); padding-block: var(--space-l) var(--space-2xl); display: grid; gap: var(--space-l); }
  .seite > * { width: min(100%, var(--measure)); margin-inline: auto; }
  .seite > .zeilen, .seite > .orte { width: 100%; }
  .text > * + * { margin-top: var(--space-m); }
  .text > * + h2 { margin-top: var(--space-xl); }
  .text > * + h3 { margin-top: var(--space-l); }
  .text > h2 + *, .text > h3 + * { margin-top: var(--space-m); }
  .text > hr { clear: both; margin-block: var(--space-l) 0; }
}

@layer components {
  /* Head: sticky and translucent; the name at the start, the navigation in the middle (behind a button on narrow
     screens, frontend.md › Layout), the scheme switch at the end. */
  .skip { position: absolute; left: var(--s2); top: -10rem; padding: var(--s2) var(--s4); background: var(--surface-2); z-index: 110; }
  .skip:focus { top: var(--s2); }
  .kopf {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--glass);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-edge);
  }
  .kopf-innen {
    width: min(100% - 2 * var(--gutter), var(--max));
    margin-inline: auto;
    min-height: var(--head);
    display: flex;
    align-items: center;
    gap: var(--s2) var(--space-m);
  }
  .marke { display: grid; color: var(--text-heading); text-decoration: none; line-height: 1.2; padding-block: var(--s2); margin-inline-end: auto; }
  .marke:hover { color: var(--text-heading); }
  .marke-name { font-family: var(--font-heading); font-size: var(--step-1); }
  .marke-was { font-size: 0.8rem; color: var(--text-quiet); letter-spacing: 0.04em; }
  .menu-auf, .menu-zu, .schema label {
    display: none;
    inline-size: 44px;
    block-size: 44px;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: var(--radius-s);
    background: none;
    color: var(--text-heading);
    cursor: pointer;
  }
  .menu-auf:hover, .menu-zu:hover, .schema label:hover { background: var(--surface); }
  .menu-auf svg, .menu-zu svg, .schema svg { inline-size: 24px; block-size: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
  .nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s1) var(--space-l); }
  .nav a {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--text);
    font-size: var(--step--1);
    font-weight: 500;
    text-decoration: none;
  }
  .nav a::after {
    content: '';
    position: absolute;
    inset-inline-start: 0;
    bottom: 6px;
    inline-size: 0;
    block-size: 2px;
    background: var(--action);
    transition: inline-size var(--duration);
  }
  .nav a:hover::after, .nav a[aria-current]::after { inline-size: 100%; }
  .nav a:hover, .nav a[aria-current] { color: var(--action); }
  @supports selector(:popover-open) {
    @media (width < 52rem) {
      .menu-auf, .menu-zu { display: grid; }
      .menu-auf { order: 1; }
      .nav {
        inset: 0 0 auto auto;
        margin: 0;
        inline-size: min(20rem, 100vw);
        block-size: 100dvh;
        max-block-size: none;
        padding: var(--s2) var(--s6) var(--s8);
        border: 0;
        border-left: 1px solid var(--edge);
        background: var(--surface-2);
        color: var(--text);
        box-shadow: var(--shadow-3);
      }
      .nav::backdrop { background: oklch(0.2 0.02 10 / 0.35); }
      .menu-zu { margin-inline-start: auto; }
      .nav ul { flex-direction: column; gap: 0; margin-top: var(--s4); }
      .nav li { border-bottom: 1px solid var(--border); }
      .nav a { font-family: var(--font-heading); font-size: 1.25rem; font-weight: 400; min-height: 52px; width: 100%; }
      .nav a::after { content: none; }
    }
  }
  @media (width >= 52rem) {
    .nav { display: block; position: static; inset: auto; margin: 0 auto; padding: 0; border: 0; background: none; color: inherit; overflow: visible; inline-size: auto; block-size: auto; }
    .menu-auf, .menu-zu { display: none; }
  }

  /* The scheme switch (frontend.md › Colour scheme): the radios Hell and Dunkel as icons, only the one to switch to
     shown, with the icon of the scheme in force (base.html); on narrow screens before the menu button. The checked one stays focusable, hidden from the eye, so focus is never lost on a switch. */
  .schema { position: relative; display: flex; border: 0; margin: 0; padding: 0; border-radius: var(--radius-s); }
  .schema label { display: grid; position: relative; }
  .schema input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
  .schema label:has(:checked), .schema:not(:has(:checked)) .schema-hell {
    position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%);
  }
  .schema:has(:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }

  .entwurf { font: 600 0.7rem/1 var(--font-body); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-quiet); border: 1px solid var(--border-control); border-radius: 99px; padding: 0.2em 0.5em; vertical-align: middle; }
  .entwurf-hinweis { text-align: center; padding: var(--s2); background: var(--action-soft); font-size: var(--step--1); }

  /* Foot: name and links, centred on the phone, in one row from 40rem. */
  .fuss { background: var(--surface); border-top: 1px solid var(--edge); margin-top: var(--s12); }
  main:has(> .band--flaeche:last-child) + .fuss { margin-top: 0; }
  .fuss-innen {
    width: min(100% - 2 * var(--gutter), var(--max));
    margin-inline: auto;
    padding-block: var(--space-l) calc(var(--space-l) + env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--s2) var(--s8);
    text-align: center;
    font-size: var(--step--1);
    color: var(--text-quiet);
  }
  .fuss-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 0 var(--space-s); }
  .fuss-links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text-quiet); text-decoration: none; }
  .fuss-links a:hover { color: var(--action); text-decoration: underline; }
  @media (width >= 40rem) {
    .fuss-innen { flex-direction: row; justify-content: space-between; text-align: start; }
    .fuss-links { justify-content: flex-end; }
  }

  /* Buttons: the rose ground, or its outline. */
  .knopf, .text p > strong:only-child > a:only-child {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: var(--space-s) var(--space-l);
    border: 2px solid var(--action);
    border-radius: var(--radius-s);
    background: var(--action);
    color: var(--text-on-action);
    font: inherit;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--duration), color var(--duration), translate var(--duration);
  }
  .knopf:hover, .text p > strong:only-child > a:only-child:hover {
    background: var(--action-strong); border-color: var(--action-strong); color: var(--text-on-action); text-decoration: none; translate: 0 -1px;
  }
  .knopf--rand { background: transparent; color: var(--action); }
  .knopf--rand:hover { background: var(--action); border-color: var(--action); color: var(--text-on-action); }
  .knopf--klein { min-height: 44px; padding: var(--s2) var(--space-m); font-size: var(--step--1); }

  .unterzeile { font-family: var(--font-heading); font-style: italic; color: var(--text-quiet); letter-spacing: 0.01em; }

  /* Music: a paragraph that is a track row (the core player's <tinypage-track>) is a quiet card; a download link in its
     note (Markdown: [Herunterladen](/media/….mp3) after the row's title) is a small outlined button at its end. */
  .text p:has(> tinypage-track) { padding: var(--s2) var(--s4); background: var(--surface); border: 1px solid var(--edge); border-radius: var(--radius-m); }
  .text p:has(> tinypage-track) + p:has(> tinypage-track) { margin-top: var(--s3); }
  tinypage-track > span:has(> a[download]) { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s1) var(--s3); }
  tinypage-track a[download] {
    display: inline-flex; align-items: center; gap: 0.4em; min-height: 44px; padding-inline: var(--s4);
    border: 1.5px solid var(--action); border-radius: 999px; color: var(--action); font-weight: 600; text-decoration: none;
    transition: background var(--duration);
  }
  tinypage-track a[download]::before { content: '↓'; font-weight: 400; }
  tinypage-track a[download]:hover { background: var(--action-soft); color: var(--action-strong); }

  /* Prose: rose section titles with a short line, rounded pictures, a gallery from several pictures in one paragraph. */
  .text h2 { color: var(--action); }
  .text h2::after { content: ''; display: block; inline-size: 2.5rem; block-size: 3px; margin-top: var(--s2); border-radius: 99px; background: currentColor; }
  .text ul, .text ol { padding-inline-start: 1.4em; }
  .text li + li { margin-top: var(--s2); }
  .text li::marker { color: var(--action); }
  .text blockquote { border-inline-start: 3px solid var(--action); padding: var(--s2) var(--space-m); font-family: var(--font-heading); font-style: italic; font-size: var(--step-1); color: var(--text-heading); }
  .text p > img:only-child { border-radius: var(--radius-m); box-shadow: var(--shadow-2); margin-inline: auto; max-height: 85vh; width: auto; }
  .text p:has(> img + img) { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(15rem, 100%), 1fr)); gap: var(--space-m); }
  .text p:has(> img + img) > img { inline-size: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: center 25%; border-radius: var(--radius-s); }
  .text table { border-collapse: collapse; inline-size: 100%; }
  .text th, .text td { text-align: start; padding: var(--s2); border-bottom: 1px solid var(--border); }
  /* A button paragraph stands a little apart. */
  .text p:has(> strong:only-child > a:only-child) { padding-block: var(--s2); }

  /* Page head: the title, and a subtitle under it (a field, or the text's first line in italics, page.html). */
  .seite-kopf { text-align: center; display: grid; gap: var(--space-s); }
  .seite-kopf .unterzeile { font-family: var(--font-body); font-style: normal; font-size: var(--step-1); max-inline-size: 50ch; margin-inline: auto; }
  .seite-kopf .unterzeile em { font-style: inherit; }

  /* Home: the logo, then the portrait beside the welcome. */
  .willkommen {
    width: min(100% - 2 * var(--gutter), var(--max));
    margin-inline: auto;
    padding-block: var(--space-l) var(--space-xl);
    display: grid;
    gap: var(--space-l);
    justify-items: center;
  }
  .logo { inline-size: min(17.5rem, 80%); mix-blend-mode: multiply; }
  .gruss { display: grid; gap: var(--space-l); justify-items: center; text-align: center; inline-size: 100%; }
  .portrait { inline-size: min(100%, 300px); aspect-ratio: 1; object-fit: cover; object-position: center top; border-radius: var(--radius-xl); box-shadow: var(--shadow-3); }
  .gruss-text { display: grid; gap: var(--s2); justify-items: center; }
  .gruss-text .unterzeile { font-size: var(--step-0); }
  .gruss-text h1 { font-size: var(--step-5); line-height: 1.1; }
  .gruss-text .text { font-size: var(--step-1); color: var(--text-quiet); max-inline-size: 50ch; margin-top: var(--s2); }
  .gruss-text p:has(> .knopf) { margin-top: var(--space-m); }
  @media (width >= 48rem) {
    .willkommen { padding-block: var(--space-l) var(--space-2xl); }
    .logo { inline-size: 28rem; }
    .gruss { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); align-items: center; gap: var(--space-xl); text-align: start; }
    .portrait { justify-self: end; }
    .gruss-text { justify-items: start; justify-self: stretch; padding-inline-end: var(--space-l); }
  }

  .band { padding-block: var(--space-xl); display: grid; gap: var(--space-m); }
  .band-titel { font-size: var(--step-3); padding-bottom: var(--s4); border-bottom: 1px solid var(--border); }
  .band--flaeche { inline-size: 100%; padding-inline: max(var(--gutter), (100% - var(--wide)) / 2); background: var(--surface); }
  .band-weiter { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--space-s); }
  @media (width >= 48rem) {
    .band { padding-block: var(--space-2xl); }
  }

  /* Angebote as rows: picture and text, sides alternating on wide screens; the title's link covers the row. */
  .zeilen { display: grid; gap: 0; }
  .zeile { position: relative; display: grid; gap: var(--space-m); padding-block: var(--space-l); border-bottom: 1px solid var(--border); }
  .zeile:first-child { padding-top: 0; }
  .zeile-bild { inline-size: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius-m); box-shadow: var(--shadow-1); }
  .zeile-text { display: grid; gap: var(--s2); align-content: center; max-inline-size: 52ch; }
  .zeile-text h2, .zeile-text h3 { font-size: var(--step-3); }
  .zeile-text h2 a, .zeile-text h3 a { color: var(--text-heading); text-decoration: none; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
  .zeile-text h2 a::after, .zeile-text h3 a::after { content: ''; position: absolute; inset: 0; border-radius: var(--radius-m); }
  .zeile:hover h2 a, .zeile:hover h3 a { color: var(--action); text-decoration: underline; text-decoration-color: currentColor; }
  .zeile-text > p:not(.unterzeile, .mehr) { color: var(--text-quiet); line-height: 1.75; }
  .mehr { color: var(--action); font-weight: 500; font-size: var(--step--1); margin-top: var(--s1); }
  .mehr span { display: inline-block; transition: translate var(--duration); }
  .zeile:hover .mehr span { translate: 4px 0; }
  @media (width >= 44rem) {
    .zeile { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--space-xl); align-items: center; }
    .zeile:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
    .zeile:nth-child(even) .zeile-bild { order: 2; }
    .zeile-bild { aspect-ratio: 5 / 4; }
  }

  /* Termine: date and time in a column beside title and place; on the phone above them. */
  .termine { list-style: none; margin: 0; padding: 0; }
  .termin { display: grid; gap: var(--s1) var(--space-m); padding-block: var(--space-m); border-bottom: 1px solid var(--border); }
  .termin:first-child { padding-top: var(--s1); }
  .termin:last-child { border-bottom: 0; }
  .termin-wann { display: flex; flex-direction: column; font-size: var(--step--1); color: var(--text-quiet); font-variant-numeric: tabular-nums; }
  .termin-wann time { color: var(--action); font-weight: 650; font-size: var(--step-0); }
  .uhrzeit { white-space: nowrap; }
  .termin-was { display: grid; gap: var(--s1); }
  .termin-titel { font-size: var(--step-1); line-height: 1.3; }
  .termin-titel a { color: var(--text-heading); text-decoration: none; }
  .termin-titel a:hover { color: var(--action); text-decoration: underline; }
  .termin-ort, .termin-hinweis { font-size: var(--step--1); color: var(--text-quiet); }
  .termin-ort a { color: inherit; }
  .termin-ort a:hover { color: var(--action); }
  .termin-text { font-size: var(--step--1); color: var(--text); }
  .termin-text > * + * { margin-top: var(--s2); }
  .termin-links { margin-top: var(--s2); }
  .termin-entfaellt { font-size: var(--step--1); color: var(--text); }
  .termin-entfaellt strong { color: var(--action); text-transform: uppercase; letter-spacing: 0.05em; }
  .termin--entfaellt .termin-titel { text-decoration: line-through; text-decoration-thickness: 1px; text-decoration-color: var(--text-quiet); color: var(--text-quiet); }
  .termin--entfaellt time { color: var(--text-quiet); }
  @media (width >= 40rem) {
    .termin { grid-template-columns: 12rem 1fr; }
  }
  .termine--naechste > li:nth-child(n + 4 of :not([hidden])) { display: none; }
  /* /termine and /rueckblick: one band per month, every second one tinted. */
  .monat { display: grid; gap: var(--s2); padding: var(--space-l) var(--space-m); border-radius: var(--radius-m); }
  .monat:nth-child(even of .monat:not([hidden])) { background: var(--surface); }
  .monat h2 { font-size: var(--step-2); padding-bottom: var(--s2); border-bottom: 2px solid var(--border); }
  .seite--termine > * { width: min(100%, var(--wide)); }
  .termine-hier { display: grid; gap: var(--s3); padding: var(--space-l); border-radius: var(--radius-m); background: var(--surface); }
  .termine-hier > h2 { font-size: var(--step-2); }
  .termine-hier .termin:last-child { padding-bottom: 0; }
  .keine { color: var(--text-quiet); }
  /* The filter chips on /termine: they need script, so without it they do not show (all Termine do). */
  .filter { display: flex; flex-wrap: wrap; gap: var(--s2); margin-bottom: var(--space-m); }
  .filter button {
    min-height: 44px;
    padding: var(--s2) var(--space-s);
    border: 1px solid var(--border);
    border-radius: 999px;
    background: none;
    color: var(--text-quiet);
    font: inherit;
    font-size: var(--step--1);
    font-weight: 500;
    cursor: pointer;
    transition: border-color var(--duration), color var(--duration);
  }
  .filter button:hover, .filter [aria-pressed='true'] { border-color: var(--action); color: var(--action); }
  .filter [aria-pressed='true'] { font-weight: 650; }
  @media (scripting: none) {
    .filter { display: none; }
  }

  /* An Angebot: the lead under the title, the facts box, and in the text a checklist card, the price overview and the
     call to action (DESIGN.md › Text conventions). */
  .seite--angebot > .text:first-of-type > p:first-child {
    font-family: var(--font-heading); font-style: italic; font-size: var(--step-1); line-height: 1.75; color: var(--text-quiet);
    text-align: center; max-inline-size: 50ch; margin-inline: auto;
  }
  .fakten {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr));
    gap: var(--space-m);
    padding: var(--space-l);
    border: 1px solid var(--edge);
    border-radius: var(--radius-m);
    background: var(--surface);
    box-shadow: var(--shadow-1);
  }
  .fakten > div { display: grid; align-content: start; gap: var(--s1); }
  @media (width >= 40rem) {
    .fakten > div:not(:last-child) { border-inline-end: 1px solid var(--edge); padding-inline-end: var(--space-m); }
  }
  .fakten dt { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-quiet); font-weight: 500; }
  .fakten dd { margin: 0; font-weight: 500; }
  .fakten .preis { color: var(--action); font-size: var(--step-1); }
  .leise { color: var(--text-quiet); font-size: var(--step--1); font-weight: 400; }
  .seite--angebot .text ol { padding-inline-start: 1.6em; }
  .seite--angebot .text ol > li::marker { font-family: var(--font-heading); font-weight: 700; }
  /* A list straight under a heading is a checklist card, two columns when there is room; a schedule whose items
     start in bold (»**14:00 Uhr:** Ankommen«) stays a list. */
  .seite--angebot .text > h2 + ul:not(:has(> li > strong:first-child)) {
    display: grid;
    gap: var(--space-s) var(--space-l);
    list-style: none;
    padding: var(--space-l);
    border: 1px solid var(--edge);
    border-radius: var(--radius-m);
    background: var(--surface);
    & > li { position: relative; margin: 0; padding-inline-start: 1.6em; }
    & > li::before { content: '✓'; position: absolute; inset-inline-start: 0; color: var(--action); font-weight: 700; }
    @media (width >= 40rem) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  }
  /* A table is the price overview: what on the left, the price on the right, dots between; its head is for screen
     readers (Markdown tables need one). */
  .seite--angebot .text table {
    display: block;
    padding: var(--space-s);
    border: 1px solid var(--edge);
    border-radius: var(--radius-m);
    background: var(--surface-2);
    & thead { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); }
    & tbody { display: block; }
    & tr { display: flex; align-items: baseline; gap: var(--s2); padding: var(--s2) var(--space-s); border-bottom: 1px solid var(--edge); }
    & tr:last-child { border-bottom: 0; }
    & tr::after { content: ''; order: 1; flex: 1; min-inline-size: var(--space-m); border-bottom: 2px dotted var(--border); }
    & td { padding: 0; border: 0; }
    & td:last-child { order: 2; font-weight: 600; color: var(--action); white-space: nowrap; }
  }
  /* The call to action stands centred under a line. */
  .seite--angebot .text > p:has(> strong:only-child > a:only-child) {
    margin-block: var(--space-xl) 0; padding-top: var(--space-l); border-top: 1px solid var(--edge); text-align: center;
    & a { font-size: var(--step-1); padding: var(--space-m) var(--space-xl); }
  }

  /* /angebote: the intro as a lead, the rows as wide as the page, the places as cards. */
  .seite--angebote > .text:first-of-type { font-size: var(--step-1); line-height: 1.75; color: var(--text-quiet); }
  .seite--angebote .text ul:has(> li > strong:first-child) {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(14rem, 100%), 1fr));
    gap: var(--space-s);
    list-style: none;
    padding: 0;
    & > li { margin: 0; padding: var(--space-s) var(--space-m); border: 1px solid var(--border); border-radius: var(--radius-s); background: var(--surface); color: var(--text-quiet); font-size: var(--step--1); }
    & > li > strong:first-child { display: block; color: var(--action); font-size: var(--step-0); font-weight: 600; }
    & a { color: var(--text); font-size: var(--step-0); text-decoration-color: var(--action); }
  }

  /* Orte. */
  .orte { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(17.5rem, 100%), 1fr)); gap: var(--space-l); }
  .ort-karte { position: relative; display: grid; grid-template-rows: auto 1fr; border: 1px solid var(--border); border-radius: var(--radius-m); overflow: hidden; background: var(--surface-2); box-shadow: var(--shadow-1); transition: box-shadow var(--duration), translate var(--duration); }
  .ort-karte:hover { box-shadow: var(--shadow-2); translate: 0 -2px; }
  .ort-karte img { inline-size: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
  .ort-karte-text { display: grid; gap: var(--s2); align-content: start; padding: var(--space-l); }
  .ort-karte h2 { font-size: var(--step-2); }
  .ort-karte h2 a { color: var(--text-heading); text-decoration: none; }
  .ort-karte h2 a::after { content: ''; position: absolute; inset: 0; }
  .ort-karte:hover h2 a { color: var(--action); }
  .ort-karte p { font-size: var(--step--1); color: var(--text-quiet); }
  .ort-karte .adresse { color: var(--action); }
  .ort-adresse { font-size: var(--step--1); color: var(--text-quiet); }
  .ort-bild { inline-size: 100%; aspect-ratio: 21 / 9; object-fit: cover; border-radius: var(--radius-m); box-shadow: var(--shadow-2); }
  .schoen { border-inline-start: 3px solid var(--action); padding: var(--s2) var(--space-m); font-family: var(--font-heading); font-style: italic; font-size: var(--step-1); color: var(--action); }

  /* Über mich: the portrait beside the first section (on the phone above it), lists in a quiet card. */
  .seite--ueber .text > p:first-child:has(> img:only-child) {
    float: right;
    inline-size: min(280px, 40%);
    margin: 0 0 var(--space-l) var(--space-l);
    & > img { inline-size: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius-l); box-shadow: var(--shadow-3); max-height: none; }
    & + * { margin-top: 0; }
    @media (width < 40rem) { float: none; inline-size: min(320px, 100%); margin: 0 auto var(--space-xl); }
  }
  .seite--ueber .text ul {
    list-style: none;
    display: grid;
    gap: var(--space-s);
    padding: var(--space-m) var(--space-l);
    border-radius: var(--radius-m);
    background: var(--surface);
    & > li { position: relative; margin: 0; padding-inline-start: var(--space-m); }
    & > li::before { content: ''; position: absolute; inset-inline-start: 0; top: 0.6em; inline-size: 6px; block-size: 6px; border-radius: 99px; background: var(--action); }
  }

  /* Kontakt: e-mail and phone as cards (a list whose items start with a bold label), the form beside them. */
  @media (width >= 52rem) {
    .seite--kontakt { width: min(100% - 2 * var(--gutter), var(--wide)); grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); align-items: start; column-gap: var(--space-l); }
    .seite--kontakt > * { width: 100%; }
    .seite--kontakt > .seite-kopf { grid-column: 1 / -1; }
  }
  .seite--kontakt .text ul:has(> li > strong:first-child) {
    display: grid;
    gap: var(--space-s);
    list-style: none;
    padding: 0;
    & > li { display: grid; grid-template-columns: auto 1fr; align-items: center; column-gap: var(--space-s); margin: 0; padding: var(--s3) var(--space-s); border: 1px solid var(--edge); border-radius: var(--radius-m); background: var(--surface-2); }
    & > li::before { grid-row: span 2; color: var(--action); font-size: 1.5rem; line-height: 1; }
    & > li:has(a[href^='mailto:'])::before { content: '\2709\FE0E'; }
    & > li:has(a[href^='tel:'])::before { content: '\260E\FE0E'; }
    & > li > strong:first-child { font-size: var(--step--1); font-weight: 500; color: var(--text-quiet); }
    & a { color: var(--text); overflow-wrap: anywhere; }
    & a:hover { color: var(--action); }
  }

  /* Contact form (kontakt-form.html). */
  .kontakt-form { display: grid; gap: var(--space-s); padding: var(--space-l); border-radius: var(--radius-m); background: var(--surface); }
  .kontakt-form h2 { font-size: var(--step-2); }
  .kontakt-form form { display: grid; gap: var(--s4); }
  .kontakt-form .felder { display: grid; gap: var(--s4); grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr)); }
  .kontakt-form label { display: block; font-weight: 500; font-size: var(--step--1); margin-bottom: var(--s1); }
  .kontakt-form .optional { font-weight: 400; color: var(--text-quiet); }
  .kontakt-form input, .kontakt-form textarea {
    inline-size: 100%; font: inherit; font-size: max(16px, 1rem); color: var(--text); background: var(--surface-2);
    border: 1px solid var(--border-control); border-radius: var(--radius-s); padding: var(--s2) var(--s3); min-height: 44px;
  }
  .kontakt-form .hp { position: absolute; left: -9999px; }

  /* Dark: the logo is drawn on white; inverted with its hue kept, and the black ground dropped. */
  @media screen {
    :root:is([data-scheme='dark'], :has(input[name='scheme'][value='dark']:checked)) .logo { mix-blend-mode: screen; filter: invert(1) hue-rotate(180deg); }
  }
  @media (forced-colors: active) {
    .knopf, .text p > strong:only-child > a:only-child, tinypage-track a[download], .filter button { border: 2px solid ButtonText; }
    .fakten, .ort-karte, .termine-hier, .kontakt-form, .monat { border: 1px solid CanvasText; }
  }
}

@layer utilities {
  .unsichtbar { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
