/* Dienstplan Custom Styles */

.dienstplan-wrapper {
  background: #f9fafb;
  min-height: 100vh;
  padding: 20px;
}

/* Calendar Grid Styling */
.dienstplan-calendar-grid {
  display: grid;
  gap: 1px;
  background: #e5e7eb;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  overflow: hidden;
}

.dienstplan-calendar-cell {
  background: white;
  min-height: 80px;
  padding: 8px;
  position: relative;
  cursor: pointer;
  transition: background-color 0.2s;
}

.dienstplan-calendar-cell:hover {
  background: #f9fafb;
}

.dienstplan-calendar-cell.weekend {
  background: #fef3c7;
}

.dienstplan-calendar-cell.holiday {
  background: #fee2e2;
}

.dienstplan-day-number {
  font-weight: 600;
  font-size: 14px;
  color: #374151;
  margin-bottom: 4px;
}

.dienstplan-shift-badge {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  margin: 2px;
  white-space: nowrap;
}

/* Table Styling */
.dienstplan-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.dienstplan-table th {
  background: #f3f4f6;
  padding: 12px;
  text-align: left;
  font-weight: 600;
  color: #374151;
  border-bottom: 2px solid #e5e7eb;
}

.dienstplan-table td {
  padding: 12px;
  border-bottom: 1px solid #e5e7eb;
}

.dienstplan-table tr:last-child td {
  border-bottom: none;
}

.dienstplan-table tr:hover {
  background: #f9fafb;
}

/* Tab Navigation */
.dienstplan-tabs {
  display: flex;
  gap: 4px;
  background: #f3f4f6;
  padding: 4px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.dienstplan-tab {
  flex: 1;
  padding: 10px 16px;
  background: transparent;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.dienstplan-tab:hover {
  background: #e5e7eb;
  color: #374151;
}

.dienstplan-tab.active {
  background: white;
  color: #6366f1;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Modal Styling */
.dienstplan-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}

.dienstplan-modal {
  background: white;
  border-radius: 12px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

/* Button Styling */
.btn {
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background: #6366f1;
  color: white;
}

.btn-primary:hover {
  background: #4f46e5;
}

.btn-success {
  background: #10b981;
  color: white;
}

.btn-success:hover {
  background: #059669;
}

.btn-danger {
  background: #ef4444;
  color: white;
}

.btn-danger:hover {
  background: #dc2626;
}

.btn-secondary {
  background: #e5e7eb;
  color: #374151;
}

.btn-secondary:hover {
  background: #d1d5db;
}

/* Input Styling */
.dienstplan-input,
.dienstplan-select {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 14px;
  transition: border-color 0.2s;
}

.dienstplan-input:focus,
.dienstplan-select:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* Warning/Alert Styling */
.dienstplan-warning {
  background: #fef3c7;
  border: 1px solid #fbbf24;
  border-radius: 6px;
  padding: 12px;
  margin: 8px 0;
  display: flex;
  align-items: start;
  gap: 8px;
}

.dienstplan-error {
  background: #fee2e2;
  border: 1px solid #f87171;
  border-radius: 6px;
  padding: 12px;
  margin: 8px 0;
  display: flex;
  align-items: start;
  gap: 8px;
}

.dienstplan-success {
  background: #d1fae5;
  border: 1px solid #6ee7b7;
  border-radius: 6px;
  padding: 12px;
  margin: 8px 0;
  display: flex;
  align-items: start;
  gap: 8px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .dienstplan-wrapper {
    padding: 10px;
  }
  
  .dienstplan-calendar-cell {
    min-height: 60px;
    padding: 4px;
  }
  
  .dienstplan-day-number {
    font-size: 12px;
  }
  
  .dienstplan-shift-badge {
    font-size: 10px;
    padding: 1px 4px;
  }
  
  .dienstplan-tabs {
    flex-direction: column;
  }
}

/* Print Styles */
@media print {
  .dienstplan-wrapper {
    background: white;
    padding: 0;
  }
  
  .dienstplan-tabs,
  .btn,
  button {
    display: none !important;
  }
  
  .dienstplan-calendar-cell {
    break-inside: avoid;
  }
}

/* Loading Spinner */
.dienstplan-spinner {
  border: 3px solid #f3f4f6;
  border-top: 3px solid #6366f1;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 40px auto;
}

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

/* Popup Menu */
.dienstplan-popup {
  position: absolute;
  background: white;
  border-radius: 8px;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 8px;
  z-index: 1000;
  min-width: 200px;
}

.dienstplan-popup-item {
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background-color 0.2s;
}

.dienstplan-popup-item:hover {
  background: #f3f4f6;
}

/* Statistics Cards */
.dienstplan-stat-card {
  background: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.dienstplan-stat-label {
  color: #6b7280;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
}

.dienstplan-stat-value {
  font-size: 28px;
  font-weight: 700;
  color: #111827;
}

.dienstplan-progress-bar {
  width: 100%;
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 8px;
}

.dienstplan-progress-fill {
  height: 100%;
  background: #6366f1;
  transition: width 0.3s;
}
