/* Amergin Commerce – main stylesheet
   Structure: fonts → tokens → base → layout → header → sections (in page order) → forms → footer → subpages → motion.
   Outer spacing lives only on .section; components never set their own outer margins.
   Tokens read WordPress theme.json presets first (--wp--preset--*) and fall back to the values here,
   so the same file works in the static build and in the block theme. */

/* ---------- Fonts (self-hosted, variable: wght 100–900, wdth 62–125) ---------- */
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-latin-wdth.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-latin-ext-wdth.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens ---------- */
:root {
  --copper: var(--wp--preset--color--copper, #894b1f);             /* brand, measured from the delivered logo files */
  --copper-deep: var(--wp--preset--color--copper-deep, #6c3a17);
  --copper-light: var(--wp--preset--color--copper-light, #e1b48e); /* copper for use on petrol surfaces */
  --petrol: var(--wp--preset--color--petrol, #102a33);             /* harbour ink: text and dark surfaces */
  --petrol-deep: var(--wp--preset--color--petrol-deep, #0b1f26);
  --mist: var(--wp--preset--color--mist, #edf1f0);
  --white: var(--wp--preset--color--white, #ffffff);
  --stone: var(--wp--preset--color--stone, #56656b);               /* secondary text, 6:1 on white */
  --line: var(--wp--preset--color--line, #d2dada);
  --error: #a4281d;
  --line-dark: rgba(255, 255, 255, 0.16);

  --font: var(--wp--preset--font-family--archivo, "Archivo", "Helvetica Neue", Arial, sans-serif);
  --wide: 122%;
  --semi-wide: 112%;

  --step-hero: var(--wp--preset--font-size--display, clamp(2.6rem, 1.4rem + 5vw, 5.75rem));
  --step-h2: var(--wp--preset--font-size--heading, clamp(1.75rem, 1.2rem + 2.6vw, 3.6rem));
  --step-h3: var(--wp--preset--font-size--subheading, clamp(1.35rem, 1.2rem + 0.5vw, 1.6rem));
  --step-lead: var(--wp--preset--font-size--lead, clamp(1.125rem, 1.05rem + 0.3vw, 1.3rem));
  --step-body: var(--wp--preset--font-size--body, 1.125rem);
  --step-small: var(--wp--preset--font-size--small, 0.9375rem);

  --container: 1320px;
  --gutter: clamp(20px, 4vw, 48px);
  --section-y: var(--wp--preset--spacing--section, clamp(80px, 9vw, 144px));
  --header-h: 76px;
  --radius: 3px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--step-body);
  line-height: 1.6;
  color: var(--petrol);
  background: var(--white);
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
h1, h2, h3, h4 { overflow-wrap: break-word; hyphens: manual; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
address { font-style: normal; }
.nowrap { white-space: nowrap; }

:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; border-radius: 2px; }
.partner :focus-visible, .site-footer :focus-visible { outline-color: var(--copper-light); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--gutter); top: -100px; z-index: 100;
  padding: 12px 18px; background: var(--petrol); color: var(--white); text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); }

/* minmax(0, 1fr) everywhere: a plain 1fr track grows to the longest German compound word and overflows small phones */
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; margin-bottom: clamp(40px, 5vw, 72px); max-width: 44rem; }
.section-head--split { max-width: none; }
.section-head__side { display: grid; gap: 20px; justify-items: start; }
.section-head__title {
  font-size: var(--step-h2);
  font-stretch: var(--wide);
  font-weight: 620;
  line-height: 1.04;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.section-head__text { font-size: var(--step-lead); line-height: 1.55; color: var(--stone); max-width: 38rem; }

@media (min-width: 900px) {
  .section-head--split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: 48px; }
}

/* ---------- Buttons and links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 24px;
  font: inherit; font-size: 1rem; font-weight: 560; font-stretch: 104%;
  line-height: 1.2; text-align: center; text-decoration: none;
  border: 1px solid transparent; border-radius: var(--radius); cursor: pointer;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}
.btn--small { min-height: 44px; padding: 0 18px; font-size: 0.9375rem; }
.btn--primary { background: var(--copper); color: var(--white); }
.btn--primary:hover { background: var(--copper-deep); }
.btn--outline { border-color: var(--petrol); color: var(--petrol); background: transparent; }
.btn--outline:hover { background: var(--petrol); color: var(--white); }
.btn--light { background: var(--copper-light); color: var(--petrol); }
.btn--light:hover { background: var(--white); }
.btn--outline-light { border-color: rgba(255, 255, 255, 0.55); color: var(--white); }
.btn--outline-light:hover { background: var(--white); color: var(--petrol); }

.text-link {
  display: inline-block; color: var(--copper); font-weight: 560;
  text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px;
  transition: text-decoration-thickness 0.15s;
}
.text-link:hover { text-decoration-thickness: 2px; }
.link-row { display: flex; flex-wrap: wrap; gap: 12px 28px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 50;
  height: var(--header-h);
  border-bottom: 1px solid transparent;
  transition: transform 0.35s var(--ease-out), border-color 0.25s;
}
/* The translucent background sits on a pseudo-element: backdrop-filter on the header itself
   would make it the containing block of the fixed mobile menu and clip it */
.site-header::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(255, 255, 255, 0.96); }
@supports (backdrop-filter: blur(10px)) {
  .site-header::before { background: rgba(255, 255, 255, 0.88); backdrop-filter: saturate(1.4) blur(12px); }
}
.nav-open .site-header::before { background: var(--white); }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header.is-hidden { transform: translateY(-100%); }
.site-header__inner { height: 100%; display: flex; align-items: center; gap: 32px; }

.brand { flex: none; display: block; }
.brand__logo { width: auto; height: 30px; }

.primary-nav__list { display: flex; gap: clamp(18px, 1.8vw, 30px); list-style: none; margin: 0; padding: 0; }
.primary-nav__list a {
  font-size: 1rem; font-weight: 520; text-decoration: none; color: var(--petrol); white-space: nowrap;
  padding-block: 8px; background: linear-gradient(var(--copper), var(--copper)) left bottom / 0 1px no-repeat;
  transition: background-size 0.25s var(--ease-out), color 0.2s;
}
.primary-nav__list a:hover { color: var(--copper); background-size: 100% 1px; }
.primary-nav__footer { display: none; }

.site-header__actions { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.lang-switch { display: flex; gap: 10px; font-size: 0.875rem; font-weight: 560; }
.lang-switch a { text-decoration: none; color: var(--stone); }
.lang-switch a[aria-current="true"] { color: var(--petrol); text-decoration: underline; text-underline-offset: 4px; }
.lang-switch a:hover { color: var(--copper); }
.lang-switch [aria-disabled="true"] { color: var(--stone); opacity: 0.6; cursor: default; }
.lang-switch--menu { display: none; }

.menu-toggle {
  display: none; align-items: center; gap: 10px;
  min-height: 44px; padding: 0 4px;
  background: none; border: 0; color: var(--petrol);
  font: inherit; font-size: 0.9375rem; font-weight: 560; cursor: pointer;
}
.menu-toggle__bars { position: relative; width: 22px; height: 12px; }
.menu-toggle__bars::before, .menu-toggle__bars::after {
  content: ""; position: absolute; left: 0; width: 100%; height: 2px; background: currentColor;
  transition: transform 0.3s var(--ease-out), top 0.3s var(--ease-out);
}
.menu-toggle__bars::before { top: 0; }
.menu-toggle__bars::after { top: 10px; }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::before { top: 5px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__bars::after { top: 5px; transform: rotate(-45deg); }

/* The client's six menu labels need about 1280px on one line */
@media (max-width: 1279px) {
  .menu-toggle { display: inline-flex; }
  .site-header__cta { display: none; }
  .primary-nav {
    position: fixed; inset: var(--header-h) 0 0; z-index: 49;
    display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
    padding: 24px var(--gutter) 40px; background: var(--white);
    overflow-y: auto; overscroll-behavior: contain; visibility: hidden; opacity: 0;
    transition: opacity 0.25s, visibility 0s linear 0.25s;
  }
  .nav-open .primary-nav { visibility: visible; opacity: 1; transition: opacity 0.25s; }
  .primary-nav__list { flex-direction: column; gap: 0; }
  .primary-nav__list li { border-bottom: 1px solid var(--line); }
  .primary-nav__list a {
    display: block; padding-block: 18px; background: none; white-space: normal;
    font-size: clamp(1.4rem, 1.1rem + 1.5vw, 2rem); font-stretch: var(--wide); font-weight: 600;
  }
  .primary-nav__footer { display: grid; gap: 24px; }
  .primary-nav__footer .btn { width: 100%; }
  .nav-open .site-header { border-bottom-color: var(--line); }
}
@media (max-width: 520px) {
  :root { --header-h: 64px; }
  .brand__logo { height: 24px; }
  .lang-switch--bar { display: none; }
  .lang-switch--menu { display: flex; gap: 24px; font-size: 1rem; }
  .lang-switch--menu a, .lang-switch--menu span { min-height: 44px; display: inline-flex; align-items: center; }
  .site-header__actions { gap: 8px; }
}

/* ---------- Hero ---------- */
.hero { padding-top: calc(var(--header-h) + clamp(32px, 5vw, 72px)); padding-bottom: clamp(40px, 5vw, 64px); overflow: hidden; }
.hero__inner { display: grid; gap: 28px 48px; grid-template-columns: minmax(0, 1fr); }
.hero__title {
  font-size: var(--step-hero);
  font-stretch: var(--wide);
  font-weight: 640;
  line-height: 0.98;
  letter-spacing: -0.025em;
  max-width: 16ch;
  text-wrap: balance;
}
.hero__group { font-size: var(--step-small); color: var(--stone); order: 3; }
.hero__group a { color: var(--petrol); font-weight: 560; text-underline-offset: 4px; }
.hero__group a:hover { color: var(--copper); }
.hero__aside { display: grid; gap: 28px; max-width: 40rem; }
.hero__lead { font-size: var(--step-lead); line-height: 1.55; color: var(--stone); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 520px) { .hero__actions .btn { flex: 1 1 100%; } }

@media (min-width: 1000px) {
  .hero__inner { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .hero__title { grid-column: 1 / span 11; }
  .hero__group { order: 0; grid-column: 1 / span 4; grid-row: 2; align-self: end; }
  .hero__aside { grid-column: 6 / span 7; grid-row: 2; margin-top: 4px; }
}
/* Short desktop screens: tighten so the hero photo starts inside the first screen */
@media (min-width: 1000px) and (max-height: 900px) {
  .hero { padding-top: calc(var(--header-h) + 28px); }
  .hero__inner { row-gap: 22px; }
}

/* Hero photo: hero-sort.js cuts it into strips that arrive shuffled and slide into order */
.hero-photo { margin-top: clamp(40px, 4.5vw, 64px); }
.hero-photo__frame { position: relative; aspect-ratio: 2400 / 857; overflow: hidden; border-radius: 3px; }
.hero-photo__frame picture { position: absolute; inset: 0; display: block; }  /* out of flow, so the frame's size comes from the layout, not the image */
.hero-photo__img { width: 100%; height: 100%; object-fit: cover; }
/* The real photo stays painted underneath (so it counts as the page's largest paint straight away);
   a white cover hides it until the strips have sorted themselves over it */
.js:not(.motion-ready):not(.reveal-all) .hero-photo__frame::after,
.hero-photo__frame.is-sorting::after { content: ""; position: absolute; inset: 0; z-index: 1; background: var(--white); }
.hero-photo__slices { position: absolute; inset: 0; z-index: 2; }
.hero-photo__slice { position: absolute; top: 0; left: 0; height: 100%; background-repeat: no-repeat; will-change: transform; }
@media (max-width: 699px) { .hero-photo__frame { aspect-ratio: 3 / 2; } }
/* Desktop: the hero fills the first screen and the photo takes whatever height is left,
   so the whole sort is visible without scrolling on any screen height */
@media (min-width: 1000px) {
  .hero { min-height: 100svh; display: flex; flex-direction: column; padding-bottom: 32px; }
  .hero-photo { flex: 1 1 auto; display: flex; flex-direction: column; }
  .hero-photo > .hero-photo__frame { flex: 1 1 auto; aspect-ratio: auto; min-height: 240px; max-height: 620px; }
}
@media (min-width: 1000px) and (max-height: 900px) { .hero-photo { margin-top: 32px; } }

/* ---------- Range band (fx/scroll-velocity.css) ---------- */
/* the resting first word lines up with the page container, like the hero headline */
.rb-scroll-velocity { --rb-scroll-velocity-start: calc(max(0px, (100vw - var(--container)) / 2) + var(--gutter)); }

/* ---------- Intro ---------- */
.intro__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; }
.intro__statement {
  font-size: clamp(1.5rem, 1.15rem + 1.6vw, 2.5rem);
  font-stretch: var(--semi-wide);
  font-weight: 480;
  line-height: 1.28;
  letter-spacing: -0.01em;
  max-width: 30ch;
  text-wrap: pretty;
}
.intro__side { display: grid; gap: 28px; align-content: start; }
.intro__side .text-link { justify-self: start; }
.facts { display: grid; }
.facts__row { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 16px; padding-block: 16px; border-top: 1px solid var(--line); }
.facts__row:last-child { border-bottom: 1px solid var(--line); }
.facts dt { font-size: var(--step-small); font-weight: 600; color: var(--petrol); }
.facts dd { font-size: 1rem; line-height: 1.5; color: var(--stone); }
@media (min-width: 1000px) {
  .intro__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .intro__statement { grid-column: 1 / span 7; }
  .intro__side { grid-column: 9 / span 4; }
}

/* ---------- Product index ---------- */
.products { padding-top: 0; }
/* Example lots: the product presentation pattern, deliberately without any price element */
.lots { margin-top: clamp(56px, 6vw, 96px); display: grid; gap: 32px; }
.lots__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 32px; }
.lots__title { font-size: var(--step-h3); font-stretch: var(--semi-wide); font-weight: 620; line-height: 1.2; }
.lots__note { font-size: var(--step-small); color: var(--stone); }
.lots__list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 40px 32px; }
.lot { display: grid; gap: 12px; align-content: start; justify-items: start; }
.lot__img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 2px; margin-bottom: 8px; }
.lot__cat { font-size: 0.875rem; font-weight: 560; color: var(--copper); }
.lot__name { font-size: 1.25rem; font-stretch: var(--semi-wide); font-weight: 600; line-height: 1.25; }
.lot__desc { font-size: 1rem; color: var(--stone); margin-bottom: 8px; }

/* ---------- Process (cards come from fx/scroll-stack.css) ---------- */
.process { background: var(--mist); }
.process__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; }
.process__intro { display: grid; gap: 20px; max-width: 44rem; }
.process__cta { margin-top: 8px; }

/* ---------- Partner (dark) ---------- */
.partner { background: var(--petrol); color: #c9d6d8; }
.partner__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px; }
.partner__col { display: grid; gap: 24px; align-content: start; justify-items: start; max-width: 34rem; }
.partner__title {
  font-size: clamp(1.75rem, 1.35rem + 1.8vw, 3rem);
  font-stretch: var(--wide); font-weight: 620; line-height: 1.06; letter-spacing: -0.015em;
  color: var(--white);
}
.partner__note { padding-top: 28px; border-top: 1px solid var(--line-dark); font-size: 1rem; }
.partner__note a { color: var(--copper-light); text-underline-offset: 4px; }
.partner__note a:hover { color: var(--white); }
@media (min-width: 900px) {
  .partner__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 0; }
  .partner__col + .partner__col { padding-left: clamp(40px, 5vw, 80px); border-left: 1px solid var(--line-dark); }
  .partner__col:first-child { padding-right: clamp(40px, 5vw, 80px); }
  .partner__note { grid-column: 1 / -1; }
}

/* ---------- Markets ---------- */
.markets__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; align-items: center; }
.markets__text { display: grid; gap: 24px; justify-items: start; }
.legend { display: grid; gap: 12px; }
.legend__item { display: flex; align-items: center; gap: 14px; font-size: 1rem; }
.legend__swatch { flex: none; width: 18px; height: 18px; border-radius: 2px; }
.legend__swatch--active { background: var(--copper); }
.legend__swatch--planned { background: repeating-linear-gradient(45deg, #dce5e6 0 3px, #647a7f 3px 4.4px); box-shadow: inset 0 0 0 1px #647a7f; }
.markets__map { margin-inline: -8px; }
.market-map__svg {
  width: 100%; height: auto;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 8%, #000 90%, transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 8%, #000 90%, transparent);
}
.map-ctx { fill: #e8edec; stroke: var(--white); stroke-width: 0.8; }
.map-eu { fill: url(#hatch); stroke: var(--white); stroke-width: 1; }
.map-de { fill: var(--copper); stroke: var(--white); stroke-width: 1.2; }
.hatch-bg { fill: #dce5e6; }
.hatch-line { stroke: #647a7f; stroke-width: 1.4; }
@media (min-width: 1000px) {
  .markets__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 48px; }
  .markets__text { grid-column: 1 / span 5; }
  .markets__map { grid-column: 6 / span 7; }
}

/* ---------- Group ---------- */
.group { background: var(--mist); padding-block: clamp(64px, 7vw, 112px); }
.group-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 40px 32px; }
.group-list__item a { display: grid; gap: 18px; padding-top: 28px; border-top: 2px solid var(--line); text-decoration: none; transition: border-color 0.2s; }
.group-list__item--parent a { border-top-color: var(--petrol); }
.group-list__item img { height: clamp(52px, 5vw, 68px); width: auto; max-width: 100%; object-fit: contain; object-position: left center; }
.group-list__desc { font-size: var(--step-small); color: var(--stone); }
.group-list__item a:hover { border-top-color: var(--copper); }

/* ---------- Contact and enquiry forms ---------- */
.contact__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; }
.contact__intro { display: grid; gap: 24px; align-content: start; }
.contact__direct { display: grid; gap: 14px; font-size: 1rem; }
.contact__direct dt { font-size: var(--step-small); font-weight: 600; }
.contact__direct dd { color: var(--stone); }
.contact__careers { font-size: 1rem; color: var(--stone); }
.contact__careers a { color: var(--petrol); font-weight: 560; text-underline-offset: 4px; }
.contact__careers a:hover { color: var(--copper); }
@media (min-width: 1000px) {
  .contact__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 48px; }
  .contact__intro { grid-column: 1 / span 4; }
  .enquiry { grid-column: 6 / span 7; }
}

.enquiry__tabs { display: none; }
.js .enquiry__tabs { display: flex; gap: 4px 28px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: 36px; }
.enquiry__tab {
  position: relative; min-height: 48px; padding: 0; background: none; border: 0; cursor: pointer;
  font: inherit; font-size: 1rem; font-weight: 560; color: var(--stone);
}
.enquiry__tab::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: transparent; transition: background-color 0.2s; }
.enquiry__tab:hover { color: var(--petrol); }
.enquiry__tab[aria-selected="true"] { color: var(--petrol); }
.enquiry__tab[aria-selected="true"]::after { background: var(--copper); }
/* Without JS all three forms simply stack */
.enquiry__panel + .enquiry__panel { margin-top: 72px; }
.js .enquiry__panel + .enquiry__panel { margin-top: 0; }
.js .enquiry__panel[hidden] { display: none; }

.form { display: grid; gap: 24px; justify-items: start; scroll-margin-top: calc(var(--header-h) + 24px); }
.form__title { font-size: var(--step-h3); font-stretch: var(--semi-wide); font-weight: 620; line-height: 1.2; }
.form__intro { font-size: 1rem; color: var(--stone); margin-top: -12px; }
.form__grid { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px 24px; }
@media (min-width: 640px) { .form__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .field--wide { grid-column: 1 / -1; } }
.field { display: grid; gap: 8px; align-content: start; }
.field label { font-size: var(--step-small); font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  font: inherit; font-size: 1rem; color: var(--petrol);
  background: var(--white); border: 1px solid #7b8c90;  /* 3.5:1 against white, the minimum for input outlines is 3:1 */ border-radius: var(--radius);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field textarea { resize: vertical; min-height: 140px; line-height: 1.5; }
.field select {
  appearance: none; padding-right: 44px;
  background-image: linear-gradient(45deg, transparent 50%, var(--petrol) 50%), linear-gradient(135deg, var(--petrol) 50%, transparent 50%);
  background-position: calc(100% - 22px) 50%, calc(100% - 17px) 50%; background-size: 5px 5px; background-repeat: no-repeat;
}
.field input[type="file"] { padding: 11px 12px; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--petrol); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--copper); outline-offset: 1px; border-color: var(--copper); }
.field__hint { font-size: 0.875rem; color: var(--stone); }
.field__error { font-size: 0.875rem; font-weight: 560; color: var(--error); }
.field [aria-invalid="true"] { border-color: var(--error); box-shadow: inset 0 0 0 1px var(--error); }
.form__privacy { font-size: 0.875rem; color: var(--stone); max-width: 44rem; }
.form__privacy a { color: var(--petrol); text-underline-offset: 3px; }
.form__status { font-size: 1rem; }
.form__status:empty { display: none; }
.form__status.is-ok { padding: 16px 18px; background: var(--mist); border-left: 3px solid var(--copper); }
.form__status.is-error { color: var(--error); font-weight: 560; }

/* ---------- Footer ---------- */
.site-footer { background: var(--petrol-deep); color: #b8c7ca; padding-top: clamp(64px, 7vw, 104px); font-size: 1rem; }
.site-footer a { color: #dbe5e6; text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
/* links inside running text need an underline, colour alone is not enough */
.site-footer__bottom p a, .site-footer address a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.site-footer__grid { display: grid; gap: 40px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); padding-bottom: 56px; }
.site-footer__brand { display: grid; gap: 20px; align-content: start; grid-column: 1 / -1; max-width: 22rem; }
.site-footer__brand img { height: 32px; width: auto; }
.site-footer__heading { font-size: 1rem; font-weight: 620; color: var(--white); margin-bottom: 14px; }
.site-footer__col ul { display: grid; gap: 10px; }
.site-footer__col address { line-height: 1.7; }
.site-footer__bottom {
  display: flex; flex-wrap: wrap; gap: 12px 32px; align-items: center;
  padding-block: 28px 36px; font-size: 0.875rem;
  /* rule drawn inside the gutters so it lines up with the content above */
  background: linear-gradient(var(--line-dark), var(--line-dark)) var(--gutter) 0 / calc(100% - 2 * var(--gutter)) 1px no-repeat;
}
.site-footer__legal { display: flex; flex-wrap: wrap; gap: 12px 24px; }
@media (min-width: 700px) { .site-footer__legal { margin-left: auto; } }
@media (min-width: 1000px) {
  .site-footer__grid { grid-template-columns: 2fr 1.2fr 1.2fr 1.2fr; }
  .site-footer__brand { grid-column: auto; }
}

/* ---------- Subpages in preparation ---------- */
.page-hero { padding-top: calc(var(--header-h) + clamp(48px, 7vw, 104px)); padding-bottom: clamp(40px, 5vw, 72px); border-bottom: 1px solid var(--line); }
.page-hero__inner { display: grid; gap: 24px; }
.page-hero__inner > * { max-width: 52rem; } /* the container itself stays full width so the heading lines up with the logo */
.page-hero__crumb { font-size: var(--step-small); color: var(--stone); }
.page-hero__crumb a { color: var(--petrol); text-underline-offset: 4px; }
.page-hero__title { font-size: clamp(2.2rem, 1.4rem + 3.6vw, 4.5rem); font-stretch: var(--wide); font-weight: 640; line-height: 1; letter-spacing: -0.02em; text-wrap: balance; }
.page-hero__lead { font-size: var(--step-lead); color: var(--stone); max-width: 40rem; }
.stub { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; }
.stub__list { border-bottom: 1px solid var(--line); }
.stub__item { display: grid; gap: 6px; padding-block: 24px; border-top: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 16px); }
.stub__item h2 { font-size: var(--step-h3); font-stretch: var(--semi-wide); font-weight: 620; line-height: 1.2; }
.stub__item p { font-size: 1rem; color: var(--stone); }
.stub__aside { display: grid; gap: 20px; align-self: start; justify-items: start; padding: 28px; background: var(--mist); border-radius: 2px; }
.stub__aside p { font-size: 1rem; color: var(--stone); }
@media (min-width: 1000px) {
  .stub { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 48px; }
  .stub__list { grid-column: 1 / span 7; }
  .stub__aside { grid-column: 9 / span 4; }
}

/* ---------- Motion gates ---------- */
/* Only the headline and hero photo wait for main.js; the lead paragraph (the LCP element) paints immediately.
   A 2.5s fallback in <head> reveals them if the scripts never arrive. */
.js:not(.motion-ready):not(.reveal-all) .hero__title { opacity: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
