/* Bubols · Tienda (widget Catálogo + tarjeta de producto). Spec: diseño.pen "02-Tienda-Desktop" y C/Tarjeta producto. */
.bubols-shop-hero__title { max-width: 860px; }
.bubols-shop-hero__lead { max-width: 760px; }
.bubols-shop-hero__lead p { margin: 0; }
.bubols-shop-hero__search { width: 100%; max-width: 560px; }

/* Category chips */
.bubols-catalog__chips { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 8px; }
.bubols-catalog__chip { display: inline-flex; align-items: center; padding: 8px 16px; border: 1.5px solid #1D2847; border-radius: 999px; background: transparent; font: 800 13px/18px Nunito, system-ui, sans-serif; color: #1D2847; text-decoration: none; transition: background-color .15s; }
.bubols-catalog__chip:hover { background: #FDD743; color: #1D2847; }
.bubols-catalog__chip.is-on,
.bubols-catalog__chip.is-on:hover { background: #1D2847; color: #fff; }
.bubols-catalog__chip:focus-visible,
.bubols-catalog__pill:focus-visible,
.bubols-catalog__check:focus-visible,
.bubols-catalog__clear:focus-visible { outline: 2px solid #1D2847; outline-offset: 2px; }

/* Listing layout */
.bubols-catalog { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 32px; align-items: start; font-family: Nunito, system-ui, sans-serif; color: #1D2847; }
.bubols-catalog *, .bubols-product-row * { box-sizing: border-box; }
.bubols-catalog__toggle-input, .bubols-catalog__toggle { display: none; }

.bubols-catalog__filters { display: flex; flex-direction: column; gap: 20px; padding: 22px; background: #FFFFFF; border: 1.5px solid #E3E7F0; border-radius: 22px; }
.bubols-catalog__filters-title { margin: 0; font: 900 17px/23px Nunito, system-ui, sans-serif; color: #1D2847; }
.bubols-catalog__group { display: flex; flex-direction: column; gap: 9px; min-width: 0; margin: 0; padding: 0; border: 0; }
.bubols-catalog__group + .bubols-catalog__group { padding-top: 20px; border-top: 1.5px solid #E3E7F0; }
.bubols-catalog__group legend { float: left; width: 100%; margin: 0 0 9px; padding: 0; font: 900 12px/16px Nunito, system-ui, sans-serif; letter-spacing: .9px; text-transform: uppercase; color: #5A628A; }
.bubols-catalog__group legend + * { clear: both; }
.bubols-catalog__pills { display: flex; flex-wrap: wrap; gap: 7px; }
.bubols-catalog__pill { padding: 5px 11px; border: 1.5px solid #E3E7F0; border-radius: 999px; background: #fff; font: 800 12px/16px Nunito, system-ui, sans-serif; color: #1D2847; text-decoration: none; }
.bubols-catalog__pill:hover { background: #FDD743; color: #1D2847; }
.bubols-catalog__pill.is-on { background: #FDD743; }
.bubols-catalog__checks { display: flex; flex-direction: column; gap: 8px; }
.bubols-catalog__check { display: flex; align-items: center; gap: 9px; font: 700 13.5px/1.3 Nunito, system-ui, sans-serif; color: #3D476B; text-decoration: none; }
.bubols-catalog__check:hover { color: #1D2847; }
.bubols-catalog__box { display: flex; flex: none; align-items: center; justify-content: center; width: 18px; height: 18px; border: 1.5px solid #C9CEDE; border-radius: 6px; background: #fff; }
.bubols-catalog__check.is-on .bubols-catalog__box { border-color: transparent; background: #7BA32A; color: #fff; }
.bubols-catalog__box svg { width: 12px; height: 12px; stroke-width: 3; }
.bubols-catalog__clear { align-self: flex-start; font: 800 13px/18px Nunito, system-ui, sans-serif; color: #1F408D; text-decoration: underline; }

.bubols-catalog__results { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.bubols-catalog__bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.bubols-catalog__count { margin: 0; font: 700 14.5px/20px Nunito, system-ui, sans-serif; color: #3D476B; }
.bubols-catalog__sort { display: flex; align-items: center; gap: 8px; margin: 0; }
.bubols-catalog__sort span { white-space: nowrap; font: 800 13.5px/18px Nunito, system-ui, sans-serif; color: #5A628A; }
.bubols-catalog__sort select { appearance: none; -webkit-appearance: none; height: auto; margin: 0; padding: 9px 38px 9px 14px; border: 1.5px solid #E3E7F0; border-radius: 12px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231D2847' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 15px; font: 800 13.5px/18px Nunito, system-ui, sans-serif; color: #1D2847; cursor: pointer; }
.bubols-catalog__sort select:focus-visible { outline: 2px solid #1D2847; outline-offset: 2px; }

.bubols-catalog__empty { padding: 48px 24px; text-align: center; background: #FFFFFF; border: 1.5px solid #E3E7F0; border-radius: 22px; }
.bubols-catalog__empty h2 { margin: 0 0 8px; font: 900 21px/1.25 Nunito, system-ui, sans-serif; color: #1D2847; }
.bubols-catalog__empty p { margin: 0 0 16px; font: 600 15px/1.5 Nunito, system-ui, sans-serif; color: #5A628A; }
.bubols-catalog__empty .bubols-catalog__clear { align-self: auto; display: inline-block; }

/* Product grid + card (Tarjeta producto) */
:is(.bubols-catalog, .bubols-product-row) .bubols-products-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.bubols-product-row .bubols-products-grid.columns-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-content: start; align-items: center; gap: 10px; float: none; width: auto; margin: 0; padding: 14px; background: #FFFFFF; border: 1.5px solid #E3E7F0; border-radius: 22px; list-style: none; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__link,
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__body { display: contents; color: inherit; text-decoration: none; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__media { position: relative; grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; height: 250px; overflow: hidden; border-radius: 15px; background: #FDD743; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card:nth-child(5n+2) .bubols-product-card__media { background: #E01950; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card:nth-child(5n+3) .bubols-product-card__media { background: #BECE3C; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card:nth-child(5n+4) .bubols-product-card__media { background: #EB7D30; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card:nth-child(5n) .bubols-product-card__media { background: #60BFD1; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__media img { display: block; width: 100%; height: 100%; margin: 0; object-fit: contain; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__tag { position: absolute; top: 12px; left: 12px; padding: 4px 12px; border-radius: 999px; background: #E01950; font: 900 11.5px/16px Nunito, system-ui, sans-serif; letter-spacing: .5px; color: #fff; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__title { grid-column: 1 / -1; font: 900 16px/1.25 Nunito, system-ui, sans-serif; color: #1D2847; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__link:focus-visible .bubols-product-card__title { outline: 2px solid #1D2847; outline-offset: 2px; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__detail { grid-column: 1 / -1; font: 700 13px/18px Nunito, system-ui, sans-serif; color: #5A628A; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price { display: block; font: 900 19px/26px Nunito, system-ui, sans-serif; color: #1D2847; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price del { font-size: 13px; font-weight: 700; color: #8A8FA3; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price ins { text-decoration: none; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button,
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card .add_to_cart_button { display: inline-flex; align-items: center; justify-content: center; margin: 0; padding: 10px 20px; border: 0; border-radius: 999px; background: #FDD743; font: 900 14px/19px Nunito, system-ui, sans-serif; color: #1D2847; text-decoration: none; white-space: nowrap; transition: filter .15s; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button:hover { filter: brightness(.94); color: #1D2847; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button.loading { opacity: .6; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card .added_to_cart { display: none; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__wishlist { position: absolute; top: 27px; right: 27px; z-index: 2; display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 999px; background: #fff; font-size: 17px; line-height: 1; color: #E01950; cursor: pointer; box-shadow: 0 2px 8px rgba(29, 40, 71, .12); }

/* Pagination */
.bubols-catalog__pager { padding-top: 16px; }
.bubols-catalog__pager ul.page-numbers { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0; padding: 0; list-style: none; }
.bubols-catalog__pager li { margin: 0; }
.bubols-catalog__pager .page-numbers:not(ul) { display: flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 6px; border: 1.5px solid #E3E7F0; border-radius: 12px; background: #fff; font: 800 14px/19px Nunito, system-ui, sans-serif; color: #1D2847; text-decoration: none; }
.bubols-catalog__pager a.page-numbers:hover { background: #FDD743; }
.bubols-catalog__pager .page-numbers.current { border-color: #1D2847; background: #1D2847; color: #fff; }
.bubols-catalog__pager .page-numbers.dots { border-color: transparent; background: none; }

@media (max-width: 1279px) {
	:is(.bubols-catalog, .bubols-product-row) .bubols-products-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1023px) {
	.bubols-catalog { grid-template-columns: minmax(0, 1fr); gap: 16px; }
	.bubols-catalog__toggle { display: inline-flex; align-items: center; gap: 8px; justify-self: start; padding: 10px 20px; border: 1.5px solid #1D2847; border-radius: 999px; font: 900 14px/19px Nunito, system-ui, sans-serif; color: #1D2847; cursor: pointer; }
	.bubols-catalog__toggle svg { width: 16px; height: 16px; }
	.bubols-catalog__toggle-input { position: absolute; display: block; width: 1px; height: 1px; opacity: 0; }
	.bubols-catalog__toggle-input:focus-visible + .bubols-catalog__toggle { outline: 2px solid #1D2847; outline-offset: 2px; }
	.bubols-catalog__filters { display: none; }
	.bubols-catalog__toggle-input:checked ~ .bubols-catalog__filters { display: flex; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-products-grid,
	.bubols-product-row .bubols-products-grid.columns-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
	.bubols-catalog__bar { flex-direction: column; align-items: flex-start; gap: 10px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-products-grid { gap: 12px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card { grid-template-columns: minmax(0, 1fr); padding: 10px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__wishlist { top: 22px; right: 22px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__media { height: 160px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__title { font-size: 14px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price { font-size: 17px; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button { width: 100%; padding: 9px 12px; }
	.bubols-product-row .bubols-products-grid.columns-3 { grid-template-columns: minmax(0, 1fr); }
}

/* Category/tag archives carry body.woocommerce-page, so WooCommerce's layout CSS floats the cards; the grid owns the layout. */
.woocommerce ul.products.bubols-products-grid li.product,
.woocommerce-page ul.products.bubols-products-grid li.product { float: none; clear: none; width: auto; margin: 0; }
.woocommerce ul.products.bubols-products-grid::before,
.woocommerce ul.products.bubols-products-grid::after { content: none; display: none; }

/* Equal-height cards: media, title, detail (flexible), then price + button pinned to the bottom row. */
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card { grid-template-rows: auto auto minmax(0, 1fr) auto; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__media { grid-row: 1; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__title { grid-row: 2; align-self: start; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__detail { grid-row: 3; align-self: start; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price { grid-row: 4; grid-column: 1; align-self: center; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button, :is(.bubols-catalog, .bubols-product-row) .bubols-product-card .add_to_cart_button { grid-row: 4; grid-column: 2; align-self: center; justify-self: end; white-space: nowrap; }
@media (max-width: 767px) {
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card { grid-template-rows: auto auto minmax(0, 1fr) auto auto; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card__price { grid-row: 4; grid-column: 1; }
	:is(.bubols-catalog, .bubols-product-row) .bubols-product-card a.button, :is(.bubols-catalog, .bubols-product-row) .bubols-product-card .add_to_cart_button { grid-row: 5; grid-column: 1; justify-self: stretch; }
}

/* Price and button share the last row: center both vertically (overrides theme/Woo align rules). */
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card .bubols-product-card__price { align-self: center; margin: 0; padding: 0; line-height: 1; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card a.button, :is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card .add_to_cart_button { align-self: center; }
:is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card a.button, :is(.bubols-catalog, .bubols-product-row) .bubols-product-card.bubols-product-card.bubols-product-card .add_to_cart_button { margin: 0; }
