/* Barra inferior móvil tipo Woodmart. */

.ed-dock {
	display: none;
}

@media (max-width: 849px) {
	.ed-dock {
		display: flex;
		position: fixed !important;
		left: 0 !important;
		right: 0 !important;
		bottom: 0 !important;
		top: auto !important;
		z-index: 10050;
		align-items: stretch;
		justify-content: space-around;
		height: auto;
		min-height: 56px;
		width: 100%;
		max-width: 100%;
		margin: 0;
		padding: 8px 4px max(8px, env(safe-area-inset-bottom, 0px));
		box-sizing: border-box;
		background: #fff !important;
		border-top: 1px solid #e5eaf0;
		box-shadow: 0 -6px 20px rgba(13, 27, 42, 0.12);
		transform: none !important;
		-webkit-transform: none !important;
		filter: none !important;
	}

	html,
	body {
		padding-bottom: 0;
	}

	#footer,
	#footer.footer-1,
	.footer-wrapper {
		padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px));
		background-color: #0d1b2a;
	}

	.ed-dock.is-overscroll {
		opacity: 0 !important;
		pointer-events: none;
	}

	.ed-dock {
		transition: opacity 0.12s ease;
	}

	.ed-dock-item {
		flex: 1 1 0;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 2px;
		min-width: 0;
		text-decoration: none !important;
		color: #0d1b2a;
		position: relative;
	}

	.ed-dock-item.is-active {
		color: #0d1b2a;
	}

	.ed-dock-item.is-active::before {
		content: "";
		position: absolute;
		top: 0;
		left: 18%;
		right: 18%;
		height: 3px;
		background: #f5c518;
		border-radius: 0 0 3px 3px;
	}

	.ed-dock-icon {
		position: relative;
		width: 24px;
		height: 24px;
		display: block;
	}

	.ed-dock-icon svg {
		width: 24px;
		height: 24px;
		fill: none;
		stroke: currentColor;
		stroke-width: 1.8;
		stroke-linejoin: round;
		stroke-linecap: round;
	}

	.ed-dock-item.is-active .ed-dock-icon svg {
		fill: #f5c518;
		stroke: #0d1b2a;
	}

	.ed-dock-label {
		font-size: 10px;
		font-weight: 700;
		letter-spacing: 0.02em;
		line-height: 1;
		white-space: nowrap;
	}

	.ed-dock-badge {
		position: absolute;
		top: -6px;
		right: -10px;
		min-width: 16px;
		height: 16px;
		padding: 0 4px;
		border-radius: 99px;
		background: #f5c518;
		color: #0d1b2a;
		font-size: 10px;
		font-weight: 800;
		line-height: 16px;
		text-align: center;
	}

	.ed-dock-badge--empty {
		display: none;
	}

	.qlwapp,
	.qlwapp-container,
	div#qlwapp,
	.qlwapp__container {
		display: none !important;
	}

	body.single-product .related .product-small .box,
	body.single-product .upsells .product-small .box {
		display: flex;
		flex-direction: column;
		height: 100%;
		background: #fff;
	}

	body.single-product .related .product-small .box-image,
	body.single-product .upsells .product-small .box-image {
		aspect-ratio: 1 / 1;
		overflow: hidden;
		background: #fff;
	}

	body.single-product .related .product-small .box-image img,
	body.single-product .upsells .product-small .box-image img {
		object-fit: contain !important;
		object-position: center;
		width: 100%;
		height: 100%;
		padding: 8px;
		box-sizing: border-box;
	}

	body.single-product .related .product-small .box-text,
	body.single-product .upsells .product-small .box-text {
		display: block !important;
		visibility: visible !important;
		height: auto !important;
		overflow: visible !important;
		padding: 8px 10px 12px !important;
		min-height: 3.2em;
	}

	body.single-product .related .flickity-viewport,
	body.single-product .upsells .flickity-viewport {
		height: auto !important;
		overflow: visible !important;
	}

	body.single-product .related .product-small .name a,
	body.single-product .upsells .product-small .name a {
		display: -webkit-box;
		-webkit-line-clamp: 2;
		-webkit-box-orient: vertical;
		overflow: hidden;
		white-space: normal !important;
		font-size: 12px;
		line-height: 1.25;
		min-height: 0;
	}

	body.single-product .related-products-wrapper {
		padding-bottom: 8px;
	}
}

/* Subir: mismo FAB que Eldesa (blanco, fijo, por encima del footer). */
#top-link,
.back-to-top,
.scroll-to-top {
	display: none !important;
}

.ed-top-fab,
.ed-wa-fab {
	position: fixed !important;
	z-index: 10060 !important;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none !important;
	box-sizing: border-box;
	bottom: 20px;
	-webkit-tap-highlight-color: transparent;
}

.ed-top-fab {
	left: 14px;
	background: #fff !important;
	border: 1px solid rgba(13, 27, 42, 0.22);
	color: #0d1b2a;
	box-shadow: 0 2px 8px rgba(13, 27, 42, 0.12);
	opacity: 0;
	pointer-events: none;
	transform: none !important;
	-webkit-transform: none !important;
	filter: none !important;
	overflow: visible;
	transition: opacity 0.2s ease;
}

.ed-wa-fab {
	right: 14px;
	background: #25d366;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}
.ed-wa-fab svg {
	display: block;
	width: 22px;
	height: 22px;
}

.ed-top-fab.is-on {
	opacity: 1;
	pointer-events: auto;
}

.ed-top-fab svg {
	width: 16px;
	height: 16px;
	stroke: currentColor;
	fill: none;
	stroke-width: 1.6;
	stroke-linecap: round;
	stroke-linejoin: round;
}

@media (hover: hover) and (pointer: fine) {
	.ed-top-fab:hover,
	.ed-top-fab:focus-visible {
		background: #f8f9fb !important;
		border-color: rgba(13, 27, 42, 0.4);
	}
}

@media (max-width: 849px) {
	.ed-top-fab,
	.ed-wa-fab {
		width: 36px;
		height: 36px;
	}
	.ed-top-fab svg {
		width: 15px;
		height: 15px;
		stroke-width: 1.5;
	}
	.ed-wa-fab svg {
		width: 20px;
		height: 20px;
	}
	body:has(.ed-dock) .ed-top-fab,
	body:has(.ed-dock) .ed-wa-fab {
		bottom: calc(66px + env(safe-area-inset-bottom, 0px));
	}
	body.woocommerce-cart .ed-top-fab,
	body.woocommerce-cart .ed-wa-fab,
	body.woocommerce-checkout .ed-top-fab,
	body.woocommerce-checkout .ed-wa-fab {
		display: none !important;
	}
}
