/* ==========================================================================
   Blaupause – Joomla 6 Template für individuelle Softwareentwicklung
   Design-System: Blueprint / Engineering-Ästhetik
   ========================================================================== */

:root {
  /* Farben */
  --color-ink:      #0a0e14;   /* Fast-Schwarz, Text & dunkle Flächen */
  --color-navy:     #0f2942;   /* Marken-Blau, dunkel */
  --color-blue:     #2c6fa8;   /* Akzent-Blau, Buttons & Links */
  --color-blue-lt:  #4f8fc7;   /* Helleres Blau für Hover/Glow */
  --color-steel:    #5c6b7a;   /* Grau, Fließtext sekundär */
  --color-mist:     #e8ebef;   /* Helles Grau, Flächen */
  --color-line:     #d3d9e0;   /* Trennlinien */
  --color-white:    #ffffff;

  /* Typografie */
  --font-display: "Space Grotesk", "Segoe UI", sans-serif;
  --font-body:    "Inter", "Segoe UI", sans-serif;
  --font-mono:    "JetBrains Mono", "Consolas", monospace;

  /* Abstände & Radien */
  --radius: 3px;
  --gap-section: clamp(4rem, 8vw, 8rem);
  --gap-content: clamp(1.25rem, 3vw, 2rem);
  --container: 1180px;
}

/* --------------------------------------------------------------------
   Basis
   -------------------------------------------------------------------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

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

a {
  color: var(--color-blue);
  text-decoration: none;
}
a:hover { color: var(--color-navy); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.6em;
  color: var(--color-ink);
  letter-spacing: -0.01em;
}

p { margin: 0 0 1em; color: var(--color-steel); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--color-blue);
  margin-bottom: 1em;
}
.eyebrow::before { content: "//"; color: var(--color-steel); }

:focus-visible {
  outline: 2px solid var(--color-blue);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* --------------------------------------------------------------------
   Skip-Link (Barrierefreiheit)
   -------------------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-navy);
  color: var(--color-white);
  padding: 0.75em 1.25em;
  z-index: 1000;
  font-family: var(--font-mono);
  font-size: 0.85rem;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* --------------------------------------------------------------------
   Header
   -------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--color-line);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--color-ink);
}
.brand:hover { color: var(--color-blue); }
.brand-mark {
  width: 30px; height: 30px;
  flex-shrink: 0;
}

/* Hauptnavigation */
.main-nav ul {
  display: flex;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav a {
  font-size: 0.94rem;
  font-weight: 500;
  color: var(--color-ink);
  padding: 0.4em 0;
  border-bottom: 2px solid transparent;
}
.main-nav a:hover,
.main-nav .current > a {
  color: var(--color-blue);
  border-bottom-color: var(--color-blue);
}
.main-nav .parent { position: relative; }
.main-nav .parent > ul {
  display: none;
  position: absolute;
  top: 100%; left: 0;
  min-width: 200px;
  background: var(--color-white);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(15, 41, 66, 0.12);
  padding: 0.5rem;
  flex-direction: column;
  gap: 0;
}
.main-nav .parent:hover > ul,
.main-nav .parent:focus-within > ul { display: flex; }
.main-nav .parent > ul a { display: block; padding: 0.55em 0.75em; border: none; border-radius: var(--radius); }
.main-nav .parent > ul a:hover { background: var(--color-mist); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  width: 42px; height: 38px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block;
  width: 18px; height: 2px;
  background: var(--color-ink);
  position: relative;
}
.nav-toggle span::before,
.nav-toggle span::after { content: ""; position: absolute; }
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }

/* Terminal-Statuszeile unter dem Header */
.status-bar {
  background: var(--color-ink);
  color: #7fb3da;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  overflow: hidden;
  white-space: nowrap;
}
.status-bar .container {
  display: flex;
  gap: 2.5rem;
  padding: 0.4rem 1.5rem;
}
.status-bar span::before { content: "› "; color: #4f8fc7; }
.status-bar .dim { color: #5c6b7a; }

/* --------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------- */
.hero {
  position: relative;
  padding: clamp(4rem, 9vw, 7rem) 0 clamp(3.5rem, 7vw, 5.5rem);
  background:
    linear-gradient(rgba(255,255,255,0.86), rgba(255,255,255,0.94)),
    repeating-linear-gradient(0deg, rgba(44,111,168,0.14) 0 1px, transparent 1px 48px),
    repeating-linear-gradient(90deg, rgba(44,111,168,0.14) 0 1px, transparent 1px 48px);
  border-bottom: 1px solid var(--color-line);
  overflow: hidden;
}
.hero-inner {
  max-width: 780px;
  position: relative;
  z-index: 1;
}
.hero h1 {
  font-size: clamp(2.3rem, 5vw, 3.6rem);
}
.hero .lead {
  font-size: 1.15rem;
  max-width: 58ch;
  color: var(--color-steel);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

/* Blueprint-Koordinatenmarke, dekorativ */
.hero-coords {
  position: absolute;
  right: clamp(1rem, 5vw, 5rem);
  top: 50%;
  transform: translateY(-50%);
  width: 210px; height: 210px;
  border: 1px dashed rgba(44,111,168,0.4);
  border-radius: 50%;
  display: none;
}
.hero-coords::before,
.hero-coords::after {
  content: "";
  position: absolute;
  background: rgba(44,111,168,0.35);
}
.hero-coords::before { top: 50%; left: -20px; right: -20px; height: 1px; }
.hero-coords::after { left: 50%; top: -20px; bottom: -20px; width: 1px; }
@media (min-width: 1000px) { .hero-coords { display: block; } }

/* --------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.85em 1.6em;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn-primary {
  background: var(--color-navy);
  color: var(--color-white);
}
.btn-primary:hover { background: var(--color-blue); color: var(--color-white); transform: translateY(-1px); }
.btn-ghost {
  background: transparent;
  color: var(--color-ink);
  border-color: var(--color-line);
}
.btn-ghost:hover { border-color: var(--color-navy); color: var(--color-navy); }
.btn-on-dark { border-color: rgba(255,255,255,0.35); color: var(--color-white); }
.btn-on-dark:hover { background: var(--color-white); color: var(--color-navy); }

/* --------------------------------------------------------------------
   Abschnitte allgemein
   -------------------------------------------------------------------- */
.section { padding: var(--gap-section) 0; }
.section-alt { background: var(--color-mist); }
.section-dark { background: var(--color-ink); color: var(--color-white); }
.section-dark h2, .section-dark h3 { color: var(--color-white); }
.section-dark p { color: #a7b2be; }

.section-head {
  max-width: 620px;
  margin-bottom: clamp(2.25rem, 5vw, 3.5rem);
}
.section-head h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }

/* --------------------------------------------------------------------
   Leistungen / Module-Karten
   -------------------------------------------------------------------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1px;
  background: var(--color-line);
  border: 1px solid var(--color-line);
}
.card {
  background: var(--color-white);
  padding: 2.25rem 1.9rem;
}
.card-id {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--color-blue);
  display: block;
  margin-bottom: 1rem;
}
.card h3 { font-size: 1.15rem; margin-bottom: 0.5em; }
.card p { margin-bottom: 0; font-size: 0.95rem; }

/* --------------------------------------------------------------------
   Ablauf / Pipeline
   -------------------------------------------------------------------- */
.pipeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0;
  counter-reset: step;
  position: relative;
}
.pipeline::before {
  content: "";
  position: absolute;
  top: 11px; left: 0; right: 0;
  height: 1px;
  background: var(--color-line);
  z-index: 0;
}
.pipeline-step {
  position: relative;
  z-index: 1;
  padding-right: 1.25rem;
}
.pipeline-step .dot {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--color-white);
  border: 2px solid var(--color-blue);
  color: var(--color-blue);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.1rem;
}
.pipeline-step h4 {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.35em;
}
.pipeline-step p { font-size: 0.9rem; margin: 0; }

/* --------------------------------------------------------------------
   Projekte / Portfolio
   -------------------------------------------------------------------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.75rem;
}
.project-card {
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--color-white);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.project-card:hover { box-shadow: 0 16px 32px rgba(15,41,66,0.12); transform: translateY(-2px); }
.project-media {
  aspect-ratio: 16/10;
  background:
    linear-gradient(135deg, var(--color-navy), var(--color-blue));
  position: relative;
}
.project-media::after {
  content: "";
  position: absolute; inset: 0;
  background: repeating-linear-gradient(45deg, rgba(255,255,255,0.06) 0 2px, transparent 2px 14px);
}
.project-body { padding: 1.5rem; }
.project-body h3 { font-size: 1.05rem; margin-bottom: 0.4em; }
.project-body p { font-size: 0.9rem; }
.stack-tags {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin-top: 1rem;
  font-family: var(--font-mono);
}
.stack-tags span {
  font-size: 0.72rem;
  background: var(--color-mist);
  color: var(--color-steel);
  padding: 0.3em 0.6em;
  border-radius: var(--radius);
}

/* --------------------------------------------------------------------
   Kennzahlen
   -------------------------------------------------------------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 2rem;
  border-top: 1px solid var(--color-line);
  border-bottom: 1px solid var(--color-line);
  padding: 2.5rem 0;
}
.stat b {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3.5vw, 2.6rem);
  color: var(--color-navy);
}
.stat span {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--color-steel);
}

/* --------------------------------------------------------------------
   Testimonial
   -------------------------------------------------------------------- */
.testimonial {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}
.testimonial blockquote {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
  font-weight: 500;
  line-height: 1.4;
  margin: 0 0 1.5rem;
  color: var(--color-ink);
}
.testimonial cite {
  font-style: normal;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--color-steel);
}

/* --------------------------------------------------------------------
   CTA
   -------------------------------------------------------------------- */
.cta-section {
  text-align: center;
}
.cta-section h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); max-width: 700px; margin-inline: auto 0.5em; }
.cta-section .lead { max-width: 560px; margin-inline: auto; }
.cta-actions {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 1rem;
  margin-top: 2rem;
}

/* --------------------------------------------------------------------
   Standard-Komponenteninhalt (Artikel, Kategorien, Suche …)
   -------------------------------------------------------------------- */
.content-area { padding: var(--gap-section) 0; }
.content-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}
.content-layout.has-sidebar { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) {
  .content-layout.has-sidebar { grid-template-columns: minmax(0, 2.4fr) minmax(0, 1fr); }
}
.sidebar > * + * { margin-top: 2rem; }
.sidebar .moduletable {
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.sidebar .moduletable h3 {
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-family: var(--font-mono);
  color: var(--color-blue);
}
.main-content article + article { margin-top: 3rem; padding-top: 3rem; border-top: 1px solid var(--color-line); }

/* --------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------- */
.site-footer {
  background: var(--color-navy);
  color: #c4d3e0;
  padding: var(--gap-section) 0 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}
@media (max-width: 800px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
.footer-brand { font-family: var(--font-display); font-weight: 700; color: var(--color-white); font-size: 1.1rem; margin-bottom: 0.75rem; }
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #7fb3da;
  margin-bottom: 1rem;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 0.6em; }
.footer-col a { color: #c4d3e0; font-size: 0.92rem; }
.footer-col a:hover { color: var(--color-white); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem;
  padding-top: 1.75rem;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: #6f8299;
}
.footer-bottom a { color: #6f8299; }
.footer-bottom a:hover { color: var(--color-white); }

/* --------------------------------------------------------------------
   Breadcrumbs
   -------------------------------------------------------------------- */
.breadcrumb-bar { background: var(--color-mist); border-bottom: 1px solid var(--color-line); }
.breadcrumb-bar ol {
  list-style: none; display: flex; flex-wrap: wrap; gap: 0.4em;
  margin: 0; padding: 0.85rem 0;
  font-family: var(--font-mono); font-size: 0.78rem; color: var(--color-steel);
}
.breadcrumb-bar li + li::before { content: "/"; margin-right: 0.4em; color: var(--color-line); }
.breadcrumb-bar a { color: var(--color-steel); }
.breadcrumb-bar a:hover { color: var(--color-blue); }

/* --------------------------------------------------------------------
   Formularelemente (Suche, Kontaktformular, etc.)
   -------------------------------------------------------------------- */
input, textarea, select {
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.7em 0.9em;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  background: var(--color-white);
  color: var(--color-ink);
  width: 100%;
}
input:focus, textarea:focus, select:focus { border-color: var(--color-blue); }
button { font-family: var(--font-body); }

/* --------------------------------------------------------------------
   Mobile Navigation
   -------------------------------------------------------------------- */
@media (max-width: 900px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: fixed;
    inset: 0 0 0 30%;
    background: var(--color-white);
    transform: translateX(100%);
    transition: transform 0.25s ease;
    padding: 5.5rem 1.75rem 2rem;
    overflow-y: auto;
    box-shadow: -20px 0 40px rgba(0,0,0,0.15);
  }
  body.nav-open .main-nav { transform: translateX(0); }
  .main-nav ul { flex-direction: column; gap: 0.25rem; }
  .main-nav .parent > ul {
    display: block;
    position: static;
    box-shadow: none;
    border: none;
    padding-left: 1rem;
  }
  .footer-grid { grid-template-columns: 1fr; }
}
