/* Checkout VIP simples e elegante
   Estilo 1 aprovado: compacto, limpo, com imagem do produto e cor suave do tema. */

body.pp-store-body{
  --pp-checkout-soft: color-mix(in srgb, var(--pp-store-accent, #22c55e) 9%, #ffffff 91%);
  --pp-checkout-line: color-mix(in srgb, var(--pp-store-accent, #22c55e) 18%, #e5e7eb 82%);
  --pp-checkout-text: #0f172a;
  --pp-checkout-muted: #64748b;
}

body.pp-store-body .pp-cart-modal{
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: flex-end;
  justify-content: center;
  background: rgba(2,6,23,.54);
  backdrop-filter: blur(3px);
  padding: 18px 12px calc(18px + env(safe-area-inset-bottom,0px));
}
body.pp-store-body .pp-cart-modal.pp-open,
body.pp-store-body .pp-cart-modal.open{display:flex;}

body.pp-store-body .pp-cart-box{
  width: min(680px,100%);
  max-height: 88vh;
  overflow: auto;
  background: #fff;
  color: var(--pp-checkout-text);
  border-radius: var(--pp-radius-modal,16px);
  box-shadow: 0 18px 42px rgba(0,0,0,.24);
  padding: 18px;
  position: relative;
}
body.pp-store-body .pp-cart-box h2{
  margin: 0 44px 14px 0;
  font-size: 24px;
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -.35px;
  color: var(--pp-checkout-text);
}
body.pp-store-body .pp-close{
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 22px;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
}

body.pp-store-body #ppCartItems{
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}
body.pp-store-body .pp-cart-line.pp-cart-item-card{
  display: grid;
  grid-template-columns: 96px minmax(0,1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 120px;
  padding: 12px;
  border: 1px solid var(--pp-checkout-line);
  border-radius: 15px;
  background: linear-gradient(135deg, var(--pp-checkout-soft), #fff 68%);
  box-shadow: 0 7px 18px rgba(15,23,42,.06);
}
body.pp-store-body .pp-checkout-item-img{
  width: 96px;
  height: 96px;
  border-radius: 13px;
  object-fit: cover;
  background: #f8fafc;
  box-shadow: 0 4px 12px rgba(0,0,0,.09);
  display: block;
}
body.pp-store-body .pp-checkout-item-placeholder{
  display: grid;
  place-items: center;
  font-size: 26px;
}
body.pp-store-body .pp-cart-item-main{
  min-width: 0;
  display: grid;
  gap: 5px;
}
body.pp-store-body .pp-cart-item-main > strong{
  color: var(--pp-checkout-text);
  font-size: 17px;
  line-height: 1.15;
  font-weight: 900;
}
body.pp-store-body .pp-cart-item-main > b{
  color: var(--pp-store-accent,#16a34a);
  font-size: 18px;
  line-height: 1;
  font-weight: 900;
}
body.pp-store-body .pp-cart-addons{
  color: var(--pp-checkout-muted);
  font-size: 12px;
  line-height: 1.25;
}
body.pp-store-body .pp-cart-qty{
  width: 132px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
  border: 1px solid var(--pp-checkout-line);
  border-radius: 12px;
  background: rgba(255,255,255,.82);
}
body.pp-store-body .pp-cart-qty button{
  width: 42px;
  height: 100%;
  border: 0;
  background: color-mix(in srgb, var(--pp-store-accent,#22c55e) 10%, #ffffff 90%);
  color: var(--pp-store-accent,#16a34a);
  font-size: 20px;
  font-weight: 900;
  cursor: pointer;
}
body.pp-store-body .pp-cart-qty strong{
  flex: 1 1 auto;
  text-align: center;
  color: var(--pp-checkout-text);
  font-size: 16px;
  font-weight: 900;
}
body.pp-store-body .pp-mini-btn{
  align-self: center;
  border: 0;
  background: transparent;
  color: var(--pp-store-accent,#16a34a);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  padding: 8px;
  white-space: nowrap;
}
body.pp-store-body .pp-mini-btn::before{content:'🗑 ';font-size:13px;}
body.pp-store-body .pp-empty{
  padding: 14px;
  border-radius: 12px;
  background: #f8fafc;
  color: #64748b;
  font-weight: 700;
}

body.pp-store-body .pp-cart-box label{
  display: block;
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 800;
  color: #334155;
}
body.pp-store-body .pp-cart-box input,
body.pp-store-body .pp-cart-box textarea,
body.pp-store-body .pp-cart-box select{
  width: 100%;
  min-height: 44px;
  margin-top: 5px;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: var(--pp-radius-input,10px);
  background: #fff;
  color: #0f172a;
  font-size: 14px;
  outline: none;
}
body.pp-store-body .pp-cart-box input:focus,
body.pp-store-body .pp-cart-box textarea:focus,
body.pp-store-body .pp-cart-box select:focus{
  border-color: color-mix(in srgb, var(--pp-store-accent,#22c55e) 45%, #e2e8f0 55%);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--pp-store-accent,#22c55e) 10%, transparent 90%);
}
body.pp-store-body .pp-cart-box textarea{min-height:76px;resize:vertical;}
body.pp-store-body .pp-checkout-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;}
body.pp-store-body .pp-coupon-apply{display:flex;gap:8px;align-items:center;}
body.pp-store-body .pp-coupon-apply input{flex:1 1 auto;}
body.pp-store-body .pp-coupon-apply button{
  min-height:42px;
  padding:0 14px;
  border:0;
  border-radius:10px;
  background:var(--pp-btn);
  color:#fff;
  font-size:13px;
  font-weight:850;
  cursor:pointer;
}
body.pp-store-body .pp-checkout-summary{
  margin:14px 0;
  padding:12px;
  border-radius:14px;
  background:#f8fafc;
  border:1px solid #e2e8f0;
}
body.pp-store-body .pp-total{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:6px 0;font-size:14px;color:#334155;}
body.pp-store-body .pp-total b{color:#0f172a;font-weight:900;}
body.pp-store-body .pp-grand-total{margin-top:10px;padding-top:10px;border-top:1px solid #e2e8f0;font-size:17px;font-weight:900;color:#0f172a;}
body.pp-store-body .pp-grand-total b{font-size:22px;color:var(--pp-store-accent,#16a34a);}
body.pp-store-body .pp-eta-box,
body.pp-store-body .pp-delivery-msg,
body.pp-store-body .pp-coupon-msg{font-size:12px;line-height:1.35;margin-top:8px;}
body.pp-store-body #ppSendOrder{
  width:100%;
  min-height:54px;
  border:0;
  border-radius:14px;
  background:var(--pp-btn);
  color:#fff;
  font-size:17px;
  font-weight:900;
  box-shadow:var(--pp-shadow-button);
  cursor:pointer;
}
body.pp-store-body #ppSendOrder:disabled{opacity:.6;cursor:not-allowed;}
body.pp-store-body .pp-small{color:#64748b;font-size:12px;line-height:1.35;margin:10px 0 0;}

@media(max-width:700px){
  body.pp-store-body .pp-cart-modal{padding:12px 10px calc(12px + env(safe-area-inset-bottom,0px));}
  body.pp-store-body .pp-cart-box{max-height:90vh;padding:16px;border-radius:16px;}
  body.pp-store-body .pp-cart-box h2{font-size:22px;}
  body.pp-store-body .pp-cart-line.pp-cart-item-card{grid-template-columns:82px minmax(0,1fr);gap:10px;min-height:104px;padding:10px;}
  body.pp-store-body .pp-checkout-item-img{width:82px;height:82px;border-radius:12px;}
  body.pp-store-body .pp-mini-btn{grid-column:2;justify-self:start;padding:2px 0 0;}
  body.pp-store-body .pp-cart-item-main > strong{font-size:16px;}
  body.pp-store-body .pp-cart-item-main > b{font-size:17px;}
  body.pp-store-body .pp-cart-qty{width:116px;height:36px;}
  body.pp-store-body .pp-cart-qty button{width:36px;font-size:18px;}
  body.pp-store-body .pp-checkout-grid{grid-template-columns:1fr;}
}


/* Forma de recebimento: Entrega ou Retirada no local. */
body.pp-store-body .pp-fulfillment{
  margin:16px 0;
  padding:0;
  border:0;
}
body.pp-store-body .pp-fulfillment legend{
  margin-bottom:10px;
  color:var(--pp-checkout-text);
  font-size:14px;
  font-weight:900;
}
body.pp-store-body .pp-fulfillment-options{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
body.pp-store-body .pp-fulfillment-option{
  display:block;
  margin:0;
  cursor:pointer;
}
body.pp-store-body .pp-fulfillment-option input{
  position:absolute;
  opacity:0;
  pointer-events:none;
}
body.pp-store-body .pp-fulfillment-option span{
  display:flex;
  min-height:74px;
  flex-direction:column;
  justify-content:center;
  gap:4px;
  padding:12px 14px;
  border:1px solid var(--pp-checkout-line);
  border-radius:16px;
  background:#fff;
  transition:border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
body.pp-store-body .pp-fulfillment-option strong{
  color:var(--pp-checkout-text);
  font-size:14px;
}
body.pp-store-body .pp-fulfillment-option small{
  color:var(--pp-checkout-muted);
  font-size:12px;
  line-height:1.35;
}
body.pp-store-body .pp-fulfillment-option.is-selected span,
body.pp-store-body .pp-fulfillment-option input:checked + span{
  border-color:var(--pp-store-accent,#22c55e);
  background:var(--pp-checkout-soft);
  box-shadow:0 0 0 3px color-mix(in srgb,var(--pp-store-accent,#22c55e) 12%,transparent);
}
body.pp-store-body .pp-pickup-details{
  display:grid;
  gap:6px;
  margin:10px 0 14px;
  padding:14px;
  border:1px solid var(--pp-checkout-line);
  border-radius:16px;
  background:linear-gradient(135deg,var(--pp-checkout-soft),#fff 72%);
  color:var(--pp-checkout-text);
}
body.pp-store-body .pp-pickup-details[hidden]{
  display:none;
}
body.pp-store-body .pp-pickup-details span{
  color:var(--pp-checkout-muted);
  font-size:13px;
  line-height:1.4;
}
@media(max-width:420px){
  body.pp-store-body .pp-fulfillment-options{
    grid-template-columns:1fr;
  }
}


/* Confirmação oficial do pedido dentro do PedidoPop. */
body.pp-store-body .pp-order-review,
body.pp-store-body .pp-order-success{display:grid;gap:14px;}
body.pp-store-body .pp-order-review[hidden],
body.pp-store-body .pp-order-success[hidden],
body.pp-store-body #ppCheckoutForm[hidden]{display:none;}
body.pp-store-body .pp-order-review__heading span,
body.pp-store-body .pp-order-success>span{font-size:11px;font-weight:900;letter-spacing:.08em;text-transform:uppercase;color:var(--pp-store-accent,#16a34a);}
body.pp-store-body .pp-order-review__heading h3,
body.pp-store-body .pp-order-success h3{margin:3px 0 5px;font-size:22px;line-height:1.15;color:var(--pp-checkout-text);}
body.pp-store-body .pp-order-review__heading p,
body.pp-store-body .pp-order-success p{margin:0;color:var(--pp-checkout-muted);font-size:13px;line-height:1.45;}
body.pp-store-body .pp-order-review__customer,
body.pp-store-body .pp-order-review__fulfillment{display:grid;grid-template-columns:1fr 1fr;gap:10px;}
body.pp-store-body .pp-order-review__customer>div,
body.pp-store-body .pp-order-review__fulfillment>div,
body.pp-store-body .pp-order-review__note{padding:12px;border:1px solid var(--pp-checkout-line);border-radius:14px;background:#fff;}
body.pp-store-body .pp-order-review small{display:block;margin-bottom:4px;color:var(--pp-checkout-muted);font-size:11px;font-weight:850;text-transform:uppercase;letter-spacing:.04em;}
body.pp-store-body .pp-order-review strong{color:var(--pp-checkout-text);font-size:14px;line-height:1.35;}
body.pp-store-body .pp-order-review__items{display:grid;border:1px solid var(--pp-checkout-line);border-radius:15px;background:#fff;overflow:hidden;}
body.pp-store-body .pp-order-review__item{display:flex;justify-content:space-between;gap:12px;padding:12px;border-top:1px solid #edf0f5;}
body.pp-store-body .pp-order-review__item:first-child{border-top:0;}
body.pp-store-body .pp-order-review__item small{margin:4px 0 0;text-transform:none;letter-spacing:0;}
body.pp-store-body .pp-order-review__item b{white-space:nowrap;color:var(--pp-store-accent,#16a34a);}
body.pp-store-body .pp-order-review__totals{padding:12px;border-radius:15px;background:#f8fafc;border:1px solid #e2e8f0;}
body.pp-store-body .pp-order-review__totals>div{display:flex;justify-content:space-between;gap:12px;margin:6px 0;color:#475569;font-size:13px;}
body.pp-store-body .pp-order-review__totals .is-total{margin-top:10px;padding-top:10px;border-top:1px solid #dbe3ed;color:var(--pp-checkout-text);font-size:17px;font-weight:900;}
body.pp-store-body .pp-order-review__totals .is-total b{color:var(--pp-store-accent,#16a34a);font-size:21px;}
body.pp-store-body .pp-order-review__note p{margin:0;color:var(--pp-checkout-text);font-size:13px;}
body.pp-store-body .pp-order-review__actions{display:grid;grid-template-columns:1fr 1.4fr;gap:10px;}
body.pp-store-body .pp-order-review__back{border:1px solid #dbe3ed;background:#fff;color:#334155;}
body.pp-store-body #ppConfirmOrder{border:0;background:var(--pp-btn);color:#fff;box-shadow:var(--pp-shadow-button);}
body.pp-store-body .pp-order-success{text-align:center;justify-items:center;padding:18px 6px 8px;}
body.pp-store-body .pp-order-success__icon{width:68px;height:68px;display:grid;place-items:center;border-radius:999px;background:#dcfce7;color:#15803d;font-size:36px;font-weight:950;box-shadow:0 0 0 8px #f0fdf4;}
body.pp-store-body .pp-order-success__actions{width:100%;display:grid;gap:10px;margin-top:4px;}
body.pp-store-body .pp-order-success__whatsapp{background:#16a34a;color:#fff;text-decoration:none;}
body.pp-store-body .pp-order-success__close{border:0;background:transparent;color:#64748b;font-weight:850;padding:8px 14px;cursor:pointer;}
@media(max-width:520px){
  body.pp-store-body .pp-order-review__customer,
  body.pp-store-body .pp-order-review__fulfillment,
  body.pp-store-body .pp-order-review__actions{grid-template-columns:1fr;}
}
