/*
Theme Name: AZ Theme Child
Theme URI: https://tndigi.com
Description: Giao diện riêng của website, kế thừa framework dùng chung từ AZ Theme.
Author: TN Digi Solution
Author URI: https://tndigi.com
Template: az-theme
Version: 1.0.0
Requires at least: 5.8
Requires PHP: 7.4
Text Domain: az-theme-child
*/

/* Chỉ thêm CSS riêng của website tại theme child này. */
.pg-topbar li.menu-item {
  font-size:14px !important;
}

/* Product categories share the configured Layout width across all sections. */
.tax-product_cat .az-child-vespa {
  --pg-category-container:var(--az-container,1110px);
  --pg-category-gutter:var(--az-gutter,24px);
}
.tax-product_cat .az-child-vespa :is(.pg-container,.az-shop-layout,.az-shop-notices,.az-shared-container,.az-shop-titlebar .az-container) {
  width:min(calc(100% - 2 * var(--pg-category-gutter)),var(--pg-category-container));
  max-width:var(--pg-category-container);
  margin-inline:auto;
  box-sizing:border-box;
}
@media(max-width:960px) {
  .tax-product_cat .az-child-vespa { --pg-category-container:var(--az-container-tablet,960px); }
}
@media(max-width:640px) {
  .tax-product_cat .az-child-vespa { --pg-category-gutter:var(--az-mobile-gutter,24px); }
}
.logo-bct a.az-ministry-badge {
    background: #ffffff;
    border-radius: 10px;
}
/* Default page content, including imported content nested inside divs. */
.az-page-simple__header {
  text-align:center;
  padding-bottom:0;
  border-bottom:0;
}
.az-page-simple__header h1 {
  margin:0;
  color:var(--az-color-primary,#009c70);
  font-family:var(--az-font-heading,var(--az-font-main,Arial,sans-serif));
  font-size:clamp(26px,3vw,38px);
  font-weight:600;
  line-height:1.25;
  text-transform:uppercase;
}
.az-page-simple__content.az-content {
  line-height:1.75;
}
.az-page-simple__content.az-content p {
  margin:0 0 20px;
  line-height:inherit;
}
.az-page-simple__content.az-content :is(h1,h2,h3,h4,h5,h6) {
  margin:32px 0 16px;
  line-height:1.35;
}
.az-page-simple__content.az-content :is(ul,ol) {
  margin:0 0 24px;
  padding-left:1.5em;
}
.az-page-simple__content.az-content ul { list-style:disc outside; }
.az-page-simple__content.az-content ol { list-style:decimal outside; }
.az-page-simple__content.az-content li {
  margin-bottom:8px;
  line-height:inherit;
}
.az-page-simple__content.az-content li:last-child { margin-bottom:0; }
.az-page-simple__content.az-content li>p { margin-bottom:8px; }
.az-page-simple__content.az-content :is(ul,ol) :is(ul,ol) {
  margin-top:8px;
  margin-bottom:0;
}
.az-page-simple__content.az-content :is(figure,.wp-caption) {
  margin-block:24px;
}
.az-page-simple__content.az-content img {
  max-width:100%;
  height:auto;
}
.az-page-simple__content.az-content img.aligncenter {
  display:block;
  margin:24px auto;
}

/* Compact product-page heading area; thumbnails remain the gallery controls. */
body.single-product .az-site .az-main.az-product-detail {
  padding-top: 0;
}
/* Woo always renders a notice wrapper; collapse its empty section above the title. */
.az-child-vespa .az-product-detail > .az-shop-notices:has(> .woocommerce-notices-wrapper:only-child:empty) {
  display: none;
}
/* Attribute choices already appear beside the product; hide the repeated legacy tab. */
.az-child-vespa .az-product-detail .az-product-tab-panel [data-az-product-tab="additional"],
.az-child-vespa .az-product-detail .az-product-tab-panel [data-az-product-pane="additional"],
.az-child-vespa .az-product-detail .az-product-content:has(.az-product-tab-content > [data-az-product-pane="additional"]:only-child) {
  display: none;
}
body.single-product .az-site .az-product-breadcrumb {
  padding-top: 12px;
  padding-bottom: 14px;
}
body.single-product .az-site .az-product-gallery-nav,
body.single-product .az-site .az-product-gallery-zoom {
  display: none;
}
@media (max-width: 640px) {
  body.single-product .az-site .az-product-breadcrumb {
    padding-top: 10px;
    padding-bottom: 10px;
  }
}

/* Compact catalogue heading/controls; avoid gaps for absent grid sections. */
.az-site .az-shop-page { padding-top: 0; margin-top: 0; }
.az-site .az-shop-page .az-shop-notices:has(> .woocommerce-notices-wrapper:empty) { display: none; }
.az-site .az-shop-layout { padding-top: 8px; row-gap: 12px; }
.az-site .az-shop-catalog-toolbar { min-height: 40px; padding: 0; gap: 12px; }
.az-site .az-shop-catalog-toolbar select { min-height: 36px; font-size: 14px; }
.az-site .az-shop-layout--category .az-shop-top-filters { grid-row: var(--az-shop-filter-row, 3); }
.az-site .az-shop-layout--category > .az-shop-sidebar,
.az-site .az-shop-layout--category .az-shop-grid,
.az-site .az-shop-layout--category .az-shop-empty { grid-row: var(--az-shop-product-row, 4); }
/* On the shop index, put the toolbar in its own row above both columns. */
.az-site .az-shop-layout:not(.az-shop-layout--category) .az-shop-results { display: contents; }
.az-site .az-shop-layout:not(.az-shop-layout--category) > .az-shop-sidebar,
.az-site .az-shop-layout:not(.az-shop-layout--category) .az-shop-grid,
.az-site .az-shop-layout:not(.az-shop-layout--category) .az-shop-empty { grid-row: var(--az-shop-product-row, 2); }
.az-site .az-shop-layout:not(.az-shop-layout--category) .az-shop-top-filters { grid-row: var(--az-shop-filter-row, 2); }
.az-site .az-shop-layout .woocommerce-pagination { grid-column: 1 / -1; }
@media (max-width: 720px) {
  .az-site .az-shop-layout .az-shop-grid,
  .az-site .az-shop-layout .az-shop-empty { grid-row: calc(var(--az-shop-product-row, 2) + 1); }
  .az-site .az-shop-layout { padding-top: 6px; row-gap: 10px; }
  .az-site .az-shop-catalog-toolbar { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; }
  .az-site .az-shop-catalog-toolbar .woocommerce-ordering { max-width: 100%; }
  .az-site .az-shop-catalog-toolbar select { max-width: 100%; }
}

/* Allow article grid items to shrink below the intrinsic width of large images. */
.az-site .az-single-post__main,
.az-site .az-single-post__content {
  min-width: 0;
  box-sizing: border-box;
}

.az-site .az-single-post__featured img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.az-site .az-single-post__content .az-post-content {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 18px;
  line-height: 1.85;
}

.az-post-content p,
.az-product-tab-body.az-content p {
  text-align: justify !important;
}

.az-site .az-single-post__content .az-post-content p {
  margin: 0 0 24px;
  font-size: inherit;
  line-height: inherit;
}

.az-site .az-single-post__content .az-post-content :is(h1, h2, h3, h4, h5, h6) {
  margin: 36px 0 16px;
  font-weight: 600;
  line-height: 1.4;
}

.az-site .az-single-post__content .az-post-content h2 {
  font-size: clamp(24px, 2.5vw, 28px);
}

.az-site .az-single-post__content .az-post-content h3 {
  font-size: clamp(21px, 2vw, 24px);
}

.az-site .az-single-post__content .az-post-content :is(ul, ol) {
  margin: 0 0 26px;
  padding-left: 28px;
  font-size: inherit;
  line-height: inherit;
}

.az-site .az-single-post__content .az-post-content li {
  margin-bottom: 12px;
  line-height: inherit;
}

.az-site .az-single-post__content .az-post-content li > p {
  margin-bottom: 10px;
}

.az-site .az-single-post__content .az-post-content :is(ul, ol) :is(ul, ol) {
  margin: 12px 0 0;
}

.az-site .az-single-post__content .az-post-content :is(figure, .wp-caption) {
  margin: 30px auto;
}

.az-site .az-single-post__content .az-post-content :is(figcaption, .wp-caption-text) {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.6;
}

.az-site .az-single-post__content .az-post-content > :first-child {
  margin-top: 0;
}

.az-site .az-single-post__content .az-post-content > :last-child {
  margin-bottom: 0;
}

.az-site .az-post-content img,
.az-site .az-post-content video,
.az-site .az-post-content iframe {
  max-width: 100%;
}

.az-site .az-post-content img {
  height: auto;
}

.az-site .az-post-content figure,
.az-site .az-post-content .wp-caption {
  max-width: 100%;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  .az-site .az-single-post__layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .az-site .az-single-post__content .az-post-content {
    font-size: 17px;
    line-height: 1.8;
  }

  .az-site .az-single-post__content .az-post-content :is(h1, h2, h3, h4, h5, h6) {
    margin-top: 28px;
    margin-bottom: 14px;
  }
}

/* Retain the existing page/archive heading ornament without the retired shell CSS. */
.az-site :is(.az-page-simple__header,.az-blog-page) .pg-brands__ornament{display:flex;align-items:center;justify-content:center;gap:10px;height:25px;margin-top:5px;color:var(--az-color-primary)}
.az-site :is(.az-page-simple__header,.az-blog-page) .pg-brands__ornament::before,.az-site :is(.az-page-simple__header,.az-blog-page) .pg-brands__ornament::after{content:'';width:90px;border-top:1px dashed var(--az-color-border,#d5d5d5)}
.az-site :is(.az-page-simple__header,.az-blog-page) .pg-brands__ornament span{font-size:21px;line-height:1;white-space:nowrap}
