/* News and Updates Section Component Styles */

.news-and-updates-section {
  width: 100%;
  background: var(--Tertiary-80, #F8E6E5);
  padding: 4rem 0;
}

.news-and-updates-section-container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

/* Header Section */
.news-and-updates-header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
}

.news-and-updates-header-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1;
}

/* Pretitle */
.news-and-updates-pretitle {
  color: var(--Primary-100, #680144);
  font-family: "DM Sans", sans-serif;
  font-size: 1.125rem; /* 18px */
  font-style: normal;
  font-weight: 500;
  line-height: 140%; /* 1.575rem */
  letter-spacing: 0.05625rem;
  text-transform: uppercase;
}

/* Heading */
.news-and-updates-heading {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: baseline;
  gap: 0.25rem;
  line-height: 1;
}

.news-and-updates-heading-part-1 {
  color: var(--Primary-100, #680144);
  font-family: "DM Sans", sans-serif;
  font-size: 3rem; /* 48px */
  font-style: normal;
  font-weight: 400;
  line-height: 140%; /* 4.2rem */
  letter-spacing: -0.06rem;
}

.news-and-updates-heading-part-2 {
  color: var(--Primary-100, #680144);
  font-family: "Calluna", serif;
  font-size: 3.25rem; /* 52px */
  font-style: italic;
  font-weight: 400;
  line-height: 140%;
  letter-spacing: -0.065rem;
}

/* Header Right - Button */
.news-and-updates-header-right {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.news-and-updates-button {
  padding: 1rem 2rem;
  border-radius: 0.5rem;
  border: 1px solid var(--Primary-100, #680144);
  background: transparent;
  text-decoration: none;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
  cursor: pointer;
}

.news-and-updates-button:hover {
  background: var(--Primary-100, #680144);
}

.news-and-updates-button-text {
  color: var(--Primary-100, #680144);
  text-align: center;
  font-family: "DM Sans", sans-serif;
  font-size: 1.125rem; /* 18px */
  font-style: normal;
  font-weight: 400;
  line-height: 140%; /* 1.575rem */
  letter-spacing: -0.0225rem;
  transition: color 0.3s ease;
}

.news-and-updates-button:hover .news-and-updates-button-text {
  color: #ffffff;
}

/* News Grid */
.news-and-updates-grid {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 1rem;
}

/* News Card - Same design as first row (odd row) from news-archive */
.news-and-updates-card {
  flex: 0 0 calc(33.333% - 0.667rem);
  max-width: calc(33.333% - 0.667rem);
  height: 504px;
  padding-bottom: 99px; /* Reserve space for hover expansion (603px - 504px) to prevent section height change */
  box-sizing: content-box; /* Padding adds to height */
  position: relative;
  display: inline-flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  overflow: hidden;
  text-decoration: none;
  transition: height 0.3s ease, padding-bottom 0.3s ease;
  gap: 0;
}

.news-and-updates-card:hover {
  height: 603px;
  padding-bottom: 0; /* Remove padding when expanded since height now includes the space */
}

/* Image Wrapper */
.news-and-updates-card-image-wrapper {
  width: 100%;
  flex: 1;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 0.625rem;
  overflow: hidden;
  position: relative;
  min-height: 0;
  margin: 0;
  padding: 0;
}

.news-and-updates-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 1 / 1;
  transition: aspect-ratio 0.3s ease;
  display: block;
  margin: 0;
  padding: 0;
  vertical-align: top;
}

.news-and-updates-card:hover .news-and-updates-card-image {
  aspect-ratio: 4 / 3;
}

.news-and-updates-card-image-placeholder {
  width: 100%;
  height: 100%;
  background: var(--Primary-100, #680144);
  opacity: 0.1;
}

/* Content Section */
.news-and-updates-card-content {
  width: 100%;
  padding: 1.5rem;
  border-left: 1.5px solid var(--Primary-100, #680144);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  gap: 1rem;
  overflow: hidden;
  position: relative;
  background: transparent;
  transition: all 0.3s ease;
}

/* Category */
.news-and-updates-card-category {
  width: 100%;
  color: var(--Primary-60, #A0638B);
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 140%;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  transition: color 0.3s ease;
  position: relative;
  z-index: 2;
}

/* Title */
.news-and-updates-card-title {
  width: 100%;
  color: var(--Primary-100, #680144);
  font-family: "DM Sans", sans-serif;
  font-size: 24px;
  font-weight: 400;
  line-height: 120%;
  letter-spacing: -1.2px;
  margin: 0;
  padding: 0;
  transition: color 0.3s ease;
  position: relative;
  z-index: 2;
}

/* Description */
.news-and-updates-card-description {
  width: 100%;
  overflow: hidden;
  color: var(--Primary-100, #680144);
  text-overflow: ellipsis;
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 140%;
  letter-spacing: -0.32px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  transition: color 0.3s ease;
  position: relative;
  z-index: 2;
}

/* Hover Background Effect */
.news-and-updates-card-hover-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background: var(--Primary-100, #680144);
  transition: width 0.3s ease;
  z-index: 1;
}

.news-and-updates-card:hover .news-and-updates-card-hover-bg {
  width: 100%;
}

.news-and-updates-card:hover .news-and-updates-card-category,
.news-and-updates-card:hover .news-and-updates-card-title,
.news-and-updates-card:hover .news-and-updates-card-description {
  color: #ffffff;
}

/* Responsive - Desktop/Laptop (1024px+) */
@media (min-width: 1024px) {
  .news-and-updates-section {
    padding: 4rem 0;
  }
  
  .news-and-updates-section-container {
    padding: 0 2rem;
  }
  
  .news-and-updates-grid {
    gap: 1rem;
  }
}

/* Responsive - Tablet (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .news-and-updates-section {
    padding: 3rem 0;
  }
  
  .news-and-updates-section-container {
    padding: 0 2rem;
    gap: 2.5rem;
  }
  
  .news-and-updates-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }
  
  .news-and-updates-header-right {
    width: 100%;
  }
  
  .news-and-updates-button {
    width: 100%;
    max-width: 300px;
  }
  
  .news-and-updates-grid {
    flex-wrap: wrap;
    gap: 1.5rem;
  }
  
  .news-and-updates-card {
    flex: 0 0 calc(50% - 0.75rem);
    max-width: calc(50% - 0.75rem);
    height: 500px;
    padding-bottom: 103px; /* Reserve space for hover expansion (603px - 500px) to prevent section height change */
  }
  
  .news-and-updates-card:hover {
    height: 603px;
    padding-bottom: 0; /* Remove padding when expanded */
  }
  
  .news-and-updates-heading-part-1 {
    font-size: 2.5rem;
    letter-spacing: -0.05rem;
  }
  
  .news-and-updates-heading-part-2 {
    font-size: 2.75rem;
    letter-spacing: -0.055rem;
  }
}

/* Responsive - Mobile (max-width: 767px) */
@media (max-width: 767px) {
  .news-and-updates-section {
    padding: 3rem 0;
  }
  
  .news-and-updates-section-container {
    padding: 0 1rem;
    gap: 2rem;
  }
  
  .news-and-updates-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }
  
  .news-and-updates-header-left {
    gap: 0.75rem;
  }
  
  .news-and-updates-pretitle {
    font-size: 1rem;
    letter-spacing: 0.05rem;
  }
  
  .news-and-updates-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }
  
  .news-and-updates-heading-part-1 {
    font-size: 2rem;
    line-height: 140%;
    letter-spacing: -0.04rem;
  }
  
  .news-and-updates-heading-part-2 {
    font-size: 2.25rem;
    line-height: 140%;
    letter-spacing: -0.045rem;
    margin-top: 0.25rem;
  }
  
  .news-and-updates-header-right {
    width: 100%;
  }
  
  .news-and-updates-button {
    width: 100%;
    max-width: 100%;
  }
  
  .news-and-updates-button-text {
    font-size: 1rem;
    letter-spacing: -0.02rem;
  }
  
  .news-and-updates-grid {
    flex-direction: column;
    gap: 1.5rem;
  }
  
  .news-and-updates-card {
    width: 100%;
    flex: 1 1 100%;
    max-width: 100%;
    height: auto;
    min-height: 400px;
  }
  
  .news-and-updates-card-image-wrapper {
    min-height: 250px;
  }
  
  .news-and-updates-card-title {
    font-size: 20px;
    letter-spacing: -0.8px;
  }
  
  .news-and-updates-card-category,
  .news-and-updates-card-description {
    font-size: 14px;
  }
}

