/*
Theme Name: Hello Biz Child
Theme URI: https://csdemo174.shitouc.cn/
Description: Child theme for Hello Biz.
Author: Site Administrator
Template: hello-biz
Version: 1.0.36
Text Domain: hello-biz-child
*/

/* One typography step above the previous 16px inherited text size. */
body {
  font-size: 18px;
}

/* The header shades the banner while the page is at the top. */
body .site-header:not(.is-stuck) {
  background: linear-gradient(180deg, rgba(0, 0, 0, .62), rgba(0, 0, 0, 0));
}

/* The photographic banner is shared by templates and Elementor widgets. */
.page-banner--photo {
  background: #dcecff;
}

.page-banner--photo .page-banner-background {
  position: absolute;
  inset: 0;
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
}

.page-banner--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .16), transparent 42%, rgba(0, 0, 0, .48));
  pointer-events: none;
}

@media (max-width: 575px) {
  .page-banner--photo .page-banner-background {
    background-position: 65% center;
  }
}

.baijia-instruments .section-title-h2 h2 {
  text-transform: none;
  padding-right: 105px;
}

.baijia-instruments .instrument-controls {
  top: 10px;
  right: 15px;
}

@media (max-width: 767px) {
  .baijia-instruments .section-title-h2 h2 {
    padding-right: 0;
  }

  .baijia-instruments .instrument-controls {
    position: static;
    justify-content: flex-end;
    margin: 12px 0 18px;
  }
}

.product-card .product-image-link {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
}

.product-card .product-name a {
  color: inherit;
  text-decoration: none;
}

.product-card .product-name a:hover,
.product-card .product-name a:focus-visible {
  color: #005699;
  text-decoration: underline;
}

#baijia-inquiry-toast {
  position: fixed;
  z-index: 99999;
  top: 24px;
  left: 50%;
  display: grid;
  gap: 4px;
  width: min(420px, calc(100vw - 32px));
  padding: 16px 20px;
  border-left: 5px solid #29784c;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 32px rgba(0, 0, 0, .2);
  color: #172b3a;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -12px);
  transition: opacity .2s, transform .2s;
}

#baijia-inquiry-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

#baijia-inquiry-toast.is-error { border-left-color: #c84040; }
#baijia-inquiry-toast strong { font-size: 18px; }
#baijia-inquiry-toast span { font-size: 14px; line-height: 1.4; }

.section-footer .follow-us span.is-disabled {
  transition: background-color .2s, border-color .2s, color .2s, opacity .2s, transform .2s;
}

.section-footer .follow-us span.is-disabled:hover {
  opacity: 1;
  transform: translateY(-2px);
}

/*
 * Keep the fixed static header below the WordPress admin bar. The flyout is
 * anchored to the header itself, so the admin-bar height is never counted twice.
 */
:root {
  --alvioralab-admin-bar-offset: 0px;
}

body.admin-bar {
  --alvioralab-admin-bar-offset: 32px;
}

body.admin-bar .site-header {
  top: var(--alvioralab-admin-bar-offset);
}

/* Desktop Products hover/focus mega menu. */
@media (min-width: 1101px) {
  body .site-header .mega-menu {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
  }
}

/* Mobile/tablet header, menu drawer, backdrop and close control. */
@media (max-width: 1100px) {
  body.admin-bar #siteNav.site-nav {
    top: 0 !important;
    bottom: auto !important;
    height: calc(100vh - var(--alvioralab-admin-bar-offset)) !important;
    height: calc(100dvh - var(--alvioralab-admin-bar-offset)) !important;
    min-height: 0 !important;
  }

  body.admin-bar .nav-backdrop {
    top: 0;
    height: calc(100vh - var(--alvioralab-admin-bar-offset));
    height: calc(100dvh - var(--alvioralab-admin-bar-offset));
  }

  body.admin-bar.mobile-menu-open .menu-toggle {
    top: 0;
  }
}

@media (max-width: 782px) {
  body.admin-bar {
    --alvioralab-admin-bar-offset: 46px;
  }
}

/*
 * WordPress normally makes the admin bar absolute below 600px. Keeping it
 * fixed prevents the fixed site header from leaving a 46px gap after scroll.
 */
@media (max-width: 600px) {
  html #wpadminbar {
    position: fixed;
  }
}

/* WordPress page canvas is white; individual sections keep their own design. */
html,
body,
#page,
.site,
.site-main,
.elementor-location-single,
.elementor-location-archive {
  background-color: #fff;
}

/* Standard WordPress pages that do not use a custom template. */
body:not(.elementor-page) #content.site-main > .page-content {
  width: calc(100% - 60px);
  max-width: 1340px;
  margin-right: auto;
  margin-left: auto;
}

@media (max-width: 575px) {
  body:not(.elementor-page) #content.site-main > .page-content {
    width: calc(100% - 30px);
  }
}

/* The hero canvas comes from the widget background control. */
.baijia-elementor-hero .carousel,
.baijia-elementor-hero .slides,
.baijia-elementor-hero .slide {
  background-color: transparent !important;
}

/* Match the original static hero; Elementor instance styles can override this. */
.baijia-elementor-hero .slide-copy h1,
.baijia-elementor-hero .slide-copy h2,
.baijia-elementor-hero .slide-copy h3,
.baijia-elementor-hero .slide-copy p {
  color: #fff;
}

/* Keep inner content on a 1340px grid while section backgrounds can span the viewport. */
.header-shell,
.footer-grid,
.footer-bottom,
.inquiry-container,
.resources-container,
.solutions-container,
.custom-services-container,
.about-container,
.chemical-container,
.featured-container,
.instruments-container,
.mega-inner,
.about-alvioralab-container,
.inquiry-form-container,
.supply-container,
.page-container,
.error-page-layout {
  max-width: 1340px !important;
}

/* Breadcrumbs share the same centered content grid as the page body. */
.page-banner .section-breadcrumb .page-container {
  width: calc(100% - 60px) !important;
  max-width: 1340px !important;
  margin-right: auto !important;
  margin-left: auto !important;
}

@media (max-width: 575px) {
  .page-banner .section-breadcrumb .page-container {
    width: calc(100% - 30px) !important;
  }
}

@media (min-width: 576px) {
  .footer-grid,
  .footer-bottom,
  .inquiry-container,
  .resources-container,
  .solutions-container,
  .custom-services-container,
  .about-container,
  .chemical-container,
  .featured-container,
  .instruments-container,
  .mega-inner,
  .about-alvioralab-container,
  .inquiry-form-container,
  .supply-container,
  .page-container,
  .error-page-layout {
    width: calc(100% - 60px) !important;
  }
}

@media (min-width: 721px) {
  .header-shell {
    width: calc(100% - 60px) !important;
  }
}

@media (max-width: 575px) {
  .footer-grid,
  .footer-bottom,
  .inquiry-container,
  .resources-container,
  .solutions-container,
  .custom-services-container,
  .about-container,
  .chemical-container,
  .featured-container,
  .instruments-container,
  .mega-inner,
  .about-alvioralab-container,
  .inquiry-form-container,
  .supply-container,
  .page-container,
  .error-page-layout {
    width: calc(100% - 30px) !important;
  }
}

/* Custom Synthesis includes one Elementor typography override. */
.elementor-102 .elementor-element.elementor-element-6cac842 .elementor-heading-title {
  font-size: 37px !important;
}

.inquiry-form .inquiry-form-notice[hidden] {
  display: none !important;
}

.baijia-featured-products .product-card {
  display: flex;
  flex-direction: column;
  height: 390px !important;
}

.baijia-featured-products .product-card-actions.is-inquiry-only {
  margin-top: auto;
}

.baijia-featured-products .product-card-actions.is-inquiry-only a:first-child {
  border-color: #172b3a !important;
  background: #fff !important;
  color: #172b3a !important;
}

.baijia-featured-products .product-name {
  min-width: 0;
  overflow: hidden;
  overflow-wrap: anywhere;
  font-size: 18px !important;
}

/* Product category showcase below the homepage inquiry widget. */
#baijiaInquiryCategories {
  padding: 42px 0 80px;
  background: #fff;
  color: #172b3a;
}

#baijiaInquiryCategories .baijia-mega-layout {
  display: grid;
  grid-template-columns: minmax(220px, 22%) minmax(0, 1fr) minmax(240px, 23%);
  gap: 0;
  width: calc(100% - 60px);
  max-width: 1340px;
  min-height: 510px;
  margin: auto;
  border: 1px solid #e1e6ef;
}

#baijiaInquiryCategories .baijia-mega-categories {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 28px 18px;
  background-color: #3d6ca8;
  background-position: center;
  background-size: cover;
}

#baijiaInquiryCategories .baijia-mega-category {
  display: block;
  min-height: 48px;
  padding: 10px 12px;
  border-radius: 6px;
  background: rgba(12, 48, 98, .52);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
  text-decoration: none;
}

#baijiaInquiryCategories .baijia-mega-category:hover,
#baijiaInquiryCategories .baijia-mega-category:focus-visible,
#baijiaInquiryCategories .baijia-mega-category.is-active {
  background: rgba(255, 255, 255, .92);
  color: #164d87;
}

#baijiaInquiryCategories .baijia-mega-panels {
  min-width: 0;
  padding: 30px 32px;
}

#baijiaInquiryCategories .baijia-mega-panel { display: none; }
#baijiaInquiryCategories .baijia-mega-panel.is-active { display: block; }
#baijiaInquiryCategories .baijia-mega-panel h2 {
  margin: 0 0 22px;
  font-size: 23px;
  line-height: 1.3;
}

#baijiaInquiryCategories .baijia-mega-panel h2 a {
  color: #123d78;
  text-decoration: none;
}

#baijiaInquiryCategories .baijia-mega-subcategories {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 22px;
}

#baijiaInquiryCategories .baijia-mega-subcategories a {
  display: block;
  min-height: 50px;
  padding: 10px 0;
  border-bottom: 1px solid #e8edf3;
  color: #263c54;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
}

#baijiaInquiryCategories .baijia-mega-subcategories a:hover,
#baijiaInquiryCategories .baijia-mega-panel h2 a:hover {
  color: #005699;
  text-decoration: underline;
}

#baijiaInquiryCategories .baijia-mega-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-left: 1px solid #e1e6ef;
}

#baijiaInquiryCategories .baijia-mega-product {
  display: flex;
  min-width: 0;
  min-height: 250px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px;
  overflow: hidden;
  border-right: 1px solid #e1e6ef;
  border-bottom: 1px solid #e1e6ef;
  color: #172b3a;
  font-size: 13px;
  line-height: 1.35;
  text-align: center;
  text-decoration: none;
}

#baijiaInquiryCategories .baijia-mega-product img {
  display: block;
  width: 120px;
  max-width: 100%;
  height: 110px;
  object-fit: contain;
}

#baijiaInquiryCategories .baijia-mega-product span {
  display: -webkit-box;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow-wrap: anywhere;
}

@media (max-width: 1100px) {
  #baijiaInquiryCategories .baijia-mega-layout {
    display: block;
  }

  #baijiaInquiryCategories .baijia-mega-categories {
    display: none;
  }

  #baijiaInquiryCategories .baijia-mega-panel,
  #baijiaInquiryCategories .baijia-mega-panel.is-active {
    display: block;
    margin-bottom: 28px;
  }

  #baijiaInquiryCategories .baijia-mega-products {
    border-top: 1px solid #e1e6ef;
    border-left: 0;
  }
}

@media (max-width: 575px) {
  #baijiaInquiryCategories {
    padding: 32px 0 55px;
  }

  #baijiaInquiryCategories .baijia-mega-layout {
    width: calc(100% - 30px);
  }

  #baijiaInquiryCategories .baijia-mega-panels {
    padding: 22px 18px;
  }

  #baijiaInquiryCategories .baijia-mega-panel h2 {
    font-size: 20px;
  }

  #baijiaInquiryCategories .baijia-mega-subcategories {
    grid-template-columns: 1fr;
  }

  #baijiaInquiryCategories .baijia-mega-product {
    min-height: 210px;
    padding: 10px;
  }
}

@media (min-width: 1051px) {
  .elementor-widget-baijia-about-alvioralab .about-alvioralab-container {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: clamp(40px, 4vw, 80px) !important;
  }

  .elementor-widget-baijia-about-alvioralab .about-alvioralab-visual {
    width: 100% !important;
    max-width: none !important;
  }

  .elementor-widget-baijia-about-alvioralab .about-lab-photo {
    height: clamp(460px, 32vw, 560px) !important;
  }
}

/* Full-width homepage image carousel. */
.baijia-fullwidth-hero {
  height: 70vh !important;
  min-height: 0 !important;
  background: transparent !important;
}

.baijia-fullwidth-hero .carousel::before,
.baijia-fullwidth-hero .carousel::after {
  display: none !important;
}

.baijia-fullwidth-hero .slide {
  inset: 0 !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  transform: none !important;
}

.baijia-fullwidth-hero .hero-banner-image {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: block;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border: 0 !important;
  border-radius: 0 !important;
}

.baijia-fullwidth-hero .hero-banner-mask {
  position: absolute;
  z-index: 2;
  inset: 0;
  background-color: rgba(255, 255, 255, .16);
  pointer-events: none;
}

.baijia-fullwidth-hero .hero-banner-hit-area {
  position: absolute;
  z-index: 3;
  inset: 0;
  display: block;
}

.baijia-fullwidth-hero .hero-banner-hit-area:focus-visible {
  outline: 4px solid #51458f;
  outline-offset: -8px;
}

.baijia-fullwidth-hero .hero-banner-overlay {
  position: absolute;
  z-index: 4;
  top: 50%;
  left: max(30px, calc((100% - 1340px) / 2));
  transform: translateY(-50%);
  color: #123d78;
}

.baijia-fullwidth-hero .hero-banner-overlay h1,
.baijia-fullwidth-hero .hero-banner-overlay h2 {
  margin: 0 0 14px !important;
  color: #123d78 !important;
  font-size: clamp(30px, 3.8vw, 58px) !important;
  line-height: 1.1;
  letter-spacing: .02em;
}

.baijia-fullwidth-hero .hero-banner-button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 10px 24px;
  border-radius: 25px;
  background: #51458f;
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  text-decoration: none;
}

.baijia-fullwidth-hero .hero-banner-button:hover,
.baijia-fullwidth-hero .hero-banner-button:focus-visible {
  background: #005699;
  color: #fff;
  outline: 2px solid #fff;
}

.baijia-fullwidth-hero .indicators {
  z-index: 5;
}

.baijia-fullwidth-hero .indicator {
  background: rgba(17, 55, 108, .55) !important;
}

.baijia-fullwidth-hero .indicator.is-active {
  background: #51458f !important;
}

.baijia-fullwidth-hero .indicator.is-active::before {
  border-color: #51458f !important;
}

@media (max-width: 575px) {
  .baijia-fullwidth-hero .hero-banner-overlay {
    left: 20px;
    right: 20px;
  }

  .baijia-fullwidth-hero .hero-banner-overlay h1,
  .baijia-fullwidth-hero .hero-banner-overlay h2 {
    margin-bottom: 9px !important;
    font-size: 30px !important;
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(10, 35, 80, .8);
  }

  .baijia-fullwidth-hero .hero-banner-button {
    min-height: 42px;
    padding: 8px 18px;
    font-size: 15px;
  }
}
