@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/space-grotesk-400.ttf") format("truetype");
}

@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/space-grotesk-500.ttf") format("truetype");
}

@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/space-grotesk-600.ttf") format("truetype");
}

@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/space-grotesk-700.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-400.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-500.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-600.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-700.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/ibm-plex-mono-400.ttf") format("truetype");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/ibm-plex-mono-500.ttf") format("truetype");
}

  :root {
    --bg: #ffffff;
    --bg-soft: #f5f4f9;
    --bg-lav: #efecf8;
    --ink: #16131f;
    --ink-soft: #45415a;
    --muted: #76728a;
    --line: #e7e4f0;
    --line-soft: #efedf5;
    --accent: #4f2cae;
    --accent-2: #6a40dd;
    --accent-soft: #ece6fb;
    --dark: #140f2c;
    --dark-2: #1d1740;
    --dark-line: #322a55;
    --dark-ink: #ffffff;
    --dark-muted: #a7a1c4;

    --ff-head: "Space Grotesk", system-ui, sans-serif;
    --ff-body: "IBM Plex Sans", system-ui, sans-serif;
    --ff-mono: "IBM Plex Mono", ui-monospace, monospace;

    --maxw: 1200px;
    --radius: 14px;
    --radius-sm: 10px;
  }

  * { box-sizing: border-box; }

  html { scroll-behavior: smooth; }

  body {
    margin: 0;
    font-family: var(--ff-body);
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }

  h1, h2, h3, h4 {
    font-family: var(--ff-head);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin: 0;
  }

  p { margin: 0; }
  a { color: inherit; text-decoration: none; }

  :focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 4px;
  }

  .skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 100;
    padding: 10px 14px;
    border-radius: 10px;
    background: var(--dark);
    color: #fff;
    font-weight: 600;
    transform: translateY(-140%);
    transition: transform .18s ease;
  }
  .skip-link:focus-visible { transform: translateY(0); }
  main:focus { outline: none; }

  .wrap {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 40px;
  }

  .eyebrow {
    font-family: var(--ff-mono);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--accent);
    margin: 0 0 18px;
  }

  .btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--ff-body);
    font-weight: 600;
    font-size: 15px;
    padding: 14px 24px;
    border-radius: 10px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease;
  }
  .btn svg { width: 17px; height: 17px; transition: transform .2s ease; }
  .btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 8px 22px -10px rgba(79,44,174,.7);
  }
  .btn-primary:hover { background: var(--accent-2); transform: translateY(-2px); }
  .btn-primary:hover svg { transform: translateX(4px); }
  .btn-ghost {
    background: transparent;
    color: var(--ink);
    border-color: var(--line);
  }
  .btn-ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
  .phil-cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
  .philosophy .btn-dl {
    color: #fff;
    border-color: rgba(255,255,255,.28);
    background: rgba(255,255,255,.04);
  }
  .philosophy .btn-dl:hover {
    color: #fff;
    border-color: rgba(255,255,255,.6);
    background: rgba(255,255,255,.12);
    transform: translateY(-2px);
  }
  .btn-dl:hover svg { transform: translateY(3px); }

  /* ---------- Header ---------- */
  header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255,255,255,.82);
    backdrop-filter: saturate(140%) blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color .25s ease, box-shadow .25s ease;
  }
  header.scrolled {
    border-color: var(--line);
    box-shadow: 0 6px 24px -18px rgba(20,15,44,.4);
  }
  .nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 78px;
  }
  .brand { display: flex; align-items: center; gap: 13px; }
  .brand-mark {
    width: 42px; height: 42px;
    border-radius: 11px;
    background: linear-gradient(150deg, var(--accent) 0%, var(--accent-2) 100%);
    display: grid; place-items: center;
    color: #fff;
    box-shadow: 0 8px 20px -10px rgba(79,44,174,.8);
  }
  .brand-mark svg { width: 22px; height: 22px; }
  .brand-name { display: block; font-family: var(--ff-head); font-weight: 600; font-size: 17px; letter-spacing: -0.01em; line-height: 1.1; }
  .brand-sub { display: block; font-size: 12px; color: var(--muted); letter-spacing: .02em; }

  .nav-links { display: flex; align-items: center; gap: 28px; }
  .nav-links a {
    position: relative;
    font-size: 15px;
    font-weight: 500;
    color: var(--ink-soft);
    padding: 4px 0;
    transition: color .18s ease;
  }
  .nav-links a::after {
    content: "";
    position: absolute;
    left: 0; bottom: -2px;
    width: 0; height: 2px;
    background: var(--accent);
    transition: width .22s ease;
  }
  .nav-links a:hover { color: var(--ink); }
  .nav-links a:hover::after,
  .nav-links a.active::after { width: 100%; }
  .nav-links a.active { color: var(--ink); }

  .nav-right { display: flex; align-items: center; gap: 22px; }
  .menu-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 6px; color: var(--ink); }
  .menu-toggle svg { width: 26px; height: 26px; }

  /* ---------- Hero ---------- */
  .hero {
    position: relative;
    background: linear-gradient(180deg, var(--bg-lav) 0%, var(--bg-soft) 100%);
    overflow: hidden;
  }
  .hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 30px;
    align-items: center;
    min-height: 560px;
    padding-top: 78px;
    padding-bottom: 86px;
  }
  .hero h1 {
    font-size: clamp(34px, 4.3vw, 52px);
    margin: 0 0 24px;
  }
  .hero h1 .em { color: var(--accent); }
  .hero-lead {
    font-size: 18px;
    color: var(--ink-soft);
    max-width: 460px;
    margin-bottom: 34px;
  }
  .hero-cta { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 48px; }

  .trust {
    display: flex;
    flex-wrap: wrap;
    gap: 38px;
  }
  .trust-item { display: flex; align-items: flex-start; gap: 12px; max-width: 220px; }
  .trust-ic {
    flex: none;
    color: var(--accent);
    margin-top: 2px;
  }
  .trust-ic svg { width: 22px; height: 22px; }
  .trust-t { font-family: var(--ff-head); font-weight: 600; font-size: 15px; }
  .trust-d { font-size: 13px; color: var(--muted); line-height: 1.45; }

  /* Hero visual: code window */
  .hero-visual { position: relative; }
  .code-window {
    background: #1a1538;
    border-radius: 16px;
    box-shadow: 0 40px 80px -30px rgba(20,15,44,.6), 0 0 0 1px rgba(255,255,255,.04);
    overflow: hidden;
    transform: perspective(1400px) rotateY(-9deg) rotateX(3deg);
    transition: transform .5s cubic-bezier(.2,.7,.2,1);
  }
  .hero-visual:hover .code-window { transform: perspective(1400px) rotateY(-5deg) rotateX(1.5deg); }
  .cw-bar {
    display: flex; align-items: center; gap: 8px;
    padding: 14px 16px;
    background: rgba(255,255,255,.03);
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .cw-dot { width: 12px; height: 12px; border-radius: 50%; }
  .cw-dot.r { background: #ff5f57; }
  .cw-dot.y { background: #febc2e; }
  .cw-dot.g { background: #28c840; }
  .cw-file {
    margin-left: 12px;
    font-family: var(--ff-mono);
    font-size: 12px;
    color: var(--dark-muted);
  }
  .cw-body {
    display: grid;
    grid-template-columns: 44px 1fr;
    font-family: var(--ff-mono);
    font-size: 13px;
    line-height: 1.85;
    padding: 18px 0 22px;
  }
  .cw-ln { text-align: right; padding-right: 16px; color: rgba(167,161,196,.35); user-select: none; }
  .cw-code { padding-right: 22px; white-space: pre; overflow: hidden; color: #d7d3ec; }
  .cw-code .ln { display: block; }
  .cw-code .i1 { padding-left: 2ch; }
  .cw-code .i2 { padding-left: 4ch; }
  .cw-code .i3 { padding-left: 6ch; }
  .cw-code .i4 { padding-left: 8ch; }
  .t-key { color: #c792ea; }
  .t-fn { color: #82aaff; }
  .t-str { color: #c3e88d; }
  .t-cls { color: #ffcb6b; }
  .t-com { color: #6b6594; font-style: italic; }
  .t-num { color: #f78c6c; }
  .t-pl { color: #d7d3ec; }

  .cw-cursor {
    display: inline-block;
    width: 8px; height: 16px;
    background: var(--accent-2);
    vertical-align: -3px;
    animation: blink 1.1s steps(2, start) infinite;
  }
  @keyframes blink { 50% { opacity: 0; } }

  .hero-badge {
    position: absolute;
    left: -26px; bottom: 36px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 13px 17px;
    display: flex; align-items: center; gap: 12px;
    box-shadow: 0 24px 50px -24px rgba(20,15,44,.45);
  }
  .hero-badge .pulse {
    width: 10px; height: 10px; border-radius: 50%;
    background: #28c840;
    box-shadow: 0 0 0 0 rgba(40,200,64,.5);
    animation: pulse 2s infinite;
  }
  @keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(40,200,64,.5); }
    70% { box-shadow: 0 0 0 9px rgba(40,200,64,0); }
    100% { box-shadow: 0 0 0 0 rgba(40,200,64,0); }
  }
  .hero-badge b { font-family: var(--ff-head); font-size: 14px; }
  .hero-badge span { font-size: 12px; color: var(--muted); display: block; }

  /* ---------- Sections ---------- */
  section { scroll-margin-top: 90px; }
  .pad { padding: 96px 0; }
  .section-head { margin-bottom: 52px; max-width: 620px; }
  .section-head h2 { font-size: clamp(30px, 3.5vw, 40px); }

  /* Services */
  .services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
  .svc-card {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 30px 28px 26px;
    display: flex;
    flex-direction: column;
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
  }
  .svc-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 26px 50px -28px rgba(20,15,44,.4);
    border-color: var(--accent-soft);
  }
  .svc-ic {
    width: 52px; height: 52px;
    border-radius: 12px;
    background: var(--accent-soft);
    color: var(--accent);
    display: grid; place-items: center;
    margin-bottom: 22px;
    transition: background .22s ease, color .22s ease;
  }
  .svc-card:hover .svc-ic { background: var(--accent); color: #fff; }
  .svc-ic svg { width: 25px; height: 25px; }
  .svc-card h3 { font-size: 19px; margin-bottom: 12px; }
  .svc-card p { font-size: 14.5px; color: var(--muted); line-height: 1.55; flex: 1; }
  .svc-link {
    margin-top: 22px;
    color: var(--accent);
    display: inline-flex; align-items: center;
  }
  .svc-link svg { width: 19px; height: 19px; transition: transform .2s ease; }
  .svc-card:hover .svc-link svg { transform: translateX(5px); }

  /* Philosophy (dark) */
  .philosophy {
    background:
      radial-gradient(1100px 500px at 12% -10%, rgba(106,64,221,.32), transparent 60%),
      radial-gradient(900px 500px at 100% 120%, rgba(79,44,174,.28), transparent 55%),
      var(--dark);
    color: var(--dark-ink);
  }
  .phil-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 56px;
    align-items: start;
  }
  /* About: photo + intro side by side, pillars below */
  .phil-about {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 56px;
    align-items: center;
    margin-bottom: 64px;
  }
  .phil-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 5;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 40px 80px -34px rgba(0,0,0,.65);
  }
  .phil-photo img {
    width: 100%; height: 100%;
    display: block;
    object-fit: cover;
  }
  .phil-photo::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 18px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
    pointer-events: none;
  }
  .phil-photo .photo-tag {
    position: absolute;
    left: 16px; bottom: 16px;
    z-index: 4;
    background: rgba(20,15,44,.72);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 11px;
    padding: 10px 14px;
    pointer-events: none;
  }
  .phil-photo .photo-tag b { display: block; font-family: var(--ff-head); font-size: 14px; color: #fff; }
  .phil-photo .photo-tag span { font-size: 12px; color: var(--dark-muted); }
  .philosophy .eyebrow { color: #b39bf6; }
  .phil-grid h2 { font-size: clamp(30px, 3.6vw, 42px); margin-bottom: 22px; }
  .phil-lead { color: var(--dark-muted); font-size: 16px; max-width: 420px; margin-bottom: 30px; }
  .phil-pillars {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 36px;
  }
  .pillar { border-left: 1px solid var(--dark-line); padding-left: 22px; }
  .pillar:first-child { border-left: 0; padding-left: 0; }
  .pillar-ic { color: #b39bf6; margin-bottom: 18px; }
  .pillar-ic svg { width: 30px; height: 30px; }
  .pillar h3 { font-size: 18px; margin-bottom: 12px; }
  .pillar p { font-size: 14px; color: var(--dark-muted); line-height: 1.6; }

  /* Blog */
  .blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 46px; }
  .link-arrow { color: var(--accent); font-weight: 600; display: inline-flex; align-items: center; gap: 8px; }
  .link-arrow svg { width: 18px; height: 18px; transition: transform .2s ease; }
  .link-arrow:hover svg { transform: translateX(5px); }

  .blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
  .post {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--bg);
    transition: transform .22s ease, box-shadow .22s ease;
    display: flex; flex-direction: column;
  }
  .post:hover { transform: translateY(-6px); box-shadow: 0 26px 50px -28px rgba(20,15,44,.4); }
  .post-img {
    display: block;
    aspect-ratio: 16 / 9;
    position: relative;
    overflow: hidden;
    background: var(--dark);
  }
  .post-img img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: transform .35s ease;
  }
  .post:hover .post-img img { transform: scale(1.04); }
  .post-img .ph-label {
    position: absolute;
    left: 14px; bottom: 12px;
    font-family: var(--ff-mono);
    font-size: 11px;
    color: rgba(255,255,255,.75);
    background: rgba(0,0,0,.32);
    padding: 4px 8px;
    border-radius: 6px;
    z-index: 2;
  }
  .post-body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
  .post-date { font-family: var(--ff-mono); font-size: 12px; color: var(--muted); margin-bottom: 12px; }
  .post h3 { font-size: 17.5px; line-height: 1.3; margin-bottom: 18px; }
  .post .svc-link { margin-top: auto; font-size: 14px; font-weight: 600; }

  /* Contact */
  .contact-grid { display: grid; grid-template-columns: 1fr 0.92fr; gap: 64px; align-items: start; }
  .contact-intro h2 { font-size: clamp(28px, 3.4vw, 38px); margin-bottom: 18px; }
  .contact-intro p { color: var(--muted); font-size: 16px; max-width: 360px; }
  .contact-details { margin-top: 40px; display: flex; flex-direction: column; gap: 22px; }
  .cd-item { display: flex; align-items: center; gap: 16px; }
  .cd-ic {
    width: 44px; height: 44px; flex: none;
    border-radius: 11px;
    background: var(--accent-soft);
    color: var(--accent);
    display: grid; place-items: center;
  }
  .cd-ic svg { width: 20px; height: 20px; }
  .cd-label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-family: var(--ff-mono); }
  .cd-val { font-weight: 600; font-size: 15px; }

  form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
  .field { margin-bottom: 16px; }
  label.flabel { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; color: var(--ink-soft); }
  input, textarea {
    width: 100%;
    font-family: var(--ff-body);
    font-size: 15px;
    color: var(--ink);
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--bg-soft);
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
  }
  input::placeholder, textarea::placeholder { color: #a09cb2; }
  input:focus, textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: #fff;
    box-shadow: 0 0 0 4px var(--accent-soft);
  }
  textarea { resize: vertical; min-height: 140px; }
  form .btn-primary { margin-top: 6px; }
  .form-note { font-size: 12.5px; color: var(--muted); margin-top: 14px; }

  /* Footer */
  footer {
    background: var(--dark);
    color: var(--dark-muted);
  }
  .footer-top {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 24px;
    padding: 40px 0;
    border-bottom: 1px solid var(--dark-line);
  }
  .footer-nav { display: flex; flex-wrap: wrap; gap: 28px; }
  .footer-nav a { font-size: 14px; color: var(--dark-muted); transition: color .18s ease; }
  .footer-nav a:hover { color: #fff; }
  .footer-top .brand-name { color: #fff; }
  .footer-bottom { padding: 22px 0; font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
  .footer-bottom a:hover { color: #fff; }

  /* Reveal animation */
  .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
  .reveal.in { opacity: 1; transform: none; }
  [data-delay="1"] { transition-delay: .08s; }
  [data-delay="2"] { transition-delay: .16s; }
  [data-delay="3"] { transition-delay: .24s; }

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

  /* Tweak-driven overrides */
  body.tilt-off .code-window { transform: none !important; }
  body.no-anim .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  body.no-anim .cw-cursor,
  body.no-anim .hero-badge .pulse { animation: none !important; }
  body.no-anim .code-window { transition: none !important; }

  /* Projektreferenzen */
  .ref-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .ref-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px;
    background: var(--bg);
    display: flex;
    flex-direction: column;
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
  }
  .ref-card:hover { transform: translateY(-4px); box-shadow: 0 26px 50px -28px rgba(20,15,44,.4); border-color: var(--accent-soft); }
  .ref-more {
    margin-top: 20px;
    display: inline-flex; align-items: center; gap: 8px;
    font-weight: 600; font-size: 14px; color: var(--accent);
  }
  .ref-more svg { width: 18px; height: 18px; transition: transform .2s ease; }
  .ref-card:hover .ref-more svg { transform: translateX(5px); }
  .ref-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
  .ref-role { font-family: var(--ff-mono); font-size: 12px; letter-spacing: .04em; color: var(--accent); text-transform: uppercase; }
  .ref-period { font-family: var(--ff-mono); font-size: 12px; color: var(--muted); white-space: nowrap; }
  .ref-card h3 { font-size: 19px; margin-bottom: 11px; line-height: 1.25; }
  .ref-card p { font-size: 14.5px; color: var(--muted); line-height: 1.55; margin-bottom: 20px; }
  .chips { display: flex; flex-wrap: wrap; gap: 8px; }
  .chip {
    font-family: var(--ff-mono); font-size: 12px;
    color: var(--ink-soft);
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 5px 11px;
  }

  /* Veröffentlichungen & Auftritte */
  .pub-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .pub-col {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 26px 26px 8px;
  }
  .pub-head { display: flex; align-items: center; gap: 13px; margin-bottom: 6px; padding-bottom: 18px; border-bottom: 1px solid var(--line-soft); }
  .pub-head .svc-ic { margin-bottom: 0; width: 42px; height: 42px; }
  .pub-head .svc-ic svg { width: 21px; height: 21px; }
  .pub-head h3 { font-size: 16px; }
  .pub-list { display: flex; flex-direction: column; }
  .pub-item {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 16px 0;
    border-bottom: 1px solid var(--line-soft);
    transition: padding-left .18s ease;
  }
  .pub-col .pub-item:last-child { border-bottom: 0; }
  .pub-item:hover { padding-left: 6px; }
  .pub-text { flex: 1; }
  .pub-title { font-weight: 600; font-size: 14.5px; line-height: 1.35; margin-bottom: 5px; transition: color .18s ease; }
  .pub-item:hover .pub-title { color: var(--accent); }
  .pub-meta { font-family: var(--ff-mono); font-size: 12px; color: var(--muted); }
  .pub-item .ext { flex: none; color: var(--muted); margin-top: 2px; transition: color .18s ease, transform .18s ease; }
  .pub-item .ext svg { width: 16px; height: 16px; }
  .pub-item:hover .ext { color: var(--accent); transform: translateX(3px); }
  .pub-all {
    display: inline-flex; align-items: center; gap: 8px;
    margin: 18px 0 0;
    padding-top: 18px;
    border-top: 1px solid var(--line-soft);
    font-weight: 600; font-size: 14px; color: var(--accent);
  }
  .pub-all svg { width: 17px; height: 17px; transition: transform .2s ease; }
  .pub-all:hover svg { transform: translateX(5px); }

  /* ---------- Publications detail page ---------- */
  .pubpage-section { padding: 64px 0 8px; scroll-margin-top: 96px; }
  .pubpage-section:last-of-type { padding-bottom: 64px; }
  .pubpage-head { display: flex; align-items: center; gap: 15px; margin-bottom: 30px; }
  .pubpage-head .svc-ic { margin-bottom: 0; width: 50px; height: 50px; flex: none; }
  .pubpage-head .svc-ic svg { width: 24px; height: 24px; }
  .pubpage-head h2 { font-size: clamp(26px, 3.2vw, 34px); }
  .pubpage-head .count { font-family: var(--ff-mono); font-size: 13px; color: var(--muted); margin-left: 4px; }

  .entry-list { display: flex; flex-direction: column; gap: 16px; }
  .entry {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--bg);
    padding: 24px 26px;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
  }
  .entry:hover { transform: translateY(-3px); box-shadow: 0 22px 44px -28px rgba(20,15,44,.4); border-color: var(--accent-soft); }
  .entry h3 { font-size: 18px; line-height: 1.3; margin-bottom: 12px; }
  .entry-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; }
  .entry-meta .m { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; color: var(--muted); }
  .entry-meta .m svg { width: 15px; height: 15px; color: var(--accent); flex: none; }
  .entry-meta .m b { color: var(--ink-soft); font-weight: 600; }
  .entry-cta {
    flex: none;
    display: inline-flex; align-items: center; gap: 8px;
    white-space: nowrap;
    font-weight: 600; font-size: 14px; color: var(--accent);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 11px 16px;
    transition: border-color .18s ease, background .18s ease;
  }
  .entry-cta:hover { border-color: var(--accent); background: var(--accent-soft); }
  .entry-cta svg { width: 16px; height: 16px; }
  .pubpage-tabs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
  .pubpage-tabs a {
    font-family: var(--ff-mono); font-size: 13px;
    padding: 9px 16px; border-radius: 999px;
    border: 1px solid var(--line); background: var(--bg);
    color: var(--ink-soft); transition: border-color .18s, color .18s, background .18s;
  }
  .pubpage-tabs a:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

  @media (max-width: 640px) {
    .entry { grid-template-columns: 1fr; gap: 18px; align-items: start; }
  }

  @media (max-width: 1000px) {
    .ref-grid { grid-template-columns: 1fr; }
    .pub-grid { grid-template-columns: 1fr; }
  }

  /* Skills / Kompetenzen */
  .skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }
  .skill-card {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px 26px 24px;
    display: flex;
    flex-direction: column;
    transition: box-shadow .22s ease, border-color .22s ease, transform .22s ease;
  }
  .skill-card:hover { box-shadow: 0 26px 50px -30px rgba(20,15,44,.35); border-color: var(--accent-soft); }
  .skill-card .skill-cat { display: flex; align-items: center; gap: 13px; margin-bottom: 20px; }
  .skill-card .svc-ic { margin-bottom: 0; width: 46px; height: 46px; flex: none; }
  .skill-card .svc-ic svg { width: 22px; height: 22px; }
  .skill-card:hover .svc-ic { background: var(--accent); color: #fff; }
  .skill-card h3 { font-size: 17px; line-height: 1.2; }
  .skill-tags { display: flex; flex-wrap: wrap; gap: 9px; }
  .skill-tag {
    font-family: var(--ff-body);
    font-size: 13.5px;
    color: var(--ink-soft);
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 6px 12px;
    transition: border-color .18s ease, color .18s ease, background .18s ease;
  }
  .skill-card:hover .skill-tag { border-color: var(--line); }
  .skill-tag:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
  /* Expandable area */
  .skill-extra { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .32s cubic-bezier(.2,.7,.2,1); }
  .skill-extra > .skill-extra-inner { overflow: hidden; }
  .skill-extra .skill-tags { padding-top: 9px; }
  .skill-card.open .skill-extra { grid-template-rows: 1fr; }
  .skill-expand {
    margin-top: 20px;
    align-self: flex-start;
    display: inline-flex; align-items: center; gap: 7px;
    font-family: var(--ff-body); font-weight: 600; font-size: 14px;
    color: var(--accent);
    background: none; border: 0; padding: 0; cursor: pointer;
  }
  .skill-expand svg { width: 16px; height: 16px; transition: transform .25s ease; }
  .skill-card.open .skill-expand svg { transform: rotate(180deg); }
  .skill-expand .more-count { color: var(--muted); font-weight: 500; }
  .skill-card.open .skill-expand .more-count { display: none; }

  @media (max-width: 920px) {
    .skills-grid { grid-template-columns: repeat(2, 1fr); }
  }
  @media (max-width: 560px) {
    .skills-grid { grid-template-columns: 1fr; }
  }

  /* Responsive */
  @media (max-width: 1100px) {
    .nav { position: relative; }
    .nav-links {
      position: absolute;
      top: calc(100% + 1px);
      left: 40px;
      right: 40px;
      display: none;
      flex-direction: column;
      align-items: stretch;
      gap: 0;
      padding: 12px;
      border: 1px solid var(--line);
      border-radius: 0 0 var(--radius) var(--radius);
      background: rgba(255,255,255,.97);
      box-shadow: 0 24px 48px -32px rgba(20,15,44,.45);
    }
    header.nav-open .nav-links { display: flex; }
    .nav-links a { padding: 12px 10px; }
    .nav-links a::after { display: none; }
    .nav-right .btn { display: none; }
    .menu-toggle { display: inline-flex; }
  }

  @media (max-width: 1000px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .hero-grid { grid-template-columns: 1fr; gap: 56px; padding-top: 56px; padding-bottom: 70px; }
    .hero-visual { max-width: 540px; }
    .phil-grid { grid-template-columns: 1fr; gap: 36px; }
    .phil-about { grid-template-columns: 1fr; gap: 36px; }
    .phil-photo { max-width: 340px; }
    .contact-grid { grid-template-columns: 1fr; gap: 44px; }
  }
  @media (max-width: 720px) {
    .wrap { padding: 0 22px; }
    .nav-links { left: 22px; right: 22px; }
    .hero-grid { gap: 0; }
    .hero-visual { display: none; }
    .pad { padding: 64px 0; }
    .blog-grid { grid-template-columns: 1fr; }
    .phil-pillars { grid-template-columns: 1fr; gap: 26px; }
    .pillar { border-left: 0; padding-left: 0; border-top: 1px solid var(--dark-line); padding-top: 22px; }
    .pillar:first-child { border-top: 0; padding-top: 0; }
    form .row { grid-template-columns: 1fr; }
    .hero-badge { display: none; }
  }
  @media (max-width: 480px) {
    .services-grid { grid-template-columns: 1fr; }
    .trust { gap: 20px; }
  }

  /* ---------- Reference detail page ---------- */
  .ref-hero {
    background: linear-gradient(180deg, var(--bg-lav) 0%, var(--bg-soft) 100%);
    border-bottom: 1px solid var(--line);
  }
  .ref-hero-inner {
    padding-top: 56px;
    padding-bottom: 60px;
    max-width: 820px;
  }
  .backlink {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: var(--ff-mono); font-size: 13px; color: var(--muted);
    margin-bottom: 28px; transition: color .18s ease;
  }
  .backlink svg { width: 16px; height: 16px; transition: transform .18s ease; }
  .backlink:hover { color: var(--accent); }
  .backlink:hover svg { transform: translateX(-4px); }
  .ref-hero h1 { font-size: clamp(32px, 4.4vw, 50px); margin-bottom: 20px; }
  @media (max-width: 720px) {
    .ref-hero-inner {
      padding-top: 48px;
      padding-bottom: 52px;
    }
  }
  .ref-tags { display: flex; flex-wrap: wrap; gap: 18px 28px; margin-top: 26px; }
  .ref-tag-item { display: flex; flex-direction: column; gap: 3px; }
  .ref-tag-item .k { font-family: var(--ff-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
  .ref-tag-item .v { font-weight: 600; font-size: 15px; }

  .ref-body { padding: 72px 0 96px; }
  .ref-layout { display: grid; grid-template-columns: 1fr 300px; gap: 64px; align-items: start; max-width: var(--maxw); }
  .ref-article > * + * { margin-top: 22px; }
  .ref-article h2 { font-size: 24px; margin-top: 44px; margin-bottom: 4px; }
  .ref-article h2:first-child { margin-top: 0; }
  .ref-article p { font-size: 16px; color: var(--ink-soft); line-height: 1.7; }
  .ref-article ul { margin: 0; padding-left: 22px; color: var(--ink-soft); font-size: 16px; line-height: 1.7; }
  .ref-article li { margin-bottom: 8px; }
  .ref-article blockquote {
    position: relative;
    margin: 34px 0;
    padding: 28px 32px 28px 72px;
    border: 1px solid rgba(36, 79, 131, .18);
    border-left: 5px solid var(--accent);
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(36, 79, 131, .08), rgba(122, 93, 199, .09));
    box-shadow: 0 24px 60px -46px rgba(20, 15, 44, .45);
    color: var(--ink);
    font-size: 19px;
    font-style: italic;
    line-height: 1.65;
  }
  .ref-article blockquote::before {
    content: "“";
    position: absolute;
    left: 26px;
    top: 16px;
    color: var(--accent);
    font-family: Georgia, serif;
    font-size: 58px;
    line-height: 1;
    opacity: .5;
  }
  .ref-article blockquote p { color: inherit; font-size: inherit; line-height: inherit; }
  @media (max-width: 560px) {
    .ref-article blockquote { padding: 24px 24px 24px 48px; }
    .ref-article blockquote::before { left: 18px; font-size: 44px; }
  }
  .ref-aside {
    position: sticky; top: 100px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 26px;
    background: var(--bg-soft);
  }
  .ref-aside h3 { font-size: 13px; font-family: var(--ff-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }
  .ref-aside .chips { margin-bottom: 26px; }
  .ref-aside .chips:last-child { margin-bottom: 0; }
  .ref-aside .chip { background: var(--bg); }

  .ref-nav { border-top: 1px solid var(--line); margin-top: 8px; }
  .ref-nav-inner { display: flex; justify-content: space-between; gap: 20px; padding: 36px 0; flex-wrap: wrap; }
  .ref-nav a { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; color: var(--ink); transition: color .18s ease; }
  .ref-nav a:hover { color: var(--accent); }
  .ref-nav svg { width: 18px; height: 18px; }

  @media (max-width: 860px) {
    .ref-layout { grid-template-columns: 1fr; gap: 40px; }
    .ref-aside { position: static; }
  }

  /* ---------- Blog article page ---------- */
  .post-hero .ref-hero-inner { max-width: 760px; }
  .post-hero .post-date-line {
    display: inline-flex; align-items: center; gap: 9px;
    font-family: var(--ff-mono); font-size: 13px; color: var(--muted);
    margin-bottom: 18px;
  }
  .post-hero .post-date-line svg { width: 16px; height: 16px; color: var(--accent); }
  .post-hashtags { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 26px; }
  .hashtag {
    font-family: var(--ff-mono); font-size: 13px;
    color: var(--accent);
    background: var(--accent-soft);
    border-radius: 999px;
    padding: 6px 13px;
    transition: transform .18s ease;
  }
  .hashtag:hover { transform: translateY(-2px); }
  .post-article { max-width: 760px; margin: 0 auto; padding: 64px 0 32px; }
  .post-article > * + * { margin-top: 22px; }
  .post-article h2 { font-size: 24px; margin-top: 44px; margin-bottom: 4px; }
  .post-article p { font-size: 17px; color: var(--ink-soft); line-height: 1.75; }
  .post-article a {
    color: var(--ink);
    text-decoration: underline;
    text-decoration-color: var(--ink-soft);
    text-decoration-thickness: 1.5px;
    text-underline-offset: 3px;
    transition: color .18s ease, text-decoration-color .18s ease;
  }
  .post-article a:hover {
    color: var(--accent);
    text-decoration-color: var(--accent);
  }
  .post-article ul { padding-left: 22px; color: var(--ink-soft); font-size: 17px; line-height: 1.75; }
  .post-article li { margin-bottom: 8px; }
  .post-article blockquote {
    margin: 8px 0; padding: 8px 0 8px 24px;
    border-left: 3px solid var(--accent);
    font-size: 19px; color: var(--ink); font-style: italic;
  }
  .post-article :not(pre) > code {
    padding: 2px 6px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: rgba(36, 79, 131, .07);
    color: var(--ink);
    font-family: var(--ff-mono);
    font-size: .9em;
    white-space: break-spaces;
  }
  .post-article pre.astro-code {
    position: relative;
    margin: 26px 0;
    border: 1px solid #3c3f41;
    border-radius: 8px;
    box-shadow: 0 18px 42px -32px rgba(9, 13, 24, .75);
    overflow: auto;
  }
  .post-article pre.astro-code::before {
    content: attr(data-language);
    position: sticky;
    left: 0;
    display: block;
    padding: 6px 12px;
    border-bottom: 1px solid #3c3f41;
    background: #2b2b2b;
    color: #a9b7c6;
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: .02em;
    text-transform: uppercase;
  }
  .post-article pre.astro-code[data-language=""]::before {
    display: none;
  }
  .post-article pre.astro-code code {
    display: block;
    min-width: max-content;
    padding: 8px 0;
    font-family: "JetBrains Mono", "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 12.5px;
    line-height: 1.12;
    counter-reset: code-line;
  }
  .post-article pre.astro-code .line {
    display: block;
    min-height: 1.12em;
    padding: 0 18px 0 58px;
    counter-increment: code-line;
  }
  .post-article pre.astro-code .line::before {
    content: counter(code-line);
    display: inline-block;
    width: 34px;
    margin-left: -46px;
    margin-right: 12px;
    color: #606366;
    text-align: right;
    user-select: none;
  }
  .post-article pre.astro-code .line:hover {
    background: #323232;
  }
