/* VELOWINO — design A "Startnummer"
 * Logo: "VELOWINO" in Bazar, green #265720 (as on banners, jerseys and shirts). Bazar is used for
 * the logo only; everything else is Archivo (variable width: narrow for display type and numbers).
 */

:root {
  --white: #ffffff;
  --green: #265720;      /* logo green */
  --green-deep: #1a3d16;
  --green-light: #d3e3cf;
  --black: #000000;
  --asphalt: #e5e6e1;
  --grey: #5b605a;
  --line: #c9cbc4;
  --narrow: "wdth" 62;
  --wide: "wdth" 125;
  --gutter: clamp(16px, 4vw, 56px);
  --max: 1240px;
  --bazar: "Bazar", "Archivo", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
body {
  margin: 0; background: var(--white); color: var(--black);
  font-family: Archivo, system-ui, sans-serif; font-size: 17px; line-height: 1.55;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 20; padding: 10px 16px; background: var(--black); color: var(--white); }
.skip:focus { top: 8px; }

/* The logo: always Bazar */
.logo { font-family: var(--bazar); font-weight: normal; letter-spacing: .01em; line-height: 1; text-decoration: none; }

/* Numbers: Archivo narrow, heavy */
.num { font-variation-settings: var(--narrow); font-weight: 900; letter-spacing: -0.015em; }

.display { margin: 0; font-variation-settings: var(--narrow); font-weight: 850; font-size: clamp(40px, 5.6vw, 76px); line-height: .98; letter-spacing: -0.01em; }

/* --- Masthead --------------------------------------------------------------------------- */
.masthead { position: sticky; top: 0; z-index: 10; background: var(--white); border-bottom: 1px solid var(--line); }
.masthead .wrap { display: flex; align-items: center; gap: 32px; height: 72px; }
.masthead .logo { font-size: 40px; color: var(--green); }
.nav { display: flex; gap: 28px; margin-left: auto; font-weight: 600; font-size: 15px; }
.nav a { text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--green); }
.nav a[aria-current] { border-bottom-color: var(--green); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 22px;
  background: var(--green); color: var(--white); border: 2px solid var(--green); border-radius: 4px;
  font: inherit; font-weight: 700; font-size: 15px; text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--green-deep); border-color: var(--green-deep); }
.btn.ghost { background: transparent; color: var(--black); border-color: var(--black); }
.btn.ghost:hover { background: var(--black); color: var(--white); }
.btn.soon { background: transparent; color: var(--green); }
.btn.soon:hover { background: var(--green); color: var(--white); }
.menu-toggle { display: none; }

/* --- Race bib --------------------------------------------------------------------------- */
.bib { position: relative; background: var(--white); border-radius: 6px; box-shadow: 0 2px 0 rgba(0,0,0,.05), 0 24px 48px -16px rgba(0,0,0,.5); }
.bib::before, .bib::after, .bib .holes::before, .bib .holes::after {
  content: ""; position: absolute; width: 9px; height: 9px; border-radius: 50%;
  background: var(--asphalt); box-shadow: inset 0 1px 2px rgba(0,0,0,.35);
}
.bib::before { top: 12px; left: 12px; } .bib::after { top: 12px; right: 12px; }
.bib .holes::before { bottom: 12px; left: 12px; } .bib .holes::after { bottom: 12px; right: 12px; }
/* band like the VELOWINO banners: green, white logo */
.bib-band {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  margin: 30px 30px 0; padding: 8px 12px 6px; background: var(--green); color: var(--white);
}
.bib-band .logo { font-size: 26px; }
.bib-band .band-meta { font-variation-settings: var(--wide); font-weight: 700; font-size: 14px; white-space: nowrap; }
.bib-number { margin: 8px 26px 0; font-size: clamp(110px, 13.5vw, 196px); line-height: .9; color: var(--green); text-align: center; }
.bib-meta { margin: 6px 30px 0; padding-bottom: 38px; text-align: center; }
.bib-meta strong { display: block; font-size: clamp(20px, 2.2vw, 28px); line-height: 1.2; }
.bib-meta span { color: var(--grey); font-size: 15px; }

/* --- Home: hero ------------------------------------------------------------------------- */
.hero { position: relative; min-height: min(86vh, 820px); display: flex; align-items: center; background: #6c8a4d; overflow: hidden; }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 40%; }
.hero .caption { position: absolute; right: var(--gutter); bottom: 18px; margin: 0; color: var(--white); font-size: 13px; text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.hero .bib {
  width: clamp(290px, 36vw, 500px);
  margin-left: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter)));
  transform: rotate(-3deg);
  animation: pin 700ms cubic-bezier(.2,.9,.3,1.2) both 150ms;
}
@keyframes pin { from { opacity: 0; transform: translateY(-28px) rotate(-9deg); } to { opacity: 1; transform: rotate(-3deg); } }

/* --- Home: intro ------------------------------------------------------------------------ */
.intro { padding: clamp(56px, 8vw, 104px) 0; }
.intro .wrap { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(32px, 5vw, 80px); align-items: end; }
.intro p { margin: 0 0 22px; max-width: 34em; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.fine { margin-top: 18px; color: var(--grey); font-size: 15px; }
.fine p { margin: 0; }

/* --- Sections --------------------------------------------------------------------------- */
.section { padding: clamp(56px, 8vw, 104px) 0; }
.section.tinted { background: var(--asphalt); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px 48px; margin-bottom: 40px; }
.section-head h2 { margin: 0; font-variation-settings: var(--narrow); font-weight: 850; font-size: clamp(36px, 4.4vw, 56px); line-height: 1; }
.section-head p { margin: 0; max-width: 36em; color: var(--grey); }
.section-head a { font-weight: 700; }
.note { margin-top: 36px; color: var(--grey); font-size: 15px; }

/* --- Route bibs ------------------------------------------------------------------------- */
.route-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.route.bib { display: flex; flex-direction: column; text-decoration: none; }
.route.bib:nth-child(odd) { transform: rotate(-.6deg); }
.route.bib:nth-child(even) { transform: rotate(.5deg); }
.route .bib-band { margin: 28px 22px 0; }
.route .bib-band .logo { font-size: 20px; }
.route .bib-band .band-meta { font-size: 12.5px; }
.route .bib-number { font-size: clamp(88px, 8vw, 124px); margin: 8px 18px 0; color: var(--black); }
.route h3 { margin: 4px 22px 0; text-align: center; font-size: 21px; line-height: 1.2; }
.route .stats { margin: 4px 22px 14px; text-align: center; color: var(--grey); font-size: 15px; }
.route .profile { display: block; width: calc(100% - 44px); height: 64px; margin: auto 22px 0; overflow: visible; }
.profile-area { fill: var(--green); opacity: .16; }
.profile-line { fill: none; stroke: var(--green); stroke-width: 2; vector-effect: non-scaling-stroke; }
.route .foot { display: flex; justify-content: space-between; align-items: baseline; margin: 12px 22px 0; padding: 10px 0 36px; border-top: 1px solid var(--line); font-size: 15px; }
.route .foot b { font-size: 22px; }
.route:hover h3 { color: var(--green); }
.route[aria-current] { outline: 3px solid var(--green); outline-offset: 4px; }

/* --- Creed ------------------------------------------------------------------------------ */
.creed { background: var(--green); color: var(--white); padding: clamp(64px, 9vw, 120px) 0; }
.creed .wrap { display: grid; grid-template-columns: 7fr 5fr; gap: 28px 48px; }
.creed .display { grid-column: 1 / -1; font-size: clamp(44px, 8.4vw, 116px); line-height: .92; }
.creed .display span { display: block; }
.creed p { grid-column: 2; margin: 0; font-size: 19px; max-width: 30em; }

/* --- Video (loads from YouTube only after a click) --------------------------------------- */
.video { margin: 0; }
.video-frame { position: relative; aspect-ratio: 16 / 9; background: var(--black); border-radius: 3px; overflow: hidden; }
.video-frame img, .video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }
.video-play {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  width: 100%; padding: 24px; border: 0; background: rgba(0,0,0,.28); color: var(--white); font: inherit; cursor: pointer;
}
.video-play:hover { background: rgba(0,0,0,.4); }
.video-play .icon { display: grid; place-items: center; width: 88px; height: 88px; border-radius: 50%; background: var(--green); }
.video-play .icon::after { content: ""; margin-left: 6px; border-style: solid; border-width: 16px 0 16px 26px; border-color: transparent transparent transparent var(--white); }
.video-play strong { font-size: 19px; }
.video-play small { max-width: 30em; font-size: 14px; text-align: center; text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.video figcaption { margin-top: 10px; color: var(--grey); font-size: 14px; }

/* --- Photos ----------------------------------------------------------------------------- */
.mosaic { display: grid; gap: 10px; grid-template-columns: repeat(6, 1fr); grid-template-rows: 220px 220px; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; border-radius: 3px; }
.mosaic .m1 { grid-column: span 2; grid-row: span 2; }
.mosaic .m2, .mosaic .m3, .mosaic .m5 { grid-column: span 2; }
.mosaic .m4, .mosaic .m6 { grid-column: span 1; }
.years { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.years a { display: inline-block; padding: 6px 14px; border: 2px solid var(--black); border-radius: 4px; font-size: 22px; text-decoration: none; line-height: 1.2; }
.years a:hover { background: var(--black); color: var(--white); }

/* --- News list -------------------------------------------------------------------------- */
.news-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin: 0; padding: 0; list-style: none; }
.news-list li { border-top: 4px solid var(--black); padding-top: 16px; }
.news-list time { color: var(--green); font-weight: 700; font-size: 15px; }
.news-list h3 { margin: 4px 0 8px; font-size: 22px; line-height: 1.25; }
.news-list h3 a { text-decoration: none; }
.news-list h3 a:hover { color: var(--green); text-decoration: underline; }
.news-list p { margin: 0; color: var(--grey); }

/* --- Newsletter ------------------------------------------------------------------------- */
.newsletter { background: var(--black); color: var(--white); padding: 48px 0; }
.newsletter .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 48px; }
.newsletter h2 { margin: 0; font-variation-settings: var(--narrow); font-weight: 850; font-size: 40px; line-height: 1; }
.newsletter p { margin: 6px 0 0; color: #b9bcb6; }
.newsletter form { display: flex; flex-wrap: wrap; gap: 10px; flex: 1 1 360px; max-width: 520px; }
.newsletter input { flex: 1 1 220px; min-width: 0; min-height: 48px; padding: 0 16px; border: 2px solid var(--white); border-radius: 4px; background: transparent; color: var(--white); font: inherit; }
.newsletter input::placeholder { color: #9a9d97; }
.newsletter .btn { background: var(--white); color: var(--black); border-color: var(--white); min-height: 48px; }
.newsletter .btn:hover { background: var(--green); border-color: var(--green); color: var(--white); }
.newsletter .hint { flex-basis: 100%; margin: 0; font-size: 13px; color: #9a9d97; }

/* --- Sponsors --------------------------------------------------------------------------- */
.logo-grid { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.logo-grid > * { display: flex; align-items: center; justify-content: center; height: 132px; padding: 22px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.logo-grid img { max-height: 72px; width: auto; object-fit: contain; mix-blend-mode: multiply; }
.logo-grid span { font-weight: 700; text-align: center; line-height: 1.25; }

/* Organiser and sponsors: section on the home page (below the intro), strip above the footer elsewhere */
.partners { padding-top: 0; }
.partners .wrap { display: grid; grid-template-columns: minmax(240px, 1fr) 3fr; gap: 32px clamp(24px, 3vw, 40px); }
.partners-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; margin-bottom: 12px; }
.partners-head h2 { margin: 0; font-size: 15px; font-weight: 700; }
.partners-head p { margin: 0; color: var(--grey); font-size: 15px; }
.partners-host { display: flex; flex-direction: column; }
.logo-grid.host { flex: 1; grid-template-columns: 1fr; }
.logo-grid.host > * { height: 100%; min-height: 160px; padding: 28px; }
.logo-grid.host img { max-height: 132px; }
.logo-grid.host span { font-variation-settings: var(--narrow); font-weight: 850; font-size: 28px; }
.partner-strip { padding: 28px 0 36px; border-top: 1px solid var(--line); }
.partner-strip .wrap { display: flex; flex-wrap: wrap; gap: 20px 56px; }
.strip-group:not(.host) { flex: 1 1 520px; }
.strip-group h2 { margin: 0 0 10px; color: var(--grey); font-size: 14px; font-weight: 600; }
.strip-logos { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 30px; }
.strip-logos a, .strip-logos div { display: block; text-decoration: none; }
.strip-logos img { max-height: 40px; max-width: 128px; width: auto; object-fit: contain; mix-blend-mode: multiply; }
.strip-group.host img { max-height: 52px; max-width: 168px; }
.strip-logos span { font-weight: 700; font-size: 15px; }

/* --- Inner pages: header ---------------------------------------------------------------- */
.page-head { padding: clamp(40px, 6vw, 80px) 0 clamp(32px, 4vw, 48px); border-bottom: 1px solid var(--line); }
.page-head .kicker { margin: 0 0 12px; font-weight: 700; font-size: 15px; }
.page-head .kicker a { color: var(--green); text-decoration: none; }
.page-head .kicker a:hover { text-decoration: underline; }
.page-head .display { max-width: 16em; }
.lead { margin: 22px 0 0; max-width: 38em; font-size: clamp(19px, 1.6vw, 22px); line-height: 1.45; }
.lead p { margin: 0 0 .6em; }
.lead p:last-child { margin-bottom: 0; }

/* --- Prose (text blocks) ---------------------------------------------------------------- */
.page-body { padding: clamp(40px, 6vw, 72px) 0 clamp(56px, 8vw, 104px); }
.prose { max-width: 44em; }
.prose > :first-child { margin-top: 0; }
.prose p, .prose ul, .prose ol { margin: 0 0 1em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .35em; }
.prose h2 { margin: 1.8em 0 .5em; font-variation-settings: var(--narrow); font-weight: 850; font-size: clamp(30px, 3vw, 40px); line-height: 1.05; }
.prose h3 { margin: 1.6em 0 .4em; font-size: 21px; line-height: 1.25; }
.prose a { color: var(--green); font-weight: 600; }
.prose a:hover { color: var(--green-deep); }
.prose figure { margin: 1.6em 0; }
.prose figure img { border-radius: 3px; }
.prose figcaption { margin-top: 8px; color: var(--grey); font-size: 14px; }
.prose blockquote { margin: 1.6em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--green); font-size: 20px; }
.prose blockquote p { margin: 0; }
.prose blockquote footer { margin-top: 8px; color: var(--grey); font-size: 15px; }
.prose hr { margin: 2.4em 0; border: 0; border-top: 1px solid var(--line); }
.prose .gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin: 1.6em 0; padding: 0; list-style: none; }
.prose .gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 3px; }
.page-body .back { margin-top: 48px; font-weight: 700; }
.page-body .back a { color: var(--green); }

/* --- Editors' guide (/anleitung) ------------------------------------------------------- */
.guide .wrap { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px clamp(32px, 5vw, 72px); align-items: start; }
.guide-toc { position: sticky; top: 96px; font-size: 15px; }
.guide-toc h2 { margin: 0 0 10px; font-size: 15px; font-weight: 700; }
.guide-toc ul { margin: 0; padding: 0; list-style: none; }
.guide-toc li { margin-bottom: 6px; }
.guide-toc a { text-decoration: none; }
.guide-toc a:hover { color: var(--green); text-decoration: underline; }
.guide .prose { max-width: 880px; }
.guide section { scroll-margin-top: 96px; }
.guide section + section { margin-top: 3.2em; padding-top: 2.4em; border-top: 1px solid var(--line); }
.guide section > h2:first-child { margin-top: 0; }
.guide .steps { padding-left: 1.6em; }
.guide .steps li { padding-left: .2em; }
.guide .shot { margin: 1.2em 0 1.8em; }
.guide .shot img { width: auto; max-width: 100%; border: 1px solid var(--line); border-radius: 6px; box-shadow: 0 10px 28px -18px rgba(0,0,0,.45); }
.guide .mk { display: inline-block; min-width: 1.45em; height: 1.45em; padding: 0 .3em; border-radius: .75em; background: #d62d20; color: var(--white); font-weight: 700; font-size: .82em; line-height: 1.45em; text-align: center; vertical-align: .08em; }
@media print {
  .masthead, .partner-strip, .footer, .guide-toc, .skip { display: none !important; }
  .guide .wrap { display: block; }
  .guide .shot { break-inside: avoid; }
  .guide .shot img { box-shadow: none; }
  .guide section + section { break-before: page; border-top: 0; margin-top: 0; }
}

/* --- Routes overview -------------------------------------------------------------------- */
.route-map { position: relative; margin: 0 0 clamp(40px, 6vw, 72px); }
.route-map svg { display: block; width: 100%; height: auto; }
.map-bg { fill: var(--asphalt); }
.map-route { fill: none; stroke: #9a9d97; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.map-route.is-current { stroke: var(--green); stroke-width: 4.5; }
.map-route.r40 { stroke: #7fa772; } .map-route.r55 { stroke: #4b8a40; } .map-route.r80 { stroke: var(--green); } .map-route.r120 { stroke: var(--black); }
.map-start { fill: var(--white); stroke: var(--black); stroke-width: 3; vector-effect: non-scaling-stroke; }
.map-place circle { fill: var(--black); }
.map-place text { font: 600 15px/1 Archivo, sans-serif; fill: var(--black); paint-order: stroke; stroke: var(--asphalt); stroke-width: 5px; stroke-linejoin: round; }
.map-place.top text { font-weight: 800; }
.map-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 14px 0 0; padding: 0; list-style: none; font-size: 15px; }
.map-legend li { display: flex; align-items: center; gap: 8px; }
.map-legend i { display: inline-block; width: 26px; height: 4px; border-radius: 2px; }
.map-legend .r40 i { background: #7fa772; } .map-legend .r55 i { background: #4b8a40; } .map-legend .r80 i { background: var(--green); } .map-legend .r120 i { background: var(--black); }
.map-legend a { text-decoration: none; font-weight: 700; }
.map-legend a:hover { text-decoration: underline; }
.map-note { margin: 8px 0 0; color: var(--grey); font-size: 13px; }

/* --- Route page ------------------------------------------------------------------------- */
.route-head { padding: clamp(40px, 6vw, 72px) 0; background: var(--asphalt); }
.route-head .wrap { display: grid; grid-template-columns: minmax(280px, 420px) 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.route-head .bib { transform: rotate(-2deg); }
.route-head .bib-number { color: var(--black); }
.route-head .kicker { margin: 0 0 10px; font-weight: 700; font-size: 15px; }
.route-head .kicker a { color: var(--green); text-decoration: none; }
.route-head .lead { margin-top: 0; }
.facts { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 8px 40px; margin: 28px 0; }
.facts div { display: flex; flex-direction: column-reverse; }
.facts dt { color: var(--grey); font-size: 14px; }
.facts dd { margin: 0; font-size: clamp(30px, 3.2vw, 44px); line-height: 1; }
.route-section { padding: clamp(48px, 7vw, 88px) 0 0; }
.route-section h2 { margin: 0 0 20px; font-variation-settings: var(--narrow); font-weight: 850; font-size: clamp(30px, 3.4vw, 44px); line-height: 1; }
.elevation { margin: 0; }
.elevation svg { display: block; width: 100%; height: clamp(160px, 22vw, 260px); overflow: visible; }
.elevation .grid line { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.elevation .stage-mark { stroke: var(--black); stroke-width: 1; stroke-dasharray: 3 3; vector-effect: non-scaling-stroke; }
.elevation-axis { position: relative; height: 22px; margin-top: 6px; color: var(--grey); font-size: 13px; }
.elevation-axis span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.elevation-axis span:first-child { transform: none; }
.elevation figcaption { margin-top: 8px; color: var(--grey); font-size: 14px; }
.stages { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; counter-reset: stage; }
.stages li { padding-top: 14px; border-top: 4px solid var(--black); counter-increment: stage; }
.stages h3 { margin: 0 0 6px; font-size: 19px; }
.stages h3::before { content: counter(stage) ". "; }
.stages h3 span { color: var(--grey); font-weight: 600; }
.stages p { margin: 0; }
.legend { margin-top: 18px; color: var(--grey); font-size: 14px; }
.downloads { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.route-more { padding-bottom: clamp(56px, 8vw, 104px); }
.other-routes .route-grid { grid-template-columns: repeat(3, 1fr); }

/* --- Albums ----------------------------------------------------------------------------- */
.album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 28px 20px; margin: 0; padding: 0; list-style: none; }
.album-card { display: block; text-decoration: none; }
.album-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 3px; }
.album-card .year { display: block; margin-top: 10px; font-size: 44px; line-height: 1; }
.album-card small { color: var(--grey); font-size: 15px; }
.album-card:hover .year { color: var(--green); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.photo-grid figure { margin: 0; }
.photo-grid a { display: block; }
.photo-grid img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 3px; }
.photo-grid figcaption { padding: 6px 2px 4px; color: var(--grey); font-size: 14px; }

/* Lightbox */
.lightbox { width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(0,0,0,.94); color: var(--white); }
.lightbox::backdrop { background: rgba(0,0,0,.94); }
.lightbox figure { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; margin: 0; padding: 56px 72px; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 150px); object-fit: contain; }
.lightbox figcaption { margin-top: 12px; color: #c9cbc4; font-size: 15px; text-align: center; }
.lightbox button { position: absolute; display: grid; place-items: center; width: 52px; height: 52px; border: 0; border-radius: 50%; background: rgba(255,255,255,.12); color: var(--white); font: 700 26px/1 Archivo, sans-serif; cursor: pointer; }
.lightbox button:hover { background: var(--green); }
.lightbox .close { top: 16px; right: 16px; }
.lightbox .prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox .next { right: 12px; top: 50%; transform: translateY(-50%); }
.lightbox .count { position: absolute; top: 28px; left: 24px; margin: 0; color: #c9cbc4; font-size: 14px; }

/* --- News page -------------------------------------------------------------------------- */
.news-archive { margin: 0; padding: 0; list-style: none; max-width: 52em; }
.news-archive li { display: grid; grid-template-columns: 9em 1fr; gap: 4px 32px; padding: 22px 0; border-top: 1px solid var(--line); }
.news-archive time { color: var(--green); font-weight: 700; font-size: 15px; padding-top: 4px; }
.news-archive h2 { margin: 0 0 6px; font-size: 22px; line-height: 1.25; }
.news-archive h2 a { text-decoration: none; }
.news-archive h2 a:hover { color: var(--green); text-decoration: underline; }
.news-archive p { margin: 0; color: var(--grey); }
.pagination { display: flex; gap: 12px; margin-top: 32px; }
.article-cover { margin: 0 0 32px; max-width: 44em; }
.article-cover img { border-radius: 3px; }

/* --- Contact ---------------------------------------------------------------------------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.contact-aside h2 { margin: 0 0 4px; font-size: 19px; }
.contact-mail { display: inline-block; margin: 0 0 20px; font-variation-settings: var(--narrow); font-weight: 850; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.1; color: var(--green); text-decoration: none; word-break: break-word; }
.contact-mail:hover { text-decoration: underline; }
.form { max-width: 40em; }
.field { margin-bottom: 22px; }
.field label { display: block; margin-bottom: 6px; font-weight: 700; }
.field input, .field textarea {
  display: block; width: 100%; padding: 12px 14px; border: 2px solid var(--black); border-radius: 4px;
  background: var(--white); color: var(--black); font: inherit;
}
.field textarea { resize: vertical; min-height: 180px; }
.field input:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--green); outline-offset: 1px; }
.field [aria-invalid="true"] { border-color: #b3261e; }
.field-error { margin: 6px 0 0; color: #b3261e; font-weight: 600; font-size: 15px; }
.notice { margin-bottom: 28px; padding: 18px 20px; border-radius: 4px; }
.notice p { margin: 0 0 6px; }
.notice ul { margin: 0; padding-left: 1.2em; }
.notice.success { background: var(--green); color: var(--white); font-size: 19px; }
.notice.success p { margin: 0; }
.notice.error { border: 2px solid #b3261e; color: #7a1a14; }
.notice.error a { color: inherit; }

/* --- Footer: logo on green, like the banners at the roadside ---------------------------- */
.footer { background: var(--green); color: var(--white); }
.banner { padding: clamp(40px, 5vw, 64px) 0 0; }
.banner .logo { display: block; font-size: clamp(56px, 8vw, 104px); line-height: 1; color: var(--white); }
.footer .cols { position: relative; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; padding-top: 36px; padding-bottom: 48px; margin-top: clamp(24px, 3vw, 36px); }
.footer .cols::before { content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); border-top: 1px solid rgba(255,255,255,.25); }
.footer p { margin: 0; color: var(--green-light); max-width: 30em; }
.footer h2 { margin: 0 0 10px; font-size: 15px; color: var(--green-light); font-weight: 600; }
.footer ul { margin: 0; padding: 0; list-style: none; line-height: 2; }
.footer a { text-decoration: none; }
.footer a:hover { text-decoration: underline; }
.credit { margin-top: 14px !important; font-size: 13px; }

/* --- Responsive ------------------------------------------------------------------------- */
@media (max-width: 1080px) {
  .route-grid { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .other-routes .route-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
  .logo-grid { grid-template-columns: repeat(3, 1fr); }
  .facts { grid-template-columns: repeat(2, auto); }
}
@media (max-width: 860px) {
  .guide .wrap { grid-template-columns: 1fr; }
  .guide-toc { position: static; }
  .partners .wrap { grid-template-columns: 1fr; }
  .logo-grid.host > * { min-height: 140px; }
  .masthead .nav {
    display: none; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; gap: 0;
    margin: 0; padding: 8px var(--gutter) 20px; background: var(--white); border-bottom: 1px solid var(--line);
    box-shadow: 0 16px 24px -16px rgba(0,0,0,.25); font-size: 19px;
  }
  .masthead .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .masthead .nav a[aria-current] { color: var(--green); border-bottom-color: var(--line); }
  .masthead.is-open .nav { display: flex; }
  .masthead .btn { margin-left: auto; }
  .menu-toggle { display: inline-flex; align-items: center; min-height: 44px; background: none; border: 0; font: inherit; font-weight: 700; padding: 8px; cursor: pointer; }
  .intro .wrap, .creed .wrap, .route-head .wrap { grid-template-columns: 1fr; }
  .route-head .bib { max-width: 420px; }
  .creed p { grid-column: 1; }
  .news-list { grid-template-columns: 1fr; gap: 28px; }
  .mosaic { grid-template-columns: repeat(2, 1fr); grid-template-rows: none; grid-auto-rows: 180px; grid-auto-flow: dense; }
  .mosaic .m1 { grid-column: span 2; grid-row: span 2; }
  .mosaic .m2, .mosaic .m3, .mosaic .m5 { grid-column: span 2; }
  .footer .cols { grid-template-columns: 1fr 1fr; }
  .footer .cols > :first-child { grid-column: 1 / -1; }
  .news-archive li { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .other-routes .route-grid { grid-template-columns: 1fr 1fr; }
  .lightbox figure { padding: 56px 12px 80px; }
  .lightbox .prev, .lightbox .next { top: auto; bottom: 16px; transform: none; }
}
@media (max-width: 560px) {
  .route-grid, .other-routes .route-grid { grid-template-columns: 1fr; }
  .route.bib:nth-child(n) { transform: none; }
  .hero { min-height: 640px; align-items: flex-end; padding-bottom: 64px; }
  .hero .bib { margin: 0 auto; }
  .logo-grid { grid-template-columns: repeat(3, 1fr); }
  .logo-grid > * { height: 84px; padding: 12px; }
  .logo-grid img { max-height: 52px; }
  .logo-grid.host > * { min-height: 112px; }
  .logo-grid.host span { font-size: 24px; }
  .masthead .btn { display: none; }
  .masthead .menu-toggle { margin-left: auto; }
  .masthead .logo { font-size: 34px; }
  .facts { gap: 16px 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero .bib { animation: none; }
}

/* Elevation chart labels (route page) */
.elevation-chart { position: relative; }
.ele-label { position: absolute; left: 0; transform: translateY(-50%); padding: 0 6px 0 0; background: var(--white); color: var(--grey); font-size: 12px; line-height: 1; }
