/* EYG Homepage Visual Polish v1.0.0 — scoped to the existing Homepage Manager. */
/* Preserve complete promotion artwork; use soft fill behind images with unusual aspect ratios. */
.eyg-home .eyg-promo-carousel {
  aspect-ratio: 2.18 / 1 !important;
  margin: 28px auto 38px !important;
  border-radius: 12px !important;
  background: #f3f5f2 !important;
  box-shadow: 0 8px 24px rgba(16, 36, 20, .10) !important;
}
.eyg-home .eyg-dealer-banner {
  isolation: isolate;
  overflow: hidden;
  background-size: 0 0 !important; /* foreground drawn by ::after without cropping */
  background-color: #eef1ed !important;
}
.eyg-home .eyg-dealer-banner::before,
.eyg-home .eyg-dealer-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: inherit;
  background-position: center;
  background-repeat: no-repeat;
}
.eyg-home .eyg-dealer-banner::before {
  z-index: 0;
  inset: -20px;
  background-size: cover;
  filter: blur(18px) saturate(.85);
  opacity: .28;
}
.eyg-home .eyg-dealer-banner::after {
  z-index: 1;
  background-size: contain;
}
/* Smaller unobtrusive circular controls; keep accessible tap areas. */
.eyg-home .eyg-promo-prev,
.eyg-home .eyg-promo-next {
  width: 42px !important;
  height: 42px !important;
  border-radius: 50% !important;
  background: rgba(17, 34, 24, .76) !important;
  color: #fff !important;
  font-size: 32px !important;
  line-height: 1 !important;
  padding: 0 !important;
  box-shadow: 0 2px 8px rgba(0,0,0,.16);
}
.eyg-home .eyg-promo-prev {left: 14px !important;}
.eyg-home .eyg-promo-next {right: 14px !important;}
.eyg-home .eyg-promo-prev:hover,
.eyg-home .eyg-promo-next:hover {background: #267c28 !important;}
.eyg-home .eyg-promo-prev:focus-visible,
.eyg-home .eyg-promo-next:focus-visible,
.eyg-home .eyg-promo-dots button:focus-visible {outline: 3px solid #58b91f; outline-offset: 3px;}
.eyg-home .eyg-promo-dots {bottom: 10px !important; padding: 6px 9px !important;}
/* Equal visual spaces for each maker while preserving source logo proportions. */
.eyg-home .eyg-brands > div {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr)) !important;
  align-items: center !important;
  column-gap: 16px !important;
  row-gap: 14px !important;
}
.eyg-home .eyg-brand-item {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 92px !important;
  height: 92px !important;
  padding: 10px 12px !important;
}
.eyg-home .eyg-brand-item img {
  width: 100% !important;
  max-width: 165px !important;
  height: 68px !important;
  max-height: 68px !important;
  object-fit: contain !important;
}
@media (max-width: 760px) {
  .eyg-home .eyg-promo-carousel {aspect-ratio: 1.7 / 1 !important; margin: 20px auto 30px !important;}
  .eyg-home .eyg-promo-prev,
  .eyg-home .eyg-promo-next {width: 36px !important; height: 36px !important; font-size: 28px !important;}
  .eyg-home .eyg-promo-prev {left: 7px !important;}
  .eyg-home .eyg-promo-next {right: 7px !important;}
  .eyg-home .eyg-brands > div {grid-template-columns: repeat(2, minmax(0, 1fr)) !important;}
}
@media (prefers-reduced-motion: reduce) {
 .eyg-home .eyg-promo-prev, .eyg-home .eyg-promo-next {transition: none !important;}
}

/* v1.1.0: Balanced manufacturer brand grid — four columns on desktop/tablet,
   two on phones. All marks fit in identical logo cells without distortion. */
.eyg-home .eyg-brands > div {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  column-gap: 20px !important;
  row-gap: 18px !important;
  justify-content: center !important;
  padding-top: 24px !important;
}
.eyg-home .eyg-brand-item {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  width: 100% !important;
  height: 102px !important;
  min-height: 102px !important;
  padding: 16px !important;
  border-radius: 8px !important;
  background: #fff !important;
}
.eyg-home .eyg-brand-item img {
  display: block !important;
  width: 100% !important;
  max-width: 190px !important;
  height: 68px !important;
  max-height: 68px !important;
  object-fit: contain !important;
  object-position: center !important;
  margin: 0 auto !important;
}
/* Optical balancing for images with more empty margin or smaller artwork.
   Transform scales the whole image uniformly (no stretching or cropping). */
.eyg-home .eyg-brand-item img[alt="Husqvarna"],
.eyg-home .eyg-brand-item img[alt="HONDA"] {transform: scale(1.22);}
.eyg-home .eyg-brand-item img[alt="WRIGHT"] {transform: scale(1.08);}
@media (max-width: 760px) {
  .eyg-home .eyg-brands > div {grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 12px !important;}
  .eyg-home .eyg-brand-item {height: 88px !important; min-height: 88px !important; padding: 12px !important;}
  .eyg-home .eyg-brand-item img {height: 60px !important; max-height: 60px !important;}
}
