/* Journals RSS Style */
.journals-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* Header */
.journals-header {
  text-align: center;
  margin-bottom: 3rem;
  padding: 2rem 0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.page-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.page-subtitle {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  opacity: 0.9;
}

.page-description {
  font-size: 1rem;
  opacity: 0.8;
  margin: 0;
  max-width: 600px;
  margin: 0 auto;
}

/* Filter Controls */
.filter-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.filter-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 0.5rem 1rem;
  border: 2px solid #e0e0e0;
  background: white;
  border-radius: 25px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  font-weight: 500;
}

.filter-btn:hover {
  border-color: #667eea;
  color: #667eea;
}

.filter-btn.active {
  background: #667eea;
  color: white;
  border-color: #667eea;
}

.update-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.9rem;
  color: #666;
}

.refresh-btn {
  padding: 0.5rem 1rem;
  background: #28a745;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.refresh-btn:hover {
  background: #218838;
}

/* Journal Sections */
.journals-grid {
  display: grid;
  gap: 2rem;
}

.journal-section {
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  padding: 2rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.journal-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.journal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.journal-title-section {
  flex: 1;
}

.journal-name {
  font-size: 1.5rem;
  margin: 0 0 0.5rem 0;
  color: #2c3e50;
}

.journal-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.impact-factor {
  background: #e8f5e8;
  color: #2e7d32;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.category-tag {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.relevance-tag {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.relevance-core {
  background: #fff3e0;
  color: #f57c00;
}

.relevance-high {
  background: #e8f5e8;
  color: #2e7d32;
}

.relevance-medium {
  background: #e3f2fd;
  color: #1976d2;
}

.journal-actions {
  display: flex;
  gap: 0.5rem;
}

.journal-link, .rss-link {
  padding: 0.5rem 1rem;
  text-decoration: none;
  border-radius: 6px;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.journal-link {
  background: #667eea;
  color: white;
}

.journal-link:hover {
  background: #5a67d8;
}

.rss-link {
  background: #ff9800;
  color: white;
}

.rss-link:hover {
  background: #f57c00;
}

.journal-description {
  margin-bottom: 1.5rem;
  color: #5a6c7d;
  line-height: 1.6;
}

/* Articles Container */
.articles-container {
  border-top: 1px solid #e0e0e0;
  padding-top: 1.5rem;
}

.loading-indicator {
  text-align: center;
  padding: 2rem;
  color: #666;
}

.loading-indicator i {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  display: block;
}

.articles-grid {
  display: grid;
  gap: 1rem;
}

.article-card {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 1.5rem;
  border-left: 4px solid #667eea;
  transition: all 0.3s ease;
  cursor: pointer;
}

.article-card:hover {
  background: #e9ecef;
  transform: translateX(5px);
}

.article-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.5rem 0;
  color: #2c3e50;
  line-height: 1.4;
}

.article-authors {
  font-size: 0.9rem;
  color: #6c757d;
  margin-bottom: 0.5rem;
}

.article-date {
  font-size: 0.85rem;
  color: #868e96;
  margin-bottom: 1rem;
}

.article-abstract {
  font-size: 0.9rem;
  color: #5a6c7d;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.article-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.article-tag {
  background: #e3f2fd;
  color: #1976d2;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
}

.ai-summary-badge {
  background: #e8f5e8;
  color: #2e7d32;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}



/* Article Actions */
.article-actions {
  margin-top: 1rem;
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.read-full-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.read-full-btn.primary-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.read-full-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
}

.read-full-btn:disabled {
  background: #e2e8f0;
  color: #a0aec0;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.read-full-btn:disabled:hover {
  transform: none;
  box-shadow: none;
}

.read-full-btn i {
  font-size: 0.9em;
}

/* Journal Categories Section */
.journal-categories {
  margin-top: 4rem;
  padding: 3rem 1rem;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  border-radius: 16px;
}

.journal-categories .container {
  max-width: 1200px;
  margin: 0 auto;
}

.journal-categories .section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2.5rem;
  color: #2c3e50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.journal-categories .section-title i {
  color: #667eea;
  font-size: 1.8rem;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.category-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border: 1px solid rgba(102, 126, 234, 0.1);
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  border-color: rgba(102, 126, 234, 0.3);
}

.category-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #f1f3f4;
}

.category-header i {
  font-size: 1.2rem;
  color: #667eea;
  width: 24px;
  text-align: center;
}

.category-header h3 {
  margin: 0;
  font-size: 1.2rem;
  color: #2c3e50;
  font-weight: 600;
}

.category-journals {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.category-journals .journal-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem;
  background: #f8f9fa;
  border-radius: 8px;
  text-decoration: none;
  color: #495057;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

.category-journals .journal-link:hover {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  transform: translateX(4px);
  border-color: #667eea;
}

.if-badge {
  background: rgba(102, 126, 234, 0.1);
  color: #667eea;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.category-journals .journal-link:hover .if-badge {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}

/* Responsive design for categories */
@media (max-width: 768px) {
  .categories-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .journal-categories {
    margin-top: 2rem;
    padding: 2rem 1rem;
  }
  
  .journal-categories .section-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
  }
  
  .category-card {
    padding: 1rem;
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .journals-container {
    padding: 1rem 0.5rem;
  }
  
  .page-title {
    font-size: 2rem;
  }
  
  .filter-controls {
    flex-direction: column;
    align-items: stretch;
  }
  
  .filter-buttons {
    justify-content: center;
  }
  
  .journal-header {
    flex-direction: column;
    gap: 1rem;
  }
  
  .journal-actions {
    align-self: flex-start;
  }
  
  .journal-meta {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }
}

/* Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.journal-section {
  animation: fadeIn 0.6s ease-out;
}

.article-card {
  animation: fadeIn 0.4s ease-out;
}

/* Hidden state for filtering */
.journal-section.hidden {
  display: none;
}
