.activityHistory-page .form-section .form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

/* --- Container da Lista de Atividades --- */
.activityHistory-page .activities-list {
  margin-top: 30px;
  border-top: 1px solid #e1e5e9;
  padding-top: 20px;
}

/* --- Item de Atividade Individual --- */
.activityHistory-page .activity-item {
  display: flex;
  align-items: flex-start;
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  background: #ffffff;
  transition: box-shadow 0.2s ease-in-out;
}

.activityHistory-page .activity-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Ícone (O círculo colorido) */
.activityHistory-page .activity-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 16px;
  font-size: 16px;
}

/* Conteúdo (Texto) */
.activityHistory-page .activity-content {
  flex-grow: 1;
  width: calc(100% - 56px);
}

.activityHistory-page .activity-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
  flex-wrap: wrap;
  gap: 10px;
}

.activityHistory-page .activity-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: #343a40;
}

.activityHistory-page .activity-time {
  font-size: 0.8rem;
  color: #6c757d;
  flex-shrink: 0;
}

.activityHistory-page .activity-description {
  font-size: 0.9rem;
  color: #495057;
  margin-bottom: 8px;
  word-wrap: break-word;
}

.activityHistory-page .activity-meta {
  font-size: 0.8rem;
  color: #6c757d;
}
.activityHistory-page .activity-meta i {
  margin-right: 4px;
}

.activityHistory-page .activity-success .activity-icon {
  background-color: #d1fae5;
  color: #065f46;
}
.activityHistory-page .activity-info .activity-icon {
  background-color: #dbeafe;
  color: #1e40af;
}
.activityHistory-page .activity-primary .activity-icon {
  background-color: #e0e7ff;
  color: #3730a3;
}
.activityHistory-page .activity-warning .activity-icon {
  background-color: #fef3c7;
  color: #92400e;
}
.activityHistory-page .activity-danger .activity-icon {
  background-color: #fee2e2;
  color: #991b1b;
}
.activityHistory-page .activity-default .activity-icon {
  background-color: #f3f4f6;
  color: #4b5563;
}

.activityHistory-page .loading-placeholder,
.activityHistory-page .no-activities-message {
  text-align: center;
  padding: 60px 20px;
  color: #6c757d;
  background-color: #f8f9fa;
  border-radius: 8px;
  border: 1px dashed #dee2e6;
}

.activityHistory-page .loading-placeholder i {
  font-size: 28px;
  margin-bottom: 15px;
  animation: spin 1s linear infinite;
}

.activityHistory-page .no-activities-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  color: #495057;
}

.activityHistory-page .no-activities-message h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #343a40;
  margin-bottom: 5px;
}
.activityHistory-page .no-activities-message p {
  font-size: 0.95rem;
  margin: 0;
}

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

.activityHistory-page .pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 25px;
  padding-top: 15px;
  border-top: 1px solid #e1e5e9;
}

.activityHistory-page .pagination-info {
  font-size: 0.9rem;
  color: #6c757d;
}

@media (max-width: 600px) {
  .activityHistory-page .activity-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }

  .activityHistory-page .activity-time {
    font-size: 0.75rem;
  }
}

.activityHistory-page .form-section {
  background-color: #ffffff;
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 30px;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.03);
}

.activityHistory-page .form-section h3 {
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 1.1rem;
  font-weight: 600;
  color: #343a40;
  padding-bottom: 10px;
  border-bottom: 1px solid #e1e5e9;
}

.activityHistory-page .form-section .form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.activityHistory-page .form-group .form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #495057;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.activityHistory-page .form-section .btn-container {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #f1f3f5;
}

.activityHistory-page #exportActivityBtn {
  background-color: #ffffff;
  color: #343a40;
  border: 1px solid #ced4da;
  font-weight: 500;
  font-size: 0.85rem;
}

.activityHistory-page #exportActivityBtn:hover {
  background-color: #f1f3f5;
  border-color: #adb5bd;
}

/* 7. Estilo dos selects (Bônus) */
.activityHistory-page .form-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  background-color: #ffffff;
  font-size: 0.9rem;
}

/* ==============================================
   ESTILOS DARK MODE
   ============================================== */

/* --- Seções de Formulário (Dark Mode) --- */
html.dark-theme .activityHistory-page .form-section {
  background-color: #2c2c2c;
  border-color: #555555;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.4);
}

html.dark-theme .activityHistory-page .form-section h3 {
  color: #f0f0f0;
  border-bottom-color: #555555;
}

html.dark-theme .activityHistory-page .form-group .form-label {
  color: #b0b0b0;
}

html.dark-theme .activityHistory-page .form-section .btn-container {
  border-top-color: #555555;
}

/* --- Campos de Formulário (Dark Mode) --- */
html.dark-theme .activityHistory-page .form-select {
  background-color: #3a3a3a;
  border-color: #555555;
  color: #f0f0f0;
}

html.dark-theme .activityHistory-page .form-select:focus {
  border-color: #0d6efd;
  background-color: #3a3a3a;
}

/* --- Lista de Atividades (Dark Mode) --- */
html.dark-theme .activityHistory-page .activities-list {
  border-top-color: #555555;
}

/* --- Itens de Atividade (Dark Mode) --- */
html.dark-theme .activityHistory-page .activity-item {
  background-color: #2c2c2c;
  border-color: #555555;
}

html.dark-theme .activityHistory-page .activity-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  background-color: #3a3a3a;
}

html.dark-theme .activityHistory-page .activity-title {
  color: #f0f0f0;
}

html.dark-theme .activityHistory-page .activity-time {
  color: #b0b0b0;
}

html.dark-theme .activityHistory-page .activity-description {
  color: #b0b0b0;
}

html.dark-theme .activityHistory-page .activity-meta {
  color: #b0b0b0;
}

html.dark-theme .activityHistory-page .activity-meta i {
  color: #888888;
}

/* --- Ícones de Atividade (Dark Mode) - Mantém cores mas ajusta opacidade --- */
html.dark-theme .activityHistory-page .activity-success .activity-icon {
  background-color: rgba(209, 250, 229, 0.2);
  color: #10b981;
}

html.dark-theme .activityHistory-page .activity-info .activity-icon {
  background-color: rgba(219, 234, 254, 0.2);
  color: #3b82f6;
}

html.dark-theme .activityHistory-page .activity-primary .activity-icon {
  background-color: rgba(224, 231, 255, 0.2);
  color: #6366f1;
}

html.dark-theme .activityHistory-page .activity-warning .activity-icon {
  background-color: rgba(254, 243, 199, 0.2);
  color: #f59e0b;
}

html.dark-theme .activityHistory-page .activity-danger .activity-icon {
  background-color: rgba(254, 226, 226, 0.2);
  color: #ef4444;
}

html.dark-theme .activityHistory-page .activity-default .activity-icon {
  background-color: rgba(243, 244, 246, 0.15);
  color: #9ca3af;
}

/* --- Loading e Mensagens Vazias (Dark Mode) --- */
html.dark-theme .activityHistory-page .loading-placeholder,
html.dark-theme .activityHistory-page .no-activities-message {
  background-color: #2c2c2c;
  border-color: #555555;
  color: #b0b0b0;
}

html.dark-theme .activityHistory-page .no-activities-icon {
  color: #666666;
}

html.dark-theme .activityHistory-page .no-activities-message h3 {
  color: #f0f0f0;
}

html.dark-theme .activityHistory-page .no-activities-message p {
  color: #b0b0b0;
}

/* --- Paginação (Dark Mode) --- */
html.dark-theme .activityHistory-page .pagination {
  border-top-color: #555555;
}

html.dark-theme .activityHistory-page .pagination-info {
  color: #b0b0b0;
}

/* --- Botão de Exportar (Dark Mode) --- */
html.dark-theme .activityHistory-page #exportActivityBtn {
  background-color: #3a3a3a;
  color: #f0f0f0;
  border-color: #555555;
}

html.dark-theme .activityHistory-page #exportActivityBtn:hover {
  background-color: #444444;
  border-color: #666666;
}
