/* =========================================================
   Gifts by Bee V3.0.1 — Cart only
   ========================================================= */

body.woocommerce-cart .gbb-commerce-page__content>.woocommerce{
  display:grid;
  grid-template-columns:minmax(0,1fr) 360px;
  gap:56px;
  align-items:start;
}

/* Keep errors/information, but the "added to cart → View cart" success
   message is suppressed server-side on the cart page. */
body.woocommerce-cart .woocommerce-error,
body.woocommerce-cart .woocommerce-info{
  grid-column:1/-1;
}

/* Product list --------------------------------------------------- */
.gbb-cart-form{
  min-width:0;
  margin:0;
}

.gbb-cart-table-head{
  display:grid;
  grid-template-columns:minmax(0,1fr) 90px 126px 96px;
  gap:18px;
  align-items:center;
  padding:0 38px 13px 0;
  border-bottom:1px solid #dfd0c8;
  color:#8b716b;
  font:650 8.5px/1.2 'Manrope',sans-serif;
  letter-spacing:.11em;
  text-transform:uppercase;
}

.gbb-cart-table-head span:not(:first-child){
  text-align:right;
}

.gbb-cart-lines{
  width:100%;
}

.gbb-cart-line{
  position:relative;
  display:grid;
  grid-template-columns:112px minmax(0,1fr) 90px 126px 96px;
  gap:18px;
  align-items:center;
  min-height:150px;
  padding:22px 38px 22px 0;
  border-bottom:1px solid #e4d6cf;
}

.gbb-cart-line__image{
  width:100%;
}

.gbb-cart-line__image>a,
.gbb-cart-line__image>img{
  width:96px;
  height:116px;
}

.gbb-cart-line__image>a{
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  border:1px solid #e8d9d2;
  border-radius:4px;
  background:#fffaf7;
}

.gbb-cart-line__image img{
  width:100%!important;
  height:100%!important;
  padding:4px;
  display:block;
  object-fit:contain!important;
  object-position:center!important;
  background:transparent!important;
}

.gbb-cart-line__details{
  min-width:0;
}

.gbb-cart-line__name{
  display:inline-block;
  max-width:100%;
  margin:0 0 7px;
  color:#302724!important;
  font:600 14px/1.38 'Manrope','DM Sans',sans-serif;
  letter-spacing:-.008em;
}

.gbb-cart-line__details .variation{
  display:grid!important;
  grid-template-columns:auto minmax(0,1fr);
  gap:3px 6px;
  margin:0!important;
  color:#846e68;
  font:500 9.5px/1.45 'DM Sans',sans-serif;
}

.gbb-cart-line__details .variation dt,
.gbb-cart-line__details .variation dd{
  float:none!important;
  margin:0!important;
  padding:0!important;
}

.gbb-cart-line__details .variation dt{
  color:#62504b;
  font-weight:650;
}

.gbb-cart-line__details .variation p{
  margin:0!important;
}

.gbb-cart-line__price,
.gbb-cart-line__subtotal{
  color:#594945;
  font:600 11px/1.35 'Manrope',sans-serif;
  text-align:right;
  white-space:nowrap;
}

.gbb-cart-line__quantity{
  display:flex;
  justify-content:flex-end;
}

.gbb-cart-line__quantity .quantity.gbb-flow-quantity{
  width:116px!important;
  height:42px!important;
  grid-template-columns:35px 1fr 35px!important;
  border:1px solid #d8c7bf!important;
  border-radius:4px!important;
  background:#fffaf7!important;
}

.gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty,
.gbb-cart-line__quantity .gbb-flow-qty-button{
  height:40px!important;
}

.gbb-cart-line__quantity .gbb-flow-qty-button{
  min-width:35px!important;
  color:#8c6760!important;
}

.gbb-cart-line__remove{
  position:absolute;
  top:20px;
  right:0;
}

.gbb-cart-line__remove .remove{
  display:grid!important;
  place-items:center;
  width:28px!important;
  height:28px!important;
  margin:0!important;
  border:1px solid transparent!important;
  border-radius:50%!important;
  background:transparent!important;
  color:#9a716a!important;
  font:400 19px/1 'DM Sans',sans-serif!important;
}

.gbb-cart-line__remove .remove:hover{
  border-color:#e1cec6!important;
  background:#fffaf7!important;
  color:#704944!important;
}

.gbb-cart-line__mobile-label,
.gbb-cart-line__mobile-price{
  display:none;
}

/* Coupon / update row -------------------------------------------- */
.gbb-cart-actions{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:18px;
  padding-top:20px;
}

.gbb-cart-coupon{
  width:min(430px,70%);
}

.gbb-cart-coupon>label{
  display:block;
  margin:0 0 7px;
  color:#806b65;
  font:650 9px/1.3 'Manrope',sans-serif;
}

.gbb-cart-coupon>div{
  display:grid;
  grid-template-columns:minmax(0,1fr) 92px;
  gap:8px;
}

.gbb-cart-coupon input{
  min-height:46px!important;
}

.gbb-cart-coupon .button,
.gbb-cart-update{
  min-height:46px!important;
}

.gbb-cart-update{
  flex:0 0 auto;
  background:transparent!important;
  color:#80534e!important;
}

.gbb-cart-update:hover{
  background:var(--gbb-brand-accent)!important;
  color:#fff!important;
}

/* Totals --------------------------------------------------------- */
body.woocommerce-cart .cart-collaterals{
  grid-column:2;
  grid-row:1;
  position:sticky;
  top:calc(var(--gbb-full-header-height) + 24px);
  width:100%!important;
  min-width:0;
}

body.woocommerce-cart .cart-collaterals .cart_totals{
  width:100%!important;
  padding:26px 25px 24px!important;
}

body.woocommerce-cart .cart_totals h2{
  font-size:15px!important;
}

body.woocommerce-cart .cart_totals table th,
body.woocommerce-cart .cart_totals table td{
  padding:13px 0!important;
}

body.woocommerce-cart .wc-proceed-to-checkout a.checkout-button{
  min-height:52px!important;
}

/* Empty cart ----------------------------------------------------- */
body.woocommerce-cart .gbb-commerce-page__content>.woocommerce:has(.gbb-cart-empty){
  display:block;
}

.gbb-cart-empty{
  max-width:620px;
  margin:16px auto 0;
  padding:24px 0 52px;
  text-align:center;
  border-bottom:1px solid #e4d6cf;
}

.gbb-cart-empty__eyebrow{
  margin:0 0 10px!important;
  color:#9b5e58!important;
  font:650 8px/1.2 'Manrope',sans-serif!important;
  letter-spacing:.13em!important;
}

.gbb-cart-empty h2{
  margin:0 auto!important;
  max-width:520px;
  color:#302724!important;
  font:400 clamp(32px,4vw,45px)/1.08 'Playfair Display',Georgia,serif!important;
  letter-spacing:-.035em!important;
}

.gbb-cart-empty__copy{
  max-width:470px;
  margin:13px auto 0!important;
  color:#78645e!important;
  font:400 11px/1.6 'DM Sans',sans-serif!important;
}

.gbb-cart-empty__shop{
  min-width:176px!important;
  min-height:47px!important;
  margin-top:22px!important;
  display:inline-flex!important;
  align-items:center;
  justify-content:center;
}

.gbb-empty-cart-products{
  margin-top:44px!important;
  padding-top:0!important;
  border-top:0!important;
}

.gbb-empty-cart-products__heading{
  margin-bottom:25px!important;
}

/* Existing product-card component is intentionally preserved. */
.gbb-empty-cart-products__grid{
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:22px!important;
}

/* Mobile --------------------------------------------------------- */
@media(max-width:900px){
  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce{
    display:block;
  }

  body.woocommerce-cart .cart-collaterals{
    position:static;
    margin-top:32px;
  }

  .gbb-cart-table-head{
    display:none;
  }
}

@media(max-width:760px){
  .gbb-cart-line{
    grid-template-columns:88px minmax(0,1fr);
    gap:0 13px;
    align-items:start;
    min-height:0;
    padding:18px 28px 18px 0;
  }

  .gbb-cart-line__image{
    grid-column:1;
    grid-row:1 / span 3;
  }

  .gbb-cart-line__image>a,
  .gbb-cart-line__image>img{
    width:88px;
    height:108px;
  }

  .gbb-cart-line__details{
    grid-column:2;
    grid-row:1;
    padding-top:1px;
  }

  .gbb-cart-line__name{
    padding-right:8px;
    margin-bottom:5px;
    font-size:12px;
    line-height:1.4;
  }

  .gbb-cart-line__price{
    display:none;
  }

  .gbb-cart-line__mobile-price{
    display:flex;
    align-items:center;
    gap:7px;
    margin-top:6px;
    color:#7f6862;
    font:500 9.5px/1.35 'DM Sans',sans-serif;
  }

  .gbb-cart-line__mobile-price span{
    color:#9b827b;
  }

  .gbb-cart-line__mobile-price strong{
    color:#5a4742;
    font:600 10px/1.35 'Manrope',sans-serif;
  }

  .gbb-cart-line__quantity{
    grid-column:2;
    grid-row:2;
    justify-content:flex-start;
    align-items:center;
    gap:9px;
    margin-top:12px;
  }

  .gbb-cart-line__quantity .quantity.gbb-flow-quantity{
    width:106px!important;
    height:40px!important;
    grid-template-columns:32px 1fr 32px!important;
  }

  .gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty,
  .gbb-cart-line__quantity .gbb-flow-qty-button{
    height:38px!important;
  }

  .gbb-cart-line__quantity .gbb-flow-qty-button{
    min-width:32px!important;
  }

  .gbb-cart-line__subtotal{
    grid-column:2;
    grid-row:3;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    margin-top:11px;
    padding-top:10px;
    border-top:1px solid #eaded7;
    text-align:left;
  }

  .gbb-cart-line__mobile-label{
    display:inline;
    color:#8a746d;
    font:500 9.5px/1.35 'DM Sans',sans-serif;
  }

  .gbb-cart-line__subtotal strong{
    color:#4c3c38;
    font-size:10px;
  }

  .gbb-cart-line__remove{
    top:14px;
    right:0;
  }

  .gbb-cart-actions{
    display:block;
    padding-top:18px;
  }

  .gbb-cart-coupon{
    width:100%;
  }

  .gbb-cart-coupon>div{
    grid-template-columns:minmax(0,1fr) 82px;
  }

  .gbb-cart-update{
    width:100%!important;
    margin-top:10px!important;
  }

  body.woocommerce-cart .cart-collaterals{
    margin-top:25px;
  }

  body.woocommerce-cart .cart-collaterals .cart_totals{
    padding:20px 16px!important;
  }

  .gbb-cart-empty{
    margin-top:4px;
    padding:20px 4px 42px;
  }

  .gbb-cart-empty h2{
    max-width:320px;
    font-size:34px!important;
  }

  .gbb-cart-empty__copy{
    max-width:320px;
  }

  .gbb-cart-empty__shop{
    margin-top:20px!important;
  }

  .gbb-empty-cart-products{
    margin-top:38px!important;
  }

  .gbb-empty-cart-products__grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:12px!important;
  }
}


/* =========================================================
   V3.0.2 — two surgical cart fixes
   ========================================================= */

/* Explicit rows prevent the sticky totals card from reserving a tall,
   empty first grid row on desktop. */
@media(min-width:901px){
  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce{
    grid-template-rows:auto auto!important;
  }

  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce>.woocommerce-notices-wrapper,
  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce>.woocommerce-message,
  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce>.woocommerce-info,
  body.woocommerce-cart .gbb-commerce-page__content>.woocommerce>.woocommerce-error{
    grid-column:1/-1!important;
    grid-row:1!important;
    align-self:start!important;
  }

  body.woocommerce-cart .gbb-cart-form{
    grid-column:1!important;
    grid-row:2!important;
  }

  body.woocommerce-cart .cart-collaterals{
    grid-column:2!important;
    grid-row:2!important;
    align-self:start!important;
  }
}

/* Quantity controls are present in the HTML immediately, not added later. */
.gbb-cart-line__quantity .quantity.gbb-flow-quantity{
  display:grid!important;
  opacity:1!important;
  visibility:visible!important;
}

.gbb-cart-line__quantity .gbb-flow-qty-button{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
}


/* =========================================================
   V3.0.3 — quantity number + automatic update
   ========================================================= */

.gbb-cart-line__quantity .quantity.gbb-flow-quantity{
  grid-template-columns:34px 48px 34px!important;
  width:116px!important;
}

.gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty{
  display:block!important;
  width:48px!important;
  min-width:48px!important;
  max-width:48px!important;
  height:40px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-left:1px solid #eee0da!important;
  border-right:1px solid #eee0da!important;
  border-radius:0!important;
  background:#fffaf7!important;
  color:#302724!important;
  -webkit-text-fill-color:#302724!important;
  opacity:1!important;
  visibility:visible!important;
  text-align:center!important;
  font:650 12px/40px 'Manrope','DM Sans',sans-serif!important;
  appearance:textfield!important;
  -moz-appearance:textfield!important;
}

.gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty::-webkit-outer-spin-button,
.gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty::-webkit-inner-spin-button{
  -webkit-appearance:none!important;
  margin:0!important;
}

.gbb-cart-line__quantity .gbb-flow-qty-button{
  width:34px!important;
  min-width:34px!important;
  height:40px!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#8b625b!important;
  opacity:1!important;
}

.gbb-cart-line__quantity .gbb-flow-qty-button:disabled{
  color:#c9b8b2!important;
  cursor:not-allowed!important;
}

@media(max-width:760px){
  .gbb-cart-line__quantity .quantity.gbb-flow-quantity{
    grid-template-columns:32px 44px 32px!important;
    width:108px!important;
  }

  .gbb-cart-line__quantity .quantity.gbb-flow-quantity .qty{
    width:44px!important;
    min-width:44px!important;
    max-width:44px!important;
    height:38px!important;
    font-size:11px!important;
    line-height:38px!important;
  }

  .gbb-cart-line__quantity .gbb-flow-qty-button{
    width:32px!important;
    min-width:32px!important;
    height:38px!important;
  }
}
