/* ==========================================================================
   AVZ VERTICAL SYSTEMS — Design System
   Built on AVZ_VerticalSystem_BrandIdentity.pdf → see ../../../BRAND-IDENTITY.md
   Palette, tint rules, 8pt base, 12-column grid and greyscale photography
   all follow the brand book.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Core palette (brand book p. 09) */
  --graphit:      #18181B;
  --cloud-dancer: #F3F1E9;
  --orange:       #FBAF4F;
  --stahlgrau:    #8A8D8F;
  --hellgrau:     #E8E6E1;

  /* Tints — never more than two per layout (brand book p. 10) */
  --graphit-75: rgba(24, 24, 27, .75);
  --graphit-50: rgba(24, 24, 27, .50);
  --graphit-25: rgba(24, 24, 27, .25);
  --graphit-10: rgba(24, 24, 27, .10);
  --graphit-06: rgba(24, 24, 27, .06);
  --orange-50:  rgba(251, 175, 79, .50);
  --orange-25:  rgba(251, 175, 79, .25);
  --orange-10:  rgba(251, 175, 79, .10);
  --light-10:   rgba(243, 241, 233, .10);
  --light-25:   rgba(243, 241, 233, .25);
  --light-50:   rgba(243, 241, 233, .50);
  --light-70:   rgba(243, 241, 233, .70);

  /* Semantic */
  --bg:            var(--cloud-dancer);
  --bg-alt:        var(--hellgrau);
  --bg-dark:       var(--graphit);
  --text:          var(--graphit);
  --text-muted:    #636466;
  --text-on-dark:  var(--cloud-dancer);
  --text-on-dark-muted: rgba(243, 241, 233, .62);
  --line:          rgba(24, 24, 27, .14);
  --line-dark:     rgba(243, 241, 233, .14);

  /* Type — Polymath Bold (display) + Arboria Book/Bold (body).
     Both are commercial licences; the stacks below degrade to the closest
     freely available grotesques until webfonts are licensed. */
  --font-display: "Polymath", "Archivo", "Inter", "Helvetica Neue", Arial, sans-serif;
  --font-body:    "Arboria", "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  /* 8pt spacing scale (brand book p. 12) */
  --s1: 8px;  --s2: 16px; --s3: 24px; --s4: 32px;
  --s6: 48px; --s8: 64px; --s12: 96px; --s16: 128px;

  /* Grid: 12 columns, fixed margin */
  --maxw: 1440px;
  --gutter: var(--s3);
  --margin: clamp(24px, 7vw, 100px);

  --radius: 0px;              /* the system is orthogonal — no rounded corners */
  --dur: .45s;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

/* --------------------------------------------------------------------------
   2. RESET / BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 120px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, video, svg { display: block; max-width: 100%; }
img, video { height: auto; }

a { color: inherit; text-decoration: none; }

button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--orange); color: var(--graphit); }

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

.skip-link {
  position: absolute; left: var(--s2); top: -100px; z-index: 999;
  background: var(--graphit); color: var(--cloud-dancer);
  padding: var(--s2) var(--s3); font-weight: 700;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: var(--s2); }

/* --------------------------------------------------------------------------
   3. TYPOGRAPHY  (brand book p. 11)
   -------------------------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  overflow-wrap: anywhere;
  hyphens: auto;
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -.02em;
  text-wrap: balance;
}

/* H1 — Polymath Bold, VERSALIEN */
.h1, h1 {
  font-size: clamp(2.75rem, 7.2vw, 6.25rem);
  text-transform: uppercase;
  letter-spacing: -.03em;
}
/* H2 */
.h2, h2 {
  font-size: clamp(2rem, 4.2vw, 3.5rem);
  text-transform: uppercase;
  letter-spacing: -.025em;
}
/* H3 — smaller grade, sentence case */
.h3, h3 { font-size: clamp(1.25rem, 2vw, 1.75rem); line-height: 1.15; }
h4       { font-size: 1.0625rem; line-height: 1.3; }

p { text-wrap: pretty; }

/* Section kicker — Arboria Book, caps, wide tracking */
.kicker {
  display: flex; align-items: center; gap: var(--s2);
  font-size: .8125rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .22em;
  color: var(--text-muted);
  margin-bottom: var(--s3);
}
.kicker::before {
  content: ""; width: 40px; height: 3px; background: var(--orange); flex: none;
}
.kicker--center { justify-content: center; }
.on-dark .kicker { color: var(--text-on-dark-muted); }

/* Caption / label — Arboria Bold, caps */
.label {
  font-size: .75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .18em;
  color: var(--text-muted);
  overflow-wrap: anywhere;
}
.on-dark .label { color: var(--text-on-dark-muted); }

.lead { font-size: clamp(1.0625rem, 1.35vw, 1.25rem); color: var(--text-muted); max-width: 62ch; }
.on-dark .lead { color: var(--text-on-dark-muted); }

.accent { color: var(--orange); }
.muted  { color: var(--text-muted); }
.on-dark .muted { color: var(--text-on-dark-muted); }
.mono { font-family: var(--font-mono); font-size: .8125rem; letter-spacing: .04em; }

/* The single accent line — mirrors the middle bar of the logo (p. 16) */
.rule-accent { width: 64px; height: 3px; background: var(--orange); border: 0; }

/* --------------------------------------------------------------------------
   4. LAYOUT
   -------------------------------------------------------------------------- */
.container {
  width: 100%; max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--margin);
}

.section { padding-block: clamp(var(--s8), 9vw, var(--s16)); position: relative; }
.section--tight { padding-block: clamp(var(--s6), 6vw, var(--s12)); }
.section--dark  { background: var(--bg-dark); color: var(--text-on-dark); }
.section--alt   { background: var(--bg-alt); }

.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gutter); }

.section-head { margin-bottom: var(--s8); max-width: 68ch; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .kicker { justify-content: center; }
.section-head p { margin-top: var(--s3); }

.section-head--split {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: var(--s6); max-width: none; flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   5. BUTTONS
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: var(--s2);
  padding: 18px var(--s4);
  font-family: var(--font-body);
  font-size: .8125rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .14em;
  border: 2px solid transparent; cursor: pointer;
  background: none;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
              border-color var(--dur) var(--ease), transform .2s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn svg { flex: none; transition: transform var(--dur) var(--ease); }
.btn:hover svg { transform: translateX(4px); }

.btn--primary { background: var(--orange); color: var(--graphit); border-color: var(--orange); }
.btn--primary:hover { background: var(--graphit); color: var(--cloud-dancer); border-color: var(--graphit); }

.btn--ghost { border-color: currentColor; color: inherit; }
.btn--ghost:hover { background: var(--graphit); color: var(--cloud-dancer); border-color: var(--graphit); }
.on-dark .btn--ghost:hover,
.hero .btn--ghost:hover { background: var(--cloud-dancer); color: var(--graphit); border-color: var(--cloud-dancer); }

.btn--dark { background: var(--graphit); color: var(--cloud-dancer); border-color: var(--graphit); }
.btn--dark:hover { background: var(--orange); color: var(--graphit); border-color: var(--orange); }

/* Inline text link with arrow */
.link-arrow {
  display: inline-flex; align-items: center; gap: var(--s1);
  font-size: .8125rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .14em;
  padding-bottom: 4px;
  border-bottom: 2px solid var(--orange);
  transition: gap var(--dur) var(--ease), color var(--dur) var(--ease);
}
.link-arrow:hover { gap: var(--s2); }
.on-dark .link-arrow:hover, .hero .link-arrow:hover { color: var(--orange); }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--s2); }

/* --------------------------------------------------------------------------
   6. TOP BAR
   -------------------------------------------------------------------------- */
.topbar {
  background: var(--graphit); color: var(--text-on-dark);
  font-size: .6875rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .16em;
}
.topbar .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s4); min-height: 40px; padding-block: 6px;
}
.topbar__claim { color: var(--text-on-dark-muted); }
.topbar__meta { display: flex; align-items: center; gap: var(--s3); }
.topbar__meta a:hover { color: var(--orange); }

.pulse { display: inline-flex; align-items: center; gap: var(--s1); }
.pulse::before {
  content: ""; width: 7px; height: 7px; background: var(--orange);
  border-radius: 50%; animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 var(--orange-50); }
  70%  { box-shadow: 0 0 0 8px rgba(251, 175, 79, 0); }
  100% { box-shadow: 0 0 0 0 rgba(251, 175, 79, 0); }
}

/* --------------------------------------------------------------------------
   7. HEADER / NAV
   -------------------------------------------------------------------------- */
.header {
  position: sticky; top: 0; z-index: 100;
  background: var(--cloud-dancer);
  border-bottom: 1px solid var(--line);
  transition: box-shadow var(--dur) var(--ease);
}
.header.is-stuck { box-shadow: 0 1px 24px rgba(24, 24, 27, .10); }

.nav { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); min-height: 88px; }
.nav__logo { display: flex; align-items: center; flex: none; }
.nav__logo img { height: 46px; width: auto; }

.nav__menu {
  display: flex; align-items: center; gap: clamp(var(--s2), 2vw, var(--s4));
  list-style: none; padding: 0; margin: 0 auto;
}
.nav__link {
  position: relative; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 2px;
  font-size: .8125rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .13em;
  white-space: nowrap;
  transition: color var(--dur) var(--ease);
}
.nav__link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 3px;
  background: var(--orange); transform: scaleX(0); transform-origin: left;
  transition: transform var(--dur) var(--ease);
}
.nav__link:hover::after, .nav__link[aria-current="page"]::after { transform: scaleX(1); }
.nav__link .chev { transition: transform var(--dur) var(--ease); }

.nav__cta { flex: none; }
/* The drawer duplicate of the CTA is hidden until the drawer exists. */
.nav__cta-mobile { display: none; }

/* Mega menu */
.has-mega { position: static; }
.mega {
  position: absolute; left: 0; right: 0; top: 100%;
  background: var(--cloud-dancer);
  border-top: 1px solid var(--line);
  border-bottom: 3px solid var(--orange);
  box-shadow: 0 24px 48px rgba(24, 24, 27, .12);
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
}
.has-mega:hover .mega,
.has-mega:focus-within .mega,
.mega.is-open { opacity: 1; visibility: visible; transform: translateY(0); }

.mega__inner {
  display: grid; grid-template-columns: 1fr 1fr 1fr 300px;
  gap: var(--s4); padding-block: var(--s6);
}
.mega__item { display: flex; gap: var(--s2); padding: var(--s2); transition: background var(--dur) var(--ease); }
.mega__item:hover { background: var(--graphit-06); }
.mega__num {
  align-self: start; background: var(--orange); color: var(--graphit);
  font-family: var(--font-mono); font-size: .6875rem; font-weight: 700; padding: 2px 7px;
}
.mega__title { font-weight: 700; font-size: .9375rem; }
.mega__desc { font-size: .8125rem; color: var(--text-muted); line-height: 1.4; }

.mega__callout {
  background: var(--graphit); color: var(--text-on-dark);
  padding: var(--s4); display: flex; flex-direction: column; gap: var(--s2);
}
.mega__callout .h3 { color: var(--cloud-dancer); }
.mega__callout .muted { color: var(--text-on-dark-muted); }
.mega__callout .phone { font-family: var(--font-display); font-size: 1.375rem; color: var(--orange); }

/* Mobile toggle */
.nav__toggle {
  display: none; flex: none;
  width: 48px; height: 48px; border: 1px solid var(--line);
  background: none; cursor: pointer; padding: 0;
  place-items: center;
}
.nav__toggle span, .nav__toggle span::before, .nav__toggle span::after {
  content: ""; display: block; width: 20px; height: 2px; background: var(--graphit);
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.nav__toggle span::before { transform: translateY(-6px); }
.nav__toggle span::after  { transform: translateY(4px); }
.nav__toggle[aria-expanded="true"] span { background: transparent; }
.nav__toggle[aria-expanded="true"] span::before { transform: rotate(45deg); }
.nav__toggle[aria-expanded="true"] span::after  { transform: rotate(-45deg) translateY(-1px); }

/* --------------------------------------------------------------------------
   8. HERO
   -------------------------------------------------------------------------- */
.hero {
  position: relative; min-height: min(92vh, 900px);
  display: flex; align-items: center;
  background: var(--graphit); color: var(--text-on-dark);
  overflow: hidden;
}
.hero__media { position: absolute; inset: 0; z-index: 0; }
.hero__media video, .hero__media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.06) brightness(.72);  /* photography: always greyscale */
}
.hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(24,24,27,.92) 0%, rgba(24,24,27,.70) 45%, rgba(24,24,27,.35) 100%),
    linear-gradient(0deg, rgba(24,24,27,.85) 0%, rgba(24,24,27,0) 45%);
}
.hero .container { position: relative; z-index: 1; padding-block: clamp(var(--s12), 14vh, 180px); }
.hero__inner { max-width: 60ch; }
.hero h1 { color: var(--cloud-dancer); }
.hero__sub {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.375rem, 2.6vw, 2.25rem);
  text-transform: uppercase; letter-spacing: -.01em;
  color: var(--orange); margin-top: var(--s3);
}
.hero .btn-row { margin-top: var(--s6); }
.hero .kicker { color: var(--text-on-dark-muted); }

/* Status card, bottom-right */
.hero__status {
  position: absolute; right: var(--margin); bottom: var(--s8); z-index: 2;
  width: 320px; max-width: calc(100vw - 2 * var(--margin));
  background: rgba(24, 24, 27, .88);
  backdrop-filter: blur(6px);
  border: 1px solid var(--line-dark);
  padding: var(--s3);
}
.hero__status-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--s3); }
.hero__status-mark { width: 26px; height: auto; }
.badge-outline {
  border: 1px solid var(--orange); color: var(--orange);
  padding: 3px 10px; font-size: .625rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .18em;
}
.hero__status dl { display: grid; grid-template-columns: auto 1fr; gap: 10px var(--s3); margin: 0; font-size: .6875rem; }
.hero__status dt { color: var(--text-on-dark-muted); text-transform: uppercase; letter-spacing: .14em; }
.hero__status dd { margin: 0; text-align: right; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }

.scroll-cue {
  position: absolute; left: 50%; bottom: var(--s4); z-index: 2;
  transform: translateX(-50%);
  color: var(--light-50);
  animation: bob 2.4s var(--ease) infinite;
}
@keyframes bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }

/* Page hero (subpages) */
.pagehero {
  position: relative; background: var(--graphit); color: var(--text-on-dark);
  padding-block: clamp(var(--s12), 12vw, 180px);
  overflow: hidden;
}
.pagehero__media { position: absolute; inset: 0; }
.pagehero__media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) brightness(.5); }
.pagehero__media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(24,24,27,.94) 0%, rgba(24,24,27,.66) 100%);
}
.pagehero .container { position: relative; z-index: 1; }
.pagehero h1 { color: var(--cloud-dancer); }
.pagehero__sub {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.25rem, 2.2vw, 2rem); text-transform: uppercase;
  color: var(--orange); margin-top: var(--s2);
}
.pagehero p { margin-top: var(--s3); max-width: 60ch; color: var(--text-on-dark-muted); }

/* Breadcrumb */
.crumbs { font-size: .6875rem; text-transform: uppercase; letter-spacing: .16em; color: var(--text-on-dark-muted); margin-bottom: var(--s3); }
.crumbs a:hover { color: var(--orange); }
.crumbs span { margin-inline: var(--s1); color: var(--orange); }

/* --------------------------------------------------------------------------
   9. METRICS BAR
   -------------------------------------------------------------------------- */
.metrics { background: var(--graphit); color: var(--text-on-dark); }
.metrics__grid {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  border-left: 1px solid var(--line-dark);
}
.metric {
  border-right: 1px solid var(--line-dark);
  padding: var(--s6) var(--s3);
  text-align: center;
}
.metric__icon { color: var(--orange); margin: 0 auto var(--s2); }
.metric__value {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2rem, 3.4vw, 3rem); line-height: 1;
  letter-spacing: -.02em;
}
.metric__label {
  margin-top: var(--s2); font-size: .6875rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .18em;
  color: var(--text-on-dark-muted);
  /* SERVICEBEREITSCHAFT is one long word — let it break in a narrow cell. */
  overflow-wrap: anywhere; hyphens: auto;
}

/* --------------------------------------------------------------------------
   10. SPLIT (text + framed image)
   -------------------------------------------------------------------------- */
.split { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--s8) var(--gutter); align-items: center; }
.split__text { grid-column: span 5; }
.split__media { grid-column: 7 / -1; position: relative; }
.split--flip .split__text { grid-column: 8 / -1; order: 2; }
.split--flip .split__media { grid-column: span 6; order: 1; }

.split__text { border-left: 3px solid var(--orange); padding-left: var(--s4); }
.split__text h2 { margin-bottom: var(--s3); }
.split__text p + p { margin-top: var(--s2); }
.split__text .btn-row, .split__text .link-arrow { margin-top: var(--s4); }

/* Technical corner brackets — graphic language p. 16 */
.framed { position: relative; }
.framed img { filter: grayscale(1) contrast(1.05); width: 100%; }
.framed::before, .framed::after {
  content: ""; position: absolute; width: 72px; height: 72px; pointer-events: none;
}
.framed::before { top: -14px; right: -14px; border-top: 3px solid var(--orange); border-right: 3px solid var(--orange); }
.framed::after  { bottom: -14px; left: -14px; border-bottom: 3px solid var(--orange); border-left: 3px solid var(--orange); }

/* --------------------------------------------------------------------------
   11. PROCESS  (Anlieferung → Montage → Prüfung → Übergabe → Service)
   -------------------------------------------------------------------------- */
.process { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--s3); position: relative; }
.process::before {
  content: ""; position: absolute; left: 0; right: 0; top: 40px; height: 2px;
  background: var(--orange);           /* the one line that carries the accent */
}
.process__step { position: relative; text-align: center; }
.process__icon {
  width: 80px; height: 80px; margin: 0 auto var(--s3);
  display: grid; place-items: center;
  border: 2px solid var(--orange);
  background: var(--bg-alt);
  color: var(--graphit);
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.process__step:hover .process__icon { background: var(--orange); transform: translateY(-4px); }
.section--dark .process__icon { background: var(--graphit); color: var(--cloud-dancer); }
.section--dark .process__step:hover .process__icon { background: var(--orange); color: var(--graphit); }
.process__title { font-family: var(--font-display); font-weight: 700; font-size: 1.0625rem; text-transform: uppercase; letter-spacing: .02em; }
.process__desc { margin-top: 6px; font-size: .6875rem; text-transform: uppercase; letter-spacing: .14em; color: var(--text-muted); }
.section--dark .process__desc { color: var(--text-on-dark-muted); }

/* --------------------------------------------------------------------------
   12. SERVICE CARDS
   -------------------------------------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); }
.cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card {
  display: flex; flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--line);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: 0 18px 40px rgba(24,24,27,.12); border-color: var(--graphit-25); }
.card__media { position: relative; aspect-ratio: 4 / 2.6; overflow: hidden; }
.card__media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.05);
  transition: transform .7s var(--ease);
}
.card:hover .card__media img { transform: scale(1.05); }
.card__num {
  position: absolute; right: 0; bottom: 0;
  background: var(--orange); color: var(--graphit);
  font-family: var(--font-mono); font-size: .8125rem; font-weight: 700;
  padding: 6px 12px;
}
.card__body { padding: var(--s3); display: flex; flex-direction: column; flex: 1; gap: var(--s2); }
.card__title { hyphens: auto; font-family: var(--font-display); font-weight: 700; font-size: 1.1875rem; text-transform: uppercase; letter-spacing: -.01em; line-height: 1.1; }
.card__desc { font-size: .9375rem; color: var(--text-muted); flex: 1; }
.card .link-arrow { align-self: flex-start; margin-top: var(--s1); }

/* --------------------------------------------------------------------------
   13. INDUSTRIES
   -------------------------------------------------------------------------- */
.industries { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); }
.industry { position: relative; aspect-ratio: 3 / 4; overflow: hidden; display: block; }
.industry img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) brightness(.62);
  transition: transform .8s var(--ease), filter var(--dur) var(--ease);
}
.industry:hover img { transform: scale(1.06); filter: grayscale(1) brightness(.45); }
.industry__label {
  position: absolute; left: var(--s3); right: var(--s3); bottom: var(--s3);
  color: var(--cloud-dancer);
  font-family: var(--font-display); font-weight: 700;
  font-size: 1.25rem; text-transform: uppercase; letter-spacing: -.01em;
}
.industry__label::before {
  content: ""; display: block; width: 32px; height: 3px; background: var(--orange);
  margin-bottom: var(--s2); transition: width var(--dur) var(--ease);
}
.industry:hover .industry__label::before { width: 64px; }

/* --------------------------------------------------------------------------
   14. VALUES / NUMBERED LIST
   -------------------------------------------------------------------------- */
.values { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--gutter); }
.value { border-top: 2px solid var(--line); padding-top: var(--s3); transition: border-color var(--dur) var(--ease); }
.value:hover { border-top-color: var(--orange); }
.section--dark .value { border-top-color: var(--line-dark); }
.value__num {
  display: inline-block; background: var(--orange); color: var(--graphit);
  font-family: var(--font-mono); font-size: .6875rem; font-weight: 700; padding: 2px 7px;
}
.value__title { hyphens: auto; font-family: var(--font-display); font-weight: 700; font-size: 1.375rem; text-transform: uppercase; margin: var(--s2) 0 var(--s1); }
.value__desc { font-size: .9375rem; color: var(--text-muted); }
.section--dark .value__desc { color: var(--text-on-dark-muted); }

/* --------------------------------------------------------------------------
   15. SLA PLANS
   -------------------------------------------------------------------------- */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); align-items: start; }
.plan {
  border: 1px solid var(--line); background: var(--bg);
  padding: var(--s6) var(--s4); position: relative;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.plan:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(24,24,27,.10); }
.plan--featured { background: var(--graphit); color: var(--text-on-dark); border-color: var(--graphit); }
.plan__badge {
  position: absolute; top: 0; right: 0;
  background: var(--orange); color: var(--graphit);
  font-size: .625rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; padding: 6px 12px;
}
.plan__name { font-family: var(--font-display); font-weight: 700; font-size: 2rem; text-transform: uppercase; }
.plan--featured .plan__name { color: var(--orange); }
.plan__sub { font-size: .75rem; text-transform: uppercase; letter-spacing: .16em; color: var(--text-muted); margin-top: 6px; }
.plan--featured .plan__sub { color: var(--text-on-dark-muted); }
.plan__list { list-style: none; padding: 0; margin: var(--s4) 0; display: grid; gap: 12px; }
.plan__list li { display: flex; gap: 12px; font-size: .9375rem; align-items: flex-start; }
.plan__list li::before {
  content: ""; flex: none; width: 8px; height: 8px; margin-top: 8px;
  background: var(--orange);
}
.plan__list li.is-off { color: var(--text-muted); }
.plan__list li.is-off::before { background: var(--line); }
.plan--featured .plan__list li.is-off { color: var(--text-on-dark-muted); }
.plan__price { font-size: .75rem; text-transform: uppercase; letter-spacing: .16em; color: var(--text-muted); margin-bottom: var(--s3); }
.plan--featured .plan__price { color: var(--text-on-dark-muted); }
.plan .btn { width: 100%; justify-content: center; }

/* --------------------------------------------------------------------------
   16. SERVICE DETAIL BLOCKS (Leistungen page)
   -------------------------------------------------------------------------- */
.svc {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--s6) var(--gutter);
  align-items: center;
  padding-block: clamp(var(--s8), 7vw, var(--s12));
  border-top: 1px solid var(--line);
  scroll-margin-top: 140px;
}
.svc__media { grid-column: span 6; }
.svc__text  { grid-column: 8 / -1; }
.svc:nth-child(even) .svc__media { grid-column: 7 / -1; order: 2; }
.svc:nth-child(even) .svc__text  { grid-column: span 5; order: 1; }

.svc__num {
  display: inline-block;
  font-family: var(--font-display); font-weight: 700;
  font-size: 3.5rem; line-height: 1; color: var(--text);
  border-top: 3px solid var(--orange); padding-top: var(--s2);
}
.svc__sub { font-size: .75rem; text-transform: uppercase; letter-spacing: .18em; color: var(--text-muted); margin-top: var(--s1); }
.svc h2 { margin: var(--s2) 0 var(--s3); font-size: clamp(1.75rem, 3vw, 2.75rem); }
.svc__list { list-style: none; padding: 0; margin: var(--s4) 0; display: grid; gap: 10px; }
.svc__list li { display: flex; gap: 12px; align-items: flex-start; font-size: .9375rem; }
.svc__list li svg { flex: none; color: var(--orange); margin-top: 3px; }

.tags { display: flex; flex-wrap: wrap; gap: var(--s1); margin-top: var(--s3); }
.tag {
  border: 1px solid var(--line); padding: 6px 12px;
  font-size: .6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .12em;
  color: var(--text-muted);
}

/* Ablauf strip */
.flow { display: flex; flex-wrap: wrap; gap: var(--s1); margin-top: var(--s4); }
.flow__step {
  display: flex; align-items: center; gap: var(--s1);
  background: var(--bg-alt); padding: 10px 14px;
  font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em;
}
.flow__step b { font-family: var(--font-mono); color: var(--text); font-weight: 700; }

/* --------------------------------------------------------------------------
   17. TIMELINE
   -------------------------------------------------------------------------- */
.timeline { position: relative; display: grid; gap: 0; }
.timeline::before {
  content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px;
  width: 2px; background: var(--orange-25);
}
.tl-item { position: relative; padding: 0 0 var(--s6) var(--s6); }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: ""; position: absolute; left: 0; top: 6px;
  width: 16px; height: 16px; background: var(--bg); border: 3px solid var(--orange);
}
.section--dark .tl-item::before { background: var(--graphit); }
.tl-item:last-child::before { background: var(--orange); }
.tl-year { font-family: var(--font-mono); font-size: .8125rem; font-weight: 700; color: var(--text); letter-spacing: .1em; }
.section--dark .tl-year { color: var(--orange); }
.tl-title { overflow-wrap: anywhere; font-family: var(--font-display); font-weight: 700; font-size: 1.375rem; text-transform: uppercase; margin: 4px 0 var(--s1); }
.tl-desc { font-size: .9375rem; color: var(--text-muted); max-width: 60ch; }
.section--dark .tl-desc { color: var(--text-on-dark-muted); }

/* --------------------------------------------------------------------------
   18. ACCORDION (jobs / FAQ)
   -------------------------------------------------------------------------- */
.acc { border-top: 1px solid var(--line); }
.acc__item { border-bottom: 1px solid var(--line); }
.acc__btn {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: var(--s3);
  padding: var(--s4) 0; background: none; border: 0; cursor: pointer; text-align: left;
  transition: color var(--dur) var(--ease);
}
.acc__btn:hover { color: var(--orange); }
.acc__head { display: flex; flex-direction: column; gap: 6px; }
.acc__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.125rem, 2vw, 1.625rem); text-transform: uppercase; line-height: 1.1; }
.acc__meta { display: flex; flex-wrap: wrap; gap: var(--s2); font-size: .6875rem; text-transform: uppercase; letter-spacing: .14em; color: var(--text-muted); }
.acc__meta span { display: inline-flex; align-items: center; gap: 6px; }
.acc__icon {
  flex: none; width: 44px; height: 44px; border: 2px solid var(--orange);
  display: grid; place-items: center; position: relative;
  transition: background var(--dur) var(--ease);
}
.acc__icon::before, .acc__icon::after {
  content: ""; position: absolute; background: var(--graphit);
}
.acc__icon::before { width: 16px; height: 2px; }
.acc__icon::after  { width: 2px; height: 16px; transition: transform var(--dur) var(--ease); }
.acc__btn[aria-expanded="true"] .acc__icon { background: var(--orange); }
.acc__btn[aria-expanded="true"] .acc__icon::after { transform: scaleY(0); }
.acc__panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur) var(--ease); }
.acc__panel[data-open="true"] { grid-template-rows: 1fr; }
.acc__panel > div { overflow: hidden; }
.acc__content { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); padding-bottom: var(--s6); }
.acc__content h4 { text-transform: uppercase; letter-spacing: .06em; margin-bottom: var(--s2); font-family: var(--font-display); }
.acc__content ul { list-style: none; padding: 0; display: grid; gap: 10px; }
.acc__content li { display: flex; gap: 12px; font-size: .9375rem; }
.acc__content li::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: 8px; background: var(--orange); }
.acc__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); border-top: 1px solid var(--line); padding-top: var(--s3); }

/* --------------------------------------------------------------------------
   19. BENEFITS / ICON GRID
   -------------------------------------------------------------------------- */
.icongrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
.icontile {
  background: var(--bg); border: 1px solid var(--line); padding: var(--s4);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.icontile:hover { border-color: var(--orange); transform: translateY(-4px); }
.icontile__icon { color: var(--orange); margin-bottom: var(--s3); }
.icontile h3 { font-size: 1.1875rem; text-transform: uppercase; margin-bottom: var(--s1); }
.icontile p { font-size: .9375rem; color: var(--text-muted); }
.section--dark .icontile { background: transparent; border-color: var(--line-dark); }
.section--dark .icontile p { color: var(--text-on-dark-muted); }

/* --------------------------------------------------------------------------
   20. QUOTE BAND
   -------------------------------------------------------------------------- */
.quote { text-align: center; }
.quote blockquote {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.75rem, 4vw, 3.25rem); line-height: 1.08;
  text-transform: uppercase; letter-spacing: -.025em;
  max-width: 20ch; margin-inline: auto;
}
.quote figcaption { margin-top: var(--s4); }

/* Voice do/don't */
.voice { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s8); }
.voice__col h3 { display: flex; align-items: center; gap: var(--s2); margin-bottom: var(--s4); text-transform: uppercase; }
.voice__list { list-style: none; padding: 0; display: grid; gap: var(--s2); }
.voice__list li { display: flex; gap: var(--s2); padding: var(--s3); background: var(--graphit-06); font-size: 1rem; }
.section--dark .voice__list li { background: var(--light-10); }
.voice__list li svg { flex: none; margin-top: 3px; }
.voice--yes svg { color: var(--orange); }
.voice--no li { opacity: .62; }

/* --------------------------------------------------------------------------
   21. BANNER / CTA
   -------------------------------------------------------------------------- */
.banner {
  background: var(--orange); color: var(--graphit);
  padding-block: var(--s8);
}
.banner__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s6); }
.banner h2 { font-size: clamp(1.5rem, 3vw, 2.5rem); max-width: 22ch; }

.cta-dark { background: var(--graphit); color: var(--text-on-dark); }
.cta-dark__inner { display: grid; grid-template-columns: 1.2fr 1fr; gap: var(--s8); align-items: center; }
.cta-card { border: 1px solid var(--line-dark); padding: var(--s6); }
.cta-card__row { display: flex; align-items: center; gap: var(--s3); padding-block: var(--s3); border-bottom: 1px solid var(--line-dark); }
.cta-card__row:last-of-type { border-bottom: 0; }
.cta-card__icon { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--orange); color: var(--orange); }
.cta-card__val { font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; }
.cta-card__val a:hover { color: var(--orange); }

/* --------------------------------------------------------------------------
   22. FORM
   -------------------------------------------------------------------------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); }
.field { display: flex; flex-direction: column; gap: var(--s1); }
.field--full { grid-column: 1 / -1; }
.field > label { font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .16em; color: var(--text-muted); }
.field input, .field select, .field textarea {
  background: var(--bg); border: 1px solid var(--line); padding: 14px var(--s2);
  font-size: .9375rem; width: 100%;
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-25);
}
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: #C4442E; }
.field__err { font-size: .75rem; color: #C4442E; display: none; }
.field.is-invalid .field__err { display: block; }
.req { color: var(--text); }

.form__note { grid-column: 1 / -1; font-size: .8125rem; color: var(--text-muted); }
.form__status { grid-column: 1 / -1; padding: var(--s3); border-left: 3px solid var(--orange); background: var(--orange-10); display: none; }
.form__status.is-visible { display: block; }

/* --------------------------------------------------------------------------
   23. LEGAL / PROSE
   -------------------------------------------------------------------------- */
.prose { max-width: 78ch; }
.prose h2 { font-size: clamp(1.375rem, 2.4vw, 2rem); margin: var(--s8) 0 var(--s3); }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.125rem; text-transform: uppercase; margin: var(--s4) 0 var(--s2); }
.prose p, .prose ul { margin-bottom: var(--s2); }
.prose ul { padding-left: var(--s3); }
.prose li { margin-bottom: 6px; }
/* Orange stays the accent as the underline; the link text keeps a legible colour. */
.prose a {
  color: var(--text); text-decoration: underline; text-underline-offset: 3px;
  text-decoration-color: var(--orange); text-decoration-thickness: 2px;
}
.prose a:hover { text-decoration-color: var(--text); }
.prose dl { display: grid; grid-template-columns: minmax(180px, 240px) 1fr; gap: 10px var(--s3); margin-bottom: var(--s4); }
.prose dt { font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--text-muted); padding-top: 3px; }
.prose dd { margin: 0; }
.prose .note { border-left: 3px solid var(--orange); background: var(--orange-10); padding: var(--s3); margin-bottom: var(--s4); }

/* --------------------------------------------------------------------------
   24. FOOTER
   -------------------------------------------------------------------------- */
.footer { background: var(--graphit); color: var(--text-on-dark); border-top: 3px solid var(--orange); }
.footer__top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: var(--s8) var(--gutter); padding-block: var(--s12) var(--s8); }
.footer__brand img { width: 44px; margin-bottom: var(--s3); }
.footer__brand p { font-size: .9375rem; color: var(--text-on-dark-muted); max-width: 34ch; }
.footer h2 { font-family: var(--font-display); font-size: 1.125rem; letter-spacing: -.01em; text-transform: uppercase; margin-bottom: var(--s3); }
.footer ul { list-style: none; padding: 0; display: grid; gap: 12px; }
.footer a { font-size: .9375rem; color: var(--text-on-dark-muted); transition: color var(--dur) var(--ease); }
.footer a:hover { color: var(--orange); }
.footer address { font-style: normal; font-size: .9375rem; color: var(--text-on-dark-muted); display: grid; gap: 12px; }
.footer__bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3);
  border-top: 1px solid var(--line-dark); padding-block: var(--s3) var(--s6);
  font-size: .75rem; color: var(--text-on-dark-muted);
}
.footer__legal { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }
.status-dot { display: inline-flex; align-items: center; gap: var(--s1); }
.status-dot::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #4FBF7A; }

/* Back to top */
.totop {
  position: fixed; right: 24px; bottom: 24px; z-index: 90;
  width: 48px; height: 48px; display: grid; place-items: center;
  background: var(--orange); color: var(--graphit); border: 0; cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), visibility var(--dur);
}
.totop.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.totop:hover { background: var(--graphit); color: var(--orange); }

/* --------------------------------------------------------------------------
   25. SCROLL REVEAL
   -------------------------------------------------------------------------- */
/* Hidden only when JS is running — without JS everything stays visible. */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* --------------------------------------------------------------------------
   26. RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 1180px) {
  .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mega__inner { grid-template-columns: 1fr 1fr 260px; }
  .values { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer__top { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
}

@media (max-width: 1340px) {
  .nav__menu { gap: var(--s2); }
  .nav__link { font-size: .75rem; letter-spacing: .09em; }
  .nav__cta .btn { padding: 14px var(--s3); font-size: .75rem; letter-spacing: .09em; }
  .nav__logo img { height: 40px; }
}

/* Nav collapses earlier than the layout: five links + CTA stop fitting ~1200px. */
@media (max-width: 1200px) {
  .nav__menu, .nav__cta { display: none; }
  .nav__toggle { display: grid; }
  .nav { min-height: 72px; }

  /* Mobile drawer */
  .nav__menu.is-open {
    display: flex; flex-direction: column; align-items: stretch; gap: 0;
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--cloud-dancer); border-bottom: 3px solid var(--orange);
    padding: var(--s2) var(--margin) var(--s4);
    max-height: calc(100vh - 72px); overflow-y: auto;
    box-shadow: 0 24px 48px rgba(24,24,27,.14);
  }
  .nav__menu.is-open > li { border-bottom: 1px solid var(--line); }
  .nav__menu.is-open .nav__link { padding: var(--s3) 0; font-size: 1rem; width: 100%; justify-content: space-between; }
  .nav__menu.is-open .nav__link::after { display: none; }
  .nav__menu.is-open .mega {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; display: none; background: transparent;
  }
  .nav__menu.is-open .mega.is-open { display: block; }
  .nav__menu.is-open .mega__inner { grid-template-columns: 1fr; padding-block: 0 var(--s3); gap: 0; }
  .nav__menu.is-open .mega__callout { display: none; }
  .nav__menu.is-open .nav__cta-mobile { display: block; margin-top: var(--s3); }
  .nav__cta-mobile { display: none; }
  .nav__cta-mobile .btn { width: 100%; justify-content: center; }

}

@media (max-width: 1024px) {
  .split { grid-template-columns: minmax(0, 1fr); gap: var(--s6); }
  .split__text, .split__media,
  .split--flip .split__text, .split--flip .split__media { grid-column: 1 / -1; order: 0; }

  .svc { grid-template-columns: minmax(0, 1fr); }
  .svc__media, .svc__text,
  .svc:nth-child(even) .svc__media, .svc:nth-child(even) .svc__text { grid-column: 1 / -1; order: 0; }

  .cta-dark__inner { grid-template-columns: 1fr; }
  .metrics__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric { border-bottom: 1px solid var(--line-dark); }
  .process { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s6) var(--s3); }
  .process::before { display: none; }
  .plans { grid-template-columns: 1fr; }
  .voice { grid-template-columns: 1fr; gap: var(--s6); }
  .acc__content { grid-template-columns: 1fr; gap: var(--s4); }
}

@media (max-width: 860px) {
  .cards, .industries, .icongrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .values { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__status { position: static; width: 100%; max-width: 360px; margin-top: var(--s6); }
  .hero .container { padding-block: var(--s12) var(--s8); }
  .scroll-cue { display: none; }
  .topbar__claim { display: none; }
  .topbar .container { justify-content: center; }
  .form { grid-template-columns: 1fr; }
  .prose dl { grid-template-columns: 1fr; gap: 4px var(--s2); }
  .prose dd { margin-bottom: var(--s2); }
}

@media (max-width: 560px) {
  .cards, .industries, .icongrid, .values, .footer__top { grid-template-columns: 1fr; }
  .process { grid-template-columns: minmax(0, 1fr); }
  .metrics__grid { grid-template-columns: minmax(0, 1fr); }
  .metric { padding-block: var(--s4); }
  .framed::before, .framed::after { width: 44px; height: 44px; }
  .btn { width: 100%; justify-content: center; }
  .btn-row { flex-direction: column; align-items: stretch; }
  .banner__inner { flex-direction: column; align-items: flex-start; }
}

/* --------------------------------------------------------------------------
   27. MOTION / PRINT
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important;
    transition-duration: .001ms !important; scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
}

@media print {
  .topbar, .header, .footer, .totop, .hero__media, .scroll-cue, .banner { display: none !important; }
  body { background: #fff; color: #000; }
  .section { padding-block: 16px; }
}

/* ==========================================================================
   28. VERTICAL RAIL SYSTEM
   The brand mark is three converging vertical bars, the middle one orange,
   marking "der Punkt der Montage". That bar becomes the spine of the page:
   a continuous track down the left margin that fills orange as you scroll,
   like a car travelling a lift shaft. Sections dock onto it.
   ========================================================================== */
.section--rail { position: relative; }

/* Track — sections abut, so the segments read as one unbroken line. */
.section--rail::before,
.section--rail::after {
  content: ""; position: absolute; top: 0; bottom: 0;
  left: var(--margin); width: 2px; pointer-events: none;
}
.section--rail::before { background: var(--graphit-10); }
.section--rail.section--dark::before { background: var(--line-dark); }

/* Fill — driven by --rail-p (0 to 1) from the scroll handler. */
.section--rail::after {
  background: var(--orange);
  transform: scaleY(var(--rail-p, 0));
  transform-origin: top center;
  transition: transform .12s linear;
}

.railed { padding-left: calc(var(--s8) + 2px); position: relative; z-index: 1; }

/* Marker docked onto the rail, aligned to a heading */
.rail-mark { position: relative; }
.rail-mark::before {
  content: ""; position: absolute;
  left: calc((var(--s8) + 2px) * -1 - 5px); top: .55em;
  width: 12px; height: 12px; background: var(--orange);
}

@media (max-width: 860px) {
  .section--rail::before, .section--rail::after { left: 10px; }
  .railed { padding-left: var(--s4); }
  .rail-mark::before { left: calc(var(--s4) * -1 - 5px); width: 10px; height: 10px; }
}

/* ==========================================================================
   29. HERO — rail lockup + lift panel
   ========================================================================== */
.hero-v2 {
  position: relative; background: var(--graphit); color: var(--text-on-dark);
  overflow: hidden; min-height: min(94vh, 940px); display: flex; align-items: center;
}
.hero-v2 .hero__media { position: absolute; inset: 0; }
.hero-v2 .hero__media video, .hero-v2 .hero__media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.08) brightness(.55);
}
.hero-v2 .hero__media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(24,24,27,.95) 0%, rgba(24,24,27,.78) 42%, rgba(24,24,27,.38) 100%),
    linear-gradient(0deg, rgba(24,24,27,.92) 0%, rgba(24,24,27,0) 40%);
}
.hero-v2 .container { position: relative; z-index: 1; padding-block: clamp(var(--s12), 13vh, 160px); }

.hero-v2__grid {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr);
  gap: clamp(var(--s8), 6vw, var(--s16)); align-items: center;
}

/* Headline anchored to its own rail */
.hero-lockup { position: relative; padding-left: calc(var(--s6) + 2px); }
.hero-lockup::before {
  content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 2px;
  background: var(--line-dark);
}
.hero-lockup__bar {
  position: absolute; left: -1px; top: 6px; width: 4px;
  background: var(--orange);
  height: 0; animation: railGrow 1.6s var(--ease) .25s forwards;
}
@keyframes railGrow { to { height: calc(100% - 12px); } }

.hero-lockup h1 { color: var(--cloud-dancer); margin: 0; }
.hero-lockup h1 span {
  display: block; position: relative;
  opacity: 0; transform: translateY(28px);
  animation: liftIn .9s var(--ease) forwards;
}
.hero-lockup h1 span:nth-child(1) { animation-delay: .10s; }
.hero-lockup h1 span:nth-child(2) { animation-delay: .22s; }
.hero-lockup h1 span:nth-child(3) { animation-delay: .34s; }
@keyframes liftIn { to { opacity: 1; transform: none; } }

.hero-lockup__sub {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.25rem, 2.4vw, 2rem);
  text-transform: uppercase; letter-spacing: -.01em;
  color: var(--orange); margin-top: var(--s4);
  opacity: 0; animation: liftIn .9s var(--ease) .46s forwards;
}
.hero-lockup .kicker { color: var(--text-on-dark-muted); }
.hero-v2 .btn-row { margin-top: var(--s8); opacity: 0; animation: liftIn .9s var(--ease) .58s forwards; }

/* Lift panel — the four promises as tray levels in a shaft */
.lift { align-self: stretch; display: flex; align-items: center; }
.lift__inner { width: 100%; }
.lift__head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: var(--s2); margin-bottom: var(--s3);
  border-bottom: 1px solid var(--line-dark); padding-bottom: var(--s2);
}
.lift__shaft { position: relative; padding-left: var(--s4); }
.lift__shaft::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
  background: var(--line-dark);
}
.lift__car {
  position: absolute; left: -3px; width: 8px; height: 25%; top: 0;
  background: var(--orange);
  transition: transform .8s var(--ease);
}
.lift__levels { list-style: none; padding: 0; margin: 0; }
.lift__level {
  padding: var(--s3) 0; border-bottom: 1px solid var(--line-dark);
  display: flex; align-items: baseline; gap: var(--s2);
  transition: padding-left var(--dur) var(--ease);
}
.lift__level:last-child { border-bottom: 0; }
.lift__level.is-active { padding-left: var(--s2); }
.lift__val {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 2.2vw, 2rem); line-height: 1;
  color: var(--text-on-dark-muted); transition: color var(--dur) var(--ease);
  flex: none; min-width: 4.5ch;
}
.lift__level.is-active .lift__val { color: var(--orange); }
.lift__lab {
  font-size: .6875rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .16em; color: var(--text-on-dark-muted);
  overflow-wrap: anywhere;
}

/* ==========================================================================
   30. STATEMENT
   ========================================================================== */
.stmt__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: clamp(var(--s8), 6vw, var(--s12)); align-items: center; }
.stmt h2 { font-size: clamp(1.75rem, 3.6vw, 3.25rem); line-height: 1.05; }
.stmt h2 em {
  font-style: normal;
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-decoration-thickness: .12em;
  text-underline-offset: .14em;
}
.section--dark .stmt h2 em { color: var(--orange); text-decoration: none; }
.stmt__meta { margin-top: var(--s6); display: grid; gap: var(--s3); }
.stmt__row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: var(--s3); align-items: baseline; padding-top: var(--s3); border-top: 1px solid var(--line); }
.section--dark .stmt__row { border-top-color: var(--line-dark); }
.stmt__k { font-family: var(--font-mono); font-size: .6875rem; letter-spacing: .1em; text-transform: uppercase; color: var(--text); }
.section--dark .stmt__k { color: var(--orange); }

/* ==========================================================================
   31. LEISTUNGSREGISTER — numbered rows that open in place
   ========================================================================== */
.register { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.section--dark .register { border-top-color: var(--line-dark); }
.reg { border-bottom: 1px solid var(--line); }
.section--dark .reg { border-bottom-color: var(--line-dark); }

.reg__head {
  width: 100%; background: none; border: 0; cursor: pointer;
  display: grid; grid-template-columns: 68px minmax(0, 1fr) minmax(0, .9fr) 44px;
  align-items: center; gap: var(--s3);
  padding: var(--s4) 0; text-align: left;
  transition: padding-left var(--dur) var(--ease);
}
.reg__head:hover, .reg__head[aria-expanded="true"] { padding-left: var(--s3); }
.reg__num {
  font-family: var(--font-mono); font-size: .8125rem; font-weight: 700;
  color: var(--text-muted); transition: color var(--dur) var(--ease);
}
.section--dark .reg__num { color: var(--text-on-dark-muted); }
.reg__head:hover .reg__num { color: var(--text); }
.section--dark .reg__head:hover .reg__num,
.section--dark .reg__head[aria-expanded="true"] .reg__num { color: var(--orange); }
.reg__title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.375rem, 2.6vw, 2.25rem); line-height: 1.05;
  text-transform: uppercase; letter-spacing: -.02em;
}
.reg__sub { font-size: .8125rem; text-transform: uppercase; letter-spacing: .14em; color: var(--text-muted); }
.section--dark .reg__sub { color: var(--text-on-dark-muted); }
.reg__plus {
  justify-self: end; width: 40px; height: 40px; position: relative;
  border: 2px solid var(--line); transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.section--dark .reg__plus { border-color: var(--line-dark); }
.reg__plus::before, .reg__plus::after {
  content: ""; position: absolute; left: 50%; top: 50%; background: currentColor;
  transform: translate(-50%, -50%);
}
.reg__plus::before { width: 14px; height: 2px; }
.reg__plus::after  { width: 2px; height: 14px; transition: transform var(--dur) var(--ease); }
.reg__head:hover .reg__plus { border-color: var(--orange); }
.reg__head[aria-expanded="true"] .reg__plus { background: var(--orange); border-color: var(--orange); color: var(--graphit); }
.reg__head[aria-expanded="true"] .reg__plus::after { transform: translate(-50%, -50%) scaleY(0); }

.reg__panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur) var(--ease); }
.reg__panel[data-open="true"] { grid-template-rows: 1fr; }
.reg__panel > div { overflow: hidden; }
.reg__body {
  display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: clamp(var(--s4), 4vw, var(--s8));
  padding: 0 0 var(--s8) 68px;
}
.reg__media { position: relative; }
.reg__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; filter: grayscale(1) contrast(1.05); }
.reg__media::after {
  content: ""; position: absolute; right: -10px; bottom: -10px; width: 56px; height: 56px;
  border-right: 3px solid var(--orange); border-bottom: 3px solid var(--orange);
}
.reg__list { list-style: none; padding: 0; margin: var(--s3) 0 0; display: grid; gap: 10px; }
.reg__list li { display: flex; gap: 12px; align-items: flex-start; font-size: .9375rem; }
.reg__list li svg { flex: none; color: var(--orange); margin-top: 3px; }
.reg__foot { margin-top: var(--s4); display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }

/* ==========================================================================
   32. ASCENT — the AVZ process as a vertical climb
   ========================================================================== */
.ascent { list-style: none; padding: 0; margin: 0; }
.ascent__step {
  position: relative; display: grid;
  grid-template-columns: 96px minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--s4); align-items: start;
  padding: var(--s6) var(--s3); border-top: 1px solid var(--line-dark);
  transition: background var(--dur) var(--ease);
}
.ascent__step:hover { background: var(--light-10); }
.ascent__step:last-child { border-bottom: 1px solid var(--line-dark); }
.ascent__n {
  font-family: var(--font-mono); font-size: .75rem; font-weight: 700;
  letter-spacing: .12em; color: var(--orange);
  display: flex; align-items: center; gap: var(--s2);
}
.ascent__n::after { content: ""; flex: 1; height: 1px; background: var(--orange-25); }
.ascent__t {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 2.6vw, 2.25rem); text-transform: uppercase;
  letter-spacing: -.02em; line-height: 1;
  display: flex; align-items: center; gap: var(--s3);
}
.ascent__t svg { color: var(--orange); flex: none; }
.ascent__d { color: var(--text-on-dark-muted); font-size: .9375rem; padding-top: 6px; }
.ascent__cap {
  display: inline-flex; align-items: center; gap: var(--s2);
  margin-top: var(--s4); color: var(--orange);
  font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .16em;
}

/* ==========================================================================
   33. BRANCHEN — one stage, names swap the image
   ========================================================================== */
.branchen { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(var(--s6), 5vw, var(--s12)); align-items: center; }
.branchen__list { list-style: none; padding: 0; margin: 0; }
.branchen__item { border-bottom: 1px solid var(--line-dark); }
.branchen__item:first-child { border-top: 1px solid var(--line-dark); }
.branchen__btn {
  width: 100%; background: none; border: 0; cursor: pointer; text-align: left;
  display: flex; align-items: center; justify-content: space-between; gap: var(--s3);
  padding: var(--s4) 0;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 3vw, 2.5rem); text-transform: uppercase; letter-spacing: -.02em;
  color: var(--text-on-dark-muted);
  transition: color var(--dur) var(--ease), padding-left var(--dur) var(--ease);
}
.branchen__btn:hover { color: var(--cloud-dancer); padding-left: var(--s3); }
.branchen__item.is-active .branchen__btn { color: var(--orange); padding-left: var(--s3); }
.branchen__meta { font-family: var(--font-mono); font-size: .6875rem; letter-spacing: .1em; opacity: .7; }
.branchen__stage { position: relative; aspect-ratio: 4 / 3.2; }
.branchen__img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.06) brightness(.8);
  opacity: 0; transform: scale(1.04);
  transition: opacity .6s var(--ease), transform .9s var(--ease);
}
.branchen__img.is-active { opacity: 1; transform: none; }
.branchen__stage::after {
  content: ""; position: absolute; left: 0; top: 0; width: 72px; height: 72px;
  border-left: 3px solid var(--orange); border-top: 3px solid var(--orange);
  pointer-events: none; z-index: 1;
}

/* ==========================================================================
   34. PLAKETTE — how AVZ appears on a serviced installation
   ========================================================================== */
.plaque__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: clamp(var(--s8), 6vw, var(--s12)); align-items: center; }
.plaque {
  background: var(--graphit); color: var(--cloud-dancer);
  border: 2px solid var(--orange); padding: var(--s6);
  max-width: 420px; margin-inline: auto;
  box-shadow: 0 24px 60px rgba(24,24,27,.28);
}
.plaque__top { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); margin-bottom: var(--s4); }
.plaque__top img { width: 30px; height: auto; }
.plaque__claim {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.375rem, 2.4vw, 1.875rem); line-height: 1.05;
  text-transform: uppercase; letter-spacing: -.02em;
}
.plaque__rule { height: 3px; background: var(--orange); margin: var(--s4) 0; }
.plaque dl { display: grid; grid-template-columns: auto 1fr; gap: 10px var(--s3); margin: 0; font-size: .6875rem; }
.plaque dt { color: var(--text-on-dark-muted); text-transform: uppercase; letter-spacing: .14em; }
.plaque dd { margin: 0; text-align: right; font-weight: 700; letter-spacing: .06em; }
.plaque__stamp {
  margin-top: var(--s4); border: 1px solid var(--orange); color: var(--orange);
  text-align: center; padding: var(--s2);
  font-family: var(--font-mono); font-size: .75rem; letter-spacing: .22em;
}

/* ==========================================================================
   35. WERTE — rail-docked entries
   ========================================================================== */
.werte { list-style: none; padding: 0; margin: 0; }
.werte__item {
  display: grid; grid-template-columns: 96px minmax(0, 1fr) minmax(0, 1.4fr);
  gap: var(--s4); align-items: baseline;
  padding: var(--s4) var(--s3); border-top: 1px solid var(--line);
  transition: padding-left var(--dur) var(--ease), background var(--dur) var(--ease);
}
.werte__item:hover { padding-left: var(--s6); background: var(--graphit-06); }
.werte__item:last-child { border-bottom: 1px solid var(--line); }
.section--dark .werte__item { border-top-color: var(--line-dark); }
.section--dark .werte__item:last-child { border-bottom-color: var(--line-dark); }
.section--dark .werte__item:hover { background: var(--light-10); }
.werte__n { font-family: var(--font-mono); font-size: .75rem; font-weight: 700; color: var(--text); letter-spacing: .12em; }
.section--dark .werte__n { color: var(--orange); }
.werte__item:hover .werte__n { color: var(--text); }
.werte__t { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.25rem, 2.2vw, 1.875rem); text-transform: uppercase; letter-spacing: -.015em; }
.werte__d { color: var(--text-muted); font-size: .9375rem; }
.section--dark .werte__d { color: var(--text-on-dark-muted); }

/* ==========================================================================
   36. JOB ROWS (homepage teaser)
   ========================================================================== */
.jobrow {
  display: flex; align-items: center; justify-content: space-between; gap: var(--s4);
  padding: var(--s4) var(--s3); border-top: 1px solid var(--line-dark);
  transition: padding-left var(--dur) var(--ease), background var(--dur) var(--ease);
}
.jobrow:last-child { border-bottom: 1px solid var(--line-dark); }
.jobrow:hover { padding-left: var(--s6); background: var(--light-10); }
.jobrow__t { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.125rem, 2vw, 1.625rem); text-transform: uppercase; letter-spacing: -.015em; line-height: 1.1; }
.jobrow__m { font-size: .6875rem; text-transform: uppercase; letter-spacing: .16em; color: var(--text-on-dark-muted); margin-top: 6px; }

/* ==========================================================================
   37. RESPONSIVE — new components
   ========================================================================== */
@media (max-width: 1100px) {
  .hero-v2__grid { grid-template-columns: minmax(0, 1fr); gap: var(--s8); }
  .lift { max-width: 460px; }
  .stmt__grid, .plaque__grid, .branchen { grid-template-columns: minmax(0, 1fr); }
  .reg__head { grid-template-columns: 52px minmax(0, 1fr) 40px; }
  .reg__sub { display: none; }
  .reg__body { grid-template-columns: minmax(0, 1fr); padding-left: 52px; }
  .ascent__step { grid-template-columns: 72px minmax(0, 1fr); }
  .ascent__d { grid-column: 2; padding-top: var(--s1); }
  .werte__item { grid-template-columns: 64px minmax(0, 1fr); }
  .werte__d { grid-column: 2; }
}

@media (max-width: 640px) {
  .reg__head { grid-template-columns: 40px minmax(0, 1fr) 34px; gap: var(--s2); padding-block: var(--s3); }
  .reg__plus { width: 34px; height: 34px; }
  .reg__body { padding-left: 0; }
  .ascent__step { grid-template-columns: minmax(0, 1fr); gap: var(--s2); padding-block: var(--s4); }
  .ascent__n::after { display: none; }
  .werte__item { grid-template-columns: minmax(0, 1fr); gap: var(--s1); }
  .werte__d, .ascent__d { grid-column: auto; }
  .jobrow { flex-direction: column; align-items: flex-start; gap: var(--s2); }
  .plaque { padding: var(--s4); }
}

/* The new register/ascent/werte titles are spans, so they miss the heading
   break rule. German compounds ("Ersatzteile & Modernisierung") would otherwise
   push their grid track wider than a 320px viewport. */
.reg__title, .ascent__t, .werte__t, .jobrow__t,
.branchen__btn, .plaque__claim, .lift__val, .stmt__k {
  overflow-wrap: anywhere;
  hyphens: auto;
}

/* --- narrow-viewport fixes -------------------------------------------------
   1. Tracked-out kickers are single long German words that must be allowed to
      break, and the label bar must be able to wrap away from the text.
   2. The stmt key/value rows need a single column on small screens.
   3. E-mail addresses in the contact card are one unbreakable token.
   4. The industry stage scales its inactive images to 1.04, which spills. */
.kicker { flex-wrap: wrap; overflow-wrap: anywhere; }
.branchen__stage { overflow: hidden; }
.cta-card__val, .cta-card__val a { overflow-wrap: anywhere; }

@media (max-width: 520px) {
  .kicker { letter-spacing: .14em; font-size: .75rem; }
  .stmt__row { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .cta-card { padding: var(--s4) var(--s3); }
  .cta-card__row { gap: var(--s2); }
  .cta-card__val { font-size: 1rem; }
}

/* The send button is a <p> driven by smtp.js, not a <button>. It reuses
   .btn/.btn--primary for its styling and hover; these add what a <p> lacks. */
.customForm {
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
}
.customForm:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }
@media (max-width: 560px) { .customForm { width: 100%; justify-content: center; } }

/* ==========================================================================
   38. SCROLL-TRIGGERED INTROS
   The hero animates on load; everything below animates as it enters the
   viewport. Motion stays mechanical and vertical to match the lift metaphor:
   rows rise, images wipe upward, accent rules draw out from their origin.
   All of it is gated behind html.js, so with JS off nothing is ever hidden.
   ========================================================================== */

/* Base — rise and fade. --d carries the per-item stagger. */
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  transition-delay: var(--d, 0ms);
  will-change: opacity, transform;
}
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal.is-in { will-change: auto; }

/* Wipe upward — for photography. The plate uncovers from its bottom edge,
   the way a tray rises into view. */
.js .reveal--clip {
  opacity: 1;
  transform: none;
  clip-path: inset(100% 0 0 0);
  transition: clip-path 1s var(--ease);
  transition-delay: var(--d, 0ms);
}
.js .reveal--clip.is-in { clip-path: inset(0 0 0 0); }

/* Slight counter-drift on the image inside a wiping plate. */
.js .reveal--clip img { transform: scale(1.06); transition: transform 1.4s var(--ease); transition-delay: var(--d, 0ms); }
.js .reveal--clip.is-in img { transform: none; }

/* Accent rules draw out rather than blink on. */
.js .reveal .kicker::before {
  transform: scaleX(0); transform-origin: left center;
  transition: transform .6s var(--ease);
  transition-delay: calc(var(--d, 0ms) + 160ms);
}
.js .reveal.is-in .kicker::before { transform: none; }

/* The rail marker pops in after its heading has settled. */
.js .reveal .rail-mark::before {
  transform: scale(0); transform-origin: center;
  transition: transform .5s cubic-bezier(.34, 1.56, .64, 1);
  transition-delay: calc(var(--d, 0ms) + 260ms);
}
.js .reveal.is-in .rail-mark::before { transform: none; }

/* Corner brackets draw after the plate has wiped open. */
.js .reveal--clip.framed::before,
.js .reveal--clip.framed::after {
  opacity: 0; transition: opacity .5s var(--ease); transition-delay: calc(var(--d, 0ms) + 620ms);
}
.js .reveal--clip.is-in.framed::before,
.js .reveal--clip.is-in.framed::after { opacity: 1; }

/* Rows travel a shorter distance than blocks. The .is-in counterparts are
   required: without them these selectors outrank `.reveal.is-in` (same
   specificity, declared later) and the rows never return to their resting
   position. */
.js .reg.reveal, .js .werte__item.reveal, .js .ascent__step.reveal, .js .jobrow.reveal {
  transform: translateY(18px);
}
.js .reg.reveal.is-in, .js .werte__item.reveal.is-in,
.js .ascent__step.reveal.is-in, .js .jobrow.reveal.is-in {
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal,
  .js .reveal--clip,
  .js .reveal--clip img,
  .js .reveal .kicker::before,
  .js .reveal .rail-mark::before {
    opacity: 1 !important;
    transform: none !important;
    clip-path: none !important;
    transition: none !important;
  }
}

/* ==========================================================================
   39. LANGUAGE SWITCHER
   German is served from the site root; every other language lives under
   /languages/<code>/. The button shows the planet plus the current language
   in its own name — never a translated one.
   ========================================================================== */
.nav__lang { flex: none; }

.langbtn {
  display: inline-flex; align-items: center; gap: var(--s1);
  padding: 12px var(--s2);
  background: none; border: 1px solid var(--line); cursor: pointer;
  font-family: var(--font-body); font-size: .75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em; color: var(--text);
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease),
              color var(--dur) var(--ease);
}
.langbtn:hover, .langbtn[aria-expanded="true"] {
  border-color: var(--orange); background: var(--orange); color: var(--graphit);
}
.langbtn svg { flex: none; }
.langbtn__name { white-space: nowrap; }

/* Mobile: planet only */
@media (max-width: 768px) {
  .langbtn { padding: 12px; }
  .langbtn__name { display: none; }
}

/* --- popup ---------------------------------------------------------------- */
.langpop {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center;
  padding: var(--s3);
}
.langpop[hidden] { display: none; }

.langpop__backdrop {
  position: absolute; inset: 0;
  background: rgba(24, 24, 27, .78);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  opacity: 0; transition: opacity .3s var(--ease);
}
.langpop.is-open .langpop__backdrop { opacity: 1; }

.langpop__panel {
  position: relative;
  width: 100%; max-width: 760px; max-height: calc(100vh - var(--s8));
  overflow-y: auto;
  background: var(--cloud-dancer); color: var(--text);
  border-top: 3px solid var(--orange);
  box-shadow: 0 32px 80px rgba(24, 24, 27, .45);
  padding: clamp(var(--s4), 4vw, var(--s8));
  opacity: 0; transform: translateY(16px);
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.langpop.is-open .langpop__panel { opacity: 1; transform: none; }

.langpop__head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: var(--s3); margin-bottom: var(--s6);
  border-bottom: 1px solid var(--line); padding-bottom: var(--s3);
}
.langpop__title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  text-transform: uppercase; letter-spacing: -.02em; line-height: 1.05;
}
.langpop__close {
  flex: none; width: 44px; height: 44px; position: relative;
  background: none; border: 1px solid var(--line); cursor: pointer;
  transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.langpop__close::before, .langpop__close::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 16px; height: 2px; background: var(--text);
}
.langpop__close::before { transform: translate(-50%, -50%) rotate(45deg); }
.langpop__close::after  { transform: translate(-50%, -50%) rotate(-45deg); }
.langpop__close:hover { background: var(--orange); border-color: var(--orange); }

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

.langitem {
  display: flex; align-items: baseline; justify-content: space-between; gap: var(--s2);
  padding: var(--s3);
  border-left: 3px solid transparent;
  background: var(--graphit-06);
  transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease),
              padding-left var(--dur) var(--ease);
}
.langitem:hover { background: var(--hellgrau); border-left-color: var(--orange); padding-left: var(--s4); }
.langitem__name { font-weight: 700; font-size: 1rem; overflow-wrap: anywhere; }
.langitem__code {
  font-family: var(--font-mono); font-size: .6875rem; letter-spacing: .1em;
  color: var(--text-muted); flex: none;
}
.langitem.is-current {
  background: var(--graphit); color: var(--cloud-dancer);
  border-left-color: var(--orange);
}
.langitem.is-current .langitem__code { color: var(--orange); }
.langitem.is-current:hover { background: var(--graphit); padding-left: var(--s3); }

@media (max-width: 720px) {
  .langpop__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 460px) {
  .langpop__list { grid-template-columns: minmax(0, 1fr); }
  .langpop { padding: var(--s2); }
}

@media (prefers-reduced-motion: reduce) {
  .langpop__backdrop, .langpop__panel { transition: none; opacity: 1; transform: none; }
}
