/* 13styles.css - VERSION 14.5 */
/* Grundlegende Stile */
body {
  font-family: 'Roboto', sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f9f9f9;
  color: #333;
}

.counter-thu-fri-conflict {
  border: 2px solid #d9534f;
  background: #fff1f0;
  color: #8a1f17;
  font-weight: 700;
  padding: 3px 6px;
}

.counter-conflict-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 5px;
  border-radius: 3px;
  background: #d9534f;
  color: #fff;
  font-size: 0.72em;
  font-weight: 700;
}

[data-theme="dark"] .counter-thu-fri-conflict {
  border-color: #ff8f85;
  background: #4a1f1d;
  color: #ffe1de;
}

/* BUG-027 fix: Screen-Reader-Only Klasse */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* BUG-028 fix: Disabled Button Styling */
button:disabled,
.btn:disabled,
.generate_custom:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}
/* Konsolidierte Benachrichtigungen */
 

/* Konsolidierte Benachrichtigungen - aktualisiert */
.day-note.hidden {
  display: none;
}




.past_months {
  opacity: 0.7;
  background-color: #7daada!important;
  /* oder andere Styles für vergangene Monate */
}

.active_month {
  background-color: #007bff!important;
  color: white;
  /* oder andere Styles für den aktiven Monat */
}


.notification {
  position: fixed;
  bottom: 20px; /* Abstand vom unteren Rand */
  left: 0; /* Start ganz links */
  width: 100%; /* Volle Breite des Containers */
  padding: 1rem 2rem;
  background-color: var(--color-success); /* Standard: Erfolg */
  color: white;
  border-radius: 0; /* Keine Rundungen für volle Breite */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
  z-index: 1100;
  display: flex;
  align-items: center;
  justify-content: center; /* Inhalt zentrieren */
  gap: var(--spacing-sm);
  opacity: 0;
  transition: 0.4s ease all;
  animation: slideIn 0.5s ease-out forwards, fadeOut 1s 8s forwards; /* Verlängerte FadeOut */
}
.nicht-verfuegbar-badge {
  background-color: #ccc;  /* Change to your preferred colour */
  color: #000;
  padding: 2px 4px;
  margin-left: 5px;
  border-radius: 3px;
  font-size: 0.8em;
}
/* Sichtbare Benachrichtigungen */
.notification.show {
  opacity: 1;
  transition: 0.4s ease all;
  /* Animation kann hier gesteuert werden */
}
/* Füge dies zu deinem CSS hinzu */
.hidden-duplicate:last-child {
  display: none!important;
}
/* Benachrichtigungstypen */
.notification.success { background-color: var(--color-success); }
.notification.error { background-color: var(--color-danger); }
.notification.warning { background-color: var(--color-warning); }
.notification.info { background-color: var(--color-info); }

/* Benachrichtigung mit Fortschrittsbalken */
.notification.with-progress::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background-color: rgba(255, 255, 255, 0.3);
  transition: 1.4s ease all;
  animation: progress 8s linear forwards; /* Anpassung der Dauer */
}


.incomplete-schedule {
  
  position: relative;
}
 
.incomplete-schedule::after {
  content: "!";
  position: absolute;
  top: 5px;
  right: 5px;
  font-size: 1.2em;
}

.unassigned-employee {
  border: 2px solid #ff0000 !important;
  border-radius: 4px;
  padding: 2px 4px;
}
.incomplete-schedule::after {
  content: "!";
  position: absolute;
  top: 5px;
  right: 5px;
  font-size: 1.2em;
  background: #ffffff;
  padding: 4px;
  border-radius: 3px;
}

.incomplete-schedule {
  border: 2px solid #ff7f7fa8 !important;
  position: relative;
}

.day.incomplete-schedule {
  border-color: var(--border-soft, #d6e0da) !important;
}

.day.incomplete-schedule::after {
  content: none;
}

.shift-block.shift-block-incomplete {
  position: relative;
  border: 2px solid #d92323 !important;
  box-shadow: 0 0 0 1px rgba(217, 35, 35, 0.16), 0 8px 18px rgba(217, 35, 35, 0.12);
}

.shift-block.shift-block-incomplete h4 {
  padding-right: 92px;
  color: #8f1111;
}

.shift-slot-warning-label {
  position: absolute;
  top: 5px;
  right: 6px;
  display: inline-flex;
  align-items: center;
  max-width: calc(100% - 12px);
  padding: 2px 6px;
  border-radius: var(--ui-radius, 6px);
  background: #d92323;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  line-height: 1.1;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(143, 17, 17, 0.22);
  pointer-events: none;
}

.shift-block p.unassigned,
.shift-block p.unassigned-employee {
  border: 1px solid rgba(217, 35, 35, 0.62) !important;
  background: #fff4f4 !important;
  color: #8f1111;
  font-weight: 800;
}

[data-theme="dark"] .shift-block.shift-block-incomplete {
  border-color: #ff6b6b !important;
  box-shadow: 0 0 0 1px rgba(255, 107, 107, 0.22), 0 8px 18px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .shift-block.shift-block-incomplete h4 {
  color: #ffd2d2;
}

[data-theme="dark"] .shift-slot-warning-label {
  background: #ff6b6b;
  color: #2b0b0b;
}

[data-theme="dark"] .shift-block p.unassigned,
[data-theme="dark"] .shift-block p.unassigned-employee {
  background: rgba(255, 107, 107, 0.16) !important;
  color: #ffe1e1;
  border-color: rgba(255, 107, 107, 0.7) !important;
}
/* Animationen */
@keyframes slideIn {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to {
    transform: translateY(100%);
    opacity: 0;
  }
}

@keyframes progress {
  from { width: 100%; }
  to { width: 0%; }
}

/* Header */
header {
  /* Bestehende Styles wie color, padding, box-shadow, border-radius bleiben */
  color: white; /* Beibehalten? Oder an Theme anpassen? */
  padding: var(--spacing-lg) var(--spacing-xl);
  box-shadow: 0px 14px 37px -16px rgb(0 0 0 / 38%);
  border-bottom-left-radius: var(--radius-md);
  border-bottom-right-radius: var(--radius-md);
  padding: 22px;
  margin: 0;

  /* Neue Styles */
  background-color: #ffffffb5; /* Weiß mit Transparenz */
  border-bottom: 1px solid var(--border-color);
  backdrop-filter: blur(4px);

  /* Fixed Header Styles */
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;
  /* box-shadow: 0 0px 0px rgba(0,0,0,0.0); /* War hier, vielleicht überflüssig durch den anderen Schatten? */
}


header h1 {
  margin: 0;
  font-size: 1.8em;
}

/* Hauptbereich */
main {
  padding: 2em;
  display: flex;
  flex-direction: column;
  gap: 2em;
}

/* Dashboard */
.dashboard {
  background-color: #ffffff;
  padding: 1.5em;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.dashboard h2 {
  margin-top: 0;
  font-size: 1.5em;
  color: #4a4a4a;
}

/* Mitarbeiterliste */
#employeeList {
  margin-top: 1em;
}

#employeeList h3 {
  margin-bottom: 0.5em;
  color: #4a4a4a;
}

#employeeList ul {
  list-style: none;
  padding: 0;
}

#employeeList li {
  padding: 0.5em 0;
  border-bottom: 1px solid #e0e0e0;
}

#employeeList li:last-child {
  border-bottom: none;
}

/* Controls */
.controls {
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
  justify-content: flex-start;
  padding: 10px;
  flex-wrap: wrap;
}

/* Jahres-Tabs */
.year-tabs {
  display: flex;
  gap: 0.3em;
  flex-wrap: nowrap;
  margin-right: 15px;
}

.year-tab {
  padding: 0.3em 0.8em;
  border: 1px solid #ccc;
  background-color: #f8f9fa;
  color: #333;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.85em;
  font-weight: 500;
  white-space: nowrap;
}

.year-tab:hover {
  background-color: #e9ecef;
  border-color: #999;
}

.year-tab.active {
  background-color: #007bff;
  color: white;
  border-color: #007bff;
}

.year-tab.active:hover {
  background-color: #0056b3;
  border-color: #0056b3;
}

/* Jahr-spezifische Farben für aktive Tabs */
.year-tab[data-year="2024"].active {
  background-color: #007bff; /* Blau */
  border-color: #007bff;
}

.year-tab[data-year="2024"].active:hover {
  background-color: #0056b3;
  border-color: #0056b3;
}

.year-tab[data-year="2025"].active {
  background-color: #28a745; /* Grün */
  border-color: #28a745;
}

.year-tab[data-year="2025"].active:hover {
  background-color: #1e7e34;
  border-color: #1e7e34;
}

.year-tab[data-year="2026"].active {
  background-color: #fd7e14; /* Orange */
  border-color: #fd7e14;
}

.year-tab[data-year="2026"].active:hover {
  background-color: #e55100;
  border-color: #e55100;
}

.year-tab[data-year="2027"].active {
  background-color: #6f42c1; /* Lila */
  border-color: #6f42c1;
}

.year-tab[data-year="2027"].active:hover {
  background-color: #5a2d91;
  border-color: #5a2d91;
}

.year-tab[data-year="2028"].active {
  background-color: #0f766e;
  border-color: #0f766e;
}

.year-tab[data-year="2028"].active:hover {
  background-color: #115e59;
  border-color: #115e59;
}

.year-tab[data-year="2029"].active {
  background-color: #be185d;
  border-color: #be185d;
}

.year-tab[data-year="2029"].active:hover {
  background-color: #9d174d;
  border-color: #9d174d;
}

/* Import Options */
.import-options {
  margin: 15px 0;
  padding: 15px;
  background-color: #f8f9fa;
  border-radius: 5px;
  border: 1px solid #e9ecef;
}

.import-options label {
  display: block;
  margin: 8px 0;
  cursor: pointer;
  font-weight: 500;
}

.import-options input[type="radio"] {
  margin-right: 8px;
}

.import-info {
  margin-top: 10px;
  padding: 10px;
  background-color: #e3f2fd;
  border-radius: 4px;
  border-left: 4px solid #2196f3;
}

.import-info small {
  color: #1976d2;
  font-style: italic;
}

/* Month Controls */
.month-controls {
  display: flex;
  align-items: center;
  gap: 0.8em;
  flex-wrap: nowrap;
  margin-right: 15px;
}

/* Schul-Tage Styling */
.ist_schule {
  opacity: 0.6 !important;
  background-color: #e8f4fd !important;
  border-left: 3px solid #2196F3 !important;
}

/* Urlaubswunsch Styling (Orange) */
.vacation-request {
  background-color: #fff3cd !important;
  border-left: 3px solid #ff9800 !important;
  color: #856404 !important;
}

.vacation-request .vacation-actions .btn-approve {
  background-color: #28a745;
  color: white;
  border: none;
  padding: 4px 8px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.8em;
  margin-right: 5px;
}

.vacation-request .vacation-actions .btn-approve:hover {
  background-color: #218838;
}

/* Genehmigter Urlaub Styling (Grün) */
.vacation-approved {
  background-color: #d4edda !important;
  border-left: 3px solid #28a745 !important;
  color: #155724 !important;
}

.vacation-approved .vacation-actions .btn-remove {
  background-color: #dc3545;
  color: white;
  border: none;
  padding: 4px 8px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.8em;
}

.vacation-approved .vacation-actions .btn-remove:hover {
  background-color: #c82333;
}

/* Kalender-Badge Styling */
.urlaub-badge {
  background-color: #28a745;
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.8em;
  font-weight: bold;
  margin-left: 5px;
}

.urlaubswunsch-badge {
  background-color: #ff9800;
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.8em;
  font-weight: bold;
  margin-left: 5px;
}

.nicht-verfuegbar-badge {
  background-color: #6c757d;
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.8em;
  font-weight: bold;
  margin-left: 5px;
}

.schule-badge {
  background-color: #2196F3;
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.8em;
  font-weight: bold;
  margin-left: 5px;
}

.btn-edit-school-days {
  background-color: #2196F3;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9em;
  transition: background-color 0.3s ease;
}

.btn-edit-school-days:hover {
  background-color: #1976D2;
}

.school-days {
  list-style: none;
  padding: 0;
  margin: 0;
}

.school-days li {
  padding: 2px 0;
  color: #2196F3;
  font-weight: 500;
}

.controls label {
  font-weight: 500;
  color: #4a4a4a;
}

.controls input[type="month"] {
  padding: 0.5em;
  border: 1px solid #ccc;
  border-radius: 4px;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.controls input[type="month"]:focus {
  border-color: #666;
 
  outline: none;
}
h2#dienstplan-heading {
  margin-bottom: 20px;
}
/* Button-Typen */
button,
.btn {
  display: inline-block; /* Stellt sicher, dass Buttons nebeneinander angezeigt werden können */
  padding: var(--spacing-sm) var(--spacing-md); /* Einheitliches Padding */
  min-height: 38px; /* Mindesthöhe für Konsistenz */
  line-height: 1.5; /* Zentriert Text vertikal */
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background-color: var(--card-bg);
  color: var(--text-color);
  cursor: pointer;
  font-weight: 500;
  text-align: center;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
  vertical-align: middle; /* Bessere Ausrichtung neben Text/Inputs */
}

button:hover,
.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-color);
  background-color: var(--hover-bg);
}

button:active,
.btn:active {
  transform: translateY(0);
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.1);
}

/* Verschiedene Button-Farben nach Funktion */
.btn-details {
  background-color: #6c757d; /* Mittelgrau */
  color: #fff;
}

.btn-edit {
  background-color: #8aa8c7; /* Blau */
  color: #fff;
}

.btn-delete {
  background-color: #dc3545; /* Rot */
  color: #fff;
}

.btn-add-vacation,
.btn-edit-days {
  background-color: #17a2b8; /* Türkis */
  color: #fff;
}

.btn-remove { 
  padding: var(--spacing-xs) var(--spacing-sm); /* Kleinere Buttons */
  min-height: auto; 
}

.btn-save {
  background-color: #28a745; /* Grün */
  color: #fff;
}

.btn-cancel {
  background-color: #6c757d; /* Grau */
  color: #fff;
}

/* Formulare */
form {
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
}

form input[type="text"],
form input[type="date"],
form select {
  padding: 0.6em;
  border: 1px solid #ccc;
  border-radius: 4px;
  flex: 1 1 200px;
  transition: border-color 0.3s, box-shadow 0.3s;
}

form input[type="text"]:focus,
form input[type="date"]:focus,
form select:focus {
  border-color: #666;
  box-shadow: 0 0 5px rgba(102, 102, 102, 0.3);
  outline: none;
}

/* Tabellen */
table {
  width: 100%;
  border-collapse: collapse;
  background-color: #ffffff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

thead {
  background-color: #6c757d; /* Mittelgrau */
  color: #fff;
}

thead th {
  padding: 1em;
  text-align: left;
  font-weight: 500;
}

tbody tr {
  border-bottom: 1px solid #e0e0e0;
  transition: background-color 0.3s;
}

tbody tr:hover {
  background-color: #f1f1f1;
}

tbody tr:last-child {
  border-bottom: none;
}

tbody td {
  padding: 0.8em 1em;
  padding-top: 0;
    padding-bottom: 0;
}

/* Options */
.options {
  background-color: #ffffff;
  padding: 1.5em;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.options h2 {
  margin-top: 0;
  font-size: 1.5em;
  color: #4a4a4a;
}

/* Export Buttons */
.export-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
}

.export-buttons button {
  flex: 1 1 150px;
  padding: 0.6em 1.2em;
  background-color: #6c757d; /* Mittelgrau */
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.2s, box-shadow 0.3s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.export-buttons button:hover {
  background-color: #5a6268;
  transform: translateY(-2px);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}

.export-buttons button:active {
  transform: translateY(0);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}







#schedule {
   
  margin-top: 1em;
  background-color: #fff;
  
  border-radius: 4px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid #8378785e !important;

   
}

#schedule-tabs {
  margin: 10px 0;
  padding: 5px;
  border-bottom: 1px solid #ccc;

  
}

.schedule-tab {
  background: none;
  border: none;
  padding: 5px 10px;
  margin-right: 5px;
  cursor: pointer;
}

.schedule-tab.active {
   
  font-weight: bold;
}

#schedules-container {
  

   
}

.schedule-month {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  grid-gap: 5px;
  
  transition: 0.8s ease all;
  top: 0;
  left: 0;
  width: 100%;
  opacity: 0;
  transition: opacity 0.8s ease, transform 0.8s ease;
  transform: translateX(10%);
}




.schedule-month:nth-child(odd) {

 
}

/* Even schedule-months start off-screen to the bottom */
.schedule-month:nth-child(even) {
  
  
}

/* For odd calendar sheets when active */
.schedule-month:nth-child(odd).active-calendar {
  transform: translateX(0);
  
 

  transform: translateX(0);
  
  transition: opacity 0.8s ease, transform 0.8s ease;
}

/* For even calendar sheets when active */
.schedule-month:nth-child(even).active-calendar {
  transform: translateY(0);
  
  

  transform: translateX(0);
  
  transition: opacity 0.8s ease, transform 0.8s ease;
}
 

.schedule-month.active-calendar {
 
  transition: 1.8s ease all;
 
  opacity: 1;
  transform: translateX(0);
  
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.day {
  background-color: #ffffff;
  border-radius: 8px;
  padding: 1em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: pointer;
}


.day:hover {
  box-shadow: 0px 12px 20px -15px #000000;
  transition: 0.4s ease all;
  transform: scale(1.02);
  background: #f4f4f4;
}


.day h3 {
  margin-top: 0;
  font-size: 1.2em;
  color: #4a4a4a;
}

.day p,
.spate-shift {
  margin: 0.5em 0;
  padding: 0.4em 0.6em;
  border-radius: 4px;
  display: inline-block;
}

.spate-shift {
  background-color: #f0ad4e; /* Orange */
  color: #fff;
  font-weight: 500;
}

.designated-lateshift {
  background-color: #5bc0de;
  color: #fff;
  padding: 0.3em 0.6em;
  border-radius: 4px;
  position: relative;
  right: 0px;
  font-size: 0.8em;
}

/* Modal Styles */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backdrop-filter: blur(4px) brightness(0.8);
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn var(--transition-normal);
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  background-color: #ffffff;
  padding: 2rem;
  border-radius: 8px;
  width: 90%;
  max-width: 1440px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  position: relative;
  transition: transform 0.3s ease-out;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.close-modal {
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.3s;
}

.close-modal:hover {
  color: #6c757d;
}

/* Status Badges */
.status-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 500;
}

.status-badge.lateshift {
  background-color: #f0ad4e; /* Orange */
  color: #fff;
}

.status-badge.fulltime {
  background-color: #28a745; /* Grün */
  color: #fff;
}

.status-badge.parttime {
  background-color: #60758c; /* Blau */
  color: #fff;
}

/* Form Styles */

/* Formulare und Inputs */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #4a4a4a;
}

.date-range {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

/* Urlaubsliste */
.current-vacations {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #e0e0e0;
}

.current-vacations ul {
  list-style: none;
  padding: 0;
}

.current-vacations li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e0e0e0;
}

.current-vacations li:last-child {
  border-bottom: none;
}



@keyframes fadeInOut {
  0% { opacity: 0; transform: translateY(-20px); }
  10%, 90% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-20px); }
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
  }
}

/* Checkbox-Styling */
input[type="checkbox"] {
  margin-right: 0.5rem;
}

.form-group label {
  cursor: pointer;
}

/* Editierbare Tage */
.day {
  position: relative;
  cursor: pointer;
  transition: all 0.2s ease;
}

.day:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.edit-indicator {
  opacity: 0.6;
  transition: opacity 0.2s ease;
}

.day:hover .edit-indicator {
  opacity: 1;
}



/* Schedule Edit Modal */
.schedule-edit .shift-select {
  width: 100%;
  padding: 8px;
  margin-top: 4px;
  border: 1px solid #ddd;
  border-radius: 4px;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.schedule-edit .shift-select:focus {
  border-color: #666;
  box-shadow: 0 0 5px rgba(102, 102, 102, 0.3);
}

.schedule-edit .form-group {
  margin-bottom: 1.5rem;
}

.schedule-conflicts {
  background-color: #ffe6e6; /* Leichtes Rot */
  padding: 10px;
  border-radius: 4px;
  margin: 10px 0;
}

.schedule-conflicts p {
  margin: 5px 0;
  color: #d9534f; /* Dunkelrot */
}

/* Status-Markierungen in den Dropdowns */
.shift-select option[data-preferred="true"] {
  background-color: #d1ecf1; /* Helles Blau */
}

.shift-select option[data-designated="true"] {
  background-color: #f8d7da; /* Helles Rot */
}
.outside-month {
  color: #999; /* Helles Grau für ausgegraute Tage */
  background-color: #f2f2f2;
}
/* Responsive Design */
@media (max-width: 1200px) {
  main {
    padding: 1.5em;
  }
}

@media (max-width: 800px) {
  .controls {
    flex-direction: column;
    align-items: flex-start;
  }

  .controls button {
    width: 100%;
  }

  form {
    flex-direction: column;
  }

  form button {
    width: 100%;
  }

  .export-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .export-buttons button {
    width: 100%;
  }
}

@media (max-width: 600px) {
  header h1 {
    font-size: 1.5em;
  }

  main {
    padding: 1em;
  }

  table thead th,
  table tbody td {
    padding: 0.6em;
  }

  #schedule {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(13%, 21fr));
    gap: 1em;
  }
}
/* Kalenderansicht */


.weekday-header {
  text-align: center;
  font-weight: bold;
  padding: 0.5em;
  background-color: #f8f9fa;
  border-radius: 4px;
}

.day {
  min-height: 150px;
  background-color: #ffffff;
  border-radius: 8px;
  padding: 1em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}

.outside-month {
  background-color: #f8f9fa;
  color: #999;
}

.outside-month h3 {
  color: #999;
}

/* Responsive Anpassungen */
@media (max-width: 768px) {
  #schedule {
    gap: 0.3em;
  }
  
  .day {
    padding: 0.5em;
    min-height: 120px;
  }
  
  .day h3 {
    font-size: 0.9em;
  }
  
  .spate-shift,
  .day p {
    font-size: 0.8em;
  }
}

/* Urlaubsverwaltung Styles */
.vacation-info {
  margin-bottom: 1rem;
  padding: 0.5rem;
  background-color: #f8f9fa;
  border-radius: 4px;
}

.vacation-preview {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #e9ecef;
  border-radius: 4px;
}

.excluded-days {
  list-style: none;
  padding-left: 0;
  margin-top: 0.5rem;
  font-size: 0.9em;
  color: #666;
}

.vacation-table {
  width: 100%;
  margin-top: 1rem;
  border-collapse: collapse;
}

.vacation-table th,
.vacation-table td {
  padding: 0.5rem;
  text-align: left;
  border-bottom: 1px solid #dee2e6;
}

.remaining-days {
  font-weight: 500;
  color: #0d6efd;
}

.holiday-entry {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  align-items: center;
}

.holiday-entry input[type="date"],
.holiday-entry input[type="text"] {
  padding: 0.3rem;
  border: 1px solid #ced4da;
  border-radius: 4px;
}

.holiday-entry input[type="text"] {
  flex-grow: 1;
}

/* Gesetzliche Feiertage (rot) */
.holiday-entry.official {
  background: linear-gradient(to right, #ffebee 0%, transparent 100%);
  border-left: 3px solid #d63031;
  padding-left: 8px;
  border-radius: 4px;
}

/* Kulturelle Feiertage (orange) */
.holiday-entry.cultural {
  background: linear-gradient(to right, #fff3e0 0%, transparent 100%);
  border-left: 3px solid #FF9800;
  padding-left: 8px;
  border-radius: 4px;
}

.holiday-date-display {
  font-weight: bold;
  min-width: 50px;
  color: #555;
}

.holiday-entry .btn-remove-holiday {
  background: #ff5252;
  color: white;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.holiday-entry .btn-remove-holiday:hover {
  background: #d32f2f;
}

.holiday-section {
  margin-bottom: 10px;
}

/* Dark Mode für Feiertags-Einträge */
[data-theme="dark"] .holiday-entry.official {
  background: linear-gradient(to right, rgba(214, 48, 49, 0.2) 0%, transparent 100%);
}

[data-theme="dark"] .holiday-entry.cultural {
  background: linear-gradient(to right, rgba(255, 152, 0, 0.2) 0%, transparent 100%);
}

[data-theme="dark"] .holiday-date-display {
  color: #aaa;
}

.weekday-header {
  text-align: center;
  font-weight: bold;
  padding: 0.5em;
  background-color: #f8f9fa;
  border-radius: 4px;
}

.day {
  min-height: 150px;
  background-color: #ffffff;
  border-radius: 8px;
  padding: 1em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}

.outside-month {
  background-color: #f8f9fa;
  color: #999;
}

.outside-month h3 {
  color: #999;
}

/* Urlaubsverwaltung */
.vacation-info {
  margin-bottom: 1rem;
  padding: 0.5rem;
  background-color: #f8f9fa;
  border-radius: 4px;
}

.vacation-preview {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #e9ecef;
  border-radius: 4px;
  border-left: 4px solid #0d6efd;
}

.excluded-days {
  list-style: none;
  padding-left: 0;
  margin-top: 0.5rem;
  font-size: 0.9em;
  color: #666;
}

.vacation-table {
  width: 100%;
  margin-top: 1rem;
  border-collapse: collapse;
}

.vacation-table th,
.vacation-table td {
  padding: 0.5rem;
  text-align: left;
  border-bottom: 1px solid #dee2e6;
}

.remaining-days {
  font-weight: 500;
  color: #0d6efd;
}

/* Feiertags-Verwaltung */
.holiday-entry {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  align-items: center;
}

.holiday-entry input[type="date"],
.holiday-entry input[type="text"] {
  padding: 0.3rem;
  border: 1px solid #ced4da;
  border-radius: 4px;
}

.holiday-entry input[type="text"] {
  flex-grow: 1;
}

/* Status Badges */
.status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 500;
}

.status-badge.lateshift {
  background-color: #f0ad4e;
  color: #fff;
}

.status-badge.fulltime {
  background-color: #28a745;
  color: #fff;
}

.status-badge.parttime {
  background-color: #697d92;
  color: #fff;
}

/* Modal Styles für Urlaubsverwaltung */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  animation: fadeIn 0.3s ease-out;
}

.modal-content {
  background-color: #ffffff;
  padding: 2rem;
  border-radius: 8px;
  width: 90%;
  max-width: 1440px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  position: relative;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #dee2e6;
}

.close-modal {
  font-size: 1.8rem; /* Größer für bessere Klickbarkeit */
  font-weight: bold;
  line-height: 1; /* Verhindert extra Höhe */
  color: var(--text-color);
  background: none;
  border: none;
  padding: 0 var(--spacing-sm); /* Etwas Padding */
  cursor: pointer;
  transition: color var(--transition-fast);
  opacity: 0.6;
}

.close-modal:hover {
  color: var(--danger-color);
  opacity: 1;
}

/* Buttons */
.btn-settings {
  background-color: #6c757d;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.btn-settings:hover {
  background-color: #5a6268;
}

.btn-add {
  background-color: #28a745;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 1rem;
  transition: background-color 0.3s;
}

.btn-add:hover {
  background-color: #218838;
}


@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Responsive Anpassungen */
@media (max-width: 768px) {
  #schedule {
    gap: 0.3em;
  }
  
  .day {
    padding: 0.5em;
    min-height: 120px;
  }
  
  .day h3 {
    font-size: 0.9em;
  }
  
  .modal-content {
    width: 95%;
    padding: 1rem;
  }
  
  .holiday-entry {
    flex-direction: column;
  }
  
  .holiday-entry input[type="date"],
  .holiday-entry input[type="text"] {
    width: 100%;
  }
}



/* Styles für den Urlaubseinstellungen-Button */
.btn-settings {
  background-color: #6c757d;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
  margin-left: 1rem;
}

.btn-settings:hover {
  background-color: #5a6268;
}

/* Styles für die Feiertags-Verwaltung */
.holiday-entry {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  align-items: center;
}

.holiday-entry input[type="date"],
.holiday-entry input[type="text"] {
  padding: 0.3rem;
  border: 1px solid #ced4da;
  border-radius: 4px;
}

.holiday-entry input[type="text"] {
  flex-grow: 1;
}



/* Urlaubsübersicht Styles */
.vacation-overview {
  padding: 1rem;
}

.vacation-stats {
  background-color: #f8f9fa;
  padding: 1rem;
  border-radius: 4px;
  margin: 1rem 0;
}

.vacation-progress {
  margin: 1rem 0;
}

.progress-bar {
  height: 20px;
  background-color: #e9ecef;
  border-radius: 10px;
  overflow: hidden;
}

.progress {
  height: 100%;
  background-color: #007bff;
  transition: width 0.3s ease;
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.history-table th,
.history-table td {
  padding: 0.5rem;
  border-bottom: 1px solid #dee2e6;
  text-align: left;
}

.vacation-list {
  list-style: none;
  padding: 0;
}

.vacation-list li {
  padding: 0.5rem;
  border-bottom: 1px solid #dee2e6;
}

.vacation-list .workday {
  color: #dc3545;
}

.vacation-list .non-workday {
  color: #6c757d;
}

.btn-overview {
  background-color: #17a2b8;
  color: white;
  border: none;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 0.5rem;
  font-size: 0.9em;
}

.btn-overview:hover {
  background-color: #138496;
}


/* Urlaubsanzeige Styles */
.vacation-info {
  background-color: #f8f9fa;
  padding: 0.8rem;
  border-radius: 6px;
  margin: 0.5rem 0;
}

.remaining-days {
  color: #0d6efd;
  font-weight: 500;
  font-size: 0.9em;
}

.vacation-progress {
  margin: 1rem 0;
}

.progress-bar {
  height: 12px;
  background-color: #e9ecef;
  border-radius: 6px;
  overflow: hidden;
  margin-top: 0.5rem;
}

.progress {
  height: 100%;
  background-color: #0d6efd;
  transition: width 0.3s ease;
}

/* Urlaubsübersicht Modal Styles */
.vacation-overview {
  padding: 1rem;
}

.vacation-stats {
  background-color: #f8f9fa;
  padding: 1rem;
  border-radius: 4px;
  margin: 1rem 0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.vacation-details {
  margin-top: 1.5rem;
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.history-table th,
.history-table td {
  padding: 0.75rem;
  border-bottom: 1px solid #dee2e6;
  text-align: left;
}

.history-table th {
  background-color: #f8f9fa;
  font-weight: 500;
}

.vacation-list {
  list-style: none;
  padding: 0;
}

.vacation-list li {
  padding: 0.75rem;
  border-bottom: 1px solid #dee2e6;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vacation-list .workday {
  color: #dc3545;
}

.vacation-list .non-workday {
  color: #6c757d;
}

/* Button Styles */
.btn-overview {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  font-size: 0.9rem;
  font-weight: 400;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  user-select: none;
  border: 1px solid transparent;
  border-radius: 0.25rem;
  background-color: #17a2b8;
  color: white;
  transition: all 0.15s ease-in-out;
  cursor: pointer;
  margin-top: 0.5rem;
}

.btn-overview:hover {
  background-color: #138496;
  transform: translateY(-1px);
}

/* Animation für Updates */
@keyframes highlight {
  0% {
    background-color: #fff;
  }
  50% {
    background-color: #e3f2fd;
  }
  100% {
    background-color: #fff;
  }
}

.updated {
  animation: highlight 1s ease-in-out;
}


.history-table th {
  background-color: #92989e;
  font-weight: 500;
}
.shift-block {
  margin: 0.5rem 0;
  padding: 0.5rem;
  border-radius: 4px;
}

.shift-block h4 {
  margin: 0 0 0.5rem 0;
  font-size: 0.9em;
  color: #666;
}

.shift-block p {
  margin: 0.2rem 0;
  padding: 0.3rem 0.6rem;
  border-radius: 3px;
  background: #f8f9fa;
}

.lateshift h4 {
  color: #f0ad4e;
}

.fulltime h4 {
  color: #28a745;
}

.parttime h4 {
  color: #007bff;
}
.btn-staffing, .btn-vacation-settings, .btn-weekly-template {
  background-color: #6c757d;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
  margin-left: 1rem;
}

.btn-staffing:hover, .btn-vacation-settings:hover, .btn-weekly-template:hover {
  background-color: #5a6268;
}

.btn-icon {
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  border: 1px solid #ccc;
  background: #f8f9fa;
  cursor: pointer;
}

.btn-scheduling-modal.btn-icon {
  margin-left: 0.5rem;
}

.btn-saturday-rotation.btn-icon {
  margin-left: 0.5rem;
}

#saturday-rotation-modal {
  align-items: stretch;
  padding: 2vh 0;
}

#saturday-rotation-modal .modal-content {
  display: flex;
  flex-direction: column;
  width: min(1120px, 96vw) !important;
  max-width: 96vw !important;
  height: 94vh;
  max-height: 94vh !important;
  margin: 0 auto !important;
  overflow: hidden;
}

#saturday-rotation-modal .modal-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 0 0.25rem 0 0;
}

.saturday-modal-layout {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(280px, 0.95fr) minmax(360px, 1.05fr);
  align-items: start;
}

.saturday-modal-panel {
  background: #fbfcfc;
  border: 1px solid rgba(31, 52, 65, 0.12);
  border-radius: var(--ui-radius);
  padding: 12px;
}

.saturday-modal-panel--stats {
  grid-column: 1 / -1;
}

.saturday-modal-panel--stats h4 {
  align-items: center;
  display: flex;
  gap: 0.45rem;
  margin: 0 0 10px;
}

.saturday-modal-panel .info-text {
  color: #666;
  font-size: 0.9em;
  line-height: 1.4;
  margin: 0 0 14px;
}

.saturday-modal-help {
  color: #777;
  font-size: 0.85em;
  line-height: 1.4;
  margin: 5px 0 10px;
}

.saturday-rotation-group-list {
  border: 1px solid #ddd;
  border-radius: var(--ui-radius);
  max-height: 260px;
  overflow-y: auto;
  padding: 10px;
}

.saturday-modal-actions {
  margin: 14px 0 0;
}

.saturday-distribution-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn-danger {
  background: #d64545 !important;
  color: white !important;
}

.saturday-distribution-preview,
.saturday-stats-summary {
  background: #f8f9fa;
  border-left: 3px solid #2196F3;
  border-radius: 4px;
  color: #555;
  font-size: 0.86em;
  line-height: 1.35;
  margin: 8px 0 12px;
  padding: 8px 10px;
}

.saturday-stats-summary strong {
  color: #333;
}

.saturday-preview-table {
  border-collapse: collapse;
  margin-top: 8px;
  width: 100%;
}

.saturday-preview-table td {
  border-bottom: 1px solid #e2e2e2;
  font-size: 0.86em;
  padding: 4px 6px;
  vertical-align: top;
}

.saturday-preview-table td:first-child {
  white-space: nowrap;
  width: 5.5rem;
}

.saturday-stats-filter,
.print-option-toggle {
  align-items: center;
  color: #555;
  display: inline-flex;
  font-size: 0.86em;
  gap: 0.4rem;
  margin: 4px 0 10px;
}

.saturday-stats-controls {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 2px 0 12px;
}

.saturday-stats-range-fields {
  align-items: center;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
}

.saturday-stats-range-fields label {
  align-items: center;
  color: #555;
  display: inline-flex;
  font-size: 0.86em;
  gap: 0.35rem;
}

.saturday-stats-range-fields input[type="date"] {
  border: 1px solid #d5dde2;
  border-radius: var(--ui-radius);
  color: #28343b;
  font: inherit;
  min-height: 34px;
  padding: 5px 8px;
}

.saturday-stats-range-fields input[type="date"]:disabled {
  background: #eef2f4;
  color: #8a969d;
}

.saturday-stats-output {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(260px, 0.9fr) minmax(360px, 1.1fr);
  align-items: start;
}

.saturday-stats-hint {
  color: #777;
  font-size: 0.8em;
  margin: 10px 0 0;
}

.print-meta {
  display: none;
}

/* Saturday Stats List */
#saturday-stats-list {
  max-height: none !important;
  overflow: visible !important;
}

#saturday-stats-list li {
  display: block;
  padding: 8px 12px;
  margin: 4px 0;
  background: #f8f9fa;
  border-radius: 4px;
  border-left: 3px solid transparent;
}

.saturday-stats-chart {
  display: grid;
  gap: 6px;
  margin: 8px 0 12px;
}

.saturday-stat-bar {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(120px, 1.1fr) minmax(120px, 2fr) 2.5rem;
  font-size: 0.86em;
}

.saturday-stat-bar-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.saturday-stat-bar-track {
  background: #e9ecef;
  border-radius: var(--ui-radius);
  display: block;
  height: 10px;
  overflow: hidden;
}

.saturday-stat-bar-fill {
  background: #2196F3;
  border-radius: var(--ui-radius);
  display: block;
  height: 100%;
}

.saturday-stat-bar.max .saturday-stat-bar-fill {
  background: #f0ad4e;
}

.saturday-stat-bar.min .saturday-stat-bar-fill {
  background: #4CAF50;
}

.saturday-stat-bar-count {
  color: #333;
  font-weight: 700;
  text-align: right;
}

.saturday-stat-header {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
}

.saturday-stat-dates {
  color: #666;
  font-size: 0.82em;
  line-height: 1.35;
  margin-top: 4px;
}

#saturday-stats-list li:nth-child(1) {
  border-left-color: #ffd700; /* Gold für meiste */
}

#saturday-stats-list li:nth-child(2) {
  border-left-color: #c0c0c0; /* Silber */
}

#saturday-stats-list li:nth-child(3) {
  border-left-color: #cd7f32; /* Bronze */
}

.stat-count {
  font-weight: bold;
  color: #2196F3;
}

[data-theme="dark"] #saturday-stats-list li {
  background: #2d2d2d;
}

[data-theme="dark"] .saturday-stat-bar-track {
  background: #3a3a3a;
}

[data-theme="dark"] .saturday-stat-bar-count {
  color: #eee;
}

[data-theme="dark"] .saturday-stat-dates {
  color: #c8d0d6;
}

[data-theme="dark"] .saturday-modal-panel {
  background: #242a2e;
  border-color: rgba(205, 218, 226, 0.14);
}

[data-theme="dark"] .saturday-stats-range-fields input[type="date"] {
  background: #20262a;
  border-color: #3a454b;
  color: #e6edf1;
}

[data-theme="dark"] .saturday-stats-range-fields input[type="date"]:disabled {
  background: #2a3034;
  color: #8f9da5;
}

.checkbox-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px 12px;
  padding: 6px 2px;
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid #ddd;
  border-radius: 6px;
}

@media (max-width: 900px) {
  #saturday-rotation-modal .modal-content {
    width: min(96vw, 720px) !important;
    height: 94vh;
  }

  .saturday-modal-layout,
  .saturday-stats-output {
    grid-template-columns: 1fr;
  }

  .saturday-stats-range-fields {
    width: 100%;
  }
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

form#addEmployeeForm {
  margin-bottom: 30px;
}

/* Styles für das Bearbeitungs-Modal mit mehreren Selects */
.schedule-edit .form-group {
  margin-bottom: 1.5rem;
  padding: 1rem;
  background-color: #f8f9fa;
  border-radius: 8px;
 }
 
 .schedule-edit .form-group label {
  display: block;
  margin-bottom: 1rem;
  font-weight: 500;
  color: #495057;
  border-bottom: 2px solid #dee2e6;
  padding-bottom: 0.5rem;
 }
 
 .schedule-edit .shift-select {
  width: 100%;
  padding: 8px;
  margin-top: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  transition: border-color 0.3s, box-shadow 0.3s;
  background-color: white;
 }
 
 .schedule-edit .shift-select:not(:last-child) {
  margin-bottom: 0.5rem;
 }
 
 .schedule-edit .shift-select:focus {
  border-color: #80bdff;
  box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
  outline: none;
 }
 .unavailable-days label {
  display: flex;
  align-items: center;
  gap: 10px;
}

.unavailable-days div {
  margin-bottom: 5px;
}
 /* Spezielle Styles für die verschiedenen Schichttypen */
 .schedule-edit .form-group:nth-child(1) .shift-select { /* Spätschicht */
  border-left: 3px solid #28a745;
 }
 
 .schedule-edit .form-group:nth-child(2) .shift-select { /* Vollzeit */
  border-left: 3px solid #f0ad4e;
 }
 
 .schedule-edit .form-group:nth-child(3) .shift-select { /* Teilzeit */
  border-left: 3px solid #007bff;
 }
 
 /* Option Styles */
 .schedule-edit .shift-select option[value=""] {
  font-style: italic;
  color: #6c757d;
 }
 
 /* Konfliktanzeige */
 .schedule-conflicts {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #fff3f3;
  border-left: 4px solid #dc3545;
  border-radius: 4px;
 }
 
 .schedule-conflicts p {
  margin: 0.5rem 0;
  color: #dc3545;
 }
 
 /* Hover-Effekte */
 .schedule-edit .shift-select:hover {
  border-color: #ced4da;
 }
 
 /* Zusätzliche visuelle Hilfen */
 .schedule-edit .form-group small {
  display: block;
  margin-top: 0.25rem;
  color: #6c757d;
 }
 
 /* Animation für neue Einträge */
 @keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
 }
 
 .schedule-edit .shift-select {
  animation: fadeIn 0.3s ease-out;
 }

 .form-group {
  width: 100%;
}



/* 1. CSS-Variablen & Theme */
:root {
  /* Farben */
  --color-primary: #007bff;
  --color-primary-light: #80bdff;
  --color-success: #28a745;
  --color-success-light: #34ce57;
  --color-warning: #f0ad4e;
  --color-warning-light: #f4b84f;
  --color-danger: #dc3545;
  --color-danger-light: #e4606d;
  --color-info: #17a2b8;
  --color-info-light: #1fc8e3;
  --color-gray: #6c757d;
  --color-gray-light: #f8f9fa;
  --color-gray-dark: #4a4a4a;

  /* Abstände */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;

  /* Rundungen */
  --ui-radius: 6px;
  --radius-sm: var(--ui-radius);
  --radius-md: var(--ui-radius);
  --radius-lg: var(--ui-radius);
  --radius-full: 999px;

  /* Schatten */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);

  /* Übergänge */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
}

/* 2. Reset & Basis */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Roboto', sans-serif;
  background-color: var(--color-gray-light);
  color: var(--color-gray-dark);
  line-height: 1.5;
}

.line-icon {
  width: 1em;
  height: 1em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  vertical-align: -0.15em;
  color: currentColor;
}

.line-icon svg {
  width: 1em;
  height: 1em;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.employee-name-with-avatar {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  min-width: 0;
  vertical-align: baseline;
}

.employee-name-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.employee-avatar {
  width: 11.5px;
  height: 11.5px;
  max-width: 11.5px;
  max-height: 11.5px;
  flex: 0 0 11.5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  overflow: hidden;
  background: #d7e0dc;
  box-shadow: 0 0 0 1px rgba(37, 49, 44, 0.14);
}

.employee-avatar-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  border-radius: 50%;
  display: block;
}

.employee-avatar-fallback {
  background: var(--avatar-color, #6f8f82);
  color: #fff;
  font-size: 5.75px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.shift-block p .employee-name-with-avatar,
.conflict-employee .employee-name-with-avatar,
.saturday-stat-header .employee-name-with-avatar {
  gap: 3px;
}

.shift-block p .employee-name-with-avatar {
  display: flex;
  width: 100%;
}

.shift-block p .employee-name-label {
  white-space: nowrap;
  text-overflow: ellipsis;
}

button .line-icon,
.export-button .line-icon,
.modal-header .line-icon,
h3 .line-icon,
h4 .line-icon {
  margin-right: 0.35rem;
}

.btn-icon .line-icon,
.notification-bell .line-icon,
.edit-indicator .line-icon,
.btn-approve .line-icon,
.btn-remove .line-icon,
.btn-remove-unavailable .line-icon,
.btn-remove-holiday .line-icon {
  margin-right: 0;
}

button,
.export-button,
.btn,
.btn-primary,
.btn-secondary,
.btn-save,
input,
select,
textarea,
.modal-content,
.template-modal-content,
.conflict-popup,
.notification,
.day,
.shift-block,
.employee-management,
.export-section,
.saturday-distribution-preview,
.counter-tonus-notice,
.counter-conflict-item,
.vacation-request-item,
.ui-radius-normalized {
  border-radius: var(--ui-radius);
}

/* 3. Layout */
.day.outside-month, .holiday-day {
  opacity: 0.5;
}


/* Beispielhafte Ferientag-Markierung */
.holiday-day {
  background-color: #FFDDE0; /* Sanftes Rot/Rosa */
  border-left: 3px solid #dc3545; /* Rot als Akzent, optional */
}



main {
  padding: var(--spacing-xl);
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xl);
}

/* 4. Container & Sections */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.section {
  background-color: white;
  border-radius: var(--radius-md);
  padding: var(--spacing-xl);
  box-shadow: var(--shadow-sm);
}

/* 5. Typografie */
h1, h2, h3, h4, h5, h6 {
  color: var(--color-gray-dark);
  margin-bottom: var(--spacing-md);
  font-weight: 500;
  line-height: 1.2;
  margin: 0;
}

h1 { font-size: 1.8rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.2rem; }
h4 { font-size: 1.1rem; }

/* 6. Utilities */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mb-1 { margin-bottom: var(--spacing-sm); }
.mb-2 { margin-bottom: var(--spacing-md); }
.mb-3 { margin-bottom: var(--spacing-lg); }
.mt-1 { margin-top: var(--spacing-sm); }
.mt-2 { margin-top: var(--spacing-md); }
.mt-3 { margin-top: var(--spacing-lg); }

/* 7. Buttons */
.btn {
  display: inline-block;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all var(--transition-normal);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn:active {
  transform: translateY(0);
}
/* General weekend style */
.weekend {
  font-weight: bold;
}

/* Make Saturday light orange */
.saturday {
  background-color: #FFF8E1; /* Light orange */
}

/* Make Sunday light blue */
.sunday {
  background-color: #E1F5FE; /* Light blue */
}

/* Example day-name-based classes */
.montag  { /* Monday-specific styling if needed */ }
.dienstag { /* Tuesday-specific styling */ }
/* ... etc. ... */

/* Button Varianten */
.btn-primary {
  background-color: var(--color-primary);
  color: white;
}

.btn-success {
  background-color: var(--color-success);
  color: white;
}

.btn-warning {
  background-color: var(--color-warning);
  color: white;
}

.btn-danger {
  background-color: var(--color-danger);
  color: white;
}

.btn-gray {
  background-color: var(--color-gray);
  color: white;
}

/* Spezielle Buttons */
.btn-settings,
.btn-staffing {
  background-color: var(--color-gray);
  color: white;
  margin-left: var(--spacing-md);
}

/* 8. Forms - Vereinheitlichung */
.form-group {
  margin-bottom: var(--spacing-md);
  width: 100%;
}

.form-label,
label {
  display: block;
  margin-bottom: var(--spacing-sm);
  font-weight: 500;
  color: var(--text-color);
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="month"],
select,
textarea,
.form-control {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md); /* Einheitliches Padding */
  min-height: 38px; /* Einheitliche Mindesthöhe wie Buttons */
  line-height: 1.5; /* Einheitliche Zeilenhöhe */
  border: 1px solid var(--input-border, #ccc);
  border-radius: var(--radius-sm);
  background-color: var(--input-bg, white);
  color: var(--text-color);
  transition: all var(--transition-fast);
  box-sizing: border-box; /* Wichtig für konsistente Größen */
  vertical-align: middle;
}

input[type="text"]:focus,
input[type="number"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="date"]:focus,
input[type="month"]:focus,
select:focus,
textarea:focus,
.form-control:focus {
  border-color: var(--input-focus, #666);
  box-shadow: 0 0 0 3px rgba(var(--input-focus, #666), 0.1);
  outline: none;
}

select {
  /* Standard-Browser-Pfeil beibehalten für Einfachheit */
  /* appearance: none; */ 
  background-image: none; /* Entfernt potenzielle Custom-Pfeile */
  cursor: pointer;
}

textarea {
  min-height: 80px; /* Mindesthöhe für Textareas */
  line-height: 1.4; /* Etwas geringere Zeilenhöhe für Fließtext */
}

/* Dark Mode Input Anpassungen */
[data-theme="dark"] input[type="text"],
[data-theme="dark"] input[type="number"],
[data-theme="dark"] input[type="email"],
[data-theme="dark"] input[type="password"],
[data-theme="dark"] input[type="date"],
[data-theme="dark"] input[type="month"],
[data-theme="dark"] select,
[data-theme="dark"] textarea,
[data-theme="dark"] .form-control {
    background-color: var(--input-bg, #2d2d2d) !important; /* !important beibehalten wg. vorherigen Regeln */
    color: var(--text-color, #eee) !important;
    border-color: var(--input-border, #555) !important;
}

[data-theme="dark"] select option {
    background-color: var(--dropdown-bg, #333);
    color: var(--text-color, #eee);
}

[data-theme="dark"] input:focus,
[data-theme="dark"] select:focus,
[data-theme="dark"] textarea:focus {
    border-color: var(--input-focus, #2ecc71) !important;
    box-shadow: 0 0 0 3px rgba(var(--input-focus-rgb, 46, 204, 113), 0.2);
}

/* 9. Tabellen */
.table {
  width: 100%;
  background-color: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--spacing-lg);
}

.table thead {
  background-color: var(--color-gray);
  color: white;
}

.table th,
.table td {
  padding: var(--spacing-md);
  text-align: left;
  border-bottom: 1px solid var(--color-gray-light);
}

.table tbody tr:hover {
  background-color: var(--color-gray-light);
}

/* 10. Status-Badges */
.badge {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1;
}

.badge-lateshift {
  background-color: var(--color-warning);
  color: white;
}

.badge-fulltime {
  background-color: var(--color-success);
  color: white;
}

.badge-parttime {
  background-color: var(--color-primary);
  color: white;
}

/* 11. Kalender/Dienstplan */

.weekday-header {
  text-align: center;
  font-weight: bold;
  padding: var(--spacing-sm);
  background-color: var(--color-gray-light);
  border-radius: var(--radius-sm);
}

.day {
  min-height: 150px;
   
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: all var(--transition-normal);
  cursor: pointer;
}

.day:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
  background-color: var(--color-gray-light);
}

.day.outside-month {
  background-color: var(--color-gray-light);
  color: var(--color-gray);
}

/* Schichtblöcke */
.shift-block {
  margin: var(--spacing-sm) 0;
  padding: var(--spacing-sm);
  border-radius: var(--radius-sm);
  border-left: 3px solid;
}

.shift-block.lateshift {
  border-color: var(--color-warning);
}

.shift-block.fulltime {
  border-color: var(--color-success);
}

.shift-block.parttime {
  border-color: var(--color-primary);
}

.shift-block h4 {
  color: var(--color-gray);
  margin-bottom: var(--spacing-sm);
  font-size: 0.9em;
}

.shift-block p {
  margin: var(--spacing-xs) 0;
  padding: var(--spacing-xs) var(--spacing-sm);
  background-color: var(--color-gray-light);
  border-radius: var(--radius-sm);
}




.hat_urlaub {
  position: relative; /* or whatever suits your layout */
  background: #ff00005c!important;
  opacity: 0.7;
}

.hat_urlaub .urlaub-badge {
 font-size: 0.9em;
    background: rgba(206, 38, 38, 0.693);
    color: white;
    padding: 0px 7px;
    margin-top: 0px;
    border-radius: 3px;
    position: absolute;
    right: 5px;

}
 


/* 12. Modals & Overlays */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn var(--transition-normal);
}

.modal-content {
  background-color: white;
  padding: var(--spacing-xl);
  border-radius: var(--radius-md);
  width: 90%;
  max-width: 1440px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: slideIn var(--transition-normal);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--color-gray-light);
}

.modal-body {
  margin-bottom: var(--spacing-lg);
}

.close-modal {
  font-size: 1.8rem; /* Größer für bessere Klickbarkeit */
  font-weight: bold;
  line-height: 1; /* Verhindert extra Höhe */
  color: var(--text-color);
  background: none;
  border: none;
  padding: 0 var(--spacing-sm); /* Etwas Padding */
  cursor: pointer;
  transition: color var(--transition-fast);
  opacity: 0.6;
}

.close-modal:hover {
  color: var(--danger-color);
  opacity: 1;
}

.modal-body { 
    padding: var(--spacing-lg); 
    /* margin-bottom entfernt, Abstand durch Footer-Padding */
}

.modal-footer {
  padding: var(--spacing-md);
  border-top: 1px solid var(--border-color);
  text-align: right; /* Buttons rechtsbündig */
}

.modal-footer button:not(:last-child) {
    margin-right: var(--spacing-sm);
}

/* Dark Mode Modal Close Button */
[data-theme="dark"] .close-modal {
  color: var(--text-color) !important; /* !important wg. alter Regel */
  opacity: 0.7;
}
[data-theme="dark"] .close-modal:hover {
  color: var(--danger-color) !important;
  opacity: 1;
}

/* Konsistente Hover Effekte für Tabellen und Kalendertage */
tbody tr:hover {
  background-color: var(--hover-bg);
  cursor: default; /* Normalerweise kein Klick-Effekt bei reinen Info-Tabellen */
}

#employeesTable tbody tr:hover {
    cursor: pointer; /* Mitarbeiterliste ist interaktiv */
}

.day:hover {
  transform: translateY(-2px); 
  box-shadow: var(--shadow-md);
  background-color: var(--hover-bg);
  cursor: pointer;
}

[data-theme="dark"] tbody tr:hover,
[data-theme="dark"] .day:hover {
    background-color: var(--hover-bg);
}




/* 14. Spezielle Modal-Varianten */
/* Urlaubs-Modal */
.vacation-overview {
  padding: var(--spacing-md);
}

.vacation-stats {
  background-color: var(--color-gray-light);
  padding: var(--spacing-md);
  border-radius: var(--radius-sm);
  margin: var(--spacing-md) 0;
  box-shadow: var(--shadow-sm);
}

.vacation-progress {
  margin: var(--spacing-md) 0;
}

.progress-bar {
  height: 12px;
  border: 1px solid #c2ccff;
  background-color: #cce5ff;
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-top: var(--spacing-sm);
}

.progress {
  height: 100%;
  background-color: var(--color-primary);
  transition: width var(--transition-normal);
}

/* Schichtbearbeitung-Modal */
.schedule-edit .form-group {
  margin-bottom: var(--spacing-lg);
  padding: var(--spacing-md);
  background-color: var(--color-gray-light);
  border-radius: var(--radius-md);
}

.schedule-conflicts {
  margin: var(--spacing-md) 0;
  padding: var(--spacing-md);
  background-color: #fff3f3;
  border-left: 4px solid var(--color-danger);
  border-radius: var(--radius-sm);
}

/* 15. Animationen */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideIn {
  from { 
    opacity: 0;
    transform: translateY(-20px);
  }
  to { 
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to { opacity: 0; }
}

@keyframes highlight {
  0% { background-color: white; }
  50% { background-color: var(--color-gray-light); }
  100% { background-color: white; }
}

/* 16. Responsive Design Verbesserungen */
@media (max-width: 1200px) {
  .container {
    padding: 0 var(--spacing-md);
  }
}

@media (max-width: 768px) {
  .modal-content {
    width: 95%;
    padding: var(--spacing-md);
  }
  
  .schedule {
    gap: var(--spacing-xs);
  }
  
  .day {
    padding: var(--spacing-sm);
    min-height: 120px;
  }
  
  .day h3 {
    font-size: 0.9em;
  }
  
  .shift-block {
    font-size: 0.9em;
  }
}

@media (max-width: 576px) {
  .controls {
    flex-direction: column;
    align-items: stretch;
  }
  
  .btn {
    width: 100%;
    margin-left: 0;
    margin-top: var(--spacing-sm);
  }
  
  .modal-content {
    padding: var(--spacing-sm);
  }
}


/* Erweiterte Tages-Styles */
.day {
  /* Bestehende Styles bleiben... */
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
  border: 1px solid transparent;
}

.day:hover {
  /* Bestehende Styles bleiben... */
  border-color: var(--color-primary-light);
}

.day.today {
  border-left: 3px solid var(--color-primary);
}

.day.has-conflict {
  border-left: 3px solid var(--color-danger);
}

/* Verbesserte Shift-Block Styles */
.shift-block {
  /* Bestehende Styles bleiben... */
  position: relative;
  transition: all var(--transition-normal);
}

.shift-block:hover {
  transform: translateX(4px);
  background-color: var(--color-gray-light);
}

.shift-block.empty {
  opacity: 0.7;
  border-style: dashed;
}

/* Status-Badge Erweiterungen */
.badge {
  /* Bestehende Styles bleiben... */
  position: relative;
  padding-left: var(--spacing-lg);
}

.badge::before {
  content: '';
  position: absolute;
  left: var(--spacing-xs);
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: currentColor;
}

/* Verbesserte Button-Styles */
.btn {
  /* Bestehende Styles bleiben... */
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5px;
  height: 5px;
  background: rgba(255, 255, 255, 0.5);
  opacity: 0;
  border-radius: 100%;
  transform: scale(1, 1) translate(-50%);
  transform-origin: 50% 50%;
}

.btn:active::after {
  animation: ripple 1s ease-out;
}

@keyframes ripple {
  0% {
    transform: scale(0, 0);
    opacity: 0.5;
  }
  100% {
    transform: scale(40, 40);
    opacity: 0;
  }
}

/* Tabellen-Erweiterung */
.table {
  /* Bestehende Styles bleiben... */
  position: relative;
}

.table tbody tr:nth-child(even) {
  background-color: var(--color-gray-light);
}

.table td.highlight {
  position: relative;
  z-index: 1;
}

.table td.highlight::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-primary);
  opacity: 0.1;
  z-index: -1;
}

/* Form-Erweiterungen */
.form-group.required label::after {
  content: '*';
  color: var(--color-danger);
  margin-left: var(--spacing-xs);
}

.form-control.is-invalid {
  border-color: var(--color-danger);
  background-image: url("data:image/svg+xml,..."); /* Fehlersymbol */
  padding-right: calc(1.5em + 0.75rem);
  background-repeat: no-repeat;
  background-position: right calc(0.375em + 0.1875rem) center;
  background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

/* Modal-Erweiterungen */
.modal-content {
  /* Bestehende Styles bleiben... */
  position: relative;
}

.modal-content.loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
}


.holiday-day::after {
  content: 'Feiertag' !important;
  display: inline-grid;
  background-color: #ff5722;
  color: #fff;
  padding: 2px 6px;
  font-size: 1.25rem;
  position: relative !important;
  border-radius: 3px;
  justify-content: center;
  align-items: center;
  bottom: 0px;
  top: auto!important;
  left: auto!important;
  right: auto!important;
}


/* Hide paragraphs if they're empty */
.shift-block p:empty {
  display: none;
}

/* Then hide the entire shift-block if it does NOT have any non-empty p */
.shift-block:not(:has(p:not(:empty))) {
  display: none;
}
/* This class highlights or dims the employee line in schedule and/or list */
.custom_urlaub {
  opacity: 0.5; /* Example styling */
  position: relative;
}

/* This is the little badge or tag.  
   We're simply placing it inline after the name. */
.vacation-tag {
  display: inline-block;
  background-color: #ff5722; /* bright color for visibility */
  color: #fff;
  padding: 2px 6px;
  font-size: 0.75rem;
  border-radius: 3px;
  margin-left: 6px;
  position: relative;
  top: -1px; /* Slight vertical alignment tweak if needed */
}

/* 
  Optionally, you can style 
  the 'custom_urlaub' text differently in the employees table 
  by referencing the same class or using a distinct class if needed.
*/
.custom_urlaub_in_employee_list {
  color: #cccccc;
  text-decoration: line-through;
}



/*******/


/* Erweiterte Kalenderansicht */
.weekday-header.weekend {
  color: var(--color-danger);
  background-color: rgba(220, 53, 69, 0.1);
}

.day.has-holiday {
  background: linear-gradient(45deg, 
    transparent 0%, 
    transparent 95%, 
    var(--color-warning) 95%, 
    var(--color-warning) 100%
  );
}

.day.has-vacation {
  background: linear-gradient(-45deg, 
    transparent 0%, 
    transparent 95%, 
    var(--color-info) 95%, 
    var(--color-info) 100%
  );
}

/* Verbesserte Schichtanzeige */
.shift-block {
  /* Bestehende Styles bleiben */
  position: relative;
  overflow: hidden;
}

.shift-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(
    to right,
    transparent,
    currentColor,
    transparent
  );
  opacity: 0.2;
}

/* Erweiterte Status-Anzeigen */
.employee-status {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.employee-status::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.employee-status.available::before {
  background-color: var(--color-success);
}

.employee-status.on-vacation::before {
  background-color: var(--color-info);
}

.employee-status.unavailable::before {
  background-color: var(--color-danger);
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}

/* Tooltips für bessere UX */
[data-tooltip] {
  position: relative;
}

[data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: var(--spacing-xs) var(--spacing-sm);
  background-color: rgba(0, 0, 0, 0.8);
  color: white;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  white-space: nowrap;
  z-index: 1000;
  animation: fadeIn 0.2s ease-out;
}

/* Verbesserte Drag & Drop Visualisierung */
.draggable {
  cursor: grab;
}

.dragging {
  cursor: grabbing;
  opacity: 0.8;
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

/* Loading States */
.loading-skeleton {
  background: linear-gradient(
    90deg,
    var(--color-gray-light) 0%,
    #f0f0f0 50%,
    var(--color-gray-light) 100%
  );
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}



@keyframes progress {
  from { width: 100%; }
  to { width: 0%; }
}

/* Erweiterte Modal-Transitionen */
.modal.slide-up {
  animation: slideUp 0.3s ease-out;
}

.modal.slide-down {
  animation: slideDown 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes slideDown {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}


.shift-block p {
  width: 100%;
}
input#employeeVacationDays {
  width: 5%;
  min-width: 150px;
  padding: 10px;
}
table.history-table tr th {
  color: black;
}




.vacation-overview {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.vacation-overview-modal .tab {
  display: flex;
  border-bottom: 1px solid #ddd;
  margin-bottom: 12px;
}

.vacation-overview-modal .tablinks {
  flex: 1;
  background-color: #f2f2f2;
  border: none;
  border-right: 1px solid #ddd;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
  color: #333;
}

.vacation-overview-modal .tablinks:last-child {
  border-right: none;
}

.vacation-overview-modal .tablinks.active {
  background-color: #fff;
  color: #0d6efd;
  border-bottom: 1px solid transparent;
}

.vacation-overview-modal .tabcontent {
  display: none;
}

.vacation-overview-modal .tabcontent.active {
  display: block;
}

.vacation-overview-modal .unavailable-details ul {
  list-style: none;
  padding-left: 0;
}

.vacation-overview-modal .unavailable-details li {
  padding: 0.6rem;
  border-bottom: 1px solid #dee2e6;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vacation-booking {
  background-color: #f8f9fa;
  padding: 1rem;
  border-radius: 8px;
  border-left: 4px solid #0d6efd;
}

.vacation-preview {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #e9ecef;
  border-radius: 4px;
}

.excluded-days {
  list-style: none;
  padding-left: 0;
  margin-top: 0.5rem;
  font-size: 0.9em;
  color: #666;
}

.vacation-list li {
  padding: 0.75rem;
  border-bottom: 1px solid #dee2e6;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background-color 0.3s ease;
}

.vacation-list li:hover {
  background-color: #f8f9fa;
}

.vacation-list .workday {
  color: #dc3545;  /* Rot für Urlaubstage */
}

.vacation-list .non-workday {
  color: #6c757d;  /* Grau für Wochenenden/Feiertage */
}

.vacation-list .school-day {
  color: #2196F3;  /* Blau für Schultage */
  font-style: italic;
}

.vacation-list li:last-child {
  border-bottom: none;
}

/* Optional: Runde Ecken für die gesamte Liste */
.vacation-list {
  border-radius: 4px;
  overflow: hidden;
  background-color: white;
  border: 1px solid #dee2e6;
}

tbody {
  column-count: 2;

}

.vacation-info {
  display: inline-flex;
  width: 100%;
}

.vacation-progress {
  margin: var(--spacing-md) 0;
  width: 80%;
  padding-right: 5%;
}

tbody tr {

  transform: scale(1.0);
 
    transition: 0.4s ease all;
    z-index: 9999;;
}

tbody tr:hover {
  border-color: var(--color-primary-light);
  transform: scale(1.005);
    box-shadow: var(--shadow-lg);
    background-color: var(--color-gray-light);
    transition: 0.4s ease all;
    z-index: 9999;
  
}





  

/* Basis-Stile */
body {
  font-family: 'Roboto', sans-serif;
  background-color: #ffffff;
}

header, footer {
  text-align: center;
  margin-bottom: 20px;
  padding: 5px;
    padding-left: 30px;
}
 footer {
  text-align: center;
  margin-bottom: 0px;
  padding: 50px;
    padding-left: 30px;
}


h1, h2, h3, h4 {
  color: #333;
}

button {
  cursor: pointer;
}

/* Allgemeine Button-Stile */
button {
  padding: 10px 15px;
  margin: 5px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
}

button:hover {
  opacity: 0.9;
}

.btn-save {
  background-color: #28a745;
  color: white;
}

.btn-cancel {
  background-color: #6c757d;
  color: white;
}

.btn-delete {
  background-color: #a0303bb6;
  color: white;
}

.btn-edit {
  background-color: #b47528c8;
  color: white;
}

.btn-add {
  background-color: #17a2b8;
  color: white;
}

.btn-overview {
  background-color: #5f748a;
  color: white;
}

.btn-staffing, .btn-vacation-settings {
  background-color: #343a40;
  color: white;
}

.btn-remove {
  background-color: #dc3545;
  color: white;
}

/* Akkordeon-Stile */
.accordion {
  background-color: #36485b;
  color: white;
  cursor: pointer;
  padding: 15px;
  width: 100%;
  border: none;
  text-align: left;
  outline: none;
  font-size: 18px;
  transition: background-color 0.3s ease;
  margin-bottom: 5px;
  border-radius: 4px;
}

.accordion:hover {
  background-color: #0056b3;
}

.accordion.active {
  background-color: #0056b3;
}
.panel {
  max-height: 0;
  opacity: 0;
  padding: 0 15px;
  background-color: #f1f1f1;
  overflow: hidden;
  transition: max-height 0.5s ease, opacity 0.5s ease, padding 0.5s ease;
  border-radius: 0 0 4px 4px;
}

.panel.show {
  max-height: fit-content;
  min-height: 100px;
  height: fit-content;
  opacity: 1;
  padding-top: 14px;
  padding-bottom: 20px;
}

.employee-management {
  margin-bottom: 30px;
}

/* Tabellen-Stile */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
  background-color: white;
  border-radius: 4px;
  overflow: hidden;
}

th, td {
  padding: 12px;
  border-bottom: 1px solid #ddd;
  text-align: left;
}

th {
  /*background-color: #f2f2f2;*/
}

tr:hover {
  /*background-color: #f1f1f1;*/
}

.status-badge {
  padding: 5px 10px;
  border-radius: 12px;
  color: white;
  font-size: 12px;
}

.status-badge.fulltime {
  background-color: #28a745;
}

.status-badge.parttime {
  background-color: #17a2b8;
}

.status-badge.lateshift {
  background-color: #ffc107;
}

/* Progressbalken-Stile */
.progress-bar {
  width: 100%;
  background-color: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
  height: 10px;
  margin-top: 5px;
}

.progress {
  height: 100%;
  background-color: #28a745;
  width: 0%;
  transition: width 0.3s ease;
}

/* Modal-Stile */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background-color: white;
  padding: 20px;
  border-radius: 4px;
  width: 90%;
  max-width: 1440px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  margin: 0;
}

.close-modal {
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
}

.modal-body {
  margin-top: 10px;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select {
  width: 100%;
  padding: 8px;
  box-sizing: border-box;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.schedule-edit-submit-actions {
  justify-content: center;
  position: static;
  z-index: 3;
  align-items: center;
  padding: 18px 0 4px;
  margin: 20px 0 0;
  background: transparent;
  border-top: 1px solid #e0e0e0;
  border-bottom: 0;
}

.schedule-edit-submit-actions .btn-submit-day {
  min-width: 140px;
}

.schedule-edit-reset-actions {
  justify-content: center;
  margin-top: 14px;
}

[data-theme="dark"] .schedule-edit-submit-actions {
  background: transparent;
  border-color: #444;
}

.vacation-info, .current-year-status, .vacation-booking, .yearly-history, .vacation-details, .employee-info, .quick-actions {
   
}

.vacation-preview p, .vacation-info p, .current-year-status p {
  margin: 5px 0;
}

.excluded-days {
  list-style-type: disc;
  padding-left: 20px;
}

.vacation-form .date-range {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.vacation-form .form-group {
  flex: 1;
}

.vacation-progress {
  margin-top: 10px;
}

.modal-content.schedule-edit .form-group label {
  font-weight: bold;
}

.modal-content.delete-confirmation .warning {
  color: #dc3545;
  font-weight: bold;
}

.confirmation-buttons {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.vacations-container .vacation-month {
  margin-bottom: 15px;
}

.vacations-container .vacation-month h4 {
  margin-bottom: 5px;
}

.vacation-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
}

.vacation-list li.workday {
  color: #28a745;
}

.vacation-list li.non-workday {
  color: #6c757d;
}

.vacation-list .btn-remove {
  padding: 5px 10px;
  font-size: 12px;
}

.shift-block {
  margin-top: 10px;
}

.shift-block h4 {
  margin-bottom: 5px;
  font-size: 16px;
  color: #555;
}

.shift-block p {
  margin: 2px 0;
  font-size: 14px;
  color: #333;
}
.generate_custom {
  background: green;
  font-weight: bold;
  color: white;
  margin-left: 20px;
}


/* Dienstplan-Stile */
.dienstplan {
  margin-bottom: 30px;
}


.weekday-header {
  font-weight: bold;
  text-align: center;
  background-color: #65788e;
  color: white;
  padding: 10px 0;
  border-radius: 4px;
}

.day {
  border: 1px solid #ddd;
  padding: 10px;
  position: relative;
  
  
  border-radius: 4px;
}

.day.outside-month {
  background-color: #e9ecef;
  color: #6c757d;
  pointer-events: none;
}

.day h3 {
  margin: 0 0 10px 0;
 
  font-size: 20px;
  color: #333;
}

.shift-block {
  margin-bottom: 5px;
}

.edit-indicator {
  font-size: 18px;
  color: #007BFF;
}



.staffing-settings {
  width: 100%;
}
 
 


.day .shift-block {
  padding: 5px;
  border-radius: 4px;
}

.day .shift-block.lateshift, .form-group.lateshift {
  background-color: #eed99c53;
  color: white;
  padding: 12px;
  border-radius: 8px;
}

.day .shift-block.fulltime, .form-group.fulltime {
  background-color: #3fa3566b;
  color: white;
  padding: 12px;
  border-radius: 8px;
}

.day .shift-block.parttime, .form-group.parttime {
  background-color: #17a3b87b;
  color: white;
  padding: 12px;
  border-radius: 8px;
}



@keyframes fadeInOut {
  0% { opacity: 0; transform: translateY(-20px); }
  10%, 90% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-20px); }
}

/* Weitere spezifische Stile */
.vacation-settings .year-selector {
  margin-bottom: 15px;
}

.vacation-settings .holiday-entry {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.vacation-settings .holiday-entry input[type="date"],
.vacation-settings .holiday-entry input[type="text"] {
  flex: 1;
}

.vacation-settings .holiday-entry .btn-remove {
  padding: 5px 10px;
  font-size: 12px;
}

.staffing-settings .form-group {
  margin-bottom: 15px;
}

.staffing-settings .form-group input[type="text"],
.staffing-settings .form-group input[type="number"] {
  width: 100%;
  padding: 8px;
  box-sizing: border-box;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.history-table, .vacation-table {
  width: 100%;
  border-collapse: collapse;
}

.history-table th, .history-table td,
.vacation-table th, .vacation-table td {
  border: 1px solid #ddd;
  padding: 8px;
}

.history-table th, .vacation-table th {
  background-color: #f2f2f2;
}

.history-table tr:hover, .vacation-table tr:hover {
  background-color: #f1f1f1;
}

/* Anpassung für spezielle Klassen */
.schedule-edit .form-group label {
  font-weight: bold;
}

.unavailable-days li {
  list-style-type: disc;
  margin-left: 20px;
}

/* Tooltip-Stile (optional) */
.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: 160px;
  background-color: #333;
  color: #fff;
  text-align: center;
  border-radius: 6px;
  padding: 5px 0;
  position: absolute;
  z-index: 1002;
  bottom: 125%; /* Positioniere über dem Element */
  left: 50%;
  margin-left: -80px;
  opacity: 0;
  transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}

/* Stil für das Akkordeon-Header */
.accordion {
  position: relative; /* Ermöglicht die Positionierung des Pseudo-Elements */
  padding-right: 30px; /* Platz für den Pfeil */
  cursor: pointer;
  /* Weitere bestehende Styles */
}

/* Pseudo-Element für den Pfeil */
.accordion::after {
  content: '▼'; /* Unicode für einen nach unten zeigenden Pfeil */
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  transition: transform 0.3s ease; /* Für sanfte Drehung */
  font-size: 16px; /* Größe des Pfeils anpassen */
}

/* Drehung des Pfeils, wenn das Akkordeon aktiv ist */
.accordion.active::after {
  transform: translateY(-50%) rotate(180deg); /* Pfeil nach oben drehen */
}
/***stats**/
/***** Employee Stats Container *****/
/***** Employee Stats Container *****/

.employee-stats-container {
  margin-top: 4rem;
  padding: 1rem;
  border: 1px solid #ddd;
  display: grid;
  grid-template-columns: repeat(1, 1fr); /* Max 6 Spalten */
  grid-gap: 1rem;
}

.stats-heading {
  grid-column: 1 / -1; /* Überschrift spannt die volle Breite */
  margin-bottom: 1rem;
  font-size: 1.5rem; /* Größere Schrift */
  font-weight: bold;
 
}

/* Einzelne Mitarbeiterkarte */
.employee-stats-card {
  border: 1px solid #eee;
  background-color: #fafafa; 
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border-radius: 0.25rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Karte hell-rot hinterlegt, wenn im Urlaub */
.employee-stats-card.card-on-vacation {
  background-color: #ffe6e6; /* Hellrot */
}

/* Abschnitt innerhalb der Karte */
.card-section {
  font-size: 0.9rem;
  padding: 0.25rem 0;
  border-bottom: 1px solid #f2f2f2;
}

.card-section:last-child {
  border-bottom: none;
}

/* Name als Überschrift */
.card-name {
  font-size: 1.2rem; /* Größere Schrift */
  font-weight: bold;
  margin-bottom: 0.25rem;
  padding: 0.5rem;
  border-radius: 0.25rem;
  text-align: center;
}

/***** SHIFT TYPE BACKGROUNDS *****/
.shift-section {
  width: 100%;
  display: grid
;
  grid-template-columns: repeat(1, 1fr);
  justify-content: left;
}

.shift_section_inner {
  width: 100%;
  display: grid
;
  grid-template-columns: repeat(6, 1fr);
  justify-content: left;
}
/* Gemeinsame Stile für shift-block und card-name */
.shift-block.fulltime,
.card-name.fulltime {
  background-color: #5cb85c;  
 
  color: #fff;
}

.shift-block.parttime,
.card-name.parttime {
  background-color: #0275d8;  
  color: #fff;
}

.shift-block.lateshift,
.card-name.lateshift {
  background-color: #f0ad4e; /* Orange für Spätschicht */
  color: #fff;
}

/* Urlaub-Status (Text "Urlaub") */
.status {
  font-weight: 500;
  display: inline-block;
}

.status.on-vacation {
  padding: 0.2rem 0.4rem;
  background: #d9534f;
  color: #fff;
  border-radius: 0.25rem;
}

/* Separator zwischen den Urlaubstagen und den "bis/ab"-Zeilen */
.stats-separator {
  margin: 0.5rem 0;
  border-top: 1px solid #ccc;
}

/* Print-Ansicht: "Urlaubsstatistik" auf neuer Seite */
@media print {
  #employeeStatsContainer {
    page-break-before: always; /* Ältere Browser */
    break-before: page;        /* Moderne Browser */
  }
}

/* Optional: Weitere Verbesserungen */
.employee-stats-card:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
  transition: all 0.2s ease-in-out;
}
/***************/


/* Responsive Design */
@media (max-width: 768px) {
  .vacation-form .date-range {
      flex-direction: column;
  }

  .modal-content {
      width: 95%;
  }

  .shift-block h4 {
      font-size: 14px;
  }

  .shift-block p {
      font-size: 12px;
  }
}

/* Print Styles */
@media print {
  @page {
    size: A4 landscape; /* Querformat A4 */
    margin: 0;          /* Seitenränder 0 */
  }
  

#schedule {
     
   
    background-color: #fff;
   
    border-radius: 0;
    overflow: hidden;
border: 0px solid!important;
 
     
      grid-template-columns: repeat(7, 1fr);
      gap: 0.3em;         /* Kleiner Abstand zwischen Spalten */
      margin-top: 1em;
      page-break-inside: avoid;
    }
  
    /* Entfernt alle Standardabstände, Animationen und Transitionen beim Drucken */
    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
      transition: none !important;
      animation: none !important;
    }
  .card-section {
    font-size: 1.4rem;
}

.hat_urlaub {
    position: relative;
    background: #ff000099 !important;
    opacity: 1;
    color: white !important;
}
    body {
      font-family: Arial, sans-serif;
      margin: 5mm;       /* Kleiner Rand um den Inhalt */
      color: #000;
      background: none;
      line-height: 1.2;  /* Etwas höhere Zeilenhöhe für bessere Lesbarkeit */
    }
  
    /* Nicht drucken */
    .no-print {
      display: none !important;
    }
    .print-only {
      display: block !important;
    }
    header, footer, .controls, .export-buttons, .employee-management, .notification {
      display: none;
    }
    .edit-indicator, .btn-overview, .btn-edit, .btn-delete, .btn-add-vacation, img, svg {
      display: none !important;
    }
  
    /* Überschriften */
    h1, h2, h3, h4, h5, h6 {
      color: #000;
      margin: 0.5em 0;        /* Leichte Abstände */
      page-break-after: avoid;
      line-height: 1.2;
      font-size: 15pt;
    }
  
    /* Gesamtes Dienstplan-Container */
    .dienstplan {
      width: 100%;
      box-sizing: border-box;
      padding: 0;
      overflow: visible;
      page-break-inside: avoid;
    }
  
    /* Kalenderlayout */
    
    .weekday-header {
     display: none;
    }
  
    /* Tageszellen */
    .day {
      break-inside: avoid;
      border: 1px solid #ccc;
      min-height: 60px;
      box-sizing: border-box;
      display: block;
      margin-bottom: 5px;
      padding: 4px 0 5px;
      gap: 10px;          /* Zwischenüberschriften etc. */
      page-break-inside: avoid;
      border-radius: 0;
    }
    .day h3 {
      font-size: 15pt;    /* Größere Tagesüberschrift */
      margin: 0 0 4px;
      line-height: 1;
      border-bottom: 1px solid #ccc;
      padding: 5px;
      font-weight: bold;
    }
  
    /* Schichtblöcke */
    .shift-block {
      page-break-inside: avoid;
      flex: 1;
      border-top: 1px solid #eee; /* Blasse Linie zwischen Schichten */
      padding: 2px 4px;
      margin: 0 0 5px;
      border-radius: 0;
      font-size: 8pt;
    }
    .shift-block:first-of-type {
      border-top: none;
    }
    .shift-block h4 {
      margin: 0 0 2px;
      font-size: 15pt;
      line-height: 1;
      padding: 5px;
    }
    .shift-block p {
      margin: 0 0 12px 0 !important;
      line-height: 1;
     
      display: block;
      float: none;
      clear: both;
      overflow: visible;
      word-wrap: break-word;
      font-size: 1.4rem;
    }
  
    /* Tabellen & Listen (z.B. Mitarbeiterliste) */
    table {
      width: 100%;
      border-collapse: collapse;
      margin: 0;
      padding: 0;
      table-layout: auto;
    }
    table, tr, th, td {
      page-break-inside: avoid;
      page-break-after: auto;
    }
    th, td {
      border: 1px solid #ccc;
      padding: 4px 6px;
      text-align: left;
      font-size: 8pt;
      line-height: 1;
      word-wrap: break-word;
      white-space: normal;
      height: auto;
      max-height: none;
      vertical-align: top;
    }
    th {
      background-color: #f8f8f8;
    }
  
    /* Beispiel: Mitarbeiterliste */
    #employeesTable {
      width: 100%;
      margin-top: 1em;
    }
    #employeesTable th, #employeesTable td {
      font-size: 8pt;
    }

    

    /* Bereiche, die im Druck ausgeblendet werden */
    .vacation-progress,
    .vacation-info,
    .vacation-stats,
    .vacation-overview,
    .vacation-booking,
    .yearly-history,
    .vacation-details {
      display: none;
    }
    .dienstplan h2 {
      font-size: 9pt;
      margin-bottom: 2px;
      line-height: 1;
    }

    section.employee-management {
      display: none;
  }
  header {
    display: none;
}
  }

  


 /* Header Styles */
.controls {
  position: sticky;
  top: 0;
  z-index: 100;
  background: white;
  padding: 10px;
  
  
  display: flex;
  gap: 10px;
  flex-wrap: nowrap;
  align-items: left;
  transition: all 0.3s ease;
}

/* Container für die beiden Reihen */
.header-row-container {
  display: flex;
  gap: 20px;
  width: 100%;
  transition: all 0.3s ease;
}

/* Month Picker Container */
#month-picker {
  display: flex;
  gap: 5px;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
  transition: all 0.3s ease;
}

#month-picker::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

/* Month Picker Buttons */
.month-picker-button {
  padding: 5px 10px;
  border: none;
  border-radius: 4px;
  background: #f0f0f0;
  cursor: pointer;
  white-space: nowrap;
  font-size: 0.9em;
  transition: all 0.2s ease;
}

.month-picker-button:hover {
  background: #e0e0e0;
}

.month-picker-button.past_months {
  opacity: 0.7;
}

.month-picker-button.active_month {
  background: #007bff;
  color: white;
}
/*****//*****//*****//*****//*****//*****//*****//*****//*****//*****/

/* Grundlegendes Layout */
body {
  margin: 0;
  padding-top: 80px; /* Platz für fixed header */
}

/* Fixed Header Container */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 999;
  background: transparent;
  box-shadow: 0 0px 0px rgba(0,0,0,0.0);
}

/* Controls Container */
.controls {
  padding: 10px;
  display: flex;
  flex-direction: row;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  transition: all 0.3s ease;
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
  background: white;
  left: 0 !important;
  background: #d9d9d9;
  width: 100vw;
  position: fixed;
  padding-left: 35px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Container für die beiden Reihen */
.header-row-container {
  display: flex;
  gap: 20px;
  width: 100%;
  transition: all 0.3s ease;
}

/* Reihen */
.controls-row,
.month-picker-row {
  flex: 1;
  min-width: 0;
}

/* Month Picker Container */
#month-picker {
  display: flex;
      gap: 5px;
      flex-wrap: nowrap;
      overflow-x: auto;
      scrollbar-width: none;
      -ms-overflow-style: none;
      transition: all 0.3s ease;
      padding-bottom: 5px;
      margin-top: 45px;
      align-items: left;
      justify-content: left;
}
button.month-picker-button {
  padding-top: 20px;
}
#month-picker::-webkit-scrollbar {
  display: none;
}

/* Month Picker Buttons */
.month-picker-button {
  padding: 5px 10px;
  border: none;
  border-radius: 4px;
  background: #f0f0f0;
  cursor: pointer;
  white-space: nowrap;
  font-size: 0.9em;
  transition: all 0.2s ease;
  color: #333;
}

.month-picker-button:hover {
  background: #e0e0e0;
}

.month-picker-button.past_months {
  opacity: 0.7;
}

.month-picker-button.active_month {
  background: #007bff;
  color: white;
}

/* Control Buttons */
.controls button {
  padding: 5px 10px;
  border: none;
  border-radius: 4px;
  background: #f8f9fa;
  cursor: pointer;
  font-size: 0.9em;
  white-space: nowrap;
  transition: all 0.2s ease;
  color: #333;
}

.controls button:hover {
  background: #e9ecef;
}

/* Month Input */
.controls input[type="month"] {
  padding: 5px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.9em;
}

/* Main Content */
main {
  margin-top: 20px; /* Abstand zum Header */
}

/* Auf schmalen Bildschirmen */
@media (max-width: 768px) {
  body {
    padding-top: 120px; /* Mehr Platz für gestapelten Header */
  }
  
  .header-row-container {
    flex-direction: column;
    gap: 10px;
  }
}



/****import export****/

.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.loading-spinner {
  width: 60px;
  height: 60px;
  border: 6px solid #f3f3f3;
  border-top: 6px solid #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 15px;
}

.loading-text {
  color: white;
  font-size: 18px;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Export/Import Modal Verbesserungen */
.modal-content.export-summary {
  max-width: 600px;
  margin: 20px auto;
}

.export-summary ul {
  list-style: none;
  padding: 0;
  margin: 15px 0;
}

.export-summary li {
  padding: 10px;
  margin: 5px 0;
  background: #f8f9fa;
  border-radius: 4px;
  display: flex;
  justify-content: space-between;
}

.export-summary li:hover {
  background: #e9ecef;
}

.export-summary .warning {
  margin: 15px 0;
  padding: 15px;
  border-radius: 4px;
  background-color: #fff3cd;
  border: 1px solid #ffeeba;
  color: #856404;
}

/* Verbesserte Button-Styles */
.modal-footer button {
  padding: 8px 16px;
  border-radius: 4px;
  font-weight: 500;
  transition: all 0.2s;
}

.btn-confirm {
  background-color: #28a745;
  color: white;
  border: none;
}

.btn-confirm:hover {
  background-color: #218838;
}

.btn-cancel {
  background-color: #dc3545;
  color: white;
  border: none;
}

.btn-cancel:hover {
  background-color: #c82333;
}

/* Verbessertes Feedback */
.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 15px 25px;
  border-radius: 4px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  z-index: 10000;
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
      transform: translateX(100%);
      opacity: 0;
  }
  to {
      transform: translateX(0);
      opacity: 1;
  }
}

.export-section {
  margin: 2rem 0;
  padding: 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.export-section h3 {
  margin-bottom: 1rem;
  color: #2c3e50;
  font-size: 1.2rem;
  font-weight: 500;
}

.export-buttons-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding: 0.5rem;
  border-radius: 6px;
  background: white;
}

.export-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  background: white;
  color: #495057;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.export-button:hover {
  background: #e9ecef;
  border-color: #ced4da;
  transform: translateY(-1px);
}

.export-button:active {
  transform: translateY(0);
}

.export-button.primary {
  background: #007bff;
  border-color: #0056b3;
  color: white;
}

.export-button.primary:hover {
  background: #0056b3;
}

.export-button.secondary {
  background: #6c757d;
  border-color: #545b62;
  color: white;
}

.export-button.secondary:hover {
  background: #545b62;
}

.icon {
  font-size: 1.1em;
}

/* Responsive Design */
@media (max-width: 768px) {
  .export-buttons-container {
    flex-direction: column;
  }

  .button-group {
    flex-direction: column;
  }

  .export-button {
    width: 100%;
    justify-content: center;
  }
}


.controls {
  /* Entfernt die Höhenbeschränkung für besseres Layout */
}


.migration-buttons {
    display: none;
    background: grey;
    padding: 4px;
    transform: scale(0.9);
}


/**knaup**/
p.hat_urlaubswunsch {
    background: #ffffb48a;
}

span.urlaubswunsch-badge {
    background:#ffca00;
    border-radius:3px;
    padding: 3px;
}


#loading-overlay {

    display: none!important;
}

/* Weekly Template Editor */
.template-editor {
  display: flex;
  flex-direction: column;
  margin-bottom: 20px;
}

/* Styling für Feiertage im Kalender */
.holiday-name {
  font-size: 0.9rem;
  font-weight: bold;
  color: #d63031;
  background-color: rgba(255, 235, 235, 0.8);
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: -8px;
  margin-bottom: 8px;
  display: inline-block;
  border: 1px solid #fab1a0;
}

/* Styling für kulturelle Feiertage (nicht arbeitsfrei) */
.cultural-holiday {
  background-color: #fff8e1 !important;
  border-left: 4px solid #FF9800 !important;
}

.cultural-holiday-name {
  font-size: 0.85rem;
  font-weight: 500;
  color: #e65100;
  background-color: rgba(255, 243, 224, 0.9);
  padding: 2px 6px;
  border-radius: 4px;
  margin-top: -8px;
  margin-bottom: 8px;
  display: inline-block;
  border: 1px solid #ffcc80;
}

/* Dark Mode für kulturelle Feiertage */
[data-theme="dark"] .cultural-holiday {
  background-color: #3e2723 !important;
  border-left-color: #ffb74d !important;
}

[data-theme="dark"] .cultural-holiday-name {
  color: #ffcc80;
  background-color: rgba(62, 39, 35, 0.9);
  border-color: #8d6e63;
}

/* Root-Variablen für Theming */
:root {
  /* Light Mode (Default) Farben */
  --bg-color: #ffffff;
  --text-color: #333333;
  --header-bg: #f8f9fa;
  --primary-color: #4285F4;
  --secondary-color: #34A853;
  --border-color: #ddd;
  --card-bg: #ffffff;
  --modal-bg: #ffffff;
  --btn-bg: #f0f0f0;
  --btn-hover: #e0e0e0;
  --input-bg: #ffffff;
  --day-bg: #ffffff;
  --weekend-bg: #f8f9fa;
  --holiday-bg: #fff4f4;
  --hover-bg: #f5f5f5;
  --fulltime-bg: #e3f2fd;
  --parttime-bg: #e8f5e9;
  --lateshift-bg: #fff8e1;
  --vacation-color: #d32f2f;
  --vacation-bg: #ffebee;
  --shadow-color: rgba(0, 0, 0, 0.1);
  --notification-bg: rgba(255, 255, 255, 0.9);
}

/* Dark Mode Farben */
[data-theme="dark"] {
  --bg-color: #121212;
  --text-color: #e0e0e0;
  --header-bg: #1e1e1e;
  --primary-color: #64B5F6;
  --secondary-color: #4db6ac;
  --border-color: #444;
  --card-bg: #1e1e1e;
  --modal-bg: #1e1e1e;
  --btn-bg: #2a2a2a;
  --btn-hover: #3a3a3a;
  --input-bg: #2a2a2a;
  --day-bg: #1e1e1e;
  --weekend-bg: #2a2a2a;
  --holiday-bg: #3d2929;
  --hover-bg: #2a2a2a;
  --fulltime-bg: #0d3b66;
  --parttime-bg: #1b4332;
  --lateshift-bg: #4d3f00;
  --vacation-color: #ef9a9a;
  --vacation-bg: #3d2929;
  --shadow-color: rgba(0, 0, 0, 0.4);
  --notification-bg: rgba(30, 30, 30, 0.9);
}

/* Dark Mode Übergänge */
body {
  transition: background-color 0.3s ease, color 0.3s ease;
  background-color: var(--bg-color);
  color: var(--text-color);
}

/* Dark Mode-Anpassungen für allgemeine Elemente */
body, html {
  background-color: var(--bg-color);
  color: var(--text-color);
}

header {
  /*background-color: var(--header-bg);*/
  border-bottom: 1px solid var(--border-color);
}

/* Buttons und Interaktive Elemente */
button, .btn, input[type="submit"] {
  background-color: var(--btn-bg);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}

button:hover, .btn:hover, input[type="submit"]:hover {
  background-color: var(--btn-hover);
}

/* Input-Felder */
input, select, textarea {
  background-color: var(--input-bg);
  color: var(--text-color);
  border: 1px solid var(--border-color);
}

/* Dienstplan-Tage */
.day {
  background-color: var(--day-bg);
  color: var(--text-color);
  border: 1px solid var(--border-color);
  box-shadow: 0 2px 4px var(--shadow-color);
}

.day h3 {
  color: var(--text-color);
}

.day.weekend {
  background-color: var(--weekend-bg);
}

.day.holiday-day {
  background-color: var(--holiday-bg);
}

/* Schichtblöcke */
.shift-block {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
}

.shift-block.fulltime {
  background-color: var(--fulltime-bg);
}

.shift-block.parttime {
  background-color: var(--parttime-bg);
}

.shift-block.lateshift {
  background-color: var(--lateshift-bg);
}

/* Modals */
.modal-content {
  background-color: var(--modal-bg);
  color: var(--text-color);
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 8px var(--shadow-color);
}

.modal-header {
  border-bottom: 1px solid var(--border-color);
}

.modal-footer {
  border-top: 1px solid var(--border-color);
}

/* Tabellen */
table {
  border-color: var(--border-color);
}

table th {
  background-color: var(--header-bg);
  color: var(--text-color);
}

table td {
  border-color: var(--border-color);
}

/* Feiertagslabel im Dark Mode */
[data-theme="dark"] .holiday-name {
  background-color: rgba(61, 41, 41, 0.8);
  color: #ef9a9a;
  border-color: #b71c1c;
}

/* Notifikationen */
.notification {
  background-color: var(--notification-bg);
  color: var(--text-color);
  box-shadow: 0 2px 8px var(--shadow-color);
}

.notification.success {
  border-left: 4px solid var(--secondary-color);
}

.notification.error {
  border-left: 4px solid var(--vacation-color);
}

.notification.info {
  border-left: 4px solid var(--primary-color);
}

/* Theme-Schalter */
.theme-switcher {
  display: flex;
  align-items: center;
  margin-left: auto;
  margin-right: 15px;
}

.theme-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}

.theme-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 24px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #2196F3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.theme-icon {
  margin: 0 5px;
  font-size: 16px;
}

/* Rest des bestehenden CSS... */

/* Theme-Schalter - verbesserte Version */
.theme-setting {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 15px;
  margin-bottom: 10px;
  background-color: var(--card-bg);
  border-radius: 4px;
  border: 1px solid var(--border-color);
  position: relative;
  z-index: 1;
}

.theme-label {
  font-weight: bold;
  user-select: none;
}

.theme-switcher {
  display: flex;
  align-items: center;
  margin-left: auto;
  margin-right: 15px;
  z-index: 10;
}

.theme-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
  z-index: 15;
}

.theme-switch input {
  opacity: 0;
  width: 100%;
  height: 100%;
  position: absolute;
  z-index: 20;
  cursor: pointer;
  margin: 0;
  left: 0;
  top: 0;
}

.slider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 24px;
  z-index: 5;
  cursor: pointer;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
  z-index: 6;
}

input:checked + .slider {
  background-color: #2196F3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.theme-icon {
  margin: 0 5px;
  font-size: 16px;
}

/* Zusätzliches Debugging-CSS */
.theme-switch:hover .slider {
  box-shadow: 0 0 5px #2196F3;
}

/* CSS Theme-Variablen */
:root {
  --primary-color: #3498db;
  --primary-dark: #2980b9;
  --secondary-color: #2ecc71;
  --secondary-dark: #27ae60;
  --danger-color: #e74c3c;
  --danger-dark: #c0392b;
  --background-color: #f5f5f5;
  --text-color: #333;
  --card-bg: #fff;
  --border-color: #ddd;
  --overlay-bg: rgba(0, 0, 0, 0.5);
  --modal-bg: #fff;
  --input-bg: #fff;
  --input-border: #ddd;
  --input-focus: #3498db;
  --hover-bg: #f0f0f0;
  --header-bg: #fff;
  --sidebar-bg: #fff;
}

/* Dark Theme */
[data-theme="dark"] {
  --primary-color: #2ecc71;
  --primary-dark: #27ae60;
  --secondary-color: #3498db;
  --secondary-dark: #2980b9;
  --danger-color: #e74c3c;
  --danger-dark: #c0392b;
  --background-color: #121212; /* Dunkler Hintergrund für Dark Mode */
  --bg-color: #121212; /* Fehlende Definition hinzugefügt */
  --text-color: #eee;
  --card-bg: #1e1e1e;
  --border-color: #444;
  --overlay-bg: rgba(0, 0, 0, 0.7);
  --modal-bg: #2d2d2d;
  --input-bg: #2d2d2d;
  --input-border: #555;
  --input-focus: #2ecc71;
  --hover-bg: #2a2a2a;
  --header-bg: #1e1e1e;
  --sidebar-bg: #1e1e1e;
  --table-bg: #1e1e1e;
  --table-header-bg: #2d2d2d;
  --table-alt-row: #252525;
  --day-bg: #1e1e1e;
  --outside-month-bg: #181818;
  --weekend-bg: #252525;
  --holiday-bg: #2d2d2d;
  --shift-block-bg: #2d2d2d;
  --schedule-bg: #121212;
  --notification-bg: #333;
  --dropdown-bg: #2d2d2d;
  --dropdown-hover: #3a3a3a;
  --tooltip-bg: #3a3a3a;
}

/* Grundelemente im Dark Mode */
[data-theme="dark"] body,
[data-theme="dark"] html { /* HTML hinzugefügt */
  background-color: var(--bg-color) !important; /* !important hinzugefügt */
  color: var(--text-color);
}

[data-theme="dark"] header {
  background-color: #1e1e1e87;
  border-bottom: 1px solid var(--border-color);
  backdrop-filter: blur(4px);
}

[data-theme="dark"] .dienstplan {
  background-color: var(--schedule-bg);
}

/* Tagesansicht und Wochenüberschriften */
[data-theme="dark"] .weekday-header {
  background-color: var(--table-header-bg);
  color: var(--text-color);
  border-color: var(--border-color);
}

[data-theme="dark"] .day {
  background-color: var(--day-bg);
  border-color: var(--border-color);
}

[data-theme="dark"] .day.outside-month {
  background-color: var(--outside-month-bg);
}

[data-theme="dark"] .day.weekend,
[data-theme="dark"] .weekday-header.weekend {
  background-color: var(--weekend-bg);
}

[data-theme="dark"] .day.holiday-day,
[data-theme="dark"] .day.has-holiday {
  background-color: var(--holiday-bg);
}

/* Schichtblöcke */
[data-theme="dark"] .shift-block {
  background-color: var(--shift-block-bg);
  border-color: var(--border-color);
}

[data-theme="dark"] .shift-block.lateshift {
  border-left: 4px solid #3498db;
}

[data-theme="dark"] .shift-block.fulltime {
  border-left: 4px solid #2ecc71;
}

[data-theme="dark"] .shift-block.parttime {
  border-left: 4px solid #f39c12;
}

/* Tabellen */
[data-theme="dark"] table {
  background-color: var(--table-bg);
  border-color: var(--border-color);
}

[data-theme="dark"] th {
  background-color: var(--table-header-bg);
  color: var(--text-color);
  border-color: var(--border-color);
}

[data-theme="dark"] td {
  border-color: var(--border-color);
}

[data-theme="dark"] tr:nth-child(even) {
  background-color: var(--table-alt-row);
}

/* Formulare und Eingabefelder */
[data-theme="dark"] input,
[data-theme="dark"] select,
[data-theme="dark"] textarea {
  background-color: var(--input-bg);
  color: var(--text-color);
  border-color: var(--input-border);
}

[data-theme="dark"] input:focus,
[data-theme="dark"] select:focus,
[data-theme="dark"] textarea:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 5px rgba(46, 204, 113, 0.5);
}

/* Buttons und Interaktionen */
[data-theme="dark"] button,
[data-theme="dark"] .btn {
  background-color: var(--card-bg);
  color: var(--text-color);
  border-color: var(--border-color);
}

[data-theme="dark"] button:hover,
[data-theme="dark"] .btn:hover {
  background-color: var(--hover-bg);
}

[data-theme="dark"] .month-picker-button {
  background-color: var(--card-bg);
  color: var(--text-color);
  border-color: var(--border-color);
}

[data-theme="dark"] .month-picker-button:hover {
  background-color: var(--hover-bg);
}

[data-theme="dark"] .month-picker-button.active_month {
  background-color: var(--primary-color);
  color: #fff;
}

/* Status-Anzeigen und Badges */
[data-theme="dark"] .status-badge {
  background-color: var(--card-bg);
  border-color: var(--border-color);
}

[data-theme="dark"] .status-badge.lateshift {
  background-color: rgba(52, 152, 219, 0.2);
}

[data-theme="dark"] .status-badge.fulltime {
  background-color: rgba(46, 204, 113, 0.2);
}

[data-theme="dark"] .status-badge.parttime {
  background-color: rgba(243, 156, 18, 0.2);
}

/* Dropdown-Menüs */
[data-theme="dark"] select option {
  background-color: var(--dropdown-bg);
  color: var(--text-color);
}

[data-theme="dark"] select option:hover,
[data-theme="dark"] select option:focus {
  background-color: var(--dropdown-hover);
}

/* Tooltips */
[data-theme="dark"] [data-tooltip]:hover::after {
  background-color: var(--tooltip-bg);
  color: var(--text-color);
  border-color: var(--border-color);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

/* Benachrichtigungen */
[data-theme="dark"] .notification {
  background-color: var(--notification-bg);
  color: var(--text-color);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Urlaubs- und Feiertagsanzeigen */
[data-theme="dark"] .holiday-title,
[data-theme="dark"] .holiday-name {
  color: #e74c3c;
}

[data-theme="dark"] .hat_urlaub {
  background-color: rgba(46, 204, 113, 0.15);
}

[data-theme="dark"] .hat_urlaub .urlaub-badge {
  background-color: rgba(46, 204, 113, 0.3);
  color: #eee;
}

/* Monatspicker und Navigation */
[data-theme="dark"] #month-picker {
 /* background-color: var(--card-bg);*/
  border-color: var(--border-color);
}

/* Modals und Popups */
[data-theme="dark"] .modal-content {
  background-color: var(--modal-bg);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .modal-header,
[data-theme="dark"] .modal-footer {
  border-color: var(--border-color);
}

/* Ein dünner Scrollbar für bessere Lesbarkeit im Dark Mode */
[data-theme="dark"] ::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

[data-theme="dark"] ::-webkit-scrollbar-track {
  background: #1a1a1a;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: #444;
  border-radius: 5px;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* Weitere Dark Mode Anpassungen für fehlende Elemente */

/* Monatspicker-Buttons */
[data-theme="dark"] .month-picker-button,
[data-theme="dark"] #month-picker button {
  background-color: #2d2d2d;
  color: #eee;
  border-color: #444;
}

[data-theme="dark"] .month-picker-button:hover,
[data-theme="dark"] #month-picker button:hover {
  background-color: #3a3a3a;
}

[data-theme="dark"] .month-picker-button.active_month,
[data-theme="dark"] #month-picker button.active_month,
[data-theme="dark"] #month-picker button.active {
  background-color: var(--primary-color);
  color: #fff;
  border-color: var(--primary-dark);
}

/* Mitarbeiterblöcke und Schichtblöcke */
[data-theme="dark"] .shift-block p,
[data-theme="dark"] .shift-block h4 {
  color: #eee;
}

[data-theme="dark"] .shift-block input,
[data-theme="dark"] .shift-block select {
  background-color: #333;
  color: #eee;
  border-color: #555;
}

/* Grüne Mitarbeiterblöcke in der Dienstplanliste */
[data-theme="dark"] input[type="text"][value],
[data-theme="dark"] .shift-block input[type="text"] {
  background-color: #2d2d2d;
  color: #eee;
  border-color: #444;
}

/* Überschriften */
[data-theme="dark"] h1, 
[data-theme="dark"] h2, 
[data-theme="dark"] h3, 
[data-theme="dark"] h4 {
  color: #eee;
}

[data-theme="dark"] .urlaubsübersicht,
[data-theme="dark"] .präsenz,
[data-theme="dark"] .hinweis {
  color: #eee;
  background-color: #1e1e1e;
  border-color: #444;
}

/* Footer */
[data-theme="dark"] footer {
  background-color: #1e1e1e;
  color: #eee;
  border-top: 1px solid #444;
}

/* Export und Backup Buttons */
[data-theme="dark"] .export-button,
[data-theme="dark"] .button-group button {
  background-color: #2d2d2d;
  color: #eee;
  border-color: #444;
}

[data-theme="dark"] .export-button:hover,
[data-theme="dark"] .button-group button:hover {
  background-color: #3a3a3a;
}

[data-theme="dark"] .export-button.primary {
  background-color: rgba(46, 204, 113, 0.2);
  border-color: #2ecc71;
}

[data-theme="dark"] .export-button.primary:hover {
  background-color: rgba(46, 204, 113, 0.3);
}

[data-theme="dark"] .export-button.secondary {
  background-color: rgba(52, 152, 219, 0.2);
  border-color: #3498db;
}

[data-theme="dark"] .export-button.secondary:hover {
  background-color: rgba(52, 152, 219, 0.3);
}

/* Header und Navigation */
[data-theme="dark"] header {
  /*background-color: #1e1e1e;*/
  border-bottom: 1px solid #444;
}

[data-theme="dark"] .controls {
  background-color: #1e1e1e;
  border-color: #444;
}

[data-theme="dark"] .year-tab {
  background-color: #2d2d2d;
  color: #e0e0e0;
  border-color: #555;
}

[data-theme="dark"] .year-tab:hover {
  background-color: #3d3d3d;
  border-color: #777;
}

[data-theme="dark"] .year-tab.active {
  background-color: #007bff;
  color: white;
  border-color: #007bff;
}

[data-theme="dark"] .year-tab.active:hover {
  background-color: #0056b3;
  border-color: #0056b3;
}

/* Dark Mode Jahr-spezifische Farben für aktive Tabs */
[data-theme="dark"] .year-tab[data-year="2024"].active {
  background-color: #007bff; /* Blau */
  border-color: #007bff;
}

[data-theme="dark"] .year-tab[data-year="2024"].active:hover {
  background-color: #0056b3;
  border-color: #0056b3;
}

[data-theme="dark"] .year-tab[data-year="2025"].active {
  background-color: #28a745; /* Grün */
  border-color: #28a745;
}

[data-theme="dark"] .year-tab[data-year="2025"].active:hover {
  background-color: #1e7e34;
  border-color: #1e7e34;
}

[data-theme="dark"] .year-tab[data-year="2026"].active {
  background-color: #fd7e14; /* Orange */
  border-color: #fd7e14;
}

[data-theme="dark"] .year-tab[data-year="2026"].active:hover {
  background-color: #e55100;
  border-color: #e55100;
}

[data-theme="dark"] .year-tab[data-year="2027"].active {
  background-color: #6f42c1; /* Lila */
  border-color: #6f42c1;
}

[data-theme="dark"] .year-tab[data-year="2027"].active:hover {
  background-color: #5a2d91;
  border-color: #5a2d91;
}

[data-theme="dark"] .year-tab[data-year="2028"].active {
  background-color: #0f766e;
  border-color: #0f766e;
}

[data-theme="dark"] .year-tab[data-year="2028"].active:hover {
  background-color: #115e59;
  border-color: #115e59;
}

[data-theme="dark"] .year-tab[data-year="2029"].active {
  background-color: #be185d;
  border-color: #be185d;
}

[data-theme="dark"] .year-tab[data-year="2029"].active:hover {
  background-color: #9d174d;
  border-color: #9d174d;
}

[data-theme="dark"] .ist_schule {
  opacity: 0.6 !important;
  background-color: #1a237e !important;
  border-left: 3px solid #2196F3 !important;
}

[data-theme="dark"] .schule-badge {
  background-color: #2196F3;
  color: white;
}

[data-theme="dark"] .btn-edit-school-days {
  background-color: #2196F3;
  color: white;
}

[data-theme="dark"] .btn-edit-school-days:hover {
  background-color: #1976D2;
}

[data-theme="dark"] .school-days li {
  color: #64B5F6;
}

/* Dark Mode für Urlaubswünsche (Orange) */
[data-theme="dark"] .vacation-request {
  background-color: #664300 !important;
  border-left: 3px solid #ff9800 !important;
  color: #ffcc80 !important;
}

[data-theme="dark"] .vacation-request .vacation-actions .btn-approve {
  background-color: #4caf50;
  color: white;
}

[data-theme="dark"] .vacation-request .vacation-actions .btn-approve:hover {
  background-color: #45a049;
}

/* Dark Mode für genehmigten Urlaub (Grün) */
[data-theme="dark"] .vacation-approved {
  background-color: #1b5e20 !important;
  border-left: 3px solid #4caf50 !important;
  color: #a5d6a7 !important;
}

[data-theme="dark"] .vacation-approved .vacation-actions .btn-remove {
  background-color: #f44336;
  color: white;
}

[data-theme="dark"] .vacation-approved .vacation-actions .btn-remove:hover {
  background-color: #e53935;
}

/* Dark Mode für Schultage in der Urlaubsliste */
[data-theme="dark"] .vacation-list .school-day {
  color: #64B5F6;  /* Hellblau für Schultage im Dark Mode */
  font-style: italic;
}

/* Mitarbeiterliste */
[data-theme="dark"] .employee-management {
  background-color: #1e1e1e;
  border-color: #444;
}

[data-theme="dark"] .accordion {
  background-color: #2d2d2d;
  color: #eee;
  border-color: #444;
}

[data-theme="dark"] .accordion:hover,
[data-theme="dark"] .accordion.active {
  background-color: #3a3a3a;
}

[data-theme="dark"] .panel {
  background-color: #1e1e1e;
  border-color: #444;
}

/* Grüne Namensblöcke in der Urlaubsübersicht */
[data-theme="dark"] .verbleibend {
  color: #eee;
}

[data-theme="dark"] .employee-stats-card {
  background-color: #2d2d2d;
  border-color: #444;
  color: #eee;
}

[data-theme="dark"] .employee-stats-card:hover {
  background-color: #3a3a3a;
}

/* Spezifische UI-Elemente im Dark Mode */
[data-theme="dark"] .generate_custom,
[data-theme="dark"] #generate {
  background-color: var(--primary-color);
  color: #fff;
  border-color: var(--primary-dark);
}

[data-theme="dark"] .generate_custom:hover,
[data-theme="dark"] #generate:hover {
  background-color: var(--primary-dark);
}

/* Datum und Tagesüberschriften */
[data-theme="dark"] .day h3,
[data-theme="dark"] .weekday-header {
  color: #eee;
}

/* Feiertags-Elemente */
[data-theme="dark"] .feiertag {
  background-color: rgba(231, 76, 60, 0.2);
  color: #eee;
}

[data-theme="dark"] .feiertag-badge {
  background-color: rgba(231, 76, 60, 0.3);
  color: #eee;
}

/* NW-Badges für Spätschicht */
[data-theme="dark"] .nw,
[data-theme="dark"] .nw-badge {
  background-color: rgba(52, 152, 219, 0.3);
  color: #eee;
}

/* Spezifische Anpassungen für grüne und blaue Mitarbeiterblöcke im Dark Mode */

/* Grüne Blöcke (oberer Bereich) */
[data-theme="dark"] .shift-block input[value^="Celine"],
[data-theme="dark"] .shift-block input[value^="Jörg"],
[data-theme="dark"] .shift-block input[value^="Roman"],
[data-theme="dark"] .shift-block input[value^="Helmut"],
[data-theme="dark"] .shift-block input[value^="Jeanette"],
[data-theme="dark"] .shift-block input[value^="nicht zugewiesen"] {
  background-color: rgba(46, 204, 113, 0.2) !important; /* Dunkleres Grün mit Transparenz */
  color: #eee !important;
  border-color: rgba(46, 204, 113, 0.4) !important;
}

/* Blaue Blöcke (unterer Bereich) */
[data-theme="dark"] .shift-block input[value^="Bernd"],
[data-theme="dark"] .shift-block input[value^="Isabelle"] {
  background-color: rgba(52, 152, 219, 0.2) !important; /* Dunkleres Blau mit Transparenz */
  color: #eee !important;
  border-color: rgba(52, 152, 219, 0.4) !important;
}

/* Hinweis Geschlossen-Blöcke */
[data-theme="dark"] .shift-block input[value^="(Hinweis)"] {
  background-color: rgba(243, 156, 18, 0.2) !important; /* Orange mit Transparenz */
  color: #eee !important;
  border-color: rgba(243, 156, 18, 0.4) !important;
}

/* Feiertags-Blöcke */
[data-theme="dark"] .day .feiertag {
  background-color: rgba(231, 76, 60, 0.15) !important; 
  color: #eee !important;
}

/* Die "Verbleibend: XX" Anzeigen */
[data-theme="dark"] span[class^="verbleibend"],
[data-theme="dark"] .verbleibend {
  color: #aaa !important;
}

/* Urlaubsübersicht und Präsenz-Überschriften */
[data-theme="dark"] #aktueller-dienstplan,
[data-theme="dark"] .urlaubsübersicht,
[data-theme="dark"] #urlaubsubersicht {
  background-color: #1a1a1a;
  color: #eee;
  border-bottom: 1px solid #444;
  padding: 10px;
}

/* Die großen grünen Blöcke in der Urlaubsübersicht */
[data-theme="dark"] .employee-stats-card,
[data-theme="dark"] [class*="lang"] {
  background-color: rgba(46, 204, 113, 0.15) !important;
  border-color: rgba(46, 204, 113, 0.3) !important;
  color: #eee !important;
}

/* Die blauen Info-Blöcke */
[data-theme="dark"] .hinweis,
[data-theme="dark"] [class*="isabelle"] {
  background-color: rgba(52, 152, 219, 0.15) !important;
  border-color: rgba(52, 152, 219, 0.3) !important;
  color: #eee !important;
}

/* Allgemeine Textfarbe für besseren Kontrast */
[data-theme="dark"] * {
  color-scheme: dark;
}

/* Die NW-Badges in Spätschicht-Zeilen */
[data-theme="dark"] .nw {
  background-color: rgba(52, 152, 219, 0.3);
  color: #eee;
  border-radius: 4px;
  padding: 2px 4px;
}

/* Generell alle Blöcke mit Mitarbeiternamen */
[data-theme="dark"] input[type="text"][value]:not([value=""]) {
  background-color: rgba(46, 204, 113, 0.15);
  color: #eee;
  border-color: rgba(46, 204, 113, 0.3);
}

/* Inline Theme Switch in der Navigation */
.inline-theme-switch {
  display: inline-flex;
  align-items: center;
  margin-left: 15px;
  margin-right: 5px;
}

.inline-theme-switch .theme-switch {
  width: 40px;
  height: 20px;
}

.inline-theme-switch .slider {
  border-radius: 20px;
}

.inline-theme-switch .slider:before {
  height: 14px;
  width: 14px;
  left: 3px;
  bottom: 3px;
}

.inline-theme-switch input:checked + .slider:before {
  transform: translateX(20px);
}

/* Verhindert, dass der Switch die Layout-Breite verändert */
@media (max-width: 768px) {
  .inline-theme-switch {
    position: absolute;
    top: 15px;
    right: 15px;
  }
  
  [data-theme="dark"] .inline-theme-switch .slider {
    background-color: #555;
  }
  
  [data-theme="dark"] .inline-theme-switch input:checked + .slider {
    background-color: var(--primary-color);
  }
}

/* Icon für Day/Night Mode */
.inline-theme-switch .slider:before {
  content: "";
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: #333;
  border: 1.5px solid currentColor;
  background: transparent;
}

.inline-theme-switch input:checked + .slider:before {
  content: "";
  color: #eee;
  box-shadow: inset -3px 0 0 currentColor;
}

/* Kalenderblatt und Schichteinträge im Dark Mode */

/* Grundfarbe für das gesamte Kalenderblatt */
[data-theme="dark"] #schedule,
[data-theme="dark"] .dienstplan {
  background-color: #121212;
  color: #eee;
}

/* Einzelne Namenseinträge in Schichtblöcken */
[data-theme="dark"] input[type="text"],
[data-theme="dark"] .shift-block input[type="text"],
[data-theme="dark"] .präsenz input[type="text"],
[data-theme="dark"] .counter input[type="text"] {
  background-color: rgba(30, 30, 30, 0.8);
  color: #eee;
  border-color: #444;
}

/* Spezifische Selektoren für die Namenseinträge */
[data-theme="dark"] .präsenz input,
[data-theme="dark"] .counter input {
  background-color: rgba(30, 30, 30, 0.8) !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Präsenz und Counter Überschriften */
[data-theme="dark"] .präsenz,
[data-theme="dark"] .counter {
  color: #eee;
}

/* Spezielles Styling für grüne Präsenz-Blöcke */
[data-theme="dark"] div[class*="präsenz"] {
  background-color: rgba(46, 204, 113, 0.2);
  border-color: rgba(46, 204, 113, 0.4);
}

/* Spezielles Styling für braune Counter-Blöcke */
[data-theme="dark"] div[class*="counter"] {
  background-color: rgba(160, 120, 80, 0.2);
  border-color: rgba(160, 120, 80, 0.4);
}

/* Allgemeine Tag-Hintergrundfarbe */
[data-theme="dark"] .day,
[data-theme="dark"] div[class*="tag"] {
  background-color: #1a1a1a;
  border-color: #444;
}

/* Explizitere Selektoren für alle möglichen Eingabefeldern */
[data-theme="dark"] input:not([type="checkbox"]):not([type="radio"]),
[data-theme="dark"] select,
[data-theme="dark"] textarea {
  background-color: rgba(30, 30, 30, 0.8);
  color: #eee;
  border-color: #444;
}

/* Text-Hervorhebung im Dark Mode */
[data-theme="dark"] *::selection {
  background-color: rgba(46, 204, 113, 0.6);
  color: #fff;
}

/* Spezifische Anpassung für die Textfelder in den Schichten */
[data-theme="dark"] .präsenz:has(input),
[data-theme="dark"] .counter:has(input) {
  background-color: transparent;
}

/* Speziell für die NW-Badges in den Eingabefeldern */
[data-theme="dark"] input[type="text"] .nw,
[data-theme="dark"] .nw-badge {
  background-color: rgba(52, 152, 219, 0.3);
  color: #eee;
}

/* Höchste Spezifität für Eingabefelder im Dark Mode */

/* Allgemeine Regel mit hoher Priorität */
[data-theme="dark"] input[type="text"] {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Lösung für das Problem mit einzelnen Namenseinträgen */
[data-theme="dark"] input.nw,
[data-theme="dark"] input[type="text"][value*="NW"],
[data-theme="dark"] input:not([class]),
[data-theme="dark"] input[value]:not([value=""]) {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Regel für alle Eingabefelder innerhalb des Dienstplans */
[data-theme="dark"] #schedule input,
[data-theme="dark"] .dienstplan input,
[data-theme="dark"] .day input {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Spezielle Styling für die Container der Eingabefelder */
[data-theme="dark"] .präsenz,
[data-theme="dark"] .counter,
[data-theme="dark"] [class^="präsenz"],
[data-theme="dark"] [class^="counter"] {
  background-color: transparent !important;
  color: #eee !important;
}

/* Stil für den Kalenderhintergrund und Tage */
[data-theme="dark"] #schedule,
[data-theme="dark"] .dienstplan,
[data-theme="dark"] .day,
[data-theme="dark"] .weekday-header {
  background-color: #1a1a1a !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Samstage und Sonntage */
[data-theme="dark"] .day.weekend,
[data-theme="dark"] .day.samstag,
[data-theme="dark"] .day.sonntag {
  background-color: #212121 !important;
}

/* Regeln für die Schicht-Container */
[data-theme="dark"] .präsenz,
[data-theme="dark"] .präsenz:has(input) {
  background-color: rgba(46, 204, 113, 0.15) !important;
  border-color: rgba(46, 204, 113, 0.3) !important;
}

[data-theme="dark"] .counter,
[data-theme="dark"] .counter:has(input) {
  background-color: rgba(160, 120, 80, 0.15) !important;
  border-color: rgba(160, 120, 80, 0.3) !important;
}

/* Spezielle Regel für die Monatsbuttons */
[data-theme="dark"] .month-picker-button,
[data-theme="dark"] button[class*="month"] {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

[data-theme="dark"] #month-picker button.active_month,
[data-theme="dark"] button.month-picker-button.active_month {
  background-color: var(--primary-color) !important;
  color: #fff !important;
  border-color: var(--primary-dark) !important;
  box-shadow: 0 0 0 2px rgba(46, 204, 113, 0.35) !important;
}

/* Weitere präzise Anpassungen für verbleibende helle Elemente */

/* Feiertage und Hinweis-Box */
[data-theme="dark"] .feiertag,
[data-theme="dark"] .hinweis,
[data-theme="dark"] [id^="hinweis"],
[data-theme="dark"] [class^="hinweis"],
[data-theme="dark"] div:has(.feiertag) {
  background-color: rgba(231, 76, 60, 0.2) !important;
  color: #eee !important;
  border-color: rgba(231, 76, 60, 0.4) !important;
}

/* Speziell für Feiertagszeilen */
[data-theme="dark"] .feiertag,
[data-theme="dark"] tr.feiertag td,
[data-theme="dark"] td.feiertag {
  background-color: rgba(231, 76, 60, 0.2) !important;
  color: #eee !important;
}

/* Fortschrittsbalken in der Mitarbeiterliste */
[data-theme="dark"] .progress-bar,
[data-theme="dark"] [class*="progress"],
[data-theme="dark"] [class*="fortschritt"] {
  background-color: #333 !important;
  border-color: #444 !important;
}

[data-theme="dark"] .progress,
[data-theme="dark"] .progress-fill,
[data-theme="dark"] [class*="fortschritt-fill"] {
  background-color: var(--primary-color) !important;
}

/* Spezifischere Regeln für Eingabefelder in Präsenz und Counter */
[data-theme="dark"] .präsenz input,
[data-theme="dark"] .counter input,
[data-theme="dark"] input[type="text"][value],
[data-theme="dark"] [class*="präsenz"] input,
[data-theme="dark"] [class*="counter"] input {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Noch spezifischere Selektoren für weiße Eingabefelder */
[data-theme="dark"] input[type="text"],
[data-theme="dark"] textarea,
[data-theme="dark"] select {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Regel für Tabellen in der Mitarbeiterliste */
[data-theme="dark"] table,
[data-theme="dark"] tr,
[data-theme="dark"] td,
[data-theme="dark"] th {
  background-color: #1a1a1a !important;
  color: #eee !important;
  border-color: #444 !important;
}

[data-theme="dark"] tr:nth-child(even) {
  background-color: #222 !important;
}

/* Eingabefelder, die dynamisch hinzugefügt werden könnten */
[data-theme="dark"] input:not([type="checkbox"]):not([type="radio"]),
[data-theme="dark"] input:not([class]),
[data-theme="dark"] input[type="text"] {
  background-color: #2d2d2d !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Spezifisch für Überschriften im Kalender */
[data-theme="dark"] .präsenz,
[data-theme="dark"] .hinweis,
[data-theme="dark"] .counter {
  color: #eee !important;
}

/* Dark Mode Anpassungen für die vom Nutzer genannten Elemente */

[data-theme="dark"] .export-section {
  background: #222;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .shift-block p {
  background-color: #333;
  color: #eee;
}

[data-theme="dark"] .vacation-info {
  background-color: #222;
  color: #eee;
  border-color: #444;
}

[data-theme="dark"] .employee-stats-container {
  border-color: #444;
  background-color: #1a1a1a;
}

/* Weitere Dark Mode Anpassungen für ähnliche Elemente */
[data-theme="dark"] [class*="export"],
[data-theme="dark"] [class*="vacation"],
[data-theme="dark"] [class*="employee"],
[data-theme="dark"] [class*="stats"] {
  background-color: #222 !important;
  color: #eee !important;
  border-color: #444 !important;
}

[data-theme="dark"] .export-buttons-container,
[data-theme="dark"] .export-button,
[data-theme="dark"] .button-group {
  background-color: transparent !important;
}

[data-theme="dark"] .stats-heading,
[data-theme="dark"] .card-section,
[data-theme="dark"] .card-name,
[data-theme="dark"] .shift-section,
[data-theme="dark"] .status {
  color: #eee !important;
  background-color: #1e1e1e !important;
  border-color: #444 !important;
}

/* Dark Mode Anpassungen für Modals und deren Inhalte */

/* Allgemeine Modal-Texte */
[data-theme="dark"] .modal,
[data-theme="dark"] .modal-content,
[data-theme="dark"] .modal-header,
[data-theme="dark"] .modal-body,
[data-theme="dark"] .modal-footer {
  color: #eee !important;
  background-color: #222 !important;
  border-color: #444 !important;
}

/* Textfarben in Modal-Elementen */
[data-theme="dark"] .modal h1,
[data-theme="dark"] .modal h2,
[data-theme="dark"] .modal h3,
[data-theme="dark"] .modal h4,
[data-theme="dark"] .modal p,
[data-theme="dark"] .modal label,
[data-theme="dark"] .modal span {
  color: #eee !important;
}

/* Formular-Elemente in Modals */
[data-theme="dark"] .modal input[type="text"],
[data-theme="dark"] .modal input[type="number"],
[data-theme="dark"] .modal input[type="email"],
[data-theme="dark"] .modal input[type="password"],
[data-theme="dark"] .modal select,
[data-theme="dark"] .modal textarea {
  background-color: #333 !important;
  color: #eee !important;
  border-color: #444 !important;
}

/* Dropdown-Menüs in Modals */
[data-theme="dark"] .modal option {
  background-color: #333 !important;
  color: #eee !important;
}

/* Checkboxen und Radiobuttons in Modals */
[data-theme="dark"] .modal input[type="checkbox"],
[data-theme="dark"] .modal input[type="radio"] {
  accent-color: var(--primary-color) !important;
}

/* Buttons in Modals */
[data-theme="dark"] .modal button,
[data-theme="dark"] .modal .btn {
  background-color: #333 !important;
  color: #eee !important;
  border-color: #444 !important;
}

[data-theme="dark"] .modal button:hover,
[data-theme="dark"] .modal .btn:hover {
  background-color: #444 !important;
}

/* Spezielle Buttons */
[data-theme="dark"] .modal button.btn-primary,
[data-theme="dark"] .modal .btn-primary {
  background-color: var(--primary-color) !important;
  color: #fff !important;
  border-color: var(--primary-dark) !important;
}

[data-theme="dark"] .modal button.btn-primary:hover,
[data-theme="dark"] .modal .btn-primary:hover {
  background-color: var(--primary-dark) !important;
}

/* Mitarbeiter bearbeiten Modal */
[data-theme="dark"] [class*="bearbeiten"],
[data-theme="dark"] [id*="bearbeiten"] {
  color: #eee !important;
  background-color: #222 !important;
}

/* Unververfügbare Tage Checkboxen */
[data-theme="dark"] .unavailable-days,
[data-theme="dark"] .unavailable-days label,
[data-theme="dark"] [class*="unavailable"],
[data-theme="dark"] [class*="verfuegbar"] {
  color: #eee !important;
}

/* Close-Button */
[data-theme="dark"] .close-modal,
[data-theme="dark"] .modal .close {
  color: #eee !important;
}

/* Styling für Wochenvorlagen-Editor - Direkte CSS Regeln */

@media screen {
  .ux-toolbar {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 6px 8px;
    border: 1px solid rgba(46, 125, 50, 0.28);
    border-radius: 8px;
    background: rgba(46, 125, 50, 0.08);
  }

  .ux-status {
    min-width: 150px;
    color: #315b34;
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
  }

  .ux-scroll-schedule,
  .ux-turnus-check-toggle,
  .ux-friday-turnus-check-toggle,
  .ux-compact-toggle {
    min-height: 34px;
    padding: 6px 10px;
    border: 1px solid rgba(46, 125, 50, 0.35);
    border-radius: 7px;
    background: #ffffff;
    color: #244f28;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  }

  .ux-scroll-schedule:hover,
  .ux-turnus-check-toggle:hover,
  .ux-friday-turnus-check-toggle:hover,
  .ux-compact-toggle:hover {
    transform: translateY(-1px);
    background: #f3fbf3;
    box-shadow: 0 3px 10px rgba(31, 74, 35, 0.12);
  }

  .ux-turnus-check-toggle[aria-pressed="true"],
  .ux-friday-turnus-check-toggle[aria-pressed="true"] {
    background: #e9f2ff;
    border-color: rgba(31, 110, 212, 0.42);
    color: #174f9d;
  }

  .ux-compact-view .schedule-month {
    gap: 0.24rem;
    grid-auto-rows: minmax(88px, auto);
  }

  .ux-compact-view .day {
    min-height: 104px;
    padding: 5px;
    border-radius: 6px;
    box-shadow: 0 3px 8px rgba(37, 49, 44, 0.08);
  }

  .ux-compact-view .day h3 {
    font-size: 0.78rem;
    margin-bottom: 3px;
    padding-bottom: 2px;
    border-bottom: 1px solid rgba(37, 49, 44, 0.12);
  }

  .ux-compact-view .shift-block {
    margin-bottom: 3px;
    padding: 3px 4px;
    border-left: 3px solid transparent;
    border-radius: 5px;
    box-shadow: none;
  }

  .ux-compact-view .shift-block.fulltime {
    border-left-color: #24864e;
  }

  .ux-compact-view .shift-block.lateshift {
    border-left-color: #bf8b18;
  }

  .ux-compact-view .shift-block.parttime {
    border-left-color: #25869a;
  }

  .ux-compact-view .shift-block h4 {
    margin: 0 0 2px;
    font-size: 0.68rem;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    opacity: 0.86;
  }

  .ux-compact-view .shift-block p {
    min-height: 0;
    padding: 1px 3px;
    margin: 1px 0;
    font-size: 0.72rem;
    line-height: 1.08;
    border-radius: 4px;
  }

  .ux-compact-view .day-checksum {
    font-size: 0.64em;
    letter-spacing: 0;
  }

  .ux-compact-view .shift-block p .employee-name-with-avatar {
    gap: 2px;
  }

  .ux-compact-view .shift-block p .employee-avatar {
    width: 10px;
    height: 10px;
    max-width: 10px;
    max-height: 10px;
    flex-basis: 10px;
  }

  [data-theme="dark"] .ux-toolbar {
    background: rgba(76, 175, 80, 0.1);
    border-color: rgba(129, 199, 132, 0.28);
  }

  [data-theme="dark"] .ux-status {
    color: #b8e2bc;
  }

  [data-theme="dark"] .ux-scroll-schedule,
  [data-theme="dark"] .ux-turnus-check-toggle,
  [data-theme="dark"] .ux-friday-turnus-check-toggle,
  [data-theme="dark"] .ux-compact-toggle {
    background: #1d2a1f;
    border-color: rgba(129, 199, 132, 0.3);
    color: #d6f0d8;
  }

  [data-theme="dark"] .ux-scroll-schedule:hover,
  [data-theme="dark"] .ux-turnus-check-toggle:hover,
  [data-theme="dark"] .ux-friday-turnus-check-toggle:hover,
  [data-theme="dark"] .ux-compact-toggle:hover {
    background: #253a28;
  }

  [data-theme="dark"] .ux-turnus-check-toggle[aria-pressed="true"],
  [data-theme="dark"] .ux-friday-turnus-check-toggle[aria-pressed="true"] {
    background: rgba(71, 127, 196, 0.18);
    border-color: rgba(138, 184, 255, 0.45);
    color: #cfe3ff;
  }

  [data-theme="dark"] .ux-compact-view .day h3 {
    border-bottom-color: rgba(237, 246, 241, 0.14);
  }
}

@media print {
  .ux-toolbar {
    display: none !important;
  }
}

@media screen {
  .notification {
    top: 16px;
    right: 16px;
    bottom: auto;
    left: auto;
    width: min(420px, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    max-height: 20vh;
    min-height: 0;
    padding: 10px 14px;
    box-sizing: border-box;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 8px;
    overflow: auto;
    border-radius: 8px;
    line-height: 1.35;
    font-size: 0.92rem;
  }

  .notification.success {
    background-color: var(--color-success);
    color: #fff;
  }

  .notification.error {
    background-color: var(--color-danger);
    color: #fff;
  }

  .notification.warning {
    background-color: var(--color-warning);
    color: #1f2933;
  }

  .notification.info {
    background-color: var(--color-info);
    color: #fff;
  }
}

#weeklyTemplateModal .counter-tonus-notice {
  margin: 0 0 14px 0;
  padding: 10px 12px;
  background: #fff8e6;
  border: 1px solid #f0d58a;
  border-left: 4px solid #f0ad4e;
  border-radius: 6px;
  color: #5f4b17;
  line-height: 1.45;
}

#weeklyTemplateModal .counter-tonus-notice strong {
  margin-right: 4px;
}

[data-theme="dark"] #weeklyTemplateModal .counter-tonus-notice {
  background: #34280f;
  border-color: #755b1c;
  border-left-color: #f0ad4e;
  color: #f5d889;
}

#weeklyTemplateModal .tab button.tablinks {
  flex: 1;
  background-color: var(--btn-bg, #e6e6e6);
  border: none;
  border-bottom: 1px solid var(--border-color, #ccc);
  outline: none;
  cursor: pointer;
  padding: 10px 12px;
  transition: 0.3s;
  font-weight: bold;
  font-size: 14px;
  margin: 0;
  border-right: 1px solid var(--border-color, #ccc);
  color: var(--text-color, #333);
}

#weeklyTemplateModal .tab button.tablinks:last-child {
  border-right: none;
}

#weeklyTemplateModal .tab button.tablinks:hover {
  background-color: var(--hover-bg, #ddd);
}

/* --- ACTIVE TAB STYLING --- */
#weeklyTemplateModal .tab button.tablinks.active {
  background-color: var(--card-bg, white); /* Hintergrund wie Inhaltsbereich */
  color: var(--primary-color, #007bff); /* Primärfarbe für Text */
  border-bottom: 1px solid transparent; /* Unteren Rand entfernen */
  position: relative;
  top: 1px; /* Leicht nach oben verschieben */
}

/* Dark Mode Anpassungen für aktive Tabs */
[data-theme="dark"] #weeklyTemplateModal .tab button.tablinks {
    background-color: var(--btn-bg, #2a2a2a);
    color: var(--text-color, #eee);
    border-right-color: var(--border-color, #444);
    border-bottom-color: var(--border-color, #444);
}

[data-theme="dark"] #weeklyTemplateModal .tab button.tablinks:hover {
    background-color: var(--hover-bg, #3a3a3a);
}

[data-theme="dark"] #weeklyTemplateModal .tab button.tablinks.active {
    background-color: var(--card-bg, #1e1e1e); /* Hintergrund wie Inhaltsbereich */
    color: var(--primary-color, #64B5F6); /* Primärfarbe für Text */
    border-bottom-color: transparent; /* Unteren Rand entfernen */
}

/* Globale Mindestbreite für alle Modals */
.modal-content {
  width: 1440px; /* Gewünschte Breite */
  max-width: 95vw; /* Maximal 95% der Viewport-Breite, um Überlaufen zu verhindern */
  /* Bestehende max-height und overflow-y beibehalten */
  max-height: 90vh;
  overflow-y: auto;
  /* Zentrierung sicherstellen */
  margin: 5vh auto; 
}

/* Spezifische Anpassungen für Dark Mode, falls nötig */
[data-theme="dark"] .modal-content {
  /* Dark Mode spezifische Stile können hierhin, falls abweichend */
}

/* Globale Mindestbreite für alle Modals - Versuch mit erhöhter Spezifität */
body .modal .modal-content {
  width: 1440px !important; /* Gewünschte Breite mit !important */
  max-width: 95vw !important; /* Maximal 95% der Viewport-Breite, um Überlaufen zu verhindern */
  /* Bestehende max-height und overflow-y beibehalten */
  max-height: 90vh;
  overflow-y: auto;
  /* Zentrierung sicherstellen */
  margin: 5vh auto !important; 
}

body .modal.schedule-edit .modal-content {
  width: min(1720px, 99vw) !important;
  max-width: 99vw !important;
}

body .modal.employee-management-modal .employee-management-modal-content {
  width: min(1180px, calc(100vw - 24px)) !important;
  max-width: calc(100vw - 24px) !important;
  height: min(900px, calc(100vh - 24px));
  max-height: calc(100vh - 24px) !important;
  margin: 12px auto !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  animation: none;
  transform: none !important;
  overflow: hidden;
}

body .modal.employee-management-modal {
  animation: none;
  transform: none !important;
}

.employee-management-modal .modal-header {
  flex: 0 0 auto;
  margin: 0;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border-soft, #d8dee4);
}

.employee-management-modal .modal-header h3 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.employee-management-modal .employee-management-modal-close {
  border: 0;
  background: transparent;
  color: inherit;
  line-height: 1;
}

.employee-management-modal-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 16px 18px 18px;
}

.employee-management-modal .employee-management {
  margin: 0;
  scroll-margin-top: 0;
}

.employee-management-modal #employeesTable {
  margin-bottom: 0;
}

body .modal.schedule-edit .modal-body {
  margin-top: 14px;
}

.schedule-edit-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.schedule-edit-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.schedule-edit-panel {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--border-soft, #dde5df);
  border-radius: var(--ui-radius, 8px);
  background: color-mix(in srgb, var(--surface-muted, #f6f8f7) 72%, #fff);
}

.schedule-edit-panel-title {
  margin: 0 0 10px;
  color: #25312c;
  font-size: 0.92rem;
  font-weight: 750;
}

.schedule-edit-shift-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.schedule-edit .form-group {
  min-width: 0;
  margin-bottom: 0;
}

.schedule-edit .shift-select {
  width: 100%;
  min-height: 38px;
}

.schedule-edit-panel--details .vacation-section,
.schedule-edit-panel--details .closed-from-section,
.schedule-edit-panel--details .note-section,
.schedule-edit-panel--template .template-section {
  margin: 0;
}

.schedule-edit-panel--details {
  display: grid;
  gap: 10px;
  align-content: start;
}

.schedule-edit-note {
  width: 100%;
  min-height: 96px;
  padding: 8px;
  box-sizing: border-box;
  resize: vertical;
}

.schedule-edit-panel--template {
  grid-column: 1 / -1;
}

@media (min-width: 1100px) {
  .schedule-edit-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.65fr);
    align-items: start;
  }

  .schedule-edit-shift-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(210px, 1fr));
    align-items: start;
  }

  .schedule-edit-panel--template .template-section {
    display: grid;
    grid-template-columns: minmax(210px, 0.8fr) minmax(250px, 1fr) minmax(320px, 1fr) auto;
    gap: 12px;
    align-items: end;
  }

  .schedule-edit-panel--template .template-section h4 {
    grid-column: 1 / -1;
    margin-bottom: 0;
  }

  .schedule-edit-panel--template .template-options,
  .schedule-edit-panel--template .template-fields,
  .schedule-edit-panel--template .template-shifts,
  .schedule-edit-panel--template .template-weekdays {
    margin-bottom: 0;
  }
}

@media (min-width: 1400px) {
  .schedule-edit-panel {
    padding: 14px;
  }

  .schedule-edit-shift-grid {
    gap: 12px;
  }
}

[data-theme="dark"] .schedule-edit-panel {
  background: color-mix(in srgb, var(--surface-muted, #232b28) 82%, #000);
  border-color: var(--border-soft, #3a4841);
}

[data-theme="dark"] .schedule-edit-panel-title {
  color: #e5eee8;
}

/* Spezifische Anpassungen für Dark Mode, falls nötig */
[data-theme="dark"] body .modal .modal-content {
  /* Dark Mode spezifische Stile können hierhin, falls abweichend */
}

/* Kontrast für Icons/Text in roten Buttons verbessern */
.btn-delete,
.btn-remove,
.btn-danger {
  /* Bestehende Styles bleiben erhalten */
  color: white !important; /* Text/Icon Farbe auf Weiß setzen */
}

/* Sicherstellen, dass auch spezifischere Icon-Elemente weiß sind */
.btn-delete *,
.btn-remove *,
.btn-danger * {
   color: white !important; 
}

/* Notiz-Anzeige im Tag */
.day-closed-from {
  font-size: 0.85em;
  font-weight: 600;
  color: #7a4b00;
  margin-top: 8px;
  padding: 5px 7px;
  background-color: #fff3cd;
  border-radius: 4px;
  border: 1px solid #f0c36a;
  white-space: normal;
  word-break: break-word;
}

.day-note {
  font-size: 0.85em;
  color: #666;
  margin-top: 8px;
  padding: 5px;
  background-color: #f9f9f9;
  border-radius: 4px;
  border: 1px solid #eee;
  cursor: pointer;
  min-height: 20px; /* Mindesthöhe, um Klickbarkeit zu gewährleisten */
  white-space: pre-wrap; /* Zeilenumbrüche und Leerzeichen beibehalten, umbrechen bei Bedarf */
  word-break: break-word; /* Lange Wörter umbrechen */
  transition: background-color 0.2s;
}

.day-note.hidden {
  opacity: 0.6;
  font-style: italic;
}

.day-note:hover {
  background-color: #efefef;
}

/* Dark Mode Anpassung für Notizen */
[data-theme="dark"] .day-closed-from {
  color: #ffdd88;
  background-color: #4a3512;
  border-color: #8a681f;
}

[data-theme="dark"] .day-note {
  color: #bbb;
  background-color: #2a2a2a;
  border-color: #444;
}

[data-theme="dark"] .day-note:hover {
  background-color: #3a3a3a;
}

/* Anpassungen für die Urlaubsübersicht unter dem Kalender */
.employee-stats-card {
    margin-bottom: 1rem; /* Fügt Abstand unter jeder Mitarbeiterkarte hinzu */
}

.monthly-vacation-list {
    padding-left: 20px;  /* Rückt die Liste ein */
    list-style-type: disc; /* Stellt sicher, dass Aufzählungspunkte verwendet werden */
    margin-top: 0.5rem; /* Kleiner Abstand über der Liste */
}

.monthly-vacation-list li {
    margin-bottom: 0.25rem; /* Kleiner Abstand zwischen Listenelementen */
}

/* Tag-Modal Urlaubssektion */
.vacation-section {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #dee2e6;
}

.vacation-section h4 {
  margin: 0 0 1rem 0;
  color: #495057;
  font-size: 1.1rem;
}

.day-vacation-list {
  max-height: 200px;
  overflow-y: auto;
}

.day-vacation-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem;
  margin-bottom: 0.5rem;
  border-radius: 4px;
  border: 1px solid #dee2e6;
  background-color: white;
}

.day-vacation-item.vacation-approved {
  background-color: #d4edda;
  border-left: 3px solid #28a745;
  color: #155724;
}

.day-vacation-item.vacation-request {
  background-color: #fff3cd;
  border-left: 3px solid #ff9800;
  color: #856404;
}

.day-vacation-item .employee-name {
  font-weight: 500;
  margin-right: 0.5rem;
}

.day-vacation-item .vacation-type {
  flex: 1;
  font-size: 0.9rem;
  margin-right: 0.5rem;
}

.day-vacation-item .vacation-actions {
  display: flex;
  gap: 0.25rem;
}

.day-vacation-item .btn-approve,
.day-vacation-item .btn-remove {
  padding: 4px 8px;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.8rem;
}

.day-vacation-item .btn-approve {
  background-color: #28a745;
  color: white;
}

.day-vacation-item .btn-approve:hover {
  background-color: #218838;
}

.day-vacation-item .btn-remove {
  background-color: #dc3545;
  color: white;
}

.day-vacation-item .btn-remove:hover {
  background-color: #c82333;
}

.no-vacations {
  text-align: center;
  color: #6c757d;
  font-style: italic;
  padding: 1rem;
}

.closed-from-section {
  margin: 1rem 0;
  padding: 1rem;
  background-color: #fff8e6;
  border-radius: 8px;
  border: 1px solid #f0d58a;
}

.closed-from-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
}

.closed-from-fields {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(130px, auto);
  gap: 0.5rem 0.75rem;
  align-items: center;
}

.closed-from-fields label {
  font-size: 0.9rem;
  color: #5f4b17;
}

.closed-from-fields input {
  width: 100%;
  min-height: 38px;
  padding: 0.5rem;
  border: 1px solid #d8ba69;
  border-radius: 4px;
  background-color: white;
}

.closed-from-fields input:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

@media (max-width: 520px) {
  .closed-from-fields {
    grid-template-columns: 1fr;
  }
}

/* Dark Mode für Tag-Modal Urlaubssektion */
[data-theme="dark"] .vacation-section {
  background-color: #2d3748;
  border-color: #4a5568;
}

[data-theme="dark"] .vacation-section h4 {
  color: #e2e8f0;
}

[data-theme="dark"] .day-vacation-item {
  background-color: #1a202c;
  border-color: #4a5568;
}

[data-theme="dark"] .day-vacation-item.vacation-approved {
  background-color: #1b5e20;
  border-left-color: #4caf50;
  color: #a5d6a7;
}

[data-theme="dark"] .day-vacation-item.vacation-request {
  background-color: #664300;
  border-left-color: #ff9800;
  color: #ffcc80;
}

[data-theme="dark"] .no-vacations {
  color: #a0aec0;
}

[data-theme="dark"] .closed-from-section {
  background-color: #34280f;
  border-color: #755b1c;
}

[data-theme="dark"] .closed-from-fields label {
  color: #f5d889;
}

[data-theme="dark"] .closed-from-fields input {
  background-color: #1a202c;
  border-color: #755b1c;
  color: #f7fafc;
}

/* Ferien-Erinnerungs-Toast */
.holiday-reminder-toast {
  position: fixed;
  top: 20px;
  right: 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  z-index: 10000;
  max-width: 400px;
  min-width: 350px;
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

.holiday-reminder-toast.show {
  transform: translateX(0);
  opacity: 1;
}

.holiday-reminder-toast.hide {
  transform: translateX(100%);
  opacity: 0;
}

.holiday-reminder-content {
  padding: 20px;
}

.holiday-reminder-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
  gap: 10px;
}

.holiday-reminder-icon {
  font-size: 24px;
  animation: pulse 2s infinite;
}

.holiday-reminder-header h4 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  flex: 1;
}

.holiday-reminder-close {
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.holiday-reminder-close:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

.holiday-reminder-body {
  margin-bottom: 20px;
}

.holiday-reminder-body p {
  margin: 8px 0;
  line-height: 1.4;
}

.holiday-reminder-body p:first-child {
  font-size: 16px;
  font-weight: 600;
}

.holiday-reminder-message {
  font-style: italic;
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.1);
  padding: 8px 12px;
  border-radius: 6px;
  border-left: 3px solid #ffd700;
}

.holiday-reminder-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.btn-holiday-reminder {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-holiday-reminder:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.btn-holiday-reminder.secondary {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.btn-holiday-reminder.secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

/* Dark Mode für Ferien-Erinnerungen */
[data-theme="dark"] .holiday-reminder-toast {
  background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
  border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .holiday-reminder-message {
  background: rgba(255, 255, 255, 0.05);
  border-left-color: #ffd700;
}

/* Responsive Design */
@media (max-width: 768px) {
  .holiday-reminder-toast {
    right: 10px;
    left: 10px;
    max-width: none;
    min-width: auto;
  }
  
  .holiday-reminder-actions {
    flex-direction: column;
  }
  
  .btn-holiday-reminder {
    width: 100%;
  }
}

/* Template-Funktionalität Styles */
.template-controls {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.template-controls h3 {
  margin-top: 0;
  margin-bottom: 15px;
  color: #495057;
  font-size: 1.2em;
}

.template-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 15px;
}

.template-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
  background: #007bff;
  color: white;
}

.template-btn:hover:not(:disabled) {
  background: #0056b3;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.template-btn:disabled {
  background: #6c757d;
  cursor: not-allowed;
  opacity: 0.6;
}

.template-btn.secondary {
  background: #6c757d;
}

.template-btn.secondary:hover:not(:disabled) {
  background: #545b62;
}

.template-btn.danger {
  background: #dc3545;
}

.template-btn.danger:hover:not(:disabled) {
  background: #c82333;
}

.template-info {
  background: #e7f3ff;
  border: 1px solid #b3d9ff;
  border-radius: 6px;
  padding: 12px;
  color: #004085;
}

.template-info.hidden,
.hidden {
  display: none !important;
}

/* Spezielle Regel für versteckte Template-Modals */
.template-modal.hidden {
  display: none !important;
}

.template-info p {
  margin: 0;
  font-weight: 500;
}

/* Template Modal Styles */
.template-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.template-modal .template-modal-content {
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  max-width: 600px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.template-modal-header {
  padding: 20px 20px 0 20px;
  border-bottom: 1px solid #e0e0e0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.template-modal-header h3 {
  margin: 0;
  color: #333;
  font-size: 18px;
}

.template-modal-header .close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.template-modal-header .close-btn:hover {
  background-color: #f0f0f0;
}

.template-modal-body {
  padding: 20px;
  background: white;
}

.template-modal-footer {
  padding: 0 20px 20px 20px;
  border-top: 1px solid #e0e0e0;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  background: white;
}

.template-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.template-form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.template-form-group label {
  font-weight: 500;
  color: #495057;
}

.template-form-group input,
.template-form-group select {
  padding: 10px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 14px;
}

.template-form-group input:focus,
.template-form-group select:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.template-options {
  display: flex;
  gap: 15px;
  align-items: center;
}

.template-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.template-options input[type="radio"] {
  margin: 0;
}

/* Dark Mode Anpassungen für Template-Funktionalität */
[data-theme="dark"] .template-modal {
  background: rgba(0, 0, 0, 0.7);
}

[data-theme="dark"] .template-modal .template-modal-content {
  background: #2d3748;
  border-color: #4a5568;
}

[data-theme="dark"] .template-modal-header {
  border-bottom-color: #4a5568;
}

[data-theme="dark"] .template-modal-header h3 {
  color: #e2e8f0;
}

[data-theme="dark"] .template-modal-header .close-btn {
  color: #a0aec0;
}

[data-theme="dark"] .template-modal-header .close-btn:hover {
  background-color: #4a5568;
}

[data-theme="dark"] .template-modal-body {
  background: #2d3748;
}

[data-theme="dark"] .template-modal-footer {
  border-top-color: #4a5568;
  background: #2d3748;
}

[data-theme="dark"] .template-controls {
  background: #2d3748;
  border-color: #4a5568;
}

[data-theme="dark"] .template-controls h3 {
  color: #e2e8f0;
}

[data-theme="dark"] .template-info {
  background: #1a365d;
  border-color: #2c5282;
  color: #90cdf4;
}

[data-theme="dark"] .template-form-group label {
  color: #e2e8f0;
}

[data-theme="dark"] .template-form-group input,
[data-theme="dark"] .template-form-group select {
  background: #4a5568;
  border-color: #718096;
  color: #e2e8f0;
}

[data-theme="dark"] .template-form-group input:focus,
[data-theme="dark"] .template-form-group select:focus {
  border-color: #63b3ed;
  box-shadow: 0 0 0 2px rgba(99,179,237,0.25);
}

/* Dienstplan Header */
.dienstplan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 15px;
}

.dienstplan-header h2 {
  margin: 0;
}

.schedule-label-legend {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px 10px;
  margin: 12px 0 0;
  padding: 9px 11px;
  border: 1px solid var(--border-soft, #d6e0da);
  border-radius: var(--ui-radius, 6px);
  background: rgba(255, 255, 255, 0.78);
  color: #25312c;
  font-size: 0.86rem;
}

.schedule-label-legend strong {
  margin-right: 2px;
  font-size: 0.82rem;
  color: #4a5b53;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.legend-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 4px;
  font-size: 0.72rem;
  line-height: 1;
  font-weight: 800;
  color: #fff;
}

.legend-badge--vacation {
  background: #d92323;
}

.legend-badge--request {
  background: #ffca00;
  color: #5f4600;
}

.legend-badge--unavailable {
  background: #6c757d;
}

.legend-badge--school {
  background: #2196f3;
}

/* Month Template Button Styles */
.month-template-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
  background: #28a745;
  color: white;
  white-space: nowrap;
}

.month-template-btn:hover {
  background: #218838;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.month-template-btn:disabled {
  background: #6c757d;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Month Template Info Styles */
.month-template-info {
  background: #d4edda;
  border: 1px solid #c3e6cb;
  border-radius: 6px;
  padding: 12px;
  color: #155724;
  margin-bottom: 15px;
}

.month-template-info p {
  margin: 0;
  font-weight: 500;
  margin-bottom: 10px;
}

.month-template-info .template-btn {
  margin-top: 5px;
}

/* Month Selection Styles */
.month-selection {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.month-selection label {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.month-selection input[type="month"] {
  padding: 8px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 14px;
}

.month-selection span {
  font-weight: 500;
  color: #495057;
}

/* Dark Mode Anpassungen für Month Template */
[data-theme="dark"] .dienstplan-header h2 {
  color: #e2e8f0;
}

[data-theme="dark"] .schedule-label-legend {
  background: rgba(31, 42, 38, 0.92);
  color: #edf6f1;
  border-color: var(--border-soft);
}

[data-theme="dark"] .schedule-label-legend strong {
  color: #b8cbc3;
}

[data-theme="dark"] .month-template-btn {
  background: #38a169;
}

[data-theme="dark"] .month-template-btn:hover {
  background: #2f855a;
}

[data-theme="dark"] .month-template-info {
  background: #22543d;
  border-color: #38a169;
  color: #9ae6b4;
}

[data-theme="dark"] .month-selection input[type="month"] {
  background: #4a5568;
  border-color: #718096;
  color: #e2e8f0;
}

[data-theme="dark"] .month-selection span {
  color: #e2e8f0;
}

/* Day Template Button Styles */
.day-template-btn {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  padding: 2px;
  border-radius: 3px;
  transition: background-color 0.2s;
  color: #666;
}

.day-template-btn:hover {
  background-color: rgba(0, 0, 0, 0.1);
  color: #333;
}

[data-theme="dark"] .day-template-btn {
  color: #ccc;
}

[data-theme="dark"] .day-template-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: #fff;
}

/* Day Template Section in Edit Modal */
.template-section {
  margin: 20px 0;
  padding: 15px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  background: #f8f9fa;
}

.template-section h4 {
  margin: 0 0 15px 0;
  color: #495057;
  font-size: 16px;
}

.template-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 15px;
}

.template-options label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
}

.template-options input[type="radio"],
.template-options input[type="checkbox"] {
  margin: 0;
}

.template-fields {
  margin-bottom: 15px;
}

.template-fields label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
  color: #495057;
}

.template-fields input[type="date"] {
  width: 100%;
  padding: 8px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 14px;
  margin-bottom: 10px;
}

.template-shifts {
  margin-bottom: 15px;
}

.template-shifts label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #495057;
}

.shift-checkboxes {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.shift-checkboxes label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: normal;
}

.btn-template {
  background: #007bff;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s;
}

.btn-template:hover {
  background: #0056b3;
}

/* Dark Mode Anpassungen für Day Template */
[data-theme="dark"] .template-section {
  background: #2d3748;
  border-color: #4a5568;
}

[data-theme="dark"] .template-section h4 {
  color: #e2e8f0;
}

[data-theme="dark"] .template-options label {
  color: #e2e8f0;
}

[data-theme="dark"] .template-fields label {
  color: #e2e8f0;
}

[data-theme="dark"] .template-fields input[type="date"] {
  background: #4a5568;
  border-color: #718096;
  color: #e2e8f0;
}

[data-theme="dark"] .template-shifts label {
  color: #e2e8f0;
}

[data-theme="dark"] .shift-checkboxes label {
  color: #e2e8f0;
}

[data-theme="dark"] .btn-template {
  background: #3182ce;
}

[data-theme="dark"] .btn-template:hover {
  background: #2c5aa0;
}

/* Template Progress Modal Styles */
.template-progress-modal,
.progress-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1001;
}

.template-progress-modal .modal-content,
.progress-modal .progress-modal-content {
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 30px;
  max-width: 500px;
  width: 90%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  text-align: center;
}

.template-progress-modal .modal-header {
  background: #f8f9fa;
  padding: 20px;
  border-bottom: 1px solid #e0e0e0;
  border-radius: 8px 8px 0 0;
}

.template-progress-modal .modal-header h3 {
  margin: 0;
  color: #333;
  font-size: 18px;
}

.template-progress-modal .modal-body {
  padding: 30px;
}

.progress-container {
  margin-bottom: 20px;
}

.progress-bar {
  width: 100%;
  height: 20px;
  background: #e0e0e0;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 10px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #4CAF50, #45a049);
  width: 0%;
  transition: width 0.3s ease;
}

.progress-text {
  text-align: center;
  font-weight: bold;
  color: #333;
  font-size: 16px;
}

.status-messages {
  max-height: 200px;
  overflow-y: auto;
  border: 1px solid #e0e0e0;
  border-radius: 5px;
  padding: 15px;
  background: #f9f9f9;
}

.status-message {
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  color: #555;
  font-size: 14px;
}

.status-message:last-child {
  border-bottom: none;
  font-weight: bold;
  color: #333;
}

/* Dark Mode für Template Progress Modal */
[data-theme="dark"] .template-progress-modal .modal-content {
  background: #2d3748;
  border-color: #4a5568;
}

[data-theme="dark"] .template-progress-modal .modal-header {
  background: #4a5568;
  border-color: #4a5568;
}

[data-theme="dark"] .template-progress-modal .modal-header h3 {
  color: #e2e8f0;
}

[data-theme="dark"] .template-progress-modal .modal-body {
  color: #e2e8f0;
}

[data-theme="dark"] .progress-bar {
  background: #4a5568;
}

[data-theme="dark"] .progress-fill {
  background: linear-gradient(90deg, #48bb78, #38a169);
}

/* Zusätzliche Stile für neue Progress-Modals */
.progress-modal .progress-bar-container {
  width: 100%;
  height: 20px;
  background: #f0f0f0;
  border-radius: 10px;
  margin: 20px 0;
  overflow: hidden;
}

.progress-modal .progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #4CAF50, #45a049);
  width: 0%;
  transition: width 0.3s ease;
  border-radius: 10px;
}

.progress-modal h3 {
  margin-bottom: 20px;
  color: #333;
}

.progress-modal p {
  margin: 10px 0;
  color: #666;
}

/* Dark Mode für neue Progress-Modals */
[data-theme="dark"] .progress-modal .progress-modal-content {
  background: #2d3748;
  border-color: #4a5568;
  color: #e2e8f0;
}

[data-theme="dark"] .progress-modal h3 {
  color: #e2e8f0;
}

[data-theme="dark"] .progress-modal p {
  color: #a0aec0;
}

[data-theme="dark"] .progress-modal .progress-bar-container {
  background: #4a5568;
}

[data-theme="dark"] .progress-text {
  color: #e2e8f0;
}

[data-theme="dark"] .status-messages {
  background: #4a5568;
  border-color: #4a5568;
}

[data-theme="dark"] .status-message {
  color: #cbd5e0;
  border-color: #4a5568;
}

[data-theme="dark"] .status-message:last-child {
  color: #e2e8f0;
}

/* Notification Bell Styles */
.notification-bell-container {
  position: relative;
  margin-left: 10px;
}

.notification-bell {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  position: relative;
  padding: 8px;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.notification-bell:hover {
  background-color: rgba(0, 0, 0, 0.1);
  transform: scale(1.1);
}

.conflict-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #ff4444;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 12px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* Urlaubskonflikt-Kennzeichnung */
.vacation-conflict-medium {
  border: 3px solid #ff8c00 !important;
  background-color: rgba(255, 140, 0, 0.1) !important;
  position: relative;
}

.vacation-conflict-high {
  border: 3px solid #ff4444 !important;
  background-color: rgba(255, 68, 68, 0.1) !important;
  position: relative;
}

.vacation-conflict-medium::after,
.vacation-conflict-high::after {
  content: "!";
  position: absolute;
  top: -8px;
  right: -8px;
  font-size: 16px;
  background: white;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Dark Mode für Konflikte */
[data-theme="dark"] .vacation-conflict-medium {
  background-color: rgba(255, 140, 0, 0.2) !important;
}

[data-theme="dark"] .vacation-conflict-high {
  background-color: rgba(255, 68, 68, 0.2) !important;
}

[data-theme="dark"] .vacation-conflict-medium::after,
[data-theme="dark"] .vacation-conflict-high::after {
  background: #333;
  color: white;
}

/* Konflikt-Popup */
.conflict-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border: 2px solid #ddd;
  border-radius: 12px;
  padding: 20px;
  max-width: 600px;
  max-height: 80vh;
  overflow-y: auto;
  z-index: 10000;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.conflict-popup h3 {
  margin: 0 0 15px 0;
  color: #333;
  border-bottom: 2px solid #ff4444;
  padding-bottom: 10px;
}

.conflict-aggregator {
  width: min(720px, calc(100vw - 32px));
  max-width: 720px;
}

.conflict-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 14px 0;
  padding-bottom: 10px;
  border-bottom: 1px solid #e4e7eb;
}

.conflict-tab-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #d6dde3;
  border-radius: 8px;
  background: #f4f7f9;
  color: #24313a;
  padding: 8px 10px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.conflict-tab-button:hover {
  background: #e8f0f5;
}

.conflict-tab-button.active {
  background: #263238;
  border-color: #263238;
  color: #fff;
}

.conflict-tab-button span {
  min-width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #fff;
  color: #263238;
  font-size: 12px;
  line-height: 1;
}

.conflict-tab-panel {
  display: none;
}

.conflict-tab-panel.active {
  display: block;
}

.conflict-empty {
  padding: 18px;
  border: 1px dashed #cfd8dc;
  border-radius: 8px;
  color: #5d6a72;
  background: #f8fafb;
}

.conflict-severity {
  display: inline-flex;
  align-items: center;
  margin-left: 10px;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 12px;
  color: white;
}

.conflict-severity.high {
  background: #d32f2f;
}

.conflict-severity.medium {
  background: #ef8b19;
}

.conflict-item {
  background: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 10px;
}

.conflict-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.btn-resolve-single {
  background-color: #17a2b8;
  color: white;
  border: none;
  padding: 5px 10px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 0.8em;
  transition: background-color 0.2s;
}

.btn-resolve-single:hover {
  background-color: #138496;
}

.conflict-date {
  font-weight: bold;
  color: #ff4444;
  margin-bottom: 8px;
}

.conflict-employees {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.conflict-employee {
  background: #e3f2fd;
  border: 1px solid #2196f3;
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.conflict-employee:hover {
  background: #bbdefb;
  transform: translateY(-1px);
}

.conflict-employee.approved {
  background: #e8f5e8;
  border-color: #4caf50;
  color: #2e7d32;
}

.conflict-employee.request {
  background: #fff3e0;
  border-color: #ff8c00;
  color: #e65100;
}

.counter-conflict-list,
.vacation-request-list {
  display: grid;
  gap: 10px;
}

.counter-conflict-item,
.vacation-request-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: #f9fbfc;
  border: 1px solid #dde6ec;
  border-radius: 8px;
  padding: 12px;
}

.counter-conflict-copy {
  display: grid;
  gap: 4px;
}

.counter-conflict-copy span,
.vacation-request-date {
  color: #52616b;
  font-size: 14px;
}

.request-profile-link {
  font: inherit;
}

.btn-open-counter-conflict-day,
.btn-approve-aggregated-request {
  border: none;
  border-radius: 6px;
  color: white;
  cursor: pointer;
  font-weight: 700;
  padding: 8px 12px;
  white-space: nowrap;
}

.btn-open-counter-conflict-day {
  background: #546e7a;
}

.btn-open-counter-conflict-day:hover {
  background: #455a64;
}

.btn-approve-aggregated-request {
  background: #2e7d32;
}

.btn-approve-aggregated-request:hover {
  background: #256b2a;
}

.conflict-actions {
  margin-top: 15px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.btn-resolve {
  background: #4caf50;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}

.btn-resolve:hover {
  background: #45a049;
}

.btn-close-conflicts {
  background: #f44336;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}

.btn-close-conflicts:hover {
  background: #d32f2f;
}

/* Dark Mode für Konflikt-Popup */
[data-theme="dark"] .conflict-popup {
  background: #333;
  border-color: #555;
  color: white;
}

[data-theme="dark"] .conflict-popup h3 {
  color: white;
  border-bottom-color: #ff4444;
}

[data-theme="dark"] .conflict-tabs {
  border-bottom-color: #555;
}

[data-theme="dark"] .conflict-tab-button {
  background: #2a2a2a;
  border-color: #555;
  color: #eee;
}

[data-theme="dark"] .conflict-tab-button:hover {
  background: #383838;
}

[data-theme="dark"] .conflict-tab-button.active {
  background: #20c997;
  border-color: #20c997;
  color: #10201b;
}

[data-theme="dark"] .conflict-tab-button span {
  background: #111;
  color: #e8f5e9;
}

[data-theme="dark"] .conflict-empty {
  background: #2a2a2a;
  border-color: #666;
  color: #ddd;
}

[data-theme="dark"] .conflict-item {
  background: #444;
  border-color: #666;
}

[data-theme="dark"] .btn-resolve-single {
  background-color: #20c997;
  color: white;
}

[data-theme="dark"] .btn-resolve-single:hover {
  background-color: #1aa179;
}

[data-theme="dark"] .conflict-employee {
  background: #1e3a5f;
  border-color: #2196f3;
  color: #90caf9;
}

[data-theme="dark"] .conflict-employee:hover {
  background: #1565c0;
}

[data-theme="dark"] .conflict-employee.approved {
  background: #1b5e20;
  border-color: #4caf50;
  color: #a5d6a7;
}

[data-theme="dark"] .conflict-employee.request {
  background: #e65100;
  border-color: #ff8c00;
  color: #ffb74d;
}

[data-theme="dark"] .counter-conflict-item,
[data-theme="dark"] .vacation-request-item {
  background: #3a3a3a;
  border-color: #666;
}

[data-theme="dark"] .counter-conflict-copy span,
[data-theme="dark"] .vacation-request-date {
  color: #d5dde3;
}

[data-theme="dark"] .btn-open-counter-conflict-day {
  background: #607d8b;
}

[data-theme="dark"] .btn-open-counter-conflict-day:hover {
  background: #78909c;
}

[data-theme="dark"] .btn-approve-aggregated-request {
  background: #2e7d32;
}

[data-theme="dark"] .btn-approve-aggregated-request:hover {
  background: #388e3c;
}

[data-theme="dark"] .vacation-overview-modal .tab {
  border-bottom-color: #444;
}

[data-theme="dark"] .vacation-overview-modal .tablinks {
  background-color: #2a2a2a;
  color: #eee;
  border-right-color: #444;
}

[data-theme="dark"] .vacation-overview-modal .tablinks.active {
  background-color: #1e1e1e;
  color: #64B5F6;
}

[data-theme="dark"] .vacation-overview-modal .unavailable-details li {
  border-bottom-color: #444;
}

/* Keyboard Navigation Focus Style */
.day:focus {
  outline: 3px solid #007bff;
  box-shadow: 0 0 10px rgba(0, 123, 255, 0.5);
  z-index: 10;
  position: relative; /* Ensure z-index works */
}

/* Ensure focus is visible even if outline is disabled in some resets */
.day:focus-visible {
  outline: 3px solid #007bff;
}

/* v15.3 subtle screen-only visual polish */
@media screen {
  :root {
    --surface-page: #eef3f1;
    --surface-card: #fbfcfb;
    --surface-muted: #f5f8f6;
    --border-soft: #d6e0da;
    --accent-line: #2f7d68;
    --accent-line-soft: rgba(47, 125, 104, 0.14);
    --focus-ring: rgba(47, 125, 104, 0.22);
    --shadow-soft: 0 10px 26px rgba(37, 49, 44, 0.08);
    --shadow-lift: 0 14px 32px rgba(37, 49, 44, 0.12);
    --presence-bg: #dff2e7;
    --presence-border: #a5d6b7;
    --counter-bg: #fff1bf;
    --counter-border: #e4bd48;
    --optional-bg: #e8edf8;
    --optional-border: #b9c4df;
  }

  [data-theme="dark"] {
    --surface-page: #101815;
    --surface-card: #17211d;
    --surface-muted: #1f2a26;
    --border-soft: #314139;
    --accent-line: #79c7ad;
    --accent-line-soft: rgba(121, 199, 173, 0.18);
    --focus-ring: rgba(121, 199, 173, 0.26);
    --shadow-soft: 0 12px 30px rgba(0, 0, 0, 0.28);
    --shadow-lift: 0 16px 38px rgba(0, 0, 0, 0.38);
    --presence-bg: #1f3b2e;
    --presence-border: #4c9a70;
    --counter-bg: #3c321b;
    --counter-border: #9a7a2f;
    --optional-bg: #202a3f;
    --optional-border: #4e5d83;
  }

  body {
    background: linear-gradient(180deg, var(--surface-page) 0%, #f7f9f8 42%, var(--surface-page) 100%);
    color: #25312c;
    padding-top: var(--top-menu-offset, 190px);
  }

  [data-theme="dark"] body {
    background: linear-gradient(180deg, var(--surface-page) 0%, #131d19 48%, #0d1412 100%);
    color: #edf6f1;
  }

  main {
    margin-top: 0;
  }

  header {
    background-color: rgba(251, 252, 251, 0.9);
    border-bottom: 1px solid var(--border-soft);
    box-shadow: 0 8px 24px rgba(37, 49, 44, 0.1);
    backdrop-filter: blur(10px);
  }

  [data-theme="dark"] header {
    background-color: rgba(23, 33, 29, 0.92);
    border-bottom-color: var(--border-soft);
  }

  .controls,
  .employee-management,
  .export-section,
  .modal-content {
    background: var(--surface-card);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
  }

  .controls {
    padding: 10px 10px;
    color: #25312c;
    display: grid;
    grid-template-columns:
      minmax(0, 0.82fr)
      minmax(0, 0.98fr)
      minmax(0, 1.35fr)
      minmax(0, 1.15fr)
      minmax(0, 0.58fr);
    align-items: stretch;
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
    overflow: visible;
  }

  .controls > .migration-buttons {
    display: none !important;
    grid-column: auto !important;
    width: 0 !important;
    height: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
  }

  .top-menu-group {
    position: relative;
    display: flex;
    align-items: center;
    align-content: center;
    gap: 7px;
    flex-wrap: wrap;
    min-width: 0;
    min-height: 56px;
    padding: 17px 7px 7px;
    border: 1px solid var(--border-soft);
    border-radius: var(--ui-radius);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.64), var(--surface-muted));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
    box-sizing: border-box;
    overflow: visible;
  }

  [data-theme="dark"] .top-menu-group {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), var(--surface-muted));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  }

  .top-menu-group-label {
    position: absolute;
    top: 5px;
    left: 7px;
    color: rgba(37, 49, 44, 0.58);
    font-size: 0.62rem;
    font-weight: 750;
    letter-spacing: 0;
    line-height: 1;
    text-transform: uppercase;
    pointer-events: none;
  }

  [data-theme="dark"] .top-menu-group-label {
    color: rgba(237, 246, 241, 0.58);
  }

  .top-menu-group h4 {
    margin: 0;
    white-space: nowrap;
  }

  .top-menu-group h4 small {
    color: rgba(37, 49, 44, 0.58) !important;
  }

  [data-theme="dark"] .top-menu-group h4 small {
    color: rgba(237, 246, 241, 0.58) !important;
  }

  .top-menu-group .year-tabs,
  .top-menu-group .month-controls,
  .top-menu-group .ux-toolbar {
    margin: 0;
  }

  .top-menu-group .year-tabs {
    align-items: center;
    flex: 1 1 auto;
    flex-wrap: wrap;
    gap: 4px;
    min-width: 0;
    overflow: visible;
    scrollbar-width: none;
  }

  .top-menu-group .year-tabs::-webkit-scrollbar {
    display: none;
  }

  .top-menu-group .year-tab {
    min-height: 30px;
    padding: 6px 8px;
    font-size: 0.8rem;
  }

  .top-menu-group button {
    width: auto;
  }

  .top-menu-group .month-controls {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
  }

  .top-menu-group .month-controls input[type="month"] {
    min-width: 132px;
    min-height: 34px;
  }

  .top-menu-group .generate_custom,
  .top-menu-group .btn-staffing,
  .top-menu-group .btn-vacation-settings,
  .top-menu-group .btn-weekly-template,
  .top-menu-group .btn-backup-import,
  .top-menu-group .btn-settings-modal,
  .top-menu-group .btn-scheduling-modal,
  .top-menu-group .btn-saturday-rotation,
  .top-menu-group .btn-employees-modal,
  .top-menu-group .btn-saturday-subscription-topbar,
  .top-menu-group .ux-scroll-schedule,
  .top-menu-group .ux-turnus-check-toggle,
  .top-menu-group .ux-friday-turnus-check-toggle,
  .top-menu-group .ux-compact-toggle {
    min-height: 34px;
    margin: 0;
    padding: 7px 9px;
    border-radius: var(--ui-radius);
    white-space: nowrap;
  }

  .top-menu-group .btn-icon,
  .top-menu-group .notification-bell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 34px;
    min-height: 34px;
    padding: 7px 8px;
  }

  .top-menu-group .btn-text,
  .top-menu-group .btn-icon-label {
    display: inline-flex;
    align-items: center;
    line-height: 1;
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0;
    white-space: nowrap;
  }

  .top-menu-group .btn-icon .line-icon,
  .top-menu-group .notification-bell .line-icon {
    margin-right: 0;
  }

  .top-menu-group .notification-bell-container,
  .top-menu-group .inline-theme-switch {
    position: relative;
    margin: 0;
  }

  .top-menu-group .notification-bell {
    border: 1px solid var(--border-soft);
    background: var(--surface-card);
    border-radius: var(--ui-radius);
    font-size: 1rem;
  }

  .top-menu-group .notification-bell:hover {
    transform: translateY(-1px);
  }

  .top-menu-group .ux-toolbar {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .top-menu-group .ux-status {
    min-width: auto;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .top-menu-group--data {
    justify-content: flex-end;
  }

  [data-quick-info] {
    position: relative;
  }

  [data-quick-info]:is(:hover, :focus-visible)::after {
    content: attr(data-quick-info);
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    z-index: 1400;
    width: max-content;
    max-width: 260px;
    padding: 8px 10px;
    border: 1px solid rgba(37, 49, 44, 0.14);
    border-radius: var(--ui-radius);
    background: rgba(25, 34, 30, 0.95);
    color: #fff;
    font-size: 0.74rem;
    font-weight: 600;
    line-height: 1.28;
    text-align: left;
    white-space: normal;
    box-shadow: 0 12px 26px rgba(25, 34, 30, 0.2);
    transform: translateX(-50%);
    pointer-events: none;
  }

  [data-quick-info]:is(:hover, :focus-visible)::before {
    content: "";
    position: absolute;
    top: calc(100% + 3px);
    left: 50%;
    z-index: 1401;
    width: 9px;
    height: 9px;
    background: rgba(25, 34, 30, 0.95);
    transform: translateX(-50%) rotate(45deg);
    pointer-events: none;
  }

  .top-menu-group--brand [data-quick-info]:is(:hover, :focus-visible)::after,
  .top-menu-group--brand [data-quick-info]:is(:hover, :focus-visible)::before {
    left: 0;
    transform: none;
  }

  .top-menu-group--brand [data-quick-info]:is(:hover, :focus-visible)::before {
    transform: rotate(45deg);
  }

  .top-menu-group--data [data-quick-info]:is(:hover, :focus-visible)::after,
  .top-menu-group--data [data-quick-info]:is(:hover, :focus-visible)::before {
    right: 0;
    left: auto;
    transform: none;
  }

  .top-menu-group--data [data-quick-info]:is(:hover, :focus-visible)::before {
    transform: rotate(45deg);
  }

  header .controls .year-tabs .year-tab[data-quick-info]:is(:hover, :focus-visible)::after {
    position: fixed;
    top: var(--quick-info-y, calc(var(--top-menu-offset) + 4px));
    z-index: 12000;
    left: var(--quick-info-x, 50vw);
    max-width: min(260px, calc(100vw - 20px));
    transform: translateX(-50%);
  }

  header .controls .year-tabs .year-tab[data-quick-info]:is(:hover, :focus-visible)::before {
    position: fixed;
    top: calc(var(--quick-info-y, calc(var(--top-menu-offset) + 4px)) - 5px);
    z-index: 12001;
    left: var(--quick-info-arrow-x, var(--quick-info-x, 50vw));
    transform: translateX(-50%) rotate(45deg);
  }

  .export-section {
    margin: 22px 0 12px;
    padding: 14px;
    background: var(--surface-card);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
  }

  .export-section h3 {
    margin: 0 0 10px;
    color: #25312c;
    font-size: 1rem;
    font-weight: 650;
  }

  .export-section .export-buttons-container {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 2px 0 4px;
    scrollbar-width: thin;
  }

  .export-section .button-group {
    flex: 0 0 auto;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    padding: 0;
    background: transparent;
  }

  .export-section .export-button {
    flex: 0 0 auto;
    min-height: 40px;
    padding: 8px 12px;
    white-space: nowrap;
    background: var(--surface-muted);
    color: #25312c;
    border: 1px solid var(--border-soft);
    line-height: 1.1;
  }

  .export-section .export-button.primary {
    background: var(--accent-line);
    border-color: var(--accent-line);
    color: #fff;
  }

  .export-section .export-button.secondary {
    background: transparent;
    border-color: rgba(47, 125, 104, 0.35);
    color: var(--accent-line);
  }

  [data-theme="dark"] .export-section {
    background: var(--surface-card) !important;
    border-color: var(--border-soft) !important;
    color: #edf6f1 !important;
  }

  [data-theme="dark"] .export-section h3,
  [data-theme="dark"] .export-section .export-button {
    color: #edf6f1 !important;
  }

  [data-theme="dark"] .export-section .button-group {
    background: transparent !important;
    border-color: transparent !important;
  }

  [data-theme="dark"] .export-section .export-button {
    background: var(--surface-muted) !important;
    border-color: var(--border-soft) !important;
  }

  [data-theme="dark"] .export-section .export-button.primary {
    background: var(--accent-line) !important;
    border-color: var(--accent-line) !important;
    color: #0d1412 !important;
  }

  [data-theme="dark"] .export-section .export-button.secondary {
    background: transparent !important;
    border-color: rgba(121, 199, 173, 0.42) !important;
    color: var(--accent-line) !important;
  }

  .employee-management {
    scroll-margin-top: var(--top-menu-offset, 190px);
  }

  .employee-management .accordion {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 10px 14px;
    margin-bottom: 0;
    font-size: 15px;
    font-weight: 700;
    background: #304253;
    border: 1px solid rgba(48, 66, 83, 0.18);
  }

  .employee-management .accordion .line-icon {
    margin-right: 0;
  }

  .employee-management .panel {
    background: var(--surface-muted);
    border: 1px solid var(--border-soft);
    border-top: 0;
    padding-inline: 12px;
  }

  .employee-management .panel.show {
    min-height: 0;
    padding-top: 10px;
    padding-bottom: 14px;
  }

  #addEmployeeForm {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(150px, 0.75fr) minmax(96px, 0.32fr) auto;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
  }

  #addEmployeeForm input,
  #addEmployeeForm select {
    min-height: 32px;
    padding: 6px 9px;
    box-sizing: border-box;
  }

  #addEmployeeForm input#employeeVacationDays {
    width: 100%;
    min-width: 96px;
    padding: 6px 9px;
  }

  #employeesTable {
    margin-top: 8px;
    font-size: 0.9rem;
  }

  #employeesTable th,
  #employeesTable td {
    padding: 8px 10px;
    vertical-align: middle;
  }

  #employeesTable .vacation-info {
    margin-bottom: 0;
    padding: 6px 8px;
  }

  #employeesTable .vacation-progress {
    margin: 6px 0 0;
  }

  #employeesTable .progress-bar {
    height: 8px;
  }

  .action-buttons,
  .vacation-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
  }

  .employee-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 32px;
    padding: 6px 10px;
    font-size: 0.84rem;
    line-height: 1.1;
    white-space: nowrap;
  }

  .employee-action-button .line-icon,
  .vacation-overview-modal .tablinks .line-icon {
    margin-right: 0;
  }

  .vacation-overview-modal .tab {
    display: flex;
    gap: 6px;
    padding: 3px;
    margin-bottom: 10px;
    border: 1px solid var(--border-soft);
    border-radius: var(--ui-radius);
    background: var(--surface-muted);
  }

  .vacation-overview-modal .tablinks {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid transparent;
    border-radius: var(--ui-radius);
    font-size: 13px;
  }

  .vacation-overview-modal .tablinks.active {
    border-color: var(--border-soft);
    box-shadow: 0 4px 12px rgba(37, 49, 44, 0.08);
  }

  .shift-block p.hat_urlaub,
  .shift-block p.hat_urlaubswunsch {
    display: flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
    overflow: hidden;
    padding-right: 6px;
  }

  .shift-block p.hat_urlaub .employee-name-with-avatar,
  .shift-block p.hat_urlaubswunsch .employee-name-with-avatar {
    min-width: 0;
    flex: 1 1 auto;
  }

  .shift-block p.hat_urlaub .employee-name-label,
  .shift-block p.hat_urlaubswunsch .employee-name-label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .shift-block p.hat_urlaub .urlaub-badge,
  .shift-block p.hat_urlaubswunsch .urlaubswunsch-badge {
    position: static;
    margin-left: auto;
    right: auto;
    top: auto;
    flex: 0 0 auto;
    transform: none;
  }

  .shift-block p.ist_nv {
    display: flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
    overflow: hidden;
    background: #eef1f3;
    border: 1px solid #d6dde2;
    color: #33414a;
    border-radius: var(--ui-radius);
    padding: 3px 6px;
    padding-right: 6px;
  }

  [data-theme="dark"] .shift-block p.ist_nv {
    background: rgba(108, 117, 125, 0.18);
    border-color: rgba(190, 200, 208, 0.32);
    color: #d8e0e5;
  }

  .shift-block p.ist_nv .employee-name-with-avatar {
    min-width: 0;
    flex: 1 1 auto;
  }

  .shift-block p.ist_nv .employee-name-label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .shift-block p.ist_nv .nicht-verfuegbar-badge {
    margin-left: auto;
    white-space: nowrap;
    flex: 0 0 auto;
  }

  header .controls #month-picker {
    flex: 1 0 100%;
    grid-column: 1 / -1;
    order: 99;
    display: flex;
    align-items: center;
    justify-content: safe center;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    margin: 0;
    min-height: 58px;
    padding: 0;
    border-top: 1px solid var(--border-soft);
    overflow-x: auto;
    overflow-y: hidden;
    box-sizing: border-box;
    scrollbar-width: thin;
  }

  header .controls #month-picker .month-picker-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-height: 42px;
    padding: 10px 14px;
    margin: 0;
    line-height: 1.2;
    box-sizing: border-box;
  }

  [data-theme="dark"] .controls {
    color: #edf6f1;
  }

  .dashboard,
  .urlaubsubersicht,
  .urlaubsübersicht,
  #aktueller-dienstplan,
  .saturday-stats-chart,
  .conflict-popup,
  .template-modal-content {
    background: var(--surface-card);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
  }

  button,
  .button,
  .btn,
  .export-button,
  .year-tab,
  .month-picker-button,
  .tablinks {
    border-color: var(--border-soft);
    box-shadow: none;
    transition: background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
  }

  button:hover,
  .button:hover,
  .btn:hover,
  .export-button:hover,
  .year-tab:hover,
  .month-picker-button:hover,
  .tablinks:hover {
    border-color: rgba(47, 125, 104, 0.35);
    box-shadow: 0 8px 18px rgba(37, 49, 44, 0.1);
    transform: translateY(-1px);
  }

  input,
  select,
  textarea {
    border-color: var(--border-soft);
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
  }

  input:focus,
  select:focus,
  textarea:focus {
    border-color: var(--accent-line);
    box-shadow: 0 0 0 3px var(--focus-ring);
  }

  .weekday-header {
    background: #e0e9e4;
    color: #25312c;
    border-color: var(--border-soft);
  }

  [data-theme="dark"] .weekday-header {
    background: #1f2a26;
    color: #edf6f1;
    border-color: var(--border-soft);
  }

  .day {
    background: var(--surface-card);
    border-color: var(--border-soft);
    box-shadow: 0 6px 16px rgba(37, 49, 44, 0.08);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
  }

  .day:hover {
    border-color: rgba(47, 125, 104, 0.35);
    box-shadow: var(--shadow-lift);
    transform: translateY(-1px);
  }

  .day.today {
    border-color: var(--accent-line);
    box-shadow: 0 0 0 2px var(--accent-line-soft), var(--shadow-soft);
  }

  .day h3 {
    display: flex;
    align-items: baseline;
    justify-content: flex-start;
    gap: 0;
    padding-right: 34px;
  }

  .day-heading-inline {
    display: inline-flex;
    align-items: baseline;
    gap: 0.45rem;
    min-width: 0;
    max-width: 100%;
  }

  .day-heading-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .day-checksum {
    position: static;
    color: #1f6ed4;
    font-size: 0.72em;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    flex: 0 0 auto;
  }

  [data-theme="dark"] .day-checksum {
    color: #8ab8ff;
  }

  .shift-block.fulltime {
    background: var(--presence-bg);
    border-color: var(--presence-border);
  }

  .shift-block.lateshift {
    background: var(--counter-bg);
    border-color: var(--counter-border);
  }

  .shift-block.parttime {
    background: var(--optional-bg);
    border-color: var(--optional-border);
  }

  .day .shift-block.fulltime,
  .form-group.fulltime {
    background: var(--presence-bg);
    border-color: var(--presence-border);
    color: #1f352b;
  }

  .day .shift-block.lateshift,
  .form-group.lateshift {
    background: var(--counter-bg);
    border-color: var(--counter-border);
    color: #3d3116;
  }

  .day .shift-block.parttime,
  .form-group.parttime {
    background: var(--optional-bg);
    border-color: var(--optional-border);
    color: #25304a;
  }

  [data-theme="dark"] .day .shift-block.fulltime,
  [data-theme="dark"] .day .shift-block.lateshift,
  [data-theme="dark"] .day .shift-block.parttime,
  [data-theme="dark"] .form-group.fulltime,
  [data-theme="dark"] .form-group.lateshift,
  [data-theme="dark"] .form-group.parttime {
    color: #edf6f1;
  }

  .ux-compact-view .day .shift-block {
    margin-bottom: 3px;
    padding: 3px 4px;
    border-left-width: 3px;
    border-left-style: solid;
  }

  .ux-compact-view .day .shift-block.fulltime {
    border-left-color: #24864e;
    box-shadow: inset 3px 0 0 #24864e;
  }

  .ux-compact-view .day .shift-block.lateshift {
    border-left-color: #bf8b18;
    box-shadow: inset 3px 0 0 #bf8b18;
  }

  .ux-compact-view .day .shift-block.parttime {
    border-left-color: #25869a;
    box-shadow: inset 3px 0 0 #25869a;
  }

  .notification {
    box-shadow: var(--shadow-soft);
  }

  .month-boundary-loader {
    grid-column: 1 / -1;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 38px;
    margin: 2px 0;
  }

  .month-boundary-loader--before {
    padding-bottom: 2px;
  }

  .month-boundary-loader--after {
    padding-top: 2px;
    gap: 8px;
    flex-wrap: wrap;
  }

  .month-boundary-load-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 34px;
    padding: 7px 13px;
    border-radius: var(--ui-radius);
    border: 1px solid var(--border-soft);
    background: color-mix(in srgb, var(--surface-card) 88%, var(--accent-line-soft));
    color: var(--accent-line);
    box-shadow: 0 5px 14px rgba(37, 49, 44, 0.08);
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
  }

  .month-boundary-load-button:hover {
    transform: translateY(-1px);
    border-color: color-mix(in srgb, var(--accent-line) 48%, var(--border-soft));
    background: color-mix(in srgb, var(--surface-card) 80%, var(--accent-line-soft));
    box-shadow: 0 8px 18px rgba(37, 49, 44, 0.12);
  }

  .month-boundary-load-button:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
  }

  .month-boundary-reset-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 34px;
    padding: 7px 12px;
    border-radius: var(--ui-radius);
    border: 1px solid color-mix(in srgb, var(--border-soft) 80%, var(--accent-line));
    background: color-mix(in srgb, var(--surface-muted) 92%, #fff);
    color: #405047;
    box-shadow: 0 4px 12px rgba(37, 49, 44, 0.06);
    font-size: 0.82rem;
    font-weight: 750;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
  }

  .month-boundary-reset-button:hover {
    transform: translateY(-1px);
    border-color: color-mix(in srgb, var(--accent-line) 40%, var(--border-soft));
    background: var(--surface-card);
    box-shadow: 0 7px 16px rgba(37, 49, 44, 0.1);
  }

  .month-boundary-reset-button:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 2px;
  }

  .month-boundary-load-button .line-icon {
    width: 15px;
    height: 15px;
  }

  .month-boundary-reset-button .line-icon {
    width: 15px;
    height: 15px;
  }

  .month-boundary-load-button small {
    color: color-mix(in srgb, currentColor 66%, transparent);
    font-size: 0.72rem;
    font-weight: 600;
  }

  .day.outside-month-loaded {
    background: linear-gradient(180deg, #f0f2f4, #e3e7eb);
    border: 1px solid #c5ccd3;
    color: #5f6872;
    opacity: 0.78;
    filter: grayscale(0.18) saturate(0.72);
  }

  .day.outside-month-loaded .shift-block {
    opacity: 0.86;
  }

  .day.outside-month-loaded h3 {
    color: #4d5965;
  }

  .day.outside-month-loaded::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    border-radius: var(--ui-radius) 0 0 var(--ui-radius);
    background: #9aa3ad;
    opacity: 0.72;
    pointer-events: none;
  }

  [data-theme="dark"] .month-boundary-load-button {
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.24);
  }

  [data-theme="dark"] .month-boundary-reset-button {
    background: color-mix(in srgb, var(--surface-muted) 88%, #000);
    color: #d8e4de;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
  }

  [data-theme="dark"] .day.outside-month-loaded {
    background: linear-gradient(180deg, #30363c, #252a2f);
    border-color: #515a63;
    color: #aeb6be;
  }
}

@media screen and (max-width: 1120px) {
  .controls {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .top-menu-group--setup,
  .top-menu-group--data {
    justify-content: flex-start;
  }
}

@media screen and (max-width: 920px) {
  .controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media screen and (max-width: 680px) {
  .controls {
    grid-template-columns: 1fr;
  }

  .top-menu-group {
    justify-content: flex-start;
  }

  .top-menu-group .month-controls {
    flex-wrap: wrap;
  }

  .employee-management-modal #addEmployeeForm {
    grid-template-columns: 1fr;
  }

  .employee-management-modal #employeesTable {
    min-width: 680px;
  }
}

@media screen {
  button,
  .button,
  .btn,
  .btn-primary,
  .btn-secondary,
  .btn-save,
  .export-button,
  .year-tab,
  .tablinks,
  input,
  select,
  textarea,
  .modal-content,
  .template-modal-content,
  .conflict-popup,
  .notification,
  .day,
  .shift-block,
  .employee-management,
  .export-section,
  .saturday-distribution-preview,
  .counter-tonus-notice,
  .counter-conflict-item,
  .vacation-request-item,
  .ui-radius-normalized {
    border-radius: var(--ui-radius) !important;
  }
}

/* Print v15.1: A3-Querformat, kompakter Kalender, ohne leere Vorschaltseiten */
@media print {
  @page {
    size: A3 landscape;
    margin: 7mm;
  }

  html,
  body {
    width: auto;
    margin: 0 !important;
    padding: 0 !important;
    background: #fff !important;
    color: #000 !important;
    font-size: 10pt;
    line-height: 1.12;
  }

  header,
  footer,
  .controls,
  .export-buttons,
  .export-section,
  .export-buttons-container,
  .employee-management,
  .notification,
  .edit-indicator,
  .btn-overview,
  .btn-edit,
  .btn-delete,
  .btn-add-vacation,
  .month-template-btn,
  .print-option-toggle,
  .month-boundary-loader,
  #schedule-tabs,
  .weekday-header {
    display: none !important;
  }

  .month-boundary-loader {
    display: none !important;
  }

  #schedule,
  #schedules-container,
  .dienstplan {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
    overflow: visible !important;
  }

  .schedule-month,
  .schedule-month.active-calendar {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr)) minmax(0, 0.78fr) !important;
    grid-auto-rows: minmax(36mm, auto);
    gap: 1.2mm !important;
    width: 100% !important;
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  #schedules-container .schedule-month.print-hidden-month {
    display: none !important;
  }

  #dienstplan-heading {
    font-size: 17pt !important;
    line-height: 1.05 !important;
    margin: 0 0 2mm !important;
  }

  .print-meta {
    display: block !important;
    float: right;
    margin-top: -8mm;
    text-align: right;
    font-size: 8pt;
    line-height: 1.1;
    color: #555;
  }

  .schedule-label-legend {
    display: flex !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 1.4mm 2.4mm !important;
    margin: 2mm 0 0 !important;
    padding: 1.4mm 1.8mm !important;
    border: 0.25mm solid #cfcfcf !important;
    border-radius: 1mm !important;
    background: #f8f8f8 !important;
    color: #111 !important;
    font-size: 7.4pt !important;
    line-height: 1.1 !important;
    break-inside: avoid;
    page-break-inside: avoid;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .schedule-label-legend strong,
  .legend-item {
    display: inline-flex !important;
    align-items: center !important;
    white-space: nowrap !important;
  }

  .legend-badge {
    height: 4.2mm !important;
    min-width: 4.2mm !important;
    padding: 0 1.2mm !important;
    border-radius: 0.8mm !important;
    font-size: 6.3pt !important;
    line-height: 1 !important;
    font-weight: 900 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  @supports selector(:has(*)) {
    #schedules-container:has(.schedule-month.active-calendar) .schedule-month:not(.active-calendar) {
      display: none !important;
    }
  }

  .day {
    min-height: 0 !important;
    margin: 0 !important;
    padding: 1.3mm !important;
    border: 0.35mm solid #cfcfcf !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
    cursor: default !important;
    overflow: hidden;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .day.print-hide-leading-empty-row {
    display: none !important;
  }

  .day h3 {
    margin: 0 0 1mm !important;
    padding: 0 0 0.8mm !important;
    border-bottom: 0.25mm solid #d9d9d9 !important;
    font-size: 10.5pt !important;
    line-height: 1 !important;
    color: #000 !important;
  }

  .shift-block {
    margin: 0 0 1mm !important;
    padding: 0 !important;
    border: 0 !important;
    border-top: 0.25mm solid #e2e2e2 !important;
    border-radius: 0 !important;
    background: transparent !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .shift-block:first-of-type {
    border-top: 0 !important;
  }

  .shift-block.fulltime {
    background: #eaf6ed !important;
    border-left: 0.8mm solid #28a745 !important;
    padding-left: 1mm !important;
  }

  .shift-block.lateshift {
    background: #fff4df !important;
    border-left: 0.8mm solid #f0ad4e !important;
    padding-left: 1mm !important;
  }

  .shift-block.parttime {
    background: #eaf1fb !important;
    border-left: 0.8mm solid #007bff !important;
    padding-left: 1mm !important;
  }

  .shift-block h4 {
    margin: 0 0 0.6mm !important;
    padding: 0 !important;
    font-size: 7.8pt !important;
    line-height: 1.05 !important;
    color: #555 !important;
  }

  .shift-block p {
    margin: 0 0 0.5mm !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    font-size: 9.4pt !important;
    line-height: 1.08 !important;
    color: #000 !important;
    word-break: break-word;
    break-inside: avoid;
  }

  .shift-block.fulltime,
  .shift-block.parttime {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 2mm;
    row-gap: 0.4mm;
  }

  .shift-block.fulltime h4,
  .shift-block.parttime h4 {
    grid-column: 1 / -1;
  }

  .shift-block.fulltime p,
  .shift-block.parttime p {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    word-break: normal;
  }

  .shift-block p.hat_urlaub,
  .shift-block p.hat_urlaubswunsch,
  .shift-block p.ist_nv {
    display: flex !important;
    align-items: center !important;
    gap: 0.8mm !important;
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    word-break: normal !important;
  }

  .shift-block p.hat_urlaub .employee-name-with-avatar,
  .shift-block p.hat_urlaubswunsch .employee-name-with-avatar,
  .shift-block p.ist_nv .employee-name-with-avatar {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    width: auto !important;
    overflow: hidden !important;
  }

  .shift-block p.hat_urlaub .employee-name-label,
  .shift-block p.hat_urlaubswunsch .employee-name-label,
  .shift-block p.ist_nv .employee-name-label {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .shift-block p.hat_urlaub .urlaub-badge,
  .shift-block p.hat_urlaubswunsch .urlaubswunsch-badge,
  .shift-block p.ist_nv .nicht-verfuegbar-badge {
    margin-left: auto !important;
    flex: 0 0 auto !important;
    white-space: nowrap !important;
  }

  .shift-block p.hat_urlaub {
    background: #d92323 !important;
    color: #fff !important;
    border: 0.45mm solid #8f1111 !important;
    font-weight: 800 !important;
    padding: 0.8mm 1.1mm !important;
    border-radius: 1mm !important;
    opacity: 1 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .shift-block p.hat_urlaub .urlaub-badge {
    position: static !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-left: auto !important;
    flex: 0 0 auto !important;
    padding: 0.25mm 0.9mm !important;
    background: #fff !important;
    color: #9b0f0f !important;
    border: 0.25mm solid #fff !important;
    border-radius: 0.8mm !important;
    font-size: 6.8pt !important;
    line-height: 1 !important;
    font-weight: 900 !important;
    vertical-align: baseline !important;
  }

  .shift-block p.hat_urlaubswunsch {
    background: #fff2a8 !important;
    color: #453500 !important;
    border: 0.35mm solid #e0b900 !important;
    padding: 0.65mm 1mm !important;
    border-radius: 1mm !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .shift-block p.hat_urlaubswunsch .urlaubswunsch-badge {
    position: static !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-left: auto !important;
    flex: 0 0 auto !important;
    padding: 0.25mm 0.9mm !important;
    background: #ffca00 !important;
    color: #4d3900 !important;
    border: 0.25mm solid #d8a900 !important;
    border-radius: 0.8mm !important;
    font-size: 6.8pt !important;
    line-height: 1 !important;
    font-weight: 900 !important;
  }

  .shift-block p.ist_nv {
    background: #edf0f2 !important;
    color: #1f2933 !important;
    border: 0.35mm solid #9aa3aa !important;
    padding: 0.65mm 1mm !important;
    border-radius: 1mm !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .shift-block p.ist_nv .nicht-verfuegbar-badge {
    position: static !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-left: auto !important;
    flex: 0 0 auto !important;
    padding: 0.25mm 0.9mm !important;
    background: #6c757d !important;
    color: #fff !important;
    border: 0.25mm solid #596168 !important;
    border-radius: 0.8mm !important;
    font-size: 6.8pt !important;
    line-height: 1 !important;
    font-weight: 900 !important;
  }

  .shift-block {
    --print-employee-row-height: 4.8mm;
  }

  .shift-block p,
  .shift-block p.hat_urlaub,
  .shift-block p.hat_urlaubswunsch,
  .shift-block p.ist_nv {
    display: flex !important;
    align-items: center !important;
    height: var(--print-employee-row-height) !important;
    min-height: var(--print-employee-row-height) !important;
    max-height: var(--print-employee-row-height) !important;
    box-sizing: border-box !important;
    line-height: 1 !important;
    overflow: hidden !important;
  }

  .shift-block p.hat_urlaub,
  .shift-block p.hat_urlaubswunsch,
  .shift-block p.ist_nv {
    padding: 0 0.85mm !important;
  }

  #employeeStatsContainer {
    break-before: page;
    page-break-before: always;
    margin-top: 0 !important;
  }
}

@media screen {
  .day.turnus-check-ok,
  .day.turnus-check-mismatch,
  .day.friday-turnus-check-ok,
  .day.friday-turnus-check-mismatch {
    position: relative;
  }

  .day.turnus-check-ok,
  .day.friday-turnus-check-ok {
    outline: 2px solid rgba(34, 139, 90, 0.5);
    outline-offset: -2px;
    box-shadow: inset 0 0 0 1px rgba(34, 139, 90, 0.18), 0 8px 18px rgba(34, 139, 90, 0.08);
  }

  .day.turnus-check-mismatch,
  .day.friday-turnus-check-mismatch {
    outline: 2px solid rgba(214, 79, 79, 0.78);
    outline-offset: -2px;
    box-shadow: inset 0 0 0 1px rgba(214, 79, 79, 0.24), 0 8px 20px rgba(214, 79, 79, 0.12);
  }

  .turnus-check-badge,
  .friday-turnus-check-badge {
    position: absolute;
    top: 34px;
    right: 8px;
    z-index: 7;
    max-width: calc(100% - 16px);
    padding: 3px 7px;
    border-radius: var(--ui-radius);
    border: 1px solid currentColor;
    font-size: 0.68rem;
    font-weight: 800;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
  }

  .friday-turnus-check-badge {
    top: 58px;
  }

  .turnus-check-badge--ok,
  .friday-turnus-check-badge--ok {
    background: rgba(232, 247, 238, 0.94);
    color: #1d6d45;
  }

  .turnus-check-badge--mismatch,
  .friday-turnus-check-badge--mismatch {
    background: rgba(255, 236, 236, 0.96);
    color: #a72626;
  }

  .turnus-check-overlay,
  .friday-turnus-check-overlay {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1800;
    width: min(360px, calc(100vw - 32px));
    padding: 12px;
    border: 1px solid var(--border-soft);
    border-radius: var(--ui-radius);
    background: rgba(255, 255, 255, 0.96);
    color: #25312c;
    box-shadow: 0 14px 36px rgba(25, 34, 30, 0.18);
    backdrop-filter: blur(12px);
  }

  .friday-turnus-check-overlay {
    bottom: 154px;
  }

  .turnus-check-overlay-head,
  .turnus-check-overlay-summary,
  .friday-turnus-check-overlay-head,
  .friday-turnus-check-overlay-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }

  .turnus-check-overlay-head strong {
    font-size: 0.95rem;
  }

  .friday-turnus-check-overlay-head strong {
    font-size: 0.95rem;
  }

  .turnus-check-overlay-close,
  .friday-turnus-check-overlay-close {
    min-height: 28px;
    padding: 5px 8px;
    border: 1px solid rgba(31, 110, 212, 0.22);
    border-radius: var(--ui-radius);
    background: #f4f8ff;
    color: #1f5ca8;
    font-size: 0.76rem;
    font-weight: 800;
    cursor: pointer;
  }

  .turnus-check-overlay p,
  .friday-turnus-check-overlay p {
    margin: 8px 0;
    color: #5a665f;
    font-size: 0.8rem;
    line-height: 1.35;
  }

  .turnus-check-overlay-summary span,
  .friday-turnus-check-overlay-summary span {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 4px 7px;
    border-radius: var(--ui-radius);
    background: #eef5ff;
    color: #1f5ca8;
    font-size: 0.76rem;
    font-weight: 800;
  }

  .turnus-check-overlay ul,
  .friday-turnus-check-overlay ul {
    margin: 9px 0 0;
    padding: 0;
    list-style: none;
  }

  .turnus-check-overlay li,
  .friday-turnus-check-overlay li {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 0;
    border-top: 1px solid rgba(37, 49, 44, 0.1);
    font-size: 0.78rem;
  }

  .turnus-check-overlay li span,
  .friday-turnus-check-overlay li span {
    text-align: right;
  }

  .turnus-check-overlay-ok,
  .friday-turnus-check-overlay-ok {
    margin-top: 9px;
    padding: 8px;
    border-radius: var(--ui-radius);
    background: rgba(232, 247, 238, 0.92);
    color: #1d6d45;
    font-size: 0.8rem;
    font-weight: 800;
  }

  [data-theme="dark"] .turnus-check-overlay,
  [data-theme="dark"] .friday-turnus-check-overlay {
    background: rgba(21, 28, 25, 0.96);
    color: #eef6f1;
    border-color: rgba(138, 184, 255, 0.22);
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.36);
  }

  [data-theme="dark"] .turnus-check-overlay p,
  [data-theme="dark"] .friday-turnus-check-overlay p {
    color: #aebdb5;
  }

  [data-theme="dark"] .turnus-check-overlay-close,
  [data-theme="dark"] .turnus-check-overlay-summary span,
  [data-theme="dark"] .friday-turnus-check-overlay-close,
  [data-theme="dark"] .friday-turnus-check-overlay-summary span {
    background: rgba(71, 127, 196, 0.18);
    border-color: rgba(138, 184, 255, 0.28);
    color: #cfe3ff;
  }

  [data-theme="dark"] .turnus-check-badge--ok,
  [data-theme="dark"] .friday-turnus-check-badge--ok {
    background: rgba(41, 94, 66, 0.94);
    color: #cff1db;
  }

  [data-theme="dark"] .turnus-check-badge--mismatch,
  [data-theme="dark"] .friday-turnus-check-badge--mismatch {
    background: rgba(116, 42, 42, 0.96);
    color: #ffe1e1;
  }
}

@media print {
  .turnus-check-overlay,
  .turnus-check-badge,
  .friday-turnus-check-overlay,
  .friday-turnus-check-badge {
    display: none !important;
  }

  .day.turnus-check-ok,
  .day.turnus-check-mismatch,
  .day.friday-turnus-check-ok,
  .day.friday-turnus-check-mismatch {
    outline: none !important;
    box-shadow: none !important;
  }
}

@media screen {
  .shift-block p.ist_nv .nicht-verfuegbar-reason {
    margin-left: auto;
    min-width: 0;
    max-width: 48%;
    flex: 0 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #52616b;
    font-size: 0.72em;
    font-weight: 700;
  }

  .shift-block p.ist_nv .nicht-verfuegbar-reason + .nicht-verfuegbar-badge {
    margin-left: 4px;
  }

  [data-theme="dark"] .shift-block p.ist_nv .nicht-verfuegbar-reason {
    color: #c8d2da;
  }
}

@media print {
  .shift-block p.ist_nv .nicht-verfuegbar-reason {
    display: inline-flex !important;
    align-items: center !important;
    margin-left: auto !important;
    min-width: 0 !important;
    max-width: 42% !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    color: #1f2933 !important;
    font-size: 6.6pt !important;
    font-weight: 800 !important;
  }

  .shift-block p.ist_nv .nicht-verfuegbar-reason + .nicht-verfuegbar-badge {
    margin-left: 0.8mm !important;
  }
}

@media screen {
  header .controls [data-quick-info]:is(:hover, :focus-visible)::after {
    position: fixed;
    z-index: 12000;
    top: var(--quick-info-y, calc(var(--top-menu-offset) + 4px));
    left: var(--quick-info-x, 50vw);
    right: auto;
    max-width: min(260px, calc(100vw - 20px));
    transform: translateX(-50%);
  }

  header .controls [data-quick-info]:is(:hover, :focus-visible)::before {
    position: fixed;
    z-index: 12001;
    top: calc(var(--quick-info-y, calc(var(--top-menu-offset) + 4px)) - 5px);
    left: var(--quick-info-arrow-x, var(--quick-info-x, 50vw));
    right: auto;
    transform: translateX(-50%) rotate(45deg);
  }
}
