/**
 * 11 — 404 error page (TSK-062).
 *
 * Presentation for the child 404 template (404.php): a numeral hero, a restyled
 * native WooCommerce product-search widget, category quick-link chips, the
 * "Ahora en oferta" section head, and light surface cosmetics for the on-sale
 * cards. Markup is `fm-404__*` BEM; rules are anchored on `body.fm.error404`
 * for a free specificity bump over Storefront/WC, per the cascade strategy in
 * AGENTS.md. Tokens only — canonical set in 01-tokens-header.css.
 *
 * The on-sale products render through the standard `[products]` loop, so their
 * COLUMN layout is Storefront's native `.columns-4` float grid: this partial
 * adds no grid/float/width rules and never touches the `ul.products` !important
 * floor in 05-shop-grid-cart.css (LRN-034/035). Only card SURFACE cosmetics
 * (background/border/radius/padding) live here — no layout, no !important.
 *
 * Last partial in the enqueue chain (inc/assets.php), so it prints after 10.
 *
 * @package futbol-mesa
 */

/* Hero -------------------------------------------------------------------- */

body.fm.error404 .fm-404__hero {
	max-width: var(--content-max);
	margin: 0 auto;
	padding: clamp(40px, 6vw, 72px) var(--content-gutter) clamp(28px, 4vw, 44px);
	text-align: center;
}

body.fm.error404 .fm-404__numeral {
	margin: 0;
	font-family: var(--font-heading);
	font-weight: 900;
	font-size: clamp(4rem, 10vw, 7rem);
	line-height: 1;
	letter-spacing: -0.04em;
	color: var(--color-hairline);
}

body.fm.error404 .fm-404__title {
	margin: 18px 0 0;
	font-family: var(--font-heading);
	font-weight: 900;
	font-size: clamp(1.8rem, 3.5vw, 2.6rem);
	letter-spacing: -0.02em;
	color: var(--color-ink);
}

body.fm.error404 .fm-404__subcopy {
	max-width: 560px;
	margin: 14px auto 0;
	font-size: 1rem;
	line-height: 1.6;
	color: var(--color-muted);
}

/* Product search — restyle the native WC_Widget_Product_Search into a pill ---
   The widget renders <div class="widget woocommerce widget_product_search">
   > <form class="woocommerce-product-search"> with an input[name="s"], a submit
   button and a hidden post_type=product input (all preserved). */

body.fm.error404 .fm-404__search {
	max-width: 620px;
	margin: 28px auto 0;
}

body.fm.error404 .fm-404__search .widget_product_search {
	margin: 0;
	padding: 0;
}

body.fm.error404 .fm-404__search .woocommerce-product-search {
	display: flex;
	gap: 10px;
	align-items: stretch;
}

body.fm.error404 .fm-404__search .woocommerce-product-search .search-field {
	flex: 1 1 auto;
	min-width: 0;
	border: 1px solid var(--color-hairline);
	border-radius: var(--radius-pill);
	padding: 15px 20px 15px 46px;
	font-size: 0.95rem;
	color: var(--color-ink);
	background-color: #fff;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='17' height='17' viewBox='0 0 24 24' fill='none' stroke='%23606060' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cline x1='21' y1='21' x2='16.5' y2='16.5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: left 18px center;
}

body.fm.error404 .fm-404__search .woocommerce-product-search .search-field:focus {
	outline: none;
	border-color: var(--color-terracotta);
}

body.fm.error404 .fm-404__search .woocommerce-product-search button[type="submit"] {
	flex: 0 0 auto;
	border: none;
	border-radius: var(--radius-pill);
	padding: 15px 32px;
	font-family: var(--font-heading);
	font-weight: 800;
	font-size: 0.95rem;
	letter-spacing: 0.02em;
	color: #fff;
	background-color: var(--color-terracotta);
	cursor: pointer;
	transition: background-color var(--transition-base) ease;
}

body.fm.error404 .fm-404__search .woocommerce-product-search button[type="submit"]:hover,
body.fm.error404 .fm-404__search .woocommerce-product-search button[type="submit"]:focus {
	background-color: var(--color-terracotta-hover);
}

/* Category quick-link chips ------------------------------------------------ */

body.fm.error404 .fm-404__chips {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin-top: 20px;
}

body.fm.error404 .fm-404__chip {
	font-family: var(--font-heading);
	font-weight: 700;
	font-size: 0.8rem;
	color: var(--color-body);
	background: #fff;
	border: 1px solid var(--color-hairline);
	border-radius: var(--radius-pill);
	padding: 8px 16px;
	transition: color var(--transition-base) ease, border-color var(--transition-base) ease;
}

body.fm.error404 .fm-404__chip:hover,
body.fm.error404 .fm-404__chip:focus {
	color: var(--color-terracotta);
	border-color: var(--color-terracotta);
}

/* "Ahora en oferta" section ----------------------------------------------- */

body.fm.error404 .fm-404__onsale {
	max-width: var(--content-max);
	margin: 0 auto;
	padding: 0 var(--content-gutter) clamp(48px, 6vw, 80px);
}

body.fm.error404 .fm-404__onsale-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 18px;
}

body.fm.error404 .fm-404__onsale-title {
	margin: 0;
	font-family: var(--font-heading);
	font-weight: 800;
	font-size: clamp(1.3rem, 2.2vw, 1.7rem);
	letter-spacing: -0.01em;
	color: var(--color-ink);
}

body.fm.error404 .fm-404__onsale-link {
	font-size: 0.88rem;
	color: var(--color-terracotta);
	text-decoration: underline;
}

/* On-sale card SURFACE cosmetics only — columns/rows stay Storefront-native
   (see file header). No float/width/grid rules, no !important. */
body.fm.error404 .fm-404__onsale ul.products li.product {
	background: #fff;
	border: 1px solid var(--color-hairline);
	border-radius: var(--radius-card);
	padding: 16px;
	box-sizing: border-box;
}
