/* ====================================
   NEWSROOM PAGE - MODERN DESIGN (SAME AS BLOG)
   ==================================== */

/* Newsroom Hero Section */
.hero.hero-newsroom {
  position: relative;
  background: url('/assets/images/newsroompage-hero-bg.png') center/cover
    no-repeat;
  color: #ffffff;
  padding: 8rem 0 6rem;
  min-height: 60vh;
  display: flex;
  align-items: center;
}

.hero.hero-newsroom h1 {
  font-family: var(--font-family-heading);
  font-weight: 700;
  font-size: 68px;
  line-height: 1.1;
  margin: 0 0 16px 0;
  color: #ffffff;
}

.hero.hero-newsroom h3 {
  font-family: var(--font-family-body);
  font-weight: 400;
  font-size: 18px;
  line-height: 1.3;
  margin: 0 0 32px 0;
  color: #ffffff;
}

/* Search Form Styling */
.hero.hero-newsroom .article-search-form {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
}

/* Newsroom Content Sections */
#headlinePost {
  padding: 80px 0 40px;
  background: var(--color-white);
}

#featuredArticles {
  padding: 40px 0 80px;
  background: var(--color-gray);
}

#allArticles {
  padding: 80px 0;
  background: var(--color-white);
}

#headlinePost h2,
#featuredArticles h2,
#allArticles h2 {
  color: var(--color-primary);
  font-size: 48px;
  font-weight: 700;
  margin-bottom: 40px;
  text-align: center;
  font-family: var(--font-family-heading);
}

/* Latest Article Card (Horizontal Layout) */
.latest-article-card {
  display: flex;
  background: var(--color-white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-bottom: 32px;
  align-items: center;
}

.latest-article-image {
  width: 400px;
  height: 280px;
  object-fit: cover;
  flex-shrink: 0;
}

.latest-article-content {
  padding: 40px;
  flex: 1;
}

.latest-article-content .article-date {
  color: var(--color-primary);
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
  font-family: var(--font-family-body);
}

.latest-article-content h3 {
  color: var(--color-primary);
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
  font-family: var(--font-family-heading);
}

/* Article Cards (Grid Layout) */
.article-card {
  background: var(--color-white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  height: 100%;
  cursor: pointer;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.article-image {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

.article-card-content {
  padding: 24px;
}

.article-card-content .article-date {
  color: var(--color-primary);
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  font-family: var(--font-family-body);
}

.article-card h4 {
  color: var(--color-primary);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  font-family: var(--font-family-heading);
}

/* Show More Button */
.show-more-btn {
  background: var(--color-white);
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  border-radius: 50px;
  padding: 14px 40px;
  font-size: 18px;
  font-weight: 600;
  font-family: var(--font-family-body);
  transition: all 0.3s ease;
  cursor: pointer;
  display: block;
  margin: 0 auto;
}

.show-more-btn:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

/* Fade-in animation for articles */
.article-container {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
}

.article-container.fade-in {
  opacity: 1;
  transform: translateY(0);
}

.article-container.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger animation for multiple articles */
.article-container.fade-in:nth-child(1) {
  transition-delay: 0.1s;
}
.article-container.fade-in:nth-child(2) {
  transition-delay: 0.2s;
}
.article-container.fade-in:nth-child(3) {
  transition-delay: 0.3s;
}
.article-container.fade-in:nth-child(4) {
  transition-delay: 0.4s;
}
.article-container.fade-in:nth-child(5) {
  transition-delay: 0.5s;
}
.article-container.fade-in:nth-child(6) {
  transition-delay: 0.6s;
}

/* Algolia Search Styling */
#search .ais-SearchBox {
  max-width: 500px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

#search .ais-SearchBox-form {
  position: relative;
  width: 100%;
  max-width: 500px;
}

#search .ais-SearchBox-input {
  background: rgba(255, 255, 255, 0.98) !important;
  border: none !important;
  border-radius: 28px !important;
  padding: 16px 24px 16px 50px !important;
  font-size: 16px !important;
  width: 100% !important;
  color: var(--color-primary) !important;
  font-family: var(--font-family-body) !important;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.1) !important;
  height: 56px !important;
  outline: none !important;
}

#search .ais-SearchBox-input::placeholder {
  color: rgba(20, 28, 82, 0.6) !important;
  font-size: 16px !important;
}

/* Search Icon */
#search .ais-SearchBox-form::before {
  content: '🔍';
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 18px;
  color: rgba(20, 28, 82, 0.6);
  z-index: 10;
  pointer-events: none;
}

#search .ais-SearchBox-submit,
#search .ais-SearchBox-reset {
  display: none !important;
}

/* Search Results Styling */
#search .ais-Hits {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 16px;
  margin-top: 16px;
  padding: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  max-height: 400px;
  overflow-y: auto;
}

#search .ais-Hits-item {
  padding: 12px 0;
  border-bottom: 1px solid rgba(20, 28, 82, 0.1);
}

#search .ais-Hits-item:last-child {
  border-bottom: none;
}

#search .ais-Hits-item a {
  color: var(--color-primary) !important;
  text-decoration: none;
  font-family: var(--font-family-body);
}

#search .ais-Hits-item a:hover {
  color: var(--color-secondary) !important;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .hero.hero-newsroom {
    padding: 12rem 0 12rem;
    min-height: 100vh;
  }

  .hero.hero-newsroom h1 {
    font-size: 42px;
  }

  .hero.hero-newsroom h3 {
    font-size: 20px;
  }

  /* Latest article - stack on mobile */
  .latest-article-card {
    flex-direction: column;
  }

  .latest-article-image {
    width: 100%;
    height: 200px;
  }

  .latest-article-content {
    padding: 24px;
  }

  .latest-article-content h3 {
    font-size: 24px;
  }

  #headlinePost h2,
  #featuredArticles h2,
  #allArticles h2 {
    font-size: 32px;
  }

  #headlinePost,
  #featuredArticles,
  #allArticles {
    padding: 60px 0 40px;
  }
}

/* Override any conflicting newsroom styles */
#newsMain * {
  font-family: var(--font-family-body) !important;
}

#newsMain h1,
#newsMain h2,
#newsMain h3,
#newsMain h4,
#newsMain h5,
#newsMain h6 {
  font-family: var(--font-family-heading) !important;
}
