/* Native Woo Checkout block; gateway fields stay in the top-level page. */
/* Keep the contact label above autofilled text, including Fastlane initialization. */
.store-unified-checkout #contact-fields .wc-block-components-text-input input[type=email]{height:60px;min-height:60px;padding:26px 12px 8px;line-height:24px}
.store-unified-checkout #contact-fields .wc-block-components-text-input label{top:7px;left:12px;font-size:12px;line-height:16px;transform:none;transition:none}
.store-unified-checkout .wc-block-components-sidebar-layout.wc-block-checkout{align-items:start;gap:28px}
.store-unified-checkout .wc-block-checkout__main{min-width:0}
.store-unified-checkout .wc-block-checkout__sidebar{position:static;align-self:start}
.store-unified-checkout .wc-block-components-checkout-step{background:#fff;border:1px solid #dce5e8;border-radius:12px;padding:22px!important;margin:20px 0}
.store-unified-checkout .wc-block-components-checkout-step__heading{margin-bottom:16px}
.store-unified-checkout .wc-block-components-checkout-step__container{padding:0!important}
.store-unified-checkout .wc-block-components-checkout-step__title{font-size:20px}
.store-unified-checkout .wc-block-components-checkout-place-order-button{width:100%;border-radius:8px;background:#14594b;color:white;min-height:48px}
.store-unified-checkout .wc-block-checkout__sidebar .wp-block-woocommerce-checkout-order-summary-block{border:1px solid #dce5e8;border-radius:12px;padding:20px;background:white}
.store-checkout-routes-ready .wp-block-woocommerce-checkout-order-summary-cart-items-block{display:none}
/* Sidebar shipping controls use the same Woo store selection as checkout. */
.store-unified-checkout:has(.bs-shipping-card) .wp-block-woocommerce-checkout-shipping-methods-block{display:none}

.store-unified-checkout #bs-cart-preview{margin-bottom:24px}
@media(max-width:782px){.store-unified-checkout .wc-block-components-sidebar-layout.wc-block-checkout{display:flex;flex-direction:column}.store-unified-checkout .wc-block-checkout__main,.store-unified-checkout .wc-block-checkout__sidebar{width:100%;padding:0}.store-unified-checkout .wc-block-components-checkout-step{padding:16px!important}}
@media(min-width:783px){.store-unified-checkout .wc-block-components-sidebar-layout.wc-block-checkout{display:grid!important;grid-template-columns:minmax(0,2fr) minmax(280px,1fr);gap:28px}.store-unified-checkout .wc-block-checkout__main,.store-unified-checkout .wc-block-checkout__sidebar{width:auto!important;margin:0!important;padding:0!important}.store-unified-checkout .wc-block-checkout .wc-block-components-sidebar-layout{width:100%}}

.store-unified-checkout .wp-block-woocommerce-checkout{display:block!important}

/* Keep the page title and initial geometry stable while Woo and routes hydrate. */
body.store-unified-checkout.bs-cart-heading-ready #main-content>article>h1{display:block}
.store-unified-checkout .bs-route-toolbar #bs-cart-title{display:none}
.store-unified-checkout .bs-route-toolbar{min-height:24px;margin:0 0 16px}
/* Once the address moves into the sidebar, a hidden subtitle needs no row. */
body.store-unified-checkout.bs-cart-heading-ready .bs-route-toolbar:has(#bs-routing-result[hidden]):not(:has(.bs-route-destination)){display:none;min-height:0;margin:0}
/* Decoration-only carts have no routing subtitle; collapse its reserved row. */
body.store-unified-checkout.bs-cart-decoration-only .bs-route-toolbar{display:none;min-height:0;margin:0}
body.store-unified-checkout.bs-cart-decoration-only .wp-block-woocommerce-checkout:not(:has(>.bs-route-toolbar))::before{display:none}
.store-unified-checkout .bs-route-status{min-height:24px}
.store-checkout-has-items .wp-block-woocommerce-checkout-order-summary-cart-items-block,
.store-checkout-has-items .wp-block-woocommerce-checkout-shipping-methods-block{display:none}
.store-checkout-has-items #bs-cart-preview:has(#bs-route-items:empty){min-height:340px}
.store-checkout-has-items #bs-cart-preview:not(.wc-block-checkout__main #bs-cart-preview){display:none}
.store-checkout-has-items .wc-block-checkout__main:not(:has(#bs-cart-preview))::before{content:'Loading your items…';display:block;box-sizing:border-box;min-height:340px;margin-bottom:24px;padding:24px;border:1px solid #dce5e8;border-radius:12px;color:#637589;background:linear-gradient(110deg,#f5f8f7,#fff)}
.store-checkout-has-items .wp-block-woocommerce-checkout:not(:has(>.bs-route-toolbar))::before{content:'Checking your delivery plan…';display:block;min-height:24px;margin-bottom:16px;font-size:13px;color:#637589}
.store-unified-checkout .bs-shipping-card{min-height:245px}
.store-unified-checkout .bs-route-destination{min-height:150px}
.store-unified-checkout .bs-free-shipping{min-height:100px}
.store-unified-checkout .bs-free-shipping-unlocked{min-height:0;display:flex;align-items:center;padding-top:8px;padding-bottom:8px}
.store-unified-checkout .bs-free-shipping-unlocked p{margin:0;line-height:1.4}
.store-unified-checkout .wc-block-checkout__sidebar:not(:has(.bs-route-destination))::before{content:'Loading delivery options…';display:block;min-height:440px;padding:20px;box-sizing:border-box;color:#637589;background:#f7faf9;border:1px solid #dce5e8;border-radius:12px;margin-bottom:20px}

/* Align the first visible cards; reserve space only during initial loading. */
body.store-unified-checkout #main-content{padding-top:24px}
body.store-unified-checkout #main-content>article>h1{margin:0 0 8px;line-height:1.2}
body.store-unified-checkout .wc-block-checkout__main,
body.store-unified-checkout .wc-block-checkout__sidebar{align-self:start;padding-top:0!important;margin-top:0!important}
body.store-unified-checkout .wc-block-checkout__sidebar>.bs-free-shipping,
body.store-unified-checkout .wc-block-checkout__sidebar>.bs-route-destination,
body.store-unified-checkout .wc-block-checkout__main>#bs-cart-preview{margin-top:0!important}
body.store-unified-checkout .wc-block-checkout__sidebar.is-sticky{position:static!important;top:auto!important}

/* The sidebar owns the saved delivery address; keep Woo's billing control live. */
.store-unified-checkout:has(.bs-saved-delivery.has-address) #shipping-fields:not(:has(.has-error)) .wc-block-components-checkout-step__heading,
.store-unified-checkout:has(.bs-saved-delivery.has-address) #shipping-fields:not(:has(.has-error)) .wc-block-components-address-address-wrapper{display:none}
.store-unified-checkout:has(.bs-saved-delivery.has-address) #shipping-fields:not(:has(.has-error)){margin-top:-12px;padding-top:16px!important;padding-bottom:16px!important}
.store-unified-checkout #shipping-fields .wc-block-checkout__use-address-for-billing{margin:0}

/* Use the same sidebar card treatment for delivery, shipping and totals. */
.store-unified-checkout .wc-block-checkout__sidebar > .bs-route-destination {
    box-sizing:border-box;
    width:100%;
    min-height:0;
    margin-bottom:20px;
    padding:20px;
    border:1px solid #dce5e8;
    border-radius:12px;
    background:#fff;
    color:#172b42;
}
.store-unified-checkout .wc-block-checkout__sidebar .bs-address-card-heading { margin-bottom:12px; }
.store-unified-checkout .wc-block-checkout__sidebar .bs-address-card-heading strong { font-size:18px; font-weight:650; line-height:1.4; }
.store-unified-checkout .wc-block-checkout__sidebar .bs-address-pin { display:none; }
.store-unified-checkout .wc-block-checkout__sidebar .bs-saved-delivery address {
    padding:0;
    border:0;
    border-radius:0;
    background:transparent;
    font-style:normal;
}

/* Contact email belongs beside payment; Fastlane cards use it for recognition. */
.store-unified-checkout.store-contact-hidden #contact-fields{display:none}
.store-unified-checkout #payment-method + #contact-fields{margin-top:-12px}
/* A useful empty state, including after the last item is removed in Blocks. */
.bs-empty-shopping{display:none}
.bs-checkout-empty .bs-empty-shopping{display:block}
.bs-checkout-empty #main-content>article>h1{text-align:center}
.bs-checkout-empty .wp-block-woocommerce-checkout,.bs-checkout-empty #bs-cart-preview,.bs-checkout-empty .bs-route-destination,.bs-checkout-empty .bs-shipping-card{display:none!important}
.bs-empty-shopping-intro{max-width:800px;margin:20px auto 42px;padding:42px 28px;text-align:center;background:#f0f7f3;border:1px solid #dce8e1;border-radius:18px}
.bs-empty-shopping-icon{display:inline-flex;align-items:center;justify-content:center;width:64px;height:64px;border-radius:50%;background:#dceee5;color:#104c3f;margin-bottom:14px}
.bs-empty-shopping-icon svg{width:30px;height:30px}
.bs-empty-eyebrow{font-size:11px;font-weight:700;letter-spacing:1.5px;color:#416e5c}
.bs-empty-shopping-intro h2{font-size:clamp(26px,3vw,36px);line-height:1.15;color:#104c3f;margin:14px auto;max-width:600px}
.bs-empty-shopping-intro>p:not(.bs-empty-eyebrow){max-width:510px;margin:16px auto;color:#647081}
.bs-empty-shopping-actions{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:20px;margin-top:26px}
.bs-empty-shopping-actions a{font-weight:700;color:#104c3f}
.bs-empty-shopping-actions a.button{background:#104c3f;color:white;padding:14px 22px;border-radius:8px;text-decoration:none}
.bs-empty-recommendations>h2,.bs-empty-recommendations>p{text-align:center}
.bs-empty-recommendations>h2{font-size:24px;margin-bottom:8px}
.bs-empty-recommendations>p{color:#647081;margin-bottom:26px}
@media(max-width:600px){.bs-empty-shopping-intro{padding:28px 18px;margin-top:12px}.bs-empty-shopping-actions{flex-direction:column;gap:16px}}
.bs-empty-recommendations ul.products li.product{position:relative}
