/* News Page Specific Styles */

/* Search & Filters Section */
.news-filter-section {
  background-color: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 4rem 0 2rem;
}

.news-search-bar {
  max-width: 600px;
  margin: 0 auto 2.5rem;
  position: relative;
}

.news-search-input {
  width: 100%;
  padding: 1rem 1.5rem 1rem 3rem;
  border: 1px solid var(--border);
  background-color: var(--background);
  border-radius: 30px;
  font-size: 1rem;
  color: var(--text-dark);
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.news-search-input:focus {
  border-color: var(--accent);
  background-color: #fff;
  box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.12);
}

.news-search-icon {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--text-light);
  pointer-events: none;
}

.news-categories {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.category-btn {
  background-color: var(--background);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.6rem 1.5rem;
  border-radius: 25px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition);
}

.category-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background-color: #fff;
}

.category-btn.active {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 4px 10px rgba(217, 119, 6, 0.25);
}

/* News Grid Section */
.news-grid-section {
  background-color: var(--background);
  min-height: 400px;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 2.5rem;
}

.news-card {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.news-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(217, 119, 6, 0.15);
}

.news-card-image-wrapper {
  position: relative;
  height: 220px;
  overflow: hidden;
  background-color: var(--primary);
}

.news-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.news-card:hover .news-card-img {
  transform: scale(1.04);
}

.news-card-badge {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  background-color: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 1rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.news-card-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.news-card-date {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 0.75rem;
  font-weight: 500;
}

.news-card h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  line-height: 1.35;
  color: var(--text-dark);
}

.news-card-excerpt {
  font-size: 0.95rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
  line-height: 1.6;
  flex: 1;
}

.news-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  background: none;
  cursor: pointer;
  padding: 0;
  align-self: flex-start;
  transition: var(--transition);
}

.news-card-link:hover {
  color: var(--accent-hover);
  gap: 0.75rem;
}

/* Empty State */
.news-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 5rem 2rem;
}

.news-empty-state h3 {
  font-size: 1.5rem;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

.news-empty-state p {
  color: var(--text-light);
}

/* Modal Overlay */
.news-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.news-modal.show {
  display: flex;
  opacity: 1;
}

.news-modal-content {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  width: 100%;
  max-width: 800px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  position: relative;
  transform: translateY(30px);
  transition: transform 0.3s ease;
}

.news-modal.show .news-modal-content {
  transform: translateY(0);
}

.news-modal-close-btn {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--border);
  color: var(--text-dark);
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.news-modal-close-btn:hover {
  background-color: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: rotate(90deg);
}

.news-modal-image-wrapper {
  height: 350px;
  width: 100%;
  position: relative;
}

.news-modal-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-modal-body {
  padding: 3rem;
}

.news-modal-meta {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.5rem;
}

.news-modal-badge {
  background-color: rgba(217, 119, 6, 0.1);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 1rem;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.news-modal-date {
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: 500;
}

.news-modal-body h2 {
  font-size: 2.25rem;
  margin-bottom: 2rem;
  color: var(--text-dark);
  line-height: 1.25;
}

.news-modal-text {
  font-size: 1.05rem;
  color: var(--text);
  line-height: 1.8;
}

.news-modal-text p {
  margin-bottom: 1.5rem;
}

/* Responsive News Styles */
@media (max-width: 768px) {
  .news-grid {
    grid-template-columns: 1fr;
  }
  .news-categories {
    gap: 0.5rem;
  }
  .category-btn {
    padding: 0.5rem 1.25rem;
    font-size: 0.85rem;
  }
  .news-modal-body {
    padding: 2rem 1.5rem;
  }
  .news-modal-body h2 {
    font-size: 1.75rem;
  }
  .news-modal-image-wrapper {
    height: 220px;
  }
  .news-modal {
    padding: 1rem;
  }
}

/* ==========================================================================
   Inline Article Images Styles (Cloudinary)
   ========================================================================== */
.news-body-image {
  margin: 2rem 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.news-body-image img {
  width: 100%;
  height: auto;
  display: block;
}

