/* ============================================================
   KRONACH DESIGN v2 — Minimal/Editorial Design System
   @layer: base, theme, layout, components, utilities
   ============================================================ */

@layer base, theme, layout, components, utilities;

/* ============================================================
   FONTS — Instrument Serif, selbst gehostet (DSGVO, kein CDN)
   ============================================================ */
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/public/fonts/instrument-serif-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/public/fonts/instrument-serif-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/public/fonts/instrument-serif-italic-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/public/fonts/instrument-serif-italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ============================================================
   THEME — Design Tokens
   ============================================================ */
@layer theme {
  :root {
    /* Colors — warm neutral palette */
    --c-bg:         #FAFAF8;
    --c-surface:    #F3F1EE;
    --c-surface-2:  #EAE7E3;
    --c-border:     #E2DDD7;
    --c-text:       #1A1714;
    --c-muted:      #6B6360;
    --c-dim:        #A8A4A0;
    --c-accent:     #BF1626;
    --c-accent-dim: #8C0F1B;
    --c-accent-bg:  #FFF0F1;
    --c-inverse:    #0F0D0C;
    --c-inv-text:   #F0EDE8;
    --c-inv-muted:  #9A9490;

    /* Typography */
    --font-display: 'Instrument Serif', 'Playfair Display', Georgia, serif;
    --font-body:    -apple-system, 'Helvetica Neue', Arial, sans-serif;
    --font-mono:    'SF Mono', 'Consolas', 'Menlo', monospace;

    /* Type Scale */
    --text-xs:    0.6875rem;   /* 11px */
    --text-sm:    0.875rem;    /* 14px */
    --text-base:  1.0625rem;   /* 17px */
    --text-lg:    1.25rem;     /* 20px */
    --text-xl:    1.5625rem;   /* 25px */
    --text-2xl:   2rem;        /* 32px */
    --text-3xl:   2.75rem;     /* 44px */
    --text-4xl:   3.75rem;     /* 60px */
    --text-hero:  clamp(2.75rem, 6.5vw + 0.5rem, 5.75rem);
    --text-h2:    clamp(2rem, 4vw + 0.5rem, 3.25rem);
    --text-h3:    clamp(1.375rem, 2vw, 1.75rem);

    /* Spacing */
    --s-1:   0.25rem;
    --s-2:   0.5rem;
    --s-3:   0.75rem;
    --s-4:   1rem;
    --s-5:   1.25rem;
    --s-6:   1.5rem;
    --s-8:   2rem;
    --s-10:  2.5rem;
    --s-12:  3rem;
    --s-16:  4rem;
    --s-20:  5rem;
    --s-24:  6rem;
    --s-32:  8rem;
    --section-gap: clamp(4.5rem, 10vw, 8rem);

    /* Layout */
    --container:      1140px;
    --container-text: 680px;
    --gutter:         clamp(1.25rem, 4vw, 2rem);

    /* Radii */
    --r-sm:   4px;
    --r-md:   8px;
    --r-lg:   16px;
    --r-xl:   24px;
    --r-full: 999px;

    /* Shadows */
    --shadow-sm:  0 1px 3px rgba(26,23,20,.06), 0 1px 2px rgba(26,23,20,.04);
    --shadow-md:  0 4px 16px rgba(26,23,20,.08), 0 2px 6px rgba(26,23,20,.04);
    --shadow-lg:  0 12px 40px rgba(26,23,20,.1),  0 4px 12px rgba(26,23,20,.05);
    --shadow-xl:  0 24px 64px rgba(26,23,20,.12), 0 8px 24px rgba(26,23,20,.06);

    /* Motion */
    --ease:      cubic-bezier(0.16, 1, 0.3, 1);
    --ease-out:  cubic-bezier(0, 0, 0.2, 1);
    --t-fast:    120ms;
    --t-base:    220ms;
    --t-slow:    380ms;
  }

}

/* ============================================================
   BASE — Reset & Fundamentals
   ============================================================ */
@layer base {
  *, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }

  html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    hanging-punctuation: first last;
  }

  body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--c-text);
    background: var(--c-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
  }

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

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

  a:focus-visible {
    outline: 2px solid var(--c-accent);
    outline-offset: 3px;
    border-radius: var(--r-sm);
  }

  ul { list-style: none; }

  ::selection {
    background: var(--c-accent);
    color: white;
  }

  /* Headings */
  h1, h2, h3, h4 {
    line-height: 1.1;
    letter-spacing: -0.025em;
    text-wrap: balance;
  }

  h1 { font-family: var(--font-display); font-size: var(--text-hero); font-weight: 400; }
  h2 { font-family: var(--font-display); font-size: var(--text-h2);   font-weight: 400; }
  h3 { font-size: var(--text-h3); font-weight: 600; letter-spacing: -0.02em; }
  h4 { font-size: var(--text-lg); font-weight: 600; }

  p + p { margin-top: var(--s-4); }

  strong { font-weight: 600; }

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

/* ============================================================
   LAYOUT — Container, Grid, Section Spacing
   ============================================================ */
@layer layout {
  .container {
    width: min(var(--container), 100%);
    padding-inline: var(--gutter);
    margin-inline: auto;
  }

  .container--text {
    max-width: calc(var(--container-text) + var(--gutter) * 2);
  }

  .section {
    padding-block: var(--section-gap);
  }

  .section--sm {
    padding-block: calc(var(--section-gap) * 0.6);
  }

  .section--dark {
    background: var(--c-inverse);
    color: var(--c-inv-text);
  }

  .section--surface {
    background: var(--c-surface);
  }

  /* Two-column grid */
  .grid-2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }

  @media (min-width: 700px) {
    .grid-2 { grid-template-columns: repeat(2, 1fr); }
  }

  /* Three-column grid */
  .grid-3 {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }

  @media (min-width: 600px) {
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
  }

  @media (min-width: 900px) {
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
  }

  /* Editorial asymmetric grid */
  .grid-editorial {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }

  @media (min-width: 860px) {
    .grid-editorial { grid-template-columns: 3fr 2fr; }
  }

  .section-label {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--c-muted);
    display: block;
    margin-bottom: var(--s-4);
  }

  .section-header {
    margin-bottom: var(--s-12);
  }

  .section-header h2 {
    margin-bottom: var(--s-4);
  }

  .section-header p {
    font-size: var(--text-lg);
    color: var(--c-muted);
    max-width: 52ch;
    line-height: 1.6;
  }
}

/* ============================================================
   COMPONENTS
   ============================================================ */
@layer components {

  /* ── Navigation ── */
  .nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--c-bg);
    border-bottom: 1px solid var(--c-border);
    transition: box-shadow var(--t-base) var(--ease);
  }

  .nav.is-scrolled {
    box-shadow: var(--shadow-sm);
  }

  .nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    gap: var(--s-6);
  }

  .nav__logo {
    font-size: var(--text-base);
    font-weight: 600;
    letter-spacing: -0.02em;
    white-space: nowrap;
    color: var(--c-text);
    transition: color var(--t-fast);
  }

  .nav__logo:hover { color: var(--c-accent); }

  .nav__logo span {
    color: var(--c-accent);
  }

  .nav__links {
    display: none;
    align-items: center;
    gap: var(--s-2);
  }

  @media (min-width: 700px) {
    .nav__links { display: flex; }
  }

  .nav__link {
    font-size: var(--text-sm);
    color: var(--c-muted);
    padding: var(--s-2) var(--s-3);
    border-radius: var(--r-sm);
    transition: color var(--t-fast), background var(--t-fast);
  }

  .nav__link:hover {
    color: var(--c-text);
    background: var(--c-surface);
  }

  .nav__cta {
    display: none;
  }

  @media (min-width: 500px) {
    .nav__cta { display: inline-flex; }
  }

  /* Mobile nav toggle */
  .nav__toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: var(--s-2);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--c-text);
  }

  @media (min-width: 700px) {
    .nav__toggle { display: none; }
  }

  .nav__toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    transition: transform var(--t-base) var(--ease), opacity var(--t-fast);
  }

  /* Mobile nav drawer */
  .nav__drawer {
    display: none;
    flex-direction: column;
    padding: var(--s-4) var(--gutter);
    border-top: 1px solid var(--c-border);
    background: var(--c-bg);
  }

  .nav__drawer.is-open { display: flex; }

  .nav__drawer .nav__link {
    padding: var(--s-3) var(--s-2);
    font-size: var(--text-base);
    border-bottom: 1px solid var(--c-border);
  }

  .nav__drawer .nav__link:last-child { border-bottom: none; }


  /* ── Buttons ── */
  .btn {
    display: inline-flex;
    align-items: center;
    gap: var(--s-2);
    padding: 0.6875em 1.375em;
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 600;
    letter-spacing: 0.01em;
    border-radius: var(--r-full);
    border: 1.5px solid transparent;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast), transform var(--t-fast);
    user-select: none;
  }

  .btn:active { transform: scale(0.98); }

  .btn--primary {
    background: var(--c-accent);
    color: white;
    border-color: var(--c-accent);
  }

  .btn--primary:hover {
    background: var(--c-accent-dim);
    border-color: var(--c-accent-dim);
  }

  .btn--ghost {
    background: transparent;
    color: var(--c-text);
    border-color: var(--c-border);
  }

  .btn--ghost:hover {
    background: var(--c-surface);
    border-color: var(--c-border);
  }

  .btn--inv {
    background: var(--c-inv-text);
    color: var(--c-inverse);
    border-color: var(--c-inv-text);
  }

  .btn--inv:hover {
    background: color-mix(in srgb, var(--c-inv-text) 88%, transparent);
  }

  .btn--inv-ghost {
    background: transparent;
    color: var(--c-inv-text);
    border-color: color-mix(in srgb, var(--c-inv-text) 35%, transparent);
  }

  .btn--inv-ghost:hover {
    background: color-mix(in srgb, var(--c-inv-text) 10%, transparent);
    border-color: color-mix(in srgb, var(--c-inv-text) 60%, transparent);
  }

  .btn--sm {
    font-size: var(--text-xs);
    padding: 0.5em 1em;
  }

  /* ── Eyebrow / Label ── */
  .eyebrow {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 400;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--c-muted);
  }

  .eyebrow--accent { color: var(--c-accent); }


  /* ── Hero ── */
  .hero {
    min-height: min(90vh, 820px);
    display: flex;
    align-items: center;
    padding-block: var(--s-20);
    position: relative;
    overflow: hidden;
  }

  .hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(
      ellipse 80% 60% at 70% 50%,
      color-mix(in srgb, var(--c-accent) 4%, transparent),
      transparent 70%
    );
    pointer-events: none;
  }

  .hero__inner {
    position: relative;
    z-index: 1;
    max-width: 780px;
  }

  .hero__eyebrow {
    margin-bottom: var(--s-6);
  }

  .hero h1 {
    margin-bottom: var(--s-6);
    color: var(--c-text);
  }

  .hero__sub {
    font-size: var(--text-lg);
    color: var(--c-muted);
    max-width: 52ch;
    line-height: 1.6;
    margin-bottom: var(--s-10);
  }

  .hero__actions {
    display: flex;
    gap: var(--s-3);
    flex-wrap: wrap;
    margin-bottom: var(--s-16);
  }

  /* Proof strip at bottom of hero */
  .hero__proof {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--s-6) var(--s-10);
    padding-top: var(--s-10);
    border-top: 1px solid var(--c-border);
  }

  @media (min-width: 500px) {
    .hero__proof {
      grid-template-columns: repeat(4, auto);
      justify-content: start;
    }
  }

  .proof-stat__value {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--c-text);
    font-variant-numeric: tabular-nums;
    line-height: 1;
    margin-bottom: var(--s-1);
  }

  .proof-stat__value--stars {
    color: #E8A020;
    letter-spacing: 0.05em;
  }

  .proof-stat__label {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--c-muted);
  }


  /* ── Section: Philosophie / Vorteile ── */
  .philosophy-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }

  @media (min-width: 720px) {
    .philosophy-grid { grid-template-columns: repeat(3, 1fr); }
  }

  .philosophy-item {
    padding: var(--s-8);
    background: var(--c-surface);
    border-radius: var(--r-lg);
    border: 1px solid var(--c-border);
    transition: border-color var(--t-base), box-shadow var(--t-base);
  }

  .philosophy-item:hover {
    border-color: var(--c-accent);
    box-shadow: var(--shadow-md);
  }

  .philosophy-item__icon {
    font-size: 1.5rem;
    margin-bottom: var(--s-4);
    display: block;
    line-height: 1;
  }

  .philosophy-item h3 {
    font-size: var(--text-base);
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: var(--s-3);
  }

  .philosophy-item p {
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.65;
  }


  /* ── Section: Referenzen (Editorial Grid) ── */
  .ref-editorial {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }

  @media (min-width: 860px) {
    .ref-editorial {
      grid-template-columns: 5fr 4fr;
      align-items: start;
    }
  }

  .ref-card {
    display: block;
    position: relative;
    border-radius: var(--r-xl);
    overflow: hidden;
    background: var(--c-surface);
    border: 1px solid var(--c-border);
    transition: transform var(--t-slow) var(--ease), box-shadow var(--t-slow) var(--ease);
    container-type: inline-size;
  }

  .ref-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
  }

  .ref-card__image {
    aspect-ratio: 16/10;
    background: var(--c-surface-2);
    overflow: hidden;
  }

  .ref-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--t-slow) var(--ease);
  }

  .ref-card:hover .ref-card__image img {
    transform: scale(1.04);
  }

  /* Placeholder wenn kein Screenshot vorhanden */
  .ref-card__image--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--c-dim);
    letter-spacing: 0.1em;
    background: var(--c-surface-2);
  }

  .ref-card__body {
    padding: var(--s-6);
  }

  @container (min-width: 500px) {
    .ref-card__body { padding: var(--s-8); }
  }

  .ref-card__tag {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--c-accent);
    background: var(--c-accent-bg);
    padding: 3px 8px;
    border-radius: var(--r-full);
    margin-bottom: var(--s-4);
  }

  .ref-card__title {
    font-size: var(--text-xl);
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--c-text);
    margin-bottom: var(--s-3);
    line-height: 1.25;
  }

  .ref-card__desc {
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.6;
    margin-bottom: var(--s-6);
  }

  .ref-card__link {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--c-accent);
    display: inline-flex;
    align-items: center;
    gap: var(--s-1);
    transition: gap var(--t-fast);
  }

  .ref-card:hover .ref-card__link { gap: var(--s-2); }


  /* ── Section: Leistungen ── */
  .service-card {
    padding: var(--s-8) var(--s-8) var(--s-8);
    border: 1px solid var(--c-border);
    border-radius: var(--r-xl);
    background: var(--c-bg);
    transition: border-color var(--t-base), box-shadow var(--t-base), transform var(--t-base);
    position: relative;
    overflow: hidden;
  }

  .service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--c-accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--t-slow) var(--ease);
  }

  .service-card:hover {
    border-color: var(--c-accent);
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
  }

  .service-card:hover::before { transform: scaleX(1); }

  .service-card__number {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--c-dim);
    margin-bottom: var(--s-8);
    letter-spacing: 0.1em;
  }

  .service-card h3 {
    font-size: var(--text-xl);
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: var(--s-3);
  }

  .service-card__desc {
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.65;
    margin-bottom: var(--s-6);
  }

  .service-card__price {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--c-text);
  }

  .service-card__price span {
    font-size: var(--text-sm);
    font-weight: 400;
    color: var(--c-muted);
  }


  /* ── Section: Preise ── */
  .pricing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-6);
    align-items: start;
  }

  @media (min-width: 700px) {
    .pricing-grid { grid-template-columns: repeat(3, 1fr); }
  }

  .pricing-card {
    border: 1.5px solid var(--c-border);
    border-radius: var(--r-xl);
    padding: var(--s-8);
    background: var(--c-bg);
    position: relative;
    transition: box-shadow var(--t-base), border-color var(--t-base), transform var(--t-base);
  }

  .pricing-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
  }

  .pricing-card--featured {
    border-color: var(--c-accent);
    background: var(--c-inverse);
    color: var(--c-inv-text);
  }

  .pricing-card--featured:hover { border-color: var(--c-accent); }

  .pricing-card__badge {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    background: var(--c-accent);
    color: white;
    padding: 3px 10px;
    border-radius: var(--r-full);
    margin-bottom: var(--s-6);
  }

  .pricing-card__name {
    font-size: var(--text-sm);
    font-family: var(--font-mono);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--c-muted);
    margin-bottom: var(--s-3);
  }

  .pricing-card--featured .pricing-card__name { color: var(--c-inv-muted); }

  .pricing-card__price {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 3.25rem);
    font-weight: 400;
    line-height: 1;
    color: var(--c-text);
    margin-bottom: var(--s-1);
  }

  .pricing-card--featured .pricing-card__price { color: var(--c-inv-text); }

  .pricing-card__suffix {
    font-size: var(--text-sm);
    color: var(--c-muted);
    margin-bottom: var(--s-6);
    padding-bottom: var(--s-6);
    border-bottom: 1px solid var(--c-border);
  }

  .pricing-card--featured .pricing-card__suffix {
    color: var(--c-inv-muted);
    border-bottom-color: color-mix(in srgb, var(--c-inv-text) 15%, transparent);
  }

  .pricing-card__features {
    display: flex;
    flex-direction: column;
    gap: var(--s-3);
    margin-bottom: var(--s-8);
  }

  .pricing-card__feature {
    display: flex;
    gap: var(--s-3);
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.5;
  }

  .pricing-card--featured .pricing-card__feature { color: var(--c-inv-muted); }

  .pricing-card__feature::before {
    content: '✓';
    color: var(--c-accent);
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 0.1em;
  }


  /* ── Testimonial ── */
  .testimonial {
    text-align: center;
  }

  .testimonial__quote {
    font-family: var(--font-display);
    font-size: var(--text-h2);
    font-weight: 400;
    line-height: 1.3;
    color: var(--c-text);
    max-width: 820px;
    margin-inline: auto;
    margin-bottom: var(--s-10);
    position: relative;
  }

  .testimonial__quote::before {
    content: '\201E';
    font-size: 8rem;
    line-height: 0;
    color: var(--c-border);
    position: absolute;
    top: 0.7rem;
    left: -2rem;
    font-family: var(--font-display);
  }

  @media (max-width: 600px) {
    .testimonial__quote::before { left: 0; top: -1rem; font-size: 4rem; }
    .testimonial__quote { padding-top: var(--s-6); }
  }

  .testimonial__author {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--s-4);
  }

  .testimonial__avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--r-full);
    background: var(--c-surface-2);
    object-fit: cover;
  }

  .testimonial__name {
    font-weight: 600;
    font-size: var(--text-sm);
    color: var(--c-text);
  }

  .testimonial__role {
    font-size: var(--text-xs);
    color: var(--c-muted);
  }


  /* ── Section: Regionen ── */
  .regionen-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }

  @media (min-width: 700px) {
    .regionen-grid { grid-template-columns: repeat(3, 1fr); }
  }

  .region-block__name {
    font-size: var(--text-sm);
    font-family: var(--font-mono);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--c-muted);
    margin-bottom: var(--s-4);
    padding-bottom: var(--s-3);
    border-bottom: 1px solid var(--c-border);
  }

  .region-block__orte {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s-2);
  }

  .ort-pill {
    display: inline-block;
    font-size: var(--text-xs);
    padding: 5px 12px;
    border: 1px solid var(--c-border);
    border-radius: var(--r-full);
    color: var(--c-muted);
    background: var(--c-bg);
    transition: border-color var(--t-fast), color var(--t-fast), background var(--t-fast);
    white-space: nowrap;
  }

  .ort-pill:hover {
    border-color: var(--c-accent);
    color: var(--c-accent);
    background: var(--c-accent-bg);
  }


  /* ── CTA Section ── */
  .cta-section {
    background: var(--c-inverse);
    color: var(--c-inv-text);
    text-align: center;
    padding-block: var(--section-gap);
  }

  .cta-section .eyebrow { color: var(--c-inv-muted); }

  .cta-section h2 {
    color: var(--c-inv-text);
    margin-bottom: var(--s-6);
  }

  .cta-section p {
    font-size: var(--text-lg);
    color: var(--c-inv-muted);
    max-width: 52ch;
    margin-inline: auto;
    line-height: 1.6;
    margin-bottom: var(--s-10);
  }

  .cta-section__actions {
    display: flex;
    gap: var(--s-4);
    justify-content: center;
    flex-wrap: wrap;
  }


  /* ── Footer ── */
  .footer {
    background: var(--c-inverse);
    color: var(--c-inv-muted);
    padding-block: var(--s-16) var(--s-8);
    border-top: 1px solid color-mix(in srgb, var(--c-inv-text) 10%, transparent);
  }

  .footer__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-10);
    margin-bottom: var(--s-16);
  }

  @media (min-width: 640px) {
    .footer__grid { grid-template-columns: 2fr 1fr 1fr; }
  }

  .footer__brand {
    font-size: var(--text-base);
    font-weight: 600;
    color: var(--c-inv-text);
    letter-spacing: -0.02em;
    margin-bottom: var(--s-4);
    display: block;
  }

  .footer__brand span { color: var(--c-accent); }

  .footer__tagline {
    font-size: var(--text-sm);
    line-height: 1.6;
    margin-bottom: var(--s-6);
  }

  .footer__contact a {
    display: flex;
    align-items: center;
    gap: var(--s-2);
    font-size: var(--text-sm);
    color: var(--c-inv-muted);
    margin-bottom: var(--s-2);
    transition: color var(--t-fast);
  }

  .footer__contact a:hover { color: var(--c-inv-text); }

  .footer__col-title {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: color-mix(in srgb, var(--c-inv-text) 45%, transparent);
    margin-bottom: var(--s-4);
    display: block;
  }

  .footer__nav {
    display: flex;
    flex-direction: column;
    gap: var(--s-2);
  }

  .footer__nav a {
    font-size: var(--text-sm);
    color: var(--c-inv-muted);
    transition: color var(--t-fast);
  }

  .footer__nav a:hover { color: var(--c-inv-text); }

  .footer__bottom {
    padding-top: var(--s-6);
    border-top: 1px solid color-mix(in srgb, var(--c-inv-text) 10%, transparent);
    display: flex;
    flex-wrap: wrap;
    gap: var(--s-4);
    align-items: center;
    justify-content: space-between;
    font-size: var(--text-xs);
    color: color-mix(in srgb, var(--c-inv-text) 35%, transparent);
  }

  .footer__legal-links {
    display: flex;
    gap: var(--s-4);
  }

  .footer__legal-links a {
    color: inherit;
    transition: color var(--t-fast);
  }

  .footer__legal-links a:hover {
    color: var(--c-inv-muted);
  }


  /* ── FAB Mobile Call Button ── */
  .fab-call {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 90;
    display: flex;
    align-items: center;
    gap: var(--s-2);
    padding: 0.875rem 1.25rem;
    background: var(--c-accent);
    color: white;
    border-radius: var(--r-full);
    font-size: var(--text-sm);
    font-weight: 600;
    box-shadow: 0 8px 32px rgba(191,22,38,.35);
    transition: transform var(--t-base) var(--ease), box-shadow var(--t-base);
  }

  .fab-call:hover {
    transform: scale(1.05) translateY(-2px);
    box-shadow: 0 12px 40px rgba(191,22,38,.45);
  }

  @media (min-width: 900px) {
    .fab-call { display: none; }
  }

  .fab-call__icon {
    font-size: 1.1rem;
    line-height: 1;
  }

  .fab-call__text {
    display: none;
  }

  @media (min-width: 400px) {
    .fab-call__text { display: inline; }
  }


  /* ── Scroll-Driven Animations (CSS native, no JS) ── */
  @supports (animation-timeline: scroll()) {
    @keyframes fade-up {
      from { opacity: 0; translate: 0 40px; }
      to   { opacity: 1; translate: 0 0; }
    }

    .animate-in {
      animation: fade-up linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 30%;
    }

    /* Stagger for grid children */
    .animate-stagger > * {
      animation: fade-up linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 40%;
    }

    .animate-stagger > *:nth-child(2) { animation-delay: 60ms; }
    .animate-stagger > *:nth-child(3) { animation-delay: 120ms; }
    .animate-stagger > *:nth-child(4) { animation-delay: 180ms; }
  }

  /* Fallback for browsers without scroll-timeline */
  @supports not (animation-timeline: scroll()) {
    .animate-in,
    .animate-stagger > * {
      opacity: 1;
      transform: none;
    }
  }

  /* ── Cookie Banner ── */
  #cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 200;
    background: var(--c-inverse);
    color: var(--c-inv-muted);
    padding: var(--s-4) var(--gutter);
    border-top: 1px solid color-mix(in srgb, var(--c-inv-text) 15%, transparent);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s-4);
    justify-content: space-between;
    font-size: var(--text-sm);
  }

  #cookie-banner p { flex: 1; min-width: 200px; }

  #cookie-banner a {
    color: var(--c-inv-text);
    text-decoration: underline;
  }

  #cookie-banner.is-hidden { display: none; }

  .cookie-actions {
    display: flex;
    gap: var(--s-3);
    flex-shrink: 0;
  }
}

/* ============================================================
   SUBPAGE COMPONENTS (Phase 2)
   ============================================================ */
@layer components {
  /* ---- Page Hero (Unterseiten) ---- */
  .page-hero {
    padding-block: calc(var(--s-20) + var(--nav-h, 4rem)) var(--s-12);
    border-bottom: 1px solid var(--c-border);
  }
  .page-hero__inner { max-width: 52rem; }
  .page-hero h1 {
    font-size: var(--text-h2);
    margin-block: var(--s-3) var(--s-5);
    text-wrap: balance;
  }
  .page-hero__sub {
    font-size: var(--text-lg);
    color: var(--c-muted);
    line-height: 1.6;
    max-width: 42rem;
  }

  /* ---- Breadcrumbs ---- */
  .breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s-2);
    align-items: center;
    font-size: var(--text-sm);
    color: var(--c-muted);
    margin-bottom: var(--s-2);
  }
  .breadcrumbs a { color: var(--c-muted); text-decoration: none; }
  .breadcrumbs a:hover { color: var(--c-accent); }
  .breadcrumbs span[aria-hidden] { color: var(--c-dim); }

  /* ---- Prose (Langtext) ---- */
  .prose { max-width: 44rem; }
  .prose > * + * { margin-top: var(--s-5); }
  .prose h2 {
    font-size: var(--text-xl);
    margin-top: var(--s-12);
    margin-bottom: var(--s-2);
  }
  .prose h3 {
    font-size: var(--text-lg);
    margin-top: var(--s-8);
    margin-bottom: var(--s-2);
  }
  .prose p,
  .prose li { line-height: 1.75; color: var(--c-text); }
  .prose a { color: var(--c-accent); text-underline-offset: 2px; }
  .prose ul,
  .prose ol { padding-left: var(--s-5); }
  .prose li + li { margin-top: var(--s-2); }
  .prose strong { font-weight: 600; }

  /* ---- Feature-Liste (Häkchen) ---- */
  .feature-list { list-style: none; display: grid; gap: var(--s-3); }
  .feature-list li {
    display: flex;
    gap: var(--s-3);
    align-items: flex-start;
    line-height: 1.6;
  }
  .feature-list li::before {
    content: "✓";
    color: var(--c-accent);
    font-weight: 700;
    flex-shrink: 0;
  }

  /* ---- Tags ---- */
  .tag-row { display: flex; flex-wrap: wrap; gap: var(--s-2); }
  .tag {
    font-size: var(--text-xs);
    font-family: var(--font-mono, monospace);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: var(--s-1) var(--s-3);
    border: 1px solid var(--c-border);
    border-radius: 999px;
    color: var(--c-muted);
  }

  /* ---- FAQ Accordion ---- */
  .faq-group { max-width: 48rem; }
  .faq-group + .faq-group { margin-top: var(--s-12); }
  .faq-group__title {
    font-size: var(--text-xl);
    margin-bottom: var(--s-5);
  }
  .faq-item {
    border-bottom: 1px solid var(--c-border);
  }
  .faq-item summary {
    cursor: pointer;
    list-style: none;
    padding-block: var(--s-5);
    font-size: var(--text-lg);
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    gap: var(--s-4);
    align-items: baseline;
  }
  .faq-item summary::-webkit-details-marker { display: none; }
  .faq-item summary::after {
    content: "+";
    color: var(--c-accent);
    font-size: 1.4em;
    line-height: 1;
    flex-shrink: 0;
    transition: transform var(--t, .2s) var(--ease, ease);
  }
  .faq-item[open] summary::after { transform: rotate(45deg); }
  .faq-item__answer {
    padding-bottom: var(--s-5);
    color: var(--c-muted);
    line-height: 1.7;
    max-width: 42rem;
  }
  .faq-item__answer a { color: var(--c-accent); }

  /* ---- Kontakt-Layout ---- */
  .contact-layout {
    display: grid;
    gap: var(--s-12);
    grid-template-columns: 1fr;
  }
  @media (min-width: 860px) {
    .contact-layout { grid-template-columns: 1.4fr 1fr; gap: var(--s-16); }
  }
  .info-list { list-style: none; display: grid; gap: var(--s-6); }
  .info-list__label {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--c-muted);
    margin-bottom: var(--s-1);
  }
  .info-list__value { font-size: var(--text-lg); }
  .info-list__value a { color: var(--c-text); text-decoration: none; }
  .info-list__value a:hover { color: var(--c-accent); }

  /* ---- Formular ---- */
  .contact-form { display: grid; gap: var(--s-5); }
  .form-row { display: grid; gap: var(--s-5); }
  @media (min-width: 540px) {
    .form-row--2 { grid-template-columns: 1fr 1fr; }
  }
  .form-field { display: grid; gap: var(--s-2); }
  .form-field label {
    font-size: var(--text-sm);
    font-weight: 500;
  }
  .form-field input,
  .form-field textarea,
  .form-field select {
    font: inherit;
    font-size: var(--text-base);
    padding: var(--s-3) var(--s-4);
    border: 1px solid var(--c-border);
    border-radius: var(--radius-sm, 8px);
    background: var(--c-bg);
    color: var(--c-text);
    width: 100%;
    transition: border-color var(--t, .2s) var(--ease, ease);
  }
  .form-field input:focus,
  .form-field textarea:focus,
  .form-field select:focus {
    outline: none;
    border-color: var(--c-accent);
  }
  .form-field textarea { resize: vertical; min-height: 8rem; }
  .form-note {
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.6;
  }
  .form-check {
    display: flex;
    gap: var(--s-3);
    align-items: flex-start;
    font-size: var(--text-sm);
    color: var(--c-muted);
    line-height: 1.5;
  }
  .form-check input { width: auto; margin-top: 0.2em; }

  /* ---- Ort-Seite Layout ---- */
  .ort-layout {
    display: grid;
    gap: var(--s-12);
    grid-template-columns: 1fr;
  }
  @media (min-width: 900px) {
    .ort-layout { grid-template-columns: 1fr 18rem; gap: var(--s-16); }
  }
  .ort-sidebar { align-self: start; }
  @media (min-width: 900px) {
    .ort-sidebar { position: sticky; top: calc(var(--nav-h, 4rem) + var(--s-6)); }
  }
  .ort-sidebar__box {
    border: 1px solid var(--c-border);
    border-radius: var(--radius, 14px);
    padding: var(--s-6);
    background: var(--c-surface);
  }
  .ort-sidebar__box + .ort-sidebar__box { margin-top: var(--s-6); }
  .ort-meta { list-style: none; display: grid; gap: var(--s-4); }
  .ort-meta dt {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--c-muted);
  }
  .ort-meta dd { font-size: var(--text-base); margin-top: 2px; }

  /* ---- Nearby-Links ---- */
  .nearby-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s-2);
  }

  /* ---- Warum-Cards Grid ---- */
  .warum-grid {
    display: grid;
    gap: var(--s-6);
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  }
  .warum-card__label {
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--c-accent);
    margin-bottom: var(--s-2);
  }
  .warum-card h3 { font-size: var(--text-lg); margin-bottom: var(--s-2); }
  .warum-card p { color: var(--c-muted); line-height: 1.65; }
}

/* ============================================================
   UTILITIES
   ============================================================ */
@layer utilities {
  .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
  }

  .text-center { text-align: center; }
  .text-muted  { color: var(--c-muted); }
  .text-accent { color: var(--c-accent); }
  .text-display { font-family: var(--font-display); }

  .mt-auto { margin-top: auto; }

  .divider {
    border: none;
    border-top: 1px solid var(--c-border);
    margin-block: var(--s-12);
  }

  /* Fade in via JS class toggle (fallback for older browsers) */
  .js-fade {
    opacity: 0;
    translate: 0 24px;
    transition: opacity var(--t-slow) var(--ease), translate var(--t-slow) var(--ease);
  }

  .js-fade.is-visible {
    opacity: 1;
    translate: 0 0;
  }
}

/* ============================================================
   LIQUID GLASS — Apple-inspired translucency (hell + dunkel)
   ============================================================ */
@layer theme {
  :root {
    /* Glas-Oberflächen */
    --glass-blur:      blur(20px) saturate(180%);
    --glass-blur-soft: blur(14px) saturate(160%);
    --glass-bg:        rgba(255, 255, 255, 0.55);
    --glass-nav:       rgba(250, 250, 248, 0.70);
    --glass-brd:       rgba(255, 255, 255, 0.65);
    --glass-shadow:    0 8px 32px rgba(26, 23, 20, 0.10), 0 2px 8px rgba(26, 23, 20, 0.05);
    --glass-hi:        inset 0 1px 0 rgba(255, 255, 255, 0.85);

    /* Hintergrund-Blobs */
    --blob-1: rgba(191, 22, 38, 0.18);
    --blob-2: rgba(255, 179, 0, 0.16);
    --blob-3: rgba(99, 102, 241, 0.15);
    --blob-opacity: 0.45;
  }

}

@layer base {
  /* Basisfarbe auf html, Body transparent → Blobs liegen dahinter sichtbar */
  html { background: var(--c-bg); }
  body { background: transparent; }
}

@layer components {
  /* ---- Animierte Hintergrund-Blobs ---- */
  .bg-fx {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
    opacity: var(--blob-opacity);
  }
  .bg-fx .blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(72px);
    will-change: transform;
  }
  .blob--1 {
    width: 46vmax; height: 46vmax;
    left: -8vmax; top: -12vmax;
    background: var(--blob-1);
    animation: blob-drift-a 24s var(--ease) infinite alternate;
  }
  .blob--2 {
    width: 40vmax; height: 40vmax;
    right: -6vmax; top: 8vmax;
    background: var(--blob-2);
    animation: blob-drift-b 30s var(--ease) infinite alternate;
  }
  .blob--3 {
    width: 38vmax; height: 38vmax;
    left: 28vmax; bottom: -16vmax;
    background: var(--blob-3);
    animation: blob-drift-c 27s var(--ease) infinite alternate;
  }
  @keyframes blob-drift-a {
    from { transform: translate3d(0,0,0) scale(1); }
    to   { transform: translate3d(8vmax, 6vmax, 0) scale(1.12); }
  }
  @keyframes blob-drift-b {
    from { transform: translate3d(0,0,0) scale(1); }
    to   { transform: translate3d(-7vmax, 5vmax, 0) scale(1.08); }
  }
  @keyframes blob-drift-c {
    from { transform: translate3d(0,0,0) scale(1); }
    to   { transform: translate3d(5vmax, -8vmax, 0) scale(0.92); }
  }

  /* ---- Glas-Navigation ---- */
  .nav {
    background: var(--glass-nav);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-brd);
    box-shadow: var(--glass-hi);
  }
  .nav.is-scrolled {
    box-shadow: var(--glass-shadow), var(--glass-hi);
  }
  .nav__drawer {
    background: var(--glass-nav);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
  }

  /* ---- Glas-Cards (Voll-Glas) ---- */
  .philosophy-item,
  .service-card,
  .pricing-card,
  .ref-card,
  .testimonial,
  .ort-sidebar__box,
  .warum-card,
  .faq-group {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur-soft);
    -webkit-backdrop-filter: var(--glass-blur-soft);
    border-color: var(--glass-brd);
    box-shadow: var(--glass-shadow), var(--glass-hi);
  }
  .warum-card,
  .faq-group {
    padding: var(--s-8);
    border: 1px solid var(--glass-brd);
    border-radius: var(--r-lg);
  }
  .philosophy-item:hover,
  .service-card:hover,
  .pricing-card:hover,
  .ref-card:hover {
    box-shadow: var(--shadow-lg), var(--glass-hi);
    border-color: color-mix(in srgb, var(--c-accent) 30%, var(--glass-brd));
  }

  /* Featured Pricing-Card behält Akzentrahmen */
  .pricing-card--featured {
    border-color: color-mix(in srgb, var(--c-accent) 45%, var(--glass-brd));
  }

  /* ---- Glas-Pills & Tags ---- */
  .ort-pill,
  .tag {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur-soft);
    -webkit-backdrop-filter: var(--glass-blur-soft);
    border-color: var(--glass-brd);
  }
  .ort-pill:hover {
    background: var(--c-accent);
    color: #fff;
    border-color: var(--c-accent);
  }

  /* ---- Glas-Formularfelder ---- */
  .form-field input,
  .form-field textarea,
  .form-field select {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur-soft);
    -webkit-backdrop-filter: var(--glass-blur-soft);
    border-color: var(--glass-brd);
  }

  /* ---- Glas-Hero-Proof ---- */
  .hero__proof {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-brd);
    border-radius: var(--r-xl);
    box-shadow: var(--glass-shadow), var(--glass-hi);
    padding: var(--s-6) var(--s-8);
  }

  /* ---- Surface-Sektionen leicht durchscheinend ---- */
  .section--surface {
    background: color-mix(in srgb, var(--c-surface) 55%, transparent);
    backdrop-filter: var(--glass-blur-soft);
    -webkit-backdrop-filter: var(--glass-blur-soft);
  }

  /* ---- Page-Hero & FAQ durchscheinend ---- */
  .page-hero {
    background: color-mix(in srgb, var(--c-surface) 40%, transparent);
    backdrop-filter: var(--glass-blur-soft);
    -webkit-backdrop-filter: var(--glass-blur-soft);
  }

  /* ---- Bewegungsreduktion: Blobs ruhigstellen ---- */
  @media (prefers-reduced-motion: reduce) {
    .bg-fx .blob { animation: none; }
  }

  /* ---- Fallback ohne backdrop-filter: kräftigere Deckung ---- */
  @supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .nav, .nav__drawer { background: var(--c-bg); }
    .philosophy-item, .service-card, .pricing-card, .ref-card,
    .testimonial, .ort-sidebar__box, .warum-card, .faq-group,
    .hero__proof, .form-field input, .form-field textarea,
    .form-field select, .ort-pill, .tag {
      background: var(--c-surface);
    }
    .section--surface, .page-hero { background: var(--c-surface); }
  }
}
