/* ==========================================================================
   Single product page
   Desktop: image column (100vh slots, loops) · sticky thumb rail · sticky details
   ========================================================================== */

/* Header floats over the image column on desktop (as in the design). */
@media (min-width: 961px) {
	.single-product .site-header { position: absolute; top: 0; left: 0; right: 0; }
}

.pdp {
	display: flex;
	align-items: flex-start;
	width: 100%;
}

/* ---------- Image column ---------- */
.pdp-gallery {
	position: relative;
	flex: 0 0 39.375vw; /* 567px at 1440 */
	width: 39.375vw;
	min-width: 0;
}
.pdp-gallery__track { display: flex; flex-direction: column; }
.pdp-gallery__set { display: flex; flex-direction: column; }
.pdp-gallery__slot {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100vh;
	min-height: 100vh;
	overflow: hidden;
}
.pdp-gallery__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
}

/* Mobile carousel controls (hidden on desktop) */
.pdp-gallery__nav,
.pdp-dots { display: none; }

/* ---------- Thumbnail rail ---------- */
.pdp-thumbs {
	position: sticky;
	top: 0;
	align-self: flex-start;
	flex-shrink: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	max-height: 100vh;
	padding: 4.25rem 2.5rem 4.25rem 1.5rem;
}
.pdp-thumbs__arrow {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 2rem;
	height: 2rem;
	padding: 0;
	background: transparent;
	border: none;
	cursor: pointer;
	transition: opacity var(--ease-button);
}
.pdp-thumbs__arrow:hover { opacity: 0.7; }
.pdp-thumbs__arrow svg { width: 1.25rem; height: 1.25rem; }
.pdp-thumbs__arrow--down svg { transform: rotate(180deg); }
.pdp-thumbs__viewport { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.pdp-thumbs__list {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	overflow-y: auto;
	scrollbar-width: none;
	scroll-behavior: smooth;
}
.pdp-thumbs__list::-webkit-scrollbar { display: none; }
.pdp-thumbs__item {
	position: relative;
	flex-shrink: 0;
	width: 4.6875rem;
	height: 6.25rem;
	padding: 0;
	border: none;
	background: transparent;
	cursor: pointer;
	transition: opacity var(--ease-button);
}
.pdp-thumbs__item:hover { opacity: 0.7; }
.pdp-thumbs__img { display: block; width: 100%; height: 100%; object-fit: contain; }

/* ---------- Details ---------- */
.pdp-info {
	position: sticky;
	top: 0;
	align-self: flex-start;
	flex: 1 1 auto;
	min-width: 0;
	padding: 4.25rem 2.5rem 4.25rem 2.5rem;
	color: var(--white);
}

.pdp-back {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	height: 1.25rem;
	color: var(--white);
	text-decoration: none;
	font-family: var(--font-display);
	font-size: 1rem;
	font-weight: 900;
	letter-spacing: 0.08px;
	text-transform: uppercase;
	transition: opacity var(--ease-button);
}
.pdp-back:hover { opacity: 0.7; }
.pdp-back svg { width: 0.625rem; height: 1rem; }
.pdp-back span { text-box: trim-both cap alphabetic; }

.pdp-title {
	margin: 1.375rem 0 0.75rem;
	font-family: var(--font-body);
	font-size: 1.625rem;
	font-weight: 400;
	line-height: 2rem;
	letter-spacing: 0.15px;
	text-transform: uppercase;
	color: var(--white);
}

.pdp-desc {
	font-family: var(--font-body);
	font-size: 0.9375rem;
	line-height: 1.375rem;
	letter-spacing: 0.15px;
	text-transform: uppercase;
	color: var(--white);
}
.pdp-desc p,
.pdp-desc ul,
.pdp-desc ol { margin: 0 0 0.75rem; }
.pdp-desc ul,
.pdp-desc ol { padding-left: 1.25rem; }
.pdp-desc li { margin: 0; }
.pdp-desc > :last-child { margin-bottom: 0; }
.pdp-desc a { color: inherit; }

.pdp-price {
	justify-content: flex-start;
	margin-top: 1rem;
	gap: 0.375rem;
}
.pdp-price .price__cur,
.pdp-price .price__now,
.pdp-price .price__was {
	font-size: 1.5rem;
	line-height: 1.5rem;
	letter-spacing: 0.5px;
}
.pdp-price .price__cur { min-width: 0; }

.pdp-notices:empty { display: none; }
.pdp-notices { margin-top: 1rem; font-size: 0.875rem; }
.pdp-notices ul { list-style: none; margin: 0; padding: 0; }
.pdp-notices .woocommerce-error { color: #ff6b5c; }
.pdp-notices a { color: inherit; }
.pdp-notices .button { display: none; }

.pdp-form { margin-top: 1.75rem; }

/* ---------- Options (colour / size stars) ---------- */
.pdp-opt {
	margin: 0 0 1.625rem;
	padding: 0;
	border: 0;
	min-width: 0;
	width: fit-content;
}
.pdp-opt__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	margin-bottom: 0.5rem;
}
.pdp-opt__label {
	float: left; /* lets legend sit in the flex row */
	padding: 0;
	color: var(--white);
	font-family: var(--font-body);
	font-size: 1rem;
	line-height: 1.25rem;
	letter-spacing: 0.08px;
	text-transform: uppercase;
}
.pdp-opt__guide {
	color: var(--white);
	font-family: var(--font-display);
	font-size: 1rem;
	font-weight: 900;
	letter-spacing: 0.08px;
	text-transform: uppercase;
	text-decoration: none;
	transition: opacity var(--ease-button);
}
.pdp-opt__guide:hover { opacity: 0.7; }

.pdp-opt__stars {
	clear: both;
	display: flex;
	flex-wrap: wrap;
	gap: 0.375rem;
}

.star {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.625rem;
	height: 2.625rem;
	cursor: pointer;
	transition: opacity var(--ease-button), transform 150ms ease;
}
.star__svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.star__shape {
	fill: transparent;
	stroke: var(--white);
	stroke-width: 1.3;
	transition: fill 150ms ease, stroke 150ms ease;
}
.star__text {
	position: relative;
	top: 0.12rem;
	font-family: var(--font-display);
	font-size: 0.625rem;
	font-weight: 900;
	line-height: 1;
	letter-spacing: 0.2px;
	text-transform: uppercase;
	color: var(--white);
	transition: color 150ms ease;
	pointer-events: none;
}
.star__text--long { font-size: 0.5rem; }

/* Size: selected star fills white. */
.star--size:hover .star__shape,
.star--option:hover .star__shape { fill: rgba(255, 255, 255, 0.15); }
.star--size:has(.star__input:checked) .star__shape,
.star--option:has(.star__input:checked) .star__shape { fill: var(--white); }
.star--size:has(.star__input:checked) .star__text,
.star--option:has(.star__input:checked) .star__text { color: var(--bg); }

/* Colour: star filled with the swatch; unselected outline is grey. */
.star--color .star__shape { fill: var(--swatch, var(--bg)); stroke: var(--grey-badge); }
.star--color:hover .star__shape { stroke: var(--white); }
.star--color:has(.star__input:checked) .star__shape { stroke: var(--white); stroke-width: 1.6; }

/* Not available for the current selection */
.star.is-unavailable { opacity: 0.5; cursor: not-allowed; }
.star.is-unavailable::after {
	content: "";
	position: absolute;
	left: 18%;
	right: 18%;
	top: 52%;
	border-top: 1px solid var(--white);
	transform: rotate(-35deg);
	pointer-events: none;
}
.star:has(.star__input:focus-visible) { outline: 2px solid var(--pink); outline-offset: 2px; border-radius: 4px; }

/* ---------- Add to bag ---------- */
.pdp-cta {
	display: flex;
	flex-direction: column;
	align-items: center;
	align-self: flex-start;
	margin-top: 2.5rem;
	padding: 0;
	background: none;
	border: none;
	cursor: pointer;
}
.pdp-cta__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	width: fit-content;
	transition: opacity 0.2s ease;
}
.pdp-cta:hover:not(:disabled) .pdp-cta__inner { opacity: 0.7; }
.pdp-cta:disabled { cursor: not-allowed; }
.pdp-cta.is-incomplete { cursor: default; }
.pdp-cta__text {
	padding: 0 0.8125rem;
	color: var(--white);
	font-family: var(--font-display);
	font-size: 2.5rem;
	font-weight: 900;
	line-height: 3rem;
	letter-spacing: 0.2px;
	text-transform: uppercase;
	white-space: nowrap;
}
.pdp-cta__line { display: block; width: 100%; height: 0.375rem; margin-top: 0; }

.pdp-msg { min-height: 1.25rem; margin-top: 0.75rem; font-size: 0.875rem; text-transform: uppercase; letter-spacing: 0.15px; }
.pdp-msg.is-error { color: #ff6b5c; }

/* ==========================================================================
   ≤ 960px: no thumb rail, header back in flow
   ========================================================================== */
@media (max-width: 960px) {
	.pdp-thumbs { display: none; }
	.pdp-gallery { flex-basis: 50vw; width: 50vw; }
}

/* ==========================================================================
   ≤ 600px: swipe carousel on top, details below, fixed add-to-bag bar
   ========================================================================== */
@media (max-width: 600px) {
	.pdp { flex-direction: column; }

	.pdp-gallery {
		flex: none;
		width: 100%;
		/* 3:4, but short enough that the title + price show above the fixed add-to-bag bar. */
		height: min(133.33vw, calc(100svh - 380px));
		min-height: 300px;
	}
	.pdp-gallery__track {
		flex-direction: row;
		width: 100%;
		height: 100%;
		overflow-x: auto;
		overflow-y: hidden;
		scroll-snap-type: x mandatory;
		scrollbar-width: none;
		overscroll-behavior-x: contain;
	}
	.pdp-gallery__track::-webkit-scrollbar { display: none; }
	.pdp-gallery__set { flex-direction: row; height: 100%; }
	.pdp-gallery__set[aria-hidden="true"] { display: none; }
	.pdp-gallery__slot {
		flex: 0 0 100vw;
		width: 100vw;
		height: 100%;
		min-height: 0;
		scroll-snap-align: start;
	}

	.pdp-gallery__nav {
		position: absolute;
		top: 50%;
		z-index: 1;
		display: flex;
		align-items: center;
		justify-content: center;
		width: 2rem;
		height: 2rem;
		padding: 0;
		background: transparent;
		border: none;
		transform: translateY(-50%);
		cursor: pointer;
	}
	.pdp-gallery__nav svg { width: 1.25rem; height: 1.25rem; }
	.pdp-gallery__nav--prev { left: 1rem; }
	.pdp-gallery__nav--prev svg { transform: rotate(-90deg); }
	.pdp-gallery__nav--next { right: 1rem; }
	.pdp-gallery__nav--next svg { transform: rotate(90deg); }

	.pdp-dots {
		position: absolute;
		left: 0;
		right: 0;
		bottom: 0.75rem;
		z-index: 2;
		display: flex;
		justify-content: center;
		gap: 0;
	}
	/* 24px tap target around an 8px dot. */
	.pdp-dots__dot {
		position: relative;
		width: 1.5rem;
		height: 1.5rem;
		margin: 0 -0.25rem;
		padding: 0;
		border: none;
		background: none;
		cursor: pointer;
	}
	.pdp-dots__dot::before {
		content: "";
		position: absolute;
		inset: 0;
		width: 0.5rem;
		height: 0.5rem;
		margin: auto;
		border-radius: 50%;
		background: var(--grey-tab);
		transition: background 0.2s;
	}
	.pdp-dots__dot.is-active::before { background: var(--white); }

	.pdp-info { position: static; width: 100%; padding: 1.5rem 1rem 9.5rem; }
	.pdp-title { margin-top: 1.25rem; font-size: 1.25rem; line-height: 1.625rem; }
	.pdp-desc { font-size: 0.8125rem; line-height: 1.25rem; }
	.pdp-opt { width: 100%; margin-bottom: 1rem; }

	.pdp-cta {
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		z-index: var(--z-scrollbar);
		align-items: center;
		margin: 0;
		padding: 1rem 1rem calc(1.5rem + env(safe-area-inset-bottom, 0px));
		background: var(--bg);
	}
	.pdp-cta__text { font-size: 2rem; line-height: 2.5rem; }
	.pdp-cta:disabled .pdp-cta__inner { filter: grayscale(100%) brightness(0.5); }
}
