/* El Rey Pata – Catálogo (/tienda/)
 * Se apoya en selector.css (mismo sistema: tokens, botones, hero, cards, badge, listas, toast).
 */

/* Secciones viejas de la plantilla: ocultas solo en /tienda/ (respaldo del filtro PHP). */
.woocommerce-shop .erp-hide-on-shop { display: none !important; }

body .erp-selector.erp-catalog { background: #fbf8f4; }

/* ---------- Hero compacto ---------- */
body .erp-catalog .erp-hero--compact { padding: 84px 0 88px; min-height: 0; }
body .erp-catalog .erp-hero__eyebrow--red { color: #ff6a5f; }
body .erp-catalog .erp-hero__title { max-width: 620px; }

/* ---------- Secciones ---------- */
body .erp-catalog .erp-cat-section { padding-top: 88px; padding-bottom: 40px; }
body .erp-catalog .erp-cat-section--addons { padding-top: 72px; padding-bottom: 88px; }
body .erp-catalog .erp-head { margin-bottom: 40px; }

/* ---------- Cards de perniles ---------- */
body .erp-catalog .erp-cat-cards { min-height: 0; align-items: stretch; }
body .erp-catalog .erp-cat-card { transition: transform .22s var(--erp-ease), box-shadow .22s var(--erp-ease); }
body .erp-catalog .erp-card__media { display: block; aspect-ratio: 4 / 3; }
body .erp-catalog .erp-card__media img { width: 100%; height: 100%; object-fit: cover; }
body .erp-catalog .erp-card__body { padding: 24px 26px 26px; }
body .erp-catalog .erp-card__title a,
body .erp-catalog .erp-card__title a:visited,
body .erp-catalog .erp-addon__title a,
body .erp-catalog .erp-addon__title a:visited { color: inherit; text-decoration: none; font: inherit; letter-spacing: inherit; }
body .erp-catalog .erp-card__title a:hover,
body .erp-catalog .erp-addon__title a:hover { color: var(--erp-red); }
body .erp-catalog .erp-card__title a:focus-visible,
body .erp-catalog .erp-addon__title a:focus-visible { outline: 3px solid var(--erp-ink); outline-offset: 2px; border-radius: 4px; }

@media (hover: hover) {
	body .erp-catalog .erp-cat-card:hover { transform: translateY(-3px); box-shadow: var(--erp-shadow-lg); }
	body .erp-catalog .erp-cat-card.is-featured:hover { box-shadow: 0 0 0 1px var(--erp-red), 0 4px 8px rgba(29, 26, 23, .06), 0 20px 44px rgba(29, 26, 23, .12); }
}

body .erp-catalog .erp-from { margin: 18px 0 20px; }
body .erp-catalog .erp-from__label { font-size: 13px; font-weight: 600; color: var(--erp-muted); margin-bottom: 2px; }
body .erp-catalog .erp-from__row { display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; }
body .erp-catalog .erp-from__qty { font-size: 14px; line-height: 1.2; color: var(--erp-text); padding-bottom: 3px; }
body .erp-catalog .erp-from__qty span { display: block; font-size: 12.5px; color: var(--erp-muted); }
body .erp-catalog .erp-from__qty strong { font-weight: 700; color: var(--erp-ink); }
body .erp-catalog .erp-from__note {
	display: inline-block;
	margin-top: 10px;
	padding: 5px 10px;
	border-radius: 8px;
	background: var(--erp-cream);
	color: var(--erp-text);
	font-size: 13px;
	line-height: 1.3;
}
body .erp-catalog .erp-from__note.is-cold { background: #eef3f8; color: #23415e; }
@media (min-width: 768px) {
	body .erp-catalog .erp-cat-card .erp-card__tagline { min-height: 2.8em; }
}

/* ---------- Puente al selector ---------- */
body .erp-catalog .erp-bridge-wrap { padding-top: 32px; padding-bottom: 8px; }
body .erp-catalog .erp-bridge {
	display: flex;
	align-items: center;
	gap: 32px;
	padding: 30px 40px;
	border-radius: 18px;
	background: var(--erp-cream-2);
	border: 1px solid #ebe1d3;
}
body .erp-catalog .erp-bridge__icon {
	flex: none;
	display: grid;
	place-items: center;
	width: 96px;
	padding-right: 32px;
	border-right: 1px solid #e2d6c6;
	color: var(--erp-red);
}
body .erp-catalog .erp-bridge__icon svg { width: 56px; height: 56px; }
body .erp-catalog .erp-bridge__text { flex: 1 1 auto; }
body .erp-catalog .erp-bridge__title { font-family: var(--erp-head); font-weight: 400; font-size: 28px; line-height: 1.15; color: var(--erp-ink); margin-bottom: 6px; }
body .erp-catalog .erp-bridge__text p { color: var(--erp-text); font-size: 16px; max-width: 420px; }

/* ---------- Complementos ---------- */
body .erp-catalog .erp-addons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
body .erp-catalog .erp-addon {
	display: grid;
	grid-template-columns: minmax(0, 44%) minmax(0, 1fr);
	background: #fff;
	border: 1px solid var(--erp-line);
	border-radius: var(--erp-radius);
	box-shadow: var(--erp-shadow);
	overflow: hidden;
	transition: transform .22s var(--erp-ease), box-shadow .22s var(--erp-ease);
}
@media (hover: hover) {
	body .erp-catalog .erp-addon:hover { transform: translateY(-2px); box-shadow: var(--erp-shadow-lg); }
	body .erp-catalog .erp-addon:hover .erp-addon__media img { transform: scale(1.03); }
}
body .erp-catalog .erp-addon__media { display: block; position: relative; min-height: 100%; background: var(--erp-cream-2); overflow: hidden; }
body .erp-catalog .erp-addon__media img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	transition: transform .6s var(--erp-ease);
}
body .erp-catalog .erp-addon__body { display: flex; flex-direction: column; padding: 24px 24px 22px; min-width: 0; }
body .erp-catalog .erp-addon__title { font-family: var(--erp-head); font-weight: 400; font-size: 22px; line-height: 1.2; color: var(--erp-ink); }
body .erp-catalog .erp-addon__tagline { margin-top: 4px; font-size: 14.5px; color: var(--erp-muted); line-height: 1.4; }
body .erp-catalog .erp-addon__price { margin: 14px 0 14px; display: flex; align-items: baseline; gap: 6px; }
body .erp-catalog .erp-addon__price strong { font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: var(--erp-red); font-variant-numeric: tabular-nums; line-height: 1; }
body .erp-catalog .erp-addon__from { font-size: 13px; font-weight: 600; color: var(--erp-muted); }
body .erp-catalog .erp-list--sm { gap: 7px; margin-bottom: 18px; }
body .erp-catalog .erp-list--sm li { font-size: 14px; }
body .erp-catalog .erp-list--sm .erp-icon { width: 18px; height: 18px; }
body .erp-catalog .erp-addon__opts-label { font-size: 13px; font-weight: 600; color: var(--erp-ink); margin-bottom: 8px; }
body .erp-catalog .erp-chips-list { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
body .erp-catalog .erp-chips-list li {
	padding: 4px 10px;
	border-radius: 999px;
	background: var(--erp-cream);
	border: 1px solid var(--erp-line);
	font-size: 13px;
	line-height: 1.35;
	color: var(--erp-text);
}
body .erp-catalog .erp-chips-list li.is-more { background: transparent; border-style: dashed; color: var(--erp-muted); }
body .erp-catalog .erp-addon__actions { margin-top: auto; }
body .erp-catalog .erp-addon__actions .erp-btn { width: 100%; }

/* ---------- Cotización ---------- */
body .erp-catalog .erp-quote { background: var(--erp-cream-2); border-top: 1px solid #ebe1d3; padding: 40px 0; }
body .erp-catalog .erp-quote__inner { display: flex; align-items: center; gap: 28px; }
body .erp-catalog .erp-quote__icon { flex: none; color: var(--erp-red); }
body .erp-catalog .erp-quote__icon svg { width: 52px; height: 52px; }
body .erp-catalog .erp-quote__text { flex: 1 1 auto; }
body .erp-catalog .erp-quote__title { font-family: var(--erp-head); font-weight: 400; font-size: 26px; line-height: 1.2; color: var(--erp-ink); margin-bottom: 4px; }
body .erp-catalog .erp-quote__text p { font-size: 16px; color: var(--erp-text); }

/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 1024px) {
	body .erp-catalog .erp-cat-section { padding-top: 72px; }
	body .erp-catalog .erp-addons { grid-template-columns: minmax(0, 1fr); max-width: 680px; margin: 0 auto; }
	body .erp-catalog .erp-bridge { padding: 28px 30px; gap: 24px; }
	body .erp-catalog .erp-bridge__icon { width: 80px; padding-right: 24px; }
}

@media (max-width: 767px) {
	body .erp-catalog .erp-hero--compact { padding: 48px 0 52px; }
	body .erp-catalog .erp-cat-section { padding-top: 52px; padding-bottom: 24px; }
	body .erp-catalog .erp-cat-section--addons { padding-top: 52px; padding-bottom: 56px; }
	body .erp-catalog .erp-head { margin-bottom: 28px; }
	body .erp-catalog .erp-card__body { padding: 20px 18px 20px; }

	body .erp-catalog .erp-bridge { flex-direction: column; text-align: center; padding: 28px 20px; gap: 14px; }
	body .erp-catalog .erp-bridge__icon { width: auto; padding: 0; border: 0; }
	body .erp-catalog .erp-bridge__icon svg { width: 48px; height: 48px; }
	body .erp-catalog .erp-bridge__title { font-size: 25px; }
	body .erp-catalog .erp-bridge__text p { margin: 0 auto; }
	body .erp-catalog .erp-bridge .erp-btn { width: 100%; white-space: normal; }

	body .erp-catalog .erp-addon { grid-template-columns: minmax(0, 1fr); }
	body .erp-catalog .erp-addon__media { aspect-ratio: 16 / 10; min-height: 0; }
	body .erp-catalog .erp-addon__body { padding: 20px 18px; }

	body .erp-catalog .erp-quote { padding: 36px 0 40px; }
	body .erp-catalog .erp-quote__inner { flex-direction: column; text-align: center; gap: 12px; }
	body .erp-catalog .erp-quote__title { font-size: 23px; }
	body .erp-catalog .erp-quote .erp-btn { width: 100%; white-space: normal; }
}

/* ---------- Pestañas Entero / Al vacío en las cards (1.5.0) ---------- */
body .erp-catalog .erp-cat-card .erp-ptabs { margin-top: 14px; }
body .erp-catalog .erp-cat-panel { display: flex; flex-direction: column; flex: 1 1 auto; }
body .erp-catalog .erp-cat-panel .erp-card__tagline { margin-top: 12px; }
body .erp-catalog .erp-pill {
	align-self: flex-start;
	margin-top: 10px;
	padding: 4px 10px;
	border-radius: 999px;
	background: var(--erp-red-soft);
	color: var(--erp-red-dark);
	font-size: 12.5px;
	font-weight: 700;
	line-height: 1.3;
}
body .erp-catalog .erp-pill--cold { background: var(--erp-cold-soft); color: var(--erp-cold-dark); }
body .erp-catalog .erp-from { margin-top: 14px; }

/* Card en modo "al vacío": borde y acentos azules, para que se note que va frío. */
body .erp-catalog .erp-cat-card.is-cold,
body .erp-catalog .erp-cat-card.is-featured.is-cold { border-color: var(--erp-cold); box-shadow: 0 0 0 1px var(--erp-cold), 0 10px 28px rgba(47, 95, 138, .14); }
@media (hover: hover) {
	body .erp-catalog .erp-cat-card.is-cold:hover,
	body .erp-catalog .erp-cat-card.is-featured.is-cold:hover { box-shadow: 0 0 0 1px var(--erp-cold), 0 4px 8px rgba(29, 26, 23, .06), 0 20px 44px rgba(47, 95, 138, .18); }
}
body .erp-catalog .erp-cat-card.is-cold .erp-list .erp-icon { background: var(--erp-cold); }
body .erp-catalog .erp-cat-card.is-cold .erp-card__title a:hover { color: var(--erp-cold); }
body .erp-catalog .erp-cat-card.is-cold .erp-card__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(47, 95, 138, 0) 55%, rgba(47, 95, 138, .28));
	pointer-events: none;
}
body .erp-catalog .erp-card__media { position: relative; }
body .erp-catalog .erp-badge--cold { background: var(--erp-cold); text-transform: none; letter-spacing: 0; font-size: 13px; }
body .erp-catalog .erp-ptabs-spacer { height: 50px; margin-top: 14px; }
@media (max-width: 767px) {
	body .erp-catalog .erp-ptabs-spacer { display: none; }
}
