

  h1, h2, h3, .wordmark { font-family: var(--font-heading); text-transform: var(--heading-transform); letter-spacing: var(--heading-spacing); }
  :root[data-skin="racing"] { font-size: calc(var(--pico-font-size) * var(--font-scale)); }
  :root[data-skin="racing"] { --pico-spacing: calc(1rem * var(--space)); --pico-typography-spacing-vertical: calc(1rem * var(--space)); --pico-block-spacing-vertical: calc(1rem * var(--space)); --pico-block-spacing-horizontal: calc(1rem * var(--space)); --pico-grid-row-gap: calc(1rem * var(--space)); }
  h1 { --pico-typography-spacing-top: calc(3rem * var(--space)); } h2 { --pico-typography-spacing-top: calc(2.625rem * var(--space)); } h3 { --pico-typography-spacing-top: calc(2.25rem * var(--space)); }
  h1, h2, h3, h4, h5, h6 { font-size: calc(var(--pico-font-size) * var(--heading-scale)); }
  a { color: var(--accent-ink); }
  .wordmark { font-weight: 700; font-size: 1.4rem; color: var(--pico-h1-color); text-decoration: none; }
  .wordmark b { color: var(--accent); }
  nav.top { border-bottom: 1px solid var(--pico-muted-border-color); position: sticky; top: 0; z-index: 10;
            background: color-mix(in srgb, var(--pico-background-color) 88%, transparent); backdrop-filter: blur(8px); }
  nav.top ul li a { font-weight: 600; }
  /* header menu uses the brand red of the "Bekijk tuning" button; the wordmark keeps its own colours */
  nav.top ul li a:not(.wordmark) { color: var(--accent); }
  button, [role=button] { box-shadow: none; transition: transform .15s, box-shadow .15s, background .15s; }
  button:hover:not(.secondary):not(.outline), a[role=button]:hover:not(.secondary):not(.outline) { transform: translateY(-1px); box-shadow: var(--glow); }

  /* hero */
  .hero { min-height: 72vh; display: grid; align-items: end; color: var(--hero-text);
          background: linear-gradient(180deg, var(--hero-shade-top) 0%, var(--hero-shade-bottom) 100%),
                      var(--hero-image) center/cover; }
  .hero .container { padding-block: calc(4rem * var(--space)); }
  .hero h1 { font-size: calc(clamp(1.6rem, 3.1vw, 2.5rem) * var(--heading-scale)); line-height: 1; margin-bottom: calc(.5rem * var(--space)); color: var(--hero-text); }
  .hero h1 em { font-style: normal; color: var(--pico-primary); }
  .hero p { max-width: 38rem; font-size: 1.15rem; color: var(--hero-text-soft); }
  /* the caps over the photo sit on a dark chip so they read on any image; section eyebrows keep the bare red.
     The chip follows the letters (box-decoration-break: clone) instead of spanning the whole hero, so more of
     the photo stays visible; the container balances the wrap, which turns a wrapped eyebrow into two even
     lines instead of one word left over on the last line. The headline and the intro keep normal wrapping. */
  .hero .container { text-wrap: balance; }
  .hero h1, .hero p { text-wrap: wrap; }
  .hero .eyebrow { display: inline; padding: .35rem .6rem; border-radius: var(--radius); background: var(--hero-chip-bg); color: var(--accent); box-decoration-break: clone; -webkit-box-decoration-break: clone; }
  .hero .cta { display: flex; gap: calc(.75rem * var(--space)); flex-wrap: wrap; margin-top: calc(1.5rem * var(--space)); }
  .hero .cta a { margin: 0; }
  .hero a.outline { color: var(--hero-text); border-color: var(--hero-text); }

  /* fitment finder */
  .finder { margin-top: calc(1.5rem * var(--space)); position: relative; z-index: 2; box-shadow: var(--finder-shadow); }
  .hero + .container .finder { margin-top: calc(-2.5rem * var(--space)); }
  .finder form { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: calc(.75rem * var(--space)); align-items: end; margin: 0; }
  .finder label { margin: 0; }
  .finder select, .finder input, .finder button { margin: 0; }

  /* sections */
  section.block { padding-block: calc(4rem * var(--space)); }
  .eyebrow { color: var(--accent-ink); font-weight: 700; letter-spacing: .15em; text-transform: uppercase; font-size: .8rem; }
  /* a view switch: two buttons that read as a choice, not as two calls to action. The chosen one is filled
     (a normal a[role=button]), the other keeps pico's outline, so the state is visible without a script.
     Used by the occasions and parts lists (all items / the sold ones). */
  .view-switch { display: flex; flex-wrap: wrap; gap: calc(.5rem * var(--space)); margin-block: calc(1.25rem * var(--space)) calc(1.75rem * var(--space)); }
  .view-switch a[role=button] { margin: 0; padding-inline: calc(1.15rem * var(--space)); }
  .grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: calc(1.25rem * var(--space)); }
  .grid-cards article { margin: 0; padding: 0; overflow: hidden; transition: transform .2s, border-color .2s; border: 1px solid var(--pico-muted-border-color); }
  .grid-cards article:hover { transform: translateY(-3px); border-color: var(--pico-primary); }
  /* hover: one pulse of light runs once around the red border, then stops */
  @property --lap { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
  .grid-cards article { position: relative; }
  .grid-cards article::after, .stages article:has(a.stretch)::after { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 2px; pointer-events: none; opacity: 0;
    background: conic-gradient(from var(--lap), transparent 0deg, transparent 250deg, var(--pico-primary) 320deg, var(--accent-ink) 358deg, transparent 360deg);
    -webkit-mask: linear-gradient(var(--mask-ink) 0 0) content-box, linear-gradient(var(--mask-ink) 0 0); -webkit-mask-composite: xor;
    mask: linear-gradient(var(--mask-ink) 0 0) content-box exclude, linear-gradient(var(--mask-ink) 0 0); }
  .grid-cards article:hover::after, .stages article:has(a.stretch):hover::after { animation: border-lap 1.1s cubic-bezier(.45,0,.35,1) 1 both; }
  @keyframes border-lap { 0% { --lap: 0deg; opacity: 0; } 8% { opacity: 1; } 90% { opacity: 1; } 100% { --lap: 360deg; opacity: 0; } }
  @media (prefers-reduced-motion: reduce) { .grid-cards article:hover::after, .stages article:has(a.stretch):hover::after { animation: none; } }
  .ph { aspect-ratio: 4/3; background: linear-gradient(135deg, var(--pico-card-sectioning-background-color), var(--pico-muted-border-color));
        display: grid; place-items: center; color: var(--pico-muted-color); font-size: .85rem; }
  .card-body { flex: 1; display: flex; flex-direction: column; align-items: flex-start; padding: calc(1rem * var(--space)) calc(1.1rem * var(--space)) calc(1.2rem * var(--space)); }
  .card-body h3 { font-size: calc(1.05rem * var(--heading-scale)); margin-bottom: calc(.25rem * var(--space)); }
  .card-body small { color: var(--pico-muted-color); }
  .price { font-size: 1.25rem; font-weight: 700; margin: auto 0 0; padding-top: calc(.75rem * var(--space)); }
  /* a sold occasion keeps its price in the list, but crossed out (doorhalen), so nobody takes it for
     something still for sale. The hover rule further down only recolours .price, so the strike stays. */
  .price.sold, .grid-cards article:hover .price.sold { color: var(--pico-muted-color); text-decoration: line-through; text-decoration-thickness: .08em; }
  /* the same cross-out on the part page, where "incl. btw" follows the amount: only the amount is struck,
     so the suffix stays readable. */
  .price .amount.sold { color: var(--pico-muted-color); text-decoration: line-through; text-decoration-thickness: .08em; }
  .badge { display: inline-block; margin-bottom: calc(.6rem * var(--space)); font-size: .7rem; font-weight: 700; padding: .15rem .5rem; border-radius: 999px;
           background: var(--pico-primary); color: var(--on-accent); text-transform: uppercase; letter-spacing: .06em; }
  .badge.ok { background: var(--success); color: var(--on-success); }
  .stages { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: calc(1.25rem * var(--space)); }
  .stages article { display: flex; flex-direction: column; margin: 0; border-top: 3px solid var(--pico-primary); }
  .stage-img { width: 100%; height: auto; border-radius: var(--pico-border-radius); margin: 0 0 calc(1rem * var(--space)); }
  .stages article { position: relative; }
  .stages a.stretch { color: inherit; text-decoration: none; }
  .stages a.stretch::after { content: ""; position: absolute; inset: 0; }
  .stages article:has(a.stretch) { transition: transform .2s, border-color .2s; }
  .stages article:has(a.stretch):hover { transform: translateY(-3px); border-color: var(--pico-primary); }
  .stages ul { padding-left: 1.1rem; }
  .stats { display: flex; gap: calc(2.5rem * var(--space)); flex-wrap: wrap; }
  .stats div strong { display: block; font-family: var(--font-heading); font-size: calc(2.4rem * var(--heading-scale)); color: var(--pico-primary); line-height: 1; }
  footer.site { border-top: 1px solid var(--pico-muted-border-color); padding-block: calc(2.5rem * var(--space)); color: var(--pico-muted-color); }
  .wordmark { display: inline-flex; align-items: center; gap: .5rem; }
  .logo { height: 2.2rem; width: auto; }
  @media (max-width: 768px) {
    nav.top { flex-wrap: wrap; }
    nav.top ul { flex-wrap: wrap; }
    section.block { padding-block: calc(2.5rem * var(--space)); }
  }
  @media (max-width: 640px) {
    .hero p { font-size: 1rem; }
  }
  .article img { max-width: 100%; height: auto; border-radius: var(--pico-border-radius); }
  .article { max-width: 760px; margin-inline: auto; }

/* language switch: a first-class nav item, not its own little thing.
   Typography is deliberately NOT set here. The anchors inherit the same font-size, font-weight and
   line-height as every other nav anchor (nav.top ul li a / the document), and use the same pico
   vertical padding + negative margin as `nav li :where(a,[role=link])`, so the switch shares the
   nav baseline and item height by construction. Only the horizontal rhythm is a touch tighter. */
nav.top ul li.lang { margin: 0; }
/* pico turns span[role=group] into an inline-flex group; undo that. `contents` drops the
   wrapper's own box entirely, so the two anchors sit in the <li>'s line box exactly like the
   single anchor in every other nav item - same line box, same item height, same baseline. */
nav.top ul li.lang > span { display: contents; }
nav .lang a {
  padding-block: var(--pico-nav-link-spacing-vertical);
  padding-inline: .3rem;
  margin-block: calc(var(--pico-nav-link-spacing-vertical) * -1);
  margin-inline: 0;
}
/* active language: an offset underline marks it without touching the box height or the glyphs */
nav .lang a[aria-current="true"] {
  color: var(--accent);
  text-decoration-line: underline;
  text-decoration-thickness: max(1px, .08em);
  text-underline-offset: .3em;
}

/* header: centre the nav items vertically */
nav.top ul { align-items: center; }
@media (max-width: 1100px) {
  .wordmark { font-size: 1.15rem; }
  nav.top ul li { padding: .5rem .4rem; }
}
.finder form { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; }
.finder button { white-space: nowrap; padding-inline: 1rem; }
.finder select { padding-inline: .75rem 2rem; background-position: right .6rem center; }
@media (max-width: 700px) { .finder form { grid-template-columns: 1fr; } }
.finder select { font-size: .95rem; padding-inline: .6rem 1.8rem; }

/* cards, galleries, cart forms (were inline styles) */
.card-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; }
.card-img, .card-link .ph { flex: none; width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: calc(.75rem * var(--space)); margin-bottom: calc(1.5rem * var(--space)); }
.gallery img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.ph-tall { min-height: 260px; margin-bottom: calc(1.5rem * var(--space)); }
.qty-form { display: flex; gap: .5rem; margin: 0; }
.qty-form input[type=number] { width: 5rem; margin: 0; }
.qty-form button { margin: 0; }
.hp { position: absolute; left: -9999px; }

/* header: never let the wordmark and the links overlap; the links wrap below the wordmark when space runs out */
nav.top { flex-wrap: wrap; column-gap: 1rem; }
nav.top ul { flex-wrap: wrap; }
nav.top > ul:first-child { flex-shrink: 0; }
.wordmark { white-space: nowrap; }

/* photo viewer: overlays the gallery links, which stay ordinary links without JS */
html.lightbox-open, html.lightbox-open body { overflow: hidden; }
.lightbox {
  position: fixed; inset: 0; z-index: 1000; display: none;
  align-items: center; justify-content: center;
  padding: max(.75rem, env(safe-area-inset-top)) .75rem max(.75rem, env(safe-area-inset-bottom));
  background: var(--lightbox-bg); color: var(--lightbox-ink);
}
.lightbox.is-open { display: flex; }
.lightbox-stage { flex: 1 1 auto; align-self: stretch; display: flex; flex-direction: column; align-items: center; gap: .5rem; width: 100%; max-width: 100%; min-height: 0; }
/* the frame keeps its size while a photo loads, so the picture never jumps or leaves a blank stage */
.lightbox-frame { position: relative; flex: 1 1 auto; width: 100%; min-height: 0; }
.lightbox-img {
  position: absolute; inset: 0; display: block; margin: auto; width: auto; height: auto;
  max-width: 100%; max-height: 100%; object-fit: contain;
  opacity: 0; transition: opacity var(--lightbox-fade) ease;
}
.lightbox-img.is-shown { opacity: 1; }
.lightbox-spinner {
  position: absolute; top: 50%; left: 50%; z-index: 1; width: 2.5rem; height: 2.5rem; margin: -1.25rem 0 0 -1.25rem;
  border: .25rem solid var(--lightbox-line); border-top-color: var(--pico-primary); border-radius: 50%;
  background: var(--lightbox-button); pointer-events: none;
  opacity: 0; visibility: hidden; transition: opacity .15s ease, visibility 0s linear .15s;
}
.lightbox.is-loading .lightbox-spinner { opacity: 1; visibility: visible; transition: opacity .15s ease, visibility 0s; }
.lightbox-caption { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin: 0; font-size: .9rem; line-height: 1.3; text-align: center; color: var(--lightbox-ink); }
.lightbox-alt[hidden] { display: none; }
.lightbox-count { font-variant-numeric: tabular-nums; }
/* The controls sit in one red-bordered pill at the foot of the viewer: prev | next | close.
   Each keeps a 44px square hit area; the icons are drawn rather than typed so they sit dead
   centre in the button instead of riding a font baseline. */
.lightbox-stage { padding-bottom: 4.75rem; }
.lightbox-bar {
  position: absolute; left: 50%; bottom: max(.75rem, env(safe-area-inset-bottom));
  translate: -50% 0; display: flex; align-items: center; gap: .35rem;
  padding: .3rem .4rem;
  border: 1px solid var(--pico-primary); border-radius: 999px;
  background: color-mix(in srgb, var(--lightbox-bg) 84%, transparent);
  box-shadow: 0 10px 30px color-mix(in srgb, var(--lightbox-bg) 70%, transparent);
  backdrop-filter: blur(8px);
}
.lightbox-bar button {
  position: relative; top: auto; right: auto; left: auto; translate: none;
  display: grid; place-items: center;
  width: 2.75rem; min-width: 2.75rem; height: 2.75rem; margin: 0; padding: 0;
  border: 0; border-radius: 50%; background: transparent;
  color: var(--pico-primary); font-size: 0; line-height: 0; cursor: pointer;
}
.lightbox-bar button svg {
  display: block; fill: none; stroke: currentColor;
  stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}
.lightbox-prev svg, .lightbox-next svg { width: 1.4rem; height: 1.4rem; }
.lightbox-close svg { width: 1.2rem; height: 1.2rem; }
/* a hairline sets close apart from the arrows; it goes away when there is only one photo */
.lightbox-bar-divider { flex: 0 0 1px; align-self: center; width: 1px; height: 1.5rem; background: var(--lightbox-line); }
.lightbox-bar-divider[hidden] { display: none; }
.lightbox-bar button:hover, .lightbox-bar button:focus-visible {
  background: color-mix(in srgb, var(--pico-primary) 18%, transparent); color: var(--accent-hover);
}
/* pico paints a blue halo on any focused button; on a red control inside the pill that reads as a
   stray blue ring, so the cue here is the brand-coloured outline (kept for keyboard users). */
.lightbox-bar button:focus { box-shadow: none; }
.lightbox-bar button:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 2px; }
.lightbox-bar button[hidden] { display: none; }
.lightbox.is-busy .lightbox-prev, .lightbox.is-busy .lightbox-next { opacity: .55; cursor: progress; }

@media (prefers-reduced-motion: no-preference) {
  .lightbox { animation: lightbox-fade .16s ease-out; }
  .lightbox button { transition: background-color .12s ease, border-color .12s ease; }
  .lightbox-spinner { animation: lightbox-spin .8s linear infinite; }
  @keyframes lightbox-fade { from { opacity: 0; } }
  @keyframes lightbox-spin { to { transform: rotate(1turn); } }
}
@media (prefers-reduced-motion: reduce) {
  .lightbox-img { transition: none; }
}

/* ---- polish: quiet motion. Each block below is independent; delete one to drop that effect. All of it is off for visitors who ask for reduced motion. ---- */
@media (prefers-reduced-motion: no-preference) {

  /* 1. cards, stages and stats rise and fade in as they scroll into view (browsers without scroll timelines just show them) */
  @supports (animation-timeline: view()) {
    @keyframes rise-in { from { opacity: 0; translate: 0 28px; } }
    .grid-cards article, .stages article, .stats div { animation: rise-in linear both; animation-timeline: view(); animation-range: entry 0% entry 35%; }
  }

  /* 2. product photos zoom slowly inside their card on hover */
  .card-img, .card-link .ph { transition: transform .7s cubic-bezier(.2,.6,.2,1); }
  .grid-cards article:hover .card-img, .grid-cards article:hover .ph { transform: scale(1.05); }

  /* 3. top menu links: a hairline appears under the hovered link and one pulse of light runs along it once */
  nav.top ul li:not(.lang) a:not(.wordmark):not([role=button]) { position: relative; text-decoration: none; }
  nav.top ul li:not(.lang) a:not(.wordmark):not([role=button])::after {
    content: ""; position: absolute; left: .6rem; right: .6rem; bottom: .3rem; height: 1px; pointer-events: none; opacity: 0; transition: opacity .3s;
    background: linear-gradient(90deg, transparent, var(--accent), transparent) -70% 0 / 40% 100% no-repeat, var(--pico-primary); }
  nav.top ul li:not(.lang) a:not(.wordmark):not([role=button]):hover::after { opacity: .85; animation: line-pulse .9s ease-out 1 both; }
  nav.top ul li:not(.lang) a:not(.wordmark):not([role=button]):is(:hover,:focus,:active,[aria-current="page"]) { text-decoration: none; }
  nav.top ul li a[aria-current="page"]::after { opacity: .5; }
  @keyframes line-pulse { to { background-position: 170% 0, 0 0; } }

  /* 4. the price warms up a shade when its card is hovered */
  .price { transition: color .3s; }
  .grid-cards article:hover .price { color: color-mix(in srgb, var(--pico-primary), var(--accent-ink) 22%); }

}
