/* Phantom Shop: slide-out cart (+ timer, ship-today and switch styles shared with checkout). */

.ps-cart,
.ps-co-page,
body:has(.ps-co-page) {
	--pc-font: "Spartan MB", "Segoe UI", system-ui, -apple-system, sans-serif;
	--pc-ink: #0b0c0e;
	--pc-text: #334155;
	--pc-muted: #64748b;
	--pc-line: #e3e8ef;
	--pc-soft: #f5f8fc;
	--pc-blue: #2d6fb7;
	--pc-blue-dark: #1d5797;
	--pc-blue-soft: #edf4fc;
	--pc-blue-line: #cfe0f3;
	--pc-navy: #08234a;
	--pc-green: #15803d;
	--pc-green-soft: #ebf7f0;
	--pc-green-line: #bfe5cd;
	--pc-red: #c2410c;
	--pc-radius: 14px;
}

/* The old side cart stays in the page but never shows, even when its own script opens it
   (its open state is styled more strongly than a plain id, hence the long selectors). */
html body #dsg-side-cart,
html body #dsg-side-cart.is-open,
html body #dsg-cart-overlay,
html body #dsg-cart-overlay.is-open { display: none !important; visibility: hidden !important; opacity: 0 !important; pointer-events: none !important; transform: translateX(110%) !important; }

html.ps-cart-lock,
html.ps-cart-lock body { overflow: hidden !important; }

.ps-cart { position: fixed; inset: 0; z-index: 1000000; visibility: hidden; pointer-events: none; font-family: var(--pc-font); -webkit-font-smoothing: antialiased; font-variant-ligatures: no-common-ligatures; }
.ps-cart *, .ps-cart *::before, .ps-cart *::after { box-sizing: border-box; }
.ps-cart.is-open { visibility: visible; pointer-events: auto; }
.ps-cart__overlay { position: absolute; inset: 0; background: rgba(8, 24, 48, .45); opacity: 0; transition: opacity .3s; -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); }
.ps-cart.is-open .ps-cart__overlay { opacity: 1; }

.ps-cart__panel {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	display: flex;
	flex-direction: column;
	width: min(440px, 100vw);
	background: #fff;
	color: var(--pc-text);
	box-shadow: -24px 0 60px -20px rgba(8, 35, 74, .35);
	transform: translateX(104%);
	transition: transform .38s cubic-bezier(.2, .8, .2, 1);
	outline: 0;
	font-size: 14px;
	line-height: 1.45;
}
.ps-cart.is-open .ps-cart__panel { transform: none; }
@media (prefers-reduced-motion: reduce) { .ps-cart__panel, .ps-cart__overlay { transition: none; } }

.ps-cart button { font-family: inherit; }
.ps-cart .ps-icon { width: 18px; height: 18px; flex: none; }

.ps-cart__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px 14px; }
.ps-cart__head h2 { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--pc-ink); font: 700 22px/1.2 var(--pc-font); letter-spacing: -.01em; text-transform: none; }
.ps-cart__count { display: inline-grid; place-items: center; min-width: 26px; height: 26px; padding: 0 8px; border-radius: 999px; background: var(--pc-blue); color: #fff; font-size: 13px; font-weight: 700; }
.ps-cart__count:empty { display: none; }
.ps-cart__close { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 1px solid var(--pc-line); border-radius: 50%; background: #fff; color: var(--pc-ink); cursor: pointer; transition: background .2s, border-color .2s; }
.ps-cart__close:hover { border-color: var(--pc-blue); color: var(--pc-blue); background: var(--pc-blue-soft); }

.ps-cart__body { position: relative; display: flex; flex: 1; flex-direction: column; min-height: 0; }
.ps-cart.is-busy .ps-cart__body::after { content: ""; position: absolute; inset: 0; z-index: 3; background: rgba(255, 255, 255, .45); cursor: progress; }
.ps-cart__loading { display: grid; flex: 1; place-items: center; }
.ps-cart__loading span,
.ps-cart.is-busy .ps-cart__head h2::after { content: ""; width: 26px; height: 26px; border: 3px solid var(--pc-blue-line); border-top-color: var(--pc-blue); border-radius: 50%; animation: ps-spin .8s linear infinite; }
.ps-cart.is-busy .ps-cart__head h2::after { width: 16px; height: 16px; border-width: 2px; }
@keyframes ps-spin { to { transform: rotate(360deg); } }

/* Free shipping bar */
.ps-cart__top { padding: 0 20px 12px; }
.ps-cart__ship { padding: 12px 14px 14px; border: 1px solid var(--pc-blue-line); border-radius: 12px; background: var(--pc-blue-soft); }
.ps-cart__ship p { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; color: var(--pc-ink); font-size: 14px; }
.ps-cart__ship p .ps-icon { color: var(--pc-blue); }
.ps-cart__ship strong { color: var(--pc-blue-dark); }
.ps-cart__bar { display: block; height: 6px; overflow: hidden; border-radius: 999px; background: #d9e6f5; }
.ps-cart__bar > span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #4f8fd3, var(--pc-blue)); transition: width .5s ease; }
.ps-cart__ship.is-done { border-color: var(--pc-green-line); background: var(--pc-green-soft); }
.ps-cart__ship.is-done p .ps-icon, .ps-cart__ship.is-done strong { color: var(--pc-green); }
.ps-cart__ship.is-done .ps-cart__bar > span { background: var(--pc-green); }

/* Middle */
.ps-cart__scroll { flex: 1; min-height: 120px; padding: 4px 20px 16px; overflow-y: auto; overscroll-behavior: contain; }
.ps-cart__note { margin: 0 0 10px; padding: 9px 12px; border-radius: 10px; background: #fff4ed; color: var(--pc-red); font-size: 13px; font-weight: 600; }
.ps-cart__note.is-ok { background: var(--pc-green-soft); color: var(--pc-green); }

.ps-cart__items { margin: 0; padding: 0; list-style: none; border: 1px solid var(--pc-line); border-radius: var(--pc-radius); background: #fff; }
.ps-cart__item { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: start; padding: 14px; transition: opacity .2s; }
.ps-cart__item + .ps-cart__item { border-top: 1px solid var(--pc-line); }
.ps-cart__item.is-removing { opacity: .4; }
.ps-cart__thumb { display: block; width: 64px; height: 64px; overflow: hidden; border: 1px solid var(--pc-line); border-radius: 10px; background: var(--pc-soft); }
.ps-cart__thumb img { display: block; width: 100%; height: 100%; object-fit: contain; }
.ps-cart__thumb--sm { width: 48px; height: 48px; }
.ps-cart__info { min-width: 0; }
.ps-cart__name { display: block; margin-bottom: 8px; color: var(--pc-blue); font-size: 15px; font-weight: 700; line-height: 1.3; text-decoration: none; }
a.ps-cart__name:hover { color: var(--pc-blue-dark); text-decoration: underline; }
.ps-cart__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ps-cart__chip { padding: 3px 9px; border-radius: 6px; background: var(--pc-blue-soft); color: var(--pc-blue-dark); font-size: 12px; font-weight: 600; }
.ps-cart__qty { display: inline-flex; align-items: center; height: 28px; border: 1px solid var(--pc-line); border-radius: 999px; }
.ps-cart__qty button { display: grid; place-items: center; width: 28px; height: 26px; padding: 0; border: 0; border-radius: 999px; background: none; color: var(--pc-muted); cursor: pointer; }
.ps-cart__qty button:hover:not([disabled]) { color: var(--pc-blue); background: var(--pc-blue-soft); }
.ps-cart__qty button[disabled] { opacity: .35; cursor: not-allowed; }
.ps-cart__qty .ps-icon { width: 13px; height: 13px; }
.ps-cart__qty span { min-width: 22px; color: var(--pc-ink); font-size: 13px; font-weight: 700; text-align: center; }
.ps-cart__right { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.ps-cart__remove { display: grid; place-items: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 50%; background: none; color: #94a3b8; cursor: pointer; }
.ps-cart__remove:hover { background: #fdecec; color: #dc2626; }
.ps-cart__remove .ps-icon { width: 14px; height: 14px; }
.ps-cart__price { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.25; }
.ps-cart__price strong { color: var(--pc-ink); font-size: 16px; font-weight: 700; }
.ps-cart__price del { color: #94a3b8; font-size: 12px; }

.ps-cart__empty { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 64px 10px; color: var(--pc-muted); text-align: center; }
.ps-cart__empty .ps-icon { width: 44px; height: 44px; color: var(--pc-blue-line); }
.ps-cart__empty p { margin: 0; color: var(--pc-ink); font-size: 16px; font-weight: 600; }
.ps-cart__shop { margin-top: 6px; padding: 12px 26px; border-radius: 999px; background: var(--pc-blue); color: #fff !important; font-weight: 700; text-decoration: none; }

/* Complete your kit */
.ps-cart__kit { margin-top: 18px; }
.ps-cart__kit h3 { display: flex; align-items: center; gap: 12px; margin: 0 0 10px; color: var(--pc-blue); font: 700 11px/1 var(--pc-font); letter-spacing: .16em; text-transform: uppercase; }
.ps-cart__kit h3::before, .ps-cart__kit h3::after { content: ""; flex: 1; height: 1px; background: var(--pc-line); }
.ps-cart__kit-card { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--pc-line); border-radius: var(--pc-radius); }
.ps-cart__kit-info { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.ps-cart__kit-info strong { color: var(--pc-ink); font-size: 14px; }
.ps-cart__kit-info span { overflow: hidden; color: var(--pc-muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.ps-cart__kit-add { flex: none; padding: 9px 14px; border: 0; border-radius: 999px; background: var(--pc-blue); color: #fff; font-size: 13px; font-weight: 700; cursor: pointer; white-space: nowrap; transition: background .2s; }
.ps-cart__kit-add:hover { background: var(--pc-blue-dark); }
.ps-cart__kit-add .woocommerce-Price-amount { color: inherit; }

/* Package Protection */
.ps-cart__protect { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 14px; border: 1px solid var(--pc-line); border-radius: var(--pc-radius); background: #fff; transition: background .2s, border-color .2s; }
.ps-cart__protect.is-on { border-color: var(--pc-green-line); background: var(--pc-green-soft); }
.ps-cart__protect-icon { display: grid; flex: none; place-items: center; width: 38px; height: 38px; border: 1px solid var(--pc-line); border-radius: 10px; background: #fff; color: var(--pc-blue); }
.ps-cart__protect.is-on .ps-cart__protect-icon { color: var(--pc-green); border-color: var(--pc-green-line); }
.ps-cart__protect-text { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.ps-cart__protect-text strong { color: var(--pc-ink); font-size: 14px; }
.ps-cart__protect-text span { color: var(--pc-muted); font-size: 12px; }
.ps-cart__protect-price { color: var(--pc-ink); font-size: 14px; font-weight: 700; }
.ps-cart__protect.is-on .ps-cart__protect-price { color: var(--pc-green); }

.ps-switch { position: relative; flex: none; width: 44px; height: 26px; padding: 0; border: 0; border-radius: 999px; background: #cbd5e1; cursor: pointer; transition: background .2s; }
.ps-switch span { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s; }
.ps-switch[aria-checked="true"] { background: var(--pc-blue); }
.ps-cart__protect.is-on .ps-switch[aria-checked="true"] { background: var(--pc-green); }
.ps-switch[aria-checked="true"] span { transform: translateX(18px); }
.ps-switch:focus-visible { outline: 2px solid var(--pc-blue); outline-offset: 2px; }

/* Discount code */
.ps-cart__coupon { margin-top: 14px; border-top: 1px solid var(--pc-line); }
.ps-cart__coupon summary { display: flex; align-items: center; gap: 10px; padding: 14px 2px; color: var(--pc-ink); font-size: 14px; font-weight: 600; list-style: none; cursor: pointer; }
.ps-cart__coupon summary::-webkit-details-marker { display: none; }
.ps-cart__coupon summary span { flex: 1; }
.ps-cart__coupon summary .ps-icon { color: var(--pc-muted); }
.ps-cart__coupon summary .ps-icon--down { width: 16px; height: 16px; transition: transform .2s; }
.ps-cart__coupon[open] summary .ps-icon--down { transform: rotate(180deg); }
.ps-cart__coupon-row { display: flex; gap: 8px; }
.ps-cart__coupon-row input { flex: 1; min-width: 0; height: 44px; margin: 0; padding: 0 14px; border: 1px solid var(--pc-line); border-radius: 10px; background: #fff; color: var(--pc-ink); font: 500 14px var(--pc-font); text-transform: uppercase; box-shadow: none; }
.ps-cart__coupon-row input::placeholder { text-transform: none; color: #94a3b8; }
.ps-cart__coupon-row input:focus { border-color: var(--pc-blue); outline: 0; box-shadow: 0 0 0 3px var(--pc-blue-soft); }
.ps-cart__coupon-row button { height: 44px; padding: 0 18px; border: 1px solid var(--pc-blue); border-radius: 10px; background: #fff; color: var(--pc-blue); font-size: 14px; font-weight: 700; cursor: pointer; }
.ps-cart__coupon-row button:hover { background: var(--pc-blue); color: #fff; }
.ps-cart__coupons { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 2px; padding: 0; list-style: none; }
.ps-cart__coupons li { display: inline-flex; align-items: center; gap: 6px; padding: 5px 6px 5px 10px; border-radius: 8px; background: var(--pc-green-soft); color: var(--pc-green); font-size: 12px; font-weight: 700; }
.ps-cart__coupons .ps-icon { width: 14px; height: 14px; }
.ps-cart__coupons button { display: grid; place-items: center; width: 20px; height: 20px; padding: 0; border: 0; border-radius: 50%; background: none; color: inherit; cursor: pointer; }
.ps-cart__coupons button:hover { background: rgba(21, 128, 61, .14); }
.ps-cart__coupons button .ps-icon { width: 12px; height: 12px; }

/* Footer */
.ps-cart__foot { padding: 14px 20px 16px; border-top: 1px solid var(--pc-line); background: #fff; box-shadow: 0 -10px 24px -18px rgba(8, 35, 74, .3); }
.ps-cart__saved { margin: 0 0 6px; color: var(--pc-blue); font-size: 14px; font-weight: 600; }
.ps-cart__saved strong { color: var(--pc-blue-dark); }
.ps-cart__row,
.ps-cart__total { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 0; }
.ps-cart__row { color: var(--pc-muted); font-size: 13px; }
.ps-cart__free { color: var(--pc-green); }
.ps-cart__total { margin: 8px 0 12px; padding-top: 10px; border-top: 1px solid var(--pc-line); color: var(--pc-ink); font-size: 16px; font-weight: 700; }
.ps-cart__total strong { color: var(--pc-blue); font-size: 24px; letter-spacing: -.01em; }

.ps-hold { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 0 10px; padding: 10px 12px; border: 1px solid var(--pc-blue-line); border-radius: 10px; background: var(--pc-blue-soft); color: var(--pc-blue-dark); font-size: 13px; font-weight: 600; text-align: center; }
.ps-hold[hidden] { display: none; }
.ps-hold .ps-icon { width: 16px; height: 16px; }
.ps-hold strong { font-variant-numeric: tabular-nums; }
.ps-shipinfo { margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: var(--pc-soft); list-style: none; }
.ps-shipinfo li { display: flex; align-items: center; gap: 8px; margin: 0; padding: 2px 0; color: var(--pc-text); font-size: 13px; }
.ps-shipinfo li[hidden] { display: none; }
.ps-shipinfo .ps-icon { width: 15px; height: 15px; color: var(--pc-blue); }
.ps-shipinfo strong { color: var(--pc-blue-dark); }

.ps-cart__checkout { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 56px; padding: 14px 20px; border-radius: 999px; background: linear-gradient(180deg, #3a7dc6, var(--pc-blue) 55%, var(--pc-blue-dark)); color: #fff !important; font-size: 17px; font-weight: 700; text-decoration: none !important; box-shadow: 0 12px 24px -12px rgba(29, 87, 151, .7); transition: transform .15s, box-shadow .2s; }
.ps-cart__checkout:hover { transform: translateY(-1px); box-shadow: 0 16px 28px -12px rgba(29, 87, 151, .75); }
.ps-cart__checkout .woocommerce-Price-amount { color: inherit; }
.ps-cards { display: flex; justify-content: center; gap: 6px; margin: 12px 0 4px; }
.ps-cards img { width: auto; height: 22px; border-radius: 4px; }
.ps-cart__continue { display: block; margin: 6px auto 0; padding: 6px 10px; border: 0; background: none; color: var(--pc-muted); font-size: 13px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ps-cart__continue:hover { color: var(--pc-blue); }

@media (max-width: 480px) {
	.ps-cart__head { padding: 14px 16px 10px; }
	.ps-cart__top, .ps-cart__scroll, .ps-cart__foot { padding-left: 16px; padding-right: 16px; }
	.ps-cart__item { grid-template-columns: 56px 1fr auto; gap: 12px; padding: 12px; }
	.ps-cart__thumb { width: 56px; height: 56px; }
}
/* Short screens: let the whole panel scroll instead of squeezing the list. */
@media (max-height: 680px) {
	.ps-cart__body { overflow-y: auto; }
	.ps-cart__scroll { flex: none; overflow: visible; }
}

/* WooCommerce adds a "View cart" link after Add to cart buttons; the drawer opens instead. */
.ps-buy .added_to_cart,
.ps-card .added_to_cart,
.ps-shop .added_to_cart { display: none !important; }
