@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('fonts/bricolage-grotesque.woff2') format('woff2');
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('fonts/source-serif-4.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/ibm-plex-mono-400.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/ibm-plex-mono-500.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/ibm-plex-mono-600.woff2') format('woff2');
}

:root {
    color-scheme: dark;
    --bg: #0f2038;
    --bg-elevated: #16304f;
    --bg-elevated-2: #1c3a5e;
    --ink: #eef2f7;
    --ink-muted: #a9b4c8;
    --ink-faint: #7c8aa3;
    --brand: #7fb2e8;
    --brand-ink: #0f2038;
    --accent: #ef9750;
    --accent-ink: #1c1006;
    --accent-hover: #db843c;
    --accent-active: #c67226;
    --success: #6cc581;
    --warning: #d8bd51;
    --danger: #ff847d;
    --line: rgba(238, 242, 247, 0.14);
    --line-strong: rgba(238, 242, 247, 0.24);
    --focus: #ef9750;
    --shadow: 0 20px 50px -25px rgba(0, 0, 0, 0.55);
    --font-display: 'Bricolage Grotesque', 'Arial Narrow', sans-serif;
    --font-body: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;
  }

  /* Bewusst nur ein dunkles Theme: das Dorfschmiede-Logo hat fest
     eingebrannte helle Schrift und ist nur auf dunklem Grund lesbar. */

  html { scroll-behavior: smooth; }
  * { box-sizing: border-box; }

  body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
  }

  .wrap {
    max-width: 960px;
    margin: 0 auto;
    padding-inline: 24px;
  }

  a { color: inherit; }
  a:focus-visible, button:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 3px;
    border-radius: 3px;
  }

  h1, h2, h3 { font-family: var(--font-display); text-wrap: balance; margin: 0; }

  .eyebrow {
    font-family: var(--font-mono);
    font-size: 12.5px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--brand);
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 14px;
  }
  .eyebrow::before {
    content: "";
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--brand);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent);
    flex: none;
  }

  /* ---- Header ---- */
  .site-header {
    position: sticky;
    top: env(safe-area-inset-top, 0px);
    z-index: 20;
    background: color-mix(in srgb, var(--bg) 86%, transparent);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
  }
  .site-header .wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-block: 16px;
    gap: 16px;
  }
  .wordmark {
    display: flex;
    align-items: center;
    gap: 9px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 19px;
    letter-spacing: -0.01em;
    text-decoration: none;
    color: var(--ink);
    white-space: nowrap;
  }
  .spark { flex: none; display: block; }
  nav.primary {
    display: flex;
    gap: clamp(14px, 3vw, 28px);
    font-family: var(--font-mono);
    font-size: 13px;
    letter-spacing: 0.02em;
  }
  nav.primary a {
    text-decoration: none;
    color: var(--ink-muted);
    padding-block: 4px;
    border-bottom: 1px solid transparent;
    transition: color .15s cubic-bezier(0.22,1,0.36,1), border-color .15s cubic-bezier(0.22,1,0.36,1), opacity .08s ease;
  }
  nav.primary a:hover { color: var(--ink); border-color: var(--line-strong); }
  nav.primary a:active { opacity: 0.6; transition-duration: .08s; }

  .nav-toggle-btn {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    padding: 8px;
    margin: -8px;
    color: var(--ink);
    cursor: pointer;
    border-radius: 6px;
    transition: opacity .08s ease;
  }
  .nav-toggle-btn:active { opacity: 0.6; }
  .nav-toggle-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

  /* ---- Hero ---- */
  .hero {
    position: relative;
    overflow: clip;
    padding-block: clamp(56px, 9vw, 104px) clamp(48px, 7vw, 84px);
    border-bottom: 1px solid var(--line);
  }
  .hero::before {
    content: "";
    position: absolute;
    inset: -20% -10% auto -10%;
    height: 480px;
    background: radial-gradient(closest-side, color-mix(in srgb, var(--brand) 22%, transparent), transparent 72%);
    filter: blur(10px);
    animation: glow 11s ease-in-out infinite;
    pointer-events: none;
  }
  @keyframes glow {
    0%, 100% { opacity: 0.4; transform: translateY(0); }
    50% { opacity: 0.65; transform: translateY(14px); }
  }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .hero::before { animation: none; opacity: 0.7; }
  }
  @media (prefers-reduced-transparency: reduce) {
    .site-header { background: var(--bg); backdrop-filter: none; }
  }
  @media (prefers-contrast: more) {
    .site-header { background: var(--bg); border-bottom: 1px solid var(--line-strong); }
  }
  .hero-inner { position: relative; max-width: 720px; }
  .hero h1 {
    font-size: clamp(34px, 5.2vw, 56px);
    font-weight: 700;
    line-height: 1.08;
    letter-spacing: -0.015em;
  }
  .hero p.lede {
    margin: 22px 0 0;
    max-width: 58ch;
    font-size: clamp(17px, 1.7vw, 19px);
    color: var(--ink-muted);
  }
  .hero-cta {
    margin-top: 32px;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
  }
  .btn {
    font-family: var(--font-mono);
    font-size: 13.5px;
    letter-spacing: 0.02em;
    text-decoration: none;
    padding: 13px 22px;
    border-radius: 5px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform .15s cubic-bezier(0.22,1,0.36,1), box-shadow .15s cubic-bezier(0.22,1,0.36,1), background .15s cubic-bezier(0.22,1,0.36,1), border-color .15s cubic-bezier(0.22,1,0.36,1), color .15s cubic-bezier(0.22,1,0.36,1);
  }
  .btn-primary {
    background: var(--accent);
    color: var(--accent-ink);
    box-shadow: var(--shadow);
  }
  .btn-primary:hover { transform: translateY(-1px); background: var(--accent-hover); }
  .btn-primary:active { transform: translateY(0) scale(0.96); background: var(--accent-active); box-shadow: 0 10px 24px -18px rgba(0,0,0,.55); transition-duration: .08s; }
  .btn-ghost {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--line-strong);
  }
  .btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
  .btn-ghost:active { transform: scale(0.96); transition-duration: .08s; }

  /* ---- Sections ---- */
  section.block { padding-block: clamp(56px, 8vw, 92px); border-bottom: 1px solid var(--line); }
  section.block:last-of-type { border-bottom: none; }
  .block-head { max-width: 62ch; margin-bottom: 40px; }
  .block-head h2 {
    font-size: clamp(26px, 3.4vw, 34px);
    font-weight: 700;
    letter-spacing: -0.01em;
  }
  .block-head p {
    margin: 16px 0 0;
    color: var(--ink-muted);
    max-width: 56ch;
  }
  .about-intro {
    max-width: 66ch;
    color: var(--ink-muted);
    margin-bottom: 44px;
  }
  .about-intro strong { color: var(--ink); font-weight: 600; }

  /* ---- Timeline ---- */
  .timeline { display: flex; flex-direction: column; }
  .tl-row {
    display: grid;
    grid-template-columns: 168px 1fr;
    gap: 24px;
    padding-block: 18px;
    border-top: 1px solid var(--line);
  }
  .tl-row:last-child { border-bottom: 1px solid var(--line); }
  .tl-date {
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--brand);
    padding-top: 2px;
    white-space: nowrap;
  }
  .tl-text { color: var(--ink); }
  .tl-text .now-tag {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--brand);
    border: 1px solid color-mix(in srgb, var(--brand) 45%, transparent);
    border-radius: 999px;
    padding: 2px 8px;
    margin-left: 8px;
    vertical-align: middle;
  }

  /* ---- Services ---- */
  .services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  .service-card {
    background: var(--bg-elevated);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 28px 26px;
  }
  .service-card h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
  }
  .service-card ul {
    list-style: none;
    margin: 0; padding: 0;
    display: flex; flex-direction: column; gap: 11px;
    color: var(--ink-muted);
    font-size: 15.5px;
  }
  .service-card li { display: flex; gap: 10px; }
  .service-card li::before {
    content: "";
    width: 5px; height: 5px;
    margin-top: 9px;
    border-radius: 1px;
    transform: rotate(45deg);
    background: var(--brand);
    flex: none;
  }

  /* ---- Work / Referenzen ---- */
  .work-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
  .work-card {
    background: var(--bg-elevated);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 24px 24px 22px;
    display: flex;
    flex-direction: column;
    gap: 10px;
  }
  .work-top { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 8px 12px; }
  .work-card h3 { font-size: 18px; font-weight: 700; min-width: 0; overflow-wrap: break-word; }
  .status {
    font-family: var(--font-mono);
    font-size: 10.5px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    white-space: nowrap;
    padding: 4px 9px;
    border-radius: 999px;
    flex: none;
  }
  .status-live { background: color-mix(in srgb, var(--success) 14%, transparent); color: var(--success); border: 1px solid color-mix(in srgb, var(--success) 40%, transparent); }
  .status-progress { background: var(--bg-elevated-2); color: var(--ink-muted); border: 1px solid var(--line-strong); }
  .work-card p { margin: 0; color: var(--ink-muted); font-size: 15px; }
  .work-card .link {
    margin-top: auto;
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--brand);
    text-decoration: none;
    width: fit-content;
    border-bottom: 1px solid transparent;
    transition: opacity .08s ease;
  }
  .work-card .link:hover { border-color: currentColor; }
  .work-card .link:active { opacity: 0.6; }

  /* ---- Contact ---- */
  .contact-panel {
    background: var(--bg-elevated);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: clamp(28px, 5vw, 48px);
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    align-items: center;
    justify-content: space-between;
  }
  .contact-panel .copy { max-width: 44ch; }
  .contact-panel h2 { font-size: clamp(24px, 3vw, 30px); margin-bottom: 12px; }
  .contact-panel p { margin: 0; color: var(--ink-muted); }
  .contact-actions { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
  .email-line {
    font-family: var(--font-mono);
    font-size: 14px;
    color: var(--ink-muted);
  }
  .region-line {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--ink-faint);
    letter-spacing: 0.02em;
  }

  footer {
    padding-block: 28px 40px;
  }
  footer .wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--ink-faint);
  }
  .footer-brand img { display: block; height: 40px; width: auto; }
  .footer-links { display: flex; gap: 16px; }
  .footer-links a {
    color: var(--ink-faint);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: color .15s ease, border-color .15s ease;
  }
  .footer-links a:hover { color: var(--ink-muted); border-color: var(--line-strong); }

  /* ---- Rechtstexte (Impressum/Datenschutz) ---- */
  .legal-page { padding-block: clamp(48px, 8vw, 80px); }
  .legal-page .wrap { max-width: 720px; }
  .legal-page .back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--brand);
    text-decoration: none;
    margin-bottom: 32px;
  }
  .legal-page .back-link:hover { text-decoration: underline; }
  .legal-page h1 {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 38px);
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0 0 8px;
  }
  .legal-page .updated {
    font-family: var(--font-mono);
    font-size: 12.5px;
    color: var(--ink-faint);
    margin: 0 0 40px;
  }
  .legal-page h2 {
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 700;
    margin: 40px 0 14px;
  }
  .legal-page h2:first-of-type { margin-top: 0; }
  .legal-page h3 {
    font-family: var(--font-display);
    font-size: 17px;
    font-weight: 600;
    margin: 24px 0 10px;
  }
  .legal-page p, .legal-page li { color: var(--ink-muted); margin: 0 0 14px; }
  .legal-page ul { margin: 0 0 14px; padding-left: 20px; }
  .legal-page a {
    color: var(--brand);
    text-decoration: underline;
    text-decoration-color: color-mix(in srgb, var(--brand) 40%, transparent);
  }
  .legal-page a:hover { text-decoration-color: currentColor; }
  .legal-page strong { color: var(--ink); font-weight: 600; }

  @media (max-width: 720px) {
    .nav-toggle-btn { display: inline-flex; }
    nav.primary {
      flex-direction: column;
      gap: 2px;
      position: absolute;
      top: 100%;
      left: 0;
      right: 0;
      background: color-mix(in srgb, var(--bg) 96%, transparent);
      backdrop-filter: blur(10px);
      border-bottom: 1px solid var(--line);
      padding: 8px 24px 16px;
      opacity: 0;
      transform: translateY(-8px);
      visibility: hidden;
      pointer-events: none;
      transition: opacity .22s cubic-bezier(0.22,1,0.36,1), transform .22s cubic-bezier(0.22,1,0.36,1), visibility 0s linear .22s;
    }
    nav.primary.open {
      opacity: 1;
      transform: translateY(0);
      visibility: visible;
      pointer-events: auto;
      transition: opacity .22s cubic-bezier(0.22,1,0.36,1), transform .22s cubic-bezier(0.22,1,0.36,1), visibility 0s linear 0s;
    }
    nav.primary a { padding-block: 10px; border-bottom: 1px solid var(--line); }
    nav.primary a:last-child { border-bottom: none; }
    .services-grid, .work-grid { grid-template-columns: 1fr; }
    .tl-row { grid-template-columns: 1fr; gap: 6px; }
    .contact-panel { flex-direction: column; align-items: flex-start; }
  }
  @media (max-width: 720px) and (prefers-reduced-motion: reduce) {
    nav.primary { transition: opacity .15s ease, visibility 0s linear .15s; transform: none; }
    nav.primary.open { transition: opacity .15s ease, visibility 0s linear 0; transform: none; }
  }
