/* Mekko Feature Carousel 0.1.1 — only enhanced sections.
   On no-JS pages, the original 3-card grid remains unchanged. */
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__navigation {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 15px;
  margin: -24px 0 14px;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__arrows {
  display: flex;
  gap: 8px;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__count {
  color: var(--mekko-brand, #54183f);
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .08em;
  white-space: nowrap;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__arrow {
  width: 37px;
  height: 37px;
  padding: 0;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(84, 24, 63, .22);
  border-radius: 50%;
  background: #fff;
  color: var(--mekko-brand, #54183f);
  cursor: pointer;
  font: 600 22px/1 sans-serif;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__arrow:hover:not(:disabled) {
  background: var(--mekko-brand-light, #f8eef5);
  border-color: var(--mekko-brand, #54183f);
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__arrow:focus-visible {
  outline: 3px solid var(--mekko-brand, #54183f);
  outline-offset: 3px;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__arrow:disabled {
  cursor: default;
  opacity: .35;
}
/* Same native horizontal scroll + snap strategy as Extras+.
   Specificity intentionally overrides the old global 3-card grid. */
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track {
  display: grid;
  grid-auto-flow: column;
  grid-template-columns: none;
  grid-auto-columns: calc((100% - 32px) / 3);
  gap: 16px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  scroll-behavior: smooth;
  align-items: stretch;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track::-webkit-scrollbar {
  display: none;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track > .mekko-feature-card {
  min-width: 0;
  height: 100%;
  grid-column: auto !important; /* cancels odd-last-item spanning from original grid */
  scroll-snap-align: start;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track > .mekko-feature-card .mekko-feature-card__link {
  height: 100%;
}
/* Field-28 images replace formerly fixed icon SVGs. */
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__visual {
  padding: 0;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__visual::before {
  content: none;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__visual img {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center;
  filter: none;
  border-radius: 0;
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__link:hover .mekko-feature-card__visual img,
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__link:focus-visible .mekko-feature-card__visual img {
  transform: none;
  filter: none;
}
@media (max-width: 980px) {
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track {
    grid-auto-columns: calc((100% - 16px) / 2);
  }
}
@media (max-width: 640px) {
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track {
    grid-auto-columns: 90%;
  }
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__navigation {
    margin-top: -12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track {
    scroll-behavior: auto;
  }
}
@media print {
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__navigation {
    display: none;
  }
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mk-feature-loop__track {
    display: grid;
    grid-auto-flow: row;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: visible;
  }
}

/* v0.1.1 — 20px shorter card image, with a clear 20px gap before the kicker.
   Net card height stays approximately the same, respecting existing typography. */
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__visual {
  height: calc(clamp(195px, 22vw, 300px) - 20px);
}
.mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__body {
  padding-top: 20px;
}

/* v0.1.1 — image reused from the clicked card above the native dialog title. */
.mekko-feature-dialog.mk-feature-dialog--has-image {
  width: min(700px, calc(100% - 32px));
  max-height: min(92dvh, 960px);
}
.mk-feature-dialog__media {
  width: 100%;
  height: clamp(160px, 24dvh, 230px);
  margin: 6px 0 22px;
  overflow: hidden;
  border-radius: 14px;
  background: var(--mekko-surface-soft, #f8eef5);
}
.mk-feature-dialog__media img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
}
@media (max-width: 640px) {
  .mekko-feature-set[data-mekko-feature-loop-active="1"] .mekko-feature-card[data-mekko-core-image="1"] .mekko-feature-card__visual {
    height: 195px;
  }
  .mk-feature-dialog__media {
    height: 170px;
    margin-bottom: 18px;
  }
}

/* 0.1.2 · Product feature cards: same editorial cover format on OnePage,
   Update and Extras; no hardcoded icon assets in page HTML. */
.mekko-feature-set.mk-product-features .mekko-feature-card__visual,
.mk-ex-page .mk-ex-features .mekko-feature-card__visual {
  padding: 0;
  height: calc(clamp(195px, 22vw, 300px) - 20px);
}
.mekko-feature-set.mk-product-features .mekko-feature-card__visual::before,
.mk-ex-page .mk-ex-features .mekko-feature-card__visual::before { content: none; }
.mekko-feature-set.mk-product-features .mekko-feature-card__visual img,
.mk-ex-page .mk-ex-feature .mekko-feature-card__visual img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center;
  filter: none;
  transform: none;
}
.mekko-feature-set.mk-product-features .mekko-feature-card__body,
.mk-ex-page .mk-ex-features .mekko-feature-card__body { padding-top: 20px; }
/* Missing field 28: no non-editable fallback illustration. */
.mekko-feature-set.mk-product-features .mekko-feature-card__visual:not(:has(img)),
.mk-ex-page .mk-ex-features .mekko-feature-card__visual:not(:has(img)) { display: none; }
.mekko-feature-set.mk-product-features .mekko-feature-card__link:hover .mekko-feature-card__visual img,
.mk-ex-page .mk-ex-feature .mekko-feature-card__link:hover .mekko-feature-card__visual img {
  transform: none;
  filter: none;
}
/* Shared homepage-like hero composition for product pages only.
   Homepage remains untouched until the future agreed hero-height alignment. */
.mekko-section.mekko-hero.mk-standard-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 0;
  padding-block: clamp(48px, 6vw, 94px);
  background: var(--mk-product-hero-color, #4b173b);
  color: #fff;
}
.mk-standard-hero[data-mekko-product="onepage"] { --mk-product-hero-color: var(--mekko-onepage, #842c66); }
.mk-standard-hero[data-mekko-product="update"] { --mk-product-hero-color: var(--mekko-update, #12687e); }
.mk-standard-hero[data-mekko-product="extras"] { --mk-product-hero-color: var(--mekko-extras, #566b2d); }
.mekko-section.mk-standard-hero > .mekko-shell__container {
  position: relative;
  z-index: 1;
}
.mekko-section.mk-standard-hero .mekko-hero__grid {
  min-height: 0;
  align-items: center;
}
.mk-standard-hero .mekko-hero__background {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.mk-standard-hero .mekko-hero__background img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
}
.mk-standard-hero .mekko-hero__background:has(img)::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(23,8,24,.52), rgba(23,8,24,.12));
}
.mk-standard-hero .mekko-hero__eyebrow,
.mk-standard-hero .mekko-hero__title,
.mk-standard-hero .mekko-hero__lede { color: #fff; }
.mk-standard-hero .mekko-hero__media {
  width: 100%;
  height: clamp(310px, 34vw, 480px);
  min-height: 0;
  overflow: hidden;
  border-radius: 18px;
}
.mk-standard-hero .mekko-hero__media img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
}
.mk-standard-hero .mekko-hero__visual-note { text-align: center; }
.mk-standard-hero .mekko-hero__media:not(:has(img)) { display: none; }
/* Extras retains its old four-slide JS, but each artwork is rendered into
   the same hero media dimensions and through independent Content Core keys. */
.mk-ex-page .mk-standard-hero .mekko-hero__media.mk-ex-hero__stage {
  max-width: none;
  margin: 0;
  min-height: 0;
}
.mk-ex-page .mk-standard-hero .mk-ex-hero__slide.is-active {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.mk-ex-page .mk-standard-hero .mk-ex-hero__slide:not(.is-active) { display: none; }
.mk-ex-page .mk-standard-hero .mk-ex-hero__illustration {
  flex: 1 1 auto;
  height: auto;
  min-height: 0;
  padding: 0;
  overflow: hidden;
}
.mk-ex-page .mk-standard-hero .mk-ex-hero__illustration img {
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: cover;
}
.mk-ex-page .mk-standard-hero .mk-ex-hero__legend {
  flex: 0 0 auto;
  padding: 9px 15px;
  background: rgba(255,255,255,.92);
}
.mk-ex-page .mk-standard-hero .mk-ex-hero__controls { margin-top: 12px; }
/* Proof visuals: dimensions remain within their original layouts. */

.mekko-product-proof[data-mekko-product="onepage"] .mekko-product-proof__visual img,
.mekko-product-proof[data-mekko-product="update"] .mekko-product-proof__visual img,
.mk-ex-page .mk-ex-highlight__art img {
  display: block;
  width: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
@media (max-width: 640px) {
  .mekko-section.mk-standard-hero { padding-block: 40px; }
  .mk-standard-hero .mekko-hero__media { height: clamp(260px, 75vw, 400px); }
  .mekko-feature-set.mk-product-features .mekko-feature-card__visual,
  .mk-ex-page .mk-ex-features .mekko-feature-card__visual { height: 195px; }
}
