/*
 Theme Name: Astra Child (v2)
 Theme URI: https://example.com/astra-child-split-menu
 Description: Child theme for Astra to center the logo and create a split menu (primary left, secondary right). Includes support for Primary Header row and Above Header row.
 Author: ChatGPT
 Version: 1.1.0
 Template: astra
 License: GNU General Public License v2 or later
*/

/* ===== GENERAL ===== */
:root { --split-gap-x: .0rem; }

/* Keep center logo centered visually */
.ast-site-identity { text-align: center; }
.ast-site-identity .site-logo-img img { display: block; margin: 0 auto; }

/* ===== PRIMARY HEADER ROW (preferred) ===== */
.ast-primary-header-bar .site-header-section-left,
.ast-primary-header-bar .site-header-section-right { flex: 1 1 0; }
.ast-primary-header-bar .site-header-section-center { flex: 0 0 auto; }

/* Left menu → pull toward center */
.ast-desktop .ast-primary-header-bar .site-header-section-left .main-header-menu,
.ast-desktop .ast-primary-header-bar .site-header-section-left .ast-nav-menu {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: flex-end !important;
  text-align: right;
}

/* Right menu → pull toward center */
.ast-desktop .ast-primary-header-bar .site-header-section-right .main-header-menu,
.ast-desktop .ast-primary-header-bar .site-header-section-right .ast-nav-menu {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: flex-start !important;
  text-align: left;
}

/* Spacing */
.ast-primary-header-bar .main-header-menu > li { margin: 0 var(--split-gap-x); }

/* ===== ABOVE HEADER ROW (your current markup) ===== */
.ast-above-header-bar .site-header-above-section-left,
.ast-above-header-bar .site-header-above-section-right { flex: 1 1 0; }
.ast-above-header-bar .site-header-above-section-center { flex: 0 0 auto; }

/* Left menu (Above Header) → pull toward center */
.ast-desktop .ast-above-header-bar .site-header-above-section-left .main-header-bar-navigation .main-header-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-left .main-navigation .ast-nav-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-left .ast-builder-menu-1 .main-header-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-left .ast-builder-menu-1 .ast-nav-menu {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: flex-end !important;
  text-align: right;
}

/* Right menu (Above Header) → pull toward center */
.ast-desktop .ast-above-header-bar .site-header-above-section-right .main-header-bar-navigation .main-header-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-right .main-navigation .ast-nav-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-right .ast-builder-menu-2 .main-header-menu,
.ast-desktop .ast-above-header-bar .site-header-above-section-right .ast-builder-menu-2 .ast-nav-menu {
  display: flex !important;
  flex-wrap: wrap;
  justify-content: flex-start !important;
  text-align: left;
}

/* Ensure header rows align items vertically */
.ast-primary-header-bar .ast-builder-grid-row,
.ast-above-header-bar .ast-builder-grid-row { align-items: center; }

/* Spacing */
.ast-above-header-bar .main-header-menu > li { margin: 0 var(--split-gap-x); }


.c-product-grid__price-atc { display: inline-flex; align-items: center; gap: 8px; }
/* Optional: remove button look entirely if Astra/Woo adds padding */
.c-product-grid__atc.button { background: none; border: 0; padding: 0; line-height: 1; box-shadow: none; }
.c-product-grid__atc-text { position: absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,1px,1px); white-space:nowrap; } /* accessibility */


.woocommerce ul.products,
.woocommerce-page ul.products {
    align-items: stretch; /* let children stretch to equal height */
}

.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Wrap summary content in a column so CTA sits at the bottom */
.woocommerce ul.products li.product .astra-shop-summary-wrap,
.woocommerce-page ul.products li.product .astra-shop-summary-wrap,
.woocommerce ul.products li.product .ast-woo-shop-product-description,
.woocommerce-page ul.products li.product .ast-woo-shop-product-description {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

/* Keep title/price up, push the ATC icon to the bottom edge */
.woocommerce ul.products li.product .price {
    margin-top: .25rem; }
.woocommerce ul.products li.product .c-product-grid__atc-wrap {
    margin-top: auto; }

/* Consistent image area */
.woocommerce ul.products li.product .astra-shop-thumbnail-wrap img,
.woocommerce ul.products li.product a img {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;   /* match your cropping ratio */
    object-fit: cover;
}

/* Optional: stabilize title height to 2 lines (prevents tall titles from stretching cards) */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: calc(1.2em * 2); /* line-height * lines */
}

.woocommerce-js div.product form.cart .variations label{ color:#777 }
.woocommerce-js .woocommerce-ordering select, .woocommerce-page .woocommerce-ordering select {
    background-color: transparent;
    border: transparent;
    border-radius: 0; color: #e9ba4d;
}

label, legend{
	color: #e9ba4d;
}


/* ===== MOBILE / TABLET ===== */
@media (max-width: 921px) {
  /* Let Astra handle mobile menu; just keep the logo centered */
  .ast-mobile-header-wrap .ast-site-identity,
  .ast-mobile-header-wrap .site-branding { text-align: center; }
  .ast-mobile-header-wrap .site-logo-img img { margin: 0 auto; }
}

@media (min-width: 922px) {
    .ast-container {
        max-width: 1300px;
    }
}
.ast-woo-shop-archive .site-content > .ast-container {
    max-width: 1300px;
}
