/* =========================================
   styles-pages.css – Überarbeitetes Layout
   ========================================= */

:root {
  --bg: #dff5e3;
  --bg-elev: #e8f9ec;
  --surface: #f5fff7;
  --text: #20351e;
  --muted: #5a7f57;

  --brand: #8fdf70;
  --brand-2: #b9f39b;

  --radius: 14px;
  --radius-sm: 8px;
  --gap: 1rem;
  --shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
}

:root[data-theme="light"] {
  --bg: #ffffff;
  --bg-elev: #f6fff8;
  --surface: #ffffff;
  --text: #1c2d1a;
  --muted: #4f6f4c;
  --brand: #9ce57c;
  --brand-2: #d5f7c5;
  --shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

/* Grundlayout */
html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font: clamp(16px, 1.6vw + 12px, 20px) / 1.6 system-ui, -apple-system,
    "Segoe UI", Roboto, Inter, Ubuntu, "Helvetica Neue", Arial, "Noto Sans";
  min-height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1rem 4rem;
}

/* Überschrift */
header {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 700;
  margin-bottom: 2rem;
  color: var(--text);
  text-align: center;
  letter-spacing: 0.5px;
}

/* Navigation */
ul {
  list-style: none;
  padding: 0;
  margin: 0 auto 2rem;
  max-width: 650px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--gap);
}

li {
  display: flex;
}

a {
  flex: 1;
  display: block;
  padding: 1rem 1.4rem;
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface), var(--bg-elev));
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border 0.25s ease,
    background 0.3s ease;
}

a:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
  border: 1px solid var(--brand);
  background: linear-gradient(180deg, var(--bg-elev), var(--surface));
}

/* Buttons */
.btn {
  appearance: none;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.35),
    rgba(255, 255, 255, 0.1)
  );
  color: var(--text);
  padding: 0.7rem 1.2rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: transform 0.04s ease, border-color 0.2s, background 0.2s;
  display: inline-block;
}

.btn:hover {
  border-color: var(--brand);
}

.btn:active {
  transform: translateY(1px);
}

.btn.primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #20351e;
  font-weight: 600;
}

/* Footer */
footer {
  margin-top: auto;
  padding: 1.2rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

/* ================================
   Mobile-Optimierung – verbessert
   ================================ */
@media (max-width: 768px) {
  body {
    padding: 1rem;
  }

  header {
    font-size: 1.6rem;
    margin-bottom: 1.2rem;
  }

  ul {
    grid-template-columns: 1fr; /* Navigation untereinander */
    gap: 1rem;
  }

  a {
    font-size: 1.2rem; /* größere Schrift */
    padding: 1.2rem 1rem; /* mehr Fläche zum Antippen */
    border-radius: 16px; /* rundere Ecken */
  }

  footer {
    font-size: 0.8rem;
    padding: 0.8rem;
  }
}

@media (max-width: 480px) {
  header {
    font-size: 1.4rem;
  }

  a {
    font-size: 1.1rem;
    padding: 1rem; /* mindestens 44px Höhe */
    border-radius: 18px;
  }
}
