/* ----------- Reset / Normalize ----------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html, body {
  height: 100%;
  font-family: system-ui, sans-serif;
  line-height: 1.5;
  background: #f9f9f9;
  color: #222;
}

/* ----------- Flexibles Layout ----------- */
body { 
  max-width: 1200px;       /* Inhalt nie breiter als 1200px */
  margin: 2rem auto;       /* oben/unten 2rem, links/rechts automatisch = mittig */
  font-family: system-ui, sans-serif; 
  padding: 0 1rem;         /* innen noch 1rem Abstand, damit Text nicht direkt am Rand klebt */
}

main {
  flex: 1; /* nimmt alles an Platz zwischen Header und Footer */
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
}

/* ----------- Typographie ----------- */
h1, h2, h3 {
  margin-bottom: .5rem;
  font-weight: 600;
}
p {
  margin-bottom: 1rem;
  max-width: 60ch;
}

/* ----------- Flexbox-Container ----------- */
.flex {
  display: flex;
  gap: 1rem;
}
.flex.center {
  align-items: center;
  justify-content: center;
}
.flex.between {
  justify-content: space-between;
}

/* ----------- Tabellen ----------- */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}
th, td {
  border: 1px solid #ccc;
  padding: .5rem .75rem;
  text-align: left;
}
thead {
  background: #eee;
}

/* ----------- Buttons ----------- */
button, .btn {
  background: #0a3a8d;
  color: #fff;
  border: none;
  padding: .5rem 1rem;
  border-radius: .3rem;
  cursor: pointer;
}
button:hover, .btn:hover {
  background: #062b66;
}

.btnback {
  background: #ccc;
  color: #222;
}

/* ----------- Footer ----------- */
footer {
  background: #eee;
  padding: .5rem 1rem;
  text-align: center;
}

/* ----------- Cards ----------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: .5rem;
  padding: 1rem;
  box-shadow: 0 2px 6px rgba(77, 29, 29, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;   /* kein Unterstrich */
  color: inherit;          /* Schriftfarbe erben */
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

