/* ==========================================================================
   Certifications & Credentials page  (certifications.html)
   --------------------------------------------------------------------------
   Page-scoped styles. Every selector is prefixed .cert- so nothing here can
   leak into the other pages. Lives outside assets/css on purpose: the gulp
   `clean` task wipes assets/css, so a hand-written file there would be lost.
   Brand tokens mirror the theme: green #124838, orange #E3A476, cream #FFDA91.
   ========================================================================== */

.cert-page {
  --cert-green: #124838;
  --cert-green-soft: #265C4C;
  --cert-mint: #85C7B3;
  --cert-orange: #E3A476;
  --cert-cream: #FFDA91;
  --cert-ink: #333;
  --cert-muted: #667772;
}

/* ---------- Intro ---------- */
.cert-lead {
  max-width: 46rem;
  color: var(--cert-ink);
  font-size: 1.02rem;
  line-height: 1.75;
  margin: 0 auto 0 0;
}

@media (max-width: 991.98px) {
  .cert-lead { margin: 0 auto; }
}

/* ---------- Certificate card ---------- */
.cert-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  background: #fff;
  border: 2px solid rgba(255, 218, 145, 0.75);
  border-radius: 22px;
  overflow: hidden;
  text-align: left;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.cert-card:hover,
.cert-card:focus-within {
  border-color: var(--cert-orange);
  box-shadow: 0 14px 34px rgba(18, 72, 56, 0.12);
  transform: translateY(-3px);
}

.cert-card__media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22rem;
  padding: 1.25rem 1.25rem 3.7rem;
  background: linear-gradient(180deg, rgba(255, 218, 145, 0.38), rgba(255, 218, 145, 0.14));
  cursor: zoom-in;
  text-decoration: none;
}

.cert-card__media img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  transition: transform 0.35s ease;
}

.cert-card__media:hover img,
.cert-card__media:focus-visible img {
  transform: scale(1.03);
}

.cert-card__media:focus-visible {
  outline: 3px solid var(--cert-orange);
  outline-offset: -3px;
}

.cert-card__view {
  position: absolute;
  left: 50%;
  bottom: 0.95rem;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 1rem;
  border-radius: 40px;
  background: linear-gradient(93deg, #2F7A63 -18.71%, var(--cert-green) 117.68%);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(18, 72, 56, 0.3);
}

.cert-card__body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  padding: 1.4rem 1.5rem 1.6rem;
}

.cert-card__tag {
  align-self: flex-start;
  margin-bottom: 0.8rem;
  padding: 0.22rem 0.75rem;
  border-radius: 40px;
  background: rgba(18, 72, 56, 0.08);
  color: var(--cert-green);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.cert-card__title {
  margin: 0 0 0.6rem;
  color: var(--cert-green);
  font-size: 1.3rem;
  font-weight: 700;
  line-height: 1.25;
}

.cert-card__desc {
  margin: 0 0 1.1rem;
  color: var(--cert-ink);
  font-size: 0.92rem;
  line-height: 1.65;
}

/* key facts: label / value pairs taken from the certificate itself */
.cert-facts {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 0.5rem 1rem;
  margin: 0 0 1.25rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(18, 72, 56, 0.22);
}

.cert-facts dt {
  padding-top: 0.12rem;
  color: var(--cert-muted);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.cert-facts dd {
  margin: 0;
  color: #222;
  font-size: 0.9rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.cert-card__actions {
  margin-top: auto;
}

.cert-verify {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding-bottom: 1px;
  border-bottom: 2px solid var(--cert-orange);
  color: var(--cert-green);
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.cert-verify:hover,
.cert-verify:focus-visible {
  color: #b9733f;
  border-color: var(--cert-green);
}

.cert-note {
  margin: 0;
  color: var(--cert-muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

/* ---------- Product scope band ---------- */
.cert-scope {
  padding: 2rem 1.5rem;
  background: #fff;
  border: 2px solid var(--cert-cream);
  border-radius: 40px;
}

.cert-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cert-chip {
  padding: 0.45rem 1rem;
  background: rgba(255, 218, 145, 0.45);
  border: 1px solid rgba(227, 164, 118, 0.55);
  border-radius: 40px;
  color: var(--cert-green);
  font-size: 0.88rem;
  font-weight: 600;
}

@media (min-width: 992px) {
  .cert-scope { padding: 2.75rem 3.25rem; }
  .cert-chips { justify-content: flex-start; }
}

/* ---------- Footnote ---------- */
.cert-footnote {
  max-width: 46rem;
  margin: 1.75rem auto 0;
  color: var(--cert-muted);
  font-size: 0.8rem;
  line-height: 1.6;
  text-align: center;
}

/* ---------- Small screens / preferences ---------- */
@media (max-width: 575.98px) {
  .cert-card__media { height: 19rem; }
}

@media (hover: none) {
  .cert-card:hover { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .cert-card,
  .cert-card__media img,
  .cert-verify { transition: none; }
  .cert-card:hover,
  .cert-card:focus-within { transform: none; }
  .cert-card__media:hover img,
  .cert-card__media:focus-visible img { transform: none; }
}
