/* GeneratePress page.php uses #primary, not the homepage's .bogg-wrap. */
body.bogg-commerce-page #primary {
  float: none !important;
  width: calc(100% - 48px) !important;
  max-width: 1040px !important;
  margin: 32px auto 64px !important;
  padding: 0;
}
body.bogg-commerce-page #primary .site-main { margin: 0; }
body.bogg-commerce-page #primary .inside-article { padding: 0; }
body.bogg-commerce-page #primary article { margin: 0; }
body.bogg-commerce-page main.bogg-wrap {
  width: calc(100% - 48px);
  max-width: 1040px;
  padding: 32px 0 64px !important;
}
body.bogg-commerce-page :is(.entry-title, main.bogg-wrap > article > h1) {
  margin: 0 0 30px;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0;
  text-align: center;
  text-transform: none;
}
body.bogg-commerce-page .entry-content { margin-top: 0; }
body.bogg-commerce-page .entry-content :is(.alignfull, .alignwide) {
  width: 100%;
  max-width: 100%;
  margin-left: 0 !important;
  margin-right: 0 !important;
}
body.bogg-commerce-page :is(.entry-content, main.bogg-wrap > article) {
  font-size: 15px;
  line-height: 1.5;
}
body.bogg-commerce-page :is(.woocommerce, .wp-block-woocommerce-cart, .wp-block-woocommerce-checkout) {
  width: 100%;
  max-width: 100%;
  margin: 0;
}

/* Preserve native forms and notices, including coupon expansion and errors. */
body.bogg-commerce-page :is(.woocommerce-info, .woocommerce-message, .woocommerce-error) {
  margin: 0 0 20px;
  padding: 12px 16px 12px 40px;
  font-size: 13px;
  line-height: 1.5;
}
body.bogg-commerce-page :is(.woocommerce-info, .woocommerce-message, .woocommerce-error)::before {
  top: 12px;
  left: 15px;
}
body.bogg-commerce-page .woocommerce-form-coupon-toggle { margin: 0; }
body.bogg-commerce-page .woocommerce-form-coupon-toggle .woocommerce-info { background: #fff; border: 1px solid var(--line); }
body.bogg-commerce-page .showcoupon { text-decoration: underline; text-underline-offset: 3px; }
body.bogg-commerce-page .woocommerce form.checkout_coupon { padding: 18px; margin: 0 0 24px; border-radius: 0; }
body.bogg-commerce-page .woocommerce form.checkout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px 40px;
  align-items: start;
  margin: 0;
}
body.bogg-commerce-page form.checkout > * { grid-column: 1 / -1; min-width: 0; }
/* WooCommerce clearfix pseudo-elements must not become extra grid cells. */
body.bogg-commerce-page form.checkout::before,
body.bogg-commerce-page form.checkout::after,
body.bogg-commerce-page #customer_details::before,
body.bogg-commerce-page #customer_details::after { content: none; }
body.bogg-commerce-page .woocommerce #customer_details.col2-set {
  display: block;
  grid-column: 1;
  float: none;
  width: 100%;
  margin: 0;
}
body.bogg-commerce-page .woocommerce #customer_details > :is(.col-1, .col-2) {
  display: flow-root;
  float: none;
  width: 100%;
  min-width: 0;
  margin: 0;
}
body.bogg-commerce-page .woocommerce #customer_details > .col-2 { margin-top: 24px; }
body.bogg-commerce-page :is(.woocommerce-billing-fields, .woocommerce-additional-fields, .woocommerce-shipping-fields) h3,
body.bogg-commerce-page #order_review_heading {
  margin: 0 0 18px;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: none;
}
body.bogg-commerce-page .woocommerce .form-row { padding: 0; margin: 0 0 14px; }
body.bogg-commerce-page .woocommerce .form-row label { margin-bottom: 5px; font-size: 13px; line-height: 1.5; }
body.bogg-commerce-page .woocommerce .form-row :is(input.input-text, select, textarea) {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 2px;
  color: var(--ink);
  background: #fff;
  font-size: 15px;
  line-height: 1.5;
}
body.bogg-commerce-page .woocommerce .form-row textarea { height: 76px; min-height: 76px; resize: vertical; }
body.bogg-commerce-page .woocommerce .form-row :is(input, select, textarea):focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
body.bogg-commerce-page .woocommerce :is(.form-row-first, .form-row-last) { width: calc(50% - 9px); }
body.bogg-commerce-page .woocommerce .form-row-first { float: left; clear: none; }
body.bogg-commerce-page .woocommerce .form-row-last { float: right; clear: none; }
body.bogg-commerce-page .woocommerce .form-row-wide { clear: both; }
body.bogg-commerce-page .select2-container { max-width: 100%; }
body.bogg-commerce-page .select2-container .select2-selection--single { height: 38px; border-color: var(--line); border-radius: 2px; }
body.bogg-commerce-page .select2-container .select2-selection__rendered { padding-left: 10px; line-height: 36px; font-size: 15px; }
body.bogg-commerce-page .select2-container .select2-selection__arrow { height: 36px; }
body.bogg-commerce-page #ship-to-different-address label { font-size: 15px; font-weight: 400; text-transform: none; }

body.bogg-commerce-page form.checkout > .bogg-checkout-summary {
  grid-column: 2;
  box-sizing: border-box;
  padding: 22px;
  border: 1px solid var(--line);
  background: #fff;
}
body.bogg-commerce-page #order_review { width: 100%; min-width: 0; }
body.bogg-commerce-page #order_review table.shop_table {
  width: 100%;
  margin: 0 0 18px;
  border: 0;
  border-collapse: collapse;
  font-size: 13px;
  line-height: 1.5;
}
body.bogg-commerce-page #order_review table.shop_table :is(th, td) { padding: 10px 0; border: 0; border-bottom: 1px solid var(--line); vertical-align: top; }
body.bogg-commerce-page #order_review table.shop_table :is(th, td):last-child { padding-left: 12px; text-align: right; }
body.bogg-commerce-page #order_review .product-name { overflow-wrap: anywhere; }
body.bogg-commerce-page #order_review .amount { white-space: nowrap; }
body.bogg-commerce-page #order_review .order-total .amount { font-size: 18px; font-weight: 500; }
body.bogg-commerce-page #payment { border: 0; border-radius: 0; background: transparent; }
body.bogg-commerce-page #payment ul.payment_methods { padding: 0; border-bottom: 1px solid var(--line); font-size: 15px; }
body.bogg-commerce-page #payment ul.payment_methods li { margin: 0 0 12px; }
body.bogg-commerce-page #payment ul.payment_methods li label { font-size: 15px; }
body.bogg-commerce-page #payment div.payment_box { width: 100%; padding: 0; margin: 12px 0; background: #fff; font-size: 13px; }
body.bogg-commerce-page #payment div.payment_box::before { display: none; }
body.bogg-commerce-page #payment :is(fieldset, iframe) { min-width: 0; max-width: 100%; }
body.bogg-commerce-page #payment fieldset { margin: 0; padding: 0; border: 0; }
body.bogg-commerce-page #payment .place-order { padding: 16px 0 0; margin: 0; }
body.bogg-commerce-page .woocommerce-privacy-policy-text { font-size: 13px; line-height: 1.5; }
body.bogg-commerce-page .woocommerce-privacy-policy-text p { margin: 0 0 14px; }
body.bogg-commerce-page #place_order { float: none; width: 100%; margin: 12px 0 0; }
body.bogg-commerce-page :is(#place_order, .checkout-button, .wc-block-cart__submit-button) {
  box-sizing: border-box;
  min-height: 44px;
  padding: 12px 16px;
  border-radius: 0;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 500;
  letter-spacing: 0;
  text-align: center;
  text-transform: uppercase;
}
body.bogg-commerce-page #place_order { border: 1px solid var(--ink); background: var(--ink); color: #fff; }
body.bogg-commerce-page #place_order:hover { background: #fff; color: var(--ink); }

/* The cart uses Blocks; its sidebar and full-width alignment need their own rules. */
body.bogg-commerce-page .wp-block-woocommerce-cart .wc-block-components-sidebar-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 40px;
  align-items: start;
  margin: 0;
}
body.bogg-commerce-page .wp-block-woocommerce-cart .wc-block-components-sidebar-layout > :is(.wc-block-components-main, .wc-block-components-sidebar) {
  box-sizing: border-box;
  width: auto;
  min-width: 0;
  margin: 0;
  padding: 0;
}
body.bogg-commerce-page .wp-block-woocommerce-cart .wc-block-components-sidebar-layout > .wc-block-components-sidebar { border: 1px solid var(--line); padding: 20px; }
body.bogg-commerce-page .wc-block-cart :is(.wc-block-cart-items, .wc-block-components-product-name) { font-size: 13px; line-height: 1.42; }
body.bogg-commerce-page .wc-block-cart .wc-block-components-product-metadata { font-size: 13px; }
body.bogg-commerce-page .wc-block-cart .wc-block-cart__totals-title { font-size: 13px; line-height: 1.5; }
body.bogg-commerce-page .wc-block-cart .wc-block-components-totals-footer-item { padding-top: 16px; padding-bottom: 16px; font-size: 18px; }
body.bogg-commerce-page .wc-block-cart .wc-block-cart__submit-container { padding: 0; }
body.bogg-commerce-page .wc-block-cart .wc-block-cart__submit-button { width: 100%; }
body.bogg-commerce-page .wc-block-cart .wc-block-cart-item__image { width: 72px; }
body.bogg-commerce-page .wc-block-cart .wc-block-cart-item__image img { width: 64px; height: 64px; object-fit: contain; }

/* Also contain shops using the classic cart shortcode. */
body.bogg-commerce-page .woocommerce-cart-form table.shop_table { font-size: 13px; }
body.bogg-commerce-page .woocommerce-cart-form .product-thumbnail img { width: 64px; }
body.bogg-commerce-page .cart-collaterals .cart_totals { box-sizing: border-box; width: 360px; max-width: 100%; padding: 20px; border: 1px solid var(--line); }
body.bogg-commerce-page .cart-collaterals h2 { font-size: 16px; }

@media (max-width: 800px) {
  body.bogg-commerce-page #primary { width: calc(100% - 32px) !important; max-width: 640px !important; margin: 24px auto 48px !important; }
  body.bogg-commerce-page main.bogg-wrap { width: calc(100% - 32px); max-width: 640px; padding: 24px 0 48px !important; }
  body.bogg-commerce-page .entry-title { font-size: 18px; margin-bottom: 24px; }
  body.bogg-commerce-page .woocommerce form.checkout,
  body.bogg-commerce-page .wp-block-woocommerce-cart .wc-block-components-sidebar-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  body.bogg-commerce-page .woocommerce #customer_details.col2-set,
  body.bogg-commerce-page form.checkout > .bogg-checkout-summary { grid-column: 1; }
  body.bogg-commerce-page form.checkout > .bogg-checkout-summary { padding: 18px; }
  body.bogg-commerce-page .woocommerce .form-row :is(input.input-text, select, textarea) { min-height: 44px; font-size: 16px; }
  body.bogg-commerce-page .select2-container .select2-selection--single { height: 44px; }
  body.bogg-commerce-page .select2-container .select2-selection__rendered { line-height: 42px; font-size: 16px; }
  body.bogg-commerce-page .select2-container .select2-selection__arrow { height: 42px; }
  body.bogg-commerce-page .cart-collaterals .cart_totals { width: 100%; float: none; }
}
@media (max-width: 480px) {
  body.bogg-commerce-page #customer_details :is(.form-row-first, .form-row-last) { width: 100%; float: none; }
  body.bogg-commerce-page .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row { grid-template-columns: 56px minmax(0, 1fr); column-gap: 12px; }
  body.bogg-commerce-page .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row .wc-block-cart-item__product { grid-column: 2; grid-row: 1; min-width: 0; }
  body.bogg-commerce-page .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row .wc-block-cart-item__total { grid-column: 2; grid-row: 2; padding: 10px 0 0; }
  body.bogg-commerce-page .wc-block-cart .wc-block-cart-item__image { width: 56px; }
  body.bogg-commerce-page .wc-block-cart .wc-block-cart-item__image img { width: 48px; height: 48px; }
}
