/* ==========================================================================
   Producto individual ARCORP (woocommerce/single-product.php del tema hijo).
   Prefijo .ar-sp-*; las tarjetas de relacionados reutilizan .prod-arcorp
   de home-arcorp.css. Sin sombras en toda la ficha.
   ========================================================================== */
/* El padre pinta #eef1f3 en body.woocommerce / .site / .site-main: la ficha va en blanco */
body.single-product,
body.single-product .site,
body.single-product .site-main,
body.single-product .site-main.ar-sp { background: #fff !important; }

.ar-sp {
	--ar-sp-red: #c4060c;
	--ar-sp-red-dark: #a00509;
	--ar-sp-ink: #111;
	--ar-sp-text: #3d3d3d;
	--ar-sp-muted: #6b6b6b;
	--ar-sp-line: #dcdcdc;
	--ar-sp-frame: #c9c9c9;
	/* Ancho del contenido (migas, ficha, relacionados) y de la línea de pestañas */
	--ar-sp-wrap: 1600px;
	--ar-sp-wide: 1600px;
	--ar-sp-gutter: clamp(16px, 3vw, 40px);
	background: #fff;
	font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
	color: var(--ar-sp-text);
}
.ar-sp *,
.ar-sp *::before,
.ar-sp *::after { box-sizing: border-box; }

/* Sin sombras: anula las de WooCommerce, OZ Cotizador y las tarjetas .prod-arcorp */
.ar-sp *,
.ar-sp *::before,
.ar-sp *::after,
.ar-sp-lightbox,
.ar-sp-lightbox * { box-shadow: none !important; text-shadow: none !important; }

.ar-sp :focus-visible { outline: 2px solid var(--ar-sp-red); outline-offset: 2px; }

/* Contenedores alineados: todo arranca en la misma línea que las migas */
.ar-sp-crumbs__inner,
.ar-sp-hero,
.ar-sp-related {
	max-width: calc(var(--ar-sp-wrap) + 2 * var(--ar-sp-gutter));
	margin-inline: auto;
	padding-inline: var(--ar-sp-gutter);
}

/* ---------- Migas ---------- */
.ar-sp-crumbs { border-bottom: 1px solid var(--ar-sp-line); }
.ar-sp-crumbs__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 6px;
	padding-block: 10px;
	font-size: 15px;
	line-height: 1.4;
	color: #222;
}
.ar-sp-crumbs__inner a { color: inherit; text-decoration: none; transition: color .2s ease; }
.ar-sp-crumbs__inner a:hover { color: var(--ar-sp-red); text-decoration: none; }
.ar-sp-crumbs__inner > span[aria-hidden] { color: var(--ar-sp-muted); }
.ar-sp-crumbs__inner [aria-current] {
	overflow: hidden;
	max-width: 60ch;
	white-space: nowrap;
	text-overflow: ellipsis;
	color: #222;
}

/* ---------- Filtros de la tienda (columna izquierda) + hero ----------
   La barra lateral usa los estilos de shop-arcorp.css (.ar-shop__sidebar, .ar-filter*). */
.ar-sp-layout {
	--ar-sp-side: 317px;
	display: grid;
	grid-template-columns: var(--ar-sp-side) minmax(0, 1fr);
	align-items: start;
	gap: 34px;
	max-width: calc(var(--ar-sp-wrap) + 2 * var(--ar-sp-gutter));
	margin-inline: auto;
	padding: 32px var(--ar-sp-gutter) 0;
}
.ar-sp-layout .ar-shop__sidebar { grid-column: 1; grid-row: 1; }
.ar-sp-layout .ar-sp-hero {
	grid-column: 2;
	grid-row: 1;
	max-width: none;
	margin: 0;
	padding: 0 0 40px;
}

/* ---------- Hero: resumen + galería ---------- */
.ar-sp-product { margin: 0; padding: 0; }
.ar-sp-hero {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
	gap: clamp(28px, 5vw, 84px);
	align-items: start;
	padding-block: 32px 40px;
}
.ar-sp-hero__summary { padding: 40px 0 0 14px; max-width: 640px; }
.ar-sp .ar-sp-hero__title {
	margin: 0 0 22px;
	font-family: "Inter", system-ui, sans-serif;
	font-size: clamp(1.75rem, 1.2rem + 1.6vw, 2.6rem);
	font-weight: 700;
	line-height: 1.12;
	letter-spacing: -.01em;
	color: var(--ar-sp-ink);
	overflow-wrap: anywhere;
}
.ar-sp-hero__intro { font-size: 16px; line-height: 1.65; color: var(--ar-sp-text); }
.ar-sp-hero__intro p { margin: 0 0 .8em; }
.ar-sp-hero__intro p:last-child { margin-bottom: 0; }
.ar-sp-hero__intro a { color: var(--ar-sp-red); }

.ar-sp-features { display: grid; gap: 18px; margin: 24px 0 0; padding: 0; list-style: none; }
.ar-sp-features li { display: flex; align-items: center; gap: 14px; margin: 0; font-size: 17px; line-height: 1.35; color: #333; }
.ar-sp-features svg {
	flex: none; width: 26px; height: 26px;
	fill: none; stroke: #222; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}

/* Botones */
.ar-sp-hero__actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 40px 0 0 -14px; }
.ar-sp .ar-sp-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 14px;
	min-height: 46px;
	padding: 10px 28px;
	border: 0;
	border-radius: 999px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	transition: background-color .2s ease, color .2s ease;
}
.ar-sp-btn svg {
	flex: none; width: 24px; height: 24px;
	fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round;
}
.ar-sp .ar-sp-btn--ghost { flex: 0 1 256px; background: #f1f1f1; color: #666; }
.ar-sp .ar-sp-btn--ghost:hover { background: #e4e4e4; color: #222; text-decoration: none; }
.ar-sp .ar-sp-btn--red { flex: 1 1 300px; max-width: 410px; background: var(--ar-sp-red); color: #fff; }
.ar-sp .ar-sp-btn--red:hover,
.ar-sp .ar-sp-btn--red:focus-visible { background: var(--ar-sp-red-dark); color: #fff; text-decoration: none; }

/* Beneficios bajo los botones (mismo diseño que la portada, sección 11) */
.ar-sp-perks {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 10px;
	margin: 32px 0 0 -14px;
	padding: 0;
	list-style: none;
}
.ar-sp-perk {
	display: flex;
	flex-direction: column;
	align-items: center;
	margin: 0;
	padding: 18px 10px 16px;
	border: 1px solid #e7e7e7;
	border-radius: 10px;
	background: #fff;
	text-align: center;
}
.ar-sp-perk__ico {
	display: inline-flex; align-items: center; justify-content: center;
	width: 44px; height: 44px; margin-bottom: 10px;
	border-radius: 50%; background: #e3131b; color: #fff;
}
.ar-sp-perk__ico svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.ar-sp-perk__title { font-size: 14px; font-weight: 600; line-height: 1.25; color: #1a1a1a; }
.ar-sp-perk__desc { margin-top: 4px; font-size: 13px; line-height: 1.35; color: #6b6b6b; }
/* Un poco más anchos: invaden parte del hueco hacia la galería (gap ≥ 64px aquí) */
@media (min-width: 1280px) {
	.ar-sp-perks { width: calc(100% + 14px + 24px); }
}
@media (min-width: 1440px) {
	.ar-sp-perks { width: calc(100% + 14px + 44px); gap: 12px; }
	.ar-sp-perk { padding: 20px 12px 18px; }
}
@media (max-width: 1279px) {
	.ar-sp-perks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 991px) {
	.ar-sp-perks { margin-left: 0; }
}

/* ---------- Galería: imagen principal + miniaturas a la derecha ---------- */
.ar-sp-gallery { display: flex; align-items: flex-start; gap: 12px; }
.ar-sp-gallery__main {
	position: relative;
	flex: 1 1 auto;
	max-width: 550px;
	aspect-ratio: 1 / 1;
	border: 1px solid var(--ar-sp-frame);
	border-radius: 14px;
	background: #fff;
	overflow: hidden;
}
.ar-sp-gallery__slide { position: absolute; inset: 0; margin: 0; display: none; }
.ar-sp-gallery__slide.is-active { display: block; }
.ar-sp .ar-sp-gallery__slide img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	padding: 5%;
	border: 0;
	border-radius: 0;
	object-fit: contain;
}
.ar-sp .ar-sp-gallery__zoom {
	position: absolute; right: 14px; bottom: 14px;
	display: grid; place-items: center;
	width: 38px; height: 38px; padding: 0;
	border: 0; border-radius: 8px; background: rgba(255, 255, 255, .9);
	color: #222; cursor: zoom-in;
	transition: color .2s ease, background-color .2s ease;
}
.ar-sp-gallery__zoom svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.ar-sp .ar-sp-gallery__zoom:hover { color: var(--ar-sp-red); background: #fff; }

.ar-sp-gallery__thumbs { display: flex; flex-direction: column; gap: 10px; flex: none; width: 92px; }
.ar-sp .ar-sp-gallery__thumb {
	display: block; width: 92px; height: 92px; padding: 6px;
	border: 1px solid var(--ar-sp-frame); border-radius: 4px; background: #fff;
	cursor: pointer;
	transition: border-color .2s ease;
}
.ar-sp-gallery__thumb img { display: block; width: 100%; height: 100%; border-radius: 0; object-fit: contain; }
.ar-sp .ar-sp-gallery__thumb:hover { border-color: #8a8a8a; background: #fff; }
.ar-sp .ar-sp-gallery__thumb.is-active { border-color: var(--ar-sp-red); }

/* Lightbox */
.ar-sp-lightbox {
	position: fixed; inset: 0; z-index: 100000;
	display: flex; align-items: center; justify-content: center;
	padding: 24px; background: rgba(0, 0, 0, .88);
}
.ar-sp-lightbox[hidden] { display: none; }
.ar-sp-lightbox img { max-width: min(92vw, 1100px); max-height: 88vh; object-fit: contain; background: #fff; border-radius: 8px; }
.ar-sp-lightbox button {
	position: absolute; display: grid; place-items: center;
	width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%;
	background: #fff; color: #111; font-size: 26px; line-height: 1; cursor: pointer;
	transition: background-color .2s ease, color .2s ease;
}
.ar-sp-lightbox button:hover { background: var(--ar-sp-red); color: #fff; }
.ar-sp-lightbox [data-lb-close] { top: 18px; right: 18px; }
.ar-sp-lightbox [data-lb-prev] { left: 18px; top: 50%; transform: translateY(-50%); }
.ar-sp-lightbox [data-lb-next] { right: 18px; top: 50%; transform: translateY(-50%); }

/* ---------- Pestañas ---------- */
/* La línea ocupa el ancho amplio; el texto arranca alineado con la ficha */
.ar-sp-tabs {
	--ar-sp-inset: clamp(0px, calc((100vw - var(--ar-sp-wrap) - 2 * var(--ar-sp-gutter)) / 2), calc((var(--ar-sp-wide) - var(--ar-sp-wrap)) / 2));
	max-width: calc(var(--ar-sp-wide) + 2 * var(--ar-sp-gutter));
	margin: 30px auto 0;
	padding: 0 var(--ar-sp-gutter);
}
.ar-sp-tabs__nav {
	display: flex; gap: 26px;
	padding-left: calc(var(--ar-sp-inset) + clamp(0px, 8vw, 134px));
	border-bottom: 1px solid #bdbdbd;
	overflow-x: auto;
	scrollbar-width: none;
}
.ar-sp-tabs__nav::-webkit-scrollbar { display: none; }
.ar-sp .ar-sp-tabs__tab {
	flex: none;
	margin: 0; padding: 8px 2px 12px;
	border: 0; border-bottom: 2px solid transparent; border-radius: 0;
	background: none;
	font-family: inherit; font-size: 16px; font-weight: 400; line-height: 1.3; color: #111;
	cursor: pointer;
	transition: color .2s ease, border-color .2s ease;
}
.ar-sp .ar-sp-tabs__tab:hover { color: var(--ar-sp-red); background: none; }
.ar-sp .ar-sp-tabs__tab.is-active { border-bottom-color: var(--ar-sp-red); font-weight: 500; }

.ar-sp-tabs__panel {
	max-width: calc(900px + var(--ar-sp-inset));
	padding: 28px 0 0 var(--ar-sp-inset);
	font-size: 16px; line-height: 1.75; color: var(--ar-sp-text);
}
.ar-sp-tabs__panel[hidden] { display: none; }
.ar-sp-tabs__panel > :first-child { margin-top: 0; }
.ar-sp-tabs__panel > :last-child { margin-bottom: 0; }
.ar-sp-tabs__panel p { margin: 0 0 1em; }
.ar-sp-tabs__panel h2,
.ar-sp-tabs__panel h3,
.ar-sp-tabs__panel h4 { margin: 1.4em 0 .5em; font-family: inherit; font-weight: 700; line-height: 1.3; color: var(--ar-sp-ink); }
.ar-sp-tabs__panel h2 { font-size: 22px; }
.ar-sp-tabs__panel h3 { font-size: 19px; }
.ar-sp-tabs__panel h4 { font-size: 17px; }
.ar-sp-tabs__panel a { color: var(--ar-sp-red); }
.ar-sp-tabs__panel ul,
.ar-sp-tabs__panel ol { margin: 0 0 1em; padding-left: 1.25em; }
.ar-sp-tabs__panel li { margin: 0 0 .35em; }
.ar-sp-tabs__panel ul li::marker { color: var(--ar-sp-red); }
.ar-sp-tabs__panel img { max-width: 100%; height: auto; border-radius: 8px; }

/* Especificaciones (tabla de atributos de WooCommerce) */
.ar-sp-tabs__panel table,
.ar-sp .woocommerce-product-attributes {
	width: 100%;
	margin: 0;
	border: 1px solid #e5e5e5;
	border-radius: 10px;
	border-collapse: separate;
	border-spacing: 0;
	overflow: hidden;
}
.ar-sp-tabs__panel th,
.ar-sp-tabs__panel td {
	padding: 12px 16px;
	border: 0;
	border-bottom: 1px solid #e5e5e5;
	background: #fff;
	text-align: left; vertical-align: top;
	font-size: 15px; line-height: 1.5;
}
.ar-sp-tabs__panel tr:last-child th,
.ar-sp-tabs__panel tr:last-child td { border-bottom: 0; }
.ar-sp-tabs__panel th { width: 32%; background: #f7f7f7; font-weight: 600; color: #222; }
.ar-sp-tabs__panel td { color: var(--ar-sp-text); font-style: normal; }
.ar-sp-tabs__panel td p { margin: 0; padding: 0; }

/* ---------- Relacionados ---------- */
.ar-sp-related { margin-top: 80px; padding-bottom: 72px; }
.ar-sp .ar-sp-related__title {
	margin: 0 0 36px;
	font-family: "Montserrat", system-ui, sans-serif;
	font-size: clamp(1.6rem, 1.1rem + 1.6vw, 2.6rem);
	font-weight: 600;
	line-height: 1.1;
	text-transform: uppercase;
	color: var(--ar-sp-ink);
}
body.woocommerce .ar-sp .ar-sp-related__grid {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 24px;
	margin: 0; padding: 0; list-style: none;
}
/* WooCommerce añade ::before/::after (clearfix) que ocuparían celdas del grid */
body.woocommerce .ar-sp ul.products.ar-sp-related__grid::before,
body.woocommerce .ar-sp ul.products.ar-sp-related__grid::after { content: none !important; display: none !important; }
/* Anula float + width:22.05% + margin de woocommerce-layout.css */
body.woocommerce .ar-sp ul.products.ar-sp-related__grid > li.product {
	float: none !important;
	clear: none !important;
	width: auto !important;
	max-width: none !important;
	min-width: 0;
	margin: 0 !important;
	padding: 0 !important;
	justify-self: stretch;
}
/* Carrusel de OZ Sliders ([oz_wc_products] en single-product.php):
   - el ancho de cada tarjeta lo pone el slider, no woocommerce-layout.css
     (width:22.05% + float + margin para ul.products li.product);
   - el título del carrusel con el mismo estilo que tenía la sección. */
body.woocommerce .ar-sp .ar-sp-related ul.ozs__track::before,
body.woocommerce .ar-sp .ar-sp-related ul.ozs__track::after { content: none !important; display: none !important; }
body.woocommerce .ar-sp .ar-sp-related ul.ozs__track > li.product {
	float: none !important;
	clear: none !important;
	width: auto !important;
	max-width: none !important;
	margin: 0 !important;
}
html body .ar-sp .ar-sp-related .ozs.prod-arcorp .ozs__title {
	font-size: clamp(1.4rem, 1rem + 1.6vw, 2.6rem) !important;
	font-weight: 600 !important;
}
html body .ar-sp .ar-sp-related .ozs.prod-arcorp .ozs__header { margin-bottom: 28px; }
.ar-sp .ar-sp-related .oz-loop-product__inner { width: 100%; height: 100%; }
.ar-sp .ar-sp-related .oz-loop-product__media img { width: 100% !important; height: auto; margin: 0 !important; }
/* Tarjeta: solo borde (sin sombra); al pasar el ratón el borde se oscurece */
.ar-sp .ar-sp-related .oz-loop-product__inner { padding: 18px 18px 22px; border-color: #c4c4c4; border-radius: 12px; }
.ar-sp .ar-sp-related .oz-loop-product__inner:hover { border-color: #8a8a8a; }
.ar-sp .ar-sp-related .oz-loop-product__title { font-size: 16px !important; color: #444; }
.ar-sp .ar-sp-related .oz-loop-product__brand { top: 22px; right: 22px; padding: 4px 8px; background: #111; border-color: #111; color: #fff; font-size: 13px; }
.ar-sp .ar-sp-related .oz-loop-product__more { font-size: 16px; color: #222; }
/* «Más información» + botón en la misma fila; si no caben, el botón baja */
.ar-sp .ar-sp-related .oz-loop-product__actions { flex-wrap: wrap; gap: 10px 6px; }
.ar-sp .ar-sp-related .oz-loop-product__more { font-size: 15px; }
.ar-sp .ar-sp-related .oz-loop-product__actions .button { padding: 10px 12px !important; border-radius: 6px !important; font-size: 14px !important; font-weight: 600 !important; white-space: nowrap; background: var(--ar-sp-red) !important; }
.ar-sp .ar-sp-related .oz-loop-product__actions .button:hover { background: var(--ar-sp-red-dark) !important; }

/* Avisos de WooCommerce dentro de la ficha */
.ar-sp .woocommerce-notices-wrapper:not(:empty) {
	max-width: calc(var(--ar-sp-wrap) + 2 * var(--ar-sp-gutter));
	margin: 16px auto 0;
	padding-inline: var(--ar-sp-gutter);
}

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
	.ar-sp-layout { --ar-sp-side: 270px; gap: 24px; }
}
/* Con la barra lateral no caben resumen y galería lado a lado: se apilan */
@media (max-width: 1199px) {
	.ar-sp-layout .ar-sp-hero { grid-template-columns: 1fr; gap: 28px; }
	.ar-sp-layout .ar-sp-hero__summary { order: 2; padding: 0; max-width: none; }
	.ar-sp-layout .ar-sp-hero__actions,
	.ar-sp-layout .ar-sp-perks { margin-left: 0; }
	.ar-sp-layout .ar-sp-gallery { order: 1; }
	.ar-sp-layout .ar-sp-gallery__main { max-width: none; }
}
@media (max-width: 991px) {
	.ar-sp-layout { grid-template-columns: minmax(0, 1fr); gap: 16px; padding-top: 20px; }
	.ar-sp-layout .ar-shop__sidebar,
	.ar-sp-layout .ar-sp-hero { grid-column: 1; grid-row: auto; }
	.ar-sp-layout .ar-sp-hero { padding-top: 4px; }
}
@media (max-width: 1199px) {
	body.woocommerce .ar-sp .ar-sp-related__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
}
@media (max-width: 991px) {
	.ar-sp-hero { grid-template-columns: 1fr; gap: 28px; padding-top: 20px; }
	.ar-sp-hero__summary { order: 2; padding: 0; max-width: none; }
	.ar-sp-hero__actions { margin-left: 0; }
	.ar-sp-gallery { order: 1; }
	.ar-sp-gallery__main { max-width: none; }
	.ar-sp-tabs { --ar-sp-inset: 0px; }
	.ar-sp-tabs__nav { padding-left: 0; }
	.ar-sp-related { margin-top: 56px; }
	body.woocommerce .ar-sp .ar-sp-related__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (max-width: 575px) {
	.ar-sp-crumbs__inner { font-size: 14px; }
	.ar-sp-crumbs__inner [aria-current] { max-width: 28ch; }
	.ar-sp-gallery { flex-direction: column; }
	.ar-sp-gallery__main { width: 100%; }
	.ar-sp-gallery__thumbs { flex-direction: row; width: auto; max-width: 100%; overflow-x: auto; }
	.ar-sp .ar-sp-gallery__thumb { flex: none; width: 70px; height: 70px; }
	.ar-sp-hero__actions { flex-direction: column; }
	.ar-sp .ar-sp-btn--ghost,
	.ar-sp .ar-sp-btn--red { flex: none; max-width: none; width: 100%; }
	.ar-sp-features li { font-size: 16px; }
	.ar-sp-tabs__panel th { width: 40%; }
	.ar-sp-related { margin-top: 48px; padding-bottom: 48px; }
	.ar-sp .ar-sp-related__title { margin-bottom: 24px; }
	body.woocommerce .ar-sp .ar-sp-related__grid { grid-template-columns: 1fr; }
}


/* ---------- FIX layout: el contenido del producto (hero + Caracteristicas +
   relacionados) va en la columna de contenido (col 2), junto al sidebar de
   filtros (col 1). Antes las pestanas y relacionados eran hermanos DEBAJO de la
   grilla; como el sidebar es mas alto que el hero, quedaba un hueco en la col 2
   y las Caracteristicas caian al fondo. Ahora van envueltos en .ar-sp-content
   dentro de la grilla. Solo escritorio (>=992px); en movil se apila en 1 col. */
@media (min-width: 992px) {
	.ar-sp-layout .ar-sp-content { grid-column: 2; min-width: 0; }
	.ar-sp-content .ar-sp-tabs { --ar-sp-inset: 0px; max-width: none; padding-inline: 0; margin-top: 12px; }
	.ar-sp-content .ar-sp-tabs__nav { padding-left: 0; }
	.ar-sp-content .ar-sp-related { max-width: none; padding-inline: 0; }
}