/**
 * Mebac Reportes - popup y botones "Reportar un error".
 *
 * Toma la tipografia y el azul del tema (WoodMart: Open Sans, Lexend Deca,
 * --wd-primary-color). Sin !important ni resets globales: los selectores
 * llevan un nivel mas que los del tema para ganarle a sus estilos de
 * button/input.
 */

/* ---------- Botones en la pagina ---------- */

.mre-disparador-wrap {
	margin: 14px 0 0;
	text-align: center;
}

.mre-disparador-wrap--producto {
	margin: 4px 0 18px;
	text-align: left;
}

.mre-disparador-wrap--busqueda,
.mre-disparador-wrap--404 {
	margin-top: 20px;
}

.mre-disparador-wrap--seccion {
	margin: 8px 0 32px;
}

.mre-disparador-wrap button.mre-disparador {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 32px;
	margin: 0;
	padding: 6px 2px;
	border: 0;
	border-radius: 6px;
	background: none;
	box-shadow: none;
	color: #767676;
	font-family: inherit;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: 0;
	text-transform: none;
	cursor: pointer;
	transition: color 0.15s ease;
}

.mre-disparador-wrap button.mre-disparador:hover,
.mre-disparador-wrap button.mre-disparador:focus-visible {
	background: none;
	color: var(--wd-primary-color, #1c61e7);
}

.mre-disparador-wrap button.mre-disparador:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

.mre-disparador svg {
	flex: none;
	width: 14px;
	height: 14px;
}

.mre-footer-suelto {
	margin-left: 12px;
	font-size: 13px;
}

/* ---------- Popup ---------- */

.mre-capa {
	--mre-azul: var(--wd-primary-color, #1c61e7);
	--mre-texto: #1d1d1f;
	--mre-gris: #6e6e73;
	--mre-borde: rgba(0, 0, 0, 0.12);
	--mre-suave: #f5f5f7;
	--mre-radio: 18px;

	position: fixed;
	inset: 0;
	/* Sobre el chat de Mebi a pantalla completa (999999) y el checkout (99999). */
	z-index: 1000000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
	background: rgba(17, 17, 17, 0);
	font-family: var(--wd-text-font, inherit);
	transition: background-color 0.2s ease;
	-webkit-tap-highlight-color: transparent;
}

.mre-capa[hidden] {
	display: none;
}

.mre-capa.mre-abierto {
	background: rgba(17, 17, 17, 0.38);
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
}

.mre-capa .mre-dialogo {
	position: relative;
	box-sizing: border-box;
	width: 100%;
	max-width: 420px;
	max-height: calc(100vh - 48px);
	overflow-y: auto;
	padding: 28px 28px 24px;
	border-radius: var(--mre-radio);
	background: #fff;
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18), 0 2px 8px rgba(0, 0, 0, 0.06);
	color: var(--mre-texto);
	text-align: left;
	opacity: 0;
	transform: scale(0.96) translateY(6px);
	transition: opacity 0.18s ease, transform 0.18s ease;
	outline: none;
}

.mre-capa.mre-abierto .mre-dialogo {
	opacity: 1;
	transform: none;
}

.mre-capa .mre-agarre {
	display: none;
}

.mre-capa .mre-titulo {
	margin: 0 44px 6px 0;
	color: var(--mre-texto);
	font-family: var(--wd-title-font, inherit);
	font-size: 21px;
	font-weight: 500;
	line-height: 1.25;
	letter-spacing: -0.01em;
	text-transform: none;
}

.mre-capa .mre-bajada {
	margin: 0 0 16px;
	color: var(--mre-gris);
	font-size: 14px;
	line-height: 1.5;
}

.mre-capa .mre-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	max-width: 100%;
	box-sizing: border-box;
	margin: 0 0 14px;
	padding: 6px 12px 6px 10px;
	border-radius: 999px;
	background: var(--mre-suave);
	color: var(--mre-gris);
	font-size: 12.5px;
	line-height: 1.3;
}

.mre-capa .mre-chip svg {
	flex: none;
}

.mre-capa .mre-chip span {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.mre-capa .mre-form textarea,
.mre-capa .mre-form input[type="email"] {
	display: block;
	box-sizing: border-box;
	width: 100%;
	min-height: 46px;
	margin: 0 0 10px;
	padding: 12px 14px;
	border: 1px solid var(--mre-borde);
	border-radius: 12px;
	background: #fff;
	box-shadow: none;
	color: var(--mre-texto);
	font-family: inherit;
	font-size: 15px;
	line-height: 1.45;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.mre-capa .mre-form textarea {
	min-height: 116px;
	resize: vertical;
}

.mre-capa .mre-form textarea:focus,
.mre-capa .mre-form input[type="email"]:focus {
	border-color: var(--mre-azul);
	box-shadow: 0 0 0 4px rgba(28, 97, 231, 0.15);
	outline: none;
}

.mre-capa .mre-form textarea::placeholder,
.mre-capa .mre-form input::placeholder {
	color: #a1a1a6;
	opacity: 1;
}

.mre-capa .mre-error {
	margin: 0 0 10px;
	color: #d70015;
	font-size: 13px;
	line-height: 1.4;
}

.mre-capa .mre-error[hidden] {
	display: none;
}

.mre-capa button.mre-enviar {
	display: block;
	width: 100%;
	min-height: 48px;
	margin: 6px 0 0;
	padding: 0 20px;
	border: 0;
	border-radius: 12px;
	background: var(--mre-azul);
	box-shadow: none;
	color: #fff;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
	line-height: 48px;
	letter-spacing: 0;
	text-transform: none;
	cursor: pointer;
	transition: filter 0.15s ease, transform 0.1s ease;
}

.mre-capa button.mre-enviar:hover {
	background: var(--mre-azul);
	color: #fff;
	filter: brightness(1.07);
}

.mre-capa button.mre-enviar:active {
	transform: scale(0.99);
}

.mre-capa button.mre-enviar:focus-visible {
	outline: 2px solid var(--mre-azul);
	outline-offset: 3px;
}

.mre-capa button.mre-enviar:disabled {
	cursor: default;
	filter: none;
	opacity: 0.6;
}

.mre-capa button.mre-cerrar {
	position: absolute;
	top: 18px;
	right: 18px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--mre-suave);
	box-shadow: none;
	color: var(--mre-gris);
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

/* Area tactil de 44 px sin agrandar el circulo. */
.mre-capa button.mre-cerrar::after {
	content: "";
	position: absolute;
	inset: -6px;
}

.mre-capa button.mre-cerrar:hover,
.mre-capa button.mre-cerrar:focus-visible {
	background: #e8e8ed;
	color: var(--mre-texto);
}

.mre-capa .mre-trampa {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.mre-capa .mre-oculto {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* Enviado */

.mre-capa .mre-vista[hidden] {
	display: none;
}

.mre-capa .mre-vista--ok {
	padding: 18px 0 8px;
	text-align: center;
}

.mre-capa .mre-ok__icono {
	display: block;
	width: 56px;
	height: 56px;
	margin: 0 auto 14px;
}

.mre-capa .mre-ok__circulo {
	stroke: var(--mre-azul);
	stroke-width: 2.5;
	stroke-dasharray: 151;
	stroke-dashoffset: 151;
	animation: mre-trazo 0.45s ease-out forwards;
}

.mre-capa .mre-ok__tilde {
	stroke: var(--mre-azul);
	stroke-width: 3;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-dasharray: 36;
	stroke-dashoffset: 36;
	animation: mre-trazo 0.3s 0.35s ease-out forwards;
}

.mre-capa .mre-ok__titulo {
	margin: 0 0 4px;
	color: var(--mre-texto);
	font-family: var(--wd-title-font, inherit);
	font-size: 19px;
	font-weight: 500;
}

.mre-capa .mre-ok__texto {
	margin: 0;
	color: var(--mre-gris);
	font-size: 14px;
}

@keyframes mre-trazo {
	to {
		stroke-dashoffset: 0;
	}
}

html.mre-sin-scroll,
html.mre-sin-scroll body {
	overflow: hidden;
}

/* ---------- Celular: hoja desde abajo ---------- */

@media (max-width: 575px) {
	.mre-capa {
		align-items: flex-end;
		padding: 0;
	}

	.mre-capa .mre-dialogo {
		max-width: none;
		max-height: 88vh;
		padding: 10px 20px calc(20px + env(safe-area-inset-bottom, 0px));
		border-radius: var(--mre-radio) var(--mre-radio) 0 0;
		opacity: 1;
		transform: translateY(100%);
		transition: transform 0.24s cubic-bezier(0.32, 0.72, 0, 1);
	}

	.mre-capa .mre-agarre {
		display: block;
		width: 36px;
		height: 5px;
		margin: 0 auto 16px;
		border-radius: 3px;
		background: rgba(0, 0, 0, 0.15);
	}

	.mre-capa button.mre-cerrar {
		top: 22px;
		right: 16px;
	}

	.mre-capa .mre-titulo {
		font-size: 20px;
	}

	/* 16 px: iOS no hace zoom al tocar el campo. */
	.mre-capa .mre-form textarea,
	.mre-capa .mre-form input[type="email"] {
		font-size: 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.mre-capa,
	.mre-capa .mre-dialogo,
	.mre-disparador-wrap button.mre-disparador {
		transition: none;
	}

	.mre-capa .mre-ok__circulo,
	.mre-capa .mre-ok__tilde {
		animation: none;
		stroke-dashoffset: 0;
	}
}
