/* Portada de Equipos Safari: estilo claro y comercial (foto de panaderia,
   vino de la marca, tarjetas limpias). Se carga solo en la portada
   (ver tienda_base_home_assets()). */

.sf-home {
	--sf-wine: #7a0c0c;
	--sf-wine-dark: #5c0000;
	--sf-gold: #c98d3f;
	--sf-cream: #faf6f0;
	--sf-cream-2: #f3ebdf;
	--sf-text: #231c1a;
	--sf-muted: #6b625d;
	--sf-border: #ece5dc;
	--sf-wa: #25d366;
	--sf-wa-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M16.04 2.67C8.65 2.67 2.67 8.65 2.67 16.03c0 2.5.68 4.85 1.87 6.87L2.5 29.33l6.6-1.98a13.3 13.3 0 0 0 6.94 1.9c7.38 0 13.36-5.98 13.36-13.35 0-3.57-1.39-6.92-3.92-9.44a13.27 13.27 0 0 0-9.44-3.79Zm6.02 16.07c-.33-.16-1.94-.96-2.24-1.06-.3-.11-.52-.16-.74.16-.22.33-.85 1.06-1.04 1.27-.19.22-.38.24-.71.08-.33-.16-1.38-.51-2.63-1.63a9.86 9.86 0 0 1-1.82-2.27c-.19-.33-.02-.5.14-.67.15-.15.33-.38.49-.57.16-.19.22-.33.33-.55.11-.22.05-.41-.03-.57-.08-.16-.74-1.78-1.01-2.44-.27-.64-.54-.55-.74-.56l-.63-.01c-.22 0-.57.08-.87.41-.3.33-1.14 1.11-1.14 2.72s1.17 3.16 1.33 3.38c.16.22 2.3 3.51 5.57 4.92.78.34 1.38.54 1.86.69.78.25 1.49.21 2.05.13.62-.09 1.94-.79 2.21-1.55.27-.77.27-1.42.19-1.55-.08-.14-.3-.22-.63-.38Z'/%3E%3C/svg%3E");
	--sf-radius: 12px;
	--sf-shadow: 0 1px 2px rgba(35, 28, 26, 0.04), 0 8px 24px -12px rgba(35, 28, 26, 0.12);
	--sf-shadow-hover: 0 2px 4px rgba(35, 28, 26, 0.05), 0 22px 44px -18px rgba(35, 28, 26, 0.28);

	color: var(--sf-text);
	overflow-x: clip;
}

/* Los grupos de la portada controlan su propio espaciado (sin blockGap) */
.sf-home :where(.wp-block-group, .wp-block-buttons, .wp-block-cover__inner-container) > * {
	margin-block-start: 0;
}
.sf-home :where(p, h1, h2, h3, ul, figure) {
	margin-block: 0;
}

.sf-wrap {
	box-sizing: border-box;
	width: 100%;
	max-width: 1240px;
	margin-inline: auto;
	padding-inline: clamp(20px, 4vw, 40px);
}

/* ---------- Titulos comunes ---------- */
.sf-kicker,
.sf-hero__kicker {
	font-size: 1.05rem;
	font-weight: 600;
	font-style: italic;
	color: var(--sf-gold);
}
.sf-title {
	font-size: clamp(1.9rem, 3.4vw, 2.75rem);
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: -0.01em;
	color: var(--sf-text);
	text-wrap: balance;
}
.sf-kicker + .sf-title {
	margin-top: 0.4rem;
}
.sf-sub {
	margin-top: 0.85rem !important;
	font-size: 1.1rem;
	line-height: 1.65;
	color: var(--sf-muted);
	max-width: 60ch;
}
.sf-head {
	margin-bottom: clamp(2rem, 4vw, 2.75rem);
}
.sf-head--center {
	text-align: center;
}
.sf-head--center .sf-sub {
	margin-inline: auto;
}
/* Linea de acento bajo los titulos centrados */
.sf-head--center .sf-title::after {
	content: "";
	display: block;
	width: 56px;
	height: 3px;
	margin: 1rem auto 0;
	border-radius: 3px;
	background: var(--sf-wine);
}
.sf-head--row {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1rem 2rem;
	flex-wrap: wrap;
}

/* ---------- Botones ---------- */
.sf-home .sf-btn .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	gap: 0.55em;
	padding: 0.95em 1.6em;
	border: 2px solid transparent;
	border-radius: 8px;
	font-size: 1.02rem;
	font-weight: 600;
	line-height: 1;
	text-decoration: none;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.sf-home .sf-btn .wp-block-button__link:hover {
	transform: translateY(-1px);
}
.sf-home .sf-btn--primary .wp-block-button__link {
	background: var(--sf-wine);
	color: #fff;
}
.sf-home .sf-btn--primary .wp-block-button__link:hover {
	background: var(--sf-wine-dark);
	box-shadow: 0 10px 22px -10px rgba(122, 12, 12, 0.7);
}
.sf-home .sf-btn--light .wp-block-button__link {
	background: #fff;
	color: var(--sf-text);
}
.sf-home .sf-btn--light .wp-block-button__link:hover {
	background: var(--sf-cream);
}
.sf-home .sf-btn--outline .wp-block-button__link {
	background: transparent;
	color: var(--sf-wine);
	border-color: var(--sf-wine);
}
.sf-home .sf-btn--outline .wp-block-button__link:hover {
	background: var(--sf-wine);
	color: #fff;
}
.sf-home .sf-btn--whatsapp .wp-block-button__link {
	background: var(--sf-wa);
	color: #fff;
	font-size: 1.1rem;
	padding: 1.05em 1.8em;
}
.sf-home .sf-btn--whatsapp .wp-block-button__link:hover {
	background: #1eb857;
}
/* Icono de WhatsApp (mascara SVG, toma el color del texto) */
.sf-home .sf-btn--wa .wp-block-button__link::before {
	content: "";
	width: 1.2em;
	height: 1.2em;
	flex-shrink: 0;
	background: currentColor;
	-webkit-mask: var(--sf-wa-icon) center / contain no-repeat;
	mask: var(--sf-wa-icon) center / contain no-repeat;
}
.sf-home .sf-btn--light.sf-btn--wa .wp-block-button__link::before {
	background: #1eb857;
}

/* ---------- Hero (bloque Portada con foto) ---------- */
.sf-home .sf-hero {
	padding: 0;
	align-items: center;
}
/* Degradado para que el texto se lea sobre la foto */
.sf-home .sf-hero .wp-block-cover__background {
	opacity: 1 !important;
	background: linear-gradient(90deg, rgba(28, 12, 8, 0.88) 0%, rgba(28, 12, 8, 0.7) 38%, rgba(28, 12, 8, 0.15) 72%, rgba(28, 12, 8, 0) 100%);
}
.sf-home .sf-hero .wp-block-cover__inner-container {
	width: 100%;
	max-width: none;
	padding-block: clamp(3.5rem, 8vw, 6rem) clamp(5rem, 9vw, 7rem);
}
.sf-hero__content {
	max-width: 600px;
}
.sf-hero__kicker {
	color: #f0c27f;
}
.sf-hero__title {
	margin-top: 0.6rem !important;
	font-size: clamp(2.4rem, 5.2vw, 4rem);
	font-weight: 700;
	line-height: 1.08;
	letter-spacing: -0.015em;
	color: #fff;
	text-wrap: balance;
}
.sf-hero__lead {
	margin-top: 1.25rem !important;
	max-width: 50ch;
	font-size: clamp(1.05rem, 1.4vw, 1.2rem);
	line-height: 1.6;
	color: rgba(255, 255, 255, 0.88);
}
.sf-hero__actions {
	margin-top: 2rem !important;
	gap: 0.75rem;
}
.sf-credit {
	position: absolute;
	right: 12px;
	bottom: calc(3.5rem + 10px);
	font-size: 0.7rem;
	color: rgba(255, 255, 255, 0.55);
}

/* ---------- Beneficios (tarjeta que se monta sobre el hero) ---------- */
.sf-benefits-wrap {
	position: relative;
	z-index: 2;
	margin-top: -3.5rem !important;
}
.sf-benefits {
	list-style: none;
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	margin: 0;
	padding: 0.5rem;
	background: #fff;
	border-radius: var(--sf-radius);
	box-shadow: 0 18px 50px -20px rgba(35, 28, 26, 0.35);
}
.sf-benefits li {
	display: flex;
	align-items: center;
	gap: 0.9rem;
	padding: 1.25rem;
	font-size: 0.92rem;
	line-height: 1.4;
	color: var(--sf-muted);
}
.sf-benefits li + li {
	border-left: 1px solid var(--sf-border);
}
.sf-benefits strong {
	display: block;
	font-size: 1.02rem;
	color: var(--sf-text);
}
.sf-benefits__icon {
	display: grid;
	flex-shrink: 0;
	place-items: center;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	background: #f8eeee;
	color: var(--sf-wine);
}
.sf-benefits__icon svg {
	width: 24px;
	height: 24px;
}

/* ---------- Secciones ---------- */
.sf-section {
	padding-block: clamp(3.5rem, 7vw, 5.5rem);
}
.sf-section--products {
	background: var(--sf-cream);
}

/* Vitrina de categorias (bloque tienda-base/category-showcase) */
.sf-cats {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1.25rem;
}
.sf-cat {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 2rem 1.5rem 1.5rem;
	border: 1px solid var(--sf-border);
	border-radius: var(--sf-radius);
	background: #fff;
	color: var(--sf-text);
	text-align: center;
	text-decoration: none;
	transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.sf-cat:hover {
	transform: translateY(-4px);
	border-color: transparent;
	box-shadow: var(--sf-shadow-hover);
}
.sf-cat__num,
.sf-cat__count {
	display: none;
}
.sf-cat__media {
	display: grid;
	place-items: center;
	width: 100%;
	height: 150px;
	margin-bottom: 1.25rem;
}
.sf-cat__icon {
	display: grid;
	place-items: center;
	width: 120px;
	height: 120px;
	border-radius: 50%;
	background: var(--sf-cream-2);
	color: var(--sf-wine);
	transition: background-color 0.25s ease, color 0.25s ease;
}
.sf-cat:hover .sf-cat__icon {
	background: var(--sf-wine);
	color: #fff;
}
.sf-cat__icon svg {
	width: 54px;
	height: 54px;
}
.sf-cat__img {
	max-width: 100%;
	max-height: 150px;
	object-fit: contain;
	transition: transform 0.3s ease;
}
.sf-cat:hover .sf-cat__img {
	transform: scale(1.05);
}
.sf-cat__body {
	flex: 1;
}
.sf-cat__title {
	display: block;
	font-size: 1.3rem;
	font-weight: 700;
	line-height: 1.2;
}
.sf-cat__desc {
	display: block;
	margin-top: 0.45rem;
	font-size: 0.93rem;
	line-height: 1.5;
	color: var(--sf-muted);
}
.sf-cat__foot {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	margin-top: 1.1rem;
	font-size: 0.95rem;
	font-weight: 600;
	color: var(--sf-wine);
}
.sf-cat__foot::before {
	content: "Ver productos";
}
.sf-cat__arrow {
	display: inline-flex;
	transition: transform 0.25s ease;
}
.sf-cat:hover .sf-cat__arrow {
	transform: translateX(4px);
}
.sf-cat__arrow svg {
	width: 17px;
	height: 17px;
}

/* ---------- Productos destacados ---------- */
.sf-link-all a {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	font-weight: 600;
	color: var(--sf-wine);
	text-decoration: none;
}
.sf-link-all a::after {
	content: "\2192";
	transition: transform 0.25s ease;
}
.sf-link-all a:hover::after {
	transform: translateX(4px);
}

.sf-products .wc-block-product-template {
	gap: 1.25rem !important;
}
.sf-products .catalog-card.sf-card {
	display: flex;
	flex-direction: column;
	padding: 0;
	border: 0;
	border-radius: var(--sf-radius);
	background: #fff;
	box-shadow: var(--sf-shadow);
	overflow: hidden;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.sf-products .catalog-card.sf-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--sf-shadow-hover);
}
.sf-products .sf-card__media {
	padding: 1rem;
	background: #fff;
}
.sf-products .sf-card .wp-block-woocommerce-product-image img {
	background: #fff;
	border-radius: 8px;
	transition: transform 0.35s ease;
}
.sf-products .sf-card:hover .wp-block-woocommerce-product-image img {
	transform: scale(1.04);
}
.sf-products .sf-card img.woocommerce-placeholder {
	background: var(--sf-cream);
}
.sf-products .sf-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 1rem 1.25rem 1.35rem;
	border-top: 1px solid var(--sf-border);
}
.sf-products .sf-card__cat {
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--sf-gold);
}
.sf-products .sf-card__cat a {
	color: inherit;
	text-decoration: none;
}
.sf-products .sf-card__title {
	margin-top: 0.35rem !important;
	font-size: 1.12rem !important;
	font-weight: 600;
	line-height: 1.3;
	text-align: left;
}
.sf-products .sf-card__title a {
	color: var(--sf-text);
}
.sf-products .sf-card__price {
	margin-top: 0.5rem !important;
	margin-bottom: 1.1rem !important;
	font-size: 1.2rem !important;
	font-weight: 700;
	text-align: left;
	color: var(--sf-wine) !important;
}
.sf-products .btn-whatsapp--product {
	margin-top: auto;
	padding: 0.8em 1em;
	border-radius: 8px;
	font-size: 0.98rem;
}

/* ---------- Somos Equipos Safari ---------- */
.sf-about__grid {
	display: grid;
	grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
	align-items: center;
	gap: clamp(2.5rem, 6vw, 5rem);
}
.sf-about__img {
	position: relative;
	isolation: isolate;
}
.sf-about__img img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	border-radius: var(--sf-radius);
	box-shadow: 0 30px 60px -30px rgba(35, 28, 26, 0.45);
}
/* Bloque decorativo vino detras de la foto */
.sf-about__img::before {
	content: "";
	position: absolute;
	z-index: -1;
	left: -18px;
	bottom: -18px;
	width: 55%;
	height: 55%;
	border-radius: var(--sf-radius);
	background: var(--sf-wine);
}
.sf-about__img figcaption {
	position: absolute;
	right: 10px;
	bottom: 8px;
	margin: 0;
	font-size: 0.7rem;
	color: rgba(255, 255, 255, 0.75);
}
.sf-checks {
	list-style: none;
	display: grid;
	gap: 0.9rem;
	margin-top: 1.75rem !important;
	padding: 0;
}
.sf-checks li {
	position: relative;
	padding-left: 2.1rem;
	line-height: 1.55;
	color: var(--sf-muted);
}
.sf-checks li strong {
	color: var(--sf-text);
}
.sf-checks li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.1em;
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 50%;
	background: var(--sf-wine) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 62% no-repeat;
}
.sf-about__actions {
	margin-top: 2rem !important;
	gap: 0.75rem;
}

/* ---------- CTA final ---------- */
.sf-cta {
	background: var(--sf-wine);
	background-image: radial-gradient(80% 140% at 100% 0%, rgba(255, 255, 255, 0.08), transparent 60%);
	color: #fff;
	padding-block: clamp(2.75rem, 5vw, 3.75rem);
}
.sf-cta__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem 3rem;
	flex-wrap: wrap;
}
.sf-cta__title {
	font-size: clamp(1.7rem, 3vw, 2.35rem);
	font-weight: 700;
	line-height: 1.15;
	color: #fff;
}
.sf-cta__text {
	margin-top: 0.5rem !important;
	font-size: 1.1rem;
	color: rgba(255, 255, 255, 0.85);
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
	.sf-cats,
	.sf-benefits {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
	.sf-benefits li:nth-child(3) {
		border-left: 0;
	}
	.sf-benefits li:nth-child(n+3) {
		border-top: 1px solid var(--sf-border);
	}
}
@media (max-width: 860px) {
	.sf-about__grid {
		grid-template-columns: 1fr;
	}
	.sf-about__img {
		max-width: 480px;
	}
	.sf-home .sf-hero .wp-block-cover__background {
		background: linear-gradient(180deg, rgba(28, 12, 8, 0.55) 0%, rgba(28, 12, 8, 0.85) 100%);
	}
}
@media (max-width: 600px) {
	.sf-cats,
	.sf-benefits {
		grid-template-columns: 1fr;
	}
	.sf-benefits li + li {
		border-left: 0;
		border-top: 1px solid var(--sf-border);
	}
	.sf-home .sf-btn,
	.sf-home .sf-btn .wp-block-button__link {
		width: 100%;
		justify-content: center;
	}
	.sf-cta__actions {
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.sf-home *,
	.sf-home *::before,
	.sf-home *::after {
		transition: none !important;
	}
}

/* Sin franja blanca entre el CTA y el pie de pagina */
.wp-site-blocks > footer {
	margin-block-start: 0;
}

/* Destacados: grilla propia (4 / 2 columnas) en lugar del flex de WooCommerce */
.sf-products ul.wc-block-product-template.is-flex-container {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
}
.sf-products ul.wc-block-product-template.is-flex-container > li {
	width: auto !important;
	margin: 0 !important;
}
@media (max-width: 900px) {
	.sf-products ul.wc-block-product-template.is-flex-container {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 0.75rem !important;
	}
	.sf-products .sf-card__media {
		padding: 0.5rem;
	}
	.sf-products .sf-card__body {
		padding: 0.75rem 0.85rem 1rem;
	}
	.sf-products .sf-card__title {
		font-size: 1rem !important;
	}
	.sf-products .btn-whatsapp--product {
		font-size: 0.88rem;
		padding: 0.7em 0.6em;
	}
}

/* Categorias en celular: 2 por fila, compactas */
@media (max-width: 600px) {
	.sf-cats {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 0.75rem;
	}
	.sf-cat {
		padding: 1.1rem 0.75rem 1rem;
	}
	.sf-cat__media {
		height: auto;
		margin-bottom: 0.75rem;
	}
	.sf-cat__icon {
		width: 72px;
		height: 72px;
	}
	.sf-cat__icon svg {
		width: 34px;
		height: 34px;
	}
	.sf-cat__title {
		font-size: 1.05rem;
	}
	.sf-cat__desc {
		display: none;
	}
	.sf-cat__foot {
		margin-top: 0.6rem;
		font-size: 0.85rem;
	}
}
