.eco-product-card__media-gallery { position: relative; aspect-ratio: 1; overflow: hidden; background: var(--eco-beige); }
.eco-product-card__media { display: block; width: 100%; height: 100%; overflow: hidden; }
.eco-product-card__media-track { display: flex; width: 100%; height: 100%; transition: transform 420ms cubic-bezier(.22,1,.36,1); will-change: transform; }
.eco-product-card__image { flex: 0 0 100%; width: 100%; height: 100%; aspect-ratio: 1; object-fit: contain; background: var(--eco-beige); }
.eco-product-card:hover .eco-product-card__image { transform: none; }
.eco-card-gallery__arrow { position: absolute; z-index: 3; top: 50%; width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid rgba(47,71,57,.18); border-radius: 50%; opacity: 0; color: var(--eco-forest-dark); background: rgba(255,255,255,.94); box-shadow: 0 4px 14px rgba(47,71,57,.1); cursor: pointer; transform: translateY(-50%); transition: opacity 180ms ease, transform 220ms cubic-bezier(.22,1,.36,1); }
.eco-card-gallery__arrow--prev { left: 10px; }
.eco-card-gallery__arrow--next { right: 10px; }
.eco-product-card__media-gallery:hover .eco-card-gallery__arrow,
.eco-product-card__media-gallery:focus-within .eco-card-gallery__arrow { opacity: 1; }
.eco-card-gallery__dots { position: absolute; z-index: 3; right: 58px; bottom: 12px; left: 58px; display: flex; justify-content: center; gap: 3px; pointer-events: none; }
.eco-card-gallery__dots button { position: relative; width: 22px; height: 22px; padding: 0; border: 0; background: transparent; pointer-events: auto; cursor: pointer; }
.eco-card-gallery__dots button::after { content: ""; position: absolute; inset: 8px; border: 1px solid var(--eco-forest); border-radius: 50%; background: rgba(255,255,255,.86); }
.eco-card-gallery__dots button[aria-current="true"]::after { background: var(--eco-forest); transform: scale(1.2); }

@media (max-width: 767px), (hover: none) {
  .eco-card-gallery__arrow { width: 44px; height: 44px; opacity: 1; }
  .eco-card-gallery__arrow--prev { left: 5px; }
  .eco-card-gallery__arrow--next { right: 5px; }
  .eco-card-gallery__dots { right: 45px; bottom: 6px; left: 45px; }
  .eco-product-card__media-gallery { touch-action: pan-y; }
}

@media (prefers-reduced-motion: reduce) {
  .eco-product-card__media-track,
  .eco-card-gallery__arrow { transition-duration: .01ms !important; }
}

.eco-product-gallery { position: sticky; top: 178px; display: grid; grid-template-columns: 82px minmax(0,1fr); gap: 14px; align-items: start; }
.eco-product-gallery__thumbs { display: grid; gap: 10px; max-height: 660px; overflow-y: auto; scrollbar-width: thin; }
.eco-product-gallery__thumbs button { width: 76px; height: 76px; padding: 3px; overflow: hidden; border: 1px solid var(--eco-border); border-radius: 8px; background: var(--eco-white); cursor: pointer; }
.eco-product-gallery__thumbs button[aria-selected="true"] { border-color: var(--eco-forest); box-shadow: 0 0 0 1px var(--eco-forest); }
.eco-product-gallery__thumbs img { width: 100%; height: 100%; object-fit: contain; }
.eco-product-gallery__stage { position: relative; min-width: 0; }
.eco-product-gallery__main { width: 100%; display: block; aspect-ratio: 1; padding: 0; overflow: hidden; border: 0; border-radius: var(--eco-radius-lg); background: var(--eco-beige); cursor: zoom-in; }
.eco-product-gallery__track { display: flex; width: 100%; height: 100%; transition: transform 420ms cubic-bezier(.22,1,.36,1); will-change: transform; }
.eco-product-gallery__track img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: contain; }
.eco-product-gallery__arrow { position: absolute; z-index: 2; top: 50%; width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid var(--eco-border); border-radius: 50%; color: var(--eco-forest-dark); background: rgba(255,255,255,.94); box-shadow: var(--eco-shadow-sm); font-size: 27px; cursor: pointer; transform: translateY(-50%); }
.eco-product-gallery__arrow--prev { left: 14px; }
.eco-product-gallery__arrow--next { right: 14px; }
.eco-product-gallery__counter { position: absolute; right: 14px; bottom: 14px; padding: 5px 10px; border-radius: 999px; color: white; background: rgba(47,71,57,.78); font-size: 12px; font-weight: 700; }
.eco-product-gallery__dots { display: none; justify-content: center; gap: 3px; margin-top: 9px; }
.eco-product-gallery__dots button { position: relative; width: 30px; height: 30px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.eco-product-gallery__dots button::after { content: ""; position: absolute; inset: 11px; border: 1px solid var(--eco-forest); border-radius: 50%; }
.eco-product-gallery__dots button[aria-current="true"]::after { background: var(--eco-forest); transform: scale(1.25); }
.eco-gallery-lightbox { position: fixed; z-index: 2500; inset: 0; display: grid; grid-template-columns: 60px minmax(0,1fr) 60px; place-items: center; padding: 24px; background: rgba(8,25,16,.94); }
.eco-gallery-lightbox__image { max-width: 100%; max-height: calc(100vh - 48px); object-fit: contain; }
.eco-gallery-lightbox button { width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.45); border-radius: 50%; color: white; background: rgba(47,71,57,.72); font-size: 27px; cursor: pointer; }
.eco-gallery-lightbox__close { position: absolute; top: 18px; right: 18px; }
.eco-gallery-lightbox__status { position: absolute; bottom: 18px; left: 50%; padding: 6px 12px; border-radius: 999px; color: white; background: rgba(47,71,57,.75); transform: translateX(-50%); }

@media (max-width: 767px) {
  .eco-product-gallery { position: static; display: block; }
  .eco-product-gallery__thumbs { display: none; }
  .eco-product-gallery__main { width: calc(100% + (2 * var(--eco-gutter))); margin-left: calc(-1 * var(--eco-gutter)); border-radius: 0; touch-action: pan-y; }
  .eco-product-gallery__arrow { width: 44px; height: 44px; }
  .eco-product-gallery__dots { display: flex; }
  .eco-product-gallery__counter { display: none; }
  .eco-gallery-lightbox { grid-template-columns: 46px minmax(0,1fr) 46px; padding: 12px; }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .eco-product-gallery { top: 126px; }
}

@media (prefers-reduced-motion: reduce) {
  .eco-product-gallery__track { transition-duration: .01ms !important; }
}
