/*
 * B3 visual parity candidate. Scope every rule to a route so the B home remains untouched.
 * Values were read from 1440x900 and 390x844 A/B2 viewport captures.
 */

/* Shop: Astra A has a ruled, light blue title and one card per mobile row. */
body.post-type-archive-product .moyomall-woocommerce {
  width: min(calc(100% - 80px), 1360px);
  padding-top: 102px;
}
body.post-type-archive-product .moyomall-woocommerce h1.page-title {
  margin: 0 0 54px;
  padding: 0 0 20px;
  border-bottom: 1px solid #dadada;
  color: #4853d3;
  font-size: 40px;
  line-height: 1.28;
  font-weight: 300;
}
body.post-type-archive-product .moyomall-woocommerce .woocommerce-result-count,
body.post-type-archive-product .moyomall-woocommerce .woocommerce-ordering {
  margin-bottom: 50px;
}
body.post-type-archive-product .moyomall-woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: 20px;
  row-gap: 48px;
  clear: both;
  margin-top: 0;
}
body.post-type-archive-product .moyomall-woocommerce ul.products::before,
body.post-type-archive-product .moyomall-woocommerce ul.products::after,
body.search .woocommerce ul.products::before,
body.search .woocommerce ul.products::after {
  content: none;
  display: none;
}
body.post-type-archive-product .moyomall-woocommerce ul.products li.product,
body.search .woocommerce ul.products li.product {
  float: none;
  clear: none;
  width: 100%;
  margin: 0;
}
body.post-type-archive-product .moyomall-woocommerce ul.products li.product a img,
body.search .woocommerce ul.products li.product a img {
  display: block;
  width: 100%;
  height: auto;
}
body.search .woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 48px 20px;
}

/* Keep Woo product cards and prices; restore their earlier visual weight. */
:is(body.post-type-archive-product, body.single-product)
  .moyomall-woocommerce ul.products li.product .woocommerce-loop-product__title,
body.search .woocommerce ul.products li.product .woocommerce-loop-product__title {
  color: #111;
  font-size: 16px;
  line-height: 1.4;
  font-weight: 700;
}
:is(body.post-type-archive-product, body.single-product)
  .moyomall-woocommerce ul.products li.product .price,
body.search .woocommerce ul.products li.product .price {
  color: #111;
  font-size: 14px;
  font-weight: 700;
}
:is(body.post-type-archive-product, body.single-product)
  .moyomall-woocommerce ul.products li.product .ast-woo-product-category,
body.search .woocommerce ul.products li.product .ast-woo-product-category {
  display: block;
  margin: 0 0 3px;
  color: #999;
  font-size: 14px;
  line-height: 1.4;
  font-weight: 400;
}

/* Product detail: breadcrumb must be inserted by the B3 PHP hook first. */
body.single-product .moyomall-woocommerce {
  width: min(calc(100% - 40px), 1400px);
  padding-top: 93px;
}
body.single-product .moyomall-woocommerce div.product div.images { width: 50%; }
body.single-product .moyomall-woocommerce div.product div.summary { width: 46%; }
body.single-product .moyomall-woocommerce div.product div.images img.wp-post-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
body.single-product .moyomall-woocommerce div.product .summary.entry-summary {
  padding-top: 0;
  margin-bottom: 34px;
  font-size: 17px;
  line-height: 27.2px;
}
body.single-product .moyomall-woocommerce .woocommerce-breadcrumb {
  margin: 0 0 15.64px;
  color: #697386;
  font-size: 15.64px;
  line-height: 27.2px;
  font-weight: 400;
}
body.single-product .moyomall-woocommerce div.product .product_title {
  margin: 0 0 15px;
  color: #1b2234;
  font-size: 30px;
  line-height: 36px;
  font-weight: 400;
  letter-spacing: 0;
}
body.single-product .moyomall-woocommerce div.product p.price,
body.single-product .moyomall-woocommerce div.product span.price {
  display: inline-block;
  margin: 0 5px 5.1px 0;
  color: #333;
  font-size: 25.5px;
  line-height: 27.2px;
  font-weight: 700;
}
body.single-product .moyomall-woocommerce div.product .ast-shipping-text {
  display: inline;
  color: #172034;
  font-size: 17px;
  line-height: 27.2px;
  font-weight: 400;
}
body.single-product .moyomall-woocommerce div.product .woocommerce-product-details__short-description p {
  margin: 0 0 29.75px;
  font-size: 17px;
  line-height: 27.2px;
}
body.single-product .moyomall-woocommerce div.product .woocommerce-product-details__short-description p:last-child { margin-bottom: 17px; }
body.single-product .moyomall-woocommerce div.product .woocommerce-tabs { padding-top: 34px; margin-bottom: 68px; }
body.single-product .moyomall-woocommerce .related ul.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 40px 20px;
}
body.single-product .moyomall-woocommerce .related ul.products::before,
body.single-product .moyomall-woocommerce .related ul.products::after { content: none; display: none; }
body.single-product .moyomall-woocommerce .related ul.products li.product {
  float: none;
  clear: none;
  width: 100%;
  margin: 0;
}

/* Magazine and article use A's editorial rhythm, not the home card grid. */
body.page-id-27306 .moyomall-page {
  width: min(calc(100% - 40px), 1400px);
  padding-top: 76px;
}
body.page-id-27306 .moyomall-page-header { margin-bottom: 7px; }
body.page-id-27306 .moyomall-magazine-cards,
body.post-type-archive-post .moyomall-magazine-cards,
body.blog .moyomall-magazine-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 50px 30px;
}
body.single-post .moyomall-single { padding-top: 45px; }
body.single-post .moyomall-single__article { max-width: 860px; }
body.single-post .moyomall-single__featured { margin-bottom: 70px; }
body.single-post .moyomall-single__article .moyomall-page-header h1 {
  font-size: 60px;
  line-height: 1.12;
  letter-spacing: -.045em;
}
body.single-post .moyomall-single__article .entry-content {
  font-size: 17px;
  line-height: 1.75;
}
body.single-post .moyomall-single__related { max-width: 860px; margin-inline: auto; }
body.single-post .moyomall-single__related .moyomall-magazine-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
}
body.single-post .moyomall-single__related .moyomall-magazine-card img { display: none; }
body.single-post .moyomall-single__related .moyomall-magazine-card__copy { padding: 48px 10px 0; }
body.single-post .moyomall-single__related .moyomall-magazine-card__copy h2 {
  margin-bottom: 12.6px;
  font-size: 18px;
  line-height: 23.4px;
  font-weight: 400;
}
body.single-post .moyomall-single__related .moyomall-magazine-card__copy p {
  color: #737373;
  font-size: 17px;
  line-height: 27.2px;
}

/* Account: keep the semantic H1, conceal its duplicate visual title only. */
body.woocommerce-account .moyomall-page {
  width: min(calc(100% - 40px), 1400px);
  min-height: 650px;
  padding-top: 97px;
}
body.woocommerce-account:not(.logged-in) .moyomall-page-content > .moyomall-page-header {
  margin-bottom: 34px;
}
body.woocommerce-account:not(.logged-in) .moyomall-page-content > .moyomall-page-header h1 {
  font-size: 34px;
  line-height: 1.3;
  font-weight: 700;
}
body.woocommerce-account:not(.logged-in) .moyomall-page-content .entry-content > .woocommerce > h2 { display: none; }
body.woocommerce-account .woocommerce h2 {
  margin: 0 0 34px;
  font-size: 34px;
  line-height: 1.3;
}
body.woocommerce-account .woocommerce form.login {
  margin: 0;
  padding: 24px;
  border-color: #d8d8d8;
}
body.woocommerce-account .woocommerce form.login input.input-text {
  min-height: 50px;
  border: 1px solid #d8d8d8;
  border-radius: 0;
}
body.woocommerce-account .woocommerce form.login button.button {
  min-width: 110px;
  min-height: 48px;
}

/* Empty cart: A's vertical placement, notice rule and action size. */
body.woocommerce-cart .moyomall-page {
  width: min(calc(100% - 40px), 1400px);
  min-height: 390px;
  padding-top: 77px;
}
body.woocommerce-cart .moyomall-page-header h1 {
  font-size: 30px;
  font-weight: 300;
}
body.woocommerce-cart .woocommerce-info {
  min-height: 64px;
  padding-block: 20px;
  border-top-color: #4754ca;
}
body.woocommerce-cart .woocommerce a.button.wc-backward {
  display: inline-flex;
  min-width: 185px;
  min-height: 48px;
  align-items: center;
  justify-content: center;
}

/* A uses two genuinely separate footer columns and centred mobile text. */
.site-footer__grid { width: min(calc(100% - 40px), 1400px); }
.site-footer__copyright,
.site-footer__html-1 { display: block; }
.site-footer__copyright { margin-bottom: 22px; }
.site-footer__html-1 { margin-bottom: 15px; }
.site-footer__html-2 { line-height: 1.6; }

/* Search hero requires B3 to restore the intro text and heading wording. */
body.search .moyomall-search-results { padding-top: 145px; }
body.search .moyomall-search-results .moyomall-page-header {
  margin: 0 10px 56px;
  padding: 0 50px 50px;
  border-bottom: 1px solid #dadada;
}
body.search .moyomall-search-results .moyomall-page-header h1 {
  margin: 0;
  color: #4853d3;
  font-size: 50px;
  line-height: 1.25;
  font-weight: 300;
}
body.search .moyomall-search-results .moyomall-search-intro {
  margin: 15px 0 0;
  font-size: 23px;
  line-height: 1.4;
}

/* Requires B3 to render page 6481's six existing tiles and board separately. */
body.page-id-6481 .moyomall-page--reviews { width: min(calc(100% - 40px), 1400px); }
body.page-id-6481 .moyomall-page--reviews .moyomall-category-tiles--page { display: none; }
body.page-id-6481 .moyomall-review-heading { margin: 0 0 67px; padding-top: 66px; }
body.page-id-6481 .moyomall-review-heading h1 {
  margin: 0 0 10px;
  font-size: 36px;
  line-height: 1.35;
}
body.page-id-6481 .moyomall-review-heading p {
  margin: 0;
  color: #4853d3;
  font-size: 16px;
}
body.page-id-6481 .moyomall-review-heading p.has-pin::before {
  content: "";
  display: inline-block;
  width: 17px;
  height: 17px;
  vertical-align: -3px;
  background: url("review-pin.svg") center / contain no-repeat;
  margin-right: .35em;
}

@media (max-width: 767px) {
  body.post-type-archive-product .moyomall-woocommerce,
  body.search .moyomall-search-results {
    width: calc(100% - 40px);
    padding-top: 43px;
  }
  body.post-type-archive-product .moyomall-woocommerce h1.page-title {
    margin-bottom: 45px;
    padding-bottom: 25px;
    font-size: 34px;
  }
  body.post-type-archive-product .moyomall-woocommerce .woocommerce-result-count,
  body.post-type-archive-product .moyomall-woocommerce .woocommerce-ordering { margin-bottom: 30px; }
  body.post-type-archive-product .moyomall-woocommerce ul.products,
  body.search .woocommerce ul.products {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 48px;
    float: none;
    clear: both;
    margin: 36px 0 0;
  }
  body.post-type-archive-product .moyomall-woocommerce ul.products::before,
  body.post-type-archive-product .moyomall-woocommerce ul.products::after,
  body.search .woocommerce ul.products::before,
  body.search .woocommerce ul.products::after {
    content: none;
    display: none;
  }
  body.post-type-archive-product .moyomall-woocommerce ul.products li.product,
  body.search .woocommerce ul.products li.product {
    float: none;
    clear: none;
    width: 100%;
    margin: 0;
    text-align: center;
  }
  body.post-type-archive-product .moyomall-woocommerce ul.products li.product a img,
  body.search .woocommerce ul.products li.product a img {
    width: 100%;
    height: auto;
  }
  body.single-product .moyomall-woocommerce { width: calc(100% - 40px); padding-top: 62px; }
  body.single-product .moyomall-woocommerce div.product div.images,
  body.single-product .moyomall-woocommerce div.product div.summary { width: 100%; float: none; }
  body.single-product .moyomall-woocommerce div.product .summary.entry-summary { padding-top: 0; margin-bottom: 31.008px; font-size: 15.504px; line-height: 24.8064px; }
  body.single-product .moyomall-woocommerce .woocommerce-breadcrumb { margin-bottom: 14.2637px; font-size: 14.2637px; line-height: 24.8064px; }
  body.single-product .moyomall-woocommerce div.product .product_title { margin-bottom: 13.68px; font-size: 27.36px; line-height: 32.832px; }
  body.single-product .moyomall-woocommerce div.product p.price,
  body.single-product .moyomall-woocommerce div.product span.price { margin-bottom: 4.6512px; font-size: 23.256px; line-height: 24.8064px; }
  body.single-product .moyomall-woocommerce div.product .ast-shipping-text { font-size: 15.504px; line-height: 24.8064px; }
  body.single-product .moyomall-woocommerce div.product .woocommerce-product-details__short-description p { margin-bottom: 27.132px; font-size: 15.504px; line-height: 24.8064px; }
  body.single-product .moyomall-woocommerce div.product .woocommerce-product-details__short-description p:last-child { margin-bottom: 15.504px; }
  body.single-product .moyomall-woocommerce div.product .woocommerce-tabs { padding-top: 31.008px; margin-bottom: 62.016px; }
  body.single-product .moyomall-woocommerce .related ul.products {
    grid-template-columns: minmax(0, 1fr);
    gap: 48px;
  }
  body.single-product .moyomall-woocommerce .related ul.products li.product a img {
    display: block;
    width: 100%;
    height: auto;
  }
  body.page-id-27306 .moyomall-page { width: calc(100% - 40px); padding-top: 50px; }
  body.page-id-27306 .moyomall-page-header { margin-bottom: 25px; }
  body.page-id-27306 .moyomall-magazine-cards,
  body.post-type-archive-post .moyomall-magazine-cards,
  body.blog .moyomall-magazine-cards { grid-template-columns: minmax(0, 1fr); gap: 54px; }
  body.single-post .moyomall-single { width: calc(100% - 40px); padding-top: 62px; }
  body.single-post .moyomall-single__featured { margin-bottom: 65px; }
  body.single-post .moyomall-single__article .moyomall-page-header h1 { font-size: 36px; line-height: 1.08; }
  body.single-post .moyomall-single__related .moyomall-magazine-cards { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  body.single-post .moyomall-single__related .moyomall-magazine-card__copy { padding: 44px 10px 20px; }
  body.single-post .moyomall-single__related .moyomall-magazine-card__copy p { font-size: 15.5px; line-height: 24.8px; }
  body.woocommerce-account .moyomall-page {
    width: calc(100% - 40px);
    min-height: 563px;
    padding-top: 59px;
  }
  body.woocommerce-account .woocommerce h2 { margin-bottom: 30px; font-size: 24px; }
  body.woocommerce-account:not(.logged-in) .moyomall-page-content > .moyomall-page-header h1 { font-size: 24px; }
  body.woocommerce-account .woocommerce form.login { padding: 24px 23px 50px; }
  body.woocommerce-cart .moyomall-page {
    width: calc(100% - 40px);
    min-height: 366px;
    padding-top: 61px;
  }
  .site-footer__grid { width: calc(100% - 40px); text-align: center; }
  .site-footer__grid > * { min-width: 0; }
  body.search .moyomall-search-results { padding-top: 113px; }
  body.search .moyomall-search-results .moyomall-page-header {
    margin: 0 0 50px;
    padding: 0 48px 45px;
  }
  body.search .moyomall-search-results .moyomall-page-header h1 { font-size: 44px; }
  body.search .moyomall-search-results .moyomall-search-intro { font-size: 20px; }
  body.page-id-6481 .moyomall-page--reviews { width: calc(100% - 40px); padding-top: 0; }
  body.page-id-6481 .moyomall-page--reviews .moyomall-category-tiles--page {
    display: grid;
    width: 100%;
    margin: 0 0 50px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.page-id-6481 .moyomall-review-heading {
    margin: 0 0 44px;
    padding-top: 0;
    text-align: center;
  }
  body.page-id-6481 .moyomall-review-heading h1 { font-size: 24px; }
  body.page-id-6481 .moyomall-review-heading p { font-size: 14px; text-align: left; }
}
