/* Art Print Options for WooCommerce */
.apo, .apo-merch-views, .apo-g-merch {
	/* Defaults; the script replaces ink, bg, accent and accent-ink with the theme's own colours. */
	--apo-ink: #302f2f;
	--apo-bg: #ffffff;
	--apo-accent: #000000;
	--apo-accent-ink: #ffffff;
	--apo-muted: color-mix(in srgb, var(--apo-ink) 62%, transparent);
	--apo-line: color-mix(in srgb, var(--apo-ink) 22%, transparent);
	--apo-hover: color-mix(in srgb, var(--apo-ink) 6%, transparent);
	--apo-soft: color-mix(in srgb, var(--apo-ink) 5%, transparent);
	--apo-stage: color-mix(in srgb, var(--apo-ink) 6%, var(--apo-bg));
}
.apo {
	margin: 0 0 1.25em;
	color: var(--apo-ink);
	font-size: 15px;
	line-height: 1.4;
	clear: both;
	width: 100%;
}
.apo * { box-sizing: border-box; }
.apo [hidden] { display: none !important; }

/* Options get a full row when the theme makes the add-to-cart form a flex row or grid */
.apo.apo-in-flex { flex: 0 0 100%; max-width: 100%; order: -1; }
.apo.apo-in-grid { grid-column: 1 / -1; }

/* ---- Dropdown boxes (Medium / Size / Style / Frame) ---- */
.apo-steps { display: flex; flex-direction: column; gap: 18px; }
.apo-dd { position: relative; border: 1px solid var(--apo-line); background: transparent; border-radius: 0; }
.apo-dd-legend {
	position: absolute; top: -9px; left: 12px; padding: 0 5px;
	background: var(--apo-bg); color: var(--apo-muted); font-size: 13px; line-height: 16px; letter-spacing: .02em;
}
.apo .apo-dd-head {
	all: unset; box-sizing: border-box; cursor: pointer;
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	width: 100%; padding: 12px 18px 11px 20px; min-height: 44px;
	font-weight: 600; font-size: 15px; letter-spacing: .02em; color: var(--apo-ink);
}
.apo .apo-dd-head:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: -2px; }
.apo-dd:not(.has-value) .apo-dd-value { font-weight: 400; color: var(--apo-muted); }
.apo-dd-chev { width: 9px; height: 9px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-3px); flex: none; opacity: .7; transition: transform .15s; }
.apo-dd.is-open .apo-dd-chev { transform: rotate(-135deg) translateY(-2px); }
.apo-dd-body { border-top: 1px solid var(--apo-line); padding: 18px 20px 20px; }

/* ---- Tiles (medium, style, frame) ---- */
.apo-tiles { display: flex; flex-wrap: wrap; gap: 10px; }
.apo .apo-tile {
	all: unset; box-sizing: border-box; cursor: pointer;
	display: flex; flex-direction: column; align-items: center; gap: 7px;
	width: 92px; padding: 8px 6px 9px; text-align: center;
	border: 1px solid transparent; color: #6b6b6b; font-size: 13px; line-height: 1.25;
	transition: border-color .15s, color .15s;
}
.apo .apo-tile:hover { color: var(--apo-ink); border-color: #e6e6e6; }
.apo .apo-tile.is-on { border-color: var(--apo-ink); color: var(--apo-ink); font-weight: 600; }
.apo .apo-tile:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: 2px; }
.apo-tile-label { display: block; }
.apo-tile-price { display: block; color: var(--apo-muted); font-size: 11.5px; font-weight: 400; white-space: nowrap; }

.apo-ico { display: block; position: relative; width: 74px; height: 48px; background: center / cover no-repeat; flex: none; }
/* Medium textures */
.apo-tex { clip-path: polygon(8% 18%, 100% 0, 92% 82%, 0 100%); }
.apo-tex-paper { background: linear-gradient(160deg, #fff 0%, #f1efea 70%, #e2dfd8 100%); box-shadow: inset 0 0 0 1px #e3e1dc; }
.apo-tex-canvas { background-color: #ece8de; background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.05) 0 1px, transparent 1px 3px), repeating-linear-gradient(90deg, rgba(0,0,0,.05) 0 1px, transparent 1px 3px); }
.apo-tex-metal { background: linear-gradient(135deg, #f7f7f8 0%, #b7bbbf 35%, #fafafa 55%, #8e9397 100%); }
.apo-tex-acrylic { background: linear-gradient(150deg, #e9f2f6 0%, #ffffff 40%, #cfdfe6 100%); }
.apo-tex-wood { background: repeating-linear-gradient(100deg, #c9a37a 0 6px, #b98f63 6px 9px, #cfab84 9px 15px); }
/* Style icons drawn from the artwork */
.apo-ico-art { position: absolute; background: center / cover no-repeat #ccc; }
.apo-ico-print .apo-ico-art { inset: 8px 4px; box-shadow: 0 2px 4px rgba(0,0,0,.25); }
.apo-ico-border .apo-ico-art { inset: 12px 10px; outline: 6px solid #fff; box-shadow: 0 2px 6px 6px rgba(0,0,0,.18); }
.apo-ico-framed { background: #fff; border: 6px solid #b59a66; box-shadow: 0 2px 4px rgba(0,0,0,.25); }
.apo-ico-framed .apo-ico-art { inset: 6px; }
.apo-ico-mirror .apo-ico-art, .apo-ico-wrap .apo-ico-art, .apo-ico-float .apo-ico-art { inset: 6px 12px 12px 6px; }
.apo-ico-mirror::after, .apo-ico-wrap::after { content: ""; position: absolute; left: 6px; right: 12px; bottom: 6px; height: 6px; background: rgba(0,0,0,.35); transform: skewX(45deg); transform-origin: 0 0; }
.apo-ico-mirror::before, .apo-ico-wrap::before { content: ""; position: absolute; top: 6px; right: 6px; bottom: 12px; width: 6px; background: rgba(0,0,0,.25); transform: skewY(45deg); transform-origin: 0 0; }
.apo-ico-float .apo-ico-art { box-shadow: 5px 6px 8px rgba(0,0,0,.35); }
.apo-ico-color { width: 34px; height: 34px; margin: 7px 0; background: var(--apo-swatch); border: 2px solid #fff; box-shadow: 0 0 0 1px #cfcfcf; }
.apo-ico-moulding { width: 70px; height: 42px; background: var(--apo-frame); clip-path: polygon(0 0, 100% 0, 50% 100%); }
.apo-ico-moulding::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255,255,255,.35), rgba(0,0,0,.2)); clip-path: polygon(14% 0, 86% 0, 50% 72%); }

/* Style groups */
.apo-group + .apo-group { margin-top: 18px; }
.apo-group-title { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 10px; }

/* Border colour */
.apo-color { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--apo-line); }
.apo-color-custom { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; cursor: pointer; }
.apo-color-input { width: 36px; height: 30px; padding: 0; border: 1px solid var(--apo-line); background: none; cursor: pointer; }
.apo-color-presets { display: flex; flex-wrap: wrap; gap: 6px; }
.apo .apo-color-dot { all: unset; box-sizing: border-box; cursor: pointer; width: 22px; height: 22px; border-radius: 50%; background: var(--apo-swatch); box-shadow: 0 0 0 1px #cfcfcf; }
.apo .apo-color-dot.is-on { box-shadow: 0 0 0 2px #fff, 0 0 0 3.5px var(--apo-ink); }
.apo .apo-color-dot:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: 2px; }

/* Sizes */
.apo-pills { display: flex; flex-wrap: wrap; gap: 10px; }
.apo .apo-pill {
	all: unset; box-sizing: border-box; cursor: pointer;
	display: inline-flex; align-items: center; gap: 8px;
	min-width: 110px; justify-content: center; padding: 10px 16px;
	border: 1px solid var(--apo-line); color: #555; font-size: 13.5px; letter-spacing: .03em;
}
.apo .apo-pill:hover { border-color: #999; color: var(--apo-ink); }
.apo .apo-pill.is-on { background: var(--apo-accent); border-color: var(--apo-accent); color: var(--apo-accent-ink); }
.apo .apo-pill.is-on .apo-tile-price { color: rgba(255,255,255,.75); }
.apo .apo-pill:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: 2px; }
.apo-note { margin: 14px 0 0; color: var(--apo-muted); font-size: 12.5px; letter-spacing: .02em; }

/* Total (only shown when the theme has no live main price) */
.apo-summary { display: flex; align-items: baseline; gap: 10px; margin-top: 16px; }
.apo-total-label { color: var(--apo-muted); font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.apo-total { font-size: 22px; font-weight: 600; }

.apo-notice { margin: 12px 0 0; padding: 10px 12px; border-left: 3px solid #b3261e; background: #fbeeed; color: #7d1a14; font-size: 14px; }
.single_add_to_cart_button.apo-locked { opacity: .5; cursor: not-allowed; }
.apo-from { font-size: .7em; text-transform: uppercase; letter-spacing: .06em; opacity: .7; margin-right: .25em; }
.apo-from[hidden] { display: none !important; }

/* ---- Chosen finish drawn on the main product image ---- */
.apo-g { position: relative; box-sizing: border-box !important; transition: border-width .2s, padding .2s, box-shadow .2s; }
.apo-g img { display: block; }
.apo-g-framed {
	border: var(--apo-g-fw) solid var(--apo-g-frame) !important;
	padding: var(--apo-g-mat) !important;
	background: #fbfaf7 !important;
	box-shadow: 0 14px 30px rgba(0,0,0,.28), 0 2px 6px rgba(0,0,0,.18) !important;
}
.apo-g-framed::after {
	content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2;
	box-shadow: inset 2px 2px 5px rgba(0,0,0,.35), inset -1px -1px 2px rgba(255,255,255,.25);
}
/* "Just the print – 1" border": white paper border, no frame */
.apo-g-matted { padding: var(--apo-g-mat) !important; background: #fff !important; box-shadow: 0 4px 14px rgba(0,0,0,.18) !important; }
/* Canvas gallery wrap: slim top and left sides (mirrored artwork or the border colour), soft shadow bottom-right */
.apo-g-wrap { padding: var(--apo-g-d) 0 0 var(--apo-g-d) !important; background: transparent !important; box-shadow: 7px 9px 14px -2px rgba(0,0,0,.28) !important; }
.apo-g-wrap::before, .apo-g-wrap::after { content: ""; position: absolute; pointer-events: none; z-index: 2; }
/* top side: from the top-left corner across, sloping down to the front face */
.apo-g-wrap::before { top: 0; left: var(--apo-g-d); right: 0; height: var(--apo-g-d); background: var(--apo-g-edge-t); transform-origin: 0 100%; transform: skewX(45deg); }
/* left side */
.apo-g-wrap::after { left: 0; top: var(--apo-g-d); bottom: 0; width: var(--apo-g-d); background: var(--apo-g-edge-l); transform-origin: 100% 0; transform: skewY(45deg); }
.apo-g-canvas:not(.apo-g-framed):not(.apo-g-wrap) { box-shadow: 6px 10px 20px rgba(0,0,0,.28) !important; }
.apo-g-float { box-shadow: 10px 16px 26px rgba(0,0,0,.32) !important; }
.apo-g-metal:not(.apo-g-framed)::after,
.apo-g-acrylic:not(.apo-g-framed)::after {
	content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2;
	background: linear-gradient(120deg, rgba(255,255,255,0) 30%, rgba(255,255,255,.16) 45%, rgba(255,255,255,0) 60%);
}

@media (max-width: 480px) {
	.apo .apo-tile { width: calc(33.333% - 7px); }
	.apo-dd-body { padding: 16px 12px 16px; }
	.apo .apo-pill { min-width: 0; flex: 1 1 40%; }
}

/* ---- Merchandise ---- */
.apo-tiles-merch { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--apo-line); }
.apo-ico-merch { width: 48px; height: 48px; color: #6b6b6b; }
.apo-ico-merch svg { width: 100%; height: 100%; display: block; }
.apo .apo-tile.is-on .apo-ico-merch { color: var(--apo-ink); }

.apo-customize { display: flex; flex-direction: column; gap: 16px; }
.apo-field { display: block; }
.apo-field-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.apo-field-label { color: var(--apo-muted); font-size: 13px; }
.apo-range-val { font-size: 13px; font-weight: 600; color: var(--apo-ink); }
.apo-range { width: 100%; accent-color: var(--apo-ink); margin: 0; }
.apo-ticks { display: flex; justify-content: space-between; color: var(--apo-muted); font-size: 11px; margin-top: 2px; }
.apo-field-select { position: relative; border: 1px solid var(--apo-line); border-radius: 2px; }
.apo-field-legend { position: absolute; top: -9px; left: 10px; padding: 0 5px; background: var(--apo-bg); color: var(--apo-muted); font-size: 12.5px; line-height: 16px; }
.apo .apo-select {
	width: 100%; border: 0; background: transparent; padding: 12px 34px 10px 14px; font-size: 14.5px; color: var(--apo-ink);
	appearance: none; -webkit-appearance: none; cursor: pointer; border-radius: 2px;
	background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
	background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%; background-size: 5px 5px; background-repeat: no-repeat;
}
.apo .apo-select:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: 1px; }
.apo-swatches { display: flex; flex-wrap: wrap; gap: 7px; }
.apo .apo-swatch { all: unset; box-sizing: border-box; cursor: pointer; width: 26px; height: 26px; border-radius: 50%; background: var(--apo-swatch); box-shadow: inset 0 0 0 1px rgba(0,0,0,.18); }
.apo .apo-swatch.is-on { box-shadow: inset 0 0 0 1px rgba(0,0,0,.18), 0 0 0 2px #fff, 0 0 0 3.5px var(--apo-ink); }
.apo .apo-swatch:focus-visible { outline: 2px solid var(--apo-ink); outline-offset: 3px; }

/* Mockup drawn over the main product image */
.apo-g-merch { position: relative !important; }
.apo-merch-stage { position: absolute; inset: 0; z-index: 4; background: var(--apo-stage, #f3f3f1); display: flex; align-items: center; justify-content: center; pointer-events: none; }
.apo-merch-stage svg { width: 100%; height: 100%; display: block; }
.apo-merch-tag { position: absolute; left: 12px; top: 12px; background: rgba(255,255,255,.92); color: #1c1b19; padding: 4px 10px; border-radius: 20px; font-size: 12px; letter-spacing: .04em; }

/* Extra mockup views under the main image (mug angles, pillow front/back) */
.apo-merch-views { margin: 10px 0 0; width: 100%; flex: 0 0 100%; clear: both; }
.apo-merch-note { margin: 0 0 10px; text-align: center; color: #8a8a8a; font-size: 13px; letter-spacing: .04em; }
.apo-merch-thumbs { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.apo-merch-thumb { all: unset; box-sizing: border-box; flex: none; cursor: pointer; width: 96px; height: 96px; background: var(--apo-stage, #f3f3f1); border: 1px solid transparent; border-radius: 2px; position: relative; }
.apo-merch-thumb svg { width: 100%; height: 100%; display: block; }
.apo-merch-thumb .apo-merch-tag { display: none; }
.apo-merch-thumb:hover { border-color: #c9c9c9; }
.apo-merch-thumb.is-on { border-color: #1c1b19; }
.apo-merch-thumb:focus-visible { outline: 2px solid #1c1b19; outline-offset: 2px; }


/* ---- Theme harmony ----
   Many themes (e.g. Hello Elementor's reset.css) colour every button:hover / :focus (pink #c36).
   Our buttons set their own background and text colour in every state so the theme's colour never shows. */
.apo .apo-dd-head, .apo .apo-dd-head:hover, .apo .apo-dd-head:focus, .apo .apo-dd-head:active { background: transparent; color: var(--apo-ink); box-shadow: none; }
.apo .apo-dd-head:hover { background: var(--apo-hover); }
.apo .apo-tile, .apo .apo-tile:focus, .apo .apo-tile:active { background: transparent; box-shadow: none; }
.apo .apo-tile:hover { background: var(--apo-hover); color: var(--apo-ink); border-color: var(--apo-line); }
.apo .apo-tile.is-on, .apo .apo-tile.is-on:hover, .apo .apo-tile.is-on:focus { background: transparent; color: var(--apo-ink); border-color: var(--apo-ink); }
.apo .apo-pill, .apo .apo-pill:focus, .apo .apo-pill:active { background: transparent; color: var(--apo-ink); box-shadow: none; }
.apo .apo-pill:hover { background: var(--apo-hover); color: var(--apo-ink); border-color: var(--apo-ink); }
.apo .apo-pill.is-on, .apo .apo-pill.is-on:hover, .apo .apo-pill.is-on:focus { background: var(--apo-accent); color: var(--apo-accent-ink); border-color: var(--apo-accent); }
.apo .apo-color-dot, .apo .apo-color-dot:hover, .apo .apo-color-dot:focus, .apo .apo-color-dot:active,
.apo .apo-swatch, .apo .apo-swatch:hover, .apo .apo-swatch:focus, .apo .apo-swatch:active { background: var(--apo-swatch); color: inherit; }
.apo-merch-views .apo-merch-thumb:hover, .apo-merch-views .apo-merch-thumb:focus, .apo-merch-views .apo-merch-thumb:active { background: var(--apo-stage, #f3f3f1); color: inherit; }
.apo-merch-views .apo-merch-thumb:hover { border-color: var(--apo-line); }
.apo-merch-views .apo-merch-thumb.is-on { border-color: var(--apo-ink); }
.apo .apo-select, .apo .apo-select:hover, .apo .apo-select:focus { background-color: transparent; color: var(--apo-ink); font-family: inherit; box-shadow: none; }
.apo .apo-field-select { border-color: var(--apo-line); border-radius: 0; }
.apo .apo-range { accent-color: var(--apo-accent); }
.apo .apo-tile, .apo .apo-pill, .apo .apo-dd-head, .apo .apo-select { font-family: inherit; text-transform: none; letter-spacing: normal; }
.apo .apo-dd-head { letter-spacing: .02em; }
.apo-merch-note { color: var(--apo-muted); }
.apo-ico-merch { color: var(--apo-muted); }
.apo .apo-tile.is-on .apo-ico-merch, .apo .apo-tile:hover .apo-ico-merch { color: var(--apo-ink); }
