/* Resources Page Styling */

.resources-section {
  padding: 3rem 1rem;
  background: #f9fafb;
}

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

.resource-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  border-left: 4px solid #667eea;
}

.resource-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(102, 126, 234, 0.15);
  border-left-color: #764ba2;
}

.resource-icon {
  font-size: 2rem;
  color: #667eea;
}

.resource-content h3 {
  margin: 0;
  font-size: 1.1rem;
  color: #1f2937;
  font-weight: 600;
  line-height: 1.4;
}

.resource-content p {
  margin: 0.5rem 0 0 0;
  color: #6b7280;
  font-size: 0.95rem;
  line-height: 1.5;
}

.resource-meta {
  display: flex;
  gap: 0.75rem;
  margin-top: auto;
  flex-wrap: wrap;
}

.level-badge,
.type-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.level-badge {
  background: #e0e7ff;
  color: #4f46e5;
}

.type-badge {
  background: #f0fdf4;
  color: #16a34a;
}

/* Filter Section */
.filter-section {
  padding: 2rem 1rem;
  background: white;
  border-bottom: 1px solid #e5e7eb;
}

.filter-section h2 {
  margin: 0 0 1.5rem 0;
  color: #1f2937;
  font-size: 1.3rem;
}

.filter-buttons {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-start;
}

.filter-group label {
  font-weight: 600;
  color: #374151;
  min-width: 100%;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-btn {
  padding: 0.5rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background: white;
  color: #4b5563;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  white-space: nowrap;
}

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

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

/* Hero Section Override for Resources */
.hero-section .search-bar {
  max-width: 500px;
  margin: 0 auto;
  position: relative;
}

.search-bar input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  background: white;
}

.search-bar i {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
}

/* Related Section */
.related-section {
  padding: 3rem 1rem;
  background: white;
}

.related-section h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: #1f2937;
}

.related-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  max-width: 900px;
  margin: 0 auto;
}

.related-card {
  text-decoration: none;
  color: inherit;
  padding: 1.5rem;
  border-radius: 12px;
  background: #f9fafb;
  text-align: center;
  transition: all 0.3s ease;
  border: 1px solid #e5e7eb;
}

.related-card:hover {
  background: white;
  box-shadow: 0 8px 16px rgba(102, 126, 234, 0.12);
  transform: translateY(-3px);
  border-color: #667eea;
}

.related-card i {
  font-size: 2.5rem;
  color: #667eea;
  margin-bottom: 1rem;
  display: block;
}

.related-card h3 {
  margin: 0.5rem 0;
  color: #1f2937;
  font-size: 1.1rem;
}

.related-card p {
  margin: 0.5rem 0 0 0;
  color: #6b7280;
  font-size: 0.9rem;
}

/* Dark Mode Support */
:root.dark-mode .resources-section,
:root.dark-mode body .resources-section {
  background: #1f2937;
}

:root.dark-mode .resource-card,
:root.dark-mode body .resource-card {
  background: #2d3748;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

:root.dark-mode .resource-card:hover,
:root.dark-mode body .resource-card:hover {
  background: linear-gradient(135deg, #3d4a63 0%, #2d3748 100%);
  box-shadow: 0 12px 24px rgba(102, 126, 234, 0.3);
}

:root.dark-mode .resource-content h3,
:root.dark-mode body .resource-content h3 {
  color: #f9fafb;
}

:root.dark-mode .resource-content p,
:root.dark-mode body .resource-content p {
  color: #d1d5db;
}

:root.dark-mode .filter-section,
:root.dark-mode body .filter-section {
  background: #111827;
  border-bottom-color: #374151;
}

:root.dark-mode .filter-section h2,
:root.dark-mode body .filter-section h2 {
  color: #f9fafb;
}

:root.dark-mode .filter-btn,
:root.dark-mode body .filter-btn {
  background: #2d3748;
  color: #d1d5db;
  border-color: #4b5563;
}

:root.dark-mode .filter-btn:hover,
:root.dark-mode body .filter-btn:hover {
  background: #3d4a63;
  border-color: #667eea;
  color: #f9fafb;
}

:root.dark-mode .filter-btn.active,
:root.dark-mode body .filter-btn.active {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

:root.dark-mode .related-card,
:root.dark-mode body .related-card {
  background: #2d3748;
}

:root.dark-mode .related-card:hover,
:root.dark-mode body .related-card:hover {
  background: #3d4a63;
  box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

:root.dark-mode .related-card h3,
:root.dark-mode body .related-card h3 {
  color: #f9fafb;
}

:root.dark-mode .related-card p,
:root.dark-mode body .related-card p {
  color: #d1d5db;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .resources-grid {
    grid-template-columns: 1fr;
  }

  .filter-group {
    flex-direction: column;
  }

  .filter-group label {
    min-width: auto;
  }

  .related-links {
    grid-template-columns: 1fr;
  }

  .filter-buttons {
    gap: 1rem;
  }

  .filter-section {
    padding: 1.5rem 1rem;
  }
}
