:root{
  --gap:14px;
  --border:#e5e7eb;
  --muted:#6b7280;
  --ink:#111827;
  --bg:#f8fafc;
  --card:#ffffff;
  --primary:#111827;
}

/* ==========================
   LIGHT ADMIN ROOT
========================== */
body.light-admin {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  margin:0;
  background:var(--bg);
  color:var(--ink);
}

body.light-admin .container {
  max-width: 1000px;
  margin: 24px auto;
  padding: 0 16px;
}

body.light-admin .topbar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 16px;
  border-bottom:1px solid var(--border);
  background:#fff;
  position:sticky;
  top:0;
}

body.light-admin .logo {
  width:28px;
  height:28px;
  border-radius:999px;
  background:#d1d5db;
  display:flex;
  align-items:center;
  justify-content:center;
}

body.light-admin h1 {
  font-size:28px;
  margin:16px 0;
}

body.light-admin h2 {
  font-size:18px;
  margin-bottom:10px;
}

body.light-admin .card {
  background:var(--card);
  border:1px solid var(--border);
  border-radius:12px;
  padding:18px;
  box-shadow:0 1px 3px rgba(0,0,0,.06);
}

body.light-admin .grid {
  display:grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: var(--gap);
}

body.light-admin label {
  display:flex;
  flex-direction:column;
  gap:6px;
  font-size:14px;
}

body.light-admin input,
body.light-admin select,
body.light-admin textarea {
  padding:10px 12px;
  border:1px solid var(--border);
  border-radius:10px;
  font-size:14px;
  background:#fff;
}

body.light-admin textarea {
  min-height:90px;
}

body.light-admin button {
  padding:10px 16px;
  border-radius:10px;
  background:var(--primary);
  color:#fff;
  border:0;
  cursor:pointer;
  font-weight:600;
}

body.light-admin .secondary {
  border:1px solid var(--border);
  color:var(--ink);
  padding:10px 16px;
  border-radius:10px;
}

body.light-admin .lanes {
  display:grid;
  grid-template-columns: repeat(6, 1fr);
  gap:10px;
}

/* ==========================
   WIZARD PROGRESS
========================== */
body.light-admin .wizard-steps {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 30px;
  padding: 20px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
}

body.light-admin .step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
  text-align: center;
}

body.light-admin .step-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e5e7eb;
  color: #6b7280;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 16px;
}

body.light-admin .step.active .step-circle {
  background: #3b82f6;
  color: #fff;
}

body.light-admin .step-label {
  font-size: 13px;
  color: #6b7280;
  font-weight: 500;
}

body.light-admin .step.active .step-label {
  color: #111827;
  font-weight: 600;
}

/* ==========================
   DURATION PILLS
========================== */
body.light-admin .duration-pills {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

body.light-admin .duration-pill {
  flex: 1;
  min-width: 120px;
  padding: 16px 12px;
  border: 2px solid var(--border);
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  text-align: center;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-height: 100px;
  justify-content: center;
}

body.light-admin .duration-icon {
  font-size: 24px;
  display: block;
}

body.light-admin .duration-label {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

body.light-admin .duration-sublabel {
  font-size: 12px;
  color: #6b7280;
  font-weight: 400;
}

body.light-admin .duration-pill:hover {
  border-color: #3b82f6;
  background: #f0f7ff;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

body.light-admin .duration-pill.active {
  border-color: #10b981 !important;
  background: #f0fdf4 !important;
  color: #065f46 !important;
}

/* ==========================
   WEEK NAVIGATION (DATES)
========================== */
body.light-admin .week-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

body.light-admin .week-nav button {
  padding: 14px 24px;
  border: 2px solid var(--border);
  background: #fff;
  color: var(--ink);
  border-radius: 12px;
  cursor: pointer;
  font-weight: 700;
  transition: all 0.2s ease;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 50px;
}

body.light-admin .week-nav button:hover {
  border-color: #3b82f6;
  background: #f0f7ff;
  color: #3b82f6;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

/* Premium Week Navigation Buttons */
.week-nav-btn-premium {
  padding: 16px 20px !important;
  border: 2px solid var(--border) !important;
  background: #fff !important;
  color: #111827 !important;
  border-radius: 12px !important;
  cursor: pointer !important;
  font-weight: 700 !important;
  transition: all 0.2s ease !important;
  font-size: 15px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  min-height: 70px !important;
  text-align: center !important;
}

.week-nav-btn-premium:hover {
  border-color: #3b82f6 !important;
  background: #f0f7ff !important;
  color: #3b82f6 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15) !important;
}

body.light-admin #days {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  justify-content: center;
  max-width: 400px;
  margin: 0 auto;
}

body.light-admin .day-tile {
  padding: 16px 14px;
  border: 2px solid var(--border);
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  text-align: center;
  transition: all 0.2s ease;
  min-width: 85px;
  min-height: 85px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

body.light-admin .day-tile .wd {
  font-size: 11px;
  color: #6b7280;
  text-transform: uppercase;
  font-weight: 500;
  letter-spacing: 0.5px;
}

body.light-admin .day-tile .dm {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
}

body.light-admin .day-tile:hover {
  border-color: #3b82f6;
  background: #f0f7ff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

body.light-admin .day-tile.active {
  border-color: #10b981;
  background: #f0fdf4;
  color: #065f46;
}

body.light-admin .day-tile.unavailable {
  background: #f3f4f6;
  border-color: #d1d5db;
  color: #9ca3af;
  cursor: not-allowed;
  opacity: 0.5;
}

/* ==========================
   TIME SLOTS
========================== */
body.light-admin .slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

body.light-admin .slot {
  padding: 14px 10px;
  border: 2px solid var(--border);
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  text-align: center;
  transition: all 0.2s ease;
  min-height: 75px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: #111827;
}

body.light-admin .slot::before {
  content: '🕐';
  font-size: 20px;
  display: block;
  margin-bottom: 6px;
}

body.light-admin .slot:hover:not(.unavailable) {
  border-color: #3b82f6;
  background: #f0f7ff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

body.light-admin .slot.active {
  border-color: #10b981;
  background: #f0fdf4;
  color: #065f46;
}

body.light-admin .slot.unavailable {
  background: #f3f4f6;
  border-color: #d1d5db;
  color: #9ca3af;
  cursor: not-allowed;
  opacity: 0.5;
}

body.light-admin .slot[data-reason="closed"] {
  background: #f3f4f6;
  border-color: #d1d5db;
  cursor: not-allowed;
  opacity: 0.5;
}

body.light-admin .slot[data-reason="too_soon"] {
  background: #fed7aa;
  border-color: #fdba74;
  color: #7c2d12;
  cursor: not-allowed;
  opacity: 0.8;
}

body.light-admin .slot[data-reason="booked"] {
  background: #fecaca;
  border-color: #fca5a5;
  color: #7f1d1d;
  cursor: not-allowed;
  opacity: 0.8;
}

/* ==========================
   RESPONSIVE DESIGN
========================== */
@media (max-width: 768px) {
  /* Duration Pills - 2 Spalten auf Tablet */
  body.light-admin .duration-pills {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  body.light-admin .duration-pill {
    min-width: unset;
    padding: 14px 10px;
    min-height: 90px;
  }

  /* Week Navigation Buttons - schmäler */
  .week-nav-btn-premium {
    padding: 12px 16px !important;
    min-height: 60px !important;
    font-size: 14px !important;
  }

  /* Date Pills - Grid 2x3 Layout */
  body.light-admin #days {
    grid-template-columns: repeat(3, 1fr);
    max-width: 300px;
  }

  body.light-admin .day-tile {
    min-width: unset;
    min-height: 75px;
    padding: 12px 10px;
  }

  /* Time Slots - 3 Spalten */
  body.light-admin .slot-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  body.light-admin .slot {
    min-height: 65px;
    padding: 12px 8px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  /* Week Navigation - Buttons über/unter den Tagen */
  .week-nav-premium {
    flex-direction: column !important;
    gap: 12px !important;
  }

  .week-nav-btn-premium {
    padding: 10px 12px !important;
    min-height: 55px !important;
    font-size: 13px !important;
    width: 100% !important;
  }

  /* Duration Pills - 1 Spalte auf Mobile */
  body.light-admin .duration-pills {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  body.light-admin .duration-pill {
    padding: 12px 8px;
    min-height: 80px;
  }

  /* Date Pills - 3 Spalten (besseres Layout: 3+2+2) */
  body.light-admin #days {
    grid-template-columns: repeat(3, 1fr);
    max-width: 100%;
    width: 100%;
  }

  body.light-admin .day-tile {
    min-height: 70px;
    padding: 10px 8px;
    font-size: 13px;
  }

  body.light-admin .day-tile .dm {
    font-size: 14px;
  }

  body.light-admin .day-tile .wd {
    font-size: 10px;
  }

  /* Time Slots - 2 Spalten */
  body.light-admin .slot-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  body.light-admin .slot {
    min-height: 60px;
    padding: 10px 6px;
    font-size: 13px;
  }

  body.light-admin .slot::before {
    font-size: 16px;
    margin-bottom: 4px;
  }

  /* Availability Counter - kleiner */
  #slots-count {
    font-size: 0.7rem !important;
    padding: 0.3rem 0.6rem !important;
  }
}
