
/* Kaia Glow cart flow inspired by user-supplied checkout reference.
   Uses Kaia's own plum/cream identity rather than reproducing another brand. */
:root{--kg-cart-plum:#5a2944;--kg-cart-rose:#f8f0f4;--kg-cart-line:#ebdde5}
#kgAddedDialog{position:fixed;inset:auto 0 0;overflow:hidden;margin:auto auto 0;
 width:min(560px,100vw);max-width:100vw;max-height:min(85dvh,850px);
 border:0;border-radius:20px 20px 0 0;padding:0;color:#392b33;background:white;
 box-shadow:0 -10px 55px #30243136}
#kgAddedDialog::backdrop{background:#1b132380;backdrop-filter:blur(2px)}
#kgAddedContent{max-height:85dvh;display:flex;flex-direction:column;overflow:auto;overscroll-behavior:contain}
.kg-added-heading{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:20px 22px 15px;flex-shrink:0}
.kg-added-heading h2{font:700 21px/1.2 'DM Sans',Arial,sans-serif;color:#33222f;margin:0}
.kg-added-close{border:0;border-radius:50%;font-size:27px;line-height:1;background:#f8f1f4;color:#6c4159;width:38px;height:38px}
.kg-added-item{display:grid;grid-template-columns:70px minmax(0,1fr);align-items:center;gap:12px;padding:0 22px 16px;border-bottom:1px solid var(--kg-cart-line)}
.kg-added-item img{width:70px;height:78px;object-fit:contain;border-radius:10px;background:#faf5f7}
.kg-added-item strong{display:block;font-size:13px;line-height:1.4;max-width:100%;color:#382832}
.kg-added-item small{display:block;margin:5px 0;color:#856a79;font-size:11px}
.kg-added-item b{display:block;color:var(--kg-cart-plum);font-size:17px;margin-top:7px}
.kg-cart-offers{padding:18px 0 14px;background:#f9f5f7;min-width:0}
.kg-cart-offers:nth-of-type(even){background:white}
.kg-cart-offers h3{font:700 16px/1.3 'DM Sans',Arial,sans-serif;margin:0 18px 3px;color:#352731}
.kg-offer-subtitle{font-size:11px;color:#786673;margin:0 18px 13px;line-height:1.55}
.kg-offer-track{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;gap:10px;
 padding:0 17px 10px;scrollbar-width:thin;scrollbar-color:#d5bfc9 transparent}
.kg-cart-offer{position:relative;flex:0 0 158px;min-width:0;scroll-snap-align:start;
 background:white;border:1px solid #eee1e7;border-radius:12px;overflow:hidden;
 box-shadow:0 2px 8px #613c4c09}
.kg-cart-offer img{display:block;width:100%;height:126px;object-fit:contain;padding:9px;background:#fbf8f9}
.kg-offer-badge{position:absolute;top:8px;left:8px;border-radius:5px;background:#f4d9e7;
 color:#642b4a;font-size:10px;font-weight:800;padding:4px 6px}
.kg-offer-info{position:relative;padding:10px 10px 46px;min-height:128px}
.kg-offer-info small{font-size:9px;text-transform:uppercase;letter-spacing:.8px;color:#987b8b}
.kg-offer-name{font-size:11px;line-height:1.3;display:-webkit-box;-webkit-box-orient:vertical;
 -webkit-line-clamp:2;overflow:hidden;min-height:30px;margin:5px 0;color:#3a2a33}
.kg-offer-prices{display:flex;flex-wrap:wrap;align-items:baseline;gap:5px}
.kg-offer-prices del{font-size:9px;color:#94808b}
.kg-offer-prices b{font-size:13px;color:var(--kg-cart-plum)}
.kg-offer-plus{position:absolute;bottom:9px;right:9px;width:35px;height:35px;
 border-radius:8px;background:var(--kg-cart-plum);color:white;border:0;
 font-size:22px;font-weight:500}
.kg-offer-plus:disabled{background:#397b62}
.kg-offer-controls{display:flex;gap:10px;justify-content:center;margin:4px 0 0}
.kg-offer-controls button{width:32px;height:29px;border:1px solid #d8becb;border-radius:8px;color:var(--kg-cart-plum);font-size:20px;background:white}
.kg-added-footer{display:grid;grid-template-columns:1fr;gap:9px;
 position:sticky;bottom:0;padding:12px 22px max(17px,env(safe-area-inset-bottom));
 background:white;border-top:1px solid #eee0e6;z-index:3}
.kg-added-footer>span{text-align:center;font-size:10px;color:#8c7280}
.kg-added-open{min-height:47px;color:white;background:var(--kg-cart-plum);border:0;border-radius:9px;
 font-weight:700;font-size:14px}
.kg-added-keep{border:0;background:white;color:#744a62;font-size:12px;padding:8px}
/* Turn the drawer into a body-scroll region with a fixed purchase dock. */
.bag-dialog[open]{display:flex;flex-direction:column;overflow:hidden}
.bag-dialog .bag-head{flex:0 0 auto;position:relative;top:auto}
.bag-dialog #bagContent{flex:1 1 auto;min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}
.bag-dialog #bagContent .bag-body.kc-checkout{padding:0 20px 30px}
.kg-cart-steps{display:flex;gap:5px;padding:12px 0 10px;border-bottom:1px solid var(--kg-cart-line)}
.kg-cart-steps span{flex:1;text-align:center;border-radius:6px;padding:9px 4px;
 font-size:10px;font-weight:650;color:#9b8794;background:#fbf7f9}
.kg-cart-steps span:first-child{color:#3e7e61;background:#eff7f3}
.kg-cart-steps .kg-current{color:var(--kg-cart-plum);background:#f5e7ee}
.bag-dialog .kc-cart-section>.kc-section-title{padding-top:15px}
.bag-dialog .bag-item{grid-template-columns:82px minmax(0,1fr);gap:12px}
.bag-dialog .bag-item img{width:82px;height:88px;border-radius:10px}
.bag-dialog .bag-item h3{font-size:12px;line-height:1.4}
.bag-dialog .bag-item .quantity{height:33px;border-radius:7px}
.bag-dialog .bag-item .quantity button{min-width:35px;height:32px;font-size:17px}
.bag-dialog .bag-item .remove{font-size:11px;padding:8px}
.kg-cep-note{font-size:11px;color:#876e7c;line-height:1.5;margin:0 0 12px}
.kg-gift-choice{background:#fff}
.kg-gift-title{display:flex;align-items:baseline;justify-content:space-between;gap:10px;margin-bottom:10px}
.kg-gift-title h3{font-size:13px;font-weight:700;color:#4e3042;margin:0}
.kg-gift-title small{font-size:10px;color:#9a8190}
.kg-gift-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.kg-gift-option{position:relative;min-height:155px;border:1px solid #eadde3;border-radius:11px;
 min-width:0;padding:15px 6px 11px;display:flex;flex-direction:column;align-items:center;
 justify-content:flex-end;gap:9px;text-align:center;color:#6b5263;cursor:pointer;background:#fff;
 transition:border-color .15s ease,background-color .15s ease}
.kg-gift-option:has(input:checked){border-color:#602947;background:#fcf4f8;box-shadow:inset 0 0 0 1px #602947}
.kg-gift-option:focus-within{outline:2px solid #93627c;outline-offset:2px}
.kg-gift-option input{position:absolute;top:9px;right:9px;accent-color:var(--kg-cart-plum);width:17px;height:17px;margin:0}
.kg-gift-illustration{display:block;width:76px;max-width:90%;height:78px;object-fit:contain}
.kg-gift-caption{display:block;min-height:30px;font-size:11px;line-height:1.35;font-weight:650;color:#6b5263}
@media(max-width:380px){.kg-gift-option{min-height:141px;padding:12px 3px 9px;gap:6px}
.kg-gift-illustration{width:64px;height:67px}.kg-gift-caption{font-size:10px}}
.kg-gift-note{font-size:10px;line-height:1.4;color:#9b8190;margin:9px 0 0}
.kg-cart-recommendations{margin:0 -20px}
.kg-cart-recommendations .kg-cart-offers{padding:16px 0 12px}
.kg-cart-recommendations .kg-cart-offer{flex-basis:146px}
.kg-cart-recommendations .kg-cart-offer img{height:110px}
.kg-cart-recommendations .kg-offer-info{min-height:125px}
.kg-cart-recommendations .kg-offer-track{padding-left:20px;padding-right:20px}
.kg-cart-recommendations .kg-cart-offers h3,
.kg-cart-recommendations .kg-offer-subtitle{margin-left:20px;margin-right:20px}
.bag-dialog .kc-payment-section{padding-bottom:20px}
.bag-dialog .kc-payment-section #commerceEligibility{margin-top:11px}
.bag-dialog .kc-payment-section .kc-secure-note{display:none}
.kg-cart-dock{flex:0 0 auto;position:relative;z-index:4;box-shadow:0 -8px 28px #482e3f13;
 background:#fff;padding:12px 18px max(13px,env(safe-area-inset-bottom));border-top:1px solid #eadce4}
.kg-coupon-fold{border:1px solid #e9dfe4;border-radius:8px;background:#faf7f9;
 margin:0 0 10px;max-height:42vh;overflow-y:auto}
.kg-coupon-fold summary{display:list-item;cursor:pointer;list-style-position:inside;
 padding:11px 12px;font-size:12px;font-weight:650;color:#503344}
.kg-coupon-fold[open] summary{border-bottom:1px solid #e9dfe4}
.kg-coupon-fields{padding:10px 11px 14px}
.kg-coupon-fields .kc-cep-form{display:grid;grid-template-columns:1fr auto;gap:8px}
.kg-coupon-fields .kc-cep-form label{grid-column:1/-1;display:block;font-size:11px}
.kg-coupon-fields .kc-cep-form input{min-width:0;width:100%;height:43px;border:1px solid #e1d3dc;border-radius:7px;padding:8px 11px}
.kg-coupon-fields .kc-cep-form button{padding:8px 12px;border-radius:7px;background:#ebdbe4;color:#5a2944;font-size:11px}
.kg-coupon-fields .kc-inline-hint{font-size:10px;line-height:1.5;color:#745565}
.kg-dock-row{display:grid;grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr);align-items:center;gap:13px}
.kg-dock-total small{display:block;font-size:10px;color:#796778}
.kg-dock-total strong{display:block;font-size:19px;font-weight:750;margin-top:4px;color:#572944;font-variant-numeric:tabular-nums}
.kg-dock-action{min-width:0}
.kg-dock-action #kcPaymentArea{margin:0;display:block}
.kg-dock-action #kcPaymentArea .button,
.kg-dock-action #kcPaymentArea .kc-pay-action{background:var(--kg-cart-plum);
 min-height:49px;font-size:12px;border-radius:8px;padding:10px}
.kg-dock-action #kcPaymentArea button:disabled{opacity:.65}
.kg-dock-action .kc-payment-ready,.kg-dock-action .kc-pending-order{max-height:28vh;overflow:auto}
.kg-dock-note{font-size:9px;color:#96838e;display:block;text-align:center;margin-top:7px}
@media(min-width:800px){
 #kgAddedDialog{inset:50% 0 auto auto;transform:translateY(-50%);margin:0 5vw 0 auto;
  width:min(550px,90vw);max-height:82dvh;border-radius:19px;box-shadow:0 20px 70px #2d152c44}
 #kgAddedContent{max-height:82dvh}
}
@media(max-width:600px){
 .bag-dialog{width:100vw;max-width:100vw}
 .bag-head h2{font-size:28px}
 .kg-dock-total strong{font-size:17px}
 .kg-dock-row{gap:9px}
 .bag-dialog #bagContent .bag-body.kc-checkout{padding:0 16px 28px}
 .kg-cart-recommendations{margin:0 -16px}
 .kg-added-heading{padding:16px}
 .kg-added-item{padding:0 16px 13px}
 .kg-added-footer{padding-left:16px;padding-right:16px}
}
@media(max-width:365px){
 .kg-dock-row{grid-template-columns:1fr}
 .kg-dock-total{display:flex;align-items:center;justify-content:space-between}
 .kg-dock-action #kcPaymentArea .button{min-height:42px}
}


/* Kaia Glow — escolha de pagamento sem alterar o processamento financeiro */
.kg-payment-methods{border:0;padding:0;margin:18px 0 16px;min-width:0}
.kg-payment-methods[hidden]{display:none}
.kg-payment-methods legend{font-size:12px;font-weight:700;color:#563346;margin-bottom:9px}
.kg-payment-option{display:flex;align-items:center;gap:11px;padding:12px 14px;margin:7px 0;
 border:1px solid #e8d8dd;border-radius:12px;background:#fffdfc;cursor:pointer}
.kg-payment-option:has(input:checked){border-color:#906078;background:#fbf4f7}
.kg-payment-option input{accent-color:#66344f;width:17px;height:17px;flex-shrink:0}
.kg-payment-option-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.kg-payment-option-copy strong{font-size:13px;color:#422c39}
.kg-payment-option-copy small{font-size:11px;color:#75616c;line-height:1.45}
.kg-payment-method-note{font-size:11px;line-height:1.55;color:#806e77;margin:9px 0 12px}


/* Confirmar endereço — etapa compacta antes do pagamento */
.kg-address-form{margin:16px 0 20px;padding:20px;border:1px solid #e8d9df;border-radius:14px;background:#fffaf9}
.kg-address-form h4{font-size:17px;color:#542b42;margin:0 0 5px;font-weight:650}
.kg-address-form>p{font-size:12px;line-height:1.5;color:#7e6773;margin:0 0 16px}
.kg-address-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.kg-address-grid label{font-size:12px;font-weight:650;color:#54394a;display:grid;gap:6px}
.kg-address-grid .kg-address-wide{grid-column:1/-1}
.kg-address-grid input{width:100%;min-width:0;border:1px solid #ddcbd2;border-radius:9px;background:#fff;color:#392a32;padding:11px;font-size:13px}
.kg-address-grid input:focus{border-color:#8b5470;outline:2px solid #ead6df}
.kg-address-form .kg-address-status{margin:15px 0 10px;font-size:12px;color:#684158}
.kg-address-form button{width:100%;min-height:46px}
@media(max-width:500px){.kg-address-form{padding:15px}.kg-address-grid{gap:10px}.kg-address-grid label{grid-column:1/-1}}

.kc-checkout .kc-payment-section[hidden]{display:none!important}

/* Endereço confirmado — resumo compacto no lugar dos campos */
.kg-address-form[hidden],.kg-address-summary[hidden],.kc-delivery-section #shippingQuoteForm[hidden]{display:none!important}
.kg-address-summary{
 margin:16px 0 18px;padding:15px 16px;
 display:flex;align-items:center;justify-content:space-between;gap:14px;
 border:1px solid #dbc8d1;background:#fcf6f8;border-radius:12px;
}
.kg-address-summary-details{min-width:0}
.kg-address-summary-details strong{display:block;color:#4c2b3c;font-size:13px;margin-bottom:5px}
.kg-address-summary-details p{font-size:12px;line-height:1.55;color:#6b5261;margin:0;overflow-wrap:anywhere}
.kg-address-summary button{
 flex-shrink:0;padding:8px 10px;border:1px solid #cdaebf;border-radius:8px;
 color:#673a54;background:#fff;font-size:12px;font-weight:650;
}
.kg-address-summary button:focus-visible{outline:2px solid #8c5475;outline-offset:2px}
.kc-shipping-choices{scroll-margin-top:20px}
@media(max-width:520px){
 .kg-address-summary{align-items:flex-start;flex-direction:column;gap:9px}
 .kg-address-summary button{align-self:flex-start}
}
.kg-guest-freight{padding:20px;background:#fbf6f8;border:1px solid #e5d5dd;border-radius:13px;margin:18px 0}.kg-guest-freight h3{margin:0 0 8px;font-size:17px}.kg-guest-freight>p,.kg-guest-freight li{font-size:13px;line-height:1.6;color:#674c5b}.kg-guest-freight form{display:flex;align-items:end;gap:9px}.kg-guest-freight label{display:flex;flex-direction:column;gap:6px;font-size:12px;flex:1}.kg-guest-freight input{width:100%;min-height:45px;border:1px solid #bfa2b1;border-radius:7px;padding:11px;font-size:16px}.kg-guest-freight button{min-height:45px;border:0;border-radius:7px;background:#54233d;color:#fff;padding:10px 17px;font-weight:600}.kg-guest-freight button:disabled{opacity:.6}.kg-guest-freight ul{padding-left:20px}.kg-guest-freight [role=status]{margin-bottom:0}
