:root {
  --green: #004b1c;
  --green2: #006b2a;
  --green-soft: #0b7a36;
  --yellow: #ffd328;
}

/* ======================
   BACKGROUND
====================== */

body {
  background:
    radial-gradient(circle at center, rgba(255,211,40,0.08), transparent 45%),
    radial-gradient(circle at 20% 30%, rgba(0,75,28,0.15), transparent 55%),
    radial-gradient(circle at 80% 70%, rgba(0,107,42,0.12), transparent 60%),
    linear-gradient(180deg, #eef2ef 0%, #e2e7e4 100%);
  background-attachment: fixed;
}

/* ======================
   HERO FINAL
====================== */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;

  padding: 28px 32px;
  border-radius: 22px;

  background: linear-gradient(135deg, var(--green), var(--green2));
  border: 4px solid var(--yellow);

  box-shadow: 0 16px 40px rgba(0,0,0,0.2);
  color: #fff;

  transition: transform .25s ease, box-shadow .25s ease;
}

/* Hover Lift */
.hero:hover {
  transform: translateY(-3px);
  box-shadow: 0 26px 60px rgba(0,0,0,0.3);
}

/* Light Overlay für Tiefe */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    circle at 25% 20%,
    rgba(255,255,255,0.08),
    transparent 55%
  );
  pointer-events: none;
}

/* ======================
   HERO LOGO
====================== */

.hero-logo {
  background: rgba(255,255,255,0.95);
  padding: 14px;
  border-radius: 18px;
  box-shadow: 0 12px 25px rgba(0,0,0,.25);
  transition: all .25s ease;
}

.hero-logo img {
  max-width: 140px;
  display: block;
}

/* leichte Bewegung beim Hover */
.hero:hover .hero-logo {
  transform: scale(1.05);
  box-shadow: 0 20px 35px rgba(0,0,0,.35);
}

/* ======================
   HERO TEXT
====================== */

.hero-content {
  flex: 1;
}

.hero-title {
  font-size: 1.9rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.hero-subtitle {
  font-size: 1rem;
  opacity: 0.85;
}

/* ======================
   KPI BLOCK
====================== */

.hero-kpi {
  text-align: right;
  min-width: 220px;
}

.hero-kpi-label {
  font-size: 0.9rem;
  opacity: 0.8;
}

.hero-kpi-value {
  font-size: 2.4rem;
  font-weight: 900;

  background: linear-gradient(135deg, #ffd328, #ffe066);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;

  text-shadow:
    0 0 6px rgba(255,211,40,0.4),
    0 0 20px rgba(255,211,40,0.3);
}

/* Glow verstärken beim Hover */
.hero:hover .hero-kpi-value {
  text-shadow:
    0 0 8px rgba(255,211,40,0.6),
    0 0 18px rgba(255,211,40,0.5),
    0 0 40px rgba(255,211,40,0.35);
}

/* ======================
   MOBILE HERO
====================== */

@media (max-width: 768px) {

  .hero {
    flex-direction: column;
    text-align: center;
  }

  .hero-kpi {
    text-align: center;
  }

  .hero-logo img {
    max-width: 120px;
  }
}

/* ======================
   NAVBAR
====================== */

.app-nav {
  background: linear-gradient(90deg, var(--green), var(--green2));
  border-bottom: 4px solid var(--yellow);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.nav-logo {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--yellow);
  transition: transform .2s ease;
}

.nav-logo:hover {
  transform: scale(1.08);
}

/* ======================
   LAYOUT
====================== */

main.container {
  max-width: 900px;
}

/* ======================
   CARD
====================== */

.card {
  border-radius: 20px;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(8px);
  box-shadow: 0 15px 40px rgba(0,0,0,0.08);
  border: 0;
  transition: transform .15s ease;
}

.card:hover {
  transform: translateY(-2px);
}

/* ======================
   LABELS
====================== */

.form-label {
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}

/* ======================
   INPUTS
====================== */

.form-control,
.form-select {
  border-radius: 12px;
  border: 1px solid #d4d8dd;
  padding: 12px 14px;
  transition: all .15s ease;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--green2);
  box-shadow: 0 0 0 3px rgba(0,107,42,.15);
}

/* ======================
   BETRAG BUTTONS
====================== */

.btn-outline-success {
  border: 2px solid rgba(0,107,42,.45);
  border-radius: 12px;
  font-weight: 700;
  font-size: 1.15rem;
  padding: 14px;
  color: var(--green2);
  transition: all .2s ease;
}

.btn-outline-success:hover {
  background: rgba(0,107,42,.08);
}

.btn-check:checked + .btn-outline-success {
  background: linear-gradient(135deg, var(--green2), var(--green));
  color: #fff;
  border-color: var(--green2);
  box-shadow: 0 10px 22px rgba(0,0,0,.15);
  transform: translateY(-2px);
}

/* ======================
   AUTOCOMPLETE
====================== */

.autocomplete-wrap {
  position: relative;
}

.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 1000;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #d9dee3;
  box-shadow: 0 12px 30px rgba(0,0,0,.15);
}

.autocomplete-item {
  padding: 10px 14px;
  cursor: pointer;
  transition: background .15s ease;
}

.autocomplete-item:hover,
.autocomplete-item.active {
  background: rgba(0,107,42,.08);
}

.autocomplete-item + .autocomplete-item {
  border-top: 1px solid #eef1f4;
}

/* ======================
   BUTTON
====================== */

.btn-success {
  margin-top: 10px;
  font-size: 1.1rem;
  padding: 14px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--green2), var(--green));
  border: none;
  font-weight: 600;
  transition: all .2s ease;
}

.btn-success:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(0,0,0,.15);
}

/* ======================
   LOGIN CARD
====================== */

.login-card {
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(8px);
  border-radius: 18px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.15);
}

/* ======================
   TABLE (Dashboard)
====================== */

.fines-card {
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(6px);
}

.fines-table thead th {
  font-weight: 800;
}

.fines-name {
  font-weight: 700;
}

.fines-total {
  font-weight: 800;
  color: var(--green2);
}

.fines-total.is-zero {
  color: #6b7280;
}

.btn-detail {
  border-radius: 10px;
  padding: 8px 14px;
  font-weight: 600;
}

/* ======================
   MOBILE
====================== */

@media (max-width: 768px) {
  main.container {
    padding: 10px;
  }

  .btn-outline-success {
    font-size: 1rem;
    padding: 12px;
  }
}

.fines-table tbody tr {
  transition: all .2s ease;
}

.fines-table tbody tr:hover {
  transform: translateX(4px);
  background: rgba(0,107,42,.06);
}

/* Zebra ultra subtil */
.fines-table tbody tr:nth-child(even) {
  background: rgba(0,0,0,.02);
}

.row-link td {
  position: relative;
}

/* Pfeil */
.row-link td:last-child::after {
  content: "→";
  position: absolute;
  right: 10px;
  opacity: 0;
  transition: all .2s ease;
}

.row-link:hover td:last-child::after {
  opacity: 0.6;
  transform: translateX(4px);
}

/* große Beträge */
.fines-total {
  font-weight: 800;
}

/* Highlight */
.fines-total:not(.is-zero) {
  color: var(--green2);
}

/* große Beträge extra */
.fines-total.high {
  color: #d97706; /* gold/orange */
}
.fines-card {
  margin-top: 10px;
  border-radius: 22px;
  padding: 18px;
  background: rgba(255,255,255,0.97);
  box-shadow: 0 20px 40px rgba(0,0,0,.08);
}
.fines-table {
  width: 100%;
  border-collapse: collapse; /* 🔥 WICHTIG */
}
/* ======================
   AUTOCOMPLETE
====================== */

.autocomplete-wrap {
  position: relative;
  z-index: 20;
}

/* Das Dropdown selbst */
.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 1200;

  display: grid;
  gap: 8px;

  padding: 10px;
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(8px);

  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 18px;

  box-shadow:
    0 16px 40px rgba(0,0,0,.16),
    0 6px 16px rgba(0,0,0,.08);

  max-height: 280px;
  overflow-y: auto;
}

/* Bootstrap d-none sauber respektieren */
.autocomplete-dropdown.d-none {
  display: none !important;
}

/* Jeder Vorschlag */
.autocomplete-item {
  appearance: none;
  -webkit-appearance: none;
  display: flex;
  align-items: center;
  gap: 12px;

  width: 100%;
  min-height: 52px;

  border: 1px solid rgba(0,107,42,.18);
  border-radius: 14px;
  background: #ffffff;

  padding: 12px 16px;
  margin: 0;

  text-align: left;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  color: #111827;

  cursor: pointer;
  transition:
    transform .16s ease,
    background-color .16s ease,
    border-color .16s ease,
    box-shadow .16s ease;
}

/* Kleiner grüner Punkt links */
.autocomplete-item::before {
  content: "•";
  flex: 0 0 auto;
  font-size: 1.2rem;
  line-height: 1;
  color: var(--green2);
  opacity: .7;
}

/* Hover */
.autocomplete-item:hover {
  background: rgba(0,107,42,.06);
  border-color: rgba(0,107,42,.35);
  transform: translateX(3px);
  box-shadow: 0 6px 14px rgba(0,0,0,.08);
}

/* Aktiv per Tastatur */
.autocomplete-item.active {
  background: rgba(0,107,42,.10);
  border-color: var(--green2);
  box-shadow: 0 0 0 2px rgba(0,107,42,.10);
}

/* Input bekommt mehr Fokus, wenn Dropdown offen ist */
.autocomplete-wrap:focus-within .form-control {
  border-color: var(--green2);
  box-shadow: 0 0 0 3px rgba(0,107,42,.14);
}

/* Optional: Scrollbar etwas hübscher */
.autocomplete-dropdown::-webkit-scrollbar {
  width: 10px;
}

.autocomplete-dropdown::-webkit-scrollbar-track {
  background: transparent;
}

.autocomplete-dropdown::-webkit-scrollbar-thumb {
  background: rgba(0,107,42,.18);
  border-radius: 999px;
}

.autocomplete-dropdown::-webkit-scrollbar-thumb:hover {
  background: rgba(0,107,42,.28);
}
