* { box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #f1efe8;
  color: #2c2c2a;
  margin: 0;
  padding: 0 0 3rem 0;
}

.login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}

.login-box {
  background: #fff;
  border-radius: 12px;
  padding: 0 0 2rem 0;
  width: 380px;
  text-align: center;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
  overflow: hidden;
}

.login-bild {
  width: 100%;
  display: block;
  margin-bottom: 1.25rem;
}

.login-box h1 { margin: 0 0 0.5rem 0; padding: 0 2rem; }

.login-spruch {
  color: #5f5e5a;
  font-size: 14px;
  margin: 0 2rem 1.5rem 2rem;
  font-style: italic;
}

.login-box form, .login-box .fehler { padding: 0 2rem; }

.login-box h1 { margin-bottom: 0.25rem; }
.untertitel { color: #5f5e5a; font-size: 14px; margin-bottom: 1.5rem; }

.login-box input {
  width: 100%;
  padding: 10px;
  margin-bottom: 1rem;
  border: 1px solid #d3d1c7;
  border-radius: 8px;
  font-size: 15px;
}

.login-box button, .admin-formular button, .status-knopf, .klein-button {
  cursor: pointer;
}

.login-box button {
  width: 100%;
  padding: 10px;
  background: #185fa5;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 15px;
}

.fehler { color: #a32d2d; font-size: 14px; }

.kopfzeile {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.kopfzeile h1 { margin: 0; font-size: 22px; font-weight: 500; }

.kopf-rechts { display: flex; gap: 0.5rem; }

.klein-button {
  background: white;
  border: 1px solid #d3d1c7;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  text-decoration: none;
  color: #2c2c2a;
}

.baustelle-karte, .massnahmen-karte, .verlauf-karte {
  background: white;
  border-radius: 12px;
  border: 1px solid #e4e2d8;
  margin: 1rem 2rem;
  padding: 1.5rem;
}

.baustelle-karte img {
  width: 100%;
  max-width: 480px;
  display: block;
  margin: 0 auto 1rem auto;
  border-radius: 8px;
  transition: opacity 0.4s ease;
}

.baustufe-info {
  text-align: center;
}

#baustufe-name {
  font-size: 18px;
  font-weight: 500;
  display: block;
  margin-bottom: 0.5rem;
}

.fortschrittsbalken-aussen {
  background: #e4e2d8;
  border-radius: 20px;
  height: 14px;
  width: 100%;
  max-width: 480px;
  margin: 0 auto 0.5rem auto;
  overflow: hidden;
}

.fortschrittsbalken-innen {
  background: #639922;
  height: 100%;
  transition: width 0.8s ease;
}

#punkte-anzeige { font-size: 14px; color: #5f5e5a; }

.ziel-vorschau {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 480px;
  margin: 1rem auto 0 auto;
  padding: 8px 12px;
  background: var(--surface-1, #f1efe8);
  border-radius: 8px;
}

.ziel-vorschau img {
  width: 56px;
  height: 40px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}

.ziel-vorschau span {
  font-size: 12px;
  color: #5f5e5a;
}

.spruch-blase {
  max-width: 480px;
  margin: 0 auto 1rem auto;
  background: #eaf3de;
  color: #27500a;
  padding: 10px 16px;
  border-radius: 20px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s ease, color 0.2s ease;
}

.spruch-blase.status-umgesetzt,
.spruch-blase.status-erledigt { background: #eaf3de; color: #27500a; }
.spruch-blase.status-versucht { background: #faeeda; color: #412402; }
.spruch-blase.status-offen { background: #f1efe8; color: #444441; }

/* Kurzes, deutliches Aufblitzen der angeklickten Zeile - unabhaengig vom Status */
@keyframes klick-blitz {
  0% { background: #d3d1c7; }
  100% { background: transparent; }
}

.massnahme-zeile.klick-markiert {
  animation: klick-blitz 0.6s ease;
}

.massnahme-zeile {
  list-style: none;
  padding: 1rem 0;
  border-bottom: 1px solid #eee;
}

.massnahme-zeile:last-child { border-bottom: none; }

.massnahme-titel {
  display: block;
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 0.6rem;
}

.status-auswahl {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.status-knopf {
  border: 1px solid #d3d1c7;
  background: white;
  border-radius: 20px;
  padding: 6px 12px;
  font-size: 12px;
  color: #5f5e5a;
}

.status-knopf.aktiv.status-umgesetzt { background: #c0dd97; border-color: #639922; color: #173404; }
.status-knopf.aktiv.status-erledigt { background: #b5d4f4; border-color: #185fa5; color: #042c53; }
.status-knopf.aktiv.status-versucht { background: #fac775; border-color: #854f0b; color: #412402; }
.status-knopf.aktiv.status-offen { background: #d3d1c7; border-color: #888780; color: #2c2c2a; }

.status-knopf:disabled { opacity: 0.5; cursor: not-allowed; }

.hinweis { color: #5f5e5a; font-size: 14px; }

.admin-formular { display: flex; gap: 8px; }
.admin-formular input { flex: 1; padding: 8px; border: 1px solid #d3d1c7; border-radius: 8px; }
.admin-formular button { background: #185fa5; color: white; border: none; border-radius: 8px; padding: 8px 16px; }

.admin-zeile {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 0;
  border-bottom: 1px solid #eee;
  gap: 1rem;
}

.admin-status { font-size: 12px; color: #5f5e5a; white-space: nowrap; }
.loeschen { color: #a32d2d; }

/* Konfetti-Effekt */
.konfetti-teil {
  position: fixed;
  top: -10px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  z-index: 999;
  pointer-events: none;
  animation: fallen 1.6s ease-in forwards;
}

@keyframes fallen {
  to { transform: translateY(100vh) rotate(400deg); opacity: 0; }
}
