/* =====================================================
   HEALIO — Shop archive, product detail, cart, checkout
   Depends on tokens in main.css
   ===================================================== */

/* ---------- Free shipping progress bar (cache-safe: filled by JS) ---------- */
.healio-ship-bar{background:linear-gradient(90deg,var(--blush-soft),#fff);border:1px solid var(--line);border-radius:14px;padding:14px 18px;display:flex;flex-direction:column;gap:9px;margin:0 0 26px}
.healio-ship-bar[hidden]{display:none !important}
.healio-ship-bar__row{display:flex;align-items:center;gap:10px;font-size:13.5px;color:var(--wine)}
.healio-ship-bar__row svg{width:17px;height:17px;color:var(--rose);flex:0 0 auto}
.healio-ship-bar__row strong{color:var(--berry);font-weight:600}
.healio-ship-bar__track{height:7px;border-radius:999px;background:var(--blush-soft);overflow:hidden}
.healio-ship-bar__fill{height:100%;width:0;border-radius:999px;background:linear-gradient(90deg,var(--rose),var(--berry));transition:width .6s cubic-bezier(.22,1,.36,1)}
.healio-ship-bar.is-qualified .healio-ship-bar__row svg{color:#3f9d6b}
.healio-ship-bar.is-qualified .healio-ship-bar__fill{background:linear-gradient(90deg,#59b884,#3f9d6b)}

/* Header cart count: hide the badge entirely when empty. */
.cart-count[data-count="0"],.cart-count:empty{display:none}

/* ---------- Archive intro ---------- */
.healio-shop-hero{text-align:center;max-width:760px;margin:0 auto clamp(28px,3.5vw,42px)}
.healio-shop-hero .eyebrow{justify-content:center}
.healio-shop-hero h1, .healio-shop-hero .hd--h1 {font-size:clamp(34px,5vw,58px);margin:0 0 16px}
.healio-shop-hero p{color:var(--mauve);font-size:16.5px;max-width:52ch;margin:0 auto}
.healio-shop-trust{display:flex;flex-wrap:wrap;justify-content:center;gap:10px 22px;margin-top:20px}
.healio-shop-trust span{display:inline-flex;align-items:center;gap:7px;font-family:var(--font-mono);font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:var(--mauve)}
.healio-shop-trust span::before{content:"";width:6px;height:6px;border-radius:50%;background:var(--rose)}

/* ---------- Lens filter bar ---------- */
.shop-toolbar{gap:14px 20px}
.shop-filters{gap:8px}
.shop-pill{font-size:12.5px;padding:9px 17px}
.shop-pill.is-active{box-shadow:0 10px 20px -12px rgba(201,103,144,.7)}

/* ---------- Product cards (uniform, aligned Add to Cart) ---------- */
.woocommerce ul.products li.product{position:relative;display:flex;flex-direction:column}
.woocommerce ul.products li.product a.woocommerce-LoopProduct-link{display:flex;flex-direction:column}
.woocommerce ul.products li.product .woocommerce-loop-product__title{padding-top:6px}
.healio-card-desc{display:block;font-size:13px;color:var(--mauve);line-height:1.4;margin:2px 16px 8px;min-height:1.2em}
.woocommerce ul.products li.product .price{display:block;margin:0 0 2px}
.woocommerce ul.products li.product .price .from{font-size:11px;color:var(--mauve);font-weight:500}
.woocommerce ul.products li.product .price ins{text-decoration:none}
.healio-card-badges{position:absolute;top:12px;left:12px;z-index:3;display:flex;flex-direction:column;gap:6px;align-items:flex-start}
.healio-loop-badge{font-family:var(--font-mono);font-size:10px;letter-spacing:.09em;text-transform:uppercase;padding:6px 11px;border-radius:999px;line-height:1;display:inline-block}
.healio-loop-badge.is-use{background:rgba(255,255,255,.94);color:var(--berry);border:1px solid rgba(201,103,144,.4);backdrop-filter:blur(4px);box-shadow:0 6px 14px -8px rgba(43,10,20,.35)}
.healio-loop-badge.is-best{background:var(--wine);color:#fff}
.woocommerce ul.products li.product .added_to_cart{display:none !important}

/* Uniform buy row pinned to the card bottom so buttons align across the row. */
.healio-card-buy{margin-top:auto;display:flex;flex-direction:column;gap:10px;padding:10px 16px 0;align-items:stretch}
.healio-card-size{display:flex;flex-direction:column;gap:6px;align-items:center}
.healio-card-size__label{font-family:var(--font-mono);font-size:9.5px;letter-spacing:.12em;text-transform:uppercase;color:var(--mauve)}
.healio-card-doses{display:flex;justify-content:center;gap:6px;flex-wrap:wrap}
.healio-card-dose{border:1px solid var(--line);background:#fff;border-radius:999px;padding:6px 13px;font-size:12px;font-weight:600;color:var(--wine);cursor:pointer;font-family:var(--font-body);transition:border-color .2s,background .2s,color .2s}
.healio-card-dose:hover{border-color:var(--rose);color:var(--berry)}
.healio-card-dose.is-active{background:var(--blush-soft);border-color:var(--rose);color:var(--berry)}
.healio-card-dose.is-static{cursor:default;background:var(--cream)}
.healio-card-dose.is-static:hover{border-color:var(--line);color:var(--wine)}
.woocommerce ul.products li.product .healio-card-buy .button,.healio-card-buy .healio-card-add{margin:0 !important;width:100%;text-align:center}
.healio-card-add.loading{opacity:.6;pointer-events:none}
.healio-card-add.added{background:#3f9d6b !important}
/* Simple/stack card buttons now route through the Store API too (see shop.js),
   so give their loading/added states the same green success look as the
   variable-product quick-add — no stray "View cart" link, no dark hover stick. */
.woocommerce ul.products li.product .healio-card-buy .button.loading{opacity:.6;pointer-events:none}
.woocommerce ul.products li.product .healio-card-buy .button.added,
.woocommerce ul.products li.product .healio-card-buy .button.added:hover{background:#3f9d6b !important;transform:none !important}

/* =====================================================
   Single product (PDP)
   ===================================================== */
.single-product .page-shell{max-width:1340px;padding-top:clamp(10px,1.6vw,26px)}
.single-product .woocommerce-breadcrumb{margin-bottom:18px !important}
.woocommerce div.product{display:grid;grid-template-columns:minmax(0,1.04fr) minmax(0,.96fr);gap:clamp(34px,4.5vw,76px);align-items:start}

.woocommerce div.product div.images,
.woocommerce div.product .woocommerce-product-gallery,
.woocommerce div.product div.summary{width:100% !important;float:none !important;margin:0 !important}

/* No sticky gallery: it overlapped the full-width sections below when scrolling. */
.woocommerce div.product .woocommerce-product-gallery{position:relative !important;top:auto !important}
.woocommerce div.product .woocommerce-product-gallery__wrapper{margin:0}
.woocommerce div.product .woocommerce-product-gallery img{width:100%;border-radius:22px;background:linear-gradient(160deg,var(--blush-soft),#fff)}
.woocommerce-product-gallery__image a{pointer-events:none;cursor:default}
.woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__trigger{display:none !important}

.woocommerce div.product div.summary{display:flex;flex-direction:column;align-items:stretch}

.pdp-eyebrow{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin:0 0 10px}
.pdp-eyebrow .sci{font-family:var(--font-mono);font-size:11.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--rose)}
.pdp-cat-chip{font-family:var(--font-mono);font-size:10.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--mauve);border:1px solid var(--line);border-radius:999px;padding:4px 11px}
.pdp-stars{display:flex;align-items:center;gap:3px;margin:0 0 10px}
.pdp-stars svg{width:15px;height:15px;color:var(--rose)}
.pdp-stars span{margin-left:8px;font-size:13px;color:var(--mauve)}
.woocommerce div.product .product_title{font-size:clamp(32px,3.6vw,50px);line-height:1.03;margin:0 0 10px}
.pdp-benefit{font-size:17.5px;color:var(--mauve);line-height:1.5;margin:0 0 14px;max-width:52ch}

.woocommerce div.product p.price,.woocommerce div.product span.price{font-size:30px;margin:0 0 10px;display:flex;align-items:baseline;gap:12px;flex-wrap:wrap}
.woocommerce div.product p.price del,.woocommerce div.product span.price del{color:var(--mauve);font-size:19px;opacity:.75;font-weight:500}
.woocommerce div.product p.price ins,.woocommerce div.product span.price ins{text-decoration:none}
.woocommerce div.product p.price .price{display:contents}

.pdp-save{display:inline-flex;align-self:flex-start;background:var(--blush-soft);color:var(--berry);font-weight:600;font-size:13.5px;border-radius:999px;padding:7px 16px;margin:0 0 12px}
.pdp-stock{display:flex;align-items:center;gap:8px;font-size:13.5px;color:var(--mauve);margin:0 0 18px}
.pdp-stock b{color:var(--wine);font-weight:600}
.pdp-stock__dot{width:8px;height:8px;border-radius:50%;background:#3f9d6b;animation:healioPulse 2.2s infinite}
@keyframes healioPulse{0%{box-shadow:0 0 0 0 rgba(63,157,107,.45)}70%{box-shadow:0 0 0 7px rgba(63,157,107,0)}100%{box-shadow:0 0 0 0 rgba(63,157,107,0)}}

/* Dosage pills (native select hidden) */
.woocommerce div.product form.variations_form .variations{display:block;margin:0 0 6px}
.woocommerce div.product form.variations_form .variations tbody,.woocommerce div.product form.variations_form .variations tr{display:block}
.woocommerce div.product form.variations_form .variations th.label{display:block;text-align:left;font-family:var(--font-mono);font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:var(--mauve);padding:0 0 10px;font-weight:500}
.woocommerce div.product form.variations_form .variations td.value{display:block}
.woocommerce div.product form.variations_form .variations select{display:none !important}
.woocommerce div.product form.variations_form .reset_variations{display:none !important}
.woocommerce div.product .woocommerce-variation-price,.woocommerce div.product .woocommerce-variation-availability{display:none}
.healio-dose-pills{display:flex;flex-wrap:wrap;gap:10px;margin:0 0 6px}
.healio-dose-pill{border:1.5px solid var(--line);background:#fff;border-radius:16px;padding:13px 20px;min-width:92px;text-align:center;cursor:pointer;font-family:var(--font-body);transition:border-color .2s,background .2s,transform .2s,box-shadow .2s;display:flex;flex-direction:column;gap:3px}
.healio-dose-pill:hover{border-color:var(--rose);transform:translateY(-1px)}
.healio-dose-pill.is-active{border-color:var(--rose);background:var(--blush-soft);box-shadow:0 10px 20px -14px rgba(201,103,144,.8)}
.healio-dose-pill .d{font-weight:700;font-size:15px;color:var(--wine)}
.healio-dose-pill .p{font-size:12px;color:var(--berry);font-weight:600}

/* ---------- Bundle & Save ---------- */
.healio-bundle{margin:6px 0 4px;width:100%}
.healio-bundle__label{font-family:var(--font-mono);font-size:11px;letter-spacing:.12em;text-transform:uppercase;color:var(--berry);margin:0 0 10px}
.healio-bundle__opts{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.healio-bundle__opt{position:relative;display:flex;flex-direction:column;align-items:center;gap:2px;border:1.5px solid var(--line);background:#fff;border-radius:16px;padding:20px 8px 12px;cursor:pointer;font-family:var(--font-body);transition:border-color .2s,box-shadow .2s,transform .2s}
.healio-bundle__opt:hover{border-color:var(--rose);transform:translateY(-1px)}
.healio-bundle__opt.is-active{border-color:var(--rose);box-shadow:0 12px 24px -16px rgba(201,103,144,.9);background:linear-gradient(180deg,#fff,var(--blush-soft))}
.healio-bundle__badge{position:absolute;top:-10px;left:50%;transform:translateX(-50%);white-space:nowrap;font-family:var(--font-mono);font-size:8.5px;letter-spacing:.08em;text-transform:uppercase;padding:4px 10px;border-radius:999px;color:#fff}
.healio-bundle__badge.is-popular{background:var(--rose)}
.healio-bundle__badge.is-best{background:var(--wine)}
.healio-bundle__price{font-weight:700;font-size:17px;color:var(--wine)}
.healio-bundle__off{font-size:11.5px;color:var(--berry);font-weight:600;min-height:1em}
.healio-bundle__off--none{visibility:hidden}
.healio-bundle__qty{font-size:12px;color:var(--mauve);margin-top:2px}
.healio-bundle__total{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:14px 0 0;padding:14px 0 0;border-top:1px solid var(--line);font-size:14.5px}
.healio-bundle__total .bt-left{color:var(--mauve)}
.healio-bundle__total .bt-left b{color:var(--berry);font-weight:700;margin-right:4px}
.healio-bundle__total .bt-right{color:var(--wine);font-weight:700;font-size:17px}

/* Hide the numeric quantity stepper when Bundle & Save drives quantity. */
.woocommerce div.product form.cart:has(.healio-bundle) .quantity{display:none !important}

/* Quantity + Add to Cart */
.woocommerce div.product form.cart{margin:14px 0 0}
.woocommerce div.product form.cart .woocommerce-variation-add-to-cart,
.woocommerce div.product form.cart:not(.variations_form){display:flex;align-items:stretch;gap:12px;flex-wrap:wrap}
.woocommerce div.product form.cart div.quantity{display:flex;align-items:stretch;border:1.5px solid var(--line);border-radius:999px;overflow:hidden;background:#fff;margin:0;flex:0 0 auto}
.woocommerce div.product form.cart .quantity input.qty{width:44px;border:0;text-align:center;font-weight:600;font-size:15px;font-family:var(--font-body);background:transparent;-moz-appearance:textfield;appearance:textfield;padding:0}
.woocommerce div.product form.cart .quantity input.qty::-webkit-outer-spin-button,
.woocommerce div.product form.cart .quantity input.qty::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
.qty-btn{width:40px;border:0;background:transparent;font-size:17px;color:var(--berry);cursor:pointer;transition:background .2s}
.qty-btn:hover{background:var(--blush-soft)}
.woocommerce div.product form.cart .button.single_add_to_cart_button{flex:1;width:100%;padding:17px 34px !important;font-size:15.5px !important;letter-spacing:.03em;text-transform:uppercase;font-weight:700}

/* Trust trio */
.pdp-trust{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin:26px 0 0;border-top:1px solid var(--line);padding-top:22px}
.pdp-trust>div{display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center;font-size:11.5px;color:var(--mauve);line-height:1.45}
.pdp-trust svg{width:21px;height:21px;color:var(--rose)}
.pdp-trust__flag{font-size:20px;line-height:21px}
.pdp-trust b{display:block;color:var(--wine);font-size:12.5px}

/* Gallery trust chips + RUO flag */
.pdp-gallery-chips{display:flex;flex-wrap:wrap;gap:8px;margin:16px 0 0}
.pdp-gallery-chips span{display:inline-flex;align-items:center;gap:7px;font-size:12px;color:var(--wine);background:var(--paper);border:1px solid var(--line);border-radius:999px;padding:8px 13px}
.pdp-gallery-chips svg{width:14px;height:14px;color:var(--rose)}
.pdp-ruo-flag{position:absolute;top:14px;right:14px;z-index:3;background:rgba(43,10,20,.72);color:#fff;font-family:var(--font-mono);font-size:9.5px;letter-spacing:.1em;text-transform:uppercase;padding:6px 11px;border-radius:999px}

/* ---------- Tabbed details ---------- */
.healio-pdp-details{grid-column:1/-1;margin-top:clamp(40px,5vw,72px);padding-top:clamp(28px,3.5vw,48px);border-top:1px solid var(--line)}
.pdp-tabbar{display:flex;gap:4px;flex-wrap:wrap;border-bottom:1px solid var(--line);margin:0 0 clamp(24px,3vw,36px)}
.pdp-tab{appearance:none;background:none;border:0;border-bottom:2px solid transparent;margin-bottom:-1px;padding:13px 20px;font-family:var(--font-mono);font-size:12px;letter-spacing:.1em;text-transform:uppercase;color:var(--mauve);cursor:pointer;transition:color .2s,border-color .2s}
.pdp-tab:hover{color:var(--berry)}
.pdp-tab.is-active{color:var(--berry);border-bottom-color:var(--rose)}
.pdp-panel{display:none}
.pdp-panel.is-active{display:block;animation:healioFade .45s ease}
@keyframes healioFade{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
.pdp-overview-grid{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr);gap:clamp(28px,4vw,64px);align-items:start}
.pdp-lede{font-size:18.5px;line-height:1.7;color:var(--wine);margin:0 0 18px}
.pdp-overview-main p{color:var(--mauve);font-size:15.5px;line-height:1.75;margin:0 0 16px;max-width:64ch}
.pdp-block{margin:0 0 28px}
.pdp-block .eyebrow{margin-bottom:14px}
.pdp-benefits{list-style:none;padding:0;margin:0;display:grid;gap:12px}
.pdp-benefits li{display:flex;align-items:flex-start;gap:12px;font-size:15px;color:var(--wine);line-height:1.5}
.pdp-benefits li svg{width:18px;height:18px;color:var(--rose);flex:0 0 auto;margin-top:2px}
.pdp-whofor__lead{color:var(--mauve);font-size:14.5px;margin:0 0 12px}
.pdp-whofor__chips{display:flex;flex-wrap:wrap;gap:8px}
.pdp-whofor__chips span{border:1px solid var(--line);background:#fff;border-radius:999px;padding:7px 15px;font-size:12.5px;color:var(--wine)}
.pdp-specs{width:100%;max-width:720px;border-collapse:collapse}
.pdp-specs tr{border-bottom:1px solid var(--line)}
.pdp-specs tr:last-child{border-bottom:0}
.pdp-specs th,.pdp-specs td{text-align:left;padding:13px 0;font-size:14px;vertical-align:top}
.pdp-specs th{color:var(--mauve);font-weight:500;width:34%;padding-right:18px}
.pdp-specs td{color:var(--wine);font-weight:500;font-family:var(--font-mono);font-size:12.5px;word-break:break-word}
.pdp-storage-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;max-width:980px}
.pdp-storage-card{background:var(--paper);border:1px solid var(--line);border-radius:var(--radius);padding:22px;box-shadow:var(--shadow-soft)}
.pdp-storage-card b{display:block;color:var(--berry);font-size:11.5px;font-family:var(--font-mono);letter-spacing:.08em;text-transform:uppercase;margin-bottom:9px;font-weight:600}
.pdp-storage-card p{font-size:13.5px;color:var(--mauve);line-height:1.65;margin:0}

/* ---------- Stack showcase ---------- */
.pdp-stack-showcase{margin:0 0 clamp(32px,4vw,52px);background:linear-gradient(160deg,#fff,var(--blush-soft));border:1px solid var(--line);border-radius:24px;padding:clamp(24px,3.5vw,44px)}
.pdp-stack-head{text-align:center;margin-bottom:clamp(20px,2.5vw,30px)}
.pdp-stack-head .eyebrow{justify-content:center}
.pdp-stack-head h2, .pdp-stack-head .hd--h2 {font-size:clamp(24px,3vw,36px)}
.pdp-stack-grid{display:flex;align-items:stretch;justify-content:center;gap:clamp(10px,1.6vw,18px)}
.pdp-stack-plus{align-self:center;font-family:var(--font-display);font-size:30px;color:var(--rose);flex:0 0 auto}
.pdp-stack-card{flex:1 1 0;min-width:0;max-width:260px;background:#fff;border:1px solid var(--line);border-radius:18px;padding:18px;text-align:center;text-decoration:none;display:flex;flex-direction:column;gap:4px;transition:transform .3s ease,box-shadow .3s ease}
.pdp-stack-card:hover{transform:translateY(-4px);box-shadow:var(--shadow-soft)}
.pdp-stack-card__media img{width:100%;border-radius:12px;background:var(--blush-soft);margin:0 0 10px}
.pdp-stack-card__name{font-weight:650;color:var(--wine);font-size:15.5px}
.pdp-stack-card__sci{font-family:var(--font-mono);font-size:10.5px;letter-spacing:.06em;text-transform:uppercase;color:var(--mauve)}
.pdp-stack-card__dose{font-size:12px;color:var(--mauve)}
.pdp-stack-card__price{color:var(--berry);font-weight:600;font-size:14px;margin-top:auto;padding-top:6px}
.pdp-stack-card__price del{color:var(--mauve);font-weight:400;font-size:12px;margin-right:5px}
.pdp-stack-card__price ins{text-decoration:none}
.pdp-stack-math{display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:12px 28px;margin-top:clamp(20px,2.5vw,28px);padding-top:clamp(18px,2vw,24px);border-top:1px solid rgba(43,10,20,.08);font-size:15px}
.pdp-stack-math .m1{color:var(--mauve)}
.pdp-stack-math .m1 del{opacity:.85}
.pdp-stack-math .m2{color:var(--wine);font-weight:650}
.pdp-stack-math .m3{background:var(--berry);color:#fff;border-radius:999px;padding:9px 20px;font-weight:600;font-size:13.5px;box-shadow:0 12px 22px -12px rgba(142,36,68,.6)}

/* ---------- Complete your stack ---------- */
.healio-related{grid-column:1/-1;margin-top:clamp(34px,4vw,56px);margin-bottom:0}
.healio-related .products{margin-bottom:0 !important}
.healio-related__head{text-align:center;margin:0 0 28px}
.healio-related__head .eyebrow{justify-content:center}
.healio-related__head h2, .healio-related__head .hd--h2 {font-size:clamp(26px,3.4vw,40px)}
.healio-related__sub{color:var(--mauve);font-size:14.5px;margin-top:10px}
.healio-related .products{display:grid !important;grid-template-columns:repeat(4,1fr);gap:22px}

/* ---------- RUO legal banner ---------- */
.pdp-ruo{grid-column:1/-1;margin-top:clamp(18px,2vw,26px);background:var(--cream);border:1px solid var(--line);border-left:3px solid var(--rose);border-radius:12px;padding:18px 22px;font-size:13px;color:var(--mauve);line-height:1.65}
.pdp-ruo b{color:var(--berry)}

/* ---------- Sticky add-to-cart bar ---------- */
.pdp-sticky{position:fixed;left:0;right:0;bottom:0;z-index:140;grid-column:1/-1;background:rgba(255,255,255,.94);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-top:1px solid var(--line);box-shadow:0 -14px 34px -22px rgba(43,10,20,.35);transform:translateY(110%);transition:transform .35s cubic-bezier(.22,1,.36,1)}
.pdp-sticky.is-visible{transform:none}
.pdp-sticky__inner{max-width:1340px;margin:0 auto;display:flex;align-items:center;gap:14px;padding:10px clamp(16px,3vw,40px)}
img.pdp-sticky__thumb{width:46px;height:46px;border-radius:12px;object-fit:cover;background:var(--blush-soft);flex:0 0 auto}
.pdp-sticky__info{display:flex;flex-direction:column;min-width:0}
.pdp-sticky__name{font-weight:600;font-size:14.5px;color:var(--wine);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pdp-sticky__price{font-size:13.5px;color:var(--berry);font-weight:600}
.pdp-sticky__price del{color:var(--mauve);font-weight:400;margin-right:6px}
.pdp-sticky__price ins{text-decoration:none}
.pdp-sticky__price .from{font-size:11px;color:var(--mauve)}
.pdp-sticky__add{margin-left:auto;background:var(--rose);color:#fff;border:0;border-radius:999px;padding:13px 32px;font-weight:600;font-size:14px;font-family:var(--font-body);cursor:pointer;transition:background .25s ease,transform .25s ease;flex:0 0 auto}
.pdp-sticky__add:hover{background:var(--berry);transform:translateY(-1px)}

/* =====================================================
   Cart page (block cart)
   ===================================================== */
.woocommerce-cart .page-shell,.woocommerce-checkout .page-shell{max-width:1180px}
.woocommerce-cart .page-head,.woocommerce-checkout .page-head{text-align:center;margin:clamp(4px,1vw,14px) 0 clamp(20px,2.5vw,30px)}
.woocommerce-cart .page-head h1, .woocommerce-checkout .page-head h1, .woocommerce-cart .page-head .hd--h1, .woocommerce-checkout .page-head .hd--h1 {font-size:clamp(34px,4.5vw,52px)}
.wp-block-woocommerce-cart,.wp-block-woocommerce-checkout{margin:0 auto}
/* Cart/checkout blocks live inside .prose (page.php): widen + center. */
.woocommerce-cart .prose,.woocommerce-checkout .prose{max-width:1120px;margin-left:auto;margin-right:auto}
.woocommerce-cart .prose>*,.woocommerce-checkout .prose>*{max-width:none}

.wc-block-cart .wc-block-cart-items{border-top:1px solid var(--line)}
.wc-block-cart-item__image img{border-radius:14px;background:linear-gradient(160deg,var(--blush-soft),#fff)}
.wc-block-components-product-name{font-weight:600;color:var(--wine) !important;font-size:15.5px}
/* Remove the long item description in the cart; keep name + dosage. */
.wc-block-cart-item__product .wc-block-components-product-metadata__description,
.wc-block-cart-item__product .wc-block-components-product-details--description{display:none !important}
.wc-block-cart-item__prices .wc-block-components-product-price,.wc-block-components-totals-item__value{color:var(--berry)}
.wc-block-cart-item__remove-link{color:var(--rose) !important;font-size:12.5px;text-decoration:none;border-bottom:1px solid transparent;transition:border-color .2s}
.wc-block-cart-item__remove-link:hover{border-color:var(--rose)}
.wc-block-components-quantity-selector{border:1.5px solid var(--line) !important;border-radius:999px !important;overflow:hidden}
.wc-block-components-quantity-selector input{font-family:var(--font-body) !important;font-weight:600}
.wc-block-components-quantity-selector__button{color:var(--berry) !important}

.wc-block-cart .wc-block-components-sidebar,.wc-block-checkout .wc-block-components-sidebar{background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow-soft);padding:8px 20px 20px}
.wc-block-components-totals-wrapper{border-color:var(--line) !important}
.wc-block-components-totals-footer-item .wc-block-components-totals-item__label,.wc-block-components-totals-footer-item .wc-block-components-totals-item__value{font-family:var(--font-display);font-weight:520;color:var(--wine)}
.wc-block-cart__submit-container .wc-block-components-button,.wc-block-components-checkout-place-order-button{width:100%;padding:16px 24px !important;font-size:15.5px !important;letter-spacing:.02em}
.wc-block-components-express-payment-continue-rule{color:var(--mauve)}

/* Empty cart + "New in store" */
.wc-block-cart__empty-cart__image{display:none}
.wc-block-cart__empty-cart__title{font-family:var(--font-display);font-weight:480;font-size:clamp(24px,3vw,34px);color:var(--wine)}
.wp-block-woocommerce-cart h2.wc-block-cart__empty-cart__title::before, .wp-block-woocommerce-cart .hd--h2.wc-block-cart__empty-cart__title::before {content:"";display:block;width:54px;height:54px;margin:0 auto 18px;background:var(--blush-soft);border-radius:50%;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C96790' stroke-width='1.6'%3E%3Cpath d='M4.5 7h15l-1.2 11a2 2 0 0 1-2 1.8H7.7a2 2 0 0 1-2-1.8L4.5 7z'/%3E%3Cpath d='M8.5 9V6a3.5 3.5 0 0 1 7 0v3'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:center;background-size:26px}
.woocommerce-cart .prose h2, .wp-block-woocommerce-cart h2, .woocommerce-cart .prose .hd--h2, .wp-block-woocommerce-cart .hd--h2 {font-family:var(--font-display);font-weight:480;color:var(--wine)}
/* New in store: force a single row of 4 on desktop. */
.wc-block-grid__products{display:grid !important;grid-template-columns:repeat(4,1fr);gap:18px}
.wc-block-grid__product{float:none !important;width:auto !important;margin:0 !important;border:1px solid var(--line) !important;border-radius:var(--radius) !important;background:#fff;overflow:hidden;padding:0 0 18px !important;transition:transform .3s ease,box-shadow .3s ease}
.wc-block-grid__product:hover{transform:translateY(-5px);box-shadow:var(--shadow-lift)}
.wc-block-grid__product-image img{border-radius:0;background:linear-gradient(160deg,var(--blush-soft),#fff)}
.wc-block-grid__product-title{font-family:var(--font-body);font-weight:600;font-size:15px;color:var(--wine);padding:12px 14px 2px}
.wc-block-grid__product-price{color:var(--berry) !important;font-weight:600}
.wc-block-grid__product-price del{color:var(--mauve);font-weight:400;font-size:12.5px;margin-right:5px}
.wc-block-grid__product-price ins{text-decoration:none}
.wc-block-grid__product-onsale{display:none !important}
.wc-block-grid__product-add-to-cart .wp-block-button__link{background:var(--rose) !important;color:#fff !important;border-radius:999px !important;font-family:var(--font-body) !important;font-weight:600 !important;font-size:13.5px !important;padding:11px 24px !important;border:0 !important;transition:background .25s ease,transform .25s ease !important}
.wc-block-grid__product-add-to-cart .wp-block-button__link:hover{background:var(--berry) !important;transform:translateY(-2px)}

.wc-block-cart__cross-sells h2, .cross-sells h2, .wc-block-cart__cross-sells .hd--h2, .cross-sells .hd--h2 {font-family:var(--font-display);font-weight:480}

/* =====================================================
   Checkout (block checkout)
   ===================================================== */
.wc-block-checkout__form{margin-top:0}
.wc-block-components-checkout-step__title,.wc-block-components-title{font-family:var(--font-display) !important;font-weight:520 !important;color:var(--wine)}
.wc-block-components-text-input input,.wc-block-components-combobox .components-combobox-control__input,.wc-block-components-select .components-custom-select-control__button,.wc-block-checkout select,.wc-block-checkout input[type="text"],.wc-block-checkout input[type="email"],.wc-block-checkout input[type="tel"]{border:1px solid var(--line) !important;border-radius:12px !important;background:#fff !important;font-family:var(--font-body) !important;box-shadow:none !important}
.wc-block-components-text-input input:focus,.wc-block-checkout select:focus,.wc-block-checkout input:focus{border-color:var(--rose) !important;box-shadow:0 0 0 3px rgba(201,103,144,.16) !important;outline:none !important}
.wc-block-components-checkbox__input[type="checkbox"]{border-radius:5px;border-color:var(--line)}
.wc-block-components-checkbox__input[type="checkbox"]:checked{background:var(--rose);border-color:var(--rose)}
.wc-block-components-radio-control__option{border-color:var(--line)}
/* A second order summary can render inside the form column (the mobile
   collapsible header on some WC versions), showing coupon+totals but NO
   products — the "incorrect summary above Place Order" the owner reported.
   Never show any order summary in the form column; the sidebar one (with
   products) is the single source of truth. */
.wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block,
.wc-block-checkout__main .wc-block-components-checkout-order-summary,
.wc-block-checkout__main .wc-block-components-order-summary{display:none !important}
/* Order summary: keep name/dosage/price/photo, hide ONLY the long product description. */
.wc-block-checkout .wc-block-components-product-metadata__description,
.wc-block-components-order-summary .wc-block-components-product-metadata__description{display:none !important}
/* Mobile: order summary (products + coupon + totals) on top, then the form
   and the Place Order button below it, so Place Order sits UNDER the correct
   order summary (owner request). */
@media (max-width:781px){
  .wc-block-checkout{display:flex !important;flex-direction:column}
  .wc-block-checkout__sidebar{order:1}
  .wc-block-checkout__main{order:2}
}
.healio-checkout-trust{display:flex;flex-wrap:wrap;justify-content:center;gap:10px 28px;margin:26px auto 0;font-size:12.5px;color:var(--mauve)}
.healio-checkout-trust span{display:inline-flex;align-items:center;gap:8px}
.healio-checkout-trust svg{width:15px;height:15px;color:var(--rose)}
.healio-checkout-trust .flag{font-size:15px}

/* =====================================================
   Reveal-on-scroll
   ===================================================== */
.h-anim{opacity:0;transform:translateY(18px);transition:opacity .65s cubic-bezier(.22,1,.36,1),transform .65s cubic-bezier(.22,1,.36,1)}
.h-anim.h-in{opacity:1;transform:none}
@media (prefers-reduced-motion:reduce){.h-anim{opacity:1;transform:none;transition:none}.pdp-stock__dot{animation:none}.healio-ship-bar__fill{transition:none}}

/* =====================================================
   Responsive
   ===================================================== */
@media (max-width:1020px){
  .woocommerce div.product{grid-template-columns:1fr;gap:20px}
  .pdp-overview-grid{grid-template-columns:1fr}
  .pdp-storage-grid{grid-template-columns:1fr 1fr}
  .healio-related .products{grid-template-columns:repeat(3,1fr)}
  .pdp-stack-grid{flex-wrap:wrap}
  .wc-block-grid__products{grid-template-columns:repeat(2,1fr)}
}
@media (max-width:760px){
  .single-product .woocommerce-breadcrumb{display:none}
  .single-product .page-shell{padding-top:6px}
  .single-product .woo-shell .page-title{margin-bottom:0}
  .pdp-gallery-chips{display:none}
  /* Bigger product image on mobile (fills the screen; ATC below the fold is OK). */
  .woocommerce div.product .woocommerce-product-gallery img{max-height:none}
  .woocommerce div.product div.summary{margin-top:16px !important}
  .woocommerce div.product .product_title{font-size:30px;margin-bottom:8px}
  .pdp-benefit{font-size:15px;margin-bottom:10px}
  .pdp-stars{margin-bottom:10px}
  .woocommerce div.product p.price,.woocommerce div.product span.price{font-size:26px;margin-bottom:8px}
  .pdp-stock{margin-bottom:14px}
  .healio-dose-pill{flex:1;min-width:0;padding:11px 12px}
  .healio-bundle__opt{padding:18px 4px 10px}
  .healio-bundle__price{font-size:15px}
  .healio-bundle__badge{font-size:7.5px;padding:3px 7px}
  .healio-bundle__qty{font-size:11px}
  .pdp-trust{gap:8px;padding-top:18px;margin-top:22px}
  .pdp-trust>div{font-size:10.5px;gap:6px}
  .pdp-trust b{font-size:11.5px}
  .pdp-trust svg{width:19px;height:19px}
  .pdp-trust__flag{font-size:18px;line-height:19px}
  .healio-related .products,.woocommerce ul.products{grid-template-columns:repeat(2,1fr) !important}
  .healio-shop-hero p{font-size:15px}
  /* Hide the dosage pills on catalog cards so rows stay clean/aligned. */
  .healio-card-size{display:none}
  .healio-card-desc{margin-bottom:10px}
  .pdp-stack-grid{flex-direction:column;align-items:stretch}
  .pdp-stack-plus{align-self:center;font-size:24px;line-height:1}
  .pdp-stack-card{max-width:none;flex-direction:row;align-items:center;text-align:left;gap:4px 14px;padding:14px;display:grid;grid-template-columns:74px 1fr auto}
  .pdp-stack-card__media{grid-row:1/5}
  .pdp-stack-card__media img{width:74px;height:74px;object-fit:cover;margin:0}
  .pdp-stack-card__name{grid-column:2}
  .pdp-stack-card__sci{grid-column:2}
  .pdp-stack-card__dose{grid-column:2}
  .pdp-stack-card__price{grid-column:3;grid-row:1/5;align-self:center;margin:0;padding:0}
  .pdp-sticky__name{font-size:13px}
  .pdp-sticky__price{font-size:12.5px}
  .pdp-sticky__add{padding:12px 22px;font-size:13.5px}
  body.has-pdp-sticky{padding-bottom:70px}
  .pdp-specs th{width:40%}
}
@media (max-width:480px){
  .wc-block-grid__products{grid-template-columns:repeat(2,1fr)}
  img.pdp-sticky__thumb{display:none}
}

/* =====================================================
   Round 3 fixes
   ===================================================== */
/* Added-to-cart notice: single clean border (was a 3px top + border = double). */
.woocommerce-notices-wrapper{border:0 !important;background:transparent !important;box-shadow:none !important}
.woocommerce-message,.woocommerce-info,.woocommerce-error{border:1px solid rgba(201,103,144,.35) !important;border-left:3px solid var(--rose) !important;border-radius:14px !important;box-shadow:none !important;background:var(--blush-soft) !important;color:var(--wine) !important;display:flex;align-items:center;gap:10px}
.woocommerce-message .button,.woocommerce-info .button{margin-left:auto}

/* Bundle & Save: widget + running total always take full-width rows so the
   Add to Cart button gets its own line (never crunched beside the total). */
.woocommerce div.product form.cart .healio-bundle,
.woocommerce div.product form.cart .healio-bundle__total{flex:0 0 100% !important;width:100%}
.woocommerce div.product form.cart .button.single_add_to_cart_button{flex:1 1 100% !important;min-height:54px}

/* WooCommerce core adds a second checkmark via .button.added::after (icon font) —
   suppress it on card buttons so the 'Added \2713' text is the only check. */
.woocommerce a.button.added::after,
.healio-card-add.added::after,
.healio-newinstore a.button.added::after,
ul.products a.button.added::after{content:none !important;display:none !important}

/* New in store (empty cart): Healio product cards, matching the shop grid.
   The cart page body has no .woocommerce class and sits inside .prose, so
   reset the leaked editorial typography and restore the card frame. */
.healio-newinstore{margin-top:14px}
.healio-newinstore ul.products li.product{background:var(--paper) !important;border:1px solid var(--line) !important;border-radius:var(--radius) !important;overflow:hidden;padding:0 0 18px !important;text-align:center;box-shadow:var(--shadow-soft)}
.healio-newinstore ul.products li.product:hover{transform:translateY(-5px);box-shadow:var(--shadow-lift)}
.healio-newinstore a{text-decoration:none !important;box-shadow:none !important;background-image:none !important;color:var(--wine)}
.healio-newinstore .woocommerce-loop-product__title{font-family:var(--font-body) !important;font-size:16px !important;font-weight:600 !important;line-height:1.3 !important;letter-spacing:0 !important;text-decoration:none !important;padding:10px 14px 2px !important;margin:0 !important}
.healio-newinstore ul.products li.product img{margin:0 !important;border-radius:0 !important}
.healio-newinstore .price{font-size:15px !important;margin:2px 0 !important}
.healio-newinstore .healio-card-desc{margin:2px 14px 8px !important}
.healio-newinstore .products{display:grid !important;grid-template-columns:repeat(4,minmax(0,1fr)) !important;gap:22px;list-style:none;margin:0;padding:0}
.healio-newinstore .products::before,.healio-newinstore .products::after{content:none !important;display:none !important}
.healio-newinstore ul.products li.product{margin:0 !important;width:auto !important;min-width:0 !important;max-width:none !important;float:none !important}
@media (max-width:1020px){ .healio-newinstore .products{grid-template-columns:repeat(2,minmax(0,1fr)) !important} }
@media (max-width:480px){ .healio-newinstore .products{grid-template-columns:repeat(2,minmax(0,1fr)) !important;gap:14px} }

/* =====================================================
   Round 4 fixes: homepage ATC, mobile checkout summary,
   empty-cart CTA, mobile filter dropdowns
   ===================================================== */

/* Homepage featured cards now reuse the shop's .healio-card-buy quick-add
   row; keep it flush with .product-info's own 20px inset and pin it to the
   card bottom so ATC buttons line up evenly across the row. */
.featured .product-card{display:flex;flex-direction:column}
.featured .product-info{display:flex;flex-direction:column;flex:1}
.featured .product-info .healio-card-buy{padding:10px 0 0}
/* The featured grid lives outside any .woocommerce wrapper, so the shop's
   pink .button pill styling (scoped under .woocommerce) never reaches it and
   the button falls back to a plain underlined link. Restore the pink pill
   here, and hide WooCommerce's post-add "View cart" link (owner: it should
   not pop up on the homepage). */
.featured .healio-card-buy .button,
.featured .healio-card-add{background:var(--rose);color:#fff;border:0;border-radius:999px;font-family:var(--font-body);font-weight:600;font-size:13.5px;padding:12px 24px;width:100%;text-align:center;text-decoration:none;cursor:pointer;transition:background .25s ease,transform .25s ease}
.featured .healio-card-buy .button:hover,
.featured .healio-card-add:hover{background:var(--berry);transform:translateY(-2px)}
.featured .healio-card-add.added,
.featured .healio-card-buy .button.added{background:#3f9d6b}
.featured .healio-card-add.loading,
.featured .healio-card-buy .button.loading{opacity:.6;pointer-events:none}
.featured .added_to_cart{display:none !important}

/* Mobile checkout: the native "tap to expand" order-summary panel has no
   working toggle at this breakpoint, so it stays permanently collapsed
   (WooCommerce only auto-expands it above ~782px). Force it open on mobile
   too, matching desktop, and hide the now-redundant total+chevron preview
   that lived in the collapsed header. */
@media (max-width:781px){
  .wc-block-components-checkout-order-summary__content{display:block !important}
  .wc-block-components-checkout-order-summary__title .wc-block-formatted-money-amount,
  .wc-block-components-checkout-order-summary__title-icon{display:none !important}
}

/* Empty cart: fun on-brand messaging + CTA back to the shop (markup injected
   via the healio_empty_cart_cta render_block filter in inc/cart-checkout.php). */
.healio-empty-cart{max-width:420px;margin:16px auto 0;text-align:center}
.healio-empty-cart__sub{color:var(--mauve);font-size:15px;line-height:1.65;margin:0 0 22px}
/* .prose a{color:var(--berry)} otherwise beats .btn-solid's white text (higher specificity: class+element vs one class). */
.healio-empty-cart .btn-solid,.healio-empty-cart .btn-solid:hover{color:#fff}

/* Mobile: category + sort collapse into a single pill-button dropdown each
   (desktop keeps the existing flat pill row, untouched, via .shop-dd-row
   being display:none above the breakpoint). Uses native <details>/<summary>
   so it needs no JS to open/close; shop.js only closes siblings on open. */
.shop-dd-row{display:none}
@media (max-width:700px){
  .shop-filters,.shop-sort{display:none}
  .shop-dd-row{display:flex;gap:10px;width:100%}
  .shop-dd{position:relative;flex:1 1 0;min-width:0}
  .shop-dd__trigger{display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;list-style:none;cursor:pointer}
  .shop-dd__trigger::-webkit-details-marker{display:none}
  .shop-dd__trigger span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .shop-dd__chevron{width:13px;height:13px;flex:0 0 auto;transition:transform .25s ease}
  .shop-dd[open] .shop-dd__trigger{border-color:var(--rose);color:var(--berry);background:var(--blush-soft)}
  .shop-dd[open] .shop-dd__chevron{transform:rotate(180deg)}
  .shop-dd__panel{display:none;position:absolute;top:calc(100% + 8px);left:0;z-index:30;background:#fff;border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow-lift);padding:10px;flex-wrap:wrap;gap:8px;width:max-content;max-width:78vw}
  .shop-dd[open] .shop-dd__panel{display:flex}
  .shop-dd:last-child .shop-dd__panel{left:auto;right:0}
}
