/**
 * Global visibility / contrast polish — breadcrumbs, muted text, pills, forms.
 * Loaded last so it wins over older theme layers.
 */

/* --------------------------------------------------------------------------
   Breadcrumbs — always readable
   -------------------------------------------------------------------------- */
.terea-breadcrumb {
  background: #f7f7f5;
  border-bottom: 1px solid #e5e5e5;
  color: #374151;
}

.terea-breadcrumb-item > a,
.terea-breadcrumb-item > span:not(.terea-breadcrumb-sep) {
  background: #fff;
  color: #111 !important;
  border: 1px solid #d1d5db;
  font-weight: 600;
}

.terea-breadcrumb-item:first-child > a,
.terea-breadcrumb-item:first-child > span {
  background: #111 !important;
  color: #fff !important;
  border-color: #111 !important;
}

.terea-breadcrumb-item > a:hover {
  background: #111 !important;
  color: #fff !important;
  border-color: #111 !important;
}

.terea-breadcrumb-item.is-current > span {
  background: #fff !important;
  color: #111 !important;
  border-color: #111 !important;
  font-weight: 700;
}

.terea-breadcrumb-sep {
  color: #6b7280;
  opacity: 1;
}

/* --------------------------------------------------------------------------
   Footer bottom bar — readable on every page, including product
   -------------------------------------------------------------------------- */
.wh-site-footer .footer-bottom,
body.single-product .wh-site-footer .footer-bottom,
body.woocommerce .wh-site-footer .footer-bottom {
  background: #ecece8 !important;
  border-top: 1px solid #d8d8d4 !important;
}

.wh-site-footer .footer-copyright,
.wh-site-footer .footer-bottom p,
.wh-site-footer .footer-bottom .widget,
.wh-site-footer .footer-bottom .widget p,
body.single-product .wh-site-footer .footer-copyright,
body.woocommerce .wh-site-footer .footer-copyright {
  color: #1f2937 !important;
  opacity: 1 !important;
}

.wh-site-footer .footer-bottom-links a,
.wh-site-footer .footer-bottom a,
body.single-product .wh-site-footer .footer-bottom-links a,
body.woocommerce .wh-site-footer .footer-bottom a {
  color: #111 !important;
  opacity: 1 !important;
}

.wh-site-footer .footer-bottom-links a:hover,
.wh-site-footer .footer-bottom a:hover {
  color: var(--tx-accent, #c8102e) !important;
}

/* WooCommerce default breadcrumb (single pill) */
.woocommerce-breadcrumb {
  background: #fff !important;
  border: 1px solid #d1d5db !important;
  color: #111 !important;
  box-shadow: none;
}

.woocommerce-breadcrumb a {
  color: #111 !important;
  font-weight: 600;
}

.woocommerce-breadcrumb a:hover {
  color: var(--tx-accent, #c8102e) !important;
}

.woocommerce-breadcrumb .separator {
  color: #6b7280 !important;
  opacity: 1;
}

/* Dark archive hero — keep crumbs bright, no white-on-white */
.wh-archive-hero .wh-archive-breadcrumb .woocommerce-breadcrumb,
.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 0 14px !important;
  color: rgba(255, 255, 255, 0.92) !important;
}

.wh-archive-hero .wh-archive-breadcrumb a,
.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item > a,
.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item > span:not(.terea-breadcrumb-sep) {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
}

.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item:first-child > a,
.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item:first-child > span,
.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item.is-current > span {
  background: #fff !important;
  color: #111 !important;
  border-color: #fff !important;
}

.wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-sep {
  color: rgba(255, 255, 255, 0.7) !important;
}

/* Product page crumbs */
.wh-product-breadcrumb .woocommerce-breadcrumb,
.wh-product-breadcrumb .terea-breadcrumb {
  color: #374151 !important;
}

.wh-product-breadcrumb a {
  color: #111 !important;
}

/* --------------------------------------------------------------------------
   Category strip / pills / chips
   -------------------------------------------------------------------------- */
.i3d-cat-strip__link {
  color: #1a1a1a !important;
  border-color: #e4e4e1 !important;
  background: #fff !important;
}

.i3d-cat-strip__link:hover,
.i3d-cat-strip__link:focus-visible,
.i3d-cat-strip__link.is-active {
  background: #111 !important;
  color: #fff !important;
  border-color: #111 !important;
}

.i3d-cat-strip__link--all {
  background: var(--tx-btn-secondary, #111) !important;
  border-color: var(--tx-btn-secondary, #111) !important;
  color: #fff !important;
}

.i3d-cat-strip__link--all:hover,
.i3d-cat-strip__link--all:focus-visible {
  background: var(--tx-btn-hover, var(--tx-accent, #c8102e)) !important;
  border-color: var(--tx-btn-hover, var(--tx-accent, #c8102e)) !important;
  color: #fff !important;
}

.i3d-compare__pill {
  color: #111 !important;
  border-color: #cfd4da !important;
  background: #fff !important;
}

.i3d-compare__pill.is-active {
  background: #111 !important;
  color: #fff !important;
  border-color: #111 !important;
}

.i3d-chip {
  color: #1f2937 !important;
  border-color: #cfd4da !important;
  background: #fff !important;
}

.i3d-kicker {
  color: #000000 !important;
}

/* Beat Customizer “white kicker” CSS on light surfaces */
body .i3d-kicker:not(.i3d-kicker--light):not(.i3d-kicker--on-dark),
.i3d-hero--split .i3d-kicker,
.i3d-section-head .i3d-kicker,
.i3d-intro .i3d-kicker,
.i3d-intro__copy .i3d-kicker,
.i3d-spotlight__copy .i3d-kicker,
.i3d-range .i3d-kicker,
.i3d-featured .i3d-kicker,
.i3d-process .i3d-kicker,
.i3d-brand .i3d-kicker,
.i3d-compare .i3d-kicker,
.i3d-checklist .i3d-kicker,
.i3d-metrics .i3d-kicker,
.i3d-about-hero .i3d-kicker,
.i3d-about-story .i3d-kicker,
.i3d-about-vision .i3d-kicker,
.i3d-about-values .i3d-kicker,
.wh-closeups .i3d-kicker,
.front-page-main .i3d-kicker:not(.i3d-kicker--light):not(.i3d-kicker--on-dark) {
  color: #6b7280 !important;
}

.i3d-intro__copy .i3d-kicker {
  color: var(--tx-accent, #c8102e) !important;
}

.i3d-about-dark .i3d-kicker,
.i3d-consult--campaign .i3d-kicker,
.i3d-kicker--light,
.i3d-kicker--on-dark {
  color: rgba(255, 255, 255, 0.82) !important;
}

.i3d-about-team .i3d-kicker--gold,
.i3d-kicker--gold {
  color: var(--i3d-gold, #b08a4a) !important;
}

.i3d-hero--split .i3d-hero__title {
  color: #111 !important;
  text-shadow: none;
}

.i3d-hero--split .i3d-hero__lead {
  color: #4b5563 !important;
  text-shadow: none;
}

.i3d-hero--split .i3d-hero__media {
  min-height: auto;
  padding: 0;
}

.i3d-hero--split .i3d-hero__media img {
  object-fit: contain !important;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  border-radius: 18px;
}

.site-footer,
.wh-site-footer {
  margin-top: 0 !important;
}

.wh-product-main.wh-kseries {
  padding-bottom: 0;
}

.i3d-range {
  background: #e9e9e9;
}

.wh-landing-masthead__title {
  min-width: 60% !important;
}

.wh-announce,
.wh-header-phone,
.i3d-subnav {
  display: none !important;
}

.i3d-archive ul.products .terea-product-card-media img,
.i3d-archive ul.products > li .terea-product-card-media img,
.wh-archive-main--cards ul.products .terea-product-card-media img,
.wh-archive-main--cards ul.products > li .terea-product-card-media img,
.terea-product-card .terea-product-card-media img {
  object-fit: contain !important;
  object-position: center !important;
  padding: 18px !important;
  background: #fff !important;
  border-radius: 12px !important;
  box-sizing: border-box !important;
  transform: none !important;
}

.wh-archive-main--cards .wh-cat-card__media img,
.i3d-archive .wh-cat-card__media img {
  object-fit: contain !important;
  object-position: center center !important;
  padding: 18px !important;
  width: 100% !important;
  height: 100% !important;
  background: transparent !important;
}

.wh-archive-main--cards .terea-product-card-media,
.i3d-archive .terea-product-card-media,
.terea-product-card .terea-product-card-media {
  background: #f4f4f2 !important;
  border-radius: 16px 16px 0 0 !important;
  padding: 18px !important;
  overflow: hidden !important;
}

.i3d-archive .terea-product-card-quick {
  display: none !important;
}

/* Light surfaces only — dark sections define their own lead colours */
.i3d-section-lead,
.i3d-modal__hint {
  color: #374151 !important;
}

.wh-rnd-problem .i3d-section-lead,
.i3d-about-dark .i3d-section-lead,
.i3d-consult--campaign .i3d-section-lead,
.i3d-hero--dark .i3d-section-lead,
[class*="--dark"] .i3d-section-lead {
  color: rgba(255, 255, 255, 0.86) !important;
}

/* --------------------------------------------------------------------------
   Page / blog / shop text floors
   -------------------------------------------------------------------------- */
body {
  color: var(--tx-text, #141414);
}

.entry-content,
.wh-site-page,
.wh-archive-main,
.wh-product-main,
.blog-main,
.terea-page-content {
  color: #141414;
}

.entry-content a,
.wh-site-page a:not(.i3d-btn):not(.wh-header-cta):not(.button) {
  color: #111;
}

.entry-content a:hover {
  color: var(--tx-accent, #c8102e);
}

/* Muted text must stay WCAG-friendly on white */
.terea-page-header p,
.wh-archive-lead,
.wh-overview-lead,
.post-card-excerpt,
.terea-empty-desc,
.woocommerce-result-count {
  color: #4b5563 !important;
}

/* --------------------------------------------------------------------------
   Forms — visible fields
   -------------------------------------------------------------------------- */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="number"],
input[type="search"],
input[type="password"],
select,
textarea {
  color: #111 !important;
  background: #fff !important;
  border-color: #c4c9d0 !important;
}

input::placeholder,
textarea::placeholder {
  color: #6b7280 !important;
  opacity: 1;
}

/* --------------------------------------------------------------------------
   Mobile readability
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .terea-breadcrumb-item > a,
  .terea-breadcrumb-item > span:not(.terea-breadcrumb-sep),
  .woocommerce-breadcrumb {
    font-size: 12px !important;
  }

  .i3d-cat-strip__link {
    min-height: 44px;
    padding: 0 14px;
    font-size: 11px;
  }

  .wh-archive-hero .wh-archive-breadcrumb a,
  .wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item > a,
  .wh-archive-hero .wh-archive-breadcrumb .terea-breadcrumb-item > span:not(.terea-breadcrumb-sep) {
    font-size: 11px !important;
  }

  /* Header CTA — force compact label (avoid REQUEST INFO overflow) */
  .wh-header-cta-full {
    display: none !important;
  }
  .wh-header-cta-short {
    display: inline !important;
  }
  .wh-header-cta {
    padding: 0 12px !important;
    min-height: 40px !important;
    min-width: 0 !important;
    font-size: 12px !important;
    letter-spacing: 0.01em !important;
  }
}

/* --------------------------------------------------------------------------
   Checklist modal polish
   -------------------------------------------------------------------------- */
.i3d-modal__tabs {
  overflow-x: auto !important;
}

.i3d-table__blank {
  display: block !important;
  width: 100%;
  min-height: 44px !important;
  border: 1.5px solid #9aa3ad !important;
  border-style: solid !important;
  border-radius: 8px !important;
  background: #f8fafc !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
}

.i3d-table-wrap:not(.i3d-table-wrap--scroll) tr {
  background: #fff !important;
}

.i3d-modal__tab.is-active {
  box-shadow: 0 6px 16px rgba(20, 20, 20, 0.18);
}

/* Product page — mobile breadcrumb must stay flat (not a bulky pill) */
.wh-product-breadcrumb .woocommerce-breadcrumb,
.wh-product-breadcrumb .terea-breadcrumb {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 0 12px !important;
  border-radius: 0 !important;
  color: #6b7280 !important;
}

.wh-product-breadcrumb .woocommerce-breadcrumb a,
.wh-product-breadcrumb a {
  color: #374151 !important;
  font-weight: 600;
}

/* Soften announce bar on product pages so it doesn't compete */
body.single-product .wh-announce {
  padding: 6px 12px;
  font-size: 10px;
}

body.single-product .wh-announce p {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 1440px) {
  .i3d-hero__copy,
  .i3d-hero--split .i3d-hero__copy {
    padding: 50px;
  }
}

@media (max-width: 1024px) {
  .i3d-hero__copy,
  .i3d-hero--split .i3d-hero__copy {
    padding: 40px;
  }
}

@media (max-width: 720px) {
  body.single-product .wh-announce {
    display: none;
  }

  .i3d-hero__copy,
  .i3d-hero__content,
  .i3d-hero--split .i3d-hero__copy {
    padding: 20px 0 !important;
  }

  .i3d-cat-strip {
    padding: 10px 0;
  }

  .i3d-cat-strip__inner {
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }

  .i3d-modal__tabs {
    padding-top: 30px !important;
    padding-bottom: 30px !important;
  }

  .wh-banner-inner {
    padding: 72px 30px 35px !important;
  }

  /* Keep hero usable on small screens — equal top/bottom padding */
  .i3d-hero--split {
    padding: 20px 0 24px !important;
  }

  .wh-banner-actions {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }

  .wh-banner-actions .wh-btn {
    background-image: none !important;
  }

  .wh-banner-actions .wh-btn--light {
    background: #fff !important;
    color: #111 !important;
  }

  .wh-banner-actions .wh-btn--outline-light {
    background: rgba(255, 255, 255, 0.12) !important;
    color: #fff !important;
    border: 1.5px solid rgba(255, 255, 255, 0.8) !important;
  }
}

@media (max-width: 420px) {
  .wh-banner-actions {
    grid-template-columns: 1fr !important;
  }
}

/* Online PDP — compact buy controls (override legacy Woo button bloat) */
body.single-product .wh-online-product .wh-online-cart form.cart {
  align-items: center !important;
}

body.single-product .wh-online-product .wh-online-cart .quantity .qty {
  width: 72px !important;
  max-width: 72px !important;
  height: 48px !important;
  min-height: 48px !important;
  border-radius: 8px !important;
}

body.single-product .wh-online-product .wh-online-cart button.single_add_to_cart_button {
  flex: 1 1 auto !important;
  height: 48px !important;
  min-height: 48px !important;
  max-height: 48px !important;
  padding: 0 20px !important;
  border-radius: 8px !important;
  line-height: 1 !important;
}

body.single-product .wh-online-product .wh-gallery__stage {
  aspect-ratio: 1 / 1 !important;
  min-height: 0 !important;
}

body.single-product .wh-online-product .wh-gallery__image {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
}

/* --------------------------------------------------------------------------
   Global mobile overflow / readable titles
   -------------------------------------------------------------------------- */
html,
body {
  max-width: 100%;
  overflow-x: clip;
}

#page,
.site,
.site-content,
.front-page-main,
.wh-online-product,
.wh-product-main,
.wh-about-main {
  max-width: 100%;
  min-width: 0;
  overflow-x: clip;
}

.container {
  box-sizing: border-box;
  /* Keep the shared 1320 shell — never stretch past the header */
  max-width: min(1320px, 100%);
  min-width: 0;
}

@media (max-width: 960px) {
  .wh-online-hero .container,
  .wh-online-product .container {
    padding-left: 16px;
    padding-right: 16px;
  }

  .i3d-section-title,
  .i3d-hero__title,
  .wh-online-title {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .i3d-section-head {
    max-width: 100%;
  }

  .i3d-hero--split .i3d-hero__grid,
  .i3d-intro__grid,
  .i3d-spotlight__panel {
    min-width: 0;
  }
}

/* --------------------------------------------------------------------------
   Footer social icons — keep SVG visible on hover (beat footer link accent color)
   -------------------------------------------------------------------------- */
.wh-site-footer .footer-social {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  margin-top: 18px !important;
}

.wh-site-footer .footer-social .social-link {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 42px !important;
  height: 42px !important;
  border-radius: 10px !important;
  background: #fff !important;
  border: 1px solid #d7d7d4 !important;
  color: #111 !important;
  text-decoration: none !important;
  box-shadow: none !important;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease !important;
}

.wh-site-footer .footer-col a.social-link,
.wh-site-footer .footer-col .widget a.social-link {
  color: #111 !important;
}

.wh-site-footer .footer-social .social-link:hover,
.wh-site-footer .footer-social .social-link:focus-visible,
.wh-site-footer .footer-col a.social-link:hover,
.wh-site-footer .footer-col a.social-link:focus-visible,
.wh-site-footer .footer-col .widget a.social-link:hover,
.wh-site-footer .footer-col .widget a.social-link:focus-visible {
  background: var(--tx-accent, #c8102e) !important;
  border-color: var(--tx-accent, #c8102e) !important;
  color: #fff !important;
  transform: translateY(-2px);
  outline: none;
}

.wh-site-footer .footer-social .social-link svg {
  display: block !important;
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0;
  fill: currentColor !important;
  pointer-events: none;
}

.wh-site-footer .footer-social .social-link path {
  fill: currentColor !important;
}

.wh-site-footer .footer-social .social-link img {
  filter: none !important;
}
