/* El Reino Animal — estética urbana minimal */

:root {
	--er-black: #0e0e0e;
	--er-ink: #1a1a1a;
	--er-grey: #6f6f6b;
	--er-line: #e3e3df;
	--er-paper: #ffffff;
	--er-stone: #f3f3f0;
	--er-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
	--er-text: "Inter", "Helvetica Neue", Arial, sans-serif;
	--er-gutter: clamp(16px, 3.2vw, 40px);
}

/* Base */
body.er {
	background: var(--er-paper);
	color: var(--er-ink);
	font-family: var(--er-text);
	font-size: 15px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
	overflow-x: clip;
}
body.er h1, body.er h2, body.er h3, body.er h4 {
	font-family: var(--er-display);
	font-variation-settings: "wdth" 112;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: var(--er-black);
}
body.er a { color: inherit; text-decoration: none; }
body.er a:focus-visible, body.er button:focus-visible, body.er input:focus-visible { outline: 2px solid var(--er-black); outline-offset: 3px; }
body.er .col-full { max-width: none; padding: 0 var(--er-gutter); margin: 0; box-sizing: border-box; }
body.er .site-content { padding-top: 0; }
body.er #primary { margin-bottom: 0; }

/* Botones */
.er-btn,
body.er .button,
body.er button.button,
body.er .single_add_to_cart_button,
body.er .wc-block-components-button:not(.is-link) {
	display: inline-flex; align-items: center; justify-content: center;
	background: var(--er-black) !important; color: #fff !important;
	border: 1px solid var(--er-black); border-radius: 0 !important;
	font-family: var(--er-text); font-size: 12px; font-weight: 600;
	letter-spacing: 0.14em; text-transform: uppercase;
	padding: 16px 30px; transition: background .2s, color .2s;
}
.er-btn:hover, body.er .button:hover, body.er .single_add_to_cart_button:hover {
	background: #fff !important; color: var(--er-black) !important;
}
.er-link {
	font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
	border-bottom: 1px solid currentColor; padding-bottom: 2px;
}

/* Barra superior */
.er-bar { background: var(--er-black); color: #fff; text-align: center; }
.er-bar p { margin: 0; padding: 9px 16px; font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; }

/* Cabecera */
.er-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--er-line); }
.admin-bar .er-header { top: 32px; }
.er-header__inner {
	display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
	padding: 0 var(--er-gutter); min-height: 72px;
}
.er-nav .er-menu { display: flex; gap: 28px; list-style: none; margin: 0; padding: 0; }
.er-nav a, .er-action {
	font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
	position: relative;
}
.er-nav a::after, .er-action::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px;
	background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.er-nav a:hover::after, .er-action:hover::after, .er-nav .current-menu-item a::after { transform: scaleX(1); }
.er-logo {
	display: flex; flex-direction: column; align-items: center; line-height: .9;
	font-family: var(--er-display); font-variation-settings: "wdth" 125; font-weight: 800;
	font-size: 22px; letter-spacing: 0.04em; text-transform: uppercase;
}
.er-logo span + span { font-size: 22px; }
.er-actions { display: flex; justify-content: flex-end; gap: 24px; }
.er-bag-count {
	display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-left: 4px;
	background: var(--er-black); color: #fff; border-radius: 10px; font-size: 10px; letter-spacing: 0;
}
.er-burger { display: none; background: none; border: 0; padding: 8px; width: 40px; }
.er-burger span:not(.screen-reader-text) { display: block; height: 1.5px; background: var(--er-black); margin: 5px 0; }

.er-search { border-top: 1px solid var(--er-line); padding: 16px var(--er-gutter); }
.er-search form { display: flex; gap: 12px; max-width: 720px; margin: 0 auto; }
.er-search input[type="search"] {
	flex: 1; border: 0; border-bottom: 1px solid var(--er-black); background: transparent;
	font-family: var(--er-display); font-size: 22px; padding: 8px 0; box-shadow: none;
}
.er-search button { background: none; border: 0; font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }

.er-drawer { position: fixed; inset: 0; top: 0; z-index: 60; background: #fff; padding: 96px var(--er-gutter) 32px; overflow-y: auto; }
.er-drawer__menu { list-style: none; margin: 0 0 32px; padding: 0; }
.er-drawer__menu a { display: block; padding: 10px 0; font-family: var(--er-display); font-variation-settings: "wdth" 115; font-weight: 700; font-size: 32px; text-transform: uppercase; border-bottom: 1px solid var(--er-line); }
.er-drawer__menu--small a { font-family: var(--er-text); font-size: 13px; font-weight: 600; letter-spacing: .14em; border: 0; }
body.er-drawer-open { overflow: hidden; }
body.er-drawer-open .er-header { z-index: 70; }

/* Portada: hero */
.er-home { width: 100vw !important; max-width: none !important; float: none !important; margin: 0 0 0 calc(50% - 50vw) !important; }
body.er .site, body.er #page { overflow: visible !important; }
.er-hero { display: grid; grid-template-columns: 1fr 1fr; min-height: min(86vh, 820px); border-bottom: 1px solid var(--er-line); }
.er-hero__text { display: flex; flex-direction: column; justify-content: flex-end; padding: 64px var(--er-gutter); }
.er-kicker { font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--er-grey); margin: 0 0 24px; }
.er-hero__title {
	font-size: clamp(46px, 6.2vw, 104px) !important; line-height: .88 !important; margin: 0 0 32px !important;
	font-variation-settings: "wdth" 125 !important; font-weight: 800 !important; text-transform: uppercase; letter-spacing: -0.035em !important;
}
.er-hero__lead { max-width: 420px; font-size: 16px; color: var(--er-grey); margin: 0 0 32px; }
.er-hero__cta { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.er-hero__media { position: relative; background: var(--er-stone); overflow: hidden; }
.er-hero__img { position: absolute; inset: 0; width: 100%; height: 100% !important; object-fit: cover; }
.er-hero__tag { position: absolute; left: 20px; bottom: 20px; background: #fff; padding: 8px 12px; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }

/* Ticker */
.er-ticker { overflow: hidden; border-bottom: 1px solid var(--er-line); background: var(--er-black); color: #fff; }
.er-ticker__track { display: flex; width: max-content; animation: er-ticker 38s linear infinite; }
.er-ticker__track span {
	padding: 18px 28px; font-family: var(--er-display); font-variation-settings: "wdth" 120; font-weight: 700;
	font-size: 18px; text-transform: uppercase; white-space: nowrap;
}
.er-ticker__track span::after { content: "✕"; margin-left: 56px; font-size: 10px; vertical-align: middle; opacity: .5; }
@keyframes er-ticker { to { transform: translateX(-50%); } }

/* Secciones */
.er-section { padding: clamp(56px, 8vw, 104px) var(--er-gutter) 0; }
.er-section__head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 28px; border-bottom: 1px solid var(--er-black); padding-bottom: 14px; }
.er-h2 { font-size: clamp(28px, 3.4vw, 44px) !important; margin: 0 !important; text-transform: uppercase; font-variation-settings: "wdth" 120 !important; }

/* Categorías */
.er-cats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; background: var(--er-line); border: 2px solid var(--er-line); }
.er-cat { position: relative; display: block; background: #fff; padding-bottom: 20px; }
.er-cat__media { display: block; aspect-ratio: 4 / 5; overflow: hidden; background: var(--er-stone); margin-bottom: 16px; }
.er-cat__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.er-cat:hover .er-cat__media img { transform: scale(1.04); }
.er-cat__n { position: absolute; top: 14px; left: 14px; background: #fff; padding: 4px 8px; font-size: 11px; font-weight: 600; letter-spacing: .1em; }
.er-cat__name { display: block; padding: 0 16px; font-family: var(--er-display); font-variation-settings: "wdth" 118; font-weight: 700; font-size: 22px; text-transform: uppercase; }
.er-cat__desc { display: block; padding: 2px 16px 0; font-size: 13px; color: var(--er-grey); }

/* Rejilla de productos */
body.er ul.products { display: grid !important; grid-template-columns: repeat(4, 1fr); gap: 40px 20px; margin: 0 !important; padding: 0; }
body.er ul.products::before, body.er ul.products::after { display: none !important; }
body.er ul.products li.product {
	width: auto !important; float: none !important; margin: 0 !important; text-align: left !important; position: relative;
}
body.er ul.products li.product a.woocommerce-LoopProduct-link { display: block; position: relative; }
body.er ul.products li.product img {
	aspect-ratio: 4 / 5; object-fit: cover; width: 100%; background: var(--er-stone); margin: 0 0 14px !important;
}
body.er ul.products li.product .er-alt-img {
	position: absolute; top: 0; left: 0; opacity: 0; transition: opacity .35s;
}
body.er ul.products li.product:hover .er-alt-img { opacity: 1; }
.er-loop-cat { display: block; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--er-grey); margin-bottom: 4px; }
body.er ul.products li.product .woocommerce-loop-product__title {
	font-family: var(--er-text) !important; font-variation-settings: normal !important;
	font-size: 14px !important; font-weight: 500 !important; letter-spacing: 0 !important; padding: 0 !important; margin: 0 0 4px !important; color: var(--er-ink);
}
body.er ul.products li.product .price { font-size: 14px; font-weight: 600; color: var(--er-black); margin: 0; }
body.er ul.products li.product .onsale {
	position: absolute; top: 12px; left: 12px; z-index: 2; border: 0; border-radius: 0; background: var(--er-black); color: #fff;
	font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; padding: 5px 8px; min-height: 0; min-width: 0; line-height: 1;
}
body.er ul.products li.product .star-rating { display: none; }

/* Manifiesto */
.er-statement { margin-top: clamp(64px, 9vw, 120px); background: var(--er-black); color: #fff; padding: clamp(56px, 8vw, 112px) var(--er-gutter); }
.er-statement__text {
	max-width: 1100px; margin: 0 0 56px; font-family: var(--er-display); font-variation-settings: "wdth" 112; font-weight: 600;
	font-size: clamp(26px, 3.6vw, 52px); line-height: 1.08; letter-spacing: -0.02em;
}
.er-statement__facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid rgba(255,255,255,.25); }
.er-statement__facts li { padding: 24px 24px 0 0; }
.er-statement__facts strong { display: block; font-family: var(--er-display); font-variation-settings: "wdth" 125; font-size: 36px; font-weight: 800; }
.er-statement__facts span { font-size: 13px; color: rgba(255,255,255,.7); }

/* Pie */
.er-footer { background: var(--er-paper); border-top: 1px solid var(--er-black); padding: 56px var(--er-gutter) 24px; }
.er-footer__claim { font-family: var(--er-display); font-variation-settings: "wdth" 112; font-weight: 600; font-size: 22px; margin: 0 0 48px; max-width: 520px; }
.er-footer__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.er-footer__col h2 { font-family: var(--er-text) !important; font-variation-settings: normal !important; font-size: 11px !important; font-weight: 600 !important; letter-spacing: .16em !important; text-transform: uppercase; color: var(--er-grey) !important; margin: 0 0 16px !important; }
.er-footer__menu, .er-footer .er-menu { list-style: none; margin: 0; padding: 0; display: block !important; }
.er-footer__menu li, .er-footer .er-menu li { margin: 0 0 8px; font-size: 14px; }
.er-footer__menu a:hover { text-decoration: underline; text-underline-offset: 3px; }
.er-footer__wordmark {
	margin: 64px 0 24px; font-family: var(--er-display); font-variation-settings: "wdth" 125; font-weight: 800;
	font-size: calc((100vw - 2 * var(--er-gutter)) / 10.9); line-height: .82; letter-spacing: -0.04em; text-transform: uppercase; white-space: nowrap; overflow: hidden;
}
.er-footer__bottom { display: flex; justify-content: space-between; border-top: 1px solid var(--er-line); padding-top: 16px; font-size: 12px; color: var(--er-grey); }
.er-footer__bottom p { margin: 0; }

/* Páginas internas */
body.er:not(.home) .site-main { padding-top: 48px; padding-bottom: 80px; }
body.er .entry-header .entry-title, body.er .woocommerce-products-header__title, body.er h1.product_title {
	font-size: clamp(32px, 4.6vw, 60px) !important; text-transform: uppercase; font-variation-settings: "wdth" 120 !important; line-height: .95;
}
body.er.page:not(.woocommerce-page) .hentry { max-width: 820px; }
body.er .hentry { border: 0; margin: 0; padding: 0; }
body.er .entry-content h2 { font-size: 22px; margin-top: 40px; text-transform: uppercase; }
body.er .woocommerce-breadcrumb { display: none; }
body.er .woocommerce-result-count { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--er-grey); }
body.er .woocommerce-ordering select { border: 1px solid var(--er-line); border-radius: 0; background: #fff; font-size: 13px; padding: 8px 10px; }
body.er .storefront-sorting { margin-bottom: 32px; padding: 0 0 16px; border-bottom: 1px solid var(--er-line); }

/* Ficha de producto */
body.er.single-product div.product { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(24px, 4vw, 72px); }
body.er.single-product div.product .woocommerce-product-gallery,
body.er.single-product div.product .summary { width: auto !important; float: none !important; margin: 0 !important; }
body.er.single-product div.product .woocommerce-product-gallery img { background: var(--er-stone); }
body.er.single-product div.product .summary { position: sticky; top: 120px; align-self: start; }
body.er.single-product div.product p.price { font-size: 20px; font-weight: 600; color: var(--er-black); }
body.er.single-product .woocommerce-product-details__short-description { color: var(--er-grey); }
body.er.single-product .variations select { border: 1px solid var(--er-black); border-radius: 0; background: #fff; padding: 12px; width: 100%; }
body.er.single-product .quantity .qty { border: 1px solid var(--er-black); border-radius: 0; height: 50px; }
body.er.single-product form.cart { display: flex; gap: 10px; flex-wrap: wrap; }
body.er.single-product form.cart .single_add_to_cart_button { flex: 1; min-height: 50px; }
body.er.single-product .woocommerce-tabs, body.er.single-product .related { grid-column: 1 / -1; }
body.er.single-product .woocommerce-tabs ul.tabs { border-bottom: 1px solid var(--er-black); }
body.er.single-product .woocommerce-tabs ul.tabs li a { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
body.er.single-product .related > h2 { font-size: 28px; text-transform: uppercase; border-bottom: 1px solid var(--er-black); padding-bottom: 14px; }
.er-perks { list-style: none; margin: 24px 0; padding: 16px 0 0; border-top: 1px solid var(--er-line); font-size: 13px; color: var(--er-grey); }
.er-perks li { padding: 4px 0; }
.er-perks li::before { content: "—"; margin-right: 10px; color: var(--er-black); }

/* Carrito y checkout de bloques */
body.er .wc-block-cart, body.er .wc-block-checkout { font-family: var(--er-text); }
body.er .wc-block-components-text-input input, body.er .wc-block-components-combobox .components-combobox-control__input,
body.er .wc-block-components-form .wc-block-components-text-input input { border-radius: 0 !important; border-color: var(--er-line) !important; }
body.er .wc-block-components-sidebar-layout .wc-block-components-sidebar { background: var(--er-stone); padding: 24px; }

/* Responsive */
@media (max-width: 1024px) {
	body.er ul.products, .er-cats { grid-template-columns: repeat(2, 1fr); }
	.er-footer__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
	.er-header__inner { grid-template-columns: auto 1fr auto; min-height: 60px; }
	.er-nav, .er-action--account, .er-action--search { display: none; }
	.er-burger { display: block; }
	.er-logo { font-size: 17px; }
	.er-logo span + span { font-size: 17px; }
	.er-hero { grid-template-columns: 1fr; min-height: 0; }
	.er-hero__media { order: -1; aspect-ratio: 4 / 5; }
	.er-hero__text { padding: 40px var(--er-gutter) 48px; }
	body.er.single-product div.product { grid-template-columns: 1fr; }
	body.er.single-product div.product .summary { position: static; }
	.er-statement__facts { grid-template-columns: 1fr; }
	.admin-bar .er-header { top: 46px; }
}
@media (max-width: 600px) {
	body.er ul.products { gap: 28px 12px; }
	.er-section__head { flex-direction: column; gap: 8px; }
	.er-footer__grid { grid-template-columns: 1fr 1fr; }
	.er-footer__bottom { flex-direction: column; gap: 6px; }
	.admin-bar .er-header { top: 0; }
}
@media (prefers-reduced-motion: reduce) {
	.er-ticker__track { animation: none; }
	.er-cat__media img, .er-alt-img { transition: none; }
}

/* Ficha: el clearfix de Storefront no debe ocupar una celda de la rejilla */
body.er.single-product div.product::before,
body.er.single-product div.product::after { content: none !important; display: none !important; }
body.er.single-product div.product .woocommerce-product-gallery { grid-column: 1; grid-row: 1; }
body.er.single-product div.product .summary { grid-column: 2; grid-row: 1; }
body.er.single-product .woocommerce-product-gallery .flex-control-thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 8px; }
body.er.single-product .woocommerce-product-gallery .flex-control-thumbs li { width: auto !important; margin: 0 !important; }
@media (max-width: 860px) {
	body.er.single-product div.product .summary { grid-column: 1; grid-row: auto; }
}

/* Galería editorial apilada */
body.er.single-product .woocommerce-product-gallery__wrapper { display: grid; gap: 8px; margin: 0; }
body.er.single-product .woocommerce-product-gallery__image { width: 100% !important; margin: 0 !important; }
body.er.single-product .woocommerce-product-gallery__image img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
body.er.single-product .woocommerce-product-gallery__trigger { z-index: 5; }


/* Rejillas: las celdas no deben ensanchar la página en móvil */
.er-cats > *, body.er ul.products > li, .er-footer__grid > * { min-width: 0; }
.er-cat__name, .er-cat__desc { overflow-wrap: anywhere; }
@media (max-width: 600px) { .er-cat__name { font-size: 18px; } }
