/* ══════════════════════════════════════════════════════════════
   Homepage stefans-projekte.de – oeffentliche Seiten.
   Bewusst eigenes Stylesheet: die Homepage ist hell und geschaeftlich,
   das App-Dashboard (dashboard.css) bleibt dunkel.
   ══════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:          #ffffff;
  --bg-soft:     #f6f8fb;
  --bg-deep:     #0f1117;   /* Hero/Footer – Bruecke zum Dashboard-Look */
  --border:      #e3e8ef;
  --text:        #1a1f2e;
  --text-muted:  #5c6579;
  --text-invert: #e8ecf4;
  --accent:      #2f6fdb;
  --accent-hover:#255ab4;
  --accent-soft: #eaf1fd;
  --radius:      14px;
  --shadow-sm:   0 1px 3px rgba(16,24,40,.06), 0 1px 2px rgba(16,24,40,.04);
  --shadow-md:   0 8px 24px rgba(16,24,40,.10);
  --wrap:        1120px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); }

.skip-link {
  position: absolute; left: -9999px;
  background: var(--accent); color: #fff;
  padding: .75rem 1.25rem; border-radius: 0 0 var(--radius) 0;
  z-index: 200;
}
.skip-link:focus { left: 0; top: 0; }

/* ── Header ───────────────────────────────────────────────── */
.site-header {
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px; gap: 1rem;
}

.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--text); }
.brand-mark {
  display: grid; place-items: center;
  width: 38px; height: 38px; flex-shrink: 0;
  background: var(--bg-deep); color: #fff;
  border-radius: 10px;
  font-weight: 700; font-size: .9rem; letter-spacing: .02em;
}
.brand-text { font-weight: 650; font-size: 1.05rem; letter-spacing: -.01em; }

.site-nav { display: flex; align-items: center; gap: .35rem; }
.site-nav a {
  padding: .55rem .85rem; border-radius: 8px;
  color: var(--text-muted); text-decoration: none;
  font-size: .925rem; font-weight: 500;
  transition: color .15s, background .15s;
}
.site-nav a:hover { color: var(--text); background: var(--bg-soft); }
.site-nav a.is-active { color: var(--accent); background: var(--accent-soft); }

.nav-app {
  margin-left: .5rem;
  background: var(--bg-deep) !important;
  color: #fff !important;
  font-weight: 600 !important;
}
.nav-app:hover { background: #232838 !important; }

/* Hamburger – nur mobil sichtbar */
.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  background: none; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer;
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
}
.nav-toggle span {
  display: block; width: 18px; height: 2px;
  background: var(--text); border-radius: 2px;
}

/* ── Hero ─────────────────────────────────────────────────── */
.hero {
  background: var(--bg-deep);
  color: var(--text-invert);
  padding: 6rem 0 5.5rem;
  /* dezenter Farbschimmer, kein externes Bild noetig */
  background-image:
    radial-gradient(ellipse 80% 60% at 15% -10%, rgba(47,111,219,.28), transparent),
    radial-gradient(ellipse 60% 50% at 95% 10%, rgba(47,111,219,.12), transparent);
}
.hero-kicker {
  text-transform: uppercase; letter-spacing: .12em;
  font-size: .75rem; font-weight: 600;
  color: #8fb4f0; margin-bottom: 1.25rem;
}
.hero h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.6rem);
  line-height: 1.12; font-weight: 750; letter-spacing: -.025em;
  margin-bottom: 1.5rem;
}
.hero-lead {
  font-size: clamp(1.02rem, 2vw, 1.2rem);
  color: #b3bdd0; max-width: 41rem; margin-bottom: 2.25rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; }

/* ── Buttons – grosszuegig, gut tappbar ───────────────────── */
.btn {
  display: inline-block;
  padding: .9rem 1.75rem;
  border-radius: 10px; border: 1px solid transparent;
  font-size: 1rem; font-weight: 600;
  text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s;
  min-height: 48px;   /* Touch-Ziel */
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost {
  background: transparent; color: var(--text-invert);
  border-color: rgba(255,255,255,.28);
}
.btn-ghost:hover { background: rgba(255,255,255,.08); }

/* ── Sections ─────────────────────────────────────────────── */
.section { padding: 4.5rem 0; }
.section-alt { background: var(--bg-soft); border-block: 1px solid var(--border); }
.section-heading {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700; letter-spacing: -.02em;
  margin-bottom: 2.25rem;
}

/* ── Karten ───────────────────────────────────────────────── */
.card-grid {
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.card {
  display: flex; flex-direction: column; gap: .6rem;
  background: var(--bg);
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.75rem;
  text-decoration: none; color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.card-icon { font-size: 2rem; line-height: 1; }
.card h3 { font-size: 1.2rem; font-weight: 650; letter-spacing: -.01em; }
.card p { color: var(--text-muted); font-size: .95rem; flex-grow: 1; }
.card-link { color: var(--accent); font-weight: 600; font-size: .925rem; margin-top: .35rem; }

/* ── Werte-Raster ─────────────────────────────────────────── */
.value-grid {
  display: grid; gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.value h3 { font-size: 1.1rem; font-weight: 650; margin-bottom: .6rem; }
.value p { color: var(--text-muted); font-size: .95rem; }

/* ── Unterseiten-Kopf ─────────────────────────────────────── */
.page-hero {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
  padding: 3.5rem 0 3rem;
}
.page-hero-icon { font-size: 2.75rem; display: block; margin-bottom: .75rem; }
.page-hero h1 {
  font-size: clamp(1.9rem, 4.5vw, 2.85rem);
  font-weight: 750; letter-spacing: -.025em; line-height: 1.15;
}
.page-hero-lead {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-muted); max-width: 42rem; margin-top: 1rem;
}

/* ── Fliesstext ───────────────────────────────────────────── */
.prose { max-width: 46rem; }
.prose h2 {
  font-size: 1.4rem; font-weight: 680; letter-spacing: -.015em;
  margin: 2.5rem 0 .85rem;
}
.prose h2:first-child { margin-top: 0; }
.prose p { margin-bottom: 1.1rem; color: #333a4d; }
.prose code {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 5px; padding: .1em .4em;
  font-size: .875em; font-family: ui-monospace, "SF Mono", Menlo, monospace;
}
.prose-cta { margin-top: 2rem; }

/* Rechtstexte duerfen etwas kleiner und ruhiger sein */
.prose-legal { font-size: .95rem; }
.prose-legal h2 { font-size: 1.15rem; margin-top: 2.25rem; }
.legal-updated {
  margin-top: 3rem; padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted); font-size: .875rem;
}

.detail-block { margin-bottom: 2.5rem; }

.check-list { list-style: none; margin-bottom: 1.25rem; }
.check-list li {
  position: relative; padding-left: 1.75rem; margin-bottom: .6rem;
  color: #333a4d;
}
.check-list li::before {
  content: "";
  position: absolute; left: .2rem; top: .62em;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
}

/* ── Kontaktkarten ────────────────────────────────────────── */
.contact-card {
  display: flex; gap: 1.25rem; align-items: flex-start;
  background: var(--bg-soft);
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.75rem; margin-bottom: 1.25rem;
}
.contact-icon { font-size: 1.75rem; line-height: 1.2; }
.contact-card h2 { font-size: 1.05rem; margin: 0 0 .4rem; }
.contact-mail {
  font-size: 1.15rem; font-weight: 600;
  color: var(--accent); text-decoration: none;
  word-break: break-word;
}
.contact-mail:hover { text-decoration: underline; }
.contact-note { color: var(--text-muted); font-size: .875rem; margin: .5rem 0 0 !important; }

/* ── Schlussaufruf ────────────────────────────────────────── */
.cta {
  background: var(--bg-deep); color: var(--text-invert);
  padding: 4rem 0; text-align: center;
}
.cta h2 {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 700; letter-spacing: -.02em; margin-bottom: .75rem;
}
.cta p { color: #a8b2c6; margin-bottom: 1.75rem; }

/* ── Footer ───────────────────────────────────────────────── */
.site-footer { background: var(--bg-deep); color: #9aa4b8; padding: 3.5rem 0 1.5rem; }
.footer-inner {
  display: flex; flex-wrap: wrap; gap: 2.5rem;
  justify-content: space-between; align-items: flex-start;
  padding-bottom: 2.5rem;
}
.footer-brand { display: flex; gap: .85rem; align-items: center; }
.footer-brand .brand-mark { background: #232838; }
.footer-brand strong { color: var(--text-invert); font-size: 1rem; }
.footer-brand p { font-size: .875rem; margin-top: .15rem; }

.footer-nav { display: grid; grid-template-columns: repeat(2, auto); gap: .5rem 2.5rem; }
.footer-nav a {
  color: #9aa4b8; text-decoration: none; font-size: .9rem;
  padding: .2rem 0;
}
.footer-nav a:hover { color: var(--text-invert); }

.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem; flex-wrap: wrap;
  border-top: 1px solid rgba(255,255,255,.09);
  padding-top: 1.5rem;
  font-size: .8rem; color: #6b7488;
}
.footer-version { font-family: ui-monospace, monospace; font-size: .72rem; }

/* ── Mobil ────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .nav-toggle { display: flex; }

  .site-nav {
    display: none;
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: .25rem;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem 1.5rem;
    box-shadow: var(--shadow-md);
  }
  .site-nav.is-open { display: flex; }
  /* Mobil grosszuegige Tapp-Flaechen */
  .site-nav a { padding: .95rem 1rem; font-size: 1rem; min-height: 48px; display: flex; align-items: center; }
  .nav-app { margin-left: 0; margin-top: .5rem; justify-content: center; }

  .hero { padding: 4rem 0 3.5rem; }
  .hero-actions .btn { flex: 1 1 100%; text-align: center; }
  .section { padding: 3rem 0; }
  .footer-inner { flex-direction: column; gap: 2rem; }
  .footer-nav { grid-template-columns: 1fr; }
}

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