.loading-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  width: 100%;
  text-align: center;
  color: #666;
}

.loading-indicator i {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.loading-indicator p {
  font-size: 1rem;
  margin: 0;
}

.no-tasks {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem;
  width: 100%;
  text-align: center;
  color: #666;
  grid-column: 1 / -1;
}

.no-tasks i {
  font-size: 3rem;
  margin-bottom: 1rem;
  color: #ccc;
}

.no-tasks p {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
}

.no-tasks .btn {
  margin-top: 1rem;
}

/* تنسيق جدول المهام */
.tasks-table-container {
  margin-top: 1.5rem;
  overflow-x: auto;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  max-width: 100%;
}

.tasks-table {
  width: 100%;
  border-collapse: collapse;
  direction: rtl;
  text-align: right;
}

.tasks-table thead {
  background-color: #f8f9fa;
  border-bottom: 2px solid #e9ecef;
}

.tasks-table th {
  padding: 1rem;
  font-weight: 600;
  color: #495057;
  position: sticky;
  top: 0;
  background-color: #f8f9fa;
  z-index: 10;
}

.tasks-table tbody tr {
  border-bottom: 1px solid #e9ecef;
  transition: background-color 0.2s ease;
}

.tasks-table tbody tr:hover {
  background-color: #f8f9fa;
}

.tasks-table td {
  padding: 1rem;
  vertical-align: middle;
}

.task-row.task-completed {
  background-color: rgba(40, 167, 69, 0.05);
}

.task-row.task-completed .task-title-cell {
  text-decoration: line-through;
  color: #6c757d;
}

.task-title-cell {
  font-weight: 600;
  color: var(--text-color);
  max-width: 200px;
}

.task-description-cell {
  max-width: 300px;
}

.description-content {
  color: #666;
  line-height: 1.5;
  max-height: 3em;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.task-priority {
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: bold;
  display: inline-block;
  text-align: center;
  min-width: 80px;
}

.task-priority.high {
  background-color: rgba(220, 53, 69, 0.1);
  color: var(--danger-color);
}

.task-priority.medium {
  background-color: rgba(255, 193, 7, 0.1);
  color: var(--warning-color);
}

.task-priority.low {
  background-color: rgba(40, 167, 69, 0.1);
  color: var(--success-color);
}

.task-date-cell, .task-assignee-cell {
  white-space: nowrap;
  color: #6c757d;
}

.task-date-cell i, .task-assignee-cell i {
  margin-left: 0.5rem;
  color: var(--primary-color);
}

.task-progress-cell {
  width: 150px;
}

.task-progress {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-direction: column;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background-color: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
}

.progress {
  height: 100%;
  background-color: var(--primary-color);
  border-radius: 4px;
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 0.8rem;
  color: #6c757d;
  font-weight: 600;
}

.task-actions-cell {
  width: 120px;
}

.task-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.action-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.2s ease;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.action-btn:hover {
  transform: scale(1.2);
  background-color: #f8f9fa;
}

.edit-btn {
  color: var(--primary-color);
}

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

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

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

.task-filter select {
  padding: 0.5rem 1rem;
  border-radius: 4px;
  border: 1px solid #ddd;
  background-color: #fff;
  font-family: 'Tajawal', sans-serif;
  cursor: pointer;
}

@media (max-width: 768px) {
  .task-controls {
    flex-direction: column;
    gap: 1rem;
    align-items: stretch;
  }
  
  .tasks-table th,
  .tasks-table td {
    padding: 0.75rem 0.5rem;
    font-size: 0.9rem;
  }
  
  .task-description-cell {
    max-width: 150px;
  }
  
  .task-title-cell {
    max-width: 120px;
  }
  
  .task-priority {
    min-width: 60px;
    padding: 0.2rem 0.5rem;
    font-size: 0.7rem;
  }
  
  .task-progress-cell {
    width: 100px;
  }
  
  .task-actions-cell {
    width: 90px;
  }
  
  .action-btn {
    width: 25px;
    height: 25px;
    font-size: 0.9rem;
  }
}

@media (max-width: 576px) {
  .tasks-table {
    display: block;
  }
  
  .tasks-table thead {
    display: none;
  }
  
  .tasks-table tbody {
    display: block;
  }
  
  .tasks-table tr {
    display: block;
    margin-bottom: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1rem;
  }
  
  .tasks-table td {
    display: flex;
    padding: 0.5rem 0;
    border: none;
    text-align: right;
  }
  
  .tasks-table td::before {
    content: attr(data-label);
    font-weight: 600;
    margin-left: 1rem;
    min-width: 100px;
  }
  
  .task-title-cell,
  .task-description-cell {
    max-width: 100%;
  }
  
  .task-actions-cell {
    justify-content: flex-start;
    width: 100%;
  }
  
  .task-actions {
    justify-content: flex-start;
  }
}