/* Prints Site Features. Colours, spacing and type sizes come from the Bricks variables. */

/* ---------- Image entrance: fade in and rise a little ----------
   Add the Bricks class "reveal" to any image. The image waits invisible. When it
   is loaded and in view, the script adds "is-revealed" and the animation runs once.
   Only opacity and transform change, so it stays smooth with many images. */
.ps-js .reveal:not(.is-revealed) {
	opacity: 0;
}

.ps-js .reveal.is-revealed {
	animation: ps-rise 1s cubic-bezier(0.16, 1, 0.3, 1) var(--ps-delay, 0ms) backwards;
}

@keyframes ps-rise {
	from {
		opacity: 0;
		transform: translateY(2.8rem);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

/* An image that is the landing spot of a page transition shows at once. */
.ps-js .reveal.is-revealed.ps-no-entrance {
	animation: none;
}

@media (prefers-reduced-motion: reduce) {
	.ps-js .reveal:not(.is-revealed) {
		opacity: 1;
	}

	.ps-js .reveal.is-revealed {
		animation: none;
	}
}

/* ---------- Print preview ---------- */
.ps-preview {
	--f: 0;
	--ps-paper-color: #fcfbf8;
	/* The frame is made for the paper size, so its outer size is the paper plus the frame.
	   A mount sits inside the frame: it does not make the frame larger, the picture gets smaller. */
	--tw: calc(var(--ps-w) + 2 * var(--f));
	--th: calc(var(--ps-h) + 2 * var(--f));
	--wall-w: 300;
	--wall-h: 220;
	--ps-frame-color: transparent;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-m, 1.6rem);
	width: 100%;
}

.ps-preview[data-finish="black"],
.ps-preview[data-finish="white"],
.ps-preview[data-finish="oak"] {
	--f: var(--ps-frame);
}

.ps-preview[data-mount="white"] { --ps-mount-color: #fff; }
.ps-preview[data-mount="offwhite"] { --ps-mount-color: #f1ede4; }
.ps-preview[data-mount="black"] { --ps-mount-color: #151515; }

/* The cut edge of the mount window shows the inside of the board. */
.ps-preview[data-mount="white"] { --ps-bevel-color: #e9e8e3; }
.ps-preview[data-mount="offwhite"] { --ps-bevel-color: #fbfaf6; }
.ps-preview[data-mount="black"] { --ps-bevel-color: #2c2c2c; }

.ps-preview[data-finish="black"] { --ps-frame-color: #171717; }
.ps-preview[data-finish="white"] { --ps-frame-color: #f6f6f3; }
.ps-preview[data-finish="oak"] { --ps-frame-color: #c7a779; }

.ps-preview__stage {
	position: relative;
	display: grid;
	place-items: center;
	width: 100%;
	min-height: var(--ps-max-h, 70vh);
	transition: opacity 0.18s ease;
}

/* Short fade while the stage switches between the close view and the wall view. */
.ps-preview__stage.is-switching {
	opacity: 0;
}

.ps-preview__object {
	container-type: inline-size; /* lets the mount edge be drawn to scale */
	width: min(100%, calc(var(--ps-max-h, 70vh) * var(--tw) / var(--th)));
	aspect-ratio: var(--tw) / var(--th);
	box-shadow: 0 3rem 5rem -2.4rem rgba(0, 0, 0, 0.32), 0 0.6rem 1.4rem -0.6rem rgba(0, 0, 0, 0.2);
}

.ps-preview__frame {
	box-sizing: border-box;
	width: 100%;
	height: 100%;
	padding: calc(var(--f) / var(--tw) * 100%);
	background-color: var(--ps-frame-color);
	background-image: linear-gradient(135deg, rgba(255, 255, 255, 0.14), rgba(0, 0, 0, 0.08));
	transition: padding 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease;
}

.ps-preview__stage.is-switching .ps-preview__frame {
	transition: none;
}

@media (prefers-reduced-motion: reduce) {
	.ps-preview__stage,
	.ps-preview__frame {
		transition: none;
	}
}

.ps-preview[data-finish="white"] .ps-preview__frame {
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.1);
}

.ps-preview__mount {
	position: relative;
	box-sizing: border-box;
	width: 100%;
	height: 100%;
	/* The white border of the print: "--ps-by" cm at top and bottom, "--ps-bx" cm at the
	   sides (set by the script). A mount covers this border, so it is drawn in the mount
	   colour then. The picture keeps its shape and the paper keeps its size. */
	padding: calc(var(--ps-by, 0) / var(--ps-w) * 100%) calc(var(--ps-bx, 0) / var(--ps-w) * 100%);
	background: var(--ps-mount-color, var(--ps-paper-color));
	transition: padding 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease;
}

.ps-preview__stage.is-switching .ps-preview__mount {
	transition: none;
}

/* The cut edge of the mount window: the board is 1.4 mm thick and cut at 45 degrees,
   so a thin edge of the same width shows around the photograph. */
.ps-preview:not([data-finish="print"]):not([data-mount="none"]) .ps-preview__image {
	box-shadow: 0 0 0 max(1px, calc(0.14 / var(--tw) * 100cqw)) var(--ps-bevel-color, #e9e8e3);
}

/* A thin shadow line where the frame meets the print. */
.ps-preview:not([data-finish="print"]) .ps-preview__mount::after {
	content: "";
	position: absolute;
	inset: 0;
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.18), inset 0 0.4rem 0.8rem -0.2rem rgba(0, 0, 0, 0.3);
	pointer-events: none;
}

.ps-preview__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ps-preview__photo {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.ps-preview[data-has-photo] .ps-preview__object {
	visibility: hidden;
}

/* Wall view: the stage is a wall of 300 x 220 cm, and everything is drawn to scale. */
.ps-preview__scene {
	display: none;
	position: absolute;
	inset: 0;
	color: var(--muted, #6b6b6b);
	border-bottom: 1px solid currentColor;
}

.ps-preview__sofa {
	position: absolute;
	bottom: 0;
	left: 50%;
	width: calc(200 / var(--wall-w) * 100%);
	height: auto;
	translate: -50% 0;
	overflow: visible;
}

/* The caption under a preview (the sofa note under the print, the note under the
   poster): one look for both. */
.ps-preview__note,
.ps-poster__note {
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	text-align: center;
	text-transform: uppercase;
}

.ps-preview__note {
	position: absolute;
	top: calc(100% + var(--space-xs, 0.7rem));
	right: 0;
	left: 0;
}

.ps-preview[data-view="wall"] .ps-preview__stage {
	display: block;
	min-height: 0;
	margin-bottom: var(--space-l, 2.4rem); /* room for the note under the floor line */
	aspect-ratio: var(--wall-w) / var(--wall-h);
}

.ps-preview[data-view="wall"] .ps-preview__scene {
	display: block;
}

.ps-preview[data-view="wall"] .ps-preview__object {
	position: absolute;
	left: 50%;
	bottom: calc((150 - var(--th) / 2) / var(--wall-h) * 100%);
	width: calc(var(--tw) / var(--wall-w) * 100%);
	translate: -50% 0;
	box-shadow: 0 1rem 1.6rem -0.8rem rgba(0, 0, 0, 0.35);
}

.ps-preview__views {
	display: flex;
	gap: var(--space-m, 1.6rem);
}

.ps-preview__view {
	padding: 0.4em 0;
	border: 0;
	border-bottom: 1px solid transparent;
	background: none;
	color: var(--muted, #6b6b6b);
	font: inherit;
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: color 0.25s ease, border-color 0.25s ease;
}

.ps-preview__view:hover,
.ps-preview__view.is-current {
	color: var(--ink, #111);
}

.ps-preview__view.is-current {
	border-bottom-color: currentColor;
}

/* ---------- Poster preview ----------
   The poster is drawn to scale: the largest poster of the shop is as high as
   --pp-max-h, a smaller size is drawn smaller. The hanger is two wooden strips
   (top and bottom) and a cord. A strip is 2 cm high and covers --pp-cover cm of
   the poster, the rest sticks out above (below) the paper. The sizes in cm are
   set by the script from the Size field. */
.ps-poster {
	--pp-wood: transparent;
	--pp-wood-line: transparent;
	--pp-strip: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-xs, 0.7rem);
	width: 100%;
}

.ps-poster[data-hanger="black"] { --pp-wood: #171717; --pp-wood-line: #000; }
.ps-poster[data-hanger="white"] { --pp-wood: #f6f6f3; --pp-wood-line: #cfcfc8; }
.ps-poster[data-hanger="oak"] { --pp-wood: #c7a779; --pp-wood-line: #a98a5e; }

.ps-poster__stage {
	box-sizing: border-box;
	display: grid;
	place-items: center;
	width: 100%;
	min-height: calc(var(--pp-max-h, 62vh) * 1.12);
	padding: calc(var(--pp-max-h, 62vh) * 0.1) 5.6rem 0;
}

.ps-poster__object {
	position: relative;
	width: min(100%, calc(var(--pp-max-h, 62vh) * var(--pp-w) / var(--pp-ref)));
	aspect-ratio: var(--pp-w) / var(--pp-h);
	box-shadow: 0 3rem 5rem -2.4rem rgba(0, 0, 0, 0.32), 0 0.6rem 1.4rem -0.6rem rgba(0, 0, 0, 0.2);
	transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.ps-poster__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ps-poster__strip {
	position: absolute;
	left: 50%;
	width: calc(var(--pp-hw) / var(--pp-w) * 100%);
	height: calc(var(--pp-strip) / var(--pp-h) * 100%);
	translate: -50% 0;
	background-color: var(--pp-wood);
	background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(0, 0, 0, 0.1));
	box-shadow: 0 0 0 1px var(--pp-wood-line), 0 0.3rem 0.6rem -0.2rem rgba(0, 0, 0, 0.35);
	opacity: 0;
	transition: opacity 0.3s ease, width 0.6s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease;
}

.ps-poster__strip--top { top: calc((var(--pp-cover) - var(--pp-strip)) / var(--pp-h) * 100%); }
.ps-poster__strip--bottom { bottom: calc((var(--pp-cover) - var(--pp-strip)) / var(--pp-h) * 100%); }

.ps-poster:not([data-hanger="none"]) .ps-poster__strip,
.ps-poster:not([data-hanger="none"]) .ps-poster__cord {
	opacity: 1;
}

/* The cord goes from both ends of the top strip up to one point. */
.ps-poster__cord {
	position: absolute;
	left: 50%;
	bottom: calc(100% + (var(--pp-strip) - var(--pp-cover)) / var(--pp-h) * 100%);
	width: calc(var(--pp-hw) * 0.84 / var(--pp-w) * 100%);
	height: calc(8 / var(--pp-h) * 100%);
	translate: -50% 0;
	color: var(--pp-wood-line);
	overflow: visible;
	opacity: 0;
	transition: opacity 0.3s ease;
}

.ps-poster__note {
	margin: 0;
	transition: opacity 0.3s ease;
}

.ps-poster[data-hanger="none"] .ps-poster__note {
	opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
	.ps-poster__object,
	.ps-poster__strip,
	.ps-poster__cord,
	.ps-poster__note {
		transition: none;
	}
}

/* ---------- Print prices ---------- */
.ps-prices {
	width: 100%;
	border-top: 1px solid var(--line, #e3e3e3);
	font-size: var(--text-s, 1.3rem);
}

.ps-prices__row {
	display: grid;
	grid-template-columns: 1.5fr 1fr 1fr 1fr;
	column-gap: var(--space-m, 1.6rem);
	align-items: baseline;
	padding: var(--space-xs, 0.7rem) 0;
	border-bottom: 1px solid var(--line, #e3e3e3);
	transition: color 0.25s ease;
}

.ps-prices__row--head {
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ps-prices.has-selection .ps-prices__row:not(.ps-prices__row--head):not(.is-selected) {
	color: var(--subtle, #a6a6a6);
}

/* ---------- Grid columns control ---------- */
.ps-cols {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs, 0.7rem);
	font-size: var(--text-s, 1.3rem);
}

.ps-cols__label {
	margin-right: var(--space-2xs, 0.4rem);
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ps-cols__btn {
	display: grid;
	place-items: center;
	width: 2.8rem;
	height: 2.8rem;
	padding: 0;
	border: 1px solid var(--line, #e3e3e3);
	background: none;
	color: var(--ink, #111);
	font: inherit;
	line-height: 1;
	cursor: pointer;
	transition: border-color 0.25s ease, color 0.25s ease;
}

.ps-cols__btn:hover {
	border-color: var(--ink, #111);
}

.ps-cols__btn:disabled {
	border-color: var(--line, #e3e3e3);
	color: var(--subtle, #a6a6a6);
	cursor: default;
}

.ps-cols__count {
	min-width: 1.4em;
	text-align: center;
	font-variant-numeric: tabular-nums;
}

/* ---------- Hidden by the script (for example the mat field without a frame) ----------
   Written as [class].ps-hidden so it beats one Bricks global class that sets display
   (for example spec-list__row, which is a grid). */
[class].ps-hidden {
	display: none;
}

/* ---------- Safari: pages only fade, the print image does not move between pages ---------- */
html.ps-safari .ps-preview__image,
html.ps-safari .ps-poster__image,
html.ps-safari .print__image {
	view-transition-name: none !important; /* the name is set inline on the image */
}

/* ---------- Page change: a print image without a pair on the other page ----------
   It fades with the rest of the page instead of staying on top until the end. */
::view-transition-old(print-image):only-child {
	animation: 0.18s ease both ps-vt-out;
}

@keyframes ps-vt-out {
	to { opacity: 0; }
}

/* ---------- Home page intro: a short opening animation, not a loading screen ---------- */
.ps-intro {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: grid;
	place-items: center;
	background: var(--paper, #fff);
	color: var(--ink, #111);
}

/* No script, already seen in this visit, or reduced motion: no intro. */
html:not(.ps-js) .ps-intro,
html.ps-intro-skip .ps-intro {
	display: none;
}

html.ps-intro-active {
	overflow: hidden;
}

.ps-intro__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-m, 1.6rem);
	padding: 0 var(--gutter, 2rem);
	text-align: center;
}

.ps-intro__title {
	display: grid;
	margin: 0;
	padding-bottom: 0.06em;
	overflow: hidden;
	font-size: clamp(44px, 11vw, 190px);
	font-weight: 500;
	line-height: 0.92;
	letter-spacing: -0.045em;
	text-transform: uppercase;
}

/* All large words share one place. Each word rises in as one piece. Words before
   the last one leave upwards. The last one stays and leaves with the cover. */
.ps-intro__big {
	grid-area: 1 / 1;
	white-space: nowrap;
	transform: translateY(110%);
}

.ps-intro__rule {
	width: min(22rem, 40vw);
	height: 1px;
	background: currentColor;
	transform: scaleX(0);
	transform-origin: left center;
}

.ps-intro__tagline {
	margin: 0;
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	line-height: 1.5;
	text-transform: uppercase;
	opacity: 0;
}

/* The script adds "is-playing" when the page is really on screen. */
.ps-intro.is-playing .ps-intro__big {
	animation: ps-intro-word 0.75s cubic-bezier(0.16, 1, 0.3, 1) calc(0.05s + var(--i) * 0.45s) both;
}

.ps-intro.is-playing .ps-intro__big:last-child {
	animation: ps-intro-rise 0.65s cubic-bezier(0.16, 1, 0.3, 1) calc(0.05s + var(--i) * 0.45s) forwards;
}

.ps-intro.is-playing .ps-intro__rule {
	animation: ps-intro-rule 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.15s forwards;
}

.ps-intro.is-playing .ps-intro__tagline {
	animation: ps-intro-fade 0.5s ease 0.25s forwards;
}

/* Leaving: the word carries on upwards and out of sight, the same way it came in.
   Then the cover fades and the page is there. */
.ps-intro.is-leaving .ps-intro__big:last-child {
	animation: ps-intro-word-out 0.5s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}

.ps-intro.is-leaving .ps-intro__rule,
.ps-intro.is-leaving .ps-intro__tagline {
	transition: opacity 0.25s ease;
	opacity: 0;
}

.ps-intro.is-leaving {
	animation: ps-intro-fade-out 0.45s ease 0.3s forwards;
}

@keyframes ps-intro-rise {
	to { transform: none; }
}

@keyframes ps-intro-word {
	0% { transform: translateY(110%); }
	40%, 60% { transform: none; }
	100% { transform: translateY(-110%); }
}

@keyframes ps-intro-rule {
	to { transform: scaleX(1); }
}

@keyframes ps-intro-fade {
	to { opacity: 1; }
}

@keyframes ps-intro-word-out {
	from { transform: none; }
	to { transform: translateY(-110%); }
}

@keyframes ps-intro-fade-out {
	to { opacity: 0; }
}

/* ---------- Mobile menu motion ----------
   Add the class "ps-menu-motion" to a Bricks "Nav (Nestable)" element. The panel fades in,
   its items rise in one after another. Dropdowns open and close with a height animation (script). Layout, type and
   colours of the menu stay in the Bricks settings of that element. */
@media (max-width: 991px) {
	.ps-menu-motion .brx-nav-nested-items {
		transition: opacity 0.35s ease, visibility 0.35s ease;
	}

	/* The close icon is part of the list, but it does not move: it shows with the panel. */
	.ps-menu-motion .brx-nav-nested-items > :not(.brxe-toggle) {
		opacity: 0;
		transform: translateY(2.4rem);
		transition: opacity 0.25s ease, transform 0.25s ease;
	}

	.ps-menu-motion.brx-open .brx-nav-nested-items > :not(.brxe-toggle) {
		opacity: 1;
		transform: none;
		transition: opacity 0.6s ease, transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
	}

	.ps-menu-motion.brx-open .brx-nav-nested-items > :nth-child(1) { transition-delay: 0.1s; }
	.ps-menu-motion.brx-open .brx-nav-nested-items > :nth-child(2) { transition-delay: 0.17s; }
	.ps-menu-motion.brx-open .brx-nav-nested-items > :nth-child(3) { transition-delay: 0.24s; }
	.ps-menu-motion.brx-open .brx-nav-nested-items > :nth-child(4) { transition-delay: 0.31s; }
	.ps-menu-motion.brx-open .brx-nav-nested-items > :nth-child(n + 5) { transition-delay: 0.38s; }
}

@media (max-width: 991px) and (prefers-reduced-motion: reduce) {
	.ps-menu-motion .brx-nav-nested-items,
	.ps-menu-motion .brx-nav-nested-items > * {
		transform: none;
		transition: none;
	}
}

/* ---------- Dark mode: parts drawn by the browser ----------
   The lists of dropdown fields and the scrollbars follow the Bricks light and dark mode. */
html[data-brx-theme="dark"] {
	color-scheme: dark;
}

html[data-brx-theme="light"] {
	color-scheme: light;
}

/* ---------- Grid filters: focus ----------
   Bricks draws a thick blue ring around a filter option after every click. Here the
   ring only shows for keyboard users, as a thin line in the text colour. */
.brxe-filter-radio[data-mode="button"] label:focus-within .bricks-button,
.brxe-filter-checkbox[data-mode="button"] label:focus-within .bricks-button {
	outline: none;
}

.brxe-filter-radio[data-mode="button"] input:focus-visible + .bricks-button,
.brxe-filter-checkbox[data-mode="button"] input:focus-visible + .bricks-button {
	outline: 1px solid var(--ink, #111);
	outline-offset: 4px;
}

/* ---------- Top section entrance (used on the home page) ----------
   Bricks classes to put on elements of a top section. They play once, after the
   intro and the page transition are over:
   - "enter-zoom": an image fades in and settles from a little too large to its size,
   - "enter-lines": a heading whose lines rise in one after another,
   - "enter-rise": any other text fades in and rises a little.
   Elements start in the order they appear on the page. */
.ps-js .enter-zoom:not(.is-entered),
.ps-js .enter-rise:not(.is-entered),
.ps-js .enter-lines:not(.is-entered) {
	opacity: 0;
}

.ps-js .enter-zoom.is-entered {
	animation: ps-enter-zoom 1.9s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.ps-js .enter-rise.is-entered {
	animation: ps-rise 1.1s cubic-bezier(0.16, 1, 0.3, 1) var(--ps-delay, 0ms) backwards;
}

/* Each line sits in its own window and rises into it. */
.enter-lines .ps-line {
	display: block;
	overflow: hidden;
	padding-bottom: 0.14em;
	margin-bottom: -0.14em;
	white-space: nowrap;
}

.enter-lines .ps-line > span {
	display: block;
	transform: translateY(112%);
	animation: ps-intro-rise 1.1s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--ps-delay, 0ms) + var(--w) * 110ms) forwards;
}

@keyframes ps-enter-zoom {
	from {
		opacity: 0;
		transform: scale(1.1);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ps-js .enter-zoom,
	.ps-js .enter-rise,
	.ps-js .enter-lines {
		opacity: 1 !important; /* beats the hidden start state above */
		animation: none !important;
	}
}

/* ---------- Recommendation button (fills the preorder form) ---------- */
.ps-rec {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--space-2xs, 0.4rem) var(--space-s, 1.2rem);
}

.ps-rec__button {
	padding: 0 0 0.3em;
	border: 0;
	border-bottom: 1px solid currentColor;
	background: none;
	color: var(--ink, #111);
	font: inherit;
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: color 0.25s ease, border-color 0.25s ease;
}

.ps-rec__button:hover {
	color: var(--muted, #6b6b6b);
}

.ps-rec__summary {
	color: var(--muted, #6b6b6b);
	font-size: var(--text-s, 1.3rem);
}

/* The form already has the recommended settings. */
.ps-rec.is-applied .ps-rec__button {
	border-bottom-color: transparent;
	color: var(--muted, #6b6b6b);
	cursor: default;
}

.ps-rec.is-applied .ps-rec__button::after {
	content: " \2713";
}

/* ---------- Form explanations: "i" buttons next to field labels ---------- */
.ps-has-help {
	position: relative;
}

.ps-help {
	position: relative;
	display: inline-grid;
	place-items: center;
	width: 1.5em;
	height: 1.5em;
	margin-left: 0.7em;
	padding: 0;
	border: 1px solid currentColor;
	border-radius: 50%;
	background: none;
	color: var(--muted, #6b6b6b);
	font: inherit;
	font-size: 1em;
	font-weight: 500;
	line-height: 1;
	letter-spacing: 0;
	text-transform: none;
	vertical-align: 0.05em;
	cursor: help;
	transition: color 0.2s ease;
}

/* A larger area to tap than the small circle. */
.ps-help::after {
	content: "";
	position: absolute;
	inset: -0.9em;
}

.ps-help:hover,
.ps-help[aria-expanded="true"] {
	color: var(--ink, #111);
}

.ps-help__tip {
	position: absolute;
	bottom: calc(100% + 0.6rem);
	left: 0;
	z-index: 20;
	width: min(100%, 38rem);
	padding: var(--space-s, 1.2rem) var(--space-m, 1.6rem);
	background: var(--ink, #111);
	color: var(--paper, #fff);
	font-size: var(--text-s, 1.3rem);
	line-height: 1.5;
	letter-spacing: 0;
	text-transform: none;
	opacity: 0;
	visibility: hidden;
	transform: translateY(0.4rem);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
	pointer-events: none;
}

.ps-help__tip.is-open {
	opacity: 1;
	visibility: visible;
	transform: none;
}

@media (prefers-reduced-motion: reduce) {
	.ps-help__tip {
		transition: none;
	}
}

/* ---------- Header: solid while a menu is open ----------
   The header is transparent at the top of a page (Bricks template settings give it a
   background and a line once the page scrolls). With a dropdown or the mobile menu open
   it must not be see-through, also at the top of the page. */
#brx-header:has(.brxe-dropdown.open, .brxe-dropdown.active, .brxe-nav-nested.brx-open) > .brxe-section {
	background-color: var(--paper, #fff);
}

/* ---------- Postcard set: the cards as a grid ---------- */
.ps-cards {
	display: grid;
	grid-template-columns: repeat(var(--ps-cards-cols, 4), minmax(0, 1fr));
	gap: var(--space-m, 1.6rem);
	width: 100%;
}

.ps-cards__card {
	margin: 0;
}

/* A postcard is 10 x 15 cm. */
.ps-cards__image {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 2 / 3;
	object-fit: cover;
	box-shadow: 0 1.2rem 2rem -1.2rem rgba(0, 0, 0, 0.35), 0 0.2rem 0.5rem -0.2rem rgba(0, 0, 0, 0.2);
}

.ps-cards__title {
	margin-top: var(--space-2xs, 0.4rem);
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
}

@media (max-width: 478px) {
	.ps-cards {
		grid-template-columns: repeat(var(--ps-cards-cols-phone, 3), minmax(0, 1fr));
		gap: var(--space-s, 1.2rem);
	}
}

/* ---------- Postcard set: small thumbnails of its cards (in a list of sets) ---------- */
.ps-thumbs {
	display: grid;
	grid-template-columns: repeat(var(--ps-thumbs-cols, 9), minmax(0, 1fr));
	gap: var(--space-2xs, 0.4rem);
	width: 100%;
	text-decoration: none;
}

.ps-thumbs__image {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 2 / 3;
	object-fit: cover;
}

.ps-thumbs__more {
	display: grid;
	place-items: center;
	aspect-ratio: 2 / 3;
	background: var(--surface, #f3f3f3);
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
}

/* ---------- Dropdowns of the "Add to cart" form ----------
   The script puts a button and a list next to each select of the form. The select
   stays, hidden, and holds the value. On a phone the list is a bottom sheet.
   Colours, spacing and type sizes come from the site variables. */
.ps-select {
	position: relative;
}

.brxe-form .ps-select .ps-select__native {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	pointer-events: none;
}

.ps-select__button {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-s, 1.2rem);
	box-sizing: border-box;
	width: 100%;
	margin: 0;
	padding: var(--space-s, 1.2rem) var(--space-m, 1.6rem);
	border: 1px solid var(--subtle, #a6a6a6);
	border-radius: 0;
	background: transparent;
	color: var(--ink, #111);
	font: inherit;
	font-size: var(--text-s, 1.3rem);
	line-height: 4rem;
	text-align: left;
	cursor: pointer;
	transition: border-color 0.2s ease;
}

.ps-select__button:hover,
.ps-select.is-open .ps-select__button,
.ps-select__button:focus-visible {
	border-color: var(--ink, #111);
}

.ps-select__button:focus-visible {
	outline: 1px solid var(--ink, #111);
	outline-offset: 2px;
}

.ps-select.is-invalid .ps-select__button {
	border-color: var(--ink, #111);
	box-shadow: inset 0 0 0 1px var(--ink, #111);
}

.ps-select__value {
	flex: 1;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ps-select__button.is-placeholder .ps-select__value {
	color: var(--muted, #6b6b6b);
}

.ps-select__arrow {
	flex: none;
	width: 0.7rem;
	height: 0.7rem;
	margin-top: -0.3rem;
	border-right: 1px solid currentColor;
	border-bottom: 1px solid currentColor;
	color: var(--muted, #6b6b6b);
	rotate: 45deg;
	transition: rotate 0.2s ease, margin 0.2s ease;
}

.ps-select.is-open .ps-select__arrow {
	margin-top: 0.3rem;
	rotate: -135deg;
}

/* A field with one possible value: shown, not opened (like the old fixed field). */
.ps-select__button:disabled {
	border-color: var(--line, #e3e3e3);
	color: var(--ink, #111);
	cursor: default;
}

.ps-select__button:disabled .ps-select__arrow {
	display: none;
}

/* The list under the field. */
.ps-select__popup {
	position: absolute;
	top: 100%;
	right: 0;
	left: 0;
	z-index: 30;
	visibility: hidden;
	opacity: 0;
	transform: translateY(-0.4rem);
	pointer-events: none;
	transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s linear 0.15s;
}

.ps-select.is-open .ps-select__popup {
	visibility: visible;
	opacity: 1;
	transform: none;
	pointer-events: auto;
	transition-delay: 0s;
}

.ps-select.is-up .ps-select__popup {
	top: auto;
	bottom: 100%;
	transform: translateY(0.4rem);
}

.ps-select.is-up.is-open .ps-select__popup {
	transform: none;
}

.ps-select__panel {
	margin-top: -1px;
	border: 1px solid var(--ink, #111);
	background: var(--paper, #fff);
	outline: 0;
}

.ps-select.is-up .ps-select__panel {
	margin-top: 0;
	margin-bottom: -1px;
}

.ps-select__head {
	display: none;
}

.ps-select__list {
	margin: 0;
	padding: 0;
	max-height: min(34rem, 50vh);
	overflow-y: auto;
	overscroll-behavior: contain;
	list-style: none;
	outline: 0;
}

.ps-select__option {
	display: flex;
	align-items: baseline;
	gap: var(--space-m, 1.6rem);
	margin: 0;
	padding: var(--space-s, 1.2rem) var(--space-m, 1.6rem);
	border-top: 1px solid var(--line, #e3e3e3);
	color: var(--ink, #111);
	font-size: var(--text-s, 1.3rem);
	line-height: 1.4;
	cursor: pointer;
}

.ps-select__option:first-child {
	border-top: 0;
}

.ps-select__option.is-active {
	background: var(--surface, #f3f3f3);
}

.ps-select__label {
	flex: 1;
	min-width: 0;
}

.ps-select__note {
	color: var(--muted, #6b6b6b);
	font-size: var(--text-xs, 1.1rem);
	letter-spacing: 0.04em;
	white-space: nowrap;
}

/* The mark of the chosen option: a thin tick. */
.ps-select__check {
	flex: none;
	align-self: center;
	width: 0.9rem;
	height: 0.5rem;
	margin-bottom: 0.2rem;
	border-bottom: 1px solid transparent;
	border-left: 1px solid transparent;
	rotate: -45deg;
}

.ps-select__option[aria-selected="true"] .ps-select__check {
	border-color: var(--ink, #111);
}

.ps-select__option[aria-disabled="true"] {
	color: var(--subtle, #a6a6a6);
	cursor: default;
}

.ps-select__option[aria-disabled="true"] .ps-select__note {
	color: inherit;
}

.ps-select__option[aria-disabled="true"].is-active {
	background: transparent;
}

/* The page behind a bottom sheet does not scroll. */
html.ps-select-lock {
	overflow: hidden;
}

/* Phones: the list is a sheet from the bottom, with the name of the field on top. */
@media (max-width: 767px) {
	.ps-select.is-sheet .ps-select__popup {
		position: fixed;
		inset: 0;
		z-index: 1000;
		display: flex;
		align-items: flex-end;
		background: rgba(17, 17, 17, 0.4);
		transform: none;
		transition: opacity 0.2s ease, visibility 0s linear 0.25s;
		touch-action: none;
	}

	.ps-select.is-sheet.is-open .ps-select__popup {
		transition-delay: 0s;
	}

	.ps-select.is-sheet .ps-select__panel {
		display: flex;
		flex-direction: column;
		box-sizing: border-box;
		width: 100%;
		max-height: 80vh;
		max-height: 80dvh;
		margin: 0;
		padding-bottom: env(safe-area-inset-bottom, 0px);
		border-width: 1px 0 0;
		transform: translateY(100%);
		transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
		touch-action: auto;
	}

	.ps-select.is-sheet.is-open .ps-select__panel {
		transform: none;
	}

	.ps-select.is-sheet .ps-select__head {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: var(--space-m, 1.6rem);
		padding: 0 0 0 var(--space-m, 1.6rem);
		border-bottom: 1px solid var(--line, #e3e3e3);
	}

	.ps-select__title {
		color: var(--muted, #6b6b6b);
		font-size: var(--text-xs, 1.1rem);
		letter-spacing: 0.08em;
		text-transform: uppercase;
	}

	.ps-select__close {
		display: grid;
		place-items: center;
		flex: none;
		width: 5.2rem;
		height: 5.2rem;
		padding: 0;
		border: 0;
		background: none;
		color: var(--ink, #111);
		cursor: pointer;
	}

	.ps-select.is-sheet .ps-select__list {
		flex: 1;
		max-height: none;
	}

	.ps-select.is-sheet .ps-select__option {
		align-items: center;
		min-height: 5.6rem;
		box-sizing: border-box;
		font-size: var(--text-m, 1.6rem);
	}
}

@media (prefers-reduced-motion: reduce) {
	.ps-select__button,
	.ps-select__arrow,
	.ps-select__popup,
	.ps-select__panel,
	.ps-select.is-sheet .ps-select__popup,
	.ps-select.is-sheet .ps-select__panel {
		transition: none;
	}
}

/* ---------- Preorder form: a field with one possible value (the paper) ----------
   It shows what the print is made with, but cannot be opened. The value is still sent. */
.brxe-form .ps-fixed-field select {
	appearance: none;
	-webkit-appearance: none;
	border-color: var(--line, #e3e3e3);
	background-image: none;
	pointer-events: none;
}

/* ---------- Form messages ("Thank you", or an error) ----------
   Bricks shows them green or red, in a box. Here they are plain text in the
   colours of the site, under the button. */
.brxe-form .message {
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--ink);
	font-size: var(--text-s);
	line-height: 1.5;
}

.brxe-form .message .text {
	padding: var(--space-xs) 0 0;
}

/* ---------- "Order received" opened without a valid order ----------
   This happens with an old or changed link. WooCommerce then shows only one
   line of text. Here it gets the look of a page title. */
#brx-content > .woocommerce > .woocommerce-order > .woocommerce-thankyou-order-received:only-child {
	margin: 0;
	padding: var(--space-2xl) var(--gutter) var(--space-3xl);
	border: 0;
	background: transparent;
	color: var(--ink);
	font-size: var(--text-3xl);
	line-height: 1.05;
	letter-spacing: -0.03em;
	text-align: left;
}

/* ---------- Cart: button in the header ----------
   Looks like a menu item. The Bricks controls of the element can change it. */
.ps-cart-button {
	display: inline-flex;
	align-items: baseline;
	gap: var(--space-2xs);
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--ink);
	font: inherit;
	font-size: var(--text-xs);
	line-height: 1;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	cursor: pointer;
	transition: color var(--duration-fast) ease;
}

.ps-cart-button:hover {
	color: var(--muted);
}

.ps-cart-button__count {
	font-variant-numeric: tabular-nums;
}

.ps-cart-button__count:not([hidden])::before {
	content: "(";
}

.ps-cart-button__count:not([hidden])::after {
	content: ")";
}

/* ---------- Cart: panel from the right ----------
   The panel is a Bricks template. This is only the frame it slides in: the dark
   cover, the place on the right, and the close button. */
.ps-cart {
	position: fixed;
	inset: 0;
	z-index: 1000;
}

.ps-cart[hidden] {
	display: none;
}

.ps-cart__overlay {
	position: absolute;
	inset: 0;
	background: rgb(0 0 0 / 0.4);
	opacity: 0;
	transition: opacity 0.4s var(--ease-out);
}

.ps-cart__panel {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	width: min(50rem, 100%);
	overflow-y: auto;
	overscroll-behavior: contain;
	background: var(--paper);
	color: var(--ink);
	outline: none;
	transform: translateX(100%);
	transition: transform 0.5s var(--ease-out);
}

.ps-cart.is-open .ps-cart__overlay {
	opacity: 1;
}

.ps-cart.is-open .ps-cart__panel {
	transform: none;
}

.ps-cart__close {
	position: absolute;
	top: var(--space-m);
	right: var(--space-m);
	z-index: 1;
	display: grid;
	place-items: center;
	width: 4.4rem;
	height: 4.4rem;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--ink);
	cursor: pointer;
	transition: color var(--duration-fast) ease;
}

.ps-cart__close:hover {
	color: var(--muted);
}

.ps-cart__close:focus-visible,
.ps-cart-button:focus-visible,
.ps-cart__remove:focus-visible {
	outline: 1px solid var(--ink);
	outline-offset: 3px;
}

.ps-cart__message {
	margin: 0;
	padding: var(--space-s) var(--space-l) 0;
	color: var(--ink);
	font-size: var(--text-s);
	line-height: 1.5;
}

.ps-cart__missing {
	margin: 0;
	padding: var(--space-l);
	color: var(--muted);
	font-size: var(--text-s);
}

@media (prefers-reduced-motion: reduce) {
	.ps-cart__overlay,
	.ps-cart__panel {
		transition: none;
	}
}

/* The form in the panel: a Bricks-form look. A few parts that Bricks does not know. */
.ps-cart-form__note {
	margin: 0;
	color: var(--muted);
	font-size: var(--text-s);
	line-height: 1.5;
}

/* A field that only a program fills in. */
.ps-cart-form__trap {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.ps-cart-form .bricks-button.is-disabled {
	opacity: 0.4;
	pointer-events: none;
}

/* ---------- Spam guard: a field that only a program fills in ----------
   The script adds it to every Bricks form. It is off the screen, not display:none,
   because programs skip fields that are not displayed. */
.ps-form-trap {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ---------- WooCommerce forms: Checkout, Cart and My account ----------
   The WooCommerce blocks (Checkout and Cart) and the classic forms (My account, paying
   an existing order) have white fields, grey buttons and fixed light colours. Here every
   part uses the palette variables, so it follows the light and dark mode of the site.
   The look is the one of the Contact form: no background, a thin line in --subtle, no
   rounded corners, the text size of the form text, and a thin line in --ink on focus.
   An error is shown with a thicker line in --ink and the message text (the site has no
   red). WooCommerce styles come after the Bricks styles and use up to four classes, so
   the selectors here start with "body" and repeat one class. No !important is needed. */

/* Blocks: Checkout and Cart */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) {
	color: var(--ink);
}

/* Text fields, selects, the order note */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="number"], [type="password"], [type="url"], [type="search"]),
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__select,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-textarea.wc-block-components-textarea,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-combobox .components-combobox-control__input.components-combobox-control__input {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background-color: transparent;
	box-shadow: none;
	color: var(--ink);
	font-size: var(--text-s);
	transition: border-color 0.2s ease;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="number"], [type="password"], [type="url"], [type="search"]),
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-combobox .components-combobox-control__input.components-combobox-control__input {
	height: 5.6rem;
	padding: 2.4rem var(--space-m) 0.8rem;
	line-height: 1.3;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__select {
	height: 5.6rem;
	padding: 2.4rem calc(var(--space-m) + 2.4rem) 0.8rem var(--space-m);
	line-height: 1.3;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-textarea.wc-block-components-textarea {
	padding: var(--space-s) var(--space-m);
	line-height: 1.5;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="number"], [type="password"], [type="url"], [type="search"]):hover,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__select:hover,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-textarea.wc-block-components-textarea:hover {
	border-color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-textarea.wc-block-components-textarea::placeholder {
	color: var(--muted);
}

/* Focus: a thin line in --ink, also with WooCommerce's own focus rule (1.5 px, light colours) */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="number"], [type="password"], [type="url"], [type="search"]):focus,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__select:focus,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-textarea.wc-block-components-textarea:focus,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-combobox .components-combobox-control__input.components-combobox-control__input:focus {
	border: 1px solid var(--ink);
	background-color: transparent;
	box-shadow: none;
	color: var(--ink);
	outline: 1px solid var(--ink);
	outline-offset: 0;
}

/* Error: a thicker line in --ink */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.has-error.has-error input,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.has-error.has-error input:focus,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select.has-error .wc-blocks-components-select__select,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-combobox.has-error .components-combobox-control__input.components-combobox-control__input,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox.has-error .wc-block-components-checkbox__input[type="checkbox"] {
	border-color: var(--ink);
	box-shadow: inset 0 0 0 1px var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__container {
	background-color: transparent;
}

/* Labels (they float above the text once the field has a value or focus) */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input label,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__label,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-combobox .wc-block-components-form-token-field-label {
	left: var(--space-m);
	max-width: calc(100% - 2 * var(--space-m));
	color: var(--muted);
	font-size: var(--text-s);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input label {
	top: 2.8rem;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input.is-active label,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.wc-block-components-text-input input:-webkit-autofill + label {
	top: 0.6rem;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-text-input.has-error.has-error label,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-validation-error,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-validation-error > p {
	color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-validation-error svg {
	fill: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-blocks-components-select .wc-blocks-components-select__expand {
	right: var(--space-m);
	fill: var(--ink);
}

/* The list of a combobox (a country or state that is typed) */
body .wc-block-components-combobox .components-form-token-field__suggestions-list,
body .components-popover .components-form-token-field__suggestions-list {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: var(--paper);
	box-shadow: none;
	color: var(--ink);
	font-size: var(--text-s);
}

body .wc-block-components-combobox .components-form-token-field__suggestion,
body .components-popover .components-form-token-field__suggestion {
	color: var(--ink);
}

body .wc-block-components-combobox .components-form-token-field__suggestion.is-selected,
body .components-popover .components-form-token-field__suggestion.is-selected,
body .wc-block-components-combobox .components-form-token-field__suggestion:hover {
	background: var(--surface);
	color: var(--ink);
}

/* Checkboxes and radio buttons */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"],
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control .wc-block-components-radio-control__input {
	border-color: var(--subtle);
	background-color: transparent;
	background-image: none;
	color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"] {
	border-radius: 0;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:checked {
	border-color: var(--ink);
	background: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control .wc-block-components-radio-control__input:checked {
	border-color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control .wc-block-components-radio-control__input:checked::before {
	background: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:focus-visible,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control .wc-block-components-radio-control__input:focus-visible {
	outline: 1px solid var(--ink);
	outline-offset: 2px;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-checkbox .wc-block-components-checkbox__mark {
	fill: var(--paper);
}

/* Payment method boxes and the Stripe test label */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control-accordion-option,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-radio-control-accordion-content {
	color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-stripe-test-mode-badge {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: var(--surface);
	color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-stripe-copy-test-number {
	color: var(--ink);
}

/* Notices and error messages */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner,
body .wc-block-components-notice-snackbar {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background-color: var(--paper);
	color: var(--ink);
	font-size: var(--text-s);
}

/* A long message (for example a key from Stripe) wraps instead of widening the page */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner .wc-block-components-notice-banner__content {
	min-width: 0;
	overflow-wrap: anywhere;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) fieldset {
	min-width: 0;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner:is(.is-error, .is-warning) {
	border-color: var(--ink);
	background-color: var(--paper);
	box-shadow: inset 0 0 0 1px var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner > svg {
	background-color: var(--ink);
	fill: var(--paper);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner .wc-block-components-button.is-link,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-notice-banner a {
	color: var(--ink);
}

/* Buttons: the Contact form button */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link) {
	border: 1px solid var(--ink);
	border-radius: 0;
	background-color: var(--ink);
	box-shadow: none;
	color: var(--paper);
	font-size: var(--text-s);
	letter-spacing: 0.5px;
	transition: background-color 0.2s ease, border-color 0.2s ease;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link):hover,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link):focus {
	border-color: var(--muted);
	background-color: var(--muted);
	color: var(--paper);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link):focus-visible {
	outline: 1px solid var(--ink);
	outline-offset: 2px;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link):disabled,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.wc-block-components-button:not(.is-link)[aria-disabled="true"] {
	opacity: 0.4;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-button.is-link {
	color: var(--ink);
}

/* The cart: quantity selector, the number on the product image */
body .wp-block-woocommerce-cart .wc-block-components-quantity-selector.wc-block-components-quantity-selector {
	border-radius: 0;
	background: transparent;
	color: var(--ink);
}

body .wp-block-woocommerce-cart .wc-block-components-quantity-selector .wc-block-components-quantity-selector__input,
body .wp-block-woocommerce-cart .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button {
	background: transparent;
	color: var(--ink);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-order-summary-item__quantity {
	border: 1px solid var(--paper);
	background: var(--ink);
	box-shadow: none;
	color: var(--paper);
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-order-summary-item__quantity span {
	color: inherit;
}

/* Square corners, as in the rest of the site */
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) :is(.wc-block-components-address-card, .wc-blocks-components-select__container, .wc-block-components-radio-control__option, .wc-block-components-radio-control-accordion-option, .wc-block-components-radio-control-accordion-content, .wp-block-woocommerce-checkout-order-summary-block, .wp-block-woocommerce-cart-order-summary-block) {
	border-radius: 0;
}

body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-product-badge,
body :is(.wp-block-woocommerce-checkout, .wp-block-woocommerce-cart) .wc-block-components-sale-badge {
	border-color: var(--subtle);
	border-radius: 0;
	background: transparent;
	color: var(--ink);
}

/* Classic forms: My account and paying an existing order */
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row label {
	display: block;
	margin: 0 0 var(--space-2xs);
	color: var(--muted);
	font-size: var(--text-xs);
	letter-spacing: 0.08em;
	line-height: 1.4;
	text-align: left;
	text-transform: uppercase;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row label.checkbox,
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row label.woocommerce-form__label-for-checkbox {
	display: flex;
	align-items: center;
	gap: var(--space-xs);
	color: var(--ink);
	font-size: var(--text-s);
	letter-spacing: 0;
	text-transform: none;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row .required {
	color: inherit;
	text-decoration: none;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], input[type="search"], textarea, select) {
	box-sizing: border-box;
	width: 100%;
	margin: 0;
	padding: var(--space-s) var(--space-m);
	border: 1px solid var(--subtle);
	border-radius: 0;
	background-color: transparent;
	box-shadow: none;
	color: var(--ink);
	font: inherit;
	font-size: var(--text-s);
	line-height: 4rem;
	transition: border-color 0.2s ease;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row textarea {
	line-height: 1.5;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], input[type="search"], textarea, select):hover {
	border-color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], input[type="search"], textarea, select):focus {
	border-color: var(--ink);
	outline: 1px solid var(--ink);
	outline-offset: 0;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row.woocommerce-invalid :is(input.input-text, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], textarea, select) {
	border-color: var(--ink);
	box-shadow: inset 0 0 0 1px var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row input[type="checkbox"],
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row input[type="radio"] {
	accent-color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .password-input {
	display: block;
	position: relative;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .password-input .show-password-input {
	top: 50%;
	right: var(--space-m);
	transform: translateY(-50%);
	color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row input[type="checkbox"] {
	appearance: none;
	flex: none;
	width: 2rem;
	height: 2rem;
	margin: 0;
	border: 1px solid var(--subtle);
	border-radius: 0;
	background-color: transparent;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row input[type="checkbox"]:checked {
	border-color: var(--ink);
	background-color: var(--ink);
	box-shadow: inset 0 0 0 4px var(--paper);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .form-row input[type="checkbox"]:focus-visible {
	outline: 1px solid var(--ink);
	outline-offset: 2px;
}

/* The login, register and password forms: left aligned, no box, like the Contact form */
body.woocommerce-account :is(form.woocommerce-form-login, form.woocommerce-form-register, form.lost_reset_password, form.woocommerce-ResetPassword) {
	max-width: 48rem;
	margin: 0 0 var(--space-xl);
	padding: 0;
	border: 0;
	text-align: left;
}

body.woocommerce-account .woocommerce > h2,
body.woocommerce-account .woocommerce .u-column1 > h2,
body.woocommerce-account .woocommerce .u-column2 > h2 {
	text-align: left;
}

body.woocommerce-account .woocommerce-LostPassword {
	margin: var(--space-s) 0 0;
	text-align: left;
}

body.woocommerce-account .woocommerce-form-login__submit {
	margin-top: var(--space-s);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) fieldset {
	border-color: var(--subtle);
	color: var(--ink);
}

/* The country and state lists of the address form (WooCommerce uses selectWoo here) */
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-selection--single {
	height: auto;
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: transparent;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-selection--single .select2-selection__rendered {
	padding: var(--space-s) var(--space-m);
	color: var(--ink);
	font-size: var(--text-s);
	line-height: 4rem;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-selection--single .select2-selection__arrow {
	top: 0;
	right: var(--space-s);
	height: 100%;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-selection--single .select2-selection__arrow b {
	border-color: var(--ink) transparent transparent;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default.select2-container--open .select2-selection--single,
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default.select2-container--focus .select2-selection--single {
	border-color: var(--ink);
	outline: 1px solid var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-dropdown {
	border: 1px solid var(--ink);
	border-radius: 0;
	background: var(--paper);
	color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-search--dropdown .select2-search__field {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: transparent;
	color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-results__option {
	color: var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-results__option--highlighted[aria-selected],
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .select2-container--default .select2-results__option[aria-selected="true"] {
	background: var(--surface);
	color: var(--ink);
}

/* Classic buttons */
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-button, .woocommerce-Button, a.button, button.button, #place_order) {
	padding: var(--space-m) var(--space-l);
	border: 1px solid var(--ink);
	border-radius: 0;
	background-color: var(--ink);
	box-shadow: none;
	color: var(--paper);
	font-size: var(--text-s);
	font-weight: 400;
	letter-spacing: 0.5px;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color 0.2s ease, border-color 0.2s ease;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-button, .woocommerce-Button, a.button, button.button, #place_order):is(:hover, :focus) {
	border-color: var(--muted);
	background-color: var(--muted);
	color: var(--paper);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-button, .woocommerce-Button, a.button, button.button, #place_order):focus-visible {
	outline: 1px solid var(--ink);
	outline-offset: 2px;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-button, .woocommerce-Button, a.button, button.button, #place_order):disabled {
	opacity: 0.4;
}

/* Classic notices */
body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-message, .woocommerce-info, .woocommerce-error) {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-s);
	margin: 0 0 var(--space-m);
	padding: var(--space-s) var(--space-m);
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: transparent;
	color: var(--ink);
	font-size: var(--text-s);
	line-height: 1.5;
	list-style: none;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-message, .woocommerce-info, .woocommerce-error)::before {
	display: none;
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) .woocommerce-error {
	border-color: var(--ink);
	box-shadow: inset 0 0 0 1px var(--ink);
}

body:is(.woocommerce-account, .woocommerce-checkout, .woocommerce-cart) :is(.woocommerce-message, .woocommerce-info, .woocommerce-error) a:not(.button) {
	color: var(--ink);
}

/* Paying an existing order: the payment list and its boxes */
body:is(.woocommerce-checkout) #payment {
	border-radius: 0;
	background: transparent;
	color: var(--ink);
}

body:is(.woocommerce-checkout) #payment ul.payment_methods,
body:is(.woocommerce-checkout) #payment div.form-row {
	border-color: var(--line);
}

body:is(.woocommerce-checkout) #payment div.payment_box {
	border-radius: 0;
	background: var(--surface);
	color: var(--ink);
}

body:is(.woocommerce-checkout) #payment div.payment_box::before {
	border-bottom-color: var(--surface);
}

body:is(.woocommerce-checkout) .wc-stripe-elements-field,
body:is(.woocommerce-checkout) .wc-stripe-iban-element-field {
	border: 1px solid var(--subtle);
	border-radius: 0;
	background: transparent;
	color: var(--ink);
}
