/* Home Redefined Site Kit
   1. Poppins everywhere
   2. Amazon style product gallery
   3. Shop archive image hover
------------------------------------------------------------------ */

:root {
	--hr-teal: #00a19b;
	--hr-ink: #54595f;
	--hr-line: #e3e6e8;
	--hr-font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

/* ---------- 1. Typography ---------- */

body,
button,
input,
select,
optgroup,
textarea,
.entry-content,
.woocommerce-Price-amount,
h1, h2, h3, h4, h5, h6,
.site-title,
.wp-block-button__link,
.button,
.entry-title,
.widget-title,
.kadence-blocks-form .kb-field,
.wc-block-components-product-name {
	font-family: var(--hr-font);
}

h1, h2, h3, h4, h5, h6,
.entry-title {
	font-weight: 600;
	letter-spacing: -0.01em;
}

/* ---------- 2. Single product gallery ---------- */

.hrsk-gallery {
	display: grid;
	grid-template-columns: 72px minmax(0, 1fr);
	gap: 16px;
	align-items: start;
	/* match WooCommerce's div.images column so the summary sits alongside */
	width: 48%;
	float: left;
	margin-bottom: 2em;
}

.hrsk-gallery.hrsk-gallery--empty {
	display: block;
}

.hrsk-gallery__rail {
	display: flex;
	flex-direction: column;
	gap: 8px;
	max-height: 560px;
	overflow-y: auto;
	overflow-x: hidden;
	scrollbar-width: thin;
	padding: 2px;
}

.hrsk-thumb {
	position: relative;
	flex: 0 0 auto;
	width: 64px;
	height: 64px;
	padding: 0;
	border: 1px solid var(--hr-line);
	border-radius: 6px;
	background: #fff;
	cursor: pointer;
	overflow: hidden;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.hrsk-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.hrsk-thumb:hover,
.hrsk-thumb:focus-visible {
	border-color: var(--hr-teal);
	box-shadow: 0 0 0 2px rgba(0, 161, 155, .22);
	outline: none;
}

.hrsk-thumb.is-active {
	border-color: var(--hr-teal);
	box-shadow: 0 0 0 2px rgba(0, 161, 155, .35);
}

.hrsk-thumb__play {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, .38);
	color: #fff;
}

/* Stage */

.hrsk-gallery__stage {
	position: relative;
	min-width: 0;
}

.hrsk-stage__img {
	position: relative;
	width: 100%;
	aspect-ratio: 1 / 1;
	border: 1px solid var(--hr-line);
	border-radius: 10px;
	overflow: hidden;
	background-color: #fff;
	cursor: zoom-in;
}

.hrsk-stage__img img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
	transform-origin: center center;
	transition: transform .18s ease;
	will-change: transform;
}

.hrsk-stage__img.is-zooming img {
	transform: scale(2.2);
	transition: none;
}

.hrsk-zoom-hint {
	position: absolute;
	left: 50%;
	bottom: 10px;
	transform: translateX(-50%);
	font-size: 12px;
	color: #6b7177;
	background: rgba(255, 255, 255, .9);
	padding: 3px 10px;
	border-radius: 999px;
	pointer-events: none;
	transition: opacity .2s ease;
}

.hrsk-stage__img.is-zooming .hrsk-zoom-hint {
	opacity: 0;
}

.hrsk-stage__video {
	position: relative;
	width: 100%;
	aspect-ratio: 1 / 1;
	border: 1px solid var(--hr-line);
	border-radius: 10px;
	overflow: hidden;
	background: #000;
}

.hrsk-stage__video video {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
}

/* Mobile: rail under the image, no zoom */

@media (max-width: 767px) {
	.hrsk-gallery {
		grid-template-columns: minmax(0, 1fr);
	}

	.hrsk-gallery__rail {
		order: 2;
		flex-direction: row;
		max-height: none;
		overflow-x: auto;
		overflow-y: hidden;
		padding-bottom: 4px;
	}

	.hrsk-gallery__stage {
		order: 1;
	}

	.hrsk-gallery {
		width: 100%;
		float: none;
	}

	.hrsk-stage__img {
		cursor: default;
	}

	.hrsk-stage__img.is-zooming img {
		transform: none;
	}

	.hrsk-zoom-hint {
		display: none;
	}
}

/* ---------- 3. Shop archive hover ---------- */

.woocommerce ul.products li.product a img,
.wc-block-grid__product-image img {
	transition: opacity .2s ease;
}

.hrsk-loop-hover {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 8px;
	display: flex;
	justify-content: center;
	opacity: 0;
	transition: opacity .2s ease;
	pointer-events: none;
}

.hrsk-loop-hover__dots {
	display: flex;
	gap: 5px;
	background: rgba(255, 255, 255, .92);
	padding: 5px 9px;
	border-radius: 999px;
	box-shadow: 0 1px 4px rgba(0, 0, 0, .12);
}

.hrsk-loop-hover__dots span {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #c8cdd1;
	transition: background .15s ease;
}

.hrsk-loop-hover__dots span.is-active {
	background: var(--hr-teal);
}

li.product:hover .hrsk-loop-hover,
.wc-block-grid__product:hover .hrsk-loop-hover {
	opacity: 1;
}

li.product,
.wc-block-grid__product {
	position: relative;
}

/* Variation swatches read better than a bare select */

.woocommerce div.product form.cart .variations select {
	font-family: var(--hr-font);
	padding: 10px 12px;
	border-radius: 6px;
	border: 1px solid var(--hr-line);
}

.woocommerce div.product .product_meta {
	font-size: 14px;
}


@media (min-width: 768px) and (max-width: 991px) {
	.hrsk-gallery {
		width: 100%;
		float: none;
	}
}
