/* Public passport page of the AkkuPass platform (DPP repo: src/AkkuPass.Resolver/wwwroot/css/tokens.css + src/AkkuPass.PublicPages/Styles/public.css), copied for the sample passport. Regenerate with the sample generator, see docs/sample-passport.md. */
/* Generated from web/packages/design-tokens/tokens.json – do not edit. Run: pnpm tokens:generate */
:root {
  --font-sans: "Open Sans Variable", "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", "Source Code Pro", Menlo, Consolas, monospace;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;
  --shadow-card: 0 1px 2px rgb(16 24 40 / 0.06), 0 4px 16px rgb(16 24 40 / 0.06);
  --shadow-overlay: 0 8px 32px rgb(16 24 40 / 0.14);
  --motion-fast: 150ms;
  --motion-base: 200ms;
  --motion-slow: 250ms;
  --motion-easing: cubic-bezier(0.2, 0, 0, 1);
  --color-bg: #ffffff;
  --color-surface: #f5f7f9;
  --color-surface-raised: #ffffff;
  --color-text: #0f172a;
  --color-text-muted: #5b6670;
  --color-border: #e2e8f0;
  --color-border-strong: #7d8995;
  --color-primary: #0470b9;
  --color-primary-hover: #035a95;
  --color-primary-contrast: #ffffff;
  --color-brand: #009cea;
  --color-secondary: #364146;
  --color-secondary-contrast: #ffffff;
  --color-focus: #0470b9;
  --color-success: #15803d;
  --color-warning: #b45309;
  --color-danger: #c62828;
  --color-info: #1d4ed8;
  --color-header-gradient: linear-gradient(120deg, #0470b9 0%, #009cea 100%);
  color-scheme: light;
}

/* Dark theme: explicit choice (.ap-dark on <html>) or the system preference unless light was chosen (.ap-light). */
:root.ap-dark {
  --color-bg: #0f172a;
  --color-surface: #1a2537;
  --color-surface-raised: #223049;
  --color-text: #e6edf3;
  --color-text-muted: #9aa8b8;
  --color-border: #2c3a50;
  --color-border-strong: #64748b;
  --color-primary: #5cbcf2;
  --color-primary-hover: #8ad0f7;
  --color-primary-contrast: #0f172a;
  --color-brand: #009cea;
  --color-secondary: #364146;
  --color-secondary-contrast: #ffffff;
  --color-focus: #5cbcf2;
  --color-success: #4ade80;
  --color-warning: #fbbf24;
  --color-danger: #f87171;
  --color-info: #93c5fd;
  --color-header-gradient: linear-gradient(120deg, #023a61 0%, #035a95 100%);
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not(.ap-light) {
    --color-bg: #0f172a;
    --color-surface: #1a2537;
    --color-surface-raised: #223049;
    --color-text: #e6edf3;
    --color-text-muted: #9aa8b8;
    --color-border: #2c3a50;
    --color-border-strong: #64748b;
    --color-primary: #5cbcf2;
    --color-primary-hover: #8ad0f7;
    --color-primary-contrast: #0f172a;
    --color-brand: #009cea;
    --color-secondary: #364146;
    --color-secondary-contrast: #ffffff;
    --color-focus: #5cbcf2;
    --color-success: #4ade80;
    --color-warning: #fbbf24;
    --color-danger: #f87171;
    --color-info: #93c5fd;
    --color-header-gradient: linear-gradient(120deg, #023a61 0%, #035a95 100%);
    color-scheme: dark;
  }
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --motion-fast: 0ms;
    --motion-base: 0ms;
    --motion-slow: 0ms;
  }
}

/* Public passport page (spec 6, ADR 0024): mobile first, no script, colours and spacing only from design tokens. The
   system font stack comes first, so that the page needs no font download (LCP < 1.5 s on 4G).

   The tenant's brand is one accent colour: it replaces --color-primary (the resolver serves /brand/{slug}/theme.css after
   this file). Everything else – the hero, tints, lines, charts, the life cycle – is derived from --color-primary, so a
   tenant can only choose a colour, never break the page. The accent has at least 4.5:1 contrast on white, and the hero is
   darker than the accent, so white text on both is always readable. */
:root {
  --ap-width: 72rem;
  --ap-hero: color-mix(in srgb, var(--color-primary) 76%, #000);
  --ap-tint: color-mix(in srgb, var(--color-primary) 9%, var(--color-surface-raised));
  --ap-line: color-mix(in srgb, var(--color-primary) 24%, var(--color-border));
}

:root.ap-dark {
  --ap-hero: color-mix(in srgb, var(--color-primary) 24%, #0b1220);
  --ap-tint: color-mix(in srgb, var(--color-primary) 16%, var(--color-surface-raised));
}

@media (prefers-color-scheme: dark) {
  :root:not(.ap-light) {
    --ap-hero: color-mix(in srgb, var(--color-primary) 24%, #0b1220);
    --ap-tint: color-mix(in srgb, var(--color-primary) 16%, var(--color-surface-raised));
  }
}

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

html {
  font-family:
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Open Sans',
    sans-serif;
  background: var(--color-surface);
  color: var(--color-text);
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  font-variant-numeric: tabular-nums;
}

[id] {
  scroll-margin-top: 4rem;
}

a {
  color: var(--color-primary);
  overflow-wrap: anywhere;
}

a:hover {
  color: var(--color-primary-hover);
}

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

h1 {
  font-size: clamp(1.75rem, 1.25rem + 2.2vw, 2.75rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  font-weight: 700;
  margin: 0 0 var(--space-4);
}

h2 {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: 1.125rem;
  line-height: 1.3;
  font-weight: 700;
  margin: 0 0 var(--space-4);
}

h2 .ap-icon {
  width: 2rem;
  height: 2rem;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
  background: var(--ap-tint);
  color: var(--color-primary);
}

p {
  margin: 0;
}

.ap-skip {
  position: absolute;
  left: var(--space-2);
  top: -100px;
  padding: var(--space-2) var(--space-4);
  background: var(--color-surface-raised);
  border-radius: var(--radius-sm);
  z-index: 10;
}

.ap-skip:focus {
  top: var(--space-2);
}

.ap-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* The header and the hero are one band of the tenant's colour; the logo sits on a white chip, so that any logo reads. */
.ap-header {
  background: var(--ap-hero);
  color: #fff;
  padding: var(--space-4) var(--space-4) 0;
}

.ap-issuer {
  max-width: var(--ap-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-weight: 600;
}

.ap-logo {
  display: inline-flex;
  flex: none;
  padding: 6px 10px;
  background: #fff;
  border-radius: var(--radius-sm);
}

.ap-logo img {
  display: block;
  height: 36px;
  width: auto;
  max-width: 11rem;
  object-fit: contain;
}

.ap-main {
  flex: 1;
  width: 100%;
  max-width: var(--ap-width);
  margin: 0 auto;
  padding: 0 var(--space-4) var(--space-12);
}

.ap-icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
}

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

.ap-mono {
  font-family: var(--font-mono);
  overflow-wrap: anywhere;
}

.ap-badge {
  display: inline-block;
  padding: 0 var(--space-3);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-pill);
  font-size: 0.875rem;
  font-weight: 600;
}

.ap-passport {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

/* The hero runs to the edges of the window: the box-shadow and the clip-path extend its colour sideways. */
.ap-passport-head {
  position: relative;
  padding: var(--space-6) 0 var(--space-16);
  background: var(--ap-hero);
  color: #fff;
  box-shadow: 0 0 0 100vmax var(--ap-hero);
  clip-path: inset(0 -100vmax);
}

.ap-section,
.ap-state {
  background: var(--color-surface-raised);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: var(--space-4);
}

.ap-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3) var(--space-6);
  margin: 0 0 var(--space-6);
}

.ap-meta > div {
  min-width: 0;
}

.ap-meta-id,
.ap-meta-wide {
  flex-basis: 100%;
}

.ap-meta dt,
.ap-details dt,
.ap-fact-label {
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

.ap-passport-head .ap-meta dt {
  color: #fff;
  opacity: 0.8;
}

.ap-meta dd,
.ap-details dd {
  margin: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.ap-meta-id dd {
  font-size: 1.1875rem;
  font-weight: 600;
}

.ap-passport-head .ap-badge {
  border-color: rgb(255 255 255 / 0.7);
  color: #fff;
}

.ap-signature {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  max-width: 48rem;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  border: 1px solid currentColor;
  border-inline-start-width: 5px;
  background: var(--color-surface-raised);
}

.ap-signature .ap-icon {
  width: 1.5rem;
  height: 1.5rem;
}

.ap-signature p {
  color: var(--color-text);
}

.ap-signature--valid {
  color: var(--color-success);
}

.ap-signature--invalid {
  color: var(--color-danger);
}

.ap-signature--unknown {
  color: var(--color-info);
}

.ap-notice {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  padding: var(--space-3);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-warning);
  background: var(--color-surface-raised);
}

/* Key facts: big values, overlapping the hero. */
.ap-facts-section {
  position: relative;
  margin-top: calc(-1 * var(--space-12));
}

.ap-facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-3);
}

.ap-fact {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-4);
  background: var(--color-surface-raised);
  border: 1px solid var(--color-border);
  border-top: 3px solid var(--color-primary);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
}

.ap-fact-icon {
  width: 2.25rem;
  height: 2.25rem;
  padding: 0.5rem;
  margin-bottom: var(--space-1);
  border-radius: 50%;
  background: var(--ap-tint);
  color: var(--color-primary);
}

.ap-fact-value {
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 700;
  overflow-wrap: break-word;
  hyphens: auto;
}

.ap-details {
  margin: 0;
  display: grid;
  gap: var(--space-3);
}

.ap-row {
  display: grid;
  gap: var(--space-1);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--color-border);
}

.ap-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.ap-details dd {
  font-weight: 500;
}

/* The body: the section menu and the content (the menu is a bar on a phone, a column from 60rem). */
.ap-body {
  display: block;
}

.ap-content,
.ap-flow {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  min-width: 0;
}

.ap-nav {
  position: sticky;
  top: 0;
  z-index: 5;
  margin: var(--space-4) calc(-1 * var(--space-4)) var(--space-4);
  padding: var(--space-2) var(--space-4);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}

.ap-nav ul {
  display: flex;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.5rem;
  padding: 0 var(--space-3);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-pill);
  background: var(--color-surface-raised);
  color: var(--color-text);
  font-size: 0.9375rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
}

.ap-nav a:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* Life cycle: the statuses of the product group in the order a passport goes through them; those of one stage are
   alternatives. The current one is filled. */
.ap-stages {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-stage {
  position: relative;
  padding-inline-start: var(--space-6);
  border-inline-start: 2px solid var(--ap-line);
}

.ap-stage::before {
  content: '';
  position: absolute;
  inset-block-start: 0.55rem;
  inset-inline-start: -0.4375rem;
  width: 0.75rem;
  height: 0.75rem;
  border: 2px solid var(--ap-line);
  border-radius: 50%;
  background: var(--color-surface-raised);
}

.ap-stage--past {
  border-color: var(--color-primary);
}

.ap-stage--past::before {
  border-color: var(--color-primary);
  background: var(--color-primary);
}

.ap-stage--current::before {
  border-color: var(--color-primary);
  background: var(--color-primary);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--color-primary) 25%, transparent);
}

.ap-steps {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-step {
  display: flex;
  flex-direction: column;
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-md);
  background: var(--color-surface-raised);
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

.ap-stage--past .ap-step {
  border-color: var(--ap-line);
}

.ap-step--current {
  border-color: var(--color-primary);
  background: var(--color-primary);
  color: var(--color-primary-contrast);
  font-weight: 700;
}

.ap-step-note {
  font-size: 0.8125rem;
  font-weight: 400;
  opacity: 0.9;
}

/* Charts: SVG drawn from the numbers; the numbers are always written out beside them. */
.ap-charts {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
}

.ap-chart h2 {
  font-size: 1rem;
  margin-bottom: var(--space-3);
}

.ap-chart-label {
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

.ap-range {
  display: block;
  width: 100%;
  height: auto;
  margin-bottom: var(--space-2);
}

.ap-range-track {
  stroke: var(--color-border);
  stroke-width: 2;
  stroke-linecap: round;
}

.ap-range-span {
  stroke: var(--color-primary);
  stroke-width: 3.5;
  stroke-linecap: round;
}

.ap-range-dot {
  fill: var(--color-surface-raised);
  stroke: var(--color-primary);
  stroke-width: 1.6;
}

.ap-range-dot--edge {
  fill: var(--color-primary);
}

.ap-range-values {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-range-values li {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.ap-range-values li:last-child:not(:first-child) {
  text-align: end;
}

.ap-range-values strong {
  font-size: 1.25rem;
  line-height: 1.2;
}

.ap-meters {
  display: grid;
  gap: var(--space-4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-meter-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-3);
  margin-bottom: var(--space-1);
}

.ap-meter-head strong {
  flex: none;
  font-size: 1.125rem;
}

.ap-meter-bar {
  display: block;
  width: 100%;
  height: 0.625rem;
  border-radius: var(--radius-pill);
  overflow: hidden;
}

.ap-meter-track {
  fill: var(--color-border);
}

.ap-meter-fill {
  fill: var(--color-primary);
  transform-box: fill-box;
  transform-origin: left center;
  animation: ap-fill 0.9s var(--motion-easing) both;
}

@keyframes ap-fill {
  from {
    transform: scaleX(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .ap-meter-fill {
    animation: none;
  }
}

/* Entries of one shape (a substance and its CAS number): the labels once, as a small table. */
.ap-entry-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.9375rem;
}

.ap-entry-table th {
  padding: 0 var(--space-3) var(--space-1) 0;
  border-bottom: 1px solid var(--color-border-strong);
  color: var(--color-text-muted);
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: start;
}

.ap-entry-table td {
  padding: var(--space-2) var(--space-3) var(--space-2) 0;
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
  overflow-wrap: anywhere;
}

.ap-entry-table tbody tr:last-child td {
  border-bottom: 0;
}

/* Other entries: a card each, the label above its value. */
.ap-entry-list {
  display: grid;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-entry {
  padding: var(--space-2) var(--space-3);
  border-inline-start: 3px solid var(--color-primary);
  border-radius: var(--radius-sm);
  background: var(--ap-tint);
}

.ap-entry dl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: var(--space-1) var(--space-4);
  margin: 0;
}

.ap-entry-part dd {
  margin: 0;
}

/* The preview of a draft in the editor: it must not be taken for the published page. */
.ap-preview-banner {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  margin: 0 0 var(--space-4);
  padding: var(--space-3);
  border: 2px dashed currentColor;
  border-radius: var(--radius-md);
  font-weight: 600;
}

.ap-versions {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: var(--space-2);
}

.ap-versions li {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: center;
}

.ap-authority-link {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  max-width: var(--ap-width);
  margin: 0 auto var(--space-3);
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

.ap-legal ul {
  margin: 0;
  padding-left: var(--space-6);
}

.ap-state {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-8);
}

.ap-state-icon {
  width: 3rem;
  height: 3rem;
  color: var(--color-primary);
}

.ap-footer {
  border-top: 1px solid var(--color-border);
  background: var(--color-surface-raised);
  padding: var(--space-6) var(--space-4);
}

.ap-issuer-name {
  flex: 1;
  min-width: 0;
}

/* The language menu: a native <details>, so it works without script. The company's own languages come first. */
.ap-lang {
  position: relative;
  flex: none;
  margin-inline-start: auto;
}

.ap-lang summary {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 2.5rem;
  padding: 0 var(--space-3);
  border: 1px solid rgb(255 255 255 / 0.65);
  border-radius: var(--radius-pill);
  color: #fff;
  font-size: 0.9375rem;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.ap-lang summary::-webkit-details-marker {
  display: none;
}

.ap-lang summary::after {
  content: '';
  width: 0.4rem;
  height: 0.4rem;
  margin-block-start: -0.2rem;
  border-inline-end: 2px solid currentColor;
  border-block-end: 2px solid currentColor;
  transform: rotate(45deg);
}

.ap-lang[open] summary {
  background: rgb(255 255 255 / 0.16);
}

.ap-lang-menu {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + var(--space-2));
  z-index: 20;
  width: min(34rem, calc(100vw - 2rem));
  max-height: 70vh;
  overflow-y: auto;
  padding: var(--space-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface-raised);
  color: var(--color-text);
  box-shadow: var(--shadow-overlay);
  font-weight: 400;
}

.ap-lang-menu ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ap-lang-menu ul + ul {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 1px solid var(--color-border);
}

.ap-lang-menu a {
  display: flex;
  align-items: center;
  min-height: 2.5rem;
  padding: 0 var(--space-3);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  text-decoration: none;
}

.ap-lang-menu a:hover {
  background: var(--ap-tint);
}

.ap-lang-menu a[aria-current] {
  background: var(--ap-tint);
  color: var(--color-primary);
  font-weight: 700;
}

.ap-powered {
  max-width: var(--ap-width);
  margin: 0 auto;
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

@media (min-width: 640px) {
  .ap-header {
    padding-inline: var(--space-6);
  }

  .ap-main {
    padding-inline: var(--space-6);
  }

  .ap-section,
  .ap-state {
    padding: var(--space-6);
  }

  .ap-nav {
    margin-inline: calc(-1 * var(--space-6));
    padding-inline: var(--space-6);
  }

  .ap-meta-id {
    flex-basis: auto;
  }

  .ap-meta-wide {
    flex-basis: auto;
    flex: 1 1 15rem;
  }

  .ap-facts {
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  }

  .ap-row {
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    gap: var(--space-4);
  }

  .ap-charts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  /* Life cycle as a rail from left to right. */
  .ap-stages {
    flex-direction: row;
    gap: 0;
  }

  .ap-stage {
    flex: 1 1 0;
    min-width: 0;
    padding: var(--space-6) var(--space-3) 0 0;
    border-inline-start: 0;
    border-block-start: 2px solid var(--ap-line);
  }

  .ap-stage::before {
    inset-block-start: -0.4375rem;
    inset-inline-start: 0;
  }

  .ap-steps {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (min-width: 960px) {
  .ap-body {
    display: grid;
    grid-template-columns: 14rem minmax(0, 1fr);
    gap: var(--space-8);
    align-items: start;
  }

  .ap-nav {
    top: var(--space-6);
    margin: 0;
    padding: 0;
    border-bottom: 0;
    background: none;
    overflow: visible;
  }

  .ap-nav ul {
    flex-direction: column;
    gap: 0;
    border-inline-start: 2px solid var(--color-border);
  }

  .ap-nav a {
    min-height: 0;
    padding: var(--space-2) var(--space-3);
    margin-inline-start: -2px;
    border: 0;
    border-inline-start: 2px solid transparent;
    border-radius: 0;
    background: none;
    white-space: normal;
    font-weight: 500;
  }

  .ap-nav a:hover {
    border-inline-start-color: var(--color-primary);
  }

  [id] {
    scroll-margin-top: var(--space-6);
  }
}

@media print {
  .ap-nav,
  .ap-lang {
    display: none;
  }

  .ap-header,
  .ap-passport-head {
    background: none;
    color: #000;
    box-shadow: none;
    clip-path: none;
  }

  .ap-passport-head {
    padding-bottom: var(--space-4);
  }

  .ap-passport-head .ap-meta dt {
    color: #000;
  }

  .ap-facts-section {
    margin-top: 0;
  }

  .ap-section,
  .ap-fact {
    box-shadow: none;
    break-inside: avoid;
  }
}
