/*
 * Nesa Underwear — Page-level overrides (single product, cart, checkout).
 * Loaded LAST — wins over everything.
 */

/* ══════════════════════════════════════════════════════
 * ZERO SIDE PADDING on key pages
 * ══════════════════════════════════════════════════════ */

body.woocommerce-cart main.oxa-page,
body.woocommerce-cart .oxa-page,
body.woocommerce-cart main.site-main,
body.woocommerce-cart .site-main,
body.woocommerce-cart #primary,
body.woocommerce-cart #primary.content-area,
body.post-type-archive-product main.site-main,
body.post-type-archive-product .site-main,
body.post-type-archive-product #primary,
body.post-type-archive-product #primary.content-area,
body.tax-product_cat main.site-main,
body.tax-product_cat .site-main,
body.tax-product_cat #primary,
body.tax-product_cat #primary.content-area,
body.woocommerce-checkout main.oxa-page,
body.woocommerce-checkout .oxa-page,
body.woocommerce-checkout main.site-main,
body.woocommerce-checkout .site-main,
body.woocommerce-checkout #primary,
body.woocommerce-checkout #primary.content-area,
body.single-product main.oxa-page,
body.single-product .oxa-page,
body.single-product main.site-main,
body.single-product .site-main,
body.single-product #primary,
body.single-product #primary.content-area {
  padding-inline: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* ══════════════════════════════════════════════════════
 * SINGLE PRODUCT — 1280px
 * ══════════════════════════════════════════════════════ */

body.single-product #primary.content-area {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 0 !important;
}
body.single-product .site-main {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 2rem 0 3rem !important;
}
body.single-product .oxa-page {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding-inline: 0 !important;
}
body.single-product .e-con-inner {
  max-width: 1280px !important;
}

/* ══════════════════════════════════════════════════════
 * CART — 1280px
 * ══════════════════════════════════════════════════════ */

body.woocommerce-cart #primary.content-area,
body.woocommerce-cart #primary {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 0 !important;
}
body.woocommerce-cart .site-main {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 2rem 0 3rem !important;
}

/* ══════════════════════════════════════════════════════
 * CHECKOUT — 1280px only, no grid override
 * ══════════════════════════════════════════════════════ */

body.woocommerce-checkout #primary.content-area,
body.woocommerce-checkout #primary {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 0 !important;
}
body.woocommerce-checkout .site-main {
  max-width: 1280px !important;
  margin-inline: auto !important;
  padding: 2rem 0 3rem !important;
}

/* ══════════════════════════════════════════════════════
 * CART TABLE BORDER
 * ══════════════════════════════════════════════════════ */

body.woocommerce-cart table.shop_table,
body.woocommerce-cart .woocommerce table.shop_table,
body.woocommerce-cart form.woocommerce-cart-form table.shop_table {
  border: 1px solid var(--nesa-line) !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

/* ══════════════════════════════════════════════════════
 * HIDE COUPON + UPDATE CART
 * ══════════════════════════════════════════════════════ */

.woocommerce-cart .coupon,
.woocommerce-cart td.actions .coupon,
.cart-discount,
.woocommerce-cart .woocommerce-form-coupon-toggle,
.woocommerce-cart #coupon_code,
.woocommerce-cart .coupon-form {
  display: none !important;
}
body.woocommerce-cart button[name="update_cart"],
body.woocommerce-cart .woocommerce-cart-form__contents td.actions button[name="update_cart"] {
  display: none !important;
}
body.woocommerce-cart table.shop_table td.actions {
  display: none !important;
}

/* ══════════════════════════════════════════════════════
 * CART — grid layout
 * ══════════════════════════════════════════════════════ */

body.woocommerce-cart .woocommerce {
  display: grid !important;
  grid-template-columns: 1fr 380px !important;
  gap: 2.5rem !important;
  align-items: start !important;
  width: 100% !important;
  max-width: 100% !important;
}
body.woocommerce-cart .woocommerce > .woocommerce-notices-wrapper,
body.woocommerce-cart .woocommerce > h1,
body.woocommerce-cart .woocommerce > .entry-title {
  grid-column: 1 / -1 !important;
}
body.woocommerce-cart .woocommerce-cart-form {
  grid-column: 1 !important;
  min-width: 0 !important;
  width: 100% !important;
}
body.woocommerce-cart .cart-collaterals {
  grid-column: 2 !important;
  min-width: 0 !important;
  margin-top: 0 !important;
}

/* ══════════════════════════════════════════════════════
 * CART TOTALS
 * ══════════════════════════════════════════════════════ */

body.woocommerce-cart .cart_totals {
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 !important;
  position: static !important;
  background: #fff !important;
  border: 1px solid var(--nesa-line) !important;
  border-radius: 12px !important;
  padding: 1.5rem !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
}
body.woocommerce-cart .cart_totals > h2 {
  font-size: 30px !important;
  font-weight: 700 !important;
  margin: 0 0 1.25rem !important;
  color: #242424 !important;
}
body.woocommerce-cart .cart_totals table {
  width: 100% !important;
  table-layout: fixed !important;
  border-collapse: collapse !important;
  margin-bottom: 1.5rem !important;
  border: none !important;
  border-radius: 0 !important;
}
body.woocommerce-cart .cart_totals table th,
body.woocommerce-cart .cart_totals table td {
  padding: 0.75rem 0 !important;
  border-bottom: 1px solid var(--nesa-line) !important;
  border-left: none !important;
  border-right: none !important;
  border-top: none !important;
  font-size: 0.9375rem !important;
  vertical-align: top !important;
  word-break: break-word !important;
  background: transparent !important;
}
body.woocommerce-cart .cart_totals table th {
  font-weight: 600 !important;
  color: var(--nesa-ink-soft) !important;
  text-align: left !important;
  width: 40% !important;
}
body.woocommerce-cart .cart_totals table td {
  color: var(--nesa-ink) !important;
  text-align: right !important;
}
body.woocommerce-cart .cart_totals table .order-total th,
body.woocommerce-cart .cart_totals table .order-total td {
  font-weight: 700 !important;
  font-size: 1.125rem !important;
  color: var(--nesa-ink) !important;
  border-bottom: 0 !important;
  padding-top: 1rem !important;
}
body.woocommerce-cart .cart_totals .wc-proceed-to-checkout a.checkout-button {
  display: block !important;
  width: 100% !important;
  padding: 1rem !important;
  background: var(--nesa-ink) !important;
  color: #fff !important;
  text-align: center !important;
  border-radius: 9999px !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  transition: background 0.2s ease !important;
  box-sizing: border-box !important;
  text-decoration: none !important;
}
body.woocommerce-cart .cart_totals .wc-proceed-to-checkout a.checkout-button:hover {
  background: var(--nesa-ink) !important;
  color: #fff !important;
}

/* ══════════════════════════════════════════════════════
 * SINGLE PRODUCT — layout
 * ══════════════════════════════════════════════════════
 *
 * This section is intentionally empty. It described the PREVIOUS PDP, where
 * WooCommerce's own .woocommerce-product-gallery and .summary were direct
 * children of div.product, and it turned div.product itself into a
 * `grid-template-columns: 45fr 55fr !important` two-column grid.
 *
 * content-single-product.php no longer renders either of those elements — the
 * gallery and the buy column live inside .oxa-pdp__grid now. So div.product
 * had exactly two grid children: .oxa-pdp__grid and section.related. The whole
 * product landed in the 45fr column and the 55fr column stood empty, which is
 * why every bit of PDP content was squashed into the left ~45% of the screen
 * with a void beside it.
 *
 * Everything else here was already dead: rules pinning
 * .woocommerce-product-gallery__wrapper / __image to 520px, floats on .summary
 * and .entry-summary, and grid-column on .woocommerce-tabs — none of those
 * elements are rendered any more.
 *
 * Deleted rather than overridden. All of it was !important, so an override
 * would have needed !important of its own, and the 45fr/55fr grid would still
 * have been sitting there for the next person to trip over. PDP layout now
 * lives in one place: assets/css/oxa-pdp.css.
 */

/* ══════════════════════════════════════════════════════
 * HIDE REVIEWS
 * ══════════════════════════════════════════════════════ */

.star-rating,
.woocommerce-product-rating,
.comment-form-rating,
#reviews,
#tab-title-reviews {
  display: none !important;
}

/* ══════════════════════════════════════════════════════
 * SINGLE PRODUCT — typography
 * ══════════════════════════════════════════════════════ */

body.single-product div.product .product_title,
body.single-product div.product h1.product_title,
body.single-product div.product .entry-summary h1,
body.single-product div.product .summary h1 {
  font-size: 33px !important;
  font-weight: 700 !important;
  color: var(--nesa-ink) !important;
  margin: 0 0 0.75rem !important;
  line-height: 1.15 !important;
}
body.single-product div.product .price,
body.single-product div.product p.price {
  font-size: 24px !important; font-weight: 700 !important; color: var(--nesa-ink) !important; margin-bottom: 1.25rem !important;
}
body.single-product div.product .price del { color: var(--nesa-ink-soft) !important; font-size: 16px !important; font-weight: 400 !important; }
body.single-product div.product .price ins { text-decoration: none !important; color: #dc2626 !important; }
body.single-product div.product .woocommerce-product-details__short-description,
body.single-product div.product .woocommerce-product-details__short-description p {
  font-size: 16px !important; color: var(--nesa-ink) !important; line-height: 1.6 !important; margin-bottom: 1.5rem !important;
}
body.single-product div.product .product_meta {
  font-size: 14px !important; color: var(--nesa-ink-soft) !important;
  padding-top: 1.5rem !important; border-top: 1px solid var(--nesa-line) !important;
  display: flex !important; flex-direction: column !important; gap: 0.375rem !important;
}
body.single-product div.product .product_meta a { color: var(--nesa-ink) !important; }/*
 * Add-to-cart button: no rules here either — see the note in bp-product.css.
 * This block was the same idea with a 10px radius and a 52px height; both
 * fought .oxa-btn--primary through !important.
 */


/* ══════════════════════════════════════════════════════
 * SINGLE PRODUCT — tabs
 * ══════════════════════════════════════════════════════ */

body.single-product .woocommerce-tabs { border-top: 1px solid var(--nesa-line); padding-top: 2rem; margin-top: 2rem; }
body.single-product .woocommerce-tabs ul.tabs {
  list-style: none !important; padding: 0 !important; margin: 0 0 1.5rem !important;
  display: flex !important; gap: 0 !important; border-bottom: 2px solid var(--nesa-line) !important;
}
body.single-product .woocommerce-tabs ul.tabs li { margin: 0 !important; padding: 0 !important; background: none !important; border: none !important; border-radius: 0 !important; }
body.single-product .woocommerce-tabs ul.tabs li::before,
body.single-product .woocommerce-tabs ul.tabs li::after { display: none !important; }
body.single-product .woocommerce-tabs ul.tabs li a {
  display: block; padding: 0.75rem 1.5rem; font-size: 0.9375rem; font-weight: 500;
  color: var(--nesa-ink-soft); border-bottom: 2px solid transparent; margin-bottom: -2px; background: none !important;
}
body.single-product .woocommerce-tabs ul.tabs li.active a { color: var(--nesa-ink); border-bottom-color: var(--nesa-ink); }
body.single-product .woocommerce-tabs .panel { font-size: 16px; line-height: 1.7; color: var(--nesa-ink); }
body.single-product .woocommerce-tabs .panel h2 { font-size: 1.25rem !important; margin-bottom: 1rem; }

/* ══════════════════════════════════════════════════════
 * SINGLE PRODUCT — related/upsells
 * ══════════════════════════════════════════════════════ */

body.single-product .related.products,
body.single-product .up-sells,
body.single-product section.related.products {
  margin-top: 2rem !important; padding-top: 2rem !important; border-top: 0 !important;
}
body.single-product .related.products > h2,
body.single-product .up-sells > h2 {
  font-size: 1.25rem !important; font-weight: 700 !important; margin-bottom: 1.5rem !important; color: var(--nesa-ink) !important;
}

/* ══════════════════════════════════════════════════════
 * RESPONSIVE
 * ══════════════════════════════════════════════════════ */

@media (max-width: 900px) {
  body.single-product div.product { grid-template-columns: 1fr !important; gap: 1.5rem !important; }  body.woocommerce-cart .woocommerce { grid-template-columns: 1fr !important; }
  body.single-product div.product .woocommerce-product-gallery__wrapper,
  body.single-product div.product .woocommerce-product-gallery .flex-viewport,
  body.single-product div.product .woocommerce-product-gallery__image,
  body.single-product div.product figure.woocommerce-product-gallery__image {
    height: 380px !important;
    max-height: 380px !important;
  }
}