/* Basislayout */
body{
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  margin:0;
  min-height:100vh;
  background:#f3f4f6;
}

.admin-header{
  background:#0A2342;
  color:#fff;
  padding:12px 20px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.admin-header a{
  color:#e5e7eb;
  text-decoration:none;
  font-size:13px;
}

.admin-header-links{
  display:flex;
  gap:12px;
}

/* Login */
.center{
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:16px;
}
.login-card{
  background:#ffffff;
  border-radius:12px;
  padding:24px 24px 20px;
  max-width:360px;
  width:100%;
  box-shadow:0 18px 45px rgba(15,23,42,0.35);
}
h2{
  margin:0 0 4px;
  font-size:20px;
  color:#0A2342;
}
.subtitle{
  margin:0 0 18px;
  font-size:13px;
  color:#6b7280;
}
.field{ margin-bottom:12px; }
label{
  display:block;
  font-size:13px;
  margin-bottom:4px;
  color:#374151;
}
input[type="text"],
input[type="password"],
input[type="date"],
input[type="number"],
select,
textarea{
  width:100%;
  padding:8px 10px;
  border-radius:8px;
  border:1px solid #d1d5db;
  font-size:14px;
  box-sizing:border-box;
}
textarea{
  resize:vertical;
  min-height:34px;
}
button{
  border:none;
  border-radius:6px;
  padding:6px 10px;
  font-size:13px;
  font-weight:600;
  cursor:pointer;
  background:#FF8C00;
  color:#111827;
}
button:hover{ filter:brightness(0.98); }

.btn-ghost{
  border-radius:6px;
  padding:4px 8px;
  font-size:12px;
  font-weight:500;
  cursor:pointer;
  background:#e5e7eb;
  color:#111827;
  border:none;
}
.btn-danger{
  border-radius:6px;
  padding:4px 8px;
  font-size:12px;
  font-weight:500;
  cursor:pointer;
  background:#ef4444;
  color:#fff;
  border:none;
}

.btn-add    { background:#10b981; color:#fff; }
.btn-save   { background:#0A2342; color:#fff; }
.btn-users  { background:#e5e7eb; }
.btn-users:hover { filter:brightness(0.97); }

.error-msg{
  margin-bottom:12px;
  padding:8px 10px;
  border-radius:6px;
  font-size:13px;
  background:#fef2f2;
  color:#991b1b;
  border:1px solid #fecaca;
}

.wrapper{ max-width:1100px; margin:24px auto; padding:0 16px 32px; }
.flash { padding:10px 14px; border-radius:6px; margin-bottom:16px; font-size:14px; }
.flash.ok { background:#ecfdf3; color:#166534; border:1px solid #bbf7d0; }
.flash.err { background:#fef2f2; color:#991b1b; border:1px solid #fecaca; }

table {
  border-collapse: collapse;
  width: 100%;
  background:#fff;
  border-radius: 8px;
  overflow:hidden;
  margin-bottom:24px;
}
th, td {
  padding: 6px 8px;
  border-bottom: 1px solid #e5e7eb;
  font-size: 13px;
  text-align:left;
  vertical-align: middle;
}
th {
  background:#0A2342;
  color:#fff;
  font-weight:600;
}
tr:last-child td { border-bottom:none; }

.section-title{
  font-size:17px;
  margin:24px 0 10px;
  color:#0A2342;
}
.small { font-size:12px; color:#6b7280; }
.nowrap{ white-space:nowrap; }
.create-row{ background:#f9fafb; }
.teilnehmer-row{ background:#f9fafb; }

.teilnehmer-inner-table{
  width:100%;
  border-collapse:collapse;
}
.teilnehmer-inner-table th,
.teilnehmer-inner-table td{
  border-bottom:1px solid #e5e7eb;
  font-size:12px;
  padding:4px 6px;
}
.teilnehmer-inner-table th{
  background:#e5e7eb;
  color:#111827;
}
.teilnehmer-inner-table tr:last-child td{
  border-bottom:none;
}

.checkbox-cell {
  text-align:center;
}
.checkbox-cell input[type="checkbox"]{
  width:auto;
}

/* Sektionen auf/zu */
.admin-section {
  margin-bottom: 12px;
}

.section-toggle {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:4px 8px;
  font-size:14px;
  font-weight:600;
  background:#e5e7eb;
  color:#111827;
  border-radius:999px;
  border:none;
  cursor:pointer;
}

.section-toggle.is-open{
  background:#d1d5db;
}

.section-body{
  margin-top:8px;
}

/* Rabattdetails auf zweiter Zeile */
.rabatt-details-row{
  background:#f9fafb;
}

.rabatt-details-grid{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
}

.rabatt-detail-item{
  min-width:160px;
  max-width:220px;
}

.rabatt-detail-item label{
  font-size:11px;
  color:#6b7280;
  margin-bottom:2px;
  display:block;
}
