:root{
  --bg:#f7fafc; --card:#ffffff; --ink:#0f172a; --muted:#64748b; --brand:#1e88e5;
  --ok:#16a34a; --warn:#f59e0b; --err:#dc2626; --line:#e5e7eb;
}
*{box-sizing:border-box}
html,body{height:100%}
body{margin:0;font:16px/1.45 system-ui,-apple-system,Segoe UI,Roboto,Inter,Arial,sans-serif;background:var(--bg);color:var(--ink)}
.container{max-width:1800px;margin:0 auto;padding:14px}
.header{display:flex;align-items:center;gap:18px;padding:14px 18px;background:#fff;border-bottom:1px solid var(--line);position:sticky;top:0;z-index:10}
.header .logo{height:34px}
.header .title{font-weight:700;font-size:20px}
.header .spacer{flex:1}
.header .meta{display:flex;gap:22px;align-items:center;color:var(--muted)}
.header .meta .big{font-size:20px;color:var(--ink);font-weight:600}
.header .pill{background:#eef6ff;color:#0b5cad;padding:6px 10px;border-radius:999px;font-weight:600}
/* ===== Center Overlay (Müllanzeige zentriert) ===== */
.header {
  position: relative; /* wichtig */
}

/* zentrierte Anzeige */
.header .waste-hint {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  
  pointer-events: none; /* optional (keine Klicks blockieren) */
}


.grid{display:grid;grid-template-columns: 1.1fr 1fr; gap:14px; align-items:start}
@media (max-width: 1200px){ .grid{grid-template-columns:1fr} }

.card{background:var(--card);border:1px solid var(--line);border-radius:12px;box-shadow:0 6px 18px rgba(0,0,0,.04)}
.card .head{padding:12px 14px;border-bottom:1px solid var(--line);display:flex;align-items:center;gap:12px}
.card .head .h2{font-weight:700}
.card .body{padding:14px}

.ann-list{display:flex;flex-direction:column;gap:12px;max-height:36vh;overflow:auto}
.ann{padding:12px 12px;border:1px solid var(--line);border-radius:10px}
.ann .t{font-weight:600;margin-bottom:6px}
.ann .p{color:var(--muted)}

/* Bekanntmachungen � Titel hervorheben */
.ann-title {
  font-weight: 700;
  margin-bottom: 4px;
  font-size: 1.05em;
}

.ann-text {
  font-size: 0.95em;
  opacity: 0.85;
  line-height: 1.4;
}


.pdf-wrap{height:36vh;border:1px dashed var(--line);border-radius:10px;overflow:hidden}
.pdf-wrap embed, .pdf-wrap iframe{width:100%;height:100%;border:0;background:#fafafa}

.kalender{height:72vh}

/* Kalender-Feinschliff für das Board */
#boardCal .fc-toolbar-title{ font-size:18px; }
#boardCal .fc-timegrid-event { font-size:13px; }

  #boardCal {
    min-height: 500px;
  }



.badges{display:flex;gap:8px;flex-wrap:wrap}
.badge{padding:4px 8px;border-radius:999px;font-weight:700;font-size:12px}
.badge.black{background:#111;color:#fff}
.badge.yellow{background:#fde047;color:#111}
.badge.green{background:#22c55e;color:#fff}

.footer{padding:10px;color:var(--muted);text-align:center}

/* ===== Aufgaben-�bersicht (linke Spalte) ===== */
.task-list{ display:flex; flex-direction:column; gap:10px; max-height:66vh; overflow:auto; }
.task-card{ background:var(--card); border:1px solid var(--line); border-radius:12px; padding:12px; }
.task-card .row{ display:grid; grid-template-columns: 1.2fr 1fr auto; gap:10px; align-items:center; }
@media (max-width:1200px){ .task-card .row{ grid-template-columns: 1fr; } }

.task-title{ font-weight:800; color:var(--ink); }
.task-meta{ color:var(--muted); display:flex; gap:8px; flex-wrap:wrap; }
.task-meta .sep{ opacity:.6; }
.task-res{ display:flex; gap:6px; flex-wrap:wrap; justify-content:flex-end; }

/* Badges f�r Ressourcen-Typen */
.tag{ display:inline-block; padding:4px 8px; border-radius:999px; font-weight:700; font-size:12px; color:#fff; }
.tag.ma{ background:#2563eb; }   /* Mitarbeiter: blau */
.tag.fz{ background:#e67a00; }   /* Fahrzeug: orange */
.tag.wz{ background:#6b7280; }   /* Werkzeug: grau */

/* Lade-/Leermeldungen */
.list-loading, .list-empty{ padding:10px; color:var(--muted); }


.day-board {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
}

.project-card {
  background: var(--card-bg, #fff);
  border-radius: 10px;
  padding: 12px 14px;
  box-shadow: 0 2px 6px rgba(0,0,0,.08);
  border-left: 6px solid var(--proj-color, #2563eb);
}

.project-title {
  font-weight: 700;
  font-size: 1.05rem;
}

.project-time {
  font-size: .85rem;
  opacity: .6;
  margin-bottom: 6px;
}

/* Projektnummer-Badge in Project Cards */

.proj-badge {
  display: inline-block;
  margin-right: 6px;
  padding: 2px 6px;
  font-size: 0.85em;
  font-weight: 700;
  color: #fff;
  background: #2563eb;        /* ITS Blau */
  border-radius: 6px;
  vertical-align: middle;
}


/* ✅ Abteilung AS */
.proj-badge.badge-AS {
  background: #0d6efd;
  color: #fff;
}

/* ✅ Abteilung EG */
.proj-badge.badge-EG {
  background: #facc15;
  color: #111;
}


.res-list {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.res-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .95rem;
}

.res-badge {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.assignment-block {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed #e2e8f0;
}

.assignment-header {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  margin-bottom: 6px;
}

.assignment-title {
  color: #0f172a;
}

.assignment-time {
  color: #475569;
  font-size: 0.9em;
}

/* ===== Smooth Board Transition ===== */
.board-fade {
  opacity: 0;
  transition: opacity 400ms ease-in-out;
}

.board-show {
  opacity: 1;
  transition: opacity 400ms ease-in-out;
}

/* ===== Board � Event Style ===== */

.fc-event {
  background: #f5f5f5 !important;
  border: 1px solid #e5e5e5 !important;
  border-radius: 10px !important;
  box-shadow: 0 3px 8px rgba(0,0,0,.06);
}

.fc-event:hover {
  box-shadow: 0 6px 14px rgba(0,0,0,.12);
  transform: translateY(-1px);
  transition: all 0.15s ease;
}

/* Container im Event */
.fc-event-titleline {
  display: flex;
  flex-direction: column;
  gap: 4px;
  line-height: 1.2;
}




.event-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}

.event-customer-inline {
  font-size: 0.8em;
  font-weight: 700;
  color: #0f172a;
}

/* Projekt */
.event-project {
  font-size: 0.85em;
  color: #334155;
}

/* T�tigkeit */
.event-task {
  font-size: 0.8em;
  color: #64748b;
}
	
	.event-resources {
  font-size: 0.75em;
  color: #475569;
  margin-top: 2px;
  font-weight: 500;
}

.event-resources-inline {
  font-size: 0.75em;
  color: #64748b;
  font-weight: 600;
  white-space: nowrap;
}

/* Erste Zeile */
.event-line-main {
  font-size: 0.9em;
  line-height: 1.2;
}

/* Kunde fett */
.event-customer {
  font-weight: 700;
  color: #0f172a;
}

/* Trenner */
.event-separator {
  color: #94a3b8;
}

/* Projektname normal */
.event-project-inline {
  font-weight: 400;
  color: #334155;
}

/* T�tigkeit */
.event-task {
  font-size: 0.8em;
  color: #475569;
}

/* Kopfzeile */
.event-header {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
  line-height: 1.2;
}

/* Kunde fett */
.event-customer-inline {
  font-weight: 700;
  color: #0f172a;
}

/* Trenner */
.event-separator {
  color: #94a3b8;
}

/* Projektname normal */
.event-project-inline {
  font-weight: 400;
  color: #334155;
}

/* T�tigkeit */
.event-task {
  font-size: 0.8em;
  color: #475569;
}

/* Ressourcen */
.event-resources {
  font-size: 0.75em;
  color: #64748b;
  font-weight: 600;
}


.einteilung-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dept-switch {
  display: inline-flex;
  border-radius: 999px;
  background: #f1f3f5;
  padding: 2px;
  gap: 2px;
}

.dept-switch button {
  border: 0;
  background: transparent;
  padding: 6px 12px;
  font-size: 0.85rem;
  border-radius: 999px;
  cursor: pointer;
  color: #555;
}

/* ===== Abteilungs-Umschalter ===== */

/* Aktiv: AS → Blau */
.dept-switch button[data-dept="AS"].active,
.dept-switch button[data-dept="as"].active {
  background: #0d6efd; /* Blau */
  color: #fff;
}

/* Aktiv: EG → Gelb */
.dept-switch button[data-dept="EG"].active,
.dept-switch button[data-dept="eg"].active {
  background: #facc15; /* Gelb */
  color: #111;
}


.dept-switch button.active {
  box-shadow: 0 2px 6px rgba(0,0,0,.15);
}


/* ===== FullCalendar Event: Basisfarbe wiederherstellen ===== */

/* nur Grundfarbe für den Event-Container */
.fc-event .fc-event-main {
  color: #0f172a; /* --ink */
}

/* Feinabstimmung wieder wie vorher */
.event-task {
  color: #475569;
}

.event-resources,
.event-resources-inline {
  color: #64748b;
}

.event-separator {
  color: #94a3b8;
}

/* Projektname normal */
.event-project-inline {
  color: #334155;
  font-weight: 400;
}

/* Kunde fett */
.event-customer-inline {
  color: #0f172a;
  font-weight: 700;
}

.footer-sub {
  font-size: 0.6em;
  opacity: 0.4s;
}

.waste-hint {
  margin-left: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #475569;
}

/* Mülltonne */
.waste-bin {
  width: 14px;
  height: 16px;
  border-radius: 2px;
  position: relative;
  display: inline-block;
}

/* Deckel */
.waste-bin::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -2px;
  right: -2px;
  height: 3px;
  border-radius: 2px;
}

/* Griff */
.waste-bin::after {
  content: "";
  position: absolute;
  top: -6px;
  left: 4px;
  width: 6px;
  height: 3px;
  border-radius: 2px;
}

.waste-paper {
  background: #2e7d32;
}
.waste-paper::before {
  background: #1b5e20;
}
.waste-paper::after {
  background: #1b5e20;
}

.waste-rest {
  background: #374151;
}
.waste-rest::before,
.waste-rest::after {
  background: #1f2937;
}

.waste-yellow {
  background: #facc15;
}
.waste-yellow::before,
.waste-yellow::after {
  background: #eab308;
}

.board-day {
  margin-left: 10px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: #0d6efd;
  color: #fff;
}

.head-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.board-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  border-right: 1px solid var(--line);
  padding-right: 8px;
}

.board-controls button {
  border: 1px solid var(--line);
  background: #fff;
  padding: 4px 8px;
  font-size: 12px;
  border-radius: 6px;
  cursor: pointer;
  color: #334155;
}

.board-controls button:hover {
  background: #f1f5f9;
}

.view-switch {
  display: inline-flex;
  border-radius: 999px;
  background: #f1f3f5;
  padding: 2px;
}

.view-switch button {
  border: 0;
  background: transparent;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  cursor: pointer;
}

.view-switch button.active {
  background: #0d6efd;
  color: #fff;
}

.board-date {
  margin-left: 10px;
  font-size: 0.85em;
  color: var(--muted);
}

.fc-hover-card {
  position: absolute;
  display: none;
  z-index: 9999;

  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(8px);

  border-radius: 14px;
  padding: 14px;

  box-shadow: 0 12px 30px rgba(0,0,0,.18);

  font-size: 13px;
  line-height: 1.5;

  min-width: 220px;
  max-width: 280px;

  pointer-events: none;

  opacity: 0;
  transform: translateY(5px) scale(0.98);
  transition: all 0.15s ease;
}

/* Titel */
.fc-hover-card .hc-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 6px;
  color: #0f172a;
}

/* Sektionen */
.fc-hover-card .hc-section {
  margin-bottom: 6px;
}

/* Subtext */
.fc-hover-card .hc-sub {
  font-size: 12px;
  color: #64748b;
}

/* Lines */
.fc-hover-card .hc-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

/* Icons */
.fc-hover-card .hc-icon {
  width: 16px;
  text-align: center;
  opacity: 0.8;
}

/* Ressourcen Block */
.fc-hover-card .hc-resources {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid #e5e7eb;
}

/* Gruppe Block */
.hc-group {
  margin-top: 8px;
}

/* Titel */
.hc-group-title {
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* kleiner Punkt statt Icon pro Eintrag */
.hc-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #94a3b8;
  display: inline-block;
  margin-right: 6px;
}

.board-pdf {
  width: 100%;
  height: 70vh;
}

.board-pdf embed {
  width: 100%;
  height: 100%;
  border: none;
}

.hidden {
  display: none;
}

.planner-link {
  color: inherit;
  text-decoration: none;
  margin-left: 8px;
  font-weight: 600;
  opacity: 0.8;
}

.planner-link:hover {
  text-decoration: underline;
  opacity: 1;
}