/* 1. Product detail surface and native gallery frame */
body.single-product #inner-wrap {
  background: #f4f7fb;
}
body.single-product div.product.type-product {
  box-sizing: border-box;
  padding: clamp(16px, 3vw, 40px);
  border: 1px solid #dce2ec;
  border-radius: 14px;
  background: #fff;
  color: #243852;
}
body.single-product div.product .woocommerce-product-gallery {
  outline: 1px solid #e3e8ef;
  border-radius: 10px;
}

/* 2. Product information, prices and descriptions */
body.single-product .product .summary .product_title,
body.single-product .product .woocommerce-tabs h2,
body.single-product .related.products > h2 {
  color: #0d2342;
  font-family: Georgia, serif;
  line-height: 1.18;
}
body.single-product .product .summary .product_title {
  font-size: clamp(26px, 3vw, 40px);
  overflow-wrap: anywhere;
}
body.single-product .product .summary :is(.price, .amount) {
  color: #102c49;
  font-weight: 700;
}
body.single-product .woocommerce-product-details__short-description,
body.single-product .product .woocommerce-Tabs-panel {
  color: #243852;
  line-height: 1.7;
}
body.single-product .product .woocommerce-tabs {
  border-top: 1px solid #dce2ec;
  padding-top: 20px;
}
body.single-product .product .woocommerce-tabs .tabs li.active a {
  color: #0d2342;
  box-shadow: inset 0 -2px #d9ae36;
}

/* 3. Style native variation and quantity fields in place */
body.single-product .summary form.cart label {
  color: #0d2342;
}
body.single-product .summary form.cart :is(select, input.qty) {
  box-sizing: border-box;
  max-width: 100%;
  min-height: 44px;
  background-color: #fff;
  color: #0d2342;
  border: 1px solid #bcc9d7;
  border-radius: 7px;
}
body.single-product .summary form.cart :focus-visible {
  outline: 3px solid #986c0a;
  outline-offset: 3px;
}
body.single-product .peptide-faq-section:has(~ .agape-footer) {
  display: none;
}

/* 4. Compact the legacy search block above the product. */
.single-product #primary.content-area {
  margin-block: clamp(18px, 3vw, 40px);
}
.single-product .wp-block-spacer:has(+ .kadence-column3429_8f3375-3c),
.single-product .kadence-column3429_8f3375-3c + p:empty,
.single-product .woocommerce-notices-wrapper:empty {
  display: none;
}
.single-product .kadence-column3429_8f3375-3c .aws-container {
  max-width: 620px;
  margin: 0 auto 16px;
}
.single-product .aws-container .aws-search-form .aws-search-field {
  border: 1px solid #cbd5e1;
  border-radius: 7px 0 0 7px;
  background: #fff;
  color: #0d2342;
  padding-inline: 14px;
}
.single-product .aws-container .aws-search-form .aws-search-btn {
  background: var(--ag-btn-gold, linear-gradient(180deg, #f6d878, #dfa92c));
  border-radius: 0 7px 7px 0;
  color: #0d2342;
}

/* 5. Give the gallery, summary and tabs a shared inset. */
.single-product #inner-wrap div[id^="product-"].product.entry-content-wrap {
  padding: clamp(16px, 2.5vw, 36px) !important;
  background: #fff;
  color: #243852;
}
.single-product #inner-wrap .product .woocommerce-tabs {
  clear: both;
  margin-block: 28px;
}
.single-product #inner-wrap .woocommerce-tabs .woocommerce-Tabs-panel {
  padding: clamp(14px, 2vw, 26px);
  background: #f7f9fc;
  border: 1px solid #dce2ec;
  border-radius: 8px;
  color: #243852;
  font-size: 16px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.single-product #inner-wrap .woocommerce-tabs .woocommerce-Tabs-panel h2 {
  margin-block: 1em 0.4em;
  font-size: clamp(21px, 2vw, 28px);
}
.single-product
  #inner-wrap
  .woocommerce-tabs
  .woocommerce-Tabs-panel
  > :first-child {
  margin-top: 0;
}

/* 6. Keep product choices and purchase controls legible in every state. */
.single-product #inner-wrap .summary .variations select {
  color: #0d2342;
  background-color: white;
}
/* 8. Shared product controls */
body.single-product #inner-wrap {
  --agape-ink: #0d2342;
  --agape-line: #dce2ec;
  --agape-gold: #d9ae36;
  --agape-action: var(--ag-btn-gold, linear-gradient(180deg, #f6d878, #dfa92c));
}
/* Purchase button visual states are defined in woocommerce-ui.css. */
.single-product #inner-wrap .summary .single_add_to_cart_button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: auto;
  margin: 0;
  padding: 10px 18px;
  white-space: normal;
}
.single-product #inner-wrap .summary .variations_button {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.single-product #inner-wrap .summary .quantity {
  margin: 0;
}
.single-product #inner-wrap .summary .quantity input.qty {
  height: 44px;
  min-width: 56px;
  border-radius: 7px;
}
.single-product #inner-wrap .summary .variations select {
  min-height: 44px;
  border-radius: 7px;
}
.single-product #inner-wrap .ypb-coa-cert-link.ypb-coa-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid #b58a22;
  border-radius: 7px;
  background: #fff;
  color: var(--agape-ink);
  font-weight: 600;
}
.single-product #inner-wrap .summary .wdr_bulk_table_msg {
  width: 100%;
  border: 1px solid var(--agape-line);
  border-spacing: 0;
  border-collapse: separate;
  border-radius: 9px;
  overflow: hidden;
}
.single-product #inner-wrap .summary .wdr_bulk_table_msg :is(th, td) {
  padding: 8px 10px;
  color: var(--agape-ink);
  text-align: left;
}
.single-product #inner-wrap .summary .wdr_bulk_table_msg th {
  background: #f4f7fb;
}

/* 9. Rounded tab controls with an amber selected state */
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 14px;
  padding: 0;
  border: 0;
  background: transparent;
}
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs::before,
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs li::before,
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs li::after {
  content: none;
}
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs li {
  margin: 0;
  padding: 0;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none;
}
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs li a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 8px 16px;
  border: 1px solid var(--agape-line);
  border-radius: 7px;
  background: #fff !important;
  color: var(--agape-ink) !important;
  box-shadow: none;
  font-weight: 600;
}
.single-product #inner-wrap div.product .woocommerce-tabs ul.tabs li.active a,
.single-product
  #inner-wrap
  div.product
  .woocommerce-tabs
  ul.tabs
  a[aria-selected="true"] {
  border-color: var(--agape-gold);
  background: #fff4cf !important;
  color: var(--agape-ink) !important;
  box-shadow: inset 0 -2px var(--agape-gold);
}

.single-product #inner-wrap .aws-container .aws-search-form {
  gap: 6px;
}
.single-product
  #inner-wrap
  .aws-container
  .aws-search-form
  :is(.aws-search-field, .aws-search-btn) {
  border-radius: 7px !important;
  min-height: 44px;
}
.single-product #inner-wrap .aws-container .aws-search-form .aws-search-btn {
  background: var(--agape-action);
}

/* 15. Compact product banner matching the shop header. */
.agape-product-banner .agape-page-banner {
  min-height: 220px;
  display: flex;
  align-items: center;
  padding: 38px 0;
  background:
    linear-gradient(90deg, rgba(4, 17, 35, 0.95), rgba(4, 17, 35, 0.65)),
    url("../images/hero-desktop-2.webp") center 45% / cover no-repeat;
  color: #fff;
}
.agape-product-banner .agape-page-banner__inner {
  width: min(100% - 40px, 1240px);
  margin: auto;
}
.agape-product-banner .agape-product-banner__title {
  margin: 0;
  color: #fff;
  font:
    700 clamp(30px, 4vw, 46px)/1.15 Georgia,
    serif;
}
.agape-product-banner .agape-page-banner__eyebrow {
  margin: 0 0 10px;
  color: #e8b840;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.agape-product-banner .agape-page-banner__description {
  max-width: 760px;
  margin-top: 16px;
  color: #d5deea;
  font-size: 14px;
  line-height: 1.65;
}
.agape-product-banner .agape-page-banner__description p {
  margin: 0 0 10px;
}
.agape-product-banner .agape-page-banner__description p:last-child {
  margin-bottom: 0;
}
.agape-product-banner__title {
  overflow-wrap: anywhere;
}
@media (max-width: 700px) {
  .agape-product-banner .agape-page-banner {
    min-height: 170px;
    padding: 28px 0;
  }
}

/* 16. Product banner search and breadcrumb spacing. */
.single-product .agape-product-banner__search {
  width: min(100%, 36rem);
  margin: 14px 0 10px;
}
.single-product .agape-product-banner__search :is(.aws-container, form) {
  width: 100%;
  max-width: none;
  margin: 0;
}
.single-product .agape-product-banner__search form {
  display: flex;
  min-height: 44px;
}
.single-product .agape-product-banner__search input[type="search"] {
  flex: 1;
  min-width: 0;
  background: white;
  color: #10243c;
  border-radius: 7px 0 0 7px;
}
.single-product .agape-product-banner__search button[type="submit"] {
  color: #10243c;
  background: var(--ag-btn-gold, linear-gradient(180deg, #f6d878, #dfa92c));
  border-radius: 0 7px 7px 0;
}
.single-product
  .agape-product-banner__trail
  :is(nav, .woocommerce-breadcrumb, .kadence-breadcrumbs) {
  padding: 0;
  margin: 0;
  color: #eef3fa;
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.single-product .agape-product-banner__trail :is(a, span) {
  color: inherit;
}
.single-product .agape-product-banner__trail a:hover {
  color: #f0cc63;
}

/* 17. Hide the legacy product spacer and its empty paragraph. */
body.single-product
  .wp-block-spacer[aria-hidden="true"]:is(
    [style="height:38px" i],
    [style="height: 38px" i],
    [style="height:38px;" i],
    [style="height: 38px;" i]
  ):has(+ p.wp-block-paragraph:empty),
body.single-product
  .wp-block-spacer[aria-hidden="true"]:is(
    [style="height:38px" i],
    [style="height: 38px" i],
    [style="height:38px;" i],
    [style="height: 38px;" i]
  )
  + p.wp-block-paragraph:empty {
  display: none;
}
