/* ==========================================================================
   Oakley México — PDP layer (single-product.php)
   Loaded after site.css / woo.css. Every selector is scoped to the .pdp
   template so the rest of the theme is left untouched.
   ========================================================================== */

/* Breadcrumbs ------------------------------------------------------------- */
.pdp .oakley-breadcrumbs {
	margin: 0 0 26px;
}

.pdp .oakley-breadcrumbs ol {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 10px;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 12px;
	line-height: 1.4;
	color: var(--oo-gray);
}

.pdp .oakley-breadcrumbs li {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}

.pdp .oakley-breadcrumbs li + li::before {
	content: "/";
	color: #c4c4c4;
}

.pdp .oakley-breadcrumbs a {
	color: var(--oo-ink);
	text-decoration: none;
}

.pdp .oakley-breadcrumbs a:hover {
	color: var(--oo-black);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.pdp .oakley-breadcrumbs li[aria-current="page"] {
	color: var(--oo-black);
	font-weight: 600;
}

/* Layout ------------------------------------------------------------------ */
.pdp .pdp__layout {
	align-items: start;
}

/* Gallery: vertical thumbnail rail + square white stage ------------------- */
.pdp__gallery.pdp__gallery--stack {
	display: grid;
	grid-template-columns: 88px minmax(0, 1fr);
	grid-template-rows: auto;
	gap: 12px;
	align-items: start;
}

.pdp__gallery.pdp__gallery--stack .pdp__stage {
	grid-column: 2;
	grid-row: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 1 / 1;
	background: #fff;
	border: 1px solid var(--oo-line-soft);
	overflow: hidden;
}

.pdp__gallery.pdp__gallery--stack .pdp__stage img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	aspect-ratio: auto;
	background: #fff;
}

.pdp__gallery.pdp__gallery--stack .pdp__thumbs {
	grid-column: 1;
	grid-row: 1;
	display: flex;
	flex-direction: column;
	gap: 8px;
	overflow: visible;
}

.pdp__thumb {
	width: 88px;
	height: 88px;
	flex: 0 0 auto;
	padding: 3px;
	border: 1px solid var(--oo-line);
	background: #fff;
	cursor: pointer;
	transition: border-color 0.2s ease;
}

.pdp__thumb:hover {
	border-color: #b9b9b9;
}

.pdp__thumb.is-active {
	border-color: var(--oo-black);
}

.pdp__gallery .pdp__thumb img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	aspect-ratio: auto;
	background: #fff;
}

.pdp__thumb:focus-visible {
	outline: 2px solid var(--oo-black);
	outline-offset: 2px;
}

/* Summary ---------------------------------------------------------------- */
.pdp__summary {
	min-width: 0;
}

.pdp__eyebrow {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0 0 10px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--oo-gray);
}

.pdp__brand {
	color: var(--oo-black);
}

.pdp__collection::before {
	content: "·";
	margin-right: 8px;
	color: #bdbdbd;
}

.pdp__title {
	margin: 0 0 8px;
	line-height: 1.08;
}

.pdp__sku {
	margin: 0 0 10px;
	font-size: 12px;
	letter-spacing: 0.02em;
	color: var(--oo-gray);
}

.pdp__color-name {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 14px;
	font-size: 13px;
	line-height: 1.4;
	color: var(--oo-ink);
}

.pdp__color-prefix {
	color: var(--oo-gray);
}

.pdp [data-pdp-color-name] {
	font-weight: 600;
	color: var(--oo-black);
}

.pdp__price {
	flex-wrap: wrap;
	align-items: baseline;
	margin-bottom: 22px;
}

.pdp__badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 3px 8px;
	border-radius: 2px;
	background: var(--oo-red, #c83430);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.04em;
	line-height: 1.2;
	white-space: nowrap;
}

/* Colour swatches --------------------------------------------------------- */
.pdp__colors {
	margin-bottom: 22px;
}

.pdp__color-list {
	gap: 10px;
}

.pdp__color {
	position: relative;
	width: 44px;
	height: 44px;
	padding: 2px;
	border: 1px solid var(--oo-line);
	border-radius: 50%;
	background: #fff;
	overflow: hidden;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pdp__color:hover {
	border-color: var(--oo-gray);
}

.pdp__color.is-active {
	border-color: var(--oo-black);
	box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--oo-black);
}

.pdp__color:focus-visible {
	outline: 2px solid var(--oo-black);
	outline-offset: 3px;
}

.pdp__gallery .pdp__color img,
.pdp__color img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	aspect-ratio: auto;
	border-radius: 50%;
	background: #fff;
}

.pdp__color-letter {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	border-radius: 50%;
	background: var(--oo-bg-soft, #f6f6f6);
	color: var(--oo-black);
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
}

/* Size chips -------------------------------------------------------------- */
.pdp__sizes-block {
	margin: 0 0 6px;
}

.pdp__sizes {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.pdp__size {
	min-width: 84px;
	min-height: 42px;
	padding: 0 18px;
	border: 1px solid var(--oo-line);
	border-radius: 999px;
	background: #fff;
	color: var(--oo-black);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	line-height: 1;
	text-transform: uppercase;
	cursor: pointer;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.pdp__size:hover {
	border-color: var(--oo-black);
}

.pdp__size.is-active {
	border-color: var(--oo-black);
	background: var(--oo-black);
	color: #fff;
}

.pdp__size:focus-visible {
	outline: 2px solid var(--oo-black);
	outline-offset: 2px;
}

/* Add to cart (native WooCommerce form wrappers) -------------------------- */
.pdp__cta {
	display: block;
	margin: 20px 0 10px;
}

.pdp__cta form.cart {
	display: flex;
	align-items: stretch;
	gap: 10px;
	margin: 0;
}

.pdp__cta form.cart .quantity {
	flex: 0 0 auto;
}

.pdp__cta form.cart .quantity .qty {
	height: 52px;
	width: 72px;
}

.pdp__cta .single_add_to_cart_button {
	flex: 1 1 auto;
	width: auto;
	min-height: 52px;
	height: 52px;
	margin: 0;
}

.pdp__cta .single_add_to_cart_button:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* Variable product: keep the default variation markup, only wrap it. */
.pdp__cta form.cart.variations_form {
	display: block;
}

.pdp__cta form.cart.variations_form .variations {
	width: 100%;
	margin: 0 0 16px;
	border-collapse: collapse;
}

.pdp__cta form.cart.variations_form .variations th,
.pdp__cta form.cart.variations_form .variations td {
	padding: 8px 0;
	text-align: left;
	vertical-align: middle;
}

.pdp__cta form.cart.variations_form .variations td {
	padding-left: 14px;
}

.pdp__cta form.cart.variations_form .variations label {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--oo-ink);
}

.pdp__cta form.cart.variations_form .variations select {
	width: 100%;
	max-width: 340px;
}

.pdp__cta form.cart.variations_form .woocommerce-variation-add-to-cart {
	display: flex;
	align-items: stretch;
	gap: 10px;
	margin-top: 16px;
}

.pdp__cta form.cart.variations_form .woocommerce-variation-add-to-cart .quantity {
	flex: 0 0 auto;
}

.pdp__cta form.cart.variations_form .woocommerce-variation-add-to-cart .single_add_to_cart_button {
	flex: 1 1 auto;
}

.pdp__cta .woocommerce-variation-price {
	margin: 0 0 12px;
	font-size: 20px;
	font-weight: 700;
}

/* Wishlist ---------------------------------------------------------------- */
.pdp__wishlist {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	min-height: 48px;
	margin: 0 0 6px;
	padding: 0 20px;
	border: 1px solid var(--oo-line);
	border-radius: 999px;
	background: #fff;
	color: var(--oo-black);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	line-height: 1;
	text-transform: uppercase;
	cursor: pointer;
	transition: border-color 0.2s ease, background 0.2s ease;
}

.pdp__wishlist svg {
	width: 18px;
	height: 18px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.7;
}

.pdp__wishlist:hover,
.pdp__wishlist.is-active {
	border-color: var(--oo-black);
}

.pdp__wishlist.is-active svg {
	fill: currentColor;
}

.pdp__wishlist:focus-visible {
	outline: 2px solid var(--oo-black);
	outline-offset: 2px;
}

/* Personalizar Ahora ------------------------------------------------------ */
.pdp__customize {
	margin: 16px 0 2px;
	text-align: center;
}

.pdp__customize:empty {
	display: none;
}

.pdp .oakley-customize-cta {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Perks ------------------------------------------------------------------- */
.pdp__perks {
	margin-top: 20px;
	font-size: 13px;
	line-height: 1.5;
}

.pdp__perks li {
	display: flex;
	align-items: flex-start;
	gap: 8px;
}

.pdp__perks li::before {
	flex: 0 0 18px;
}

/* Accordions -------------------------------------------------------------- */
.pdp__accordion {
	margin-top: 26px;
}

.pdp__acc-trigger {
	gap: 12px;
}

.pdp__acc-trigger:focus-visible {
	outline: 2px solid var(--oo-black);
	outline-offset: -2px;
}

.pdp__acc-panel {
	font-size: 14px;
	line-height: 1.65;
}

.pdp__acc-panel p {
	margin: 0 0 12px;
}

.pdp__acc-panel p:last-child {
	margin-bottom: 0;
}

.pdp__acc-panel a {
	color: var(--oo-black);
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Specs table */
.pdp__specs {
	width: 100%;
	border-collapse: collapse;
}

.pdp__specs th,
.pdp__specs td {
	padding: 9px 0;
	border-bottom: 1px solid var(--oo-line-soft);
	text-align: left;
	vertical-align: top;
	font-size: 13px;
	line-height: 1.45;
}

.pdp__specs tr:last-child th,
.pdp__specs tr:last-child td {
	border-bottom: 0;
}

.pdp__specs th {
	width: 44%;
	padding-right: 16px;
	color: var(--oo-gray);
	font-weight: 500;
}

.pdp__specs td {
	color: var(--oo-black);
	font-weight: 600;
}

/* Social share ------------------------------------------------------------ */
.pdp__share {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 18px;
	margin-top: 26px;
	padding-top: 18px;
	border-top: 1px solid var(--oo-line);
}

.pdp__share-label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--oo-gray);
}

.pdp__share-link {
	padding: 0;
	border: 0;
	background: none;
	color: var(--oo-ink);
	font-family: inherit;
	font-size: 12px;
	font-weight: 600;
	line-height: 1.3;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

.pdp__share-link:hover {
	color: var(--oo-black);
}

/* Notices ---------------------------------------------------------------- */
.pdp .woocommerce-notices-wrapper:empty {
	display: none;
}

.pdp .woocommerce-message,
.pdp .woocommerce-info,
.pdp .woocommerce-error {
	margin: 0 0 20px;
}

/* Related products -------------------------------------------------------- */
.pdp__related {
	margin-top: 96px;
}

.pdp__related-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 40px 26px;
}

.pdp__related-grid .prod-tile-wrapper {
	min-width: 0;
}

/* Responsive -------------------------------------------------------------- */
@media (max-width: 1023px) {
	.pdp__gallery.pdp__gallery--stack {
		grid-template-columns: minmax(0, 1fr);
	}

	.pdp__gallery.pdp__gallery--stack .pdp__stage {
		grid-column: 1;
		grid-row: 1;
	}

	.pdp__gallery.pdp__gallery--stack .pdp__thumbs {
		grid-column: 1;
		grid-row: 2;
		flex-direction: row;
		overflow-x: auto;
		padding-bottom: 2px;
	}

	.pdp__thumb {
		width: 76px;
		height: 76px;
	}

	.pdp__related-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.pdp .oakley-breadcrumbs {
		margin-bottom: 18px;
	}

	.pdp .oakley-breadcrumbs ol {
		font-size: 11px;
	}

	.pdp .oakley-breadcrumbs li:not(:first-child):not(:last-child) {
		display: none;
	}

	.pdp__gallery.pdp__gallery--stack {
		gap: 8px;
	}

	.pdp__thumb {
		width: 64px;
		height: 64px;
	}

	.pdp__price {
		margin-bottom: 18px;
	}

	.pdp__cta form.cart {
		flex-wrap: nowrap;
	}

	.pdp__cta .single_add_to_cart_button {
		font-size: 11px;
		letter-spacing: 0.06em;
	}

	.pdp__specs th {
		width: 46%;
	}

	.pdp__related {
		margin-top: 64px;
	}

	.pdp__related-grid {
		gap: 26px 12px;
	}

	.pdp__share {
		gap: 8px 14px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.pdp__color,
	.pdp__size,
	.pdp__thumb,
	.pdp__wishlist,
	.pdp__cta .single_add_to_cart_button {
		transition: none;
	}
}
