/* ═══════════════════════════════════════════════════════════════
   Tierarztpraxis Steinegg · Tiergesundheit — 2026 Rebuild
   Warme Naturheilkunde-Ästhetik · Markenblau + Salbeigrün
   ═══════════════════════════════════════════════════════════════ */

@layer reset, tokens, base, layout, components, utilities;

/* ─────────── RESET ─────────── */
@layer reset {
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  img, picture, svg, video { display: block; max-width: 100%; }
  img { height: auto; }
  input, button, textarea, select { font: inherit; }
  h1, h2, h3, h4, h5, h6 { overflow-wrap: break-word; text-wrap: balance; }
  p { overflow-wrap: break-word; }
  ul[class], ol[class] { list-style: none; }
}

/* ─────────── TOKENS ─────────── */
@layer tokens {
  :root {
    color-scheme: light;

    /* Brand: rgb(17,112,183) ≈ oklch(0.55 0.13 250) */
    --brand:        oklch(0.55 0.13 250);
    --brand-deep:   oklch(0.42 0.11 250);
    --brand-soft:   oklch(from var(--brand) 0.93 0.03 h);
    --sage:         oklch(0.58 0.09 150);
    --sage-soft:    oklch(from var(--sage) 0.92 0.04 h);

    --paper:   light-dark(oklch(0.977 0.008 85), oklch(0.22 0.012 260));
    --paper-2: light-dark(oklch(0.955 0.012 85), oklch(0.255 0.014 260));
    --card:    light-dark(oklch(1 0 0), oklch(0.28 0.015 260));
    --ink:     light-dark(oklch(0.28 0.02 255), oklch(0.92 0.008 85));
    --ink-2:   light-dark(oklch(0.45 0.02 255), oklch(0.75 0.012 85));
    --line:    light-dark(oklch(0.88 0.012 85), oklch(0.35 0.015 260));
    --heart:   oklch(0.6 0.21 25);

    --accent-text: light-dark(var(--brand-deep), oklch(0.75 0.09 250));
    --sage-text:   light-dark(oklch(0.45 0.09 150), oklch(0.78 0.08 150));

    --font-display: 'Quicksand', ui-rounded, system-ui, sans-serif;
    --font-body: 'Assistant', system-ui, sans-serif;

    /* Fluide Typo-Skala */
    --step--1: clamp(0.83rem, 0.8rem + 0.15vw, 0.94rem);
    --step-0:  clamp(1rem, 0.96rem + 0.3vw, 1.155rem);
    --step-1:  clamp(1.2rem, 1.13rem + 0.45vw, 1.5rem);
    --step-2:  clamp(1.5rem, 1.35rem + 0.8vw, 2rem);
    --step-3:  clamp(1.9rem, 1.6rem + 1.5vw, 2.8rem);
    --step-4:  clamp(2.4rem, 1.9rem + 2.6vw, 4rem);
    --step-5:  clamp(3rem, 2.2rem + 4.5vw, 6rem);

    /* Fluide Space-Skala */
    --sp-1: clamp(0.5rem, 0.45rem + 0.25vw, 0.75rem);
    --sp-2: clamp(1rem, 0.9rem + 0.5vw, 1.5rem);
    --sp-3: clamp(1.75rem, 1.5rem + 1.2vw, 2.75rem);
    --sp-4: clamp(3rem, 2.4rem + 3vw, 5.5rem);
    --sp-5: clamp(4.5rem, 3.5rem + 5vw, 8.5rem);

    --radius: 1.25rem;
    --radius-lg: 2rem;
    --content: 68rem;
    --shadow: 0 1px 2px oklch(0.2 0.02 260 / 0.06), 0 8px 28px oklch(0.2 0.02 260 / 0.1);
    --shadow-lg: 0 2px 6px oklch(0.2 0.02 260 / 0.08), 0 20px 60px oklch(0.2 0.02 260 / 0.18);
  }

  @font-face {
    font-family: 'Quicksand';
    src: url('assets/fonts/Quicksand.woff2') format('woff2');
    font-weight: 300 700;
    font-display: swap;
  }
  @font-face {
    font-family: 'Assistant';
    src: url('assets/fonts/Assistant.woff2') format('woff2');
    font-weight: 200 800;
    font-display: swap;
  }
}

/* ─────────── BASE ─────────── */
@layer base {
  html { scroll-behavior: smooth; }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
  }

  body {
    font-family: var(--font-body);
    font-size: var(--step-0);
    line-height: 1.65;
    color: var(--ink);
    background: var(--paper);
    /* feines Papierkorn */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.028'/%3E%3C/svg%3E");
  }

  h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.01em;
  }

  a { color: var(--accent-text); text-underline-offset: 0.2em; }
  a:hover { text-decoration-thickness: 2px; }

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

  ::selection { background: var(--brand-soft); color: var(--brand-deep); }

  .icon {
    display: inline-block;
    inline-size: 1.05em;
    block-size: 1.05em;
    fill: currentColor;
    vertical-align: -0.15em;
    flex: none;
  }
  .sprite { position: absolute; inline-size: 0; block-size: 0; overflow: hidden; }
}

/* ─────────── LAYOUT ─────────── */
@layer layout {
  .section {
    max-inline-size: var(--content);
    margin-inline: auto;
    padding: var(--sp-5) var(--sp-3);
  }

  .section-alt {
    max-inline-size: none;
    background: var(--paper-2);
    border-block: 1px solid var(--line);
  }
  .section-alt > * {
    max-inline-size: var(--content);
    margin-inline: auto;
    padding-inline: var(--sp-3);
  }
  .section-alt { padding-inline: 0; }

  .split {
    display: grid;
    gap: var(--sp-3);
    align-items: center;
    margin-block-end: var(--sp-4);
  }
  @media (min-width: 56rem) {
    .split { grid-template-columns: 5fr 7fr; }
    .split-reverse { grid-template-columns: 7fr 5fr; }
    .split-reverse .split-img { order: 2; }
  }

  .split-text > p + p { margin-block-start: 0.85em; }

  .section-head { margin-block-end: var(--sp-3); position: relative; }
  .section-head-center { text-align: center; }
  .section-intro { margin-block-end: var(--sp-2); }

  .prose-center {
    max-inline-size: 46rem;
    margin-inline: auto;
    text-align: center;
  }
  .prose-center p + p { margin-block-start: 0.85em; }
}

/* ─────────── COMPONENTS ─────────── */
@layer components {

  /* — Skip link — */
  .skip-link {
    position: fixed;
    inset-block-start: 0.75rem;
    inset-inline-start: 0.75rem;
    z-index: 100;
    padding: 0.7em 1.2em;
    background: var(--brand);
    color: #fff;
    border-radius: 999px;
    font-weight: 600;
    text-decoration: none;
    translate: 0 -300%;
    transition: translate 0.2s;
  }
  .skip-link:focus-visible { translate: 0 0; }

  /* — Header — */
  .site-header {
    position: sticky;
    inset-block-start: 0;
    z-index: 50;
    background: light-dark(oklch(0.977 0.008 85 / 0.82), oklch(0.22 0.012 260 / 0.82));
    backdrop-filter: blur(14px);
    border-block-end: 1px solid transparent;
    transition: border-color 0.3s, box-shadow 0.3s;
  }
  .site-header.scrolled {
    border-color: var(--line);
    box-shadow: 0 4px 24px oklch(0.2 0.02 260 / 0.07);
  }
  .site-header nav {
    max-inline-size: var(--content);
    margin-inline: auto;
    padding: 0.8rem var(--sp-3);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-2);
  }
  .wordmark {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: var(--step-1);
    color: var(--ink);
    text-decoration: none;
    line-height: 1.05;
  }
  .wordmark .icon { inline-size: 1.5em; block-size: 1.5em; color: var(--brand); }
  .wordmark em {
    display: block;
    font-family: var(--font-body);
    font-style: normal;
    font-weight: 400;
    font-size: var(--step--1);
    color: var(--ink-2);
    letter-spacing: 0.14em;
    text-transform: uppercase;
  }
  .nav-links {
    display: flex;
    align-items: center;
    gap: clamp(0.75rem, 2vw, 2rem);
  }
  .nav-links a {
    font-family: var(--font-display);
    font-weight: 600;
    text-decoration: none;
    color: var(--ink-2);
    padding: 0.5em 0.25em;
    transition: color 0.2s;
  }
  .nav-links a:hover, .nav-links a[aria-current] { color: var(--accent-text); }
  .nav-cta {
    background: var(--brand);
    color: #fff !important;
    padding: 0.55em 1.3em !important;
    border-radius: 999px;
  }
  .nav-cta:hover { background: var(--brand-deep); }

  .nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: 0;
    padding: 0.6rem;
    cursor: pointer;
  }
  .nav-toggle span {
    inline-size: 24px;
    block-size: 2.5px;
    background: var(--ink);
    border-radius: 2px;
  }
  @media (max-width: 47rem) {
    .nav-links { display: none; }
    .nav-toggle { display: flex; }
  }

  .mobile-menu {
    inset: auto 0 0 0;
    inline-size: 100%;
    border: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    background: var(--card);
    padding: var(--sp-3);
    box-shadow: var(--shadow-lg);
  }
  .mobile-menu::backdrop { background: oklch(0.2 0.02 260 / 0.45); backdrop-filter: blur(3px); }
  .mobile-menu nav { display: grid; gap: 0.25rem; }
  .mobile-menu a {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: var(--step-2);
    text-decoration: none;
    color: var(--ink);
    padding: 0.6em 0.4em;
    border-radius: 0.75rem;
  }
  .mobile-menu a:hover { background: var(--brand-soft); color: var(--brand-deep); }

  /* — Eyebrow — */
  .eyebrow {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: var(--step--1);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--sage-text);
    margin-block-end: 0.6rem;
  }

  .h-display {
    font-size: var(--step-3);
    color: var(--ink);
    margin-block-end: 0.4em;
  }
  .lede {
    font-size: var(--step-1);
    color: var(--ink-2);
    font-style: italic;
  }

  /* — Buttons — */
  .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6em;
    padding: 0.75em 1.6em;
    min-block-size: 44px;
    border-radius: 999px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: var(--step-0);
    text-decoration: none;
    transition: background 0.2s, translate 0.15s, box-shadow 0.2s;
  }
  .btn:hover { translate: 0 -2px; box-shadow: var(--shadow); }
  .btn-primary { background: var(--brand); color: #fff; }
  .btn-primary:hover { background: var(--brand-deep); }
  .btn-accent { background: var(--sage); color: #fff; }
  .btn-accent:hover { background: oklch(from var(--sage) calc(l - 0.08) c h); }
  .btn-light { background: #fff; color: var(--brand-deep); }

  /* — Hero — */
  .hero {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: clip;
    min-block-size: min(88svh, 46rem);
    isolation: isolate;
  }
  .hero-media { position: absolute; inset: 0; }
  .hero-media img, .hero-video {
    position: absolute;
    inset: 0;
    inline-size: 100%;
    block-size: 100%;
    object-fit: cover;
    /* Hund sitzt links im Bild – Ausschnitt so, dass rechts Raum für Text bleibt */
    object-position: 22% 55%;
  }
  .hero-video { opacity: 0; transition: opacity 0.8s ease; }
  .hero-video.is-playing { opacity: 1; }
  /* Lesbarkeit: Verlauf von unten + sanfte Abdunklung oben */
  .hero-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
      linear-gradient(to top,
        var(--paper) 0%,
        oklch(0.24 0.04 250 / 0.6) 38%,
        oklch(0.24 0.04 250 / 0.42) 70%,
        oklch(0.24 0.04 250 / 0.5) 100%);
  }
  /* Ab Tablet: Text rechts, damit der Hund links frei bleibt */
  @media (min-width: 60rem) {
    .hero-media::after {
      background:
        linear-gradient(to top, var(--paper) 0%, transparent 32%),
        linear-gradient(to left,
          oklch(0.24 0.04 250 / 0.72) 0%,
          oklch(0.24 0.04 250 / 0.6) 38%,
          oklch(0.24 0.04 250 / 0.15) 72%,
          transparent 100%);
    }
  }
  .hero-inner {
    position: relative;
    z-index: 1;
    inline-size: 100%;
    max-inline-size: var(--content);
    margin-inline: auto;
    padding: var(--sp-5) var(--sp-3) var(--sp-4);
    text-align: center;
    display: grid;
    justify-items: center;
  }
  @media (min-width: 60rem) {
    .hero-inner {
      justify-items: end;
      text-align: end;
    }
    .hero-inner > * { max-inline-size: 34rem; }
    .hero .status-card { justify-items: end; }
    .hero-actions { justify-content: flex-end; }
  }
  .hero .eyebrow {
    color: oklch(0.95 0.02 85);
    text-shadow: 0 1px 14px oklch(0.2 0.04 250 / 0.7);
  }
  .hero h1 {
    font-size: var(--step-4);
    color: #fff;
    text-shadow: 0 2px 30px oklch(0.2 0.04 250 / 0.65);
    margin-block: 0.15em 0.35em;
  }
  .hero h1 .heart {
    inline-size: 0.85em;
    block-size: 0.85em;
    color: var(--heart);
    filter: drop-shadow(0 2px 12px oklch(0.35 0.16 25 / 0.6));
    animation: heartbeat 2.2s ease-in-out infinite;
  }
  @keyframes heartbeat {
    0%, 40%, 100% { scale: 1; }
    10% { scale: 1.14; }
    20% { scale: 1; }
    30% { scale: 1.1; }
  }
  @media (prefers-reduced-motion: reduce) {
    .hero h1 .heart { animation: none; }
  }
  .hero-lede {
    font-size: var(--step-1);
    color: oklch(0.96 0.01 85);
    text-shadow: 0 1px 16px oklch(0.2 0.04 250 / 0.75);
    max-inline-size: 38ch;
    text-wrap: balance;
    margin-block-end: var(--sp-3);
  }

  .status-card {
    background: var(--card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: var(--sp-2) var(--sp-3);
    display: grid;
    gap: 0.75rem;
    justify-items: center;
    max-inline-size: 34rem;
  }
  .status-note {
    display: inline-flex;
    align-items: center;
    gap: 0.5em;
    font-weight: 700;
    color: var(--accent-text);
    background: var(--brand-soft);
    padding: 0.4em 1em;
    border-radius: 999px;
    font-size: var(--step--1);
  }
  .hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-1);
    align-items: center;
  }
  .btn-ghost {
    background: transparent;
    border: 2px solid var(--line);
    color: var(--accent-text);
  }
  .btn-ghost:hover { border-color: var(--brand); background: var(--brand-soft); }

  @media (max-width: 40rem) {
    .hero { min-block-size: min(92svh, 44rem); }
    .hero-media img, .hero-video { object-position: center 32%; }
  }

  /* — Divider — */
  .divider {
    position: relative;
    display: grid;
    grid-template-rows: 100%;
    grid-template-columns: 100%;
    overflow: clip;
    /* Parallax: fixes Bild, das nur durch dieses "Fenster" sichtbar ist */
    clip-path: inset(0);
    block-size: clamp(18rem, 55svh, 30rem);
  }
  .divider picture, .divider h2 { grid-area: 1 / 1; }
  .divider img {
    position: fixed;
    inset: 0;
    inline-size: 100vw;
    block-size: 100lvh;
    object-fit: cover;
  }
  @media (prefers-reduced-motion: reduce) {
    .divider img {
      position: static;
      inline-size: 100%;
      block-size: 100%;
    }
  }
  .divider::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, oklch(0.35 0.08 250 / 0.35), oklch(0.3 0.08 250 / 0.45));
  }
  .divider h2 {
    position: relative;
    z-index: 1;
    place-self: center;
    color: #fff;
    font-size: var(--step-5);
    letter-spacing: 0.02em;
    text-shadow: 0 4px 40px oklch(0.2 0.06 250 / 0.7);
  }
  /* Titel-Einblendung (progressive enhancement) */
  @supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
      .divider h2 {
        animation: divider-title linear both;
        animation-timeline: view();
        animation-range: entry 10% entry 50%;
      }
      @keyframes divider-title {
        from { opacity: 0; translate: 0 1.2em; }
        to { opacity: 1; translate: 0 0; }
      }
    }
  }

  /* — Accordion (native details) — */
  .accordion {
    display: grid;
    gap: 0.75rem;
    margin-block-start: var(--sp-2);
  }
  .accordion details {
    /* Grid-Items haben min-width:auto und würden sonst breiter als ihre
       Spalte bleiben — auf schmalen Viewports gäbe das Seiten-Scroll. */
    min-inline-size: 0;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 1px 2px oklch(0.2 0.02 260 / 0.04);
    overflow: clip;
    transition: box-shadow 0.25s;
  }
  .accordion details[open] { box-shadow: var(--shadow); border-color: color-mix(in oklch, var(--brand) 35%, var(--line)); }
  .accordion summary {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.9rem;
    padding: 1.1rem 1.4rem;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: var(--step-1);
    line-height: 1.3;
    cursor: pointer;
    list-style: none;
    color: var(--ink);
  }
  .accordion summary::-webkit-details-marker { display: none; }
  .accordion summary::after {
    content: '+';
    margin-inline-start: auto;
    font-size: 1.5em;
    font-weight: 400;
    line-height: 1;
    color: var(--accent-text);
    transition: rotate 0.3s;
    flex: none;
  }
  .accordion details[open] summary::after { rotate: 45deg; }
  .accordion summary em { font-style: italic; font-weight: 400; color: var(--ink-2); }
  .accordion summary .num {
    display: grid;
    place-items: center;
    inline-size: 2em;
    block-size: 2em;
    flex: none;
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand-deep);
    font-size: 0.8em;
    font-weight: 700;
  }
  .details-body { padding: 0.25rem 1.4rem 1.4rem; color: var(--ink-2); }
  .details-body p + p, .details-body ul { margin-block-start: 0.8em; }
  .details-body ul { padding-inline-start: 1.2em; }
  /* Animierte Öffnung, wo unterstützt */
  @supports (interpolate-size: allow-keywords) {
    :root { interpolate-size: allow-keywords; }
    .accordion details::details-content {
      block-size: 0;
      overflow: clip;
      transition: block-size 0.35s ease, content-visibility 0.35s allow-discrete;
    }
    .accordion details[open]::details-content { block-size: auto; }
  }

  /* — Split-Bilder / Blobs — */
  /* clip hält die dekorative Blob-Form im Kasten (kein Seiten-Scroll);
     clip statt hidden, damit kein Scroll-Container entsteht. */
  .split-img { position: relative; overflow-x: clip; }
  .split-img img {
    inline-size: min(100%, 26rem);
    margin-inline: auto;
    aspect-ratio: 1;
    object-fit: cover;
  }
  .blob img { border-radius: 58% 42% 55% 45% / 48% 55% 45% 52%; }
  .blob-b img { border-radius: 45% 55% 44% 56% / 55% 46% 54% 45%; }
  .blob::before {
    content: '';
    position: absolute;
    inset: -4% 3% auto auto;
    inline-size: 38%;
    aspect-ratio: 1;
    border-radius: 58% 42% 55% 45% / 48% 55% 45% 52%;
    background: var(--sage-soft);
    z-index: -1;
    rotate: 18deg;
  }
  .badge-fig img {
    inline-size: min(100%, 20rem);
    margin-inline: auto;
    filter: drop-shadow(0 12px 32px oklch(0.2 0.02 260 / 0.18));
  }

  .badge-link { display: inline-block; margin-block-start: var(--sp-2); }
  .badge-link img { inline-size: 7.5rem; block-size: auto; transition: scale 0.25s; }
  .badge-link:hover img { scale: 1.05; }

  .shop-row {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    margin-block-start: var(--sp-2);
    flex-wrap: wrap;
  }
  .shop-row img { inline-size: 7rem; block-size: auto; }

  /* — Check-Liste — */
  .check-list { display: grid; gap: 0.5rem; margin-block: 0.8em; }
  .check-list li {
    padding-inline-start: 1.7em;
    position: relative;
  }
  .check-list li::before {
    content: '';
    position: absolute;
    inset-inline-start: 0;
    inset-block-start: 0.42em;
    inline-size: 0.95em;
    block-size: 0.95em;
    border-radius: 50%;
    background: var(--sage-soft);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-8.5' fill='none' stroke='%233d7a52' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-size: 68%;
    background-position: center;
    background-repeat: no-repeat;
  }

  /* — Galerie — */
  .gallery-heading, .sub-topic h4 {
    font-size: var(--step-2);
    margin-block: var(--sp-3) var(--sp-2);
    display: flex;
    align-items: center;
    gap: 0.75rem;
  }
  .gallery-heading::after, .sub-topic h4::after {
    content: '';
    flex: 1;
    block-size: 2px;
    border-radius: 2px;
    background: linear-gradient(to right, var(--line), transparent);
  }
  .sub-topic { margin-block-start: var(--sp-4); }
  .sub-topic p + p { margin-block-start: 0.8em; }

  .gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(15rem, 100%), 1fr));
    gap: var(--sp-2);
    margin-block-start: var(--sp-2);
  }
  .gallery figure {
    display: grid;
    gap: 0.6rem;
    cursor: zoom-in;
    border-radius: var(--radius);
  }
  .gallery img {
    inline-size: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: scale 0.3s, box-shadow 0.3s;
  }
  .gallery figure:hover img { scale: 1.025; box-shadow: var(--shadow-lg); }
  .gallery figcaption {
    font-size: var(--step--1);
    color: var(--ink-2);
    line-height: 1.5;
    padding-inline: 0.25rem;
  }

  /* — Profil & Kontakt — */
  .profile-grid {
    display: grid;
    gap: var(--sp-3);
    margin-block-start: var(--sp-4);
    align-items: stretch;
  }
  @media (min-width: 52rem) {
    .profile-grid { grid-template-columns: 1fr 1fr; }
  }
  .profile-card, .contact-card {
    border-radius: var(--radius-lg);
    padding: var(--sp-3);
  }
  .profile-card {
    background: var(--card);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    text-align: center;
  }
  .avatar img {
    inline-size: 9rem;
    block-size: 9rem;
    border-radius: 50%;
    object-fit: cover;
    margin-inline: auto;
    border: 4px solid var(--brand-soft);
    margin-block-end: var(--sp-2);
  }
  .profile-card h4 { font-size: var(--step-2); margin-block-end: var(--sp-2); }
  .facts {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.7rem 1.2rem;
    text-align: start;
    font-size: var(--step--1);
  }
  .facts dt {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--accent-text);
  }
  .facts dd { color: var(--ink-2); }

  .contact-card {
    background: linear-gradient(150deg, var(--brand) 0%, var(--brand-deep) 100%);
    color: #fff;
    text-align: center;
    display: grid;
    gap: 0.9rem;
    place-content: center;
    justify-items: center;
    box-shadow: var(--shadow-lg);
    scroll-margin-block-start: 6rem;
  }
  .contact-card h4 { font-size: var(--step-2); }
  .contact-card .status-note { background: oklch(1 0 0 / 0.16); color: #fff; }
  .contact-card .btn-light { font-size: var(--step-1); }
  .contact-mail {
    color: #fff;
    display: inline-flex;
    align-items: center;
    gap: 0.5em;
    min-block-size: 44px;
  }

  /* — Legal — */
  .section-legal {
    border-block-start: 1px solid var(--line);
    font-size: var(--step--1);
    color: var(--ink-2);
  }
  .section-legal .h-display { font-size: var(--step-2); }
  .legal-grid {
    display: grid;
    gap: var(--sp-3);
    align-items: start;
  }
  @media (min-width: 52rem) {
    .legal-grid { grid-template-columns: 2fr 3fr; }
  }
  .legal-card {
    font-style: normal;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: var(--sp-3);
  }
  .legal-card h4, .legal-privacy h4 {
    font-size: var(--step-1);
    color: var(--ink);
    margin-block-end: var(--sp-1);
  }
  .legal-name {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--ink);
    margin-block-end: var(--sp-2);
  }
  .legal-facts { display: grid; gap: 0.7rem; }
  .legal-facts li {
    display: flex;
    align-items: center;
    gap: 0.7rem;
  }
  .legal-facts .icon { color: var(--brand); }
  .legal-lede { margin-block-end: var(--sp-2); }
  .accordion-slim { margin-block-start: 0; }
  .accordion-slim summary {
    font-size: var(--step-0);
    padding: 0.85rem 1.2rem;
  }
  .accordion-slim .details-body { padding: 0.1rem 1.2rem 1.1rem; }

  /* — Footer — */
  .site-footer {
    text-align: center;
    padding: var(--sp-3);
    color: var(--ink-2);
    font-size: var(--step--1);
    border-block-start: 1px solid var(--line);
    background: var(--paper-2);
  }

  /* — Lightbox — */
  .lightbox {
    border: 0;
    padding: 0;
    background: transparent;
    max-inline-size: min(92vw, 60rem);
    max-block-size: 92svh;
    margin: auto;
  }
  .lightbox::backdrop {
    background: oklch(0.15 0.02 260 / 0.82);
    backdrop-filter: blur(6px);
  }
  .lightbox figure {
    display: grid;
    gap: 0.75rem;
  }
  .lightbox img {
    inline-size: 100%;
    max-block-size: 78svh;
    object-fit: contain;
    border-radius: var(--radius);
  }
  .lightbox figcaption {
    color: #fff;
    text-align: center;
    font-size: var(--step-0);
    text-wrap: balance;
  }
  .lightbox-close {
    position: absolute;
    inset-block-start: -0.5rem;
    inset-inline-end: -0.5rem;
    z-index: 2;
    inline-size: 2.75rem;
    block-size: 2.75rem;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: var(--ink);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: var(--shadow);
  }
  @media (max-width: 40rem) {
    .lightbox-close { inset-block-start: 0.5rem; inset-inline-end: 0.5rem; }
  }

  /* — Scroll-Reveal für Sektionen — */
  @supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
      .section-head, .split-text, .split-img, .accordion, .gallery figure, .prose-center, .profile-card, .contact-card {
        animation: rise-in 0.7s ease both;
        animation-timeline: view();
        animation-range: entry 5% entry 38%;
      }
      @keyframes rise-in {
        from { opacity: 0; translate: 0 2rem; }
        to { opacity: 1; translate: 0 0; }
      }
    }
  }
}

/* ─────────── UTILITIES ─────────── */
@layer utilities {
  .visually-hidden {
    position: absolute;
    inline-size: 1px;
    block-size: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}
