/* Shared hub-page design system — used by /wordpress-agentur,
   /typo3-agentur and /woocommerce-agentur via the `extraCSS` frontmatter.

   Design intent — full-dark "developer workshop" aesthetic that breaks
   sharply from the Leistungen / Consulting visual rhythm. Dual-layer
   dark backgrounds, code-grid texture, monospace accents, brand-color
   glows on every interactive element. All selectors are namespaced
   under `.agency-hub` so they cannot leak into the rest of the site.

   Per-hub brand color is selected via a modifier class on the wrapper:
     <div class="agency-hub">                          → WordPress (default)
     <div class="agency-hub agency-hub--typo3">        → TYPO3 orange
     <div class="agency-hub agency-hub--woocommerce">  → WooCommerce purple
   Each modifier overrides the `--brand`, `--brand-soft`, `--brand-deep`
   and `--brand-rgb` tokens on the same element, and the rest of the
   stylesheet reads from those tokens — no inline custom properties.
   `--brand-rgb` is the comma-separated RGB triple of the colour used in
   every translucent rgba() glow / tint / soft-border on the page; it is a
   separate token because rgba() cannot interpolate a hex var. Pick
   whichever of brand / brand-deep reads best as a 5–25 % alpha glow on a
   near-black canvas (vivid for orange/purple, deep for blue).
   To add a new hub, copy one of the modifier blocks below, set its four
   `--brand*` values, and apply the new class on the hub-page wrapper. */

.agency-hub {
  /* Tokens — dual-shade dark palette */
  --hub-bg-base: #0c0c12;
  --hub-bg-card: #14141c;
  --hub-bg-card-elev: #1c1c26;
  --hub-bg-card-hover: #20202c;
  --hub-border: rgba(225, 226, 228, 0.10);
  --hub-border-strong: rgba(225, 226, 228, 0.22);
  --hub-text: #f0f1f3;
  --hub-text-muted: #8e8e9b;
  --hub-text-dim: #5a5a68;

  /* Brand color tokens — overridable per page via the modifier
     classes below (.agency-hub--typo3 / --woocommerce). Defaults:
     WordPress blue. */
  --brand: #2a8bb8;
  --brand-soft: #4ba8d2;
  --brand-deep: #21759b;
  /* RGB triple for rgba() glows/tints — see header comment. */
  --brand-rgb: 33, 117, 155;
  /* Cross-brand accent (red) stays constant — anchors the page to the
     aceArt master palette no matter which hub is rendered. */
  --brand-accent: #f0533e;
}
.agency-hub--typo3 {
  --brand: #FF8700;
  --brand-soft: #FFAB47;
  --brand-deep: #C25700;
  --brand-rgb: 255, 135, 0;
}
.agency-hub--woocommerce {
  --brand: #7F54B3;
  --brand-soft: #9670C9;
  --brand-deep: #5E3C8A;
  --brand-rgb: 127, 84, 179;
}
.agency-hub {

  --hub-mono: 'JetBrains Mono', 'Menlo', 'Monaco', 'Consolas', monospace;

  /* Background texture — fine code-grid */
  --hub-grid: rgba(255, 255, 255, 0.025);
  --hub-grid-strong: rgba(255, 255, 255, 0.04);

  /* Page-level frame */
  background: var(--hub-bg-base);
  color: var(--hub-text);
  position: relative;
  /* `overflow-x: clip` keeps the WORDPRESS bgmark + marquee from escaping
     the viewport horizontally, but unlike `overflow: hidden` it does NOT
     establish a scroll container — so descendants with `position: sticky`
     (the .agency-toc sidebar) keep sticking against the viewport. */
  overflow-x: clip;
}

/* Page-wide subtle dot grid */
.agency-hub::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.04) 1px, transparent 0);
  background-size: 24px 24px;
  pointer-events: none;
  z-index: 0;
}
.agency-hub > * { position: relative; z-index: 1; }

/* All headings are white in dark theme */
.agency-hub h1, .agency-hub h2, .agency-hub h3, .agency-hub h4 {
  color: var(--hub-text);
}

/* ===== HERO ============================================================ */
.agency-hub .agency-hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  /* Generous top breathing room below the fixed header (was 8rem) so the
     hero eyebrow/H1 doesn't sit right under the header — matches the
     extra spacing applied to .page-hero. */
  padding: calc(var(--hdr-h) + 180px) 0 5rem;
  isolation: isolate;
  background:
    radial-gradient(ellipse 60% 50% at 75% 30%, rgba(var(--brand-rgb), 0.18) 0%, transparent 70%),
    radial-gradient(ellipse 80% 60% at 20% 90%, rgba(240, 83, 62, 0.10) 0%, transparent 70%);
}
.agency-hub .agency-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--hub-grid-strong) 1px, transparent 1px),
    linear-gradient(90deg, var(--hub-grid-strong) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 80% at 30% 50%, black 0%, transparent 90%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 30% 50%, black 0%, transparent 90%);
  pointer-events: none;
  z-index: 0;
}

/* Animated thin gradient line at the bottom of the hero */
.agency-hub .agency-hero::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--brand) 30%, var(--brand-accent) 70%, transparent 100%);
  animation: agency-pulse-line 4s ease-in-out infinite;
  z-index: 1;
  pointer-events: none;
}
@keyframes agency-pulse-line {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

.agency-hub .agency-hero__bgmark {
  position: absolute;
  right: -3vw;
  bottom: -6vw;
  font-family: var(--font-bold), system-ui;
  font-weight: 900;
  font-size: clamp(180px, 26vw, 460px);
  letter-spacing: -0.04em;
  line-height: 0.85;
  color: transparent;
  -webkit-text-stroke: 1px rgba(var(--brand-rgb), 0.15);
  white-space: nowrap;
  user-select: none;
  pointer-events: none;
  z-index: 0;
}
.agency-hub .agency-hero__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Eyebrow with blinking cursor accent */
.agency-hub .agency-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--hub-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand-soft);
  margin-bottom: 1.5rem;
  padding: 0.4rem 0.85rem;
  border: 1px solid rgba(var(--brand-rgb), 0.4);
  border-radius: 4px;
  background: rgba(var(--brand-rgb), 0.08);
}
.agency-hub .agency-hero__eyebrow::before {
  content: "▸";
  color: var(--brand);
  font-family: var(--hub-mono);
}
.agency-hub .agency-hero__eyebrow::after {
  content: "_";
  color: var(--brand);
  animation: agency-blink 1.1s steps(2) infinite;
  margin-left: 0.2rem;
}
/* When the eyebrow is a real <a> (spoke pages link back to their hub)
   instead of static text (the hub page itself), signal interactivity. */
a.agency-hub .agency-hero__eyebrow,
.agency-hub a.agency-hero__eyebrow {
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.agency-hub a.agency-hero__eyebrow:hover {
  border-color: rgba(var(--brand-rgb), 0.7);
  background: rgba(var(--brand-rgb), 0.14);
}
@keyframes agency-blink {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

.agency-hub .agency-hero h1 {
  font-family: var(--font-bold), system-ui;
  font-size: clamp(48px, 7.5vw, 104px);
  font-weight: 900;
  line-height: 1.0;
  letter-spacing: -0.03em;
  margin: 0 0 2rem;
  max-width: 18ch;
}
.agency-hub .agency-hero h1 .agency-hero__accent {
  color: var(--brand-accent);
  position: relative;
  display: inline-block;
}
.agency-hub .agency-hero h1 .agency-hero__accent::after {
  content: "";
  position: absolute;
  bottom: 0.05em;
  left: 0;
  right: 0;
  height: 0.15em;
  background: linear-gradient(90deg, var(--brand-accent) 0%, var(--brand) 100%);
  opacity: 0.4;
  pointer-events: none;
}
.agency-hub .agency-hero__lead {
  font-size: clamp(18px, 1.6vw, 22px);
  line-height: 1.6;
  color: var(--hub-text-muted);
  max-width: 56ch;
  margin: 0 0 2.5rem;
}

/* Meta strip — terminal-style chips */
.agency-hub .agency-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 0 0 2.5rem;
  padding: 0;
  list-style: none;
  max-width: 880px;
}
.agency-hub .agency-hero__meta-item {
  flex: 0 1 auto;
  min-width: 0;
  padding: 0.85rem 1.1rem;
  background: rgba(20, 20, 28, 0.6);
  border: 1px solid var(--hub-border);
  border-radius: 6px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  transition: border-color 0.2s, background 0.2s;
}
.agency-hub .agency-hero__meta-item:hover {
  border-color: rgba(var(--brand-rgb), 0.5);
  background: rgba(var(--brand-rgb), 0.08);
}
.agency-hub .agency-hero__meta-key {
  font-family: var(--hub-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--hub-text-dim);
}
.agency-hub .agency-hero__meta-val {
  font-size: 16px;
  font-weight: 600;
  color: var(--hub-text);
}

/* ===== LAYOUT FRAME (TOC + main column) =============================== */
.agency-hub .agency-frame {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 4rem;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 2rem;
}
.agency-hub .agency-frame > * { min-width: 0; }
@media (max-width: 1024px) {
  .agency-hub .agency-frame { grid-template-columns: minmax(0, 1fr); gap: 0; }
}

/* TOC — command-palette style */
.agency-hub .agency-toc {
  position: sticky;
  top: 140px;
  align-self: start;
  /* Initial breathing room before sticky kicks in: the TOC sits inside the
     same grid row as the first .agency-section, so without a top margin it
     would visually butt up against that section's heading. ~5rem matches
     the section's own top padding so the TOC starts where the section
     content starts, not at the section's top edge. */
  margin-top: 5rem;
  font-family: var(--hub-mono);
  font-size: 12.5px;
  line-height: 1.6;
  padding: 1.25rem 1.1rem;
  background: rgba(20, 20, 28, 0.5);
  border: 1px solid var(--hub-border);
  border-radius: 8px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.agency-hub .agency-toc__label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--hub-text-dim);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--hub-border);
}
/* aceArt Pik (spade) glyph in the brand-color, used as the heading
   marker. The Pik SVG is loaded as a CSS mask so we can repaint it via
   `background-color` — that way the same asset works for the WordPress
   blue / TYPO3 orange / WooCommerce purple variants of this design
   system, just by changing the brand-color token. */
.agency-hub .agency-toc__label::before {
  content: "";
  display: inline-block;
  width: 11px;
  height: 12px;
  background-color: var(--brand);
  -webkit-mask: url('/assets/images/aceart-ace-red-pik.svg') no-repeat center / contain;
          mask: url('/assets/images/aceart-ace-red-pik.svg') no-repeat center / contain;
  flex-shrink: 0;
}
.agency-hub .agency-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
}
.agency-hub .agency-toc li {
  counter-increment: toc;
  margin-bottom: 0.6rem;
}
.agency-hub .agency-toc a {
  color: var(--hub-text-muted);
  text-decoration: none;
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.25rem 0;
  transition: color 0.2s;
  border-radius: 3px;
}
.agency-hub .agency-toc a::before {
  content: counter(toc, decimal-leading-zero);
  color: var(--brand);
  font-weight: 700;
  font-size: 11px;
  flex-shrink: 0;
}
.agency-hub .agency-toc a:hover {
  color: var(--hub-text);
}
.agency-hub .agency-toc a:hover::before { color: var(--brand-accent); }
/* Active state — set by inline scroll-spy script. The link is highlighted
   white + bold and the leading "01" counter turns red, mirroring the
   visual signal of the brand-color accent used elsewhere on the page. */
.agency-hub .agency-toc a.is-active {
  color: var(--hub-text);
  font-weight: 700;
}
.agency-hub .agency-toc a.is-active::before {
  color: var(--brand-accent);
}
@media (max-width: 1024px) {
  .agency-hub .agency-toc { display: none; }
}

/* ===== MAIN COLUMN SECTIONS =========================================== */
.agency-hub .agency-section {
  padding: 5rem 0;
  position: relative;
  scroll-margin-top: 100px;
}
.agency-hub .agency-section + .agency-section {
  border-top: 1px solid var(--hub-border);
}
/* Subtle gradient fade above each section divider */
.agency-hub .agency-section + .agency-section::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
  opacity: 0.6;
  pointer-events: none;
}

.agency-hub .agency-section__eyebrow {
  font-family: var(--hub-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brand-soft);
  font-weight: 500;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.agency-hub .agency-section__eyebrow::before {
  content: "//";
  color: var(--hub-text-dim);
  font-weight: 400;
}

.agency-hub .agency-section h2 {
  font-family: var(--font-bold), system-ui;
  font-size: clamp(32px, 4.2vw, 56px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 2rem;
  max-width: 24ch;
}
.agency-hub .agency-section__lead {
  font-size: 19px;
  line-height: 1.6;
  color: var(--hub-text-muted);
  max-width: 60ch;
  margin: 0 0 3rem;
}
.agency-hub .agency-section__lead strong {
  color: var(--hub-text);
  font-weight: 600;
  background: linear-gradient(transparent 65%, rgba(var(--brand-rgb), 0.25) 65%);
}

/* Inline links inside spoke body copy (e.g. "Ähnliche Themen" cross-links,
   or a link up to a general Leistungen page) — the hub's own hand-authored
   content never has inline links in running prose, so this pattern didn't
   exist yet. */
.agency-hub .agency-section__lead a {
  color: var(--brand-soft);
  text-decoration: underline;
  text-decoration-color: rgba(var(--brand-rgb), 0.5);
  text-underline-offset: 2px;
  transition: color 0.2s, text-decoration-color 0.2s;
}
.agency-hub .agency-section__lead a:hover {
  color: var(--hub-text);
  text-decoration-color: var(--brand-accent);
}

/* ===== SPOKE SUB-HEADINGS (h3/h4 inside a spoke .agency-section) ====== */
.agency-hub .agency-section__subhead {
  font-family: var(--font-bold), system-ui;
  font-weight: 800;
  color: var(--hub-text);
  letter-spacing: -0.01em;
  margin: 2.5rem 0 1rem;
}
.agency-hub .agency-section__subhead:first-child { margin-top: 0; }
h3.agency-section__subhead { font-size: clamp(20px, 2.2vw, 26px); }
h4.agency-section__subhead { font-size: 18px; margin-top: 2rem; }

/* ===== SPOKE CHECKLIST — bullet lists inside a spoke .agency-section = */
.agency-hub .agency-checklist {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.agency-hub .agency-checklist li {
  position: relative;
  padding: 1rem 1.25rem 1rem 2.75rem;
  background: var(--hub-bg-card);
  border: 1px solid var(--hub-border);
  border-radius: 8px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--hub-text-muted);
}
.agency-hub .agency-checklist li::before {
  content: "→";
  position: absolute;
  left: 1.1rem;
  top: 1rem;
  color: var(--brand);
  font-weight: 700;
}
.agency-hub .agency-checklist li strong {
  color: var(--hub-text);
  font-weight: 700;
}

/* ===== SPOKE INLINE IMAGE ============================================= */
.agency-hub .agency-section__img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 2rem 0;
  border-radius: 12px;
  border: 1px solid var(--hub-border);
}

/* ===== MANIFEST PULL-QUOTE ============================================ */
.agency-hub .agency-quote {
  position: relative;
  padding: 2.5rem 2rem 2rem 2.5rem;
  margin: 2rem 0 0;
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.08) 0%, transparent 60%);
  border-left: 3px solid var(--brand);
  border-radius: 0 8px 8px 0;
}
.agency-hub .agency-quote::before {
  content: "“";
  position: absolute;
  top: -10px;
  left: 12px;
  font-size: 80px;
  font-family: Georgia, serif;
  color: var(--brand);
  line-height: 1;
  opacity: 0.6;
}
.agency-hub .agency-quote p {
  font-family: var(--font-bold), system-ui;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.4;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--hub-text);
  margin: 0;
}

/* ===== CAPABILITY MATRIX ============================================= */
.agency-hub .agency-matrix {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 0;
  margin-top: 2rem;
  border: 1px solid var(--hub-border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--hub-bg-card);
}
.agency-hub .agency-matrix__row {
  display: contents;
}
.agency-hub .agency-matrix__row > * {
  padding: 1.5rem 1.75rem;
  border-bottom: 1px solid var(--hub-border);
  transition: background 0.25s;
}
.agency-hub .agency-matrix__row:last-child > * { border-bottom: none; }
.agency-hub .agency-matrix__row:hover > * { background: var(--hub-bg-card-elev); }
.agency-hub .agency-matrix__key {
  font-family: var(--hub-mono);
  font-weight: 600;
  font-size: 14px;
  color: var(--brand-soft);
  letter-spacing: -0.005em;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}
.agency-hub .agency-matrix__key::before {
  content: "→";
  color: var(--hub-text-dim);
  font-weight: 400;
}
.agency-hub .agency-matrix__val {
  font-size: 16px;
  line-height: 1.6;
  color: var(--hub-text-muted);
}
@media (max-width: 640px) {
  .agency-hub .agency-matrix { grid-template-columns: 1fr; }
  .agency-hub .agency-matrix__row > * {
    padding: 0.85rem 1.25rem;
    border-bottom: none;
  }
  .agency-hub .agency-matrix__row > *:first-child { padding-top: 1.5rem; }
  .agency-hub .agency-matrix__row > *:last-child {
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--hub-border);
  }
  .agency-hub .agency-matrix__row:last-child > *:last-child { border-bottom: none; }
  .agency-hub .agency-matrix__key {
    color: var(--brand-soft);
    font-size: 12px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: -0.25rem;
  }
}

/* ===== TIMELINE — CI/CD pipeline aesthetic ============================ */
.agency-hub .agency-timeline {
  position: relative;
  margin-top: 2rem;
  padding-left: 3rem;
}
.agency-hub .agency-timeline::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 14px;
  bottom: 14px;
  width: 2px;
  background: linear-gradient(to bottom,
    var(--brand) 0%,
    var(--brand) 60%,
    var(--brand-accent) 100%);
  opacity: 0.7;
}
.agency-hub .agency-timeline__step {
  position: relative;
  padding: 0 0 2.75rem;
}
.agency-hub .agency-timeline__step:last-child { padding-bottom: 0; }
.agency-hub .agency-timeline__step::before {
  content: "";
  position: absolute;
  left: -3rem;
  top: 4px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--hub-bg-base);
  border: 2px solid var(--brand);
  box-shadow:
    0 0 0 4px var(--hub-bg-base),
    0 0 16px rgba(var(--brand-rgb), 0.4);
}
.agency-hub .agency-timeline__step::after {
  content: "";
  position: absolute;
  left: calc(-3rem + 11px);
  top: 15px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 8px var(--brand);
  animation: agency-pulse-dot 2s ease-in-out infinite;
}
@keyframes agency-pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.7); }
}
.agency-hub .agency-timeline__num {
  font-family: var(--hub-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-soft);
  margin-bottom: 0.5rem;
}
.agency-hub .agency-timeline__title {
  font-family: var(--font-bold), system-ui;
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 0.65rem;
  color: var(--hub-text);
  letter-spacing: -0.01em;
}
.agency-hub .agency-timeline__body {
  font-size: 17px;
  line-height: 1.65;
  color: var(--hub-text-muted);
  margin: 0;
  max-width: 60ch;
}

/* ===== PROJECT GRID — asymmetric cards with blue selection markers ==== */
.agency-hub .agency-projects {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 1.25rem;
  margin-top: 2rem;
}
.agency-hub .agency-project {
  position: relative;
  display: block;
  aspect-ratio: 16 / 11;
  border-radius: 12px;
  overflow: hidden;
  background: var(--hub-bg-card);
  border: 1px solid var(--hub-border);
  text-decoration: none;
  min-width: 0;
  transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.3, 1),
              border-color 0.4s,
              box-shadow 0.4s;
}
.agency-hub .agency-project--feature {
  grid-column: span 2;
  grid-row: span 2;
  aspect-ratio: 4 / 3;
}
/* Blue selection-bracket corners */
.agency-hub .agency-project::before,
.agency-hub .agency-project::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border: 2px solid var(--brand);
  opacity: 0;
  transition: opacity 0.4s, transform 0.4s;
  z-index: 2;
  pointer-events: none;
}
.agency-hub .agency-project::before {
  top: 8px; left: 8px;
  border-right: none; border-bottom: none;
  transform: translate(8px, 8px);
}
.agency-hub .agency-project::after {
  bottom: 8px; right: 8px;
  border-left: none; border-top: none;
  transform: translate(-8px, -8px);
}
.agency-hub .agency-project:hover {
  border-color: var(--brand);
  box-shadow: 0 16px 40px rgba(var(--brand-rgb), 0.25);
  transform: translateY(-2px);
}
.agency-hub .agency-project:hover::before,
.agency-hub .agency-project:hover::after {
  opacity: 1;
  transform: translate(0, 0);
}
.agency-hub .agency-project img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.3, 1),
              filter 0.4s;
  filter: saturate(0.85);
}
.agency-hub .agency-project:hover img {
  transform: scale(1.04);
  filter: saturate(1);
}
.agency-hub .agency-project__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(to top,
    rgba(12, 12, 18, 0.95) 0%,
    rgba(12, 12, 18, 0.6) 40%,
    transparent 90%);
  color: var(--hub-text);
}
.agency-hub .agency-project__title {
  font-family: var(--font-bold), system-ui;
  font-size: 20px;
  font-weight: 800;
  margin: 0;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.agency-hub .agency-project--feature .agency-project__title { font-size: 30px; }
.agency-hub .agency-project__tag {
  display: inline-block;
  font-family: var(--hub-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--brand-soft);
  margin-bottom: 0.5rem;
}
@media (max-width: 980px) {
  .agency-hub .agency-projects { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .agency-hub .agency-project--feature { grid-column: span 2; grid-row: auto; aspect-ratio: 16 / 10; }
  .agency-hub .agency-project--feature .agency-project__title { font-size: 24px; }
}
@media (max-width: 560px) {
  .agency-hub .agency-projects { grid-template-columns: minmax(0, 1fr); }
  .agency-hub .agency-project--feature { grid-column: auto; }
}

/* ===== CUSTOMER MARQUEE — dark chip strip ============================= */
.agency-hub .agency-marquee {
  margin-top: 2rem;
  overflow: hidden;
  position: relative;
  padding: 1rem 0;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}
.agency-hub .agency-marquee__track {
  display: flex;
  gap: 1.25rem;
  width: max-content;
  animation: agency-marquee 42s linear infinite;
}
.agency-hub .agency-marquee:hover .agency-marquee__track { animation-play-state: paused; }
/* White plate, brand-natural logo. The earlier `brightness(0) invert(1)`
   silhouette treatment collapsed multi-coloured logos (e.g. KlettMEX,
   which has red, navy, light-grey and white internal elements) into a
   single white blob with no internal contrast — the brand became
   unrecognisable. Switching to white plates mirrors the proven pattern
   on /agentur/netzwerk and keeps every customer logo readable. */
.agency-hub .agency-marquee__item {
  flex-shrink: 0;
  height: 80px;
  width: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem;
  background: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  transition: transform 0.3s, box-shadow 0.3s;
}
.agency-hub .agency-marquee__item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(var(--brand-rgb), 0.25);
}
.agency-hub .agency-marquee__item img {
  height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  /* Subtle desaturation at rest gives the strip visual cohesion; full
     colour on hover so the user can see the actual brand. */
  filter: grayscale(70%);
  opacity: 0.85;
  transition: opacity 0.3s, filter 0.3s;
}
.agency-hub .agency-marquee__item:hover img {
  filter: grayscale(0%);
  opacity: 1;
}
@keyframes agency-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .agency-hub .agency-marquee__track { animation: none; }
}

/* ===== PAGE-BUILDER PILLS — terminal chips ============================ */
.agency-hub .agency-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.5rem;
}
.agency-hub .agency-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 1.1rem;
  border: 1px solid var(--hub-border);
  border-radius: 6px;
  font-family: var(--hub-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--hub-text-muted);
  background: var(--hub-bg-card);
  transition: border-color 0.25s, color 0.25s, background 0.25s;
}
.agency-hub .agency-pill:hover {
  border-color: var(--brand);
  color: var(--hub-text);
  background: var(--hub-bg-card-elev);
}
.agency-hub .agency-pill::before {
  content: ">";
  color: var(--brand);
  font-weight: 700;
}

/* ===== FAQ — code-comment-style numbering ============================= */
.agency-hub .agency-faq { margin-top: 2rem; }
.agency-hub .agency-faq details {
  border: 1px solid var(--hub-border);
  border-radius: 8px;
  background: var(--hub-bg-card);
  margin-bottom: 0.65rem;
  overflow: hidden;
  transition: border-color 0.25s;
}
.agency-hub .agency-faq details[open] {
  border-color: rgba(var(--brand-rgb), 0.45);
  background: var(--hub-bg-card-elev);
}
.agency-hub .agency-faq summary {
  cursor: pointer;
  list-style: none;
  font-family: var(--font-bold), system-ui;
  font-size: 18px;
  font-weight: 700;
  color: var(--hub-text);
  display: grid;
  grid-template-columns: 36px 1fr 32px;
  gap: 1rem;
  align-items: center;
  padding: 1.5rem 1.75rem;
  position: relative;
  transition: background 0.2s;
}
.agency-hub .agency-faq summary:hover { background: rgba(var(--brand-rgb), 0.05); }
.agency-hub .agency-faq summary::-webkit-details-marker { display: none; }
.agency-hub .agency-faq details {
  counter-increment: agency-faq-counter;
}
.agency-hub .agency-faq { counter-reset: agency-faq-counter; }
.agency-hub .agency-faq summary::before {
  content: counter(agency-faq-counter, decimal-leading-zero);
  font-family: var(--hub-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--brand-soft);
  letter-spacing: 0.05em;
}
.agency-hub .agency-faq summary::after {
  content: "+";
  font-family: var(--font-bold), system-ui;
  font-size: 26px;
  font-weight: 400;
  color: var(--brand);
  text-align: center;
  line-height: 1;
  transition: transform 0.25s;
  justify-self: center;
}
.agency-hub .agency-faq details[open] summary::after { content: "−"; }
.agency-hub .agency-faq__body {
  padding: 0 1.75rem 1.5rem 4rem;
  color: var(--hub-text-muted);
  font-size: 16.5px;
  line-height: 1.65;
  max-width: 70ch;
}
.agency-hub .agency-faq__body a.agency-faq__deeplink {
  /* Block-level flex so the chip sits on its own line below the answer
     text instead of trailing inline (where `margin-top` would have no
     effect and the line-height of the preceding paragraph would push
     the chip down awkwardly). `width: fit-content` keeps the chip only
     as wide as its label. */
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1rem;
  font-family: var(--hub-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--brand-soft);
  text-decoration: none;
  padding: 0.4rem 0.8rem;
  border: 1px solid rgba(var(--brand-rgb), 0.3);
  border-radius: 4px;
  transition: background 0.2s, color 0.2s;
}
.agency-hub .agency-faq__body a.agency-faq__deeplink::before {
  content: "→";
  color: var(--brand);
}
.agency-hub .agency-faq__body a.agency-faq__deeplink:hover {
  color: var(--hub-text);
  background: rgba(var(--brand-rgb), 0.15);
}
@media (max-width: 640px) {
  .agency-hub .agency-faq summary {
    grid-template-columns: 30px 1fr 24px;
    padding: 1.25rem 1.25rem;
    font-size: 16px;
    gap: 0.75rem;
  }
  .agency-hub .agency-faq__body { padding: 0 1.25rem 1.25rem 3rem; }
}

/* ===== SPOKE TILES — module cards ===================================== */
.agency-hub .agency-spokes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}
.agency-hub .agency-spoke {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  padding: 2.25rem 2rem;
  border-radius: 12px;
  border: 1px solid var(--hub-border);
  text-decoration: none;
  background: var(--hub-bg-card);
  overflow: hidden;
  transition: transform 0.35s, border-color 0.35s, box-shadow 0.35s;
  isolation: isolate;
}
.agency-hub .agency-spoke::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 100% 0%, rgba(var(--brand-rgb), 0.18) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.4s;
  z-index: -1;
  pointer-events: none;
}
.agency-hub .agency-spoke:hover {
  transform: translateY(-4px);
  border-color: var(--brand);
  box-shadow: 0 16px 40px rgba(var(--brand-rgb), 0.22);
}
.agency-hub .agency-spoke:hover::before { opacity: 1; }
.agency-hub .agency-spoke__num {
  font-family: var(--hub-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--brand-soft);
  margin-bottom: 0.4rem;
  text-transform: uppercase;
}
.agency-hub .agency-spoke__title {
  font-family: var(--font-bold), system-ui;
  font-size: 22px;
  font-weight: 800;
  color: var(--hub-text);
  margin: 0 0 0.6rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
}
.agency-hub .agency-spoke__desc {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--hub-text-muted);
  margin: 0;
  flex: 1;
}
.agency-hub .agency-spoke__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--hub-mono);
  font-weight: 600;
  color: var(--brand-soft);
  font-size: 13px;
  margin-top: 0.5rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.agency-hub .agency-spoke__cta::after {
  content: "→";
  transition: transform 0.25s;
  color: var(--brand);
}
.agency-hub .agency-spoke:hover .agency-spoke__cta { color: var(--hub-text); }
.agency-hub .agency-spoke:hover .agency-spoke__cta::after { transform: translateX(6px); color: var(--brand-accent); }
@media (max-width: 640px) {
  .agency-hub .agency-spokes { grid-template-columns: 1fr; }
}

/* ===== CONTACT CARD =================================================== */
.agency-hub .agency-contact {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 2.5rem;
  align-items: center;
  margin-top: 2rem;
  padding: 2.5rem;
  background: var(--hub-bg-card-elev);
  border: 1px solid var(--hub-border);
  border-radius: 14px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.agency-hub .agency-contact::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--brand-rgb), 0.45) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}
.agency-hub .agency-contact::after {
  content: "";
  position: absolute;
  bottom: -80px;
  left: -80px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240, 83, 62, 0.18) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}
.agency-hub .agency-contact img {
  width: 100%;
  border-radius: 10px;
  display: block;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.6);
}
.agency-hub .agency-contact__role {
  font-family: var(--hub-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-soft);
  margin: 0 0 0.65rem;
}
.agency-hub .agency-contact__name {
  font-family: var(--font-bold), system-ui;
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 900;
  line-height: 1.05;
  color: var(--hub-text);
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
}
.agency-hub .agency-contact__pitch {
  font-size: 17.5px;
  line-height: 1.6;
  color: var(--hub-text-muted);
  margin: 0 0 1.75rem;
  max-width: 52ch;
}
@media (max-width: 720px) {
  .agency-hub .agency-contact {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 2rem;
  }
  .agency-hub .agency-contact img { max-width: 220px; margin: 0 auto; }
  .agency-hub .agency-contact__pitch { margin-inline: auto; }
}

/* ===== FINAL CTA STRIP =============================================== */
.agency-hub .agency-cta-strip {
  background:
    radial-gradient(ellipse 50% 80% at 50% 0%, rgba(var(--brand-rgb), 0.18) 0%, transparent 70%),
    var(--hub-bg-card);
  padding: 4.5rem 2rem;
  text-align: center;
  border-top: 1px solid var(--hub-border);
  margin-top: 4rem;
  position: relative;
  overflow: hidden;
}
.agency-hub .agency-cta-strip::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--hub-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--hub-grid) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.6;
  pointer-events: none;
}
.agency-hub .agency-cta-strip > * { position: relative; }
.agency-hub .agency-cta-strip h2 {
  font-family: var(--font-bold), system-ui;
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 900;
  margin: 0 0 1rem;
  line-height: 1.1;
  color: var(--hub-text);
  letter-spacing: -0.02em;
}
.agency-hub .agency-cta-strip p {
  font-size: 18px;
  color: var(--hub-text-muted);
  margin: 0 auto 2rem;
  max-width: 50ch;
  line-height: 1.55;
}

/* ===== RESPONSIVE TWEAKS ============================================== */
@media (max-width: 980px) {
  .agency-hub .agency-section { padding: 4rem 0; }
  .agency-hub .agency-hero { min-height: 75vh; padding: calc(var(--hdr-h) + 120px) 0 4rem; }
}
@media (max-width: 640px) {
  .agency-hub .agency-section { padding: 3rem 0; }
  .agency-hub .agency-hero { min-height: auto; padding: calc(var(--hdr-h) + 90px) 0 3.5rem; }
  .agency-hub .agency-hero__inner { padding: 0 1.25rem; }
  .agency-hub .agency-frame { padding: 0 1.25rem; }
  .agency-hub .agency-hero__meta { gap: 0.5rem; }
  .agency-hub .agency-hero__meta-item { padding: 0.65rem 0.85rem; flex: 1 1 calc(50% - 0.25rem); }
  .agency-hub .agency-hero__meta-key { font-size: 10px; }
  .agency-hub .agency-hero__meta-val { font-size: 14px; }
  .agency-hub .agency-quote { padding: 2rem 1.25rem 1.5rem 1.75rem; }
  .agency-hub .agency-timeline { padding-left: 2.25rem; }
  .agency-hub .agency-timeline__step::before {
    left: calc(-2.25rem + 4px);
    width: 22px;
    height: 22px;
    box-shadow: 0 0 0 3px var(--hub-bg-base), 0 0 12px rgba(var(--brand-rgb), 0.4);
  }
  .agency-hub .agency-timeline__step::after {
    left: calc(-2.25rem + 12px);
    top: 12px;
    width: 6px;
    height: 6px;
  }
  .agency-hub .agency-timeline__title { font-size: 20px; }
  .agency-hub .agency-cta-strip { padding: 3rem 1.5rem; }
}
