/**
 * @file
 * Styles for Newsletter Page on Soil MIP platform.
 * Hero banner background color matched strictly with the top header section color (#000e38).
 */

/* Hide default duplicate Page Title H1 on Newsletter page */
.page-newsletter h1,
.page-newsletter h1.page-title,
.page-newsletter #page-title {
  display: none !important;
}

/* Main Container Wrapper */
.smip-newsletter-wrapper {
  width: 100% !important;
  box-sizing: border-box !important;
  margin-top: 1rem;
  margin-bottom: 3rem;
  font-family: Arial, sans-serif !important;
}

/* ------------------------------------------------------------------
 * 1. Dark Navy Hero Subscription Banner (Background Matched with Header #000e38)
 * ------------------------------------------------------------------ */
.smip-newsletter-hero {
  position: relative;
  width: 100vw !important;
  left: 50% !important;
  right: 50% !important;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
  box-sizing: border-box !important;
  background: #000e38 !important; /* Matched strictly with Header section color */
  background: linear-gradient(135deg, #000e38 0%, #001648 60%, #002d62 100%) !important;
  color: #ffffff;
  border-radius: 0 !important; /* Edge-to-edge full width from page border to border */
  padding: 3.5rem 0;
  margin-bottom: 3.5rem;
  box-shadow: 0 10px 30px rgba(0, 14, 56, 0.2);
  overflow: hidden;
  font-family: Arial, sans-serif !important;
}

.smip-newsletter-hero__inner {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-sizing: border-box;
}

.smip-newsletter-hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 900px;
}

/* ECL Badge Typography (12px / Bold 700) */
.smip-newsletter-hero__badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  color: #ffd100;
  font-family: Arial, sans-serif !important;
  font-size: 0.75rem !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  margin-bottom: 1.25rem;
}

/* ECL Hero Title Typography (36px / Bold 700 / line-height 1.2) */
.smip-newsletter-hero__title {
  color: #ffffff !important;
  font-family: Arial, sans-serif !important;
  font-size: 2.25rem !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: -0.01em;
  margin: 0 0 1rem 0 !important;
  padding: 0 !important;
  border: none !important;
}

/* ECL Lead Description Typography (18px / Regular 400 / line-height 1.56) */
.smip-newsletter-hero__desc {
  color: rgba(255, 255, 255, 0.92);
  font-family: Arial, sans-serif !important;
  font-size: 1.125rem !important;
  font-weight: 400 !important;
  line-height: 1.56 !important;
  margin-bottom: 1.75rem;
}

.smip-newsletter-hero__desc p,
.smip-newsletter-intro-item {
  color: rgba(255, 255, 255, 0.92) !important;
  font-family: Arial, sans-serif !important;
  font-size: 1.125rem !important;
  font-weight: 400 !important;
  line-height: 1.56 !important;
  margin-bottom: 1rem !important;
}

/* Subscribe Button - Vibrant EC Yellow (#ffd100) on Header Navy Background */
.smip-newsletter-hero a[href*="subscribe"],
.smip-newsletter-hero a[href*="subscriptions"],
.smip-newsletter-hero .ecl-button,
.smip-newsletter-hero .btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.65rem !important;
  background-color: #ffd100 !important; /* EC Yellow Button */
  color: #000e38 !important;            /* Header Navy Text */
  font-family: Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
  padding: 0.75rem 1.75rem !important;
  border-radius: 4px !important;        /* ECL Standard 4px Radius */
  text-decoration: none !important;
  margin-top: 0.5rem !important;
  margin-bottom: 0.5rem !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2) !important;
  border: none !important;
  transition: all 0.25s ease-in-out !important;
}

.smip-newsletter-hero a[href*="subscribe"]:hover,
.smip-newsletter-hero a[href*="subscriptions"]:hover,
.smip-newsletter-hero .ecl-button:hover,
.smip-newsletter-hero .btn:hover {
  background-color: #ffffff !important;
  color: #000e38 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3) !important;
  text-decoration: none !important;
}

/* ECL Small Subtext Typography (14px / Regular 400) */
.smip-newsletter-hero__privacy {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  background: rgba(255, 255, 255, 0.08);
  border-left: 3.5px solid #ffd100;
  color: rgba(255, 255, 255, 0.88);
  font-family: Arial, sans-serif !important;
  font-size: 0.875rem !important;
  font-weight: 400 !important;
  line-height: 1.45 !important;
  padding: 0.75rem 1.1rem;
  border-radius: 0 4px 4px 0;
  margin-top: 1.5rem;
}

.smip-newsletter-hero__privacy svg {
  flex-shrink: 0;
}


/* ------------------------------------------------------------------
 * 2. Section Headers (ECL v5 H2 Typography Specs)
 * ------------------------------------------------------------------ */
.smip-newsletter-section {
  width: 100%;
  margin-bottom: 3.5rem;
  font-family: Arial, sans-serif !important;
}

.smip-newsletter-section__header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.65rem;
  border-bottom: 2px solid #e2e8f0;
}

.smip-newsletter-section__header h3 {
  color: #004494 !important;
  font-family: Arial, sans-serif !important;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  letter-spacing: -0.01em;
  margin: 0 !important;
  padding: 0 !important;
}


/* ------------------------------------------------------------------
 * 3. Previous Editions Cards Grid (ECL v5 Card Specs Alignment)
 * ------------------------------------------------------------------ */
.smip-newsletter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.smip-newsletter-card {
  background: #ffffff;
  border: 1px solid #cfdae6;
  border-top: 4px solid #004494;
  border-radius: 4px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  transition: all 0.25s cubic-bezier(0.165, 0.84, 0.44, 1);
  font-family: Arial, sans-serif !important;
}

.smip-newsletter-card:hover {
  transform: translateY(-3px);
  border-top-color: #1e5631;
  box-shadow: 0 8px 20px rgba(0, 68, 148, 0.12);
}

.smip-newsletter-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.smip-newsletter-card__badge {
  background: #f0f4f8;
  color: #004494;
  font-family: Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 0.75rem !important;
  line-height: 1 !important;
  padding: 0.3rem 0.7rem;
  border-radius: 9999px;
  border: 1px solid #d0dbe5;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.smip-newsletter-card__date {
  color: #515962;
  font-family: Arial, sans-serif !important;
  font-size: 0.875rem !important;
  font-weight: 400 !important;
  line-height: 1.4 !important;
}

.smip-newsletter-card__title {
  color: #004494;
  font-family: Arial, sans-serif !important;
  font-size: 1.125rem !important;
  font-weight: 700 !important;
  line-height: 1.4 !important;
  margin: 0 0 1.25rem 0 !important;
}

.smip-newsletter-card__action {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #eef2f6;
}

.smip-newsletter-card__link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: #004494 !important;
  font-family: Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 0.875rem !important;
  line-height: 1.4 !important;
  text-decoration: none !important;
  transition: color 0.2s ease;
}

.smip-newsletter-card__link:hover {
  color: #1e5631 !important;
  text-decoration: underline !important;
}


/* ------------------------------------------------------------------
 * 4. PDF Downloads Section & Language Pills (ECL v5 File Specs)
 * ------------------------------------------------------------------ */
.smip-pdf-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.smip-pdf-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  background: #f8fafc;
  border: 1px solid #cfdae6;
  border-radius: 4px;
  padding: 1.1rem 1.35rem;
  transition: all 0.2s ease;
  font-family: Arial, sans-serif !important;
}

.smip-pdf-item:hover {
  background: #ffffff;
  border-color: #004494;
  box-shadow: 0 4px 14px rgba(0, 68, 148, 0.08);
}

.smip-pdf-item__left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.smip-pdf-item__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: #fef2f2;
  border-radius: 4px;
  flex-shrink: 0;
}

.smip-pdf-item__title {
  color: #2e363e;
  font-family: Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 1rem !important;
  line-height: 1.4 !important;
}

.smip-pdf-item__right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.smip-pdf-item__label {
  color: #515962;
  font-family: Arial, sans-serif !important;
  font-size: 0.85rem !important;
  font-weight: 400 !important;
}

.smip-pdf-item__pills {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.smip-lang-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #ffffff;
  border: 1.5px solid #004494;
  color: #004494 !important;
  font-family: Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 0.8125rem !important;
  padding: 0.3rem 0.75rem;
  border-radius: 4px;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.smip-lang-pill:hover {
  background: #004494;
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 68, 148, 0.25);
}

.smip-lang-pill svg {
  transition: transform 0.2s ease;
}

.smip-lang-pill:hover svg {
  transform: translateY(1px);
}


/* ------------------------------------------------------------------
 * 5. Responsive Mobile Rules
 * ------------------------------------------------------------------ */
@media (max-width: 640px) {
  .smip-newsletter-hero {
    padding: 2.25rem 0;
  }

  .smip-newsletter-hero__inner {
    padding: 0 1.25rem;
  }

  .smip-newsletter-hero__title {
    font-size: 1.65rem !important;
  }

  .smip-newsletter-grid {
    grid-template-columns: 1fr;
  }

  .smip-pdf-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .smip-pdf-item__right {
    width: 100%;
  }
}