/**
 * Straightline merchandising overrides — Product Kits (and future Add-ons).
 */

/* Kit configurator component cards — match shop card look on dark site */
body.custom-background .pk-kit-component-cards .product-title,
body.custom-background .pk-kit-component-cards .product-title a,
body.custom-background .pk-kit-component-cards .price,
body.custom-background .pk-kit-component-cards .price .woocommerce-Price-amount,
body.custom-background .pk-kit-component-cards .product-stock span,
body.custom-background .pk-kit-line-item__label,
body.custom-background .pk-kit-line-item__price,
body.custom-background .pk-kit-configurator__summary .pk-kit-sidebar-item__title,
body.custom-background .pk-kit-configurator__summary .pk-kit-sidebar-item__title a,
body.custom-background .pk-kit-configurator__summary .price,
body.custom-background .pk-kit-configurator__summary .pk-kit-configurator__total-amount,
body.custom-background .pk-kit-configurator__summary .pk-kit-configurator__total-label {
  color: #fff !important;
}

/* Keep kit product title/price/stock white on hover — no color shift. */
body.custom-background .pk-kit-component-cards .product:hover .product-title,
body.custom-background .pk-kit-component-cards .product:hover .product-title a,
body.custom-background .pk-kit-component-cards .product:hover .price,
body.custom-background .pk-kit-component-cards .product:hover .price .woocommerce-Price-amount,
body.custom-background .pk-kit-component-cards .product:hover .product-stock,
body.custom-background .pk-kit-component-cards .product:hover .product-stock span {
  color: #fff !important;
}

body.custom-background .pk-kit-configurator__summary .pk-kit-sidebar-item {
  border-bottom-color: rgba(255, 255, 255, 0.2);
}

body.custom-background .pk-kit-configurator__summary .pk-kit-configurator__line-items {
  border-top-color: rgba(255, 255, 255, 0.2);
}

body.custom-background .pk-kit-configurator__summary .pk-kit-variation-row select,
body.custom-background .pk-kit-card__variations .pk-kit-variation-row select {
  background-color: #fff;
  color: #212529;
}

body.custom-background .pk-kit-variation-row label,
body.custom-background .pk-kit-configurator__summary .pk-kit-variation-row label,
body.custom-background .pk-kit-card__variations .pk-kit-variation-row label {
  color: #fff !important;
}

/* Main kit gallery keeps a light surface; component product images do not. */
body.custom-background .pk-kit-product-gallery:not(.pk-kit-product-gallery--component) .pk-kit-gallery-main-wrap {
  background-color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}

body.custom-background .pk-kit-component-cards .thumbnail-wrapper,
body.custom-background .pk-kit-component-cards .pk-kit-gallery-main-wrap {
  background-color: transparent;
  border-color: transparent;
}

body.custom-background .pk-kit-product-gallery .pk-kit-gallery-thumb {
  background-color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}

body.custom-background .pk-kit-product-gallery .pk-kit-gallery-thumb.is-active,
body.custom-background .pk-kit-product-gallery .pk-kit-gallery-thumbs .slider-item.slick-current .pk-kit-gallery-thumb {
  border-color: #fff;
}

body.custom-background .pk-kit-component-cards .thumbnail-wrapper img {
  opacity: 1 !important;
  visibility: visible !important;
}

body.custom-background .pk-kit-card__accordion-trigger,
body.custom-background .pk-kit-card__accordion-trigger:hover,
body.custom-background .pk-kit-card__accordion-panel,
body.custom-background .pk-kit-card__accordion-panel p,
body.custom-background .pk-kit-card__accordion-panel li,
body.custom-background .pk-kit-card__accordion-panel td,
body.custom-background .pk-kit-card__accordion-panel th {
  color: rgba(255, 255, 255, 0.92) !important;
}

body.custom-background .pk-kit-component-cards .product-title a:hover,
body.custom-background .pk-kit-component-cards .product:hover .product-title a:hover,
body.custom-background .pk-kit-configurator__summary .pk-kit-sidebar-item__title a:hover {
  color: #fff !important;
  text-decoration: none;
}

body.custom-background .pk-kit-card__accordion {
  border-top-color: rgba(255, 255, 255, 0.2);
}

body.custom-background .pk-kit-card__accordion-item {
  border-bottom-color: rgba(255, 255, 255, 0.2);
}

body.custom-background .pk-kit-configurator__description {
  border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
  color: #fff !important;
}

body.custom-background .pk-kit-product-gallery .pk-kit-gallery-thumb__play {
  border-color: transparent transparent transparent #fff;
}

/* Force kit description readable on dark BG — editor/inline span colors often win otherwise */
body.custom-background .pk-kit-configurator__description-title,
body.custom-background .pk-kit-configurator__description-content,
body.custom-background .pk-kit-configurator__description-content *:not(img):not(svg):not(path) {
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.25);
}

body.custom-background .pk-kit-configurator__description-content a,
body.custom-background .pk-kit-configurator__description-content a * {
  color: #fff !important;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

body.custom-background .pk-kit-configurator__description-content a:hover,
body.custom-background .pk-kit-configurator__description-content a:hover * {
  color: rgba(255, 255, 255, 0.78) !important;
}

/* Kit top summary / intro / meta */
body.custom-background .pk-kit-configurator .product_title,
body.custom-background .pk-kit-configurator .pk-kit-configurator__intro,
body.custom-background .pk-kit-configurator .pk-kit-configurator__intro *,
body.custom-background .pk-kit-configurator .product-detail .product-meta,
body.custom-background .pk-kit-configurator .product-detail .product-meta *,
body.custom-background .pk-kit-configurator .product-identifiers,
body.custom-background .pk-kit-configurator .product-identifiers * {
  color: #fff !important;
}

body.custom-background .pk-kit-configurator .product-detail .product-meta a {
  color: #fff !important;
}

body.custom-background .pk-kit-card__accordion-trigger,
body.custom-background .pk-kit-card__accordion-trigger:hover,
body.custom-background .pk-kit-card__accordion-panel,
body.custom-background .pk-kit-card__accordion-panel *:not(img):not(svg):not(path) {
  color: rgba(255, 255, 255, 0.92) !important;
}

body.custom-background .pk-kit-related-products__link,
body.custom-background .pk-kit-related-products__title,
body.custom-background .pk-kit-related-products__price {
  color: rgba(255, 255, 255, 0.92) !important;
}

body.custom-background .pk-kit-configurator section.related.products .product-title a,
body.custom-background .pk-kit-configurator section.related.products .price,
body.custom-background .pk-kit-merchandising-footer .product-title a,
body.custom-background .pk-kit-merchandising-footer .price {
  color: #fff;
}

@media screen and (max-width: 991.98px) {
  body.custom-background .pk-kit-configurator section.related.products .product-footer-inner,
  body.custom-background .pk-kit-merchandising-footer .product-footer-inner {
    background-color: transparent !important;
    border-top: 0;
    box-shadow: none;
  }

  body.custom-background .pk-kit-configurator section.related.products .product-content-fade,
  body.custom-background .pk-kit-merchandising-footer .product-content-fade {
    display: none;
  }
}

body.custom-background .pk-kit-configurator section.related.products .klb-title .entry-title,
body.custom-background .pk-kit-merchandising-footer .klb-title .entry-title {
  color: #fff;
}

body.custom-background .pk-kit-related-products__link:hover .pk-kit-related-products__title {
  color: #ef233c !important;
}

/* PDP banner — match add-on card look on dark background */
body.custom-background .pk-kit-pdp-banner {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: border-color 0.2s ease;
}

body.custom-background .pk-kit-pdp-banner__link {
  color: #fff !important;
  transition: color 0.2s ease;
}

body.custom-background .pk-kit-pdp-banner:hover {
  border-color: #ef233c;
}

body.custom-background .pk-kit-pdp-banner:hover .pk-kit-pdp-banner__link,
body.custom-background .pk-kit-pdp-banner__link:hover {
  color: #ef233c !important;
}

/* Kit archive cards — match Partdo product cards on dark background */
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .thumbnail-wrapper {
  background-color: #fff;
}

/* White hover card surfaces are desktop-only; mobile footer is always visible */
@media screen and (min-width: 992px) {
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer-inner,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-content-fade {
    background-color: #fff;
  }

  body.custom-background .pk-kit-archive-products .pk-kit-card-inner:hover .product-title a,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner:hover .price,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner:hover .product-stock,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner:hover .product-stock i,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner:hover .product-stock span {
    color: #212529 !important;
  }
}

@media screen and (max-width: 991.98px) {
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer,
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer-inner {
    background-color: transparent !important;
    border-top: 0;
    box-shadow: none;
    margin: 0;
    padding-left: 0;
    padding-right: 0;
  }

  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-content-fade {
    display: none !important;
  }

  /* Keep a little gap between side-by-side CTAs */
  body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer .button {
    margin-top: 0.35rem;
  }
}

body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-title a,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .price,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-stock,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-stock i,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-stock span {
  color: #fff;
}

/* Kit archive CTA — match loop Add to cart / Read more (light pill + dark text) */
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer .button,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer .button.add_to_cart_button {
  background-color: #f1f3f5 !important;
  border-color: #dee2e6 !important;
  color: #212529 !important;
  -webkit-text-fill-color: #212529 !important;
  background-image: none !important;
}

body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer .button:hover,
body.custom-background .pk-kit-archive-products .pk-kit-card-inner .product-footer .button.add_to_cart_button:hover {
  background-color: var(--color-primary, #ef233c) !important;
  border-color: var(--color-primary, #ef233c) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

.pk-kit-from-label {
  margin-right: 0.25rem;
  font-size: 0.8125rem;
  font-weight: 500;
}

.pk-kit-pdp-banner {
  margin: 0.75rem 0 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--theme-theme-radius-base, 8px);
  display: block;
}

.pk-kit-pdp-banner__link {
  display: block;
  font-weight: 600;
  text-decoration: none;
}

/* Legacy slp-kit-* aliases — keep white text if an older CSS/HTML mix is deployed */
body.custom-background .slp-kit-configurator__description-title,
body.custom-background .slp-kit-configurator__description-content,
body.custom-background .slp-kit-configurator__description-content *:not(img):not(svg):not(path) {
  color: #fff !important;
}
