/* Implements: CANONICAL-COMPONENT-LIBRARY.md §§2–4, CANONICAL-IMAGE-SYSTEM.md; Version 1.0.0. */
.story-card a,.story-feature a,.story-home-lead a,.story-carousel a{text-decoration:none}.story-card-media{display:block;overflow:hidden}.story-card-media img{aspect-ratio:4/5;object-fit:cover}.story-card-copy{padding:40px 40px 70px;background:var(--story-white)}.story-card-copy>*+*{margin-top:12px}.story-card-excerpt{margin-bottom:0;font-size:14px;line-height:1.45;color:var(--story-muted)}
@media(min-width:640px){.story-card-media img{aspect-ratio:120/121}}


/* R8 — optional editorial card/hero video. Geometry remains owned by the existing media box. */
.story-editorial-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}


/* =================================================================
   STORY Shop Edit — V1
   Opt-in commerce module for editorial styling/shopping features.
   Usage: .story-shop-edit > .story-shop-edit__grid > .story-shop-card
   Isolated from STORY Editorial Media and legacy article media.
   ================================================================= */
.story-article-body .story-shop-edit {
  width: min(calc(100vw - 32px), 1240px);
  max-width: none;
  margin: clamp(42px, 5vw, 68px) 0 clamp(64px, 7vw, 92px) 50%;
  transform: translateX(-50%);
}

.story-article-body .story-shop-edit__header {
  margin: 0 0 24px;
  padding: 0 0 12px;
  border-bottom: 1px solid currentColor;
}

.story-article-body .story-shop-edit__header h3 {
  max-width: none;
  margin: 0;
  font: 700 15px/18px var(--story-font);
  letter-spacing: .055em;
  text-transform: uppercase;
}

.story-article-body .story-shop-edit__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px 16px;
  align-items: start;
}

/* Classic Editor / wpautop guard:
   the Shop Edit grid contract permits product cards only. WordPress can emit
   empty paragraph or BR nodes between block-level <article> cards; when left
   visible those nodes consume CSS Grid cells and push every product into the
   second column on phones. Remove only those direct formatting artefacts. */
.story-article-body .story-shop-edit__grid > p,
.story-article-body .story-shop-edit__grid > br {
  display: none;
}

.story-article-body .story-shop-card {
  min-width: 0;
}

.story-article-body .story-shop-card__media {
  display: block;
  margin: 0 0 16px;
  overflow: hidden;
  background: #f5f5f3;
  text-decoration: none;
}

.story-article-body .story-shop-card__media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  margin: 0;
  object-fit: contain;
  object-position: center;
}

.story-article-body .story-shop-card__brand,
.story-article-body .story-shop-card__name,
.story-article-body .story-shop-card__price {
  margin: 0;
}

.story-article-body .story-shop-card__brand {
  font: 700 12px/16px var(--story-font);
  letter-spacing: .05em;
  text-transform: uppercase;
}

.story-article-body .story-shop-card__name {
  margin-top: 5px;
  font: var(--font-weight-light) 15px/20px var(--story-font);
}

.story-article-body .story-shop-card__price {
  margin-top: 7px;
  font: var(--font-weight-medium) 14px/18px var(--story-font);
}

.story-article-body .story-shop-card__button {
  display: inline-block;
  margin-top: 14px;
  padding-bottom: 3px;
  border-bottom: 1px solid currentColor;
  color: inherit;
  font: 700 11px/14px var(--story-font);
  letter-spacing: .06em;
  text-decoration: none;
  text-transform: uppercase;
}

.story-article-body .story-shop-card__button:hover,
.story-article-body .story-shop-card__button:focus-visible {
  opacity: .62;
}

@media (min-width: 768px) {
  .story-article-body .story-shop-edit {
    width: min(calc(100vw - 64px), 1240px);
  }

  .story-article-body .story-shop-edit__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 42px 22px;
  }
}

@media (max-width: 639px) {
  .story-article-body .story-shop-edit {
    margin-top: 38px;
    margin-bottom: 58px;
  }

  .story-article-body .story-shop-edit__header {
    margin-bottom: 18px;
  }

  .story-article-body .story-shop-edit__grid {
    gap: 30px 12px;
  }

  .story-article-body .story-shop-card__name {
    font-size: 14px;
    line-height: 19px;
  }
}
