/*
 * WordPress-only corrections.
 *
 * assets/css/hep.css is generated from the Astro build, so template-specific
 * fixes that only apply to the WordPress side live here and are enqueued after
 * the main bundle.
 */

/* Keep compact labels readable on phones. */
@media (max-width: 760px) {
  body.solution-page main .excavator-system__parts a i,
  body.solution-page main .roller-card__link,
  body.solution-page main .generator-summary__brands b {
    font-size: max(16px, 1em) !important;
  }
}

/*
 * Product photographs are 1:1 files shot on white, but the Astro frames are
 * landscape. The square file was rendered at the frame width and then clipped
 * by overflow:hidden, so the bottom of almost every unit was cut off. The
 * plate is now square and the photograph fits inside it, which keeps the unit
 * at full size and shows all of it.
 */
body.solution-page main .part-visual--photo {
  position: relative;
  aspect-ratio: 1;
}

body.solution-page main .part-visual--photo .part-visual__photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/*
 * One white plate for every product photograph on the site. Any leftover grey
 * padding around the photo made the white areas differ from page to page, so
 * every container that holds a product shot shares the same white background.
 * Scene photographs (heroes, facilities, solution cards) keep the original
 * grey plates.
 *
 * The home hero carousel is deliberately excluded: its slides are transparent
 * cut-outs on a frosted card over the navy hero, so a white plate there reads
 * as a stray white box.
 */
main .part-visual--photo,
main .loader-product__visual,
main .generator-flow__image,
main .home-product-mini__image,
main .site-product-card .bg-light:has(> img),
main .product-detail__image-frame,
main .product-detail__visual,
main .wp-block-image {
  background-color: #fff !important;
}

/* The home hero slide is a transparent cut-out; drop the frosted card frame so
   the unit sits directly on the navy hero instead of inside a box. */
main .home-carousel__product {
  background: none !important;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

/* Let the photograph panel fill its frame instead of floating as a square
   inside a grey box, so the white area covers the whole image frame. The
   pale inner padding of the visual cell is removed as well, otherwise a
   grey ring stayed visible inside the white plate. */
body.solution-page main .excavator-system__visual {
  background-color: #fff;
  padding: 0;
}

body.solution-page main .excavator-system__art {
  min-height: 100%;
}

body.solution-page main .excavator-system__art .part-visual--photo {
  position: absolute;
  inset: auto;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  transform: none;
}

body.solution-page main .excavator-system__art .part-visual__photo {
  top: 7%;
  left: 7%;
  right: auto;
  bottom: auto;
  width: 86%;
  height: 86%;
}

/* Keep the tilted accent of the third frame on the photograph itself. */
body.solution-page main .excavator-system__art--3 .part-visual__photo {
  transform: rotate(-7deg);
}

/*
 * Product detail hero: the Astro frame painted a diagonal gradient behind the
 * photograph. Because the photograph is blended with multiply, its white
 * studio background picked up that gradient and the plate looked grey instead
 * of white. The frame is a plain white plate now.
 */
main .product-detail__image-frame {
  background: #fff !important;
  background-image: none !important;
}

/*
 * Product detail hero: every model ships four studio photographs (front,
 * label, connector, back). They are presented as one white plate plus a
 * thumbnail strip, matching the legacy catalogue behaviour.
 */
.product-detail__thumbs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}

.product-detail__thumb {
  width: 88px;
  height: 88px;
  padding: 0;
  border: 1px solid #e4eaee;
  border-radius: 0;
  background-color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  overflow: hidden;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.product-detail__thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply;
  display: block;
}

.product-detail__thumb:hover,
.product-detail__thumb:focus-visible {
  border-color: #1d60ca;
}

.product-detail__thumb.is-active,
.product-detail__thumb[aria-current="true"] {
  border-color: #1d60ca;
  box-shadow: inset 0 0 0 1px #1d60ca;
}

@media (max-width: 600px) {
  .product-detail__thumbs {
    gap: 8px;
    margin-top: 12px;
  }

  .product-detail__thumb {
    width: 72px;
    height: 72px;
  }
}

/*
 * Visitor readability fixes.
 *
 * .site-page a{color:inherit} in hep.css was winning over the button colours,
 * so the header CTA and primary buttons rendered dark navy text on blue.
 * These rules restore white text and keep the contrast above WCAG AA.
 */
.site-page a.site-header__quote,
.site-page a.site-header__quote:hover,
.site-page a.site-header__quote:focus-visible,
.site-page a.site-header__mobile-quote,
.site-page a.site-header__mobile-quote:hover,
.site-page a.site-header__mobile-quote:focus-visible,
.site-page a.btn-primary,
.site-page a.btn-primary:hover,
.site-page a.btn-primary:focus-visible,
.site-page a.product-detail__quote-button,
.site-page a.product-detail__quote-button:hover,
.site-page a.product-detail__quote-button:focus-visible {
  color: #fff;
}

/* Product card type chip: #6c757d on #f8f9fa is 4.4:1; darken to clear AA. */
.site-page .site-product-card__type.text-secondary {
  color: #495057 !important;
}

/* Key product-detail copy was 13px on desktop; lift to 14px for easier reading. */
.product-detail__notice,
.product-detail__related nav a,
.product-detail__more summary {
  font-size: 14px;
}

/* Generator summary link used the blue accent on navy (2.4:1); lighten it. */
.generator-summary a {
  color: var(--site-blue-soft, #8fc3f4) !important;
}

/* Section kickers / company name: #70808a at weight 300 reads faint; lift both. */
.site-section-kicker {
  color: #5c6b75;
  font-weight: 400;
}

/* About contact line: secondary grey on #f8f9fa sat at 4.4:1; darken it. */
.site-contact-line {
  color: #495057;
  font-size: 17px;
  font-weight: 500;
}

/* Product breadcrumb: 13px at #6a7f8c was 4.0:1; darken for AA. */
.product-detail__breadcrumb ol,
.product-detail__breadcrumb a {
  color: #556b78;
}

/* Keep the product breadcrumb at the 14px site minimum on every viewport. */
.product-detail__breadcrumb ol {
  font-size: 14px;
}

/*
 * Solution-detail readability floor.
 *
 * The ported pages used 11-13px for labels, table headers, filter controls
 * and card metadata. At normal desktop viewing distance those elements read
 * like footnotes, especially on the darker hero panels. Keep compact UI text
 * at 14px and explanatory copy at 15px so the hierarchy remains intact.
 */
body.solution-page main :is(
  .mining-kicker,
  .mining-hero__facts dt,
  .mining-form__label,
  .mining-category__body small,
  .mining-category em,
  .mining-quote__copy li,
  .diesel-label,
  .diesel-rail__head span,
  .diesel-rail__foot span,
  .diesel-rail__foot p,
  .diesel-intro__body a,
  .diesel-notes dt,
  .diesel-selector legend,
  .diesel-selector label > span,
  .diesel-platforms button,
  .diesel-selector select,
  .diesel-action,
  .diesel-directory__summary p,
  .diesel-notes-list summary span,
  .diesel-notes-list summary em,
  .diesel-reference-card > span,
  .diesel-reference-card a,
  .roller-kicker,
  .roller-hero__button,
  .roller-speed-band,
  .roller-use-card__visual > span,
  .roller-use-card p,
  .roller-use-card small,
  .roller-modules__head > span,
  .roller-tabs button,
  .roller-card__index,
  .roller-card__body > span,
  .roller-card p,
  .roller-card__link,
  .roller-note__mark span,
  .roller-note__button,
  .generator-kicker,
  .generator-button,
  .generator-summary__label,
  .generator-summary dt,
  .generator-summary__brands span,
  .generator-summary__brands b,
  .generator-summary > a,
  .generator-flow__top,
  .generator-flow__top b,
  .generator-flow p,
  .generator-flow em,
  .generator-selection p,
  .generator-config-footer span,
  .generator-config-footer p,
  .loader-kicker,
  .loader-hero__link,
  .loader-hero__caption span,
  .loader-tabs button,
  .loader-filter-group > label,
  .loader-filter-group legend,
  .loader-filter-group input[type="search"],
  .loader-filter-group select,
  .loader-check,
  .loader-check em,
  .loader-clear,
  .loader-results__head span,
  .loader-results__head p,
  .loader-product__visual > span,
  .loader-product__record,
  .loader-product p,
  .loader-product a,
  .loader-application__mark span,
  .loader-application__copy a,
  .excavator-kicker,
  .excavator-button,
  .excavator-hero__label span,
  .excavator-intro__label,
  .excavator-intro nav a,
  .excavator-system__head > p,
  .excavator-system__art-label,
  .excavator-system__content li,
  .excavator-system__parts-head,
  .excavator-system__parts a > span,
  .excavator-system__parts a > i,
  .excavator-bundle__index,
  .excavator-bundle__item div > span,
  .excavator-bundle__item p,
  .excavator-bundle__item > b,
  .excavator-bundle__foot span,
  .solution-quote__kicker,
  .solution-quote__copy li
) {
  font-size: 14px;
}

body.solution-page main .solution-table__head th,
body.solution-page main .solution-table__name small,
body.solution-page main .solution-table__action {
  font-size: 14px;
}

body.solution-page main :is(
  .diesel-notes > p:not(.diesel-label),
  .diesel-selector__copy > p:last-child,
  .diesel-references__intro > p:last-child,
  .diesel-notes-list details > p,
  .roller-note__grid > p,
  .generator-section-head > p,
  .loader-quote > p:not(.loader-kicker),
  .loader-application__copy p,
  .excavator-system__content > p,
  .excavator-bundle__head > p,
  .excavator-bundle__foot > p
) {
  font-size: 15px;
}

body.solution-page .loader-quote .quote-form input,
body.solution-page .loader-quote .quote-form textarea {
  font-size: 14px;
}

/* Keep mobile breadcrumbs and inline policy links at a 24px touch target. */
@media (max-width: 767px) {
  .site-breadcrumbs a,
  .product-detail__breadcrumb a {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
  }

  .site-content a,
  .site-policy-content a {
    padding-block: 2px;
  }

  .site-policy-content a,
  .entry-content a,
  body.solution-page main .solution-table__name a,
  body.solution-page main .solution-table__action a,
  body.solution-page main .diesel-reference-card a,
  body.solution-page main .loader-application__copy a {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
  }
}

/* Mobile solution copy needs more than the 14px desktop minimum. */
@media (max-width: 760px) {
  body.solution-page main :is(
    .mining-hero__lead,
    .mining-section-head > p,
    .mining-categories__intro > p:last-child,
    .mining-quote__copy > p:not(.mining-kicker),
    .mining-quote__copy li,
    .diesel-rail__foot p,
    .diesel-intro__body p,
    .diesel-notes > p:not(.diesel-label),
    .diesel-selector__copy > p:last-child,
    .diesel-references__intro > p:last-child,
    .diesel-notes-list details > p,
    .roller-section-head > p,
    .roller-use-card p,
    .roller-note__grid > p,
    .generator-hero__copy > p:not(.generator-kicker),
    .generator-section-head > p,
    .generator-flow p,
    .generator-config-footer p,
    .loader-hero__copy > p:not(.loader-kicker),
    .loader-results__head p,
    .loader-results__empty,
    .loader-product p,
    .loader-quote > p:not(.loader-kicker),
    .loader-application__copy p,
    .excavator-hero__copy > p:not(.excavator-kicker),
    .excavator-system__content > p,
    .excavator-system__content li,
    .excavator-bundle__head > p,
    .excavator-bundle__item p,
    .excavator-bundle__foot > p,
    .solution-quote__copy p,
    .solution-quote__copy li
  ) {
    font-size: 18px;
    line-height: 1.68;
  }

  body.solution-page main :is(
    .mining-kicker,
    .mining-hero__facts dt,
    .mining-form__label,
    .mining-category__body small,
    .mining-category em,
    .diesel-label,
    .diesel-rail__head span,
    .diesel-rail__foot span,
    .diesel-rail nav a,
    .diesel-intro__body a,
    .diesel-notes dt,
    .diesel-platforms button,
    .diesel-selector legend,
    .diesel-selector label > span,
    .diesel-selector select,
    .diesel-action,
    .diesel-notes-list summary span,
    .diesel-notes-list summary em,
    .diesel-reference-card > span,
    .diesel-reference-card a,
    .roller-kicker,
    .roller-hero__button,
    .roller-speed-band,
    .roller-use-card small,
    .roller-tabs button,
    .roller-card__body > span,
    .roller-card__link,
    .roller-note__button,
    .generator-kicker,
    .generator-button,
    .generator-summary__label,
    .generator-summary dt,
    .generator-summary__brands span,
    .generator-summary__brands b,
    .generator-summary > a,
    .generator-flow__top,
    .generator-flow__top b,
    .generator-config-footer span,
    .loader-kicker,
    .loader-hero__link,
    .loader-tabs button,
    .loader-filter-group > label,
    .loader-filter-group select,
    .loader-filter-group input[type="search"],
    .loader-check,
    .loader-clear,
    .loader-product a,
    .loader-application__copy a,
    .excavator-kicker,
    .excavator-button,
    .excavator-system__head > p,
    .excavator-system__parts-head,
    .excavator-system__parts a > span,
    .excavator-system__parts a > i,
    .excavator-bundle__index,
    .excavator-bundle__item div > span,
    .excavator-bundle__item > b,
    .excavator-bundle__foot span,
    .solution-table__head th,
    .solution-table__action
  ) {
    font-size: 16px;
  }
}

/* Sitewide mobile reading scale: navigation and UI text 16px, prose 17px. */
@media (max-width: 760px) {
  body.site-page {
    font-size: 17px;
  }

  .site-header__mobile-nav details ul a,
  .site-header__mobile-contact > span,
  .site-header__mobile-contact a,
  .site-header__mobile-quote,
  .site-header__mobile-search,
  .site-header__quote-short,
  .site-header__language-code,
  .site-header__language-option-name,
  .site-header__language-option-code {
    font-size: 16px;
  }

  .site-footer p,
  .site-footer a:not(.footer-mark) {
    font-size: 16px;
    line-height: 1.6;
  }

  .site-footer__base {
    font-size: 16px;
  }

  .site-breadcrumbs {
    font-size: 16px;
  }

  .site-page-hero__keywords a {
    font-size: 16px;
  }

  .site-product-card__title {
    font-size: 18px;
    line-height: 1.4;
  }

  .site-product-card__excerpt,
  .site-product-card__type {
    font-size: 16px;
    line-height: 1.6;
  }

  .site-product-card__action,
  .site-solution-card__action,
  .home-solution-card__more {
    font-size: 16px;
  }

  .site-solution-card__body p {
    font-size: 17px;
    line-height: 1.7;
  }

  .site-pagination a,
  .site-pagination span {
    font-size: 16px;
  }

  .site-product-facts dt,
  .site-product-facts dd,
  .site-check-list li {
    font-size: 16px;
    line-height: 1.7;
  }

  .site-contact-panel small {
    font-size: 16px;
  }

  .site-contact-panel address > a {
    font-size: 17px;
  }

  .entry-content,
  .site-content,
  .site-policy-content,
  .entry-content p,
  .entry-content li,
  .site-content p,
  .site-content li,
  .site-policy-content p,
  .site-policy-content li {
    font-size: 17px;
    line-height: 1.75;
  }

  .site-page .btn,
  .site-page .btn-sm,
  .quote-form__label,
  .quote-form label {
    font-size: 16px;
  }

  .quote-form input:not([type="hidden"]),
  .quote-form textarea {
    font-size: 17px;
  }

  .product-detail__breadcrumb ol,
  .product-detail__breadcrumb a,
  .product-detail__tabs a,
  .product-detail__facts > div,
  .product-detail__contact a,
  .product-detail__related nav a,
  .product-detail__more summary,
  .product-detail__check-row > p {
    font-size: 16px;
  }

  .product-detail__notice {
    font-size: 16px;
    line-height: 1.7;
  }

  .product-detail__overview-copy p,
  .product-detail__rich {
    font-size: 17px;
  }

  .product-detail__visual figcaption,
  .product-detail__more-note {
    font-size: 15px;
  }
}
/* Alternate the HVAC bundle and inquiry panels so two dark bands never touch. */
body.solution-page--hvac-refrigeration-solution .excavator-bundle {
  background: var(--site-surface);
  color: var(--site-text);
  border-top: 1px solid var(--site-line);
}

body.solution-page--hvac-refrigeration-solution .excavator-bundle__head h2,
body.solution-page--hvac-refrigeration-solution .excavator-bundle__item h3 {
  color: var(--site-navy);
}

body.solution-page--hvac-refrigeration-solution
  .excavator-bundle__head
  > p,
body.solution-page--hvac-refrigeration-solution .excavator-bundle__item p {
  color: var(--site-muted);
}

body.solution-page--hvac-refrigeration-solution .excavator-bundle__grid,
body.solution-page--hvac-refrigeration-solution .excavator-bundle__item {
  border-color: var(--site-line-strong);
}

body.solution-page--hvac-refrigeration-solution .excavator-bundle__item:hover,
body.solution-page--hvac-refrigeration-solution
  .excavator-bundle__item:focus-visible {
  background: var(--site-surface-strong);
}

body.solution-page--hvac-refrigeration-solution
  .excavator-bundle__item
  div
  > span,
body.solution-page--hvac-refrigeration-solution .excavator-bundle__item > b {
  color: var(--site-blue);
}

