/*! HP cart — WooCommerce-style cart matching the reference storefront layout */
:root{
  --ct-blue:#1a97d5;
  --ct-blue-dark:#1487c1;
  --ct-ink:#242424;
  --ct-line:rgba(0,0,0,.075);
  --ct-line-soft:rgba(0,0,0,.09);
  --ct-grey:#f7f7f7;
  --ct-muted:#767676;
}

/* first-paint guard: native cart chrome stays invisible until our shell is in place */
main.cart-page > .cart-breadcrumb,
main.cart-page > .cart-heading,
main.cart-page > .cart-alert,
main.cart-page > .cart-layout{visibility:hidden;}
main.cart-page.hp-cart-fb > .cart-breadcrumb,
main.cart-page.hp-cart-fb > .cart-heading,
main.cart-page.hp-cart-fb > .cart-alert,
main.cart-page.hp-cart-fb > .cart-layout{visibility:visible;}

/* hide the storefront's own cart chrome — our table replaces it */
main.cart-page[data-hp-cart="1"] > .cart-breadcrumb,
main.cart-page[data-hp-cart="1"] > .cart-heading,
main.cart-page[data-hp-cart="1"] > .cart-alert,
main.cart-page[data-hp-cart="1"] > .cart-layout{display:none !important;}
main.cart-page[data-hp-cart="1"]{padding:0 !important;margin:0 !important;max-width:none !important;width:100% !important;background:#fff;}
main.cart-page.is-busy .hp-cart-grid{opacity:.55;pointer-events:none;transition:opacity .15s;}

.hp-cart{max-width:1425px;margin:0 auto;padding:0 20px 70px;box-sizing:border-box;font-family:'Montserrat',Arial,Helvetica,sans-serif;color:var(--ct-ink);}
.hp-cart *,.hp-cart *::before,.hp-cart *::after{box-sizing:border-box;}
.hp-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;}

/* ---------- checkout steps ---------- */
.hp-steps{display:flex;justify-content:center;align-items:center;gap:15px;list-style:none;margin:0 0 26px;padding:20px 0;background:#fff;}
.hp-steps li{font-size:22px;font-weight:600;line-height:1.3;text-transform:none;color:var(--ct-ink);white-space:nowrap;display:flex;align-items:center;gap:15px;}
.hp-steps li + li::before{content:"\203A";color:#c9c9c9;font-weight:400;font-size:24px;line-height:1;}
.hp-steps a{color:inherit;text-decoration:none;}
.hp-steps li.is-on a{color:var(--ct-ink);text-decoration:underline;text-decoration-color:var(--ct-blue);text-decoration-thickness:2px;text-underline-offset:5px;}
.hp-steps li:not(.is-on){color:#242424;}
.hp-steps a:hover{color:var(--ct-blue);}

/* ---------- notice ---------- */
.hp-cart-note{display:none;}
.hp-cart-note.is-on{display:block;background:#eaf6fc;border-left:4px solid var(--ct-blue);color:#153e57;font-size:14px;line-height:1.5;padding:14px 18px;margin:0 0 20px;}
.hp-cart-note.is-green{background:#459647;border-left-color:#3b813d;color:#fff;}

/* ---------- layout ---------- */
.hp-cart-grid{display:grid;grid-template-columns:minmax(0,1fr) 455px;gap:30px;align-items:start;}
.hp-cart-grid.is-empty{display:block;}

/* ---------- product table ---------- */
.hp-ct{width:100%;border-collapse:collapse;table-layout:fixed;}
.hp-ct col,
.hp-ct .hp-c-rm{width:40px;}
.hp-ct thead th{font-size:16px;font-weight:600;text-transform:uppercase;color:#000;text-align:left;padding:15px 10px;border-bottom:2px solid var(--ct-line);line-height:1.3;vertical-align:bottom;}
.hp-ct thead th.hp-c-rm{padding:15px 10px 15px 0;}
.hp-ct thead th.hp-c-sub{text-align:right;padding:15px 0 15px 10px;}
.hp-ct thead th.hp-c-name{width:31%;}
.hp-ct thead th.hp-c-thumb{width:104px;}
.hp-ct thead th.hp-c-price{width:164px;}
.hp-ct thead th.hp-c-qty{width:166px;}
.hp-ct thead th.hp-c-sub{width:153px;}

.hp-ct tbody td{padding:15px 12px;vertical-align:middle;border-bottom:1px solid var(--ct-line-soft);font-size:14px;color:var(--ct-ink);}
.hp-ct tbody td.hp-c-rm{padding:15px 0;text-align:center;border-bottom:1px solid var(--ct-line-soft);}
.hp-ct tbody td.hp-c-thumb{padding:15px 12px;}
.hp-ct tbody td.hp-c-sub{text-align:right;padding:15px 0 15px 12px;}
.hp-ct tbody tr:last-child td{border-bottom:0;}

.hp-item .hp-c-thumb img{width:80px;height:80px;object-fit:contain;display:block;background:#fff;}
.hp-item .hp-c-name a{font-size:14px;font-weight:500;color:var(--ct-ink);text-decoration:none;line-height:1.45;display:block;}
.hp-item .hp-c-name a:hover{color:var(--ct-blue);}
.hp-item-meta{display:block;font-size:12px;color:var(--ct-muted);margin-top:4px;letter-spacing:.02em;}
.hp-item .hp-c-price,.hp-item .hp-c-sub{font-size:14px;color:var(--ct-ink);}
.hp-item .hp-c-sub{font-weight:500;}

.hp-rm{width:30px;height:30px;line-height:1;border:0;background:transparent;color:#333;font-size:22px;cursor:pointer;padding:0;border-radius:0;}
.hp-rm:hover{color:#c0392b;}

/* quantity stepper */
.hp-q{display:inline-flex;align-items:stretch;height:42px;}
.hp-q button{width:25px;min-width:25px;height:42px;border:2px solid rgba(0,0,0,.1);background:#fff;color:#000;font-size:14px;line-height:1;cursor:pointer;padding:0;}
.hp-q button:hover{background:#f2f2f2;}
.hp-q input{width:32px;height:42px;border:0;border-top:2px solid rgba(0,0,0,.1);border-bottom:2px solid rgba(0,0,0,.1);text-align:center;font-size:14px;color:#000;background:#fff;padding:0;-moz-appearance:textfield;font-family:inherit;}
.hp-q input::-webkit-outer-spin-button,.hp-q input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0;}
.hp-q input:focus{outline:none;background:#fafafa;}

/* action row: coupon + update */
.hp-ct .hp-action-row td{border-bottom:0;padding:20px 0 0;}
.hp-cart-actions{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;}
.hp-coupon{display:flex;align-items:center;gap:10px;flex-wrap:wrap;}
.hp-coupon input{height:42px;width:230px;max-width:100%;border:2px solid rgba(0,0,0,.1);padding:0 15px;font-size:14px;color:#000;background:#fff;font-family:inherit;border-radius:0;}
.hp-coupon input::placeholder{color:#9a9a9a;}
.hp-coupon input:focus{outline:none;border-color:rgba(0,0,0,.28);}

.hp-btn-blue,.hp-btn-grey{display:inline-flex;align-items:center;justify-content:center;height:42px;padding:5px 20px;font-size:13px;font-weight:500;text-transform:uppercase;letter-spacing:.02em;border:0;border-radius:0;cursor:pointer;font-family:inherit;transition:background .16s;}
.hp-btn-blue{background:var(--ct-blue);color:#fff;}
.hp-btn-blue:hover{background:var(--ct-blue-dark);}
.hp-btn-grey{background:var(--ct-grey);color:#333;}
.hp-btn-grey:hover{background:#ececec;}

/* ---------- cart totals ---------- */
.hp-totals-in{border:3px solid var(--ct-line);padding:25px;}
.hp-totals h2{margin:0 0 12px;font-size:22px;font-weight:600;text-transform:uppercase;color:#000;line-height:1.3;letter-spacing:0;}
.hp-totals table{width:100%;border-collapse:collapse;}
.hp-totals th{width:104px;text-align:left;font-size:14px;font-weight:600;color:#000;vertical-align:top;padding:15px 0 15px 0;line-height:1.5;}
.hp-totals td{font-size:14px;color:#000;text-align:right;padding:15px 0 15px 12px;line-height:1.5;vertical-align:top;}

/* shipment picker — mirrors the store's own shipping plans */
.hp-totals .hp-ship-row td{text-align:left;}
.hp-ships{list-style:none;margin:0;padding:0;}
.hp-ships li{margin:0 0 9px;}
.hp-ships li:last-child{margin-bottom:0;}
.hp-ships label{display:flex;align-items:flex-start;gap:7px;font-size:14px;line-height:1.45;color:#000;cursor:pointer;}
.hp-ships input[type=radio]{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:15px;height:15px;flex:0 0 15px;margin:3px 0 0;border:1px solid #9a9a9a;border-radius:50%;background:#fff;box-sizing:border-box;padding:0;cursor:pointer;}
.hp-ships input[type=radio]:checked{border-color:#000;box-shadow:inset 0 0 0 3.5px #000;}
.hp-ships li.is-off input[type=radio]{border-color:#c9c9c9;}
.hp-ships .hp-ship-pfx{display:none;}
@media (min-width:401px){.hp-ships .hp-ship-pfx{display:inline;}}
.hp-ships .hp-ship-name{flex:1 1 auto;}
.hp-ships .hp-ship-fee{white-space:nowrap;}
@media (max-width:400px){.hp-ships .hp-ship-name{font-size:13px;} .hp-ships .hp-ship-fee{font-size:13px;}}
.hp-ships li.is-on .hp-ship-name{font-weight:600;}
.hp-ships li.is-off label,
.hp-ships li.is-off .hp-ship-fee{color:#9a9a9a;cursor:default;}
.hp-totals .hp-discount td{color:#2e7d32;}
.hp-totals .hp-total-row th,.hp-totals .hp-total-row td{border-top:1px solid var(--ct-line-soft);font-size:14px;color:#000;}
.hp-totals .hp-total-row strong{font-size:17px;font-weight:700;}
.hp-checkout{display:block;width:100%;margin-top:22px;height:42px;background:var(--ct-blue);color:#fff;border:0;border-radius:0;font-size:13px;font-weight:600;text-transform:uppercase;letter-spacing:.03em;cursor:pointer;font-family:inherit;}
.hp-checkout:hover{background:var(--ct-blue-dark);}

/* ---------- empty ---------- */
.hp-cart-empty{padding:60px 0 70px;text-align:center;}
.hp-cart-empty p{font-size:16px;color:var(--ct-ink);margin:0 0 22px;}
.hp-cart-empty .hp-btn-blue{padding:0 28px;}

/* ---------- responsive ---------- */
@media (max-width:1200px){
  .hp-cart-grid{grid-template-columns:minmax(0,1fr) 380px;gap:24px;}
  .hp-ct thead th.hp-c-price{width:130px;}
  .hp-ct thead th.hp-c-qty{width:140px;}
  .hp-ct thead th.hp-c-sub{width:130px;}
}
@media (max-width:980px){
  .hp-cart{max-width:none;padding:0 12px 50px;}
  .hp-steps{gap:10px;margin:0 0 18px;padding:16px 12px;}
  .hp-steps li{font-size:16px;gap:10px;}
  .hp-steps li + li::before{font-size:18px;}
  .hp-cart-grid{grid-template-columns:1fr;gap:22px;}
  .hp-cart-note{margin:0 12px 16px;}

  /* table -> stacked cards */
  .hp-ct{display:block;table-layout:auto;}
  .hp-ct thead{display:none;}
  .hp-ct tbody,.hp-ct tr,.hp-ct td{display:block;}
  .hp-ct .hp-item{position:relative;display:grid;grid-template-columns:96px minmax(0,1fr);grid-template-rows:auto auto auto auto;column-gap:14px;padding:16px 12px;border-bottom:1px solid var(--ct-line-soft);}
  .hp-ct tbody td{padding:0;border-bottom:0;}
  .hp-item .hp-c-rm{position:absolute;top:10px;right:8px;width:30px;padding:0;z-index:2;}
  .hp-item .hp-c-thumb{grid-column:1;grid-row:1 / span 4;padding:0;}
  .hp-item .hp-c-thumb img{width:96px;height:96px;}
  .hp-item .hp-c-name,.hp-item .hp-c-price,.hp-item .hp-c-qty,.hp-item .hp-c-sub{grid-column:2;text-align:left;}
  .hp-item .hp-c-name{padding-right:34px;margin-bottom:6px;}
  .hp-item .hp-c-name a{font-size:14px;}
  .hp-item .hp-c-price{display:flex;align-items:baseline;gap:8px;margin-bottom:6px;font-size:14px;}
  .hp-item .hp-c-price::before{content:attr(data-label);font-size:12px;color:var(--ct-muted);text-transform:uppercase;letter-spacing:.04em;min-width:66px;}
  .hp-item .hp-c-qty{display:flex;align-items:center;gap:10px;margin-bottom:6px;}
  .hp-item .hp-c-qty::before{content:attr(data-label);font-size:12px;color:var(--ct-muted);text-transform:uppercase;letter-spacing:.04em;min-width:66px;}
  .hp-item .hp-q{height:36px;}
  .hp-item .hp-q button{width:24px;min-width:24px;height:36px;}
  .hp-item .hp-q input{width:30px;height:36px;}
  .hp-item .hp-c-sub{display:flex;align-items:baseline;gap:8px;font-weight:600;}
  .hp-item .hp-c-sub::before{content:attr(data-label);font-size:12px;font-weight:400;color:var(--ct-muted);text-transform:uppercase;letter-spacing:.04em;min-width:66px;}
  .hp-ct .hp-action-row{display:block;padding:0 12px;}
  .hp-ct .hp-action-row td{padding:18px 0 0;display:block;}
  .hp-cart-actions{flex-direction:column;align-items:stretch;gap:12px;}
  .hp-coupon{flex-direction:column;align-items:stretch;gap:10px;}
  .hp-coupon input{width:100%;}
  .hp-coupon .hp-btn-blue{width:100%;}
  .hp-cart-actions .hp-btn-grey{width:100%;}
  .hp-totals-in{padding:20px;border-width:3px;}
  .hp-totals h2{font-size:20px;}
}
@media (max-width:480px){
  .hp-cart{padding:0 15px 54px;}

  /* steps — reference site keeps them centred and compact */
  .hp-steps{gap:8px;padding:13px 0;justify-content:center;flex-wrap:nowrap;}
  .hp-steps li{font-size:12.5px;gap:8px;letter-spacing:0;font-weight:600;}
  .hp-steps li + li::before{font-size:15px;}

  /* product row — 100px thumb, info stacked on the right, × pinned top-right */
  .hp-ct .hp-item{grid-template-columns:100px minmax(0,1fr);column-gap:15px;padding:14px 0;}
  .hp-item .hp-c-thumb img{width:100px;height:100px;}
  .hp-item .hp-c-rm{top:8px;right:0;width:28px;padding:0;}
  .hp-rm{font-size:24px;line-height:1;}
  .hp-item .hp-c-name{padding-right:30px;margin-bottom:5px;}
  .hp-item .hp-c-name a{font-size:14px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
  .hp-item-meta{font-size:11px;line-height:1.4;margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;}
  .hp-item .hp-c-price{margin-bottom:5px;}
  .hp-item .hp-c-price::before,
  .hp-item .hp-c-qty::before,
  .hp-item .hp-c-sub::before{font-size:14px;color:#000;text-transform:none;letter-spacing:0;min-width:0;font-weight:400;}
  .hp-item .hp-c-price,
  .hp-item .hp-c-qty,
  .hp-item .hp-c-sub{justify-content:space-between;width:100%;}
  .hp-item .hp-c-qty{margin-bottom:5px;}
  .hp-item .hp-q{height:30px;}
  .hp-item .hp-q button{width:25px;min-width:25px;height:30px;font-size:13px;}
  .hp-item .hp-q input{width:30px;height:30px;font-size:14px;}
  .hp-item .hp-c-sub{font-weight:400;}

  /* actions — Update cart sits above the coupon row, like the reference */
  .hp-ct .hp-action-row{padding:0;}
  .hp-cart-actions{flex-direction:column-reverse;gap:16px;}
  .hp-coupon{flex-direction:column;align-items:stretch;gap:12px;}
  .hp-coupon input{height:42px;}
  .hp-coupon .hp-btn-blue{width:100%;}

  /* totals */
  .hp-totals-in{padding:25px 28px;}
  .hp-totals h2{font-size:22px;margin-bottom:10px;}
  .hp-totals table,.hp-totals tbody{display:block;width:100%;}
  .hp-totals tr{display:flex;align-items:baseline;justify-content:space-between;}
  .hp-totals th,.hp-totals td{display:block;width:auto;padding:15px 0;}
  /* shipment block: label on its own line, plans stacked underneath */
  .hp-totals tr.hp-ship-row{display:block;}
  .hp-totals tr.hp-ship-row th{padding:15px 0 6px;text-align:left;}
  .hp-totals tr.hp-ship-row td{padding:0 0 15px;text-align:left;}
  .hp-ships label{justify-content:space-between;}
  .hp-ships .hp-ship-name{flex:1 1 auto;padding-right:12px;}
  .hp-checkout{height:42px;}
}
@media (max-width:360px){
  .hp-steps li{font-size:11px;gap:5px;}
  .hp-steps li + li::before{font-size:12px;}
  .hp-cart{padding:0 12px 48px;}
  .hp-ct .hp-item{grid-template-columns:92px minmax(0,1fr);column-gap:12px;}
  .hp-item .hp-c-thumb img{width:92px;height:92px;}
  .hp-totals-in{padding:20px;}
}

/* mobile: no 3-step trail — a single centered "Shopping cart" title */
@media (max-width:980px){
  .hp-steps{gap:0;justify-content:center;margin:0 0 18px;padding:16px 12px 4px;}
  .hp-steps li{display:none;font-size:17px;gap:0;letter-spacing:0;}
  .hp-steps li.is-on{display:flex;justify-content:center;}
  .hp-steps li.is-on a{text-decoration:none;}
}
