/* ==========================================================================
   GoGoNano checkout v2 (2026-10-28). Loaded only when gn_co_v2_active().
   Markup: woocommerce/checkout/form-checkout.php + review-order.php and the
   "Checkout v2" block in functions.php. Everything is scoped to .gn-co-v2.
   ========================================================================== */

/* Customer Reviews prints an empty photo-viewer box in the footer. Its own CSS (which
   hides it) is not loaded on checkout (script diet), so hide the box here. */
body.gn-co-v2 .cr-pswp { display: none !important; }

/* Steps ------------------------------------------------------------------- */
.gn-co-v2 .gn-co-step {
  background: #fff;
  border: 1px solid #c9dcda;
  border-radius: 12px;
  padding: 20px 22px 8px;
  margin-bottom: 16px;
}
.gn-co-v2 .gn-co-step__title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 16px;
  padding: 0;
  border: 0;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
  color: #073a40;
}
.gn-co-v2 .gn-co-step__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #073a40;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}
/* Flatsome draws a line above the billing fields; the step titles already separate the steps. */
.gn-co-v2 .gn-co-step .woocommerce-billing-fields { border-top: 0; padding-top: 0; }
.gn-co-v2 .gn-co-step .form-row { margin-bottom: 14px; }
.gn-co-v2 .gn-co-step--payment { padding-bottom: 12px; }

/* Step 2: carriers ----------------------------------------------------------- */
.gn-co-v2 .gn-co-shipping { clear: both; margin: 4px 0 18px; }
.gn-co-v2 .gn-co-ship-group + .gn-co-ship-group { margin-top: 14px; }
.gn-co-v2 .gn-co-ship-group__title {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #4b5b5d;
}
.gn-co-v2 .gn-co-ship-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.gn-co-v2 .gn-co-ship {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid #c9dcda;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.gn-co-v2 .gn-co-ship:hover { border-color: #1eadbd; }
.gn-co-v2 .gn-co-ship.is-chosen,
.gn-co-v2 .gn-co-ship:has(input:checked) {
  border-color: #1eadbd;
  background: #eef8f9;
  box-shadow: inset 0 0 0 1px #1eadbd;
}
.gn-co-v2 .gn-co-ship input[type="radio"] {
  flex: 0 0 auto;
  margin: 0;
  accent-color: #1eadbd;
}
.gn-co-v2 .gn-co-ship label {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.3;
  color: #073a40;
  cursor: pointer;
}
/* the whole card is clickable */
.gn-co-v2 .gn-co-ship label::after { content: ""; position: absolute; inset: 0; }
.gn-co-v2 .gn-co-ship label { min-width: 0; }
.gn-co-v2 .gn-co-ship__name { flex: 1 1 auto; min-width: 0; }
.gn-co-v2 .gn-co-ship__note { display: block; margin-top: 2px; font-size: 12px; line-height: 1.3; color: #4b5b5d; }
.gn-co-v2 .gn-co-ship__price { flex: 0 0 auto; font-weight: 700; white-space: nowrap; }
.gn-co-v2 .gn-co-ship__logo { display: inline-flex; flex: 0 0 auto; gap: 4px; }
.gn-co-v2 .gn-co-ship__logo img { width: 44px; height: 22px; object-fit: contain; margin: 0; }
.gn-co-v2 .gn-co-free { color: #1a8a5a; font-weight: 700; }
.gn-co-v2 .gn-co-side .gn-co-ship-total td { font-weight: 700; color: #073a40; }

/* Pickup point, right under the chosen carrier's group */
.gn-co-v2 table.gn-co-pickup { width: 100%; margin: 10px 0 0; border: 0; }
.gn-co-v2 table.gn-co-pickup td { padding: 0; border: 0; }
.gn-co-v2 .gn-co-pickup .montonio-pickup-point-select-wrapper {
  padding: 12px 14px;
  border-radius: 10px;
  background: #eef8f9;
  border-left: 4px solid #1eadbd;
}
.gn-co-v2 .gn-co-pickup label { display: block; margin: 0 0 6px; font-size: 14px; font-weight: 700; color: #073a40; }
.gn-co-v2 .gn-co-pickup br { display: none; }
.gn-co-v2 .gn-co-pickup .select2-container .select2-selection--single { height: 44px; border-radius: 8px; border-color: #c9dcda; }
.gn-co-v2 .gn-co-pickup .select2-container .select2-selection__rendered { line-height: 42px; padding-left: 12px; }
.gn-co-v2 .gn-co-pickup .select2-container .select2-selection__arrow { height: 42px; }

/* Ship to a different address + order notes */
.gn-co-v2 .gn-co-step--delivery .woocommerce-shipping-fields h3,
.gn-co-v2 .gn-co-step--delivery #ship-to-different-address {
  margin: 4px 0 12px;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
}
.gn-co-v2 .woocommerce-additional-fields.is-collapsed { display: none; }
.gn-co-v2 .woocommerce-additional-fields > h3 { display: none; }
.gn-co-v2 .gn-co-notes-toggle {
  display: inline-block;
  margin: 0 0 14px;
  font-size: 14px;
  color: #1eadbd;
  font-weight: 600;
  text-decoration: none;
}
.gn-co-v2 .gn-co-notes-toggle:hover { color: #073a40; }

/* Step 3: payment -------------------------------------------------------------- */
.gn-co-v2 .gn-co-step--payment #payment { background: none; padding: 0; border: 0; }
.gn-co-v2 #payment ul.payment_methods {
  margin: 0 0 16px;
  padding: 0;
  border: 0;
}
.gn-co-v2 #payment ul.payment_methods > li {
  position: relative;
  margin: 0 0 8px;
  padding: 0;
  border: 1px solid #c9dcda;
  border-radius: 10px;
  background: #fff;
  list-style: none;
  transition: border-color .15s, background .15s;
}
.gn-co-v2 #payment ul.payment_methods > li:hover { border-color: #1eadbd; }
.gn-co-v2 #payment ul.payment_methods > li:has(> input:checked) {
  border-color: #1eadbd;
  background: #eef8f9;
  box-shadow: inset 0 0 0 1px #1eadbd;
}
.gn-co-v2 #payment ul.payment_methods > li > input {
  position: absolute;
  top: 17px;
  left: 14px;
  margin: 0;
  accent-color: #1eadbd;
}
/* the label fills the whole row, so the full card is clickable */
.gn-co-v2 #payment ul.payment_methods > li > label {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 13px 14px 13px 42px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
  color: #073a40;
  cursor: pointer;
}
.gn-co-v2 #payment ul.payment_methods > li > label img { margin: 0 0 0 auto; max-height: 24px; }
.gn-co-v2 #payment div.payment_box {
  margin: 0;
  padding: 0 14px 14px;
  background: none;
  font-size: 14px;
}
.gn-co-v2 #payment div.payment_box::before { display: none; }

/* Montonio bank logos: dense grid instead of 100×100 tiles */
.gn-co-v2 .montonio-bank-payments-form .montonio-bank-items:not(.montonio-bank-items--list) {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}
.gn-co-v2 .montonio-bank-payments-form .montonio-bank-items:not(.montonio-bank-items--list) .montonio-bank-item {
  width: auto;
  height: 52px;
  padding: 8px;
  border-radius: 8px;
}
.gn-co-v2 .montonio-bank-payments-form .montonio-bank-items .montonio-bank-item.active {
  border-color: #1eadbd;
  background: #eef8f9;
  box-shadow: inset 0 0 0 1px #1eadbd;
}
.gn-co-v2 #payment #montonio-payments-description.montonio-bank-items .montonio-bank-item-img { max-height: 22px; }

/* Summary: terms, place order, trust line ---------------------------------------- */
.gn-co-v2 .gn-co-place-order { margin: 16px 0 0; padding: 16px 0 0; border-top: 1px solid #e6eeee; }
.gn-co-v2 .gn-co-place-slot--main .gn-co-place-order { margin-top: 4px; }
.gn-co-v2 .gn-co-place-order .woocommerce-privacy-policy-text { font-size: 12px; line-height: 1.5; color: #6b7a7c; }
.gn-co-v2 .gn-co-place-order .woocommerce-privacy-policy-text p { margin: 12px 0 0; }
.gn-co-v2 .gn-co-place-order .form-row.validate-required { margin: 0 0 10px; }
.gn-co-v2 #place_order {
  width: 100%;
  min-height: 52px;
  margin: 4px 0 0;
  border-radius: 10px;
  font-size: 17px;
  letter-spacing: 0;
}
.gn-co-v2 .gn-co-place-order .gg-checkout-trust { margin: 12px 0 0; }

/* Summary: coupon ------------------------------------------------------------------ */
.gn-co-v2 .gn-co-coupon { margin: 12px 0 0; }
.gn-co-v2 .gn-co-coupon__toggle {
  margin: 0;
  padding: 0;
  min-height: 0;
  border: 0;
  background: none;
  color: #1eadbd;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  cursor: pointer;
}
.gn-co-v2 .gn-co-coupon__toggle:hover { color: #073a40; }
.gn-co-v2 .gn-co-coupon__toggle::before { content: "+ "; }
.gn-co-v2 .gn-co-coupon__box:not([hidden]) { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; }
.gn-co-v2 .gn-co-coupon__box input { flex: 1 1 140px; height: 42px; margin: 0; border-radius: 8px; }
.gn-co-v2 .gn-co-coupon__apply {
  flex: 0 0 auto;
  height: 42px;
  min-height: 0;
  margin: 0;
  padding: 0 16px;
  border-radius: 8px;
  background: #073a40;
  color: #fff;
  font-size: 14px;
  letter-spacing: 0;
  text-transform: none;
  line-height: 42px;
}
.gn-co-v2 .gn-co-coupon__apply:hover { background: #1eadbd; }
.gn-co-v2 .gn-co-coupon__msg { flex: 1 1 100%; margin: 0; font-size: 13px; color: #b3261e; }

/* Top of the page: the login / coupon toggle row is not shown in v2. The coupon lives
   in the summary; login is offered by the saving line in the summary (.gn-co-account),
   which opens WooCommerce's login form here at the top. */
.gn-co-v2 .gg-checkout-toggles { display: none; }
.gn-co-v2 form.woocommerce-form-login { max-width: 560px; margin: 0 0 20px; }

/* Top of the checkout: returning-customer saving for guests, above step 1 ----------- */
.gn-co-v2 .gn-co-account:empty { display: none; }
.gn-co-v2 .gn-co-account__text {
  margin: 0 0 16px;
  padding: 12px 16px;
  border-left: 4px solid #1eadbd;
  border-radius: 6px;
  background: #eef8f9;
  font-size: 14px;
  line-height: 1.45;
  color: #073a40;
}
.gn-co-v2 .gn-co-account__text strong { white-space: nowrap; }
.gn-co-v2 .gn-co-account__login { font-weight: 700; color: #1eadbd; text-decoration: none; white-space: nowrap; }
.gn-co-v2 .gn-co-account__login:hover { color: #073a40; }

/* Summary column --------------------------------------------------------------- */
.gn-co-v2 .gn-co-side .col-inner.has-border {
  border: 1px solid #c9dcda;
  border-radius: 12px;
  padding: 20px 22px;
  background: #fff;
}
.gn-co-v2 .gn-co-side #order_review_heading {
  margin: 0 0 12px;
  font-size: 18px;
  letter-spacing: 0;
  text-transform: none;
  color: #073a40;
}
.gn-co-v2 .gn-co-side .order-total th,
.gn-co-v2 .gn-co-side .order-total td { font-size: 18px; }
/* compact summary table */
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table thead { display: none; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table td,
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table th { padding: 7px 0 !important; font-size: 14px; }
.gn-co-v2 .gn-co-side .cart_item td { padding: 10px 0 !important; vertical-align: top; }
/* product row: thumbnail | name, quantity, attributes (markup: review-order.php) */
.gn-co-v2 .gn-co-side .cart_item .product-name { padding-right: 12px !important; }
.gn-co-v2 .gn-co-side .cart_item .product-total { width: 1%; text-align: right; }
.gn-co-v2 .gn-co-side .cart_item .product-total .amount { white-space: nowrap; }
/* sale price: old price on its own small line above the new one */
.gn-co-v2 .gn-co-side .cart_item .product-total del { display: block; font-size: 12px; line-height: 1.3; opacity: .7; }
.gn-co-v2 .gn-co-side .cart_item .product-total ins { text-decoration: none; }
.gn-co-v2 .gn-co-item { display: flex; align-items: flex-start; gap: 12px; }
.gn-co-v2 .gn-co-item .gn-co-item__img {
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  margin: 0;
  border-radius: 6px;
  object-fit: cover;
}
.gn-co-v2 .gn-co-item__body { flex: 1 1 auto; min-width: 0; font-size: 14px; line-height: 1.4; color: #073a40; }
.gn-co-v2 .gn-co-item__body .product-quantity { white-space: nowrap; font-weight: 600; color: #4b5b5d; }
/* product attributes: label and value side by side under the name */
.gn-co-v2 .gn-co-side .cart_item dl.variation {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1px 6px;
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.4;
  color: #4b5b5d;
}
.gn-co-v2 .gn-co-side .cart_item dl.variation dt,
.gn-co-v2 .gn-co-side .cart_item dl.variation dd {
  float: none;
  margin: 0;
  padding: 0;
  font-size: 12px;
}
.gn-co-v2 .gn-co-side .cart_item dl.variation dt { font-weight: 600; }
.gn-co-v2 .gn-co-side .cart_item dl.variation dd p { margin: 0; }
/* Summary table as a stack of flex rows: each row sizes its own label/value,
   so the narrow product price column no longer squeezes the totals rows. */
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table,
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tbody,
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tfoot { display: block; width: 100%; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tr {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid #e6eeee;
}
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tbody tr:first-child { border-top: 0; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tr > * { border: 0; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table .cart_item { align-items: flex-start; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table .cart_item .product-name { flex: 1 1 auto; min-width: 0; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table .cart_item .product-total { flex: 0 0 auto; width: auto; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tfoot th { flex: 0 1 auto; }
.gn-co-v2 .gn-co-side .woocommerce-checkout-review-order-table tfoot td { flex: 1 1 auto; text-align: right; }
.gn-co-v2 .gn-co-side .order-savings th,
.gn-co-v2 .gn-co-side .order-savings td { padding: 7px 8px !important; }
.gn-co-v2 .gn-co-side .order-total td { line-height: 1.25; }
.gn-co-v2 .gn-co-side .order-total .includes_tax { display: block; font-size: 12px; font-weight: 400; color: #4b5b5d; }
.gn-co-v2 .gn-co-freeship:empty { display: none; }
.gn-co-v2 .gn-co-freeship { margin: 14px 0 4px; }
.gn-co-v2 .gn-co-freeship__text { margin: 0 0 6px; font-size: 14px; color: #073a40; }
.gn-co-v2 .gn-co-freeship__bar { height: 6px; border-radius: 3px; background: #e6eeee; overflow: hidden; }
.gn-co-v2 .gn-co-freeship__bar span { display: block; height: 100%; border-radius: 3px; background: #1eadbd; }
.gn-co-v2 .gn-co-sumtoggle { display: none; }

/* Desktop: summary column follows the scroll. The script sets "top" so a summary
   taller than the window still shows its bottom (the button) before it sticks. */
@media (min-width: 850px) {
  .gn-co-v2 .gn-co-side .col-inner { position: sticky; top: 24px; }
}

/* Tablet + mobile: one column, summary collapsed into a bar at the top ---------- */
@media (max-width: 849px) {
  .gn-co-v2 .gn-co-side { order: -1; margin-bottom: 4px; }
  .gn-co-v2 .gn-co-side:not(.is-open) { padding-bottom: 0; }
  .gn-co-v2 .gn-co-sumtoggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin: 0 0 12px;
    padding: 12px 16px;
    border: 1px solid #c9dcda;
    border-radius: 10px;
    background: #eef8f9;
    color: #073a40;
    font-size: 15px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    line-height: 1.3;
    min-height: 0;
  }
  .gn-co-v2 .gn-co-sumtoggle__label::after { content: " ▾"; color: #1eadbd; }
  .gn-co-v2 .gn-co-side.is-open .gn-co-sumtoggle__label::after { content: " ▴"; }
  .gn-co-v2 .gn-co-sumtoggle__total { font-weight: 700; }
  .gn-co-v2 .gn-co-side:not(.is-open) .col-inner { display: none; }
}

@media (max-width: 549px) {
  .gn-co-v2 .gn-co-step { padding: 16px 14px 4px; border-radius: 10px; }
  .gn-co-v2 .gn-co-step--payment { padding-bottom: 16px; }
  .gn-co-v2 .gn-co-ship-list { grid-template-columns: 1fr; gap: 6px; }
  .gn-co-v2 .montonio-bank-payments-form .montonio-bank-items:not(.montonio-bank-items--list) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .gn-co-v2 .montonio-bank-payments-form .montonio-bank-items:not(.montonio-bank-items--list) .montonio-bank-item { height: 48px; padding: 6px; }
}

/* Cart page (preview): same carrier cards, one per row in the narrow totals column ---- */
.gn-cart-v2 .cart_totals .gn-cart-ship > td { padding: 12px 0 !important; text-align: left !important; }
.gn-cart-v2 .cart_totals .gn-cart-ship p { text-align: left !important; }
.gn-cart-v2 .gn-cart-ship .gn-co-ship label,
.gn-cart-v2 .gn-cart-ship .gn-co-ship__name { text-align: left; }
.gn-cart-v2 .gn-cart-ship__title {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 700;
  color: #073a40;
}
.gn-cart-v2 .gn-co-shipping { margin: 0 0 10px; }
.gn-cart-v2 .gn-co-ship-list { grid-template-columns: 1fr; gap: 6px; }
.gn-cart-v2 .gn-co-ship { padding: 8px 12px; }
.gn-cart-v2 .gn-co-ship label { font-size: 14px; }
.gn-cart-v2 .woocommerce-shipping-destination { margin: 0; font-size: 13px; color: #4b5b5d; }
