/*
 * Catalog pages: shop, pet / category / sub-category, brand, Offers and Brands (templates/archive-product.html,
 * taxonomy-product_cat.html, taxonomy-product_brand.html, page-offers.html, page-brands.html; inc/catalog.php).
 * Everything is scoped to main.dolphin-catalog. Logical properties only, so Arabic (RTL) mirrors.
 * Phone first (390px prototypes); the sidebar appears above 782px, WooCommerce's own Product Filters breakpoint.
 */

/* ---------- Page frame ---------- */

/* The shared 1240px content column with its gutters (00-base.css tokens), like the header and footer. */
body .wp-site-blocks > .dolphin-catalog {
	margin-block-start: 0;
}

.dolphin-catalog {
	box-sizing: border-box;
	max-width: var(--dolphin-container, 1288px);
	margin-inline: auto;
	padding: 12px var(--dolphin-gutter, 16px) 56px;
}

.dolphin-catalog > * {
	margin-block: 0;
}

.dolphin-catalog .dolphin-sr-only,
.dolphin-catalog .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.dolphin-catalog a:focus-visible,
.dolphin-catalog button:focus-visible,
.dolphin-catalog select:focus-visible,
.dolphin-catalog input:focus-visible {
	outline: 3px solid var(--wp--preset--color--orange-600);
	outline-offset: 2px;
}

.dolphin-catalog .dolphin-icon {
	flex: none;
	display: block;
}

.dolphin-catalog__notices:empty {
	display: none;
}

/* ---------- Head: breadcrumbs, title, intro ---------- */

.dolphin-catalog__head {
	display: flex;
	flex-direction: column;
	gap: 0;
	padding-block-end: 16px;
}

.dolphin-catalog__head > * {
	margin-block: 0;
}

/* Breadcrumbs: shared .dolphin-breadcrumbs styles (50-pages.css). */

.dolphin-catalog-heading {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 4px 0 0;
}

.dolphin-catalog-heading__title {
	margin: 0;
	font-size: 28px;
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -0.02em;
	color: var(--wp--preset--color--forest);
}

html[lang^="ar"] .dolphin-catalog-heading__title {
	letter-spacing: 0;
}

/* Large heading word in brand orange (24px+ bold passes AA for large text). */
.dolphin-catalog .dolphin-accent {
	color: var(--wp--preset--color--orange);
}

.dolphin-catalog-heading__intro,
.dolphin-catalog-heading__intro p {
	margin: 0;
	max-width: 640px;
	font-size: 15px;
	line-height: 1.6;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog-heading__intro p + p {
	margin-block-start: 8px;
}

/* Brand page head: logo tile + name. */
.dolphin-brand-heading {
	flex-direction: row;
	align-items: center;
	gap: 16px;
}

.dolphin-brand-heading__logo {
	flex: none;
	display: block;
	width: 112px;
	aspect-ratio: 3 / 2;
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--card, 16px);
	background: var(--wp--preset--color--white);
}

.dolphin-brand-heading__logo img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dolphin-brand-heading__text {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}

.dolphin-brand-heading__all {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	min-height: 44px;
	font-size: 14px;
	font-weight: 600;
	color: var(--wp--preset--color--forest);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.dolphin-brand-heading__all:hover {
	color: var(--wp--preset--color--orange-700);
}

/* ---------- Chips (pet pills on the shop, In stock on phones) ---------- */

.dolphin-catalog .dolphin-chip {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding: 0 16px;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--pill, 999px);
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--forest);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	white-space: nowrap;
	text-decoration: none;
}

.dolphin-catalog .dolphin-chip:hover {
	border-color: var(--wp--preset--color--forest);
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-chip.is-active {
	border-color: var(--wp--preset--color--forest);
	background: var(--wp--preset--color--forest);
	color: var(--wp--preset--color--cream);
}

.dolphin-catalog .dolphin-chip.is-active:hover {
	background: var(--wp--preset--color--forest-900);
	color: var(--wp--preset--color--cream);
}

.dolphin-pet-pills {
	margin-block-start: 14px;
}

.dolphin-pet-pills ul {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* ---------- Sub-category circles (Cat Food / Dog Food) ---------- */

.dolphin-subcats {
	margin-block-start: 8px;
}

/* The row scrolls sideways inside the content column (never into the page gutters). */
.dolphin-subcats__list {
	--dolphin-fade-start: 0px;
	--dolphin-fade-end: 0px;
	display: flex;
	gap: 14px;
	margin: 0;
	padding: 12px 10px 8px;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scrollbar-width: none;
	list-style: none;
}

/* assets/js/30-catalog.js marks the side(s) with more tiles; that column edge fades out. */
.dolphin-subcats__list.has-fade-start {
	--dolphin-fade-start: 28px;
}

.dolphin-subcats__list.has-fade-end {
	--dolphin-fade-end: 28px;
}

.dolphin-subcats__list.has-fade-start,
.dolphin-subcats__list.has-fade-end {
	-webkit-mask-image: linear-gradient(to var(--dolphin-fade-dir, right), transparent 0, #000 var(--dolphin-fade-start), #000 calc(100% - var(--dolphin-fade-end)), transparent 100%);
	mask-image: linear-gradient(to var(--dolphin-fade-dir, right), transparent 0, #000 var(--dolphin-fade-start), #000 calc(100% - var(--dolphin-fade-end)), transparent 100%);
}

[dir="rtl"] .dolphin-subcats__list {
	--dolphin-fade-dir: left;
}

.dolphin-subcats__list::-webkit-scrollbar {
	display: none;
}

.dolphin-subcats__list > li {
	display: flex;
	flex: none;
}

.dolphin-subcats__list > li:first-child {
	margin-inline-start: auto;
}

.dolphin-subcats__list > li:last-child {
	margin-inline-end: auto;
}

.dolphin-subcats__tile {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	width: 92px;
	color: var(--wp--preset--color--forest);
	text-decoration: none;
	border-radius: 12px;
}

.dolphin-subcats__art {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	aspect-ratio: 1 / 1;
	border-radius: 50%;
	/* Sand disc behind the owner's bowl photos (between line and cream). */
	background: color-mix(in srgb, var(--wp--preset--color--line) 62%, var(--wp--preset--color--cream));
	color: var(--wp--preset--color--orange);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.dolphin-subcats__art img {
	display: block;
	width: 82%;
	height: 82%;
	object-fit: contain;
}

.dolphin-subcats__label {
	font-size: 13px;
	font-weight: 600;
	line-height: 1.3;
	text-align: center;
}

.dolphin-subcats__tile.is-current .dolphin-subcats__art {
	box-shadow: 0 0 0 4px var(--wp--preset--color--cream), 0 0 0 8px var(--wp--preset--color--orange-600);
}

.dolphin-subcats__tile.is-current .dolphin-subcats__label {
	color: var(--wp--preset--color--orange-700);
	font-weight: 700;
}

@media (hover: hover) {
	.dolphin-subcats__tile:hover .dolphin-subcats__art {
		transform: scale(1.04);
	}

	.dolphin-subcats__tile:hover .dolphin-subcats__label {
		color: var(--wp--preset--color--orange-700);
	}
}

/* ---------- Listing layout ---------- */

.dolphin-catalog .dolphin-listing,
.dolphin-catalog .dolphin-listing > .dolphin-listing__layout {
	margin-block: 0;
}

.dolphin-listing__layout {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.dolphin-listing__layout > *,
.dolphin-listing__main > * {
	margin-block: 0;
}

.dolphin-listing__aside,
.dolphin-listing__main {
	min-width: 0;
}

.dolphin-listing__toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 16px;
	margin-block-end: 16px;
}

.dolphin-listing__toolbar > * {
	margin: 0;
}

.dolphin-catalog .dolphin-results-count {
	margin: 0;
	font-size: 14px;
	line-height: 1.4;
	color: var(--wp--preset--color--muted);
}

/* Sort: "Sort by | Best selling ▾" in one outlined box. */
.dolphin-catalog .dolphin-sort {
	margin: 0;
	font-size: inherit;
}

.dolphin-catalog .dolphin-sort .woocommerce-ordering {
	position: relative;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	gap: 4px;
	height: 48px;
	margin: 0;
	padding-inline-start: 14px;
	border: 1.5px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--control, 12px);
	background: var(--wp--preset--color--white);
}

.dolphin-catalog .dolphin-sort .woocommerce-ordering:focus-within {
	border-color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-sort label {
	margin: 0;
	font-size: 13px;
	font-weight: 400;
	color: var(--wp--preset--color--muted);
	white-space: nowrap;
	cursor: pointer;
}

.dolphin-catalog .dolphin-sort select.orderby {
	height: 100%;
	margin: 0;
	padding-block: 0;
	padding-inline: 2px 34px;
	border: 0;
	border-radius: var(--wp--custom--radius--control, 12px);
	background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%230F3D32' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
	color: var(--wp--preset--color--forest);
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
}

[dir="rtl"] .dolphin-catalog .dolphin-sort select.orderby,
.rtl .dolphin-catalog .dolphin-sort select.orderby {
	background-position: left 10px center;
}

.dolphin-catalog .dolphin-sort select.orderby:focus-visible {
	outline-offset: -3px;
}

/* ---------- Product cards ---------- */

.dolphin-catalog .dolphin-products.wc-block-product-template {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
	width: 100%;
	max-width: none;
	margin: 0;
	padding: 0;
	list-style: none;
}

.dolphin-catalog .dolphin-products > li.wc-block-product {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	gap: 6px;
	width: auto;
	min-width: 0;
	max-width: none;
	margin: 0;
	padding: 10px;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--card, 16px);
	background: var(--wp--preset--color--white);
	text-align: start;
}

.dolphin-catalog .dolphin-products > li.wc-block-product > * {
	margin: 0;
}

.dolphin-catalog .dolphin-card__image {
	position: relative;
	margin: 0;
	overflow: hidden;
	border-radius: 12px;
	background: var(--wp--preset--color--white);
}

.dolphin-catalog .dolphin-card__image a {
	display: block;
}

.dolphin-catalog .dolphin-card__image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: contain;
}

.dolphin-catalog .dolphin-card__image .wc-block-components-product-sale-badge,
.dolphin-catalog .dolphin-card__badge .wc-block-components-product-sale-badge {
	position: absolute;
	top: 8px;
	inset-inline-start: 8px;
	inset-inline-end: auto;
	z-index: 1;
	margin: 0;
	padding: 3px 9px;
	border: 0;
	border-radius: 999px;
	background: var(--wp--preset--color--orange-600);
	color: var(--wp--preset--color--white);
	font-size: 11px;
	font-weight: 700;
	line-height: 1.5;
	text-transform: none;
	letter-spacing: 0;
}

.dolphin-catalog .dolphin-card__brand {
	font-size: 12px;
	line-height: 1.4;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-card__brand .wp-block-post-terms__separator {
	color: inherit;
}

.dolphin-catalog .dolphin-card__title {
	margin: 0;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	text-align: start;
}

.dolphin-catalog .dolphin-card__title a {
	color: var(--wp--preset--color--forest);
	text-decoration: none;
}

/* Every product card: a taller tap area for the name link (one line is about 19px), 12px more above and below
 * without changing the layout. */
body .dolphin-card__title a {
	position: relative;
	display: block;
}

body .dolphin-card__title a::after {
	content: "";
	position: absolute;
	inset-block: -12px;
	inset-inline: 0;
}

.dolphin-catalog .dolphin-card__title a:hover {
	color: var(--wp--preset--color--orange-700);
}

/* Size line under a card's name ("400 g · 2 kg"), on catalog pages and the homepage's Best sellers. */
body .dolphin-card__sizes {
	display: flex;
	flex-wrap: wrap;
	gap: 0 6px;
	margin: 0;
	font-size: 12px;
	line-height: 1.4;
	color: var(--wp--preset--color--muted);
}

body .dolphin-card__sizes > span + span::before {
	content: "·";
	margin-inline-end: 6px;
}

.dolphin-catalog .dolphin-card__price {
	margin-block-start: auto !important;
	padding-block-start: 4px;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.4;
	text-align: start;
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-card__price .wc-block-components-product-price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0 6px;
	text-align: start;
}

.dolphin-catalog .dolphin-card__price ins {
	order: -1;
	color: var(--wp--preset--color--orange-600);
	text-decoration: none;
}

.dolphin-catalog .dolphin-card__price del {
	font-size: 13px;
	font-weight: 400;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-price-from {
	font-size: 13px;
	font-weight: 400;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-card__button {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 0;
	padding-block-start: 4px;
	text-align: center;
}

.dolphin-catalog .dolphin-card__button .wp-block-button__link {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 44px;
	margin: 0;
	padding: 0 12px;
	border: 2px solid var(--wp--preset--color--orange-600);
	border-radius: var(--wp--custom--radius--pill, 999px);
	background: var(--wp--preset--color--orange-600);
	color: var(--wp--preset--color--white);
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
}

.dolphin-catalog .dolphin-card__button .wp-block-button__link:hover {
	border-color: var(--wp--preset--color--orange-700);
	background: var(--wp--preset--color--orange-700);
	color: var(--wp--preset--color--white);
}

/* Bag icon before "Add to cart" on every product card (CatsMobile.dc.html; listings, Best sellers, related products),
 * not on "Choose size" or out-of-stock buttons. */
body .dolphin-card__button .wp-block-button__link.product_type_simple.add_to_cart_button {
	gap: 6px;
}

body .dolphin-card__button .wp-block-button__link.product_type_simple.add_to_cart_button::before {
	content: "";
	flex: none;
	width: 18px;
	height: 18px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 8h12l-1 12H7z'/%3E%3Cpath d='M9 8a3 3 0 0 1 6 0'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 8h12l-1 12H7z'/%3E%3Cpath d='M9 8a3 3 0 0 1 6 0'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Sizes / flavours (variable products) open the product page: outline button, as in the design. */
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_variable,
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_grouped,
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_external {
	border-color: var(--wp--preset--color--forest);
	background: transparent;
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_variable:hover,
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_grouped:hover,
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_external:hover {
	background: var(--wp--preset--color--cream);
	color: var(--wp--preset--color--forest);
}

/* Out of stock (simple product): quiet outline, still opens the product. */
.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_simple:not(.add_to_cart_button) {
	border-color: var(--wp--preset--color--line);
	background: transparent;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-card__button .wp-block-button__link.product_type_simple:not(.add_to_cart_button):hover {
	border-color: var(--wp--preset--color--muted);
	background: transparent;
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-card__button .added_to_cart {
	font-size: 13px;
	font-weight: 600;
	color: var(--wp--preset--color--forest);
}

/* ---------- Pagination ---------- */

.dolphin-catalog .dolphin-listing .dolphin-pagination {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin: 32px 0 0;
}

.dolphin-catalog .dolphin-listing .dolphin-pagination > *,
.dolphin-catalog .dolphin-listing .dolphin-pagination .wp-block-query-pagination-numbers {
	margin: 0;
}

.dolphin-catalog .dolphin-listing .dolphin-pagination .wp-block-query-pagination-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.dolphin-catalog .dolphin-listing .dolphin-pagination .page-numbers,
.dolphin-catalog .dolphin-listing .dolphin-pagination .wp-block-query-pagination-previous,
.dolphin-catalog .dolphin-listing .dolphin-pagination .wp-block-query-pagination-next {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	height: 44px;
	margin: 0;
	padding: 0 6px;
	border: 1.5px solid var(--wp--preset--color--line);
	border-radius: 999px;
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--forest);
	font-size: 15px;
	font-weight: 600;
	line-height: 1;
	text-decoration: none;
}

.dolphin-catalog .dolphin-listing .dolphin-pagination a:hover {
	border-color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-listing .dolphin-pagination .page-numbers.current {
	border-color: var(--wp--preset--color--forest);
	background: var(--wp--preset--color--forest);
	color: var(--wp--preset--color--cream);
}

.dolphin-catalog .dolphin-listing .dolphin-pagination .page-numbers.dots {
	border-color: transparent;
	background: transparent;
	min-width: 24px;
}

.dolphin-catalog .dolphin-listing .dolphin-pagination [class*="-arrow"] {
	margin: 0;
	font-size: 20px;
	line-height: 1;
}

/* The chevrons (« ») are bidi-mirrored characters, so Arabic pages flip them without any CSS. */

/* ---------- Filters (WooCommerce Product Filters) ---------- */

.dolphin-catalog .dolphin-filters {
	--wc-product-filter-block-spacing: 28px;
	--wc-product-filters-background-color: var(--wp--preset--color--cream);
	--wc-product-filters-text-color: var(--wp--preset--color--forest);
	--wc-product-filter-price-slider: var(--wp--preset--color--forest);
	--wc-product-filter-price-slider-handle: var(--wp--preset--color--white);
	--wc-product-filter-price-slider-handle-border: var(--wp--preset--color--forest);
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	width: 100%;
	font-size: 15px;
	color: var(--wp--preset--color--forest);
}

/* Phone: "Filters" pill that opens WooCommerce's overlay. */
.dolphin-catalog .dolphin-filters .wc-block-product-filters__open-overlay {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding-block: 0;
	padding-inline: 14px 16px;
	border: 1px solid var(--wp--preset--color--forest);
	border-radius: var(--wp--custom--radius--pill, 999px);
	background: var(--wp--preset--color--forest);
	color: var(--wp--preset--color--cream);
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	white-space: nowrap;
	cursor: pointer;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filters__open-overlay span {
	padding: 0;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filters__open-overlay:hover {
	background: var(--wp--preset--color--forest-900);
}

.dolphin-catalog .dolphin-filters .wc-block-product-filters__open-overlay svg {
	width: 18px;
	height: 18px;
	fill: none;
}

/* Phone overlay as a bottom sheet (WooCommerce shows the panel inline above 782px). */
@media (max-width: 782px) {
	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay {
		z-index: 100000;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-dialog {
		inset: auto 0 0 0;
		width: 100%;
		max-height: min(88vh, 100%);
		border-radius: 20px 20px 0 0;
		background: var(--wp--preset--color--cream);
		color: var(--wp--preset--color--forest);
		transform: translateY(100%);
		transition: transform 0.3s ease;
	}

	.dolphin-catalog .dolphin-filters.is-overlay-opened .wc-block-product-filters__overlay-dialog {
		transform: translateY(0);
	}

	.dolphin-catalog .dolphin-filters.is-overlay-opened .wc-block-product-filters__overlay {
		background-color: rgba(15, 61, 50, 0.45);
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-header {
		padding: 8px 8px 0;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__close-overlay {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 44px;
		height: 44px;
		border-radius: 999px;
		color: var(--wp--preset--color--forest);
		cursor: pointer;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__close-overlay:hover {
		background: var(--wp--preset--color--white);
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-content {
		gap: 24px;
		padding: 0 20px 20px;
		overflow-y: auto;
		overscroll-behavior: contain;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-footer {
		padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px));
		border-top: 1px solid var(--wp--preset--color--line);
		box-shadow: none;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__apply {
		min-height: 48px;
		border: 0;
		border-radius: var(--wp--custom--radius--pill, 999px);
		background: var(--wp--preset--color--forest);
		color: var(--wp--preset--color--cream);
		font-family: inherit;
		font-size: 15px;
		font-weight: 600;
		cursor: pointer;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__apply:hover {
		background: var(--wp--preset--color--forest-900);
	}
}

/* Filter groups. */
.dolphin-catalog .dolphin-filter {
	margin: 0;
}

.dolphin-catalog .dolphin-filter__title {
	margin: 0 0 6px;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__items {
	display: flex;
	flex-direction: column;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__label {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 44px;
	margin: 0;
	font-size: 15px;
	cursor: pointer;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__input-wrapper::before {
	display: none;
}

.dolphin-catalog .dolphin-filters input[type="checkbox"].wc-block-product-filter-checkbox-list__input {
	box-sizing: border-box;
	width: 18px;
	height: 18px;
	border: 1.5px solid var(--wp--preset--color--forest);
	border-radius: 4px;
	background: var(--wp--preset--color--white);
}

.dolphin-catalog .dolphin-filters input[type="checkbox"].wc-block-product-filter-checkbox-list__input:checked {
	background: var(--wp--preset--color--forest);
}

.dolphin-catalog .dolphin-filters svg.wc-block-product-filter-checkbox-list__mark {
	width: 18px;
	height: 18px;
	padding: 4px;
	color: var(--wp--preset--color--white);
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__text-wrapper {
	font-size: 15px;
	gap: 4px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__count {
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-checkbox-list__show-more-button {
	min-height: 44px;
	font-size: 14px;
	font-weight: 600;
	color: var(--wp--preset--color--forest);
}

/* Price slider: forest handles and range, roomier inputs. */
.dolphin-catalog .dolphin-filters .wc-block-product-filter-price-slider__range input[type="range"]::-webkit-slider-thumb {
	width: 18px;
	height: 18px;
	margin-top: -8px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-price-slider__range input[type="range"]::-moz-range-thumb {
	width: 18px;
	height: 18px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-price-slider__range input[type="range"]:focus-visible::-webkit-slider-thumb {
	outline: 3px solid var(--wp--preset--color--orange-600);
	outline-offset: 2px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-price-slider .text input[type="text"] {
	box-sizing: border-box;
	max-width: 96px;
	min-height: 44px;
	padding: 8px 10px;
	border: 1.5px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--control, 12px);
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--forest);
	font-family: inherit;
	font-size: 14px;
}

/* Active filters + Clear filters. */
.dolphin-catalog .dolphin-filters .wc-block-product-filter-removable-chips__items {
	gap: 6px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-removable-chips__item {
	min-height: 36px;
	padding: 0 6px 0 12px;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 999px;
	background: var(--wp--preset--color--white);
	font-size: 13px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-removable-chips__remove {
	width: 32px;
	height: 32px;
	justify-content: center;
	border-radius: 999px;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-clear-button .wp-block-button__link {
	min-height: 40px;
	padding: 0 16px;
	border: 1.5px solid var(--wp--preset--color--forest);
	border-radius: 999px;
	background: transparent;
	color: var(--wp--preset--color--forest);
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
}

.dolphin-catalog .dolphin-filters .wc-block-product-filter-clear-button :where(.wp-block-buttons) {
	margin-top: 10px;
}

/* ---------- Empty states ---------- */

.dolphin-catalog .wp-block-woocommerce-product-collection-no-results {
	margin: 0;
}

.dolphin-catalog-empty {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	margin: 8px 0 0;
	padding: 40px 20px;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--card, 16px);
	background: var(--wp--preset--color--white);
	text-align: center;
}

.dolphin-catalog-empty > * {
	margin: 0;
}

.dolphin-catalog-empty__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 72px;
	height: 72px;
	margin-block-end: 6px;
	border-radius: 50%;
	background: var(--wp--preset--color--orange-50);
	color: var(--wp--preset--color--orange-600);
}

.dolphin-catalog-empty__title {
	margin: 0;
	font-size: 22px;
	font-weight: 700;
	line-height: 1.25;
	color: var(--wp--preset--color--forest);
}

.dolphin-catalog-empty__text {
	max-width: 440px;
	margin: 0;
	font-size: 15px;
	line-height: 1.6;
	color: var(--wp--preset--color--muted);
}

.dolphin-catalog .dolphin-catalog-empty__whatsapp {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 48px;
	margin-block-start: 8px;
	padding: 0 22px;
	border-radius: var(--wp--custom--radius--pill, 999px);
	background: var(--wp--preset--color--sage-700);
	color: var(--wp--preset--color--white);
	font-size: 15px;
	font-weight: 600;
	text-decoration: none;
}

.dolphin-catalog .dolphin-catalog-empty__whatsapp:hover {
	background: var(--wp--preset--color--forest);
	color: var(--wp--preset--color--white);
}

/* Store empty vs. filters matched nothing (the body class only depends on the page, not on the filters). */
.dolphin-catalog-empty--store {
	display: none;
}

.dolphin-empty-catalog .dolphin-catalog-empty--store {
	display: flex;
}

.dolphin-empty-catalog .dolphin-catalog-empty--filtered {
	display: none;
}

/*
 * Empty listing (launch day): no sort, count, pagination or Filters panel. WooCommerce 11.2 still prints the
 * Filters wrapper and its phone "Filter products" button with nothing in it (issue #69085).
 */
.dolphin-empty-catalog .dolphin-listing__aside,
.dolphin-empty-catalog .dolphin-listing__toolbar,
.dolphin-empty-catalog .dolphin-listing .dolphin-pagination,
.dolphin-empty-catalog .dolphin-catalog .wc-block-product-filters,
.dolphin-empty-catalog .dolphin-catalog .dolphin-pet-pills {
	display: none !important;
}

/* Products, but no filter group with a choice (e.g. one product): no empty sidebar or empty phone sheet. */
.dolphin-catalog .dolphin-listing__aside:has(.dolphin-filters--empty),
.dolphin-catalog .dolphin-filters--empty {
	display: none !important;
}

/* ---------- Brands page ---------- */

.dolphin-brand-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
	margin: 4px 0 0;
	padding: 0;
	list-style: none;
}

.dolphin-brand-grid > li {
	display: flex;
	min-width: 0;
	margin: 0;
}

.dolphin-brand-card {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	width: 100%;
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: var(--wp--custom--radius--card, 16px);
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--forest);
	text-decoration: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dolphin-brand-card:hover {
	border-color: var(--wp--preset--color--forest);
	box-shadow: 0 6px 18px rgba(15, 61, 50, 0.08);
	color: var(--wp--preset--color--forest);
}

.dolphin-brand-card__logo {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 3 / 2;
	border-block-end: 1px solid var(--wp--preset--color--line);
	background: var(--wp--preset--color--white);
}

.dolphin-brand-card__logo img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dolphin-brand-card__logo.is-text {
	padding: 12px;
	background: var(--wp--preset--color--sage-50);
}

.dolphin-brand-card__wordmark {
	font-size: 22px;
	font-weight: 800;
	line-height: 1.15;
	text-align: center;
	letter-spacing: -0.01em;
	color: var(--wp--preset--color--forest);
	overflow-wrap: anywhere;
}

.dolphin-brand-card__name {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	min-height: 48px;
	padding: 8px 12px;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
}

.dolphin-brand-card__name .dolphin-icon {
	color: var(--wp--preset--color--orange-600);
	transition: transform 0.2s ease;
}

[dir="rtl"] .dolphin-brand-card__name .dolphin-icon,
.rtl .dolphin-brand-card__name .dolphin-icon {
	transform: scaleX(-1);
}

@media (hover: hover) {
	.dolphin-brand-card:hover .dolphin-brand-card__name .dolphin-icon {
		transform: translateX(3px);
	}

	[dir="rtl"] .dolphin-brand-card:hover .dolphin-brand-card__name .dolphin-icon,
	.rtl .dolphin-brand-card:hover .dolphin-brand-card__name .dolphin-icon {
		transform: scaleX(-1) translateX(3px);
	}
}

/* ---------- Tablet / desktop ---------- */

@media (min-width: 600px) {
	.dolphin-catalog .dolphin-products.wc-block-product-template {
		gap: 16px;
	}

	.dolphin-brand-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 16px;
	}
}

@media (min-width: 783px) {
	.dolphin-catalog {
		padding: 24px var(--dolphin-gutter, 24px) 80px;
	}

	.dolphin-catalog__head {
		margin-block-end: 32px;
		padding-block-end: 32px;
		border-block-end: 1px solid var(--wp--preset--color--line);
	}

	/* The Brands page goes straight from its intro to the logo grid (no rule, as in the design). */
	.dolphin-catalog--brands .dolphin-catalog__head {
		margin-block-end: 24px;
		padding-block-end: 0;
		border-block-end: 0;
	}

	.dolphin-catalog-heading {
		gap: 8px;
		margin-top: 8px;
	}

	.dolphin-catalog-heading__title {
		font-size: 40px;
	}

	.dolphin-catalog-heading__intro,
	.dolphin-catalog-heading__intro p {
		font-size: 16px;
	}

	.dolphin-brand-heading {
		gap: 24px;
	}

	.dolphin-brand-heading__logo {
		width: 180px;
	}

	.dolphin-pet-pills {
		margin-block-start: 20px;
	}

	.dolphin-subcats {
		margin-block-start: 24px;
	}

	.dolphin-subcats__list,
	.dolphin-subcats__list.has-fade-start,
	.dolphin-subcats__list.has-fade-end {
		flex-wrap: wrap;
		justify-content: center;
		gap: 24px 48px;
		margin: 0;
		padding: 12px 8px 4px;
		overflow: visible;
		-webkit-mask-image: none;
		mask-image: none;
	}

	.dolphin-subcats__list:has(> li:nth-child(5)) {
		justify-content: space-between;
		gap: 24px;
	}

	.dolphin-subcats__list > li:first-child,
	.dolphin-subcats__list > li:last-child {
		margin-inline: 0;
	}

	.dolphin-subcats__tile {
		gap: 12px;
		width: 168px;
	}

	.dolphin-subcats__label {
		font-size: 17px;
	}

	/* Sidebar + results. */
	.dolphin-listing__layout {
		display: grid;
		grid-template-columns: 220px minmax(0, 1fr);
		gap: 32px;
		align-items: start;
	}

	.dolphin-empty-catalog .dolphin-listing__layout,
	.dolphin-catalog .dolphin-listing__layout:has(.dolphin-filters--empty) {
		grid-template-columns: minmax(0, 1fr);
	}

	.dolphin-listing__aside {
		padding-block-start: 12px;
	}

	.dolphin-catalog .dolphin-filters {
		display: flex;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		background: transparent;
	}

	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-content {
		gap: 28px;
	}

	/* WooCommerce hides its overlay button here with a :where() rule that the phone styling above outranks. */
	.dolphin-catalog .dolphin-filters .wc-block-product-filters__open-overlay,
	.dolphin-catalog .dolphin-stock-chip {
		display: none;
	}

	.dolphin-listing__toolbar {
		margin-block-end: 20px;
	}

	.dolphin-catalog .dolphin-results-count {
		font-size: 15px;
	}

	.dolphin-catalog .dolphin-products.wc-block-product-template {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 24px;
	}

	.dolphin-catalog .dolphin-products > li.wc-block-product {
		gap: 10px;
		padding: 14px;
		box-shadow: 0 1px 2px rgba(15, 61, 50, 0.06);
	}

	.dolphin-catalog .dolphin-card__title {
		min-height: 2.7em;
		font-size: 16px;
	}

	.dolphin-catalog .dolphin-card__price {
		font-size: 18px;
	}

	.dolphin-catalog .dolphin-card__button .wp-block-button__link {
		font-size: 15px;
	}

	.dolphin-catalog-empty {
		padding: 56px 32px;
	}

	.dolphin-catalog-empty__title {
		font-size: 26px;
	}

	.dolphin-brand-grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 24px;
	}

	.dolphin-brand-card__name {
		min-height: 52px;
		padding: 12px 16px;
		font-size: 16px;
	}

	.dolphin-brand-card__wordmark {
		font-size: 28px;
	}
}

@media (min-width: 1000px) {
	.dolphin-catalog .dolphin-products.wc-block-product-template {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (min-width: 1100px) {
	.dolphin-listing__layout {
		grid-template-columns: 248px minmax(0, 1fr);
		gap: 40px;
	}

	.dolphin-subcats__tile {
		width: 200px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.dolphin-subcats__art,
	.dolphin-brand-card,
	.dolphin-brand-card__name .dolphin-icon,
	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay,
	.dolphin-catalog .dolphin-filters .wc-block-product-filters__overlay-dialog {
		transition: none !important;
	}

	.dolphin-subcats__tile:hover .dolphin-subcats__art {
		transform: none;
	}
}
