/**
 * Yerbatería — Funciones: formulario de arrepentimiento, botón y Data Fiscal.
 * Usa la paleta del tema si está activo; si no, valores propios.
 */

.yb-boton-arrepentimiento {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 10px 16px;
	border: 1px solid currentColor;
	border-radius: var(--wp--custom--radio, 2px);
	font-size: 0.875rem;
	font-weight: 600;
	text-decoration: none;
}

.yb-data-fiscal { line-height: 0; }
.yb-data-fiscal img { max-height: 64px; width: auto; height: auto; }
.yb-data-fiscal--vacio { line-height: 1.3; font-size: 12px; }
.yb-data-fiscal--vacio a {
	display: inline-block;
	max-width: 220px;
	padding: 6px 10px;
	border: 1px dashed currentColor;
	border-radius: 2px;
	color: inherit;
	opacity: 0.8;
}

.yb-arrepentimiento { scroll-margin-top: 120px; }
.yb-form {
	display: grid;
	gap: 18px 24px;
	margin-top: 24px;
}
@media (min-width: 600px) {
	.yb-form { grid-template-columns: 1fr 1fr; }
	.yb-form__campo--ancho, .yb-form__enviar { grid-column: 1 / -1; }
}
.yb-form p { margin: 0; }
.yb-form__campo label { display: block; margin-bottom: 6px; font-size: 0.875rem; font-weight: 600; }
.yb-form__campo input[type="text"],
.yb-form__campo input[type="email"],
.yb-form__campo input[type="tel"],
.yb-form__campo input[type="date"],
.yb-form__campo textarea {
	width: 100%;
	box-sizing: border-box;
	padding: 0.7em 0.85em;
	border: 1px solid var(--wp--preset--color--arena, #D8C7A8);
	border-radius: var(--wp--custom--radio, 2px);
	background: var(--wp--preset--color--etiqueta, #FBF8F1);
	color: inherit;
	font: inherit;
}
.yb-form__ayuda { display: block; margin-top: 4px; font-size: 0.8125rem; color: var(--wp--preset--color--musgo, #5A5E55); }
.yb-form__check label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.yb-form__check input { margin-top: 0.3em; width: 18px; height: 18px; flex: none; }
.yb-form__trampa { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.yb-aviso {
	margin: 24px 0;
	padding: 16px 20px;
	border-radius: var(--wp--custom--radio, 2px);
	border: 1px solid var(--wp--preset--color--arena, #D8C7A8);
	background: var(--wp--preset--color--etiqueta, #FBF8F1);
}
.yb-aviso p { margin: 0 0 6px; }
.yb-aviso p:last-child { margin-bottom: 0; }
.yb-aviso--ok { border-left: 4px solid var(--wp--preset--color--monte, #213B2F); }
.yb-aviso--error { border-left: 4px solid var(--wp--preset--color--tierra, #9A5638); }
.yb-codigo { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.04em; }

/* En el editor, la vista previa no es interactiva. */
.yb-vista-editor form,
.yb-vista-editor a { pointer-events: none; }

/* ---------- Selects del formulario ---------- */
.yb-form__campo select {
	width: 100%;
	box-sizing: border-box;
	padding: 0.7em 0.85em;
	border: 1px solid var(--wp--preset--color--arena, #D8C7A8);
	border-radius: var(--wp--custom--radio, 2px);
	background: var(--wp--preset--color--etiqueta, #FBF8F1);
	color: inherit;
	font: inherit;
}

/* ---------- Datos de la tienda ---------- */
.yb-contacto-datos { margin: 0; display: grid; gap: 10px; }
.yb-contacto-datos > div { display: grid; grid-template-columns: 6.5em 1fr; gap: 12px; align-items: baseline; }
.yb-contacto-datos dt { font-size: 0.8125rem; opacity: 0.72; }
.yb-contacto-datos dd { margin: 0; overflow-wrap: anywhere; }
.yb-redes { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; padding: 0; list-style: none; }
.yb-redes--iconos { gap: 2px; flex-wrap: nowrap; }
.yb-redes__icono { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; color: inherit; text-decoration: none; }
.yb-redes__icono svg { display: block; width: 18px; height: 18px; }
.yb-redes__icono--falta { opacity: 0.4; outline: 1px dashed currentColor; outline-offset: -3px; }
.yb-info-compra { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 18px; }
.yb-info-compra strong { font-weight: 600; }
.yb-falta-dato {
	display: inline-block;
	padding: 6px 10px;
	border: 1px dashed currentColor;
	border-radius: 2px;
	font-size: 12px;
	line-height: 1.3;
	opacity: 0.8;
	color: inherit;
}

/* ---------- Newsletter ---------- */
.yb-newsletter { scroll-margin-top: 120px; }
.yb-newsletter__titulo {
	margin: 0 0 6px;
	font-family: var(--wp--preset--font-family--newsreader, Georgia, serif);
	font-size: 1.375rem;
	line-height: 1.2;
}
.yb-newsletter__texto { margin: 0 0 14px; font-size: 0.9375rem; opacity: 0.86; max-width: 40ch; }
.yb-newsletter__form { display: flex; gap: 8px; max-width: 460px; }
.yb-newsletter__form input[type="email"] {
	flex: 1;
	min-width: 0;
	min-height: 48px;
	padding: 0 14px;
	border: 1px solid var(--wp--preset--color--arena, #D8C7A8);
	border-radius: var(--wp--custom--radio, 2px);
	background: var(--wp--preset--color--etiqueta, #FBF8F1);
	color: var(--wp--preset--color--tinta, #1C211E);
	font: inherit;
	font-size: 16px;
}
.yb-newsletter__form button { min-height: 48px; white-space: nowrap; }
.yb-newsletter__aviso { margin: 0 0 12px; padding: 10px 12px; border-left: 3px solid currentColor; font-size: 0.9375rem; }
@media (max-width: 420px) {
	.yb-newsletter__form { flex-direction: column; }
}

/* ---------- Descubrí tu yerba ---------- */
.yb-descubri { margin-block: 32px; }
.yb-descubri__form { display: grid; gap: 28px; }
.yb-descubri__pregunta { margin: 0; padding: 0; border: 0; min-width: 0; }
.yb-descubri__pregunta legend {
	padding: 0;
	margin-bottom: 12px;
	font-family: var(--wp--preset--font-family--newsreader, Georgia, serif);
	font-size: 1.375rem;
	line-height: 1.25;
}
.yb-descubri__paso {
	display: block;
	margin-bottom: 4px;
	font-family: var(--wp--preset--font-family--instrument-sans, system-ui, sans-serif);
	font-size: 0.8125rem;
	color: var(--wp--preset--color--musgo, #5A5E55);
}
.yb-descubri__opcion { display: block; margin-bottom: 8px; cursor: pointer; }
.yb-descubri__opcion input { position: absolute; opacity: 0; pointer-events: none; }
.yb-descubri__opcion span {
	display: block;
	padding: 14px 16px;
	border: 1px solid var(--wp--preset--color--arena, #D8C7A8);
	border-radius: var(--wp--custom--radio, 2px);
	background: var(--wp--preset--color--etiqueta, #FBF8F1);
	transition: border-color 0.15s ease, background-color 0.15s ease;
}
.yb-descubri__opcion:hover span { border-color: var(--wp--preset--color--monte, #213B2F); }
.yb-descubri__opcion input:checked + span {
	border-color: var(--wp--preset--color--monte, #213B2F);
	box-shadow: inset 0 0 0 1px var(--wp--preset--color--monte, #213B2F);
	background: var(--wp--preset--color--papel, #EDE4D3);
}
.yb-descubri__opcion input:focus-visible + span { outline: 2px solid var(--wp--preset--color--tierra, #9A5638); outline-offset: 2px; }
.yb-descubri__resultado {
	padding: 24px;
	background: var(--wp--preset--color--papel, #EDE4D3);
	border-radius: var(--wp--custom--radio, 2px);
}
.yb-descubri__resultado:focus { outline: none; }
.yb-descubri__item + .yb-descubri__item { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--wp--preset--color--arena, #D8C7A8); }
.yb-descubri__item p { margin: 0 0 6px; }
.yb-descubri__titulo { font-family: var(--wp--preset--font-family--newsreader, Georgia, serif); font-size: 1.625rem; line-height: 1.2; }
.yb-descubri__acciones { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 10px !important; }
.yb-descubri__acciones a { font-weight: 600; color: var(--wp--preset--color--monte, #213B2F); text-underline-offset: 5px; }
.yb-descubri__reiniciar {
	margin-top: 20px;
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	text-decoration: underline;
	text-underline-offset: 5px;
	cursor: pointer;
}

/* ---------- Reclamos ---------- */
.yb-reclamos { font-size: 0.8125rem; }

/* Selector de idioma (el tema Yerbatería lo ubica y lo completa). */
.yb-idiomas ul { margin: 0; padding: 0; list-style: none; }
.yb-idiomas__lista { display: flex; gap: 10px; }
.yb-idiomas__lista a[aria-current] { font-weight: 600; text-decoration: underline; }
.yb-idiomas__menu { display: none; }
@media (max-width: 599px) {
	.yb-idiomas__lista { display: none; }
	.yb-idiomas__menu { display: block; }
}
