/* BUILD-01P: Woo's native single-product DOM inside the shared illustrated store. */
body.single-product .store--product-detail {
	--pd-ink: #513b32;
	--pd-muted: #765f50;
	--pd-line: #ead4bb;
	--pd-coral: #b92c4c;
}
body.single-product .store--product-detail .store-content { container-name: pf-product; container-type: inline-size; }
body.single-product .store--product-detail .view-scrollport { padding-top: 0; }

/* The product has a path and category context instead of catalogue search/sort. */
body.single-product .store--product-detail .product-route {
	display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem;
	min-width: 0; margin: .2rem 0 1rem; border: 1px solid var(--pd-line);
	border-radius: 1rem; background: linear-gradient(180deg,#fffefa,#fff7ec);
	box-shadow: inset 0 .1rem 0 #fff,0 .17rem 0 #ead1b5,0 .32rem .5rem #70482912;
	color: var(--pd-muted); padding: .55rem .7rem; font-size: .875rem; line-height: 1.45;
}
body.single-product .store--product-detail .product-route a { color: #8b3948; font-weight: 800; text-decoration: none; }
body.single-product .store--product-detail .product-route a:hover { text-decoration: underline; text-underline-offset: .2em; }
body.single-product .store--product-detail .product-route a:focus:not(:focus-visible) { outline: none; }
body.single-product .store--product-detail .product-route a:focus-visible { outline: var(--pf-control-focus-ring); outline-offset: 2px; }
body.single-product .store--product-detail .product-route__back {
	display: inline-flex; flex: none; align-items: center; min-height: var(--pf-control-target);
	border: 0; border-radius: 999px; background: transparent; box-shadow: none;
	padding: 4px 0; font-size: var(--pf-control-font);
}
body.single-product .store--product-detail .product-route__back-surface {
	display: inline-flex; align-items: center; gap: .35rem; min-height: var(--pf-control-action-surface);
	border: 1px solid #e5b8a5; border-radius: 999px; background: #fff5e9;
	box-shadow: inset 0 1px 0 #fff,0 2px 0 #e8c9ad; padding: .3rem .65rem;
}
body.single-product .store--product-detail .product-route__back .icon { width: 1rem; height: 1rem; transform: rotate(180deg); }
body.single-product .store--product-detail .product-route__category { display: inline-flex; align-items: center; min-height: var(--pf-control-target); }
body.single-product .store--product-detail .product-route__separator { color: #ae8c70; font-weight: 900; }
body.single-product .store--product-detail .product-route__categories { min-width: 0; overflow-wrap: anywhere; }
body.single-product .store--product-detail .product-route__current { min-width: 0; color: var(--pd-ink); font-weight: 800; overflow-wrap: anywhere; }

/* Native gallery and summary take the two proposed columns when the store has room. */
body.single-product .store--product-detail div.product {
	display: grid; grid-template-columns: minmax(0,1fr); align-items: start;
	gap: 1.25rem; min-width: 0;
}
body.single-product .store--product-detail div.product::before,
body.single-product .store--product-detail div.product::after { display: none; }
body.single-product .store--product-detail div.product > :is(.woocommerce-product-gallery,.summary,.woocommerce-tabs,.related,.upsells) {
	float: none; clear: none; width: 100%; min-width: 0; margin: 0;
}
body.single-product .store--product-detail div.product > :is(.woocommerce-tabs,.related,.upsells) { grid-column: 1 / -1; }
body.single-product .store--product-detail div.product > .onsale { z-index: 2; }
@container pf-product (min-width: 48rem) {
	body.single-product .store--product-detail div.product { grid-template-columns: minmax(0,1.04fr) minmax(0,1fr); gap: clamp(1.25rem,2.5cqi,2rem); }
	body.single-product .store--product-detail div.product > .woocommerce-product-gallery { grid-column: 1; }
	body.single-product .store--product-detail div.product > .summary { grid-column: 2; }
}

/* Woo owns image IDs, media markup, gallery controls and variation image updates. */
body.single-product .store--product-detail div.product div.images {
	position: relative; overflow: hidden; border: 1px solid #f0d7b8;
	border-radius: 1.375rem; background: radial-gradient(ellipse at 50% 38%,#fffaf2 20%,#ffe7cf 100%);
	box-shadow: inset 0 .1rem 0 #fff,0 .18rem 0 #e8cbb0,0 .4rem .7rem #70482917;
	padding: clamp(.75rem,2cqi,1.25rem);
}
body.single-product .store--product-detail div.product div.images .woocommerce-product-gallery__wrapper { min-width: 0; }
body.single-product .store--product-detail div.product div.images .woocommerce-product-gallery__image { display: grid; place-items: center; min-width: 0; aspect-ratio: 1.05; }
body.single-product .store--product-detail div.product div.images .woocommerce-product-gallery__image a { display: grid; place-items: center; width: 100%; height: 100%; }
body.single-product .store--product-detail div.product div.images .woocommerce-product-gallery__image img {
	display: block; width: 100%; max-width: 100%; height: 100%; max-height: 32rem;
	margin: 0; border-radius: .875rem; object-fit: contain;
}
body.single-product .store--product-detail div.product div.images .woocommerce-product-gallery__trigger {
	top: 1rem; right: 1rem; border: 1px solid #e7c5a7; background: #fffaf2;
	box-shadow: 0 .15rem .35rem #70482922;
}
body.single-product .store--product-detail div.product div.images .flex-control-thumbs {
	display: flex; flex-wrap: wrap; gap: .5rem; margin: .75rem 0 0; padding: 0; list-style: none;
}
body.single-product .store--product-detail div.product div.images .flex-control-thumbs li {
	float: none; width: 4.5rem; height: 4.5rem; margin: 0; border: 1px solid var(--pd-line);
	border-radius: .75rem; background: #fff; padding: .25rem; overflow: hidden;
}
body.single-product .store--product-detail div.product div.images .flex-control-thumbs li:has(img.flex-active) { border: 2px solid var(--pd-coral); }
body.single-product .store--product-detail div.product div.images .flex-control-thumbs img { width: 100%; height: 100%; object-fit: contain; }
body.single-product .store--product-detail div.product div.images :is(a,button,img):focus-visible { outline: var(--pf-control-focus-ring); outline-offset: 2px; }

/* The purchase summary keeps the confirmed title, price, copy and native form order. */
body.single-product .store--product-detail div.product > .summary {
	border: 1px solid var(--pd-line); border-radius: 1.375rem;
	background: linear-gradient(180deg,#fffefa,#fffaf4);
	box-shadow: inset 0 .1rem 0 #fff,0 .18rem 0 #e8cbb0,0 .4rem .7rem #70482912;
	padding: clamp(1rem,2cqi,1.5rem); overflow-wrap: anywhere;
}
body.single-product .store--product-detail div.product .product_title {
	margin: 0 0 .5rem; color: #8b3948; font-size: clamp(1.5rem,1.25rem + .6vw,2rem);
	font-weight: 900; line-height: 1.3; overflow-wrap: anywhere;
}
body.single-product .store--product-detail div.product .summary .price-main {
	margin: .375rem 0 .625rem; color: var(--pd-coral); font-size: clamp(1.5rem,2vw,1.875rem); font-weight: 900;
}
body.single-product .store--product-detail div.product .summary .price-main :is(p.price,span.price) {
	margin: 0; color: inherit; font-size: inherit; font-weight: inherit; line-height: inherit;
}
body.single-product .store--product-detail div.product .summary .woocommerce-variation-price .price-main { margin: .375rem 0; }
body.single-product .store--product-detail div.product .woocommerce-product-details__short-description {
	color: var(--pd-muted); font-size: 1rem; line-height: 1.7; overflow-wrap: anywhere;
}
body.single-product .store--product-detail div.product .woocommerce-product-details__short-description > :first-child { margin-top: 0; }
body.single-product .store--product-detail div.product .woocommerce-product-details__short-description :last-child { margin-bottom: 0; }
body.single-product .store--product-detail div.product .stock {
	display: inline-flex; align-items: center; max-width: 100%; margin: .75rem 0;
	border: 1px solid #a7d2a4; border-radius: 999px; background: #f1f9ec;
	color: #316f37; padding: .35rem .7rem; font-size: .875rem; font-weight: 800; line-height: 1.4;
}
body.single-product .store--product-detail div.product .stock.out-of-stock { border-color: #e4acaa; background: #fff0ef; color: #9f3a46; }

body.single-product .store--product-detail div.product form.cart { margin: .75rem 0; }
body.single-product .store--product-detail div.product form.cart:not(.variations_form) { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
body.single-product .store--product-detail div.product form.cart:not(.variations_form) > .stock { flex-basis: 100%; }
body.single-product .store--product-detail div.product form.cart .variations { width: 100%; margin: 0 0 .625rem; border: 0; border-spacing: 0; }
body.single-product .store--product-detail div.product form.cart .variations :is(th,td) { border: 0; padding: .4rem .5rem .4rem 0; vertical-align: middle; }
body.single-product .store--product-detail div.product form.cart .variations label { color: var(--pd-ink); font-weight: 800; }
body.single-product .store--product-detail div.product form.cart .variations select {
	width: 100%; min-width: 0; min-height: var(--pf-control-target); border: 1.5px solid #d8b78e;
	border-radius: .875rem; background: linear-gradient(180deg,#fffefa,#fff8ec); color: var(--pd-ink);
	box-shadow: inset 0 1px 0 #fff,0 2px 0 #e9cfab,0 4px 6px #70482910;
	padding: .25rem .75rem; font: inherit;
}
body.single-product .store--product-detail div.product form.cart .variations .reset_variations { display: none; align-items: center; min-height: var(--pf-control-target); margin-top: .25rem; color: #8b3948; font-size: var(--pf-control-font); line-height: 1.25; }
body.single-product .store--product-detail div.product form.cart .variations:has(select option:checked:not([value=""])) .reset_variations { display: inline-flex; }
body.single-product .store--product-detail div.product form.cart .woocommerce-variation-add-to-cart { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
body.single-product .store--product-detail div.product form.cart .quantity { float: none; margin: 0; }
body.single-product .store--product-detail div.product form.cart .quantity input.qty {
	min-height: var(--pf-control-target); border: 1.5px solid #d8b78e; border-radius: .75rem;
	background: linear-gradient(180deg,#fffefa,#fff8ec); color: var(--pd-ink);
	box-shadow: inset 0 1px 0 #fff,0 2px 0 #e9cfab; padding-block: .4rem; font: inherit;
}
body.single-product .store--product-detail div.product form.cart .single_add_to_cart_button {
	float: none; flex: 1 1 9rem; min-width: min(100%,9rem); min-height: var(--pf-control-target); margin: 0; border: 2px solid #fff8e9;
	border-radius: 999px; background: linear-gradient(180deg,#dc3f61,#b92c4c);
	box-shadow: inset 0 1px 0 #ffffff85,0 2px 0 #bd5366;
	color: #fff; padding: .375rem 1rem; font-size: 15px; font-weight: 900; letter-spacing: .015em; line-height: 1.3;
}
body.single-product .store--product-detail div.product form.cart .single_add_to_cart_button:hover:not(:disabled):not(.disabled) { background: linear-gradient(180deg,#c63d59,#a62644); color: #fff; }
body.single-product .store--product-detail div.product form.cart .single_add_to_cart_button:is(:disabled,.disabled,.wc-variation-selection-needed) {
	border-color: #f7ebdf; background: #d79aa4; box-shadow: 0 .16rem 0 #b97f89;
	color: #fff; cursor: not-allowed; opacity: 1;
}
body.single-product .store--product-detail div.product form.cart :is(select,input,button,a):focus:not(:focus-visible) { outline: none; }
body.single-product .store--product-detail div.product form.cart :is(select,input,button,a):focus-visible { outline: var(--pf-control-focus-ring); outline-offset: 3px; }
body.single-product .store--product-detail div.product .product_meta {
	display: block; margin-top: .75rem; border-top: 1px dashed #e8d7c4;
	color: #897665; padding-top: .625rem; font-size: .8125rem; line-height: 1.5;
}
body.single-product .store--product-detail div.product .product_meta > span { display: block; }
body.single-product .store--product-detail div.product .product_meta a { color: #806553; text-decoration-color: #bca18b; }

/* Woo owns tab content, review submission and related-product query. */
body.single-product .store--product-detail div.product > .woocommerce-tabs {
	border: 1px solid var(--pd-line); border-radius: 1.25rem;
	background: linear-gradient(180deg,#fffefa,#fff8ee);
	box-shadow: inset 0 .1rem 0 #fff,0 .18rem 0 #e8cbb0;
	padding: clamp(.875rem,2cqi,1.5rem);
}
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs {
	display: flex; flex-wrap: wrap; gap: .375rem; margin: 0 0 .75rem;
	border-bottom: 1px solid #e5c7a6; padding: 0 .25rem;
}
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs::before,
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs::after { display: none; }
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li {
	float: none; margin: 0; border: 1px solid #e5c7a6; border-bottom: 0;
	border-radius: .75rem .75rem 0 0; background: linear-gradient(180deg,#fff6e9,#ffedd7);
	box-shadow: inset 0 1px 0 #fff,0 .1rem 0 #e5c7a6; padding: 0;
}
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li::before,
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li::after { display: none; content: none; }
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li a {
	display: inline-flex; align-items: center; min-height: 2.75rem;
	color: #704c3b; padding: .5rem .9rem; font-weight: 800; text-decoration: none;
}
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li.active {
	border-color: var(--pd-coral); background: linear-gradient(180deg,#dc3f61,#b92c4c);
	box-shadow: inset 0 1px 0 #ffffff85,0 .16rem 0 #ad5262;
}
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li.active a { color: #fff; }
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs a:focus:not(:focus-visible) { outline: none; }
body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs a:focus-visible { outline: var(--pf-control-focus-ring); outline-offset: 2px; }
body.single-product .store--product-detail div.product .woocommerce-tabs .panel { min-width: 0; margin: 0; padding: .4rem .25rem .75rem; overflow-wrap: anywhere; }
body.single-product .store--product-detail div.product .woocommerce-tabs :is(h2,h3) { color: #8b3948; line-height: 1.3; }
body.single-product .store--product-detail div.product #review_form :is(textarea,input[type="text"],input[type="email"],input[type="url"]) {
	width: 100%; min-width: 0; border: 1.5px solid #d9b996; border-radius: .75rem;
	background: #fffefa; color: var(--pd-ink); padding: .7rem .8rem; font: inherit;
}
body.single-product .store--product-detail div.product #review_form textarea { min-height: 8rem; resize: vertical; }
body.single-product .store--product-detail div.product #review_form p.stars a::before { color: var(--pd-coral); }
body.single-product .store--product-detail div.product #review_form #respond input#submit {
	min-height: 2.75rem; border: 2px solid #fff8e9; border-radius: 999px;
	background: linear-gradient(180deg,#d8385b,#b92c4c);
	box-shadow: inset 0 .1rem 0 #ffffff75,0 .16rem 0 #cb6370,0 .32rem .4rem #75422724;
	color: #fff; padding: .55rem 1.1rem; font-weight: 800;
}
body.single-product .store--product-detail div.product #review_form #respond input#submit:hover { background: linear-gradient(180deg,#c63d59,#a62644); color: #fff; }
body.single-product .store--product-detail div.product #review_form #respond input#submit:focus:not(:focus-visible) { outline: none; }
body.single-product .store--product-detail div.product #review_form #respond input#submit:focus-visible { outline: var(--pf-control-focus-ring); outline-offset: 2px; }
body.single-product .store--product-detail div.product > :is(.related,.upsells) { margin-top: 0; }
body.single-product .store--product-detail div.product > :is(.related,.upsells) > h2 {
	margin: 0 0 .75rem; color: #8b3948; font-size: clamp(1.25rem,1rem + .4vw,1.625rem);
	font-weight: 900; line-height: 1.3;
}

@media (max-width: 600px) {
	body.single-product .store--product-detail .product-route { gap: .25rem .4rem; margin: .1rem 0 .75rem; padding: .45rem .5rem; font-size: .8125rem; }
	body.single-product .store--product-detail .product-route__back { min-height: var(--pf-control-target); }
	body.single-product .store--product-detail div.product { gap: 1rem; }
	body.single-product .store--product-detail div.product div.images .flex-control-thumbs li { width: 3.75rem; height: 3.75rem; }
	body.single-product .store--product-detail div.product > .summary { padding: 1rem; }
	body.single-product .store--product-detail div.product .summary .price-main { font-size: 1.25rem; }
	body.single-product .store--product-detail div.product form.cart .variations :is(th,td) { display: block; width: 100%; padding: .25rem 0; text-align: left; }
	body.single-product .store--product-detail div.product form.cart .single_add_to_cart_button { max-width: 100%; white-space: normal; }
	/* Related uses the shared card; only its narrow purchase row stacks Woo price above the native action. */
	body.single-product .store--product-detail div.product > .related .product-buy-row {
		flex-direction: column; align-items: stretch; flex-wrap: nowrap; gap: .25rem;
	}
	body.single-product .store--product-detail div.product > .related .product-action {
		width: 100%; margin-left: 0; align-items: flex-end;
	}
	body.single-product .store--product-detail div.product > .related :is(.product-name a,.product-tagline) {
		display: block; max-height: none; overflow: visible; -webkit-line-clamp: unset; line-clamp: unset;
	}
	body.single-product .store--product-detail div.product .woocommerce-tabs ul.tabs li a { padding: .5rem .55rem; font-size: .875rem; }
}
