/* ==========================================================================
   Media Centre — Opportunities (listing + detail).
   Listing reuses the shared .post-card system (posts.css); opportunities are
   keyed to the brand green family. All values are core.css tokens.
   ========================================================================== */

/* Opportunity cards share the post-card grid; green accent + PDF placeholder. */
.post-card--opportunity .post-card__image-wrapper {
  background: linear-gradient(135deg, var(--colour-secondary-light) 0%, var(--colour-secondary-dark) 100%);
}

/* ---- Empty-state hero (no opportunities) ---- */
.opportunities-container {
  position: relative;
  overflow: hidden;
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  border: 1px solid var(--colour-border);
  border-radius: var(--radius-lg);
  margin-top: var(--space-6);
}

.opportunities-bg {
  position: absolute;
  inset: 0;
  background-image: url("../img/home-hero-bg_default.1d91ad7d7bfd.jpg");
  background-size: cover;
  background-position: center;
  min-height: 240px;
  z-index: 0;
  opacity: 0.18;
}

.opportunities-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.opportunities-heading {
  color: var(--colour-text);
  margin: 0;
}

.opportunities-wrapper {
  padding: var(--space-6) 0;
}

/* ==========================================================================
   Opportunity detail page
   ========================================================================== */
.opportunity-detail {
  padding: 0;
}

.opportunity-wrapper {
  max-width: var(--container-narrow);
  margin: 0 auto;
}

.opportunity-header {
  padding-bottom: var(--space-5);
  margin-bottom: var(--space-5);
  border-bottom: 1px solid var(--colour-border);
}

.opportunity-header h1 {
  margin-bottom: var(--space-3);
}

.opportunity-subtitle {
  font-size: var(--text-xl);
  font-weight: var(--fw-semibold);
  color: var(--colour-text-muted);
  margin: 0 0 var(--space-4);
  line-height: var(--leading-snug);
}

.opportunity-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-5);
  font-size: var(--text-sm);
  color: var(--colour-text-muted);
}

.opportunity-meta__date,
.opportunity-meta__updated {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* ---- Badge + primary action (brand green) ---- */
.opportunities-badge {
  display: inline-flex;
  align-items: center;
  color: var(--colour-secondary-dark);
  background: var(--colour-secondary-alpha-10);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.opportunities-button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: #fff;
  text-decoration: none;
  font-weight: var(--fw-semibold);
  background: var(--colour-secondary);
  border-radius: var(--radius-pill);
  padding: var(--space-3) var(--space-5);
  transition: background var(--motion-base) var(--ease-standard),
    box-shadow var(--motion-base) var(--ease-standard);
}
.opportunities-button:hover {
  color: #fff;
  background: var(--colour-secondary-dark);
  box-shadow: var(--shadow-md);
}

/* ---- Content ---- */
.opportunity-content {
  margin-bottom: var(--space-5);
}

.opportunity-excerpt {
  font-size: var(--text-lg);
  line-height: var(--leading-normal);
  color: var(--colour-text);
  padding: var(--space-3) 0;
}
.opportunity-excerpt p {
  margin: 0 0 var(--space-4);
}
.opportunity-excerpt p:last-child {
  margin-bottom: 0;
}
.opportunity-excerpt ul,
.opportunity-excerpt ol {
  margin: var(--space-4) 0;
  padding-left: var(--space-5);
}
.opportunity-excerpt li {
  margin-bottom: var(--space-2);
}
.opportunity-excerpt strong {
  color: var(--colour-text);
  font-weight: var(--fw-semibold);
}

/* ---- Download card ---- */
.opportunity-download__card {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-4);
  padding: var(--space-5);
  margin-bottom: var(--space-5);
  background: var(--colour-bg-subtle);
  border: 1px solid var(--colour-border);
  border-left: 4px solid var(--colour-secondary);
  border-radius: var(--radius-lg);
}
.opportunity-download__icon {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  background: var(--colour-secondary-alpha-10);
  color: var(--colour-secondary-dark);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}
.opportunity-download__info {
  flex: 1;
  min-width: 0;
}
.opportunity-download__title {
  font-size: var(--text-lg);
  font-weight: var(--fw-bold);
  margin: 0 0 var(--space-1);
  color: var(--colour-text);
}
.opportunity-download__text {
  margin: 0;
  color: var(--colour-text-muted);
  font-size: var(--text-sm);
}

/* ---- Info card ---- */
.opportunity-info {
  margin-bottom: var(--space-6);
}
.opportunity-info__card {
  background: var(--colour-bg-subtle);
  border: 1px solid var(--colour-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}
.opportunity-info__title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-lg);
  font-weight: var(--fw-bold);
  color: var(--colour-text);
  margin: 0 0 var(--space-4);
}
.opportunity-info__title i {
  color: var(--colour-secondary-dark);
}
.opportunity-info__list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.opportunity-info__list li {
  position: relative;
  padding-left: var(--space-6);
  margin-bottom: var(--space-3);
  color: var(--colour-text);
  line-height: var(--leading-normal);
}
.opportunity-info__list li:last-child {
  margin-bottom: 0;
}
.opportunity-info__list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--colour-secondary);
  font-weight: var(--fw-bold);
}

/* ---- Footer nav ---- */
.opportunity-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-3);
  padding-top: var(--space-5);
  margin-top: var(--space-5);
  border-top: 1px solid var(--colour-border);
}
.opportunity-footer__back,
.opportunity-footer__download {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  text-decoration: none;
  font-weight: var(--fw-semibold);
  border-radius: var(--radius-pill);
  transition: all var(--motion-base) var(--ease-standard);
}
.opportunity-footer__back {
  background: transparent;
  color: var(--colour-text);
  border: 1px solid var(--colour-border-strong);
}
.opportunity-footer__back:hover {
  border-color: var(--colour-primary);
  color: var(--colour-primary);
}
.opportunity-footer__download {
  background: var(--colour-secondary);
  color: #fff;
}
.opportunity-footer__download:hover {
  background: var(--colour-secondary-dark);
  box-shadow: var(--shadow-md);
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .opportunity-subtitle {
    font-size: var(--text-lg);
  }
  .opportunity-download__card {
    flex-direction: column;
    text-align: center;
  }
  .opportunity-footer {
    flex-direction: column;
    align-items: stretch;
  }
  .opportunity-footer__back,
  .opportunity-footer__download {
    justify-content: center;
  }
  .opportunity-meta {
    gap: var(--space-2) var(--space-4);
  }
}

@media print {
  .opportunity-download,
  .opportunity-download__card,
  .opportunity-footer {
    display: none;
  }
  .opportunity-wrapper {
    max-width: 100%;
  }
}
