:root {
  --primary:      #457c1f;   /* BSZ Grün */
  --primary-dark: #2f5614;   /* BSZ Grün dunkel */
  --primary-light:#e8f3df;   /* BSZ Grün hell */
  --accent:       #dedd21;   /* BSZ Gelbgrün */
  --accent-dark:  #b8b900;
  --red:          #e32513;   /* BSZ Rot */
  --green:        #457c1f;
  --gray:         #6b7280;
  --bg:           #f4f6f1;   /* leicht grünliches Grau */
  --card:         #ffffff;
  --border:       #dde8d4;   /* grünlicher Rand */
}

* { box-sizing: border-box; }

body {
  font-family: "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  margin: 0;
  color: #111827;
}

header {
  background: var(--primary-dark);
  color: white;
  padding: 0.6rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 4px solid var(--accent);
}

header .header-logo {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  text-decoration: none;
}
header .header-logo img {
  height: 44px;
  width: auto;
}
header .header-title {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
header .header-title span:first-child {
  font-size: 0.7rem;
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
header .header-title span:last-child {
  font-size: 1rem;
  font-weight: 700;
  color: white;
}
header h1 { font-size: 1rem; margin: 0; }

header nav {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  flex-wrap: wrap;
}
header nav a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  margin-left: 0.2rem;
  font-size: 0.85rem;
  padding: 0.3rem 0.7rem;
  border-radius: 4px;
  transition: background 0.15s;
}
header nav a:hover { background: rgba(255,255,255,0.15); color: white; }

main {
  max-width: 900px;
  margin: 2rem auto;
  padding: 0 1rem;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

h2 { margin-top: 0; }

label {
  display: block;
  margin-top: 1rem;
  margin-bottom: 0.3rem;
  font-weight: 600;
  font-size: 0.9rem;
}

input, textarea, select {
  width: 100%;
  padding: 0.6rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.95rem;
  font-family: inherit;
}

textarea { resize: vertical; min-height: 70px; }

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
}
.checkbox-row input { width: auto; }

button {
  background: var(--primary);
  color: white;
  border: none;
  padding: 0.7rem 1.4rem;
  border-radius: 6px;
  font-size: 0.95rem;
  cursor: pointer;
  margin-top: 1.5rem;
}
button:hover { background: var(--primary-dark); }
button.secondary { background: var(--gray); }
button.danger { background: var(--red); }
button.success { background: var(--green); }

.error { color: var(--red); font-size: 0.9rem; margin-top: 0.5rem; }
.hint { color: var(--gray); font-size: 0.85rem; }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 0.6rem; border-bottom: 1px solid var(--border); font-size: 0.9rem; }
th { color: var(--gray); font-weight: 600; }

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
}
.badge.offen { background: #fef3c7; color: #92400e; }
.badge.genehmigt { background: #dcfce7; color: #166534; }
.badge.abgelehnt { background: #fee2e2; color: #991b1b; }

.tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}
.tile {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.2rem;
  text-decoration: none;
  color: #111827;
  display: block;
}
.tile:hover { border-color: var(--primary); background: var(--primary-light); }
.tile h3 { margin: 0 0 0.4rem 0; font-size: 1rem; color: var(--primary-dark); }
.tile p { margin: 0; font-size: 0.85rem; color: var(--gray); }

.login-box {
  max-width: 360px;
  margin: 4rem auto;
}

fieldset {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.8rem 1rem;
  margin-top: 1rem;
}
fieldset legend {
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0 0.3rem;
}

.radio-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem 1.5rem;
  margin-top: 0.4rem;
}
.radio-row label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: normal;
  margin: 0;
  cursor: pointer;
}
.radio-row input[type="radio"] { width: auto; }

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.checkbox-grid label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: normal;
  margin: 0;
  cursor: pointer;
}
.checkbox-grid input[type="checkbox"] { width: auto; }
