/* ── Design Tokens ─────────────────────────────────────────────── */
:root {
  --primary:       #DC2626;
  --primary-dark:  #B91C1C;
  --primary-light: #FEE2E2;
  --bg:            #FFFFFF;
  --bg-alt:        #F9FAFB;
  --bg-section:    #F3F4F6;
  --bg-card:       #FFFFFF;
  --text:          #111827;
  --text-muted:    #6B7280;
  --text-light:    #9CA3AF;
  --border:        #E5E7EB;
  --radius:        12px;
  --shadow:        0 1px 4px rgba(0,0,0,0.04), 0 4px 16px rgba(0,0,0,0.06);
  --shadow-hover:  0 8px 32px rgba(0,0,0,0.10);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── Navbar ─────────────────────────────────────────────────────── */
.navbar {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 1rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 0 var(--border);
}

.navbar-brand {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary) !important;
  text-decoration: none;
  letter-spacing: -0.3px;
  transition: opacity 0.2s;
}

.navbar-brand:hover {
  opacity: 0.8;
}

.navbar-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.navbar-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.4rem 0.9rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}

.navbar-links a:hover {
  color: var(--primary);
  background: var(--primary-light);
}

/* ── Hero Background Image ──────────────────────────────────────── */
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

/* Weißer Overlay nur wenn ein Bild vorhanden ist */
.hero:has(.hero-img)::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.72);
  z-index: 1;
  pointer-events: none;
}

/* Hero-Inhalt über dem Overlay */
.hero:has(.hero-img) > *:not(.hero-img) {
  position: relative;
  z-index: 2;
}

/* ── Hero ───────────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(145deg, #ffffff 0%, #fef2f2 55%, #fee2e2 100%);
  padding: 5.5rem 2rem 4.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.hero::before {
  content: '';
  position: absolute;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(220, 38, 38, 0.07) 0%, transparent 65%);
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}

.hero-badge {
  display: inline-block;
  background: var(--primary-light);
  border: 1px solid rgba(220, 38, 38, 0.25);
  color: var(--primary);
  padding: 0.35rem 1.1rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.75rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 1.25rem;
  letter-spacing: -1.5px;
}

.hero h1 span {
  color: var(--primary);
  -webkit-text-fill-color: var(--primary);
  background: none;
}

.hero p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto 2.5rem;
  line-height: 1.75;
}

/* ── Buttons ────────────────────────────────────────────────────── */
.btn-primary-custom {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  padding: 0.8rem 2.25rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  border: none;
  cursor: pointer;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.28);
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
}

.btn-primary-custom:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(220, 38, 38, 0.38);
  color: #fff;
}

.btn-primary-custom:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
}

.btn-outline-custom {
  display: inline-block;
  background: transparent;
  color: var(--primary);
  padding: 0.8rem 2.25rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  border: 2px solid var(--primary);
  margin-left: 0.75rem;
  transition: background 0.2s, color 0.2s, transform 0.2s, box-shadow 0.2s;
}

.btn-outline-custom:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.25);
}

/* ── Sections & Cards ───────────────────────────────────────────── */
.section {
  padding: 3.5rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
}

.section-title {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.section-sub {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 2.5rem;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
  position: relative;
  overflow: hidden;
}

.card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(220, 38, 38, 0.18);
}

.card:hover::after {
  transform: scaleX(1);
}

.card-icon {
  font-size: 1.8rem;
  margin-bottom: 1.1rem;
}

.card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
  line-height: 1.65;
}

.card a {
  color: var(--primary);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: gap 0.2s, color 0.2s;
}

.card a:hover {
  gap: 0.6rem;
  color: var(--primary-dark);
}

/* ── Contact ────────────────────────────────────────────────────── */
.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 3rem;
  align-items: start;
}

.contact-info h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 0.75rem;
  letter-spacing: -0.5px;
}

.contact-info p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 0.95rem;
  line-height: 1.75;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-item-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--primary-light);
  border: 1px solid rgba(220, 38, 38, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.contact-item-text strong {
  display: block;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.contact-item-text a,
.contact-item-text span {
  color: var(--text-muted);
  font-size: 0.88rem;
  text-decoration: none;
}

.contact-item-text a:hover {
  color: var(--primary);
}

/* ── Form ───────────────────────────────────────────────────────── */
.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.25rem;
  box-shadow: var(--shadow);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  color: var(--text);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-light);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.10);
}

.form-group textarea {
  resize: vertical;
  min-height: 130px;
}

/* ── Static Pages (Impressum / Datenschutz) ─────────────────────── */
.page-content {
  max-width: 720px;
  margin: 3rem auto;
  padding: 0 2rem;
}

.page-content .page-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem 3rem;
  box-shadow: var(--shadow);
}

.page-content h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--border);
  letter-spacing: -0.5px;
}

.page-card h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-top: 2rem;
  margin-bottom: 0.6rem;
}

.page-card p,
.page-card li {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

.page-card ul {
  padding-left: 1.5rem;
  margin: 0.5rem 0 1rem;
}

.page-card li {
  margin-bottom: 0.35rem;
}

.page-card a {
  color: var(--primary);
  text-decoration: none;
}

.page-card a:hover {
  text-decoration: underline;
}

.page-card code {
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.1rem 0.45rem;
  font-size: 0.88rem;
  color: var(--text);
  font-family: 'Consolas', 'Courier New', monospace;
}

.info-row {
  display: flex;
  gap: 1rem;
  align-items: center;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

.info-row:last-of-type {
  border-bottom: none;
}

.info-label {
  color: var(--text-muted);
  min-width: 110px;
  font-size: 0.85rem;
  font-weight: 600;
}

.info-value {
  color: var(--text);
}

.info-value a {
  color: var(--primary);
  text-decoration: none;
}

.info-value a:hover {
  text-decoration: underline;
}

/* ── Footer ─────────────────────────────────────────────────────── */
footer {
  margin-top: auto;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 2.5rem 2rem;
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.25rem;
  list-style: none;
  margin-bottom: 1.25rem;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.35rem 0.8rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}

.footer-links a:hover {
  color: var(--primary);
  background: var(--primary-light);
}

.footer-copy {
  color: var(--text-light);
  font-size: 0.82rem;
}

/* ── Joke / Text Page ───────────────────────────────────────────── */
.joke-box {
  max-width: 600px;
  margin: 5rem auto;
  padding: 0 2rem;
  text-align: center;
}

.joke-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem 2.5rem;
  box-shadow: var(--shadow);
}

.joke-card h1 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 1.5rem;
  line-height: 1.55;
}

#text {
  color: var(--primary);
  font-size: 1.1rem;
  font-weight: 600;
  min-height: 1.5rem;
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .navbar {
    padding: 0.9rem 1.25rem;
  }

  .navbar-links {
    gap: 0;
  }

  .navbar-links a {
    padding: 0.35rem 0.65rem;
    font-size: 0.85rem;
  }

  .hero {
    padding: 3.5rem 1.25rem 3rem;
  }

  .section {
    padding: 2.5rem 1.25rem;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .page-content .page-card {
    padding: 1.75rem 1.5rem;
  }

  .btn-outline-custom {
    margin-left: 0;
    margin-top: 0.75rem;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    letter-spacing: -0.5px;
  }

  .navbar-links a {
    font-size: 0.8rem;
    padding: 0.3rem 0.5rem;
  }

  .page-content {
    padding: 0 1rem;
  }
}
