/* Today Page Specific Styles - Cosmic Theme */

/* Today-specific table columns */
.col-scheduled {
  width: 15%;
}

.task-scheduled-at-cell {
  text-align: center;
  padding: 12px 16px;
}

.task-scheduled-at {
  font-weight: 600;
  color: #495057;
  font-size: 0.85rem;
}

.task-scheduled-at.today-scheduled-at {
  color: #007bff;
  font-weight: 700;
  background-color: #e3f2fd;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #bbdefb;
}

.task-scheduled-at.past-scheduled-at {
  color: #dc3545;
  font-weight: 700;
  background-color: #f8d7da;
  padding: 4px 8px;
  border-radius: 4px;
  border: 1px solid #f5c6cb;
}

/* Task subtitle rows for grouping - Original cosmic theme but thinner */
.tasks-table .task-subtitle-row {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%) !important;
  border-bottom: 2px solid #2a2a3e !important;
  border-top: 1px solid #2a2a3e !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.tasks-table .task-subtitle-row td {
  padding: 12px 20px !important;
  font-weight: 700 !important;
  font-size: 14px !important;
  color: #fff !important;
  text-align: left !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  position: relative;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  background: transparent !important;
}

.tasks-table .task-subtitle-row:first-child {
  border-top: none !important;
}

.tasks-table .task-subtitle-row td::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: linear-gradient(135deg, #7f5fff 0%, #ffd700 100%);
  border-radius: 0 3px 3px 0;
  box-shadow: 0 0 8px rgba(127, 95, 255, 0.5);
}

.tasks-table .section-title {
  font-weight: 700 !important;
  color: #fff !important;
  font-size: 14px !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* Today-specific empty state */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #6c757d;
}

.empty-state h3 {
  background: linear-gradient(45deg, var(--cosmic-white), var(--cosmic-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-size: 1.5rem;
  margin-bottom: 12px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.empty-state p {
  font-size: 1.1rem;
  margin-bottom: 24px;
}

/* Priority arrow styling for today */
.task-priority-arrow {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  flex-shrink: 0;
  border-radius: 50%;
  margin-right: 8px;
  transition: all 0.3s ease;
}

.task-priority-arrow.priority-none {
  background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
  color: white;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
}

.task-priority-arrow.priority-high {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: white;
  box-shadow: 0 0 8px rgba(251, 191, 36, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: starGlow 2s ease-in-out infinite alternate;
}

.task-priority-arrow.priority-medium {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
  box-shadow: 0 0 6px rgba(59, 130, 246, 0.3), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.task-priority-arrow.priority-low {
  background: linear-gradient(135deg, #a78bfa 0%, #8b5cf6 100%);
  color: white;
  box-shadow: 0 0 4px rgba(167, 139, 250, 0.3), 0 2px 4px rgba(0, 0, 0, 0.1);
}

@keyframes starGlow {
  0% { box-shadow: 0 0 8px rgba(251, 191, 36, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1); }
  100% { box-shadow: 0 0 12px rgba(251, 191, 36, 0.6), 0 2px 6px rgba(0, 0, 0, 0.15); }
}

/* Fix task title color visibility */
.task-title-link {
  color: #2c3e50 !important;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.task-title-link:hover {
  color: #007bff !important;
  text-decoration: none;
}

/* Ensure task title cell has proper color */
.task-title-cell {
  color: #2c3e50;
}

.task-title-row {
  display: flex;
  align-items: center;
  color: #2c3e50;
}

/* Today-specific task row styling */
.tasks-table tbody tr.task-row {
  border-left: 4px solid transparent;
  transition: all 0.2s ease;
  background-color: #fff;
  border-bottom: 1px solid #e9ecef;
}

.tasks-table tbody tr.task-row:hover {
  background-color: #f8f9fa;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tasks-table tbody tr.task-row.completed {
  opacity: 0.7;
  background-color: #f8f9fa;
}

.tasks-table tbody tr.task-row.completed .task-title-link {
  text-decoration: line-through;
  color: #6c757d !important;
}

/* Table styling */
.tasks-table {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  border: 1px solid #e9ecef;
}

.tasks-table thead {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.tasks-table thead th {
  color: #495057;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 16px 20px;
  border-bottom: 2px solid #dee2e6;
}

/* Priority legend styling */
.priority-legend {
  margin-top: 2rem;
  padding: 1.5rem;
  background: #f8f9fa;
  border-radius: 12px;
  border: 1px solid #e9ecef;
}

.priority-legend-content h4 {
  margin: 0 0 1rem 0;
  color: #495057;
  font-size: 1.1rem;
  font-weight: 600;
}

.priority-examples {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.priority-example {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.priority-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  border-radius: 50%;
  margin-right: 8px;
}

.priority-icon.priority-high {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  color: white;
  box-shadow: 0 0 8px rgba(251, 191, 36, 0.4), 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: starGlow 2s ease-in-out infinite alternate;
}

.priority-icon.priority-medium {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
  box-shadow: 0 0 6px rgba(59, 130, 246, 0.3), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.priority-icon.priority-low {
  background: linear-gradient(135deg, #a78bfa 0%, #8b5cf6 100%);
  color: white;
  box-shadow: 0 0 4px rgba(167, 139, 250, 0.3), 0 2px 4px rgba(0, 0, 0, 0.1);
}

.priority-icon.priority-none {
  background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
  color: white;
  box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
}

.priority-example span {
  font-size: 0.9rem;
  color: #6c757d;
  font-weight: 500;
}

.priority-explanation {
  margin: 0;
  color: #6c757d;
  font-size: 0.9rem;
  line-height: 1.5;
  font-style: italic;
}

/* Reschedule buttons styling */
.task-reschedule-cell {
  text-align: center;
  padding: 6px 4px;
  width: 100px;
  min-width: 100px;
  max-width: 100px;
}

.reschedule-buttons {
  display: flex;
  flex-direction: row;
  gap: 3px;
  align-items: center;
  justify-content: center;
}

.reschedule-form {
  display: inline-block;
  margin: 0;
  flex: 1;
  min-width: 0;
}

.reschedule-btn {
  padding: 2px 4px;
  border: none;
  border-radius: 2px;
  font-size: 0.65rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  min-width: 0;
  max-width: 100px;
  height: 30px;
  white-space: nowrap;
}

.reschedule-btn.unschedule-btn {
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
  color: white;
}

.reschedule-btn.unschedule-btn:hover {
  background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 123, 255, 0.3);
}

.reschedule-btn.today-btn {
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
  color: white;
}

.reschedule-btn.today-btn:hover {
  background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 123, 255, 0.3);
}

/* Today-specific responsive design */
@media (max-width: 768px) {
  .tasks-table {
    min-width: 600px;
  }
  
  .col-scheduled {
    width: 18%;
  }
  
  .task-scheduled-at {
    font-size: 0.8rem;
  }
  
  .priority-examples {
    gap: 1rem;
  }
  
  .priority-example {
    flex-direction: column;
    text-align: center;
    gap: 0.25rem;
  }
  
  .priority-sample {
    width: 20px;
    height: 12px;
  }
  
  .priority-example span {
    font-size: 0.8rem;
  }
}

/* Loading spinner for today page */
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #007bff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 16px;
}

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

/* Today-specific task status indicators */
.task-status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 8px;
}

.task-status-indicator.scheduled-today {
  background-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.2);
}

.task-status-indicator.past-scheduled {
  background-color: #dc3545;
  box-shadow: 0 0 0 2px rgba(220, 53, 69, 0.2);
}

.task-status-indicator.completed {
  background-color: #28a745;
  box-shadow: 0 0 0 2px rgba(40, 167, 69, 0.2);
}
