/* Capability & Quality — editorial pages matching Handy Foods system */

.hf-editorial {
  background: var(--off-white);
  color: var(--black);
}

/* Stella / Our Story style: left copy + full-bleed right image. */
.hf-editorial-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 0;
  padding: 0;
  max-width: none;
  margin: 0;
  overflow: hidden;
  background: var(--off-white);
}

.hf-editorial-hero-copy {
  padding: 168px 64px 88px 72px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hf-editorial-hero-copy .section-label {
  margin-bottom: 18px;
}

.hf-editorial-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(48px, 6vw, 78px);
  line-height: 1.08;
  font-weight: 400;
  color: var(--black);
  margin-bottom: 20px;
}

.hf-editorial-hero h1 em {
  color: var(--red);
  font-style: italic;
  font-weight: 400;
}

.hf-editorial-lede {
  font-family: var(--font-serif);
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.35;
  font-weight: 300;
  color: var(--black);
  max-width: 18ch;
  margin-bottom: 24px;
}

.hf-editorial-hero-copy > p,
.hf-editorial-prose p {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.8;
  color: var(--text-mid);
  max-width: 640px;
}

.hf-editorial-prose p + p {
  margin-top: 18px;
}

.hf-editorial-hero-sub {
  margin-top: 40px;
  padding-top: 36px;
  border-top: 1px solid rgba(217, 45, 39, 0.18);
}

.hf-editorial-hero-sub h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.15;
  font-weight: 400;
  color: var(--black);
  margin: 0 0 18px;
}

.hf-editorial-hero-features {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hf-editorial-hero-features .hf-feature {
  padding: 22px 0 8px;
  border-top: 1px solid rgba(217, 45, 39, 0.18);
}

.hf-editorial-hero-features .hf-feature h2 {
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 12px;
  font-weight: 600;
}

.hf-editorial-hero-features .hf-feature p {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-mid);
  max-width: 640px;
  margin: 0;
}

.hf-editorial-hero-media {
  position: relative;
  min-width: 0;
  min-height: 100%;
  overflow: hidden;
  background: #ece7e2;
}

.hf-editorial-hero-media img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center center;
}

.hf-editorial-hero-media .hf-slideshow {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hf-editorial-hero-media .hf-slideshow-viewport,
.hf-editorial-hero-media .hf-slideshow-slide,
.hf-editorial-hero-media .hf-slideshow-batch,
.hf-editorial-hero-media .hf-slideshow-item {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hf-editorial-hero-media .hf-slideshow-item img {
  position: absolute;
  inset: 0;
}

/* Quality: keep the subject framed so the fill doesn't leave a dead band. */
.quality-page .hf-editorial-hero-media img {
  object-position: center 30%;
}

.hf-stat-value--long {
  font-size: clamp(22px, 2.4vw, 34px);
}

.hf-editorial-section {
  padding: 72px 72px;
  max-width: 1400px;
  margin: 0 auto;
}

.hf-editorial-section.narrow {
  max-width: 860px;
}

.hf-editorial-section h2 {
  font-family: var(--font-serif);
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  font-weight: 400;
  margin-bottom: 28px;
}

.hf-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px 32px;
  padding: 72px 72px 88px;
  max-width: 1400px;
  margin: 0 auto;
}

.hf-stat {
  border-top: 1px solid rgba(217, 45, 39, 0.22);
  padding-top: 22px;
}

.hf-stat-value {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.1;
  color: var(--red);
  margin-bottom: 12px;
}

.hf-stat-label {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--black);
  margin-bottom: 10px;
  font-weight: 600;
}

.hf-stat p {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  color: var(--text-mid);
}

.hf-logo-band {
  background: var(--black);
  color: #fff;
  padding: 72px;
  text-align: center;
}

.hf-logo-band--light {
  background: #fff;
  color: var(--black);
  border-top: 1px solid rgba(217, 45, 39, 0.12);
  border-bottom: 1px solid rgba(217, 45, 39, 0.12);
}

.hf-logo-band .section-label {
  color: rgba(255, 255, 255, 0.35);
  justify-content: center;
  margin-bottom: 20px;
}

.hf-logo-band--light .section-label {
  color: var(--red);
}

.hf-logo-band h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 400;
  margin-bottom: 40px;
  color: #fff;
}

.hf-logo-band--light h2 {
  color: var(--black);
}

.hf-logo-row {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
  gap: 28px 36px;
  max-width: 1200px;
  margin: 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.hf-logo-row::-webkit-scrollbar {
  display: none;
}

.hf-logo-row img {
  display: block;
  width: auto;
  height: auto;
  max-height: 48px;
  max-width: 110px;
  object-fit: contain;
  flex: 0 0 auto;
}

.hf-logo-row img.logo-aldi {
  max-height: 56px;
  max-width: 56px;
}

.hf-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 36px 48px;
  padding: 0 72px 72px;
  max-width: 1400px;
  margin: 0 auto;
}

.hf-feature {
  padding: 28px 0 8px;
  border-top: 1px solid rgba(217, 45, 39, 0.18);
}

.hf-feature h2 {
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
  font-weight: 600;
}

.hf-feature p {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-mid);
}

.hf-cert-section {
  padding: 72px;
  max-width: none;
  margin: 0;
  background: #fff;
  border-top: 1px solid rgba(217, 45, 39, 0.12);
  border-bottom: 1px solid rgba(217, 45, 39, 0.12);
  text-align: center;
}

.hf-cert-section h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 400;
  margin-bottom: 40px;
  text-align: center;
  color: var(--black);
}

.hf-cert-row {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
  gap: 28px 36px;
  max-width: 1200px;
  margin: 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.hf-cert-row::-webkit-scrollbar {
  display: none;
}

.hf-logo-row.hf-cert-row img,
.hf-cert-row img {
  display: block;
  width: auto;
  height: auto;
  max-height: 72px;
  max-width: 140px;
  object-fit: contain;
  flex: 0 0 auto;
}

.hf-editorial-close {
  padding: 96px 72px;
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}

.hf-editorial-close h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 400;
  margin-bottom: 18px;
}

.hf-editorial-close p {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.8;
  color: var(--text-mid);
  margin-bottom: 28px;
}

.hf-editorial-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}

.footer-design-credit {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  font-family: var(--font-body);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.02em;
}

.footer-design-credit img {
  display: block;
  height: 28px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  opacity: 0.9;
}

@media (max-width: 768px) {
  .footer-design-credit {
    margin-left: 0;
    justify-content: center;
  }
}

@media (max-width: 1100px) {
  .hf-editorial-hero-copy {
    padding: 140px 48px 72px;
  }
  .hf-stat-grid,
  .hf-feature-grid {
    grid-template-columns: 1fr 1fr;
    padding-left: 40px;
    padding-right: 40px;
  }
  .hf-editorial-section,
  .hf-logo-band,
  .hf-cert-section,
  .hf-editorial-close {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media (max-width: 900px) {
  .hf-editorial-hero {
    grid-template-columns: 1fr;
  }
  .hf-editorial-hero-copy {
    order: 1;
    padding: 120px 40px 48px;
  }
  .hf-editorial-hero-media {
    order: 2;
    min-height: 420px;
    height: 56vw;
    max-height: 640px;
  }
  .hf-editorial-hero-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

@media (max-width: 768px) {
  .hf-editorial-hero-copy {
    padding: 112px 24px 40px;
  }
  .hf-editorial-hero-media {
    min-height: 320px;
    height: 70vw;
    max-height: 480px;
  }
  .hf-editorial-hero-sub {
    margin-top: 32px;
    padding-top: 28px;
  }
  .hf-editorial-hero-features {
    margin-top: 32px;
  }
  .hf-stat-grid,
  .hf-feature-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 48px 24px 64px;
  }
  .hf-editorial-section,
  .hf-logo-band,
  .hf-cert-section,
  .hf-editorial-close {
    padding-left: 24px;
    padding-right: 24px;
  }
  .hf-logo-row,
  .hf-cert-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: center;
    justify-items: center;
    gap: 22px 14px;
    max-width: 100%;
    overflow: visible;
  }
  .hf-cert-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .hf-logo-row img,
  .hf-logo-row.hf-cert-row img,
  .hf-cert-row img {
    width: 100%;
    max-width: 88px;
    max-height: 40px;
    flex: none;
  }
  .hf-logo-row img.logo-aldi {
    max-height: 48px;
    max-width: 48px;
  }
  .hf-cert-row img {
    max-height: 56px;
    max-width: 100px;
  }
}

@media (max-width: 480px) {
  .hf-logo-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 18px 10px;
  }
  .hf-cert-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px 10px;
  }
  .hf-logo-row img,
  .hf-logo-row.hf-cert-row img,
  .hf-cert-row img {
    max-width: 72px;
    max-height: 34px;
  }
  .hf-logo-row img.logo-aldi {
    max-height: 40px;
    max-width: 40px;
  }
  .hf-cert-row img {
    max-height: 48px;
    max-width: 84px;
  }
}

/* Editorial pages: show content even before JS runs (avoids blank page). */
.hf-editorial .reveal {
  opacity: 1;
  transform: none;
}
.hf-editorial .reveal.is-pending {
  opacity: 0;
  transform: translateY(36px);
}
@media (prefers-reduced-motion: reduce) {
  .hf-editorial .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
