/* PayPal "View Cart" button - floating in the bottom-right corner on every page */
.pp-cart-float {
	position: fixed;
	right: 24px;
	bottom: 24px;
	z-index: 9999;
	padding: 6px;
	background: #fff;
	border-radius: 6px;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

@media print {
	.pp-cart-float {
		display: none;
	}
}

/*
 * PayPal "Add to Cart" buttons: the product name and price PayPal prints
 * are restyled to match the site's product box (font, size, colour of
 * .product .label / .product .value), centred above the button.
 * PayPal styles these with id selectors, hence !important.
 */
paypal-add-to-cart-button .item-header {
	display: block !important;
	text-align: center !important;
	margin: 0 0 14px !important;
	font-weight: normal !important;
	color: inherit !important;
}

/* product name: like the "SIZE:" / "PRICE $:" labels */
paypal-add-to-cart-button .item-header .item-title {
	display: block !important;
	max-width: none !important;
	margin-bottom: 6px;
	font-family: "Humanist970", "Trebuchet MS", verdana, sans-serif !important;
	font-size: 11px !important;
	font-weight: normal !important;
	letter-spacing: 0.5px !important;
	text-transform: uppercase !important;
	color: inherit !important;
}

/* price: like the "4 oz" / "300.00" values */
paypal-add-to-cart-button .item-header .price-container {
	display: block !important;
	max-width: none !important;
	text-align: center !important;
}

paypal-add-to-cart-button .item-header #price-label {
	justify-content: center !important;
}

paypal-add-to-cart-button .item-header #price-label h3 {
	margin: 0 !important;
	font-family: "Humanist521-Light", Verdana, Arial, Helvetica, sans-serif !important;
	font-size: 14px !important;
	font-weight: bold !important;
	letter-spacing: 1px !important;
	color: inherit !important;
}

/* Add to Cart button: content width (like the site's old button), centred */
paypal-add-to-cart-button [aria-live] {
	text-align: center !important;
}

paypal-add-to-cart-button .addToCartButtonContainer {
	display: inline-flex !important;
	width: auto !important;
	min-width: 0 !important;
	margin: 0 auto !important;
	padding-left: 25px !important;
	padding-right: 25px !important;
}

/* product photo PayPal adds to the button: the page already shows the product image */
paypal-add-to-cart-button .hero-container {
	display: none !important;
}

/* wrapper around each Add to Cart button: full width, so the button
   is not squeezed inside flex columns (e.g. the .photo column of product lists) */
.pp-add-to-cart {
	width: 100%;
	text-align: center;
}

paypal-add-to-cart-button {
	display: block;
	width: 100%;
}

/* Quantity selector (products with quantity enabled in PayPal):
   label like the site's labels, compact centred dropdown */
paypal-add-to-cart-button .input-label {
	display: block !important;
	margin: 0 0 4px !important;
	text-align: center !important;
	font-family: "Humanist970", "Trebuchet MS", verdana, sans-serif !important;
	font-size: 11px !important;
	letter-spacing: 0.5px !important;
	text-transform: uppercase !important;
	color: inherit !important;
}

paypal-add-to-cart-button .selectContainer {
	width: 90px !important;
	max-width: 90px !important;
	margin: 0 auto 12px !important;
}

paypal-add-to-cart-button .selectContainer select {
	width: 100% !important;
	height: 32px !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 26px 0 10px !important;
	line-height: 30px !important;
	font-family: "Humanist521-Light", Verdana, Arial, Helvetica, sans-serif !important;
	font-size: 14px !important;
	font-weight: bold !important;
	letter-spacing: 1px !important;
	color: #6e7073 !important;
	background-color: #fff !important;
}

/* PayPal's dropdown arrow, re-centred for the smaller box */
paypal-add-to-cart-button .selectContainer::after {
	top: 10px !important;
	right: 10px !important;
	width: 6px !important;
	height: 6px !important;
}

/* Two Add to Cart buttons stacked (e.g. 15 ml and 30 ml of the same product):
   drop PayPal's 32px bottom margin and the old <br> between them,
   keep a small gap instead */
.pp-add-to-cart + br:has(+ .pp-add-to-cart) {
	display: none;
}

.pp-add-to-cart:has(+ .pp-add-to-cart) paypal-add-to-cart-button > div,
.pp-add-to-cart:has(+ br + .pp-add-to-cart) paypal-add-to-cart-button > div {
	margin-bottom: 0 !important;
}

.pp-add-to-cart + .pp-add-to-cart,
.pp-add-to-cart + br + .pp-add-to-cart {
	margin-top: 8px; /* + PayPal's own 16px = 24px between the button and the next size */
}

/* ...and the empty photo-carousel slot PayPal keeps above the 2nd button's title */
.pp-add-to-cart + .pp-add-to-cart [id^="carousel-container-"],
.pp-add-to-cart + br + .pp-add-to-cart [id^="carousel-container-"] {
	display: none !important;
}

/* Narrow columns (e.g. the old article sidebars): keep "Add to Cart" on one line */
.pp-add-to-cart {
	container-type: inline-size;
}

paypal-add-to-cart-button .addToCartButtonContainer {
	white-space: nowrap !important;
}

@container (max-width: 180px) {
	paypal-add-to-cart-button .addToCartButtonContainer {
		padding-left: 12px !important;
		padding-right: 12px !important;
	}
}

/* PayPal subscription button (Phytoplankton Co-op): compact and centred */
.pp-subscribe {
	max-width: 220px;
	margin: 16px auto 0; /* space between the price text above and the button */
}

/* narrow columns (e.g. Co-op column): never wider than the column */
.pp-subscribe {
	width: 100%;
	box-sizing: border-box;
}

/* the photo slot PayPal keeps above every button is always empty (we hide
   PayPal's product photo), so drop it everywhere, not only when stacked */
paypal-add-to-cart-button [id^="carousel-container-"] {
	display: none !important;
}

/* PayPal's subscribe buttons are at least 150px wide; in narrower columns
   (the Co-op column) scale them down a little so they stay inside the box */
.pp-subscribe {
	container-type: inline-size;
}

@container (max-width: 165px) {
	.pp-subscribe > [id^="paypal-button-container-"] {
		zoom: 0.88;
	}
}

/* Co-op subscription moved under the Retail buttons in product lists */
.pp-coop {
	width: 100%;
	margin-top: 24px;
	text-align: center;
}

.pp-coop .row {
	justify-content: center;
}

/* product description set in PayPal (e.g. "This formulation contains NO
   XYLITOL..."): same look as the site's small product text */
paypal-add-to-cart-button .item-description {
	margin: -6px auto 14px !important;
	max-width: 260px;
	text-align: center !important;
	font-family: "Humanist521-Light", Verdana, Arial, Helvetica, sans-serif !important;
	font-size: 14px !important;
	font-weight: normal !important;
	line-height: 1.4 !important;
	letter-spacing: 0.5px !important;
	color: #6e7073 !important;
}
