/**
 * Desistimiento para WooCommerce — estilos públicos.
 *
 * Personalice los colores con variables CSS, por ejemplo:
 *   :root { --wdes-accent: #0b5cad; --wdes-accent-text: #fff; }
 */

:root {
	--wdes-accent: #1d2327;
	--wdes-accent-text: #ffffff;
	--wdes-border: #c3c4c7;
	--wdes-muted: #50575e;
	--wdes-error: #b32d2e;
	--wdes-error-bg: #fcf0f1;
	--wdes-info-bg: #f0f6fc;
	--wdes-info-border: #2271b1;
	--wdes-warning-bg: #fcf9e8;
	--wdes-warning-border: #dba617;
	--wdes-radius: 4px;
}

/* ---------- Botón «Desistir del contrato aquí» ---------- */

.wdes-boton {
	display: inline-block;
	padding: 0.6em 1.2em;
	border: 2px solid var(--wdes-accent);
	border-radius: var(--wdes-radius);
	background: var(--wdes-accent);
	color: var(--wdes-accent-text) !important;
	font-weight: 600;
	font-size: 1rem;
	line-height: 1.3;
	text-decoration: none !important;
	text-align: center;
	cursor: pointer;
}

.wdes-boton:hover,
.wdes-boton:focus {
	background: var(--wdes-accent-text);
	color: var(--wdes-accent) !important;
}

.wdes-boton:focus-visible {
	outline: 3px solid var(--wdes-info-border);
	outline-offset: 2px;
}

/* ---------- Enlace del pie (mismo aspecto que los demás enlaces legales) ---------- */

.wdes-footer-sep {
	padding: 0 0.35em;
}

.wdes-footer-sep::before {
	content: "·";
}

.wdes-footer-fallback {
	clear: both;
	margin: 0;
	padding: 12px 16px;
	text-align: center;
	font-size: 0.875em;
}

.wdes-footer-links {
	margin: 0.5em 0 0;
}

/* Opción «negrita» de los ajustes. */
a.wdes-destacado,
.wdes-destacado > a,
.wdes-destacado .wp-block-navigation-item__content {
	font-weight: 700;
}

.wdes-boton-wrap--fixed {
	position: fixed;
	left: 16px;
	bottom: 16px;
	z-index: 99990;
}

.wdes-boton-wrap--fixed .wdes-boton {
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

@media print {
	.wdes-boton-wrap,
	.wdes-footer-fallback {
		display: none;
	}
}

/* ---------- Condiciones de desistimiento ---------- */

.wdes-condiciones {
	margin: 2em 0;
}

.wdes-condiciones--form,
.wdes-condiciones--ack,
.wdes-condiciones--terms {
	padding-top: 1.5em;
	border-top: 1px solid var(--wdes-border);
}

.wdes-condiciones__section {
	margin: 0 0 1.5em;
}

.wdes-condiciones__section ul {
	margin: 0 0 1em 1.2em;
}

.wdes-condiciones__section--cierre {
	color: var(--wdes-muted);
	font-size: 0.9em;
}

.wdes-condiciones__anexo {
	margin-top: 2em;
}

/* ---------- Formulario ---------- */

.wdes-container {
	max-width: 720px;
}

.wdes-form {
	margin: 0 0 2em;
}

.wdes-form__form {
	margin: 1em 0;
}

.wdes-steps {
	display: flex;
	gap: 1em;
	margin: 0 0 1em;
	color: var(--wdes-muted);
	font-size: 0.9em;
}

.wdes-steps__current {
	font-weight: 700;
	color: inherit;
	border-bottom: 2px solid currentColor;
}

.wdes-field {
	margin: 0 0 1.2em;
}

.wdes-field label,
.wdes-details summary {
	display: block;
	font-weight: 600;
	margin-bottom: 0.3em;
}

.wdes-details summary {
	cursor: pointer;
	font-weight: 400;
	text-decoration: underline;
}

.wdes-details[open] summary {
	margin-bottom: 0.8em;
}

.wdes-field input[type="text"],
.wdes-field input[type="email"],
.wdes-field select,
.wdes-field textarea {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	padding: 0.5em 0.6em;
	border: 1px solid var(--wdes-border);
	border-radius: var(--wdes-radius);
	font: inherit;
}

.wdes-field--error input,
.wdes-field--error textarea {
	border-color: var(--wdes-error);
}

.wdes-required,
.wdes-optional {
	font-weight: 400;
	color: var(--wdes-muted);
	font-size: 0.9em;
}

.wdes-help {
	display: block;
	color: var(--wdes-muted);
	font-size: 0.9em;
	margin-top: 0.3em;
}

.wdes-field__error {
	display: block;
	color: var(--wdes-error);
	font-size: 0.9em;
	margin-top: 0.3em;
}

.wdes-errors,
.wdes-notice,
.wdes-info,
.wdes-success {
	padding: 0.8em 1em;
	margin: 0 0 1.2em;
	border-left: 4px solid var(--wdes-info-border);
	background: var(--wdes-info-bg);
}

.wdes-errors {
	border-left-color: var(--wdes-error);
	background: var(--wdes-error-bg);
}

.wdes-errors ul {
	margin: 0.4em 0 0 1.2em;
}

.wdes-info--warning,
.wdes-excluded {
	border-left-color: var(--wdes-warning-border);
	background: var(--wdes-warning-bg);
}

.wdes-excluded {
	display: block;
	margin-top: 0.4em;
	padding: 0.4em 0.6em;
	border-left: 3px solid var(--wdes-warning-border);
	font-size: 0.9em;
}

.wdes-success .wdes-title {
	margin-top: 0;
}

.wdes-privacy {
	color: var(--wdes-muted);
	font-size: 0.9em;
}

.wdes-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.8em;
	margin: 1.2em 0;
}

.wdes-button {
	display: inline-block;
	padding: 0.7em 1.4em;
	border: 2px solid var(--wdes-accent);
	border-radius: var(--wdes-radius);
	background: var(--wdes-accent);
	color: var(--wdes-accent-text);
	font: inherit;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.wdes-button:hover,
.wdes-button:focus {
	opacity: 0.9;
	color: var(--wdes-accent-text);
}

.wdes-button--secondary {
	background: transparent;
	color: var(--wdes-accent);
}

.wdes-button--secondary:hover,
.wdes-button--secondary:focus {
	color: var(--wdes-accent);
}

.wdes-button[disabled] {
	opacity: 0.6;
	cursor: wait;
}

.wdes-link-button {
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	text-decoration: underline;
	cursor: pointer;
}

/* ---------- Declaración ---------- */

.wdes-declaration {
	border: 1px solid var(--wdes-border);
	border-radius: var(--wdes-radius);
	padding: 1em;
	margin: 0 0 1.2em;
}

.wdes-declaration dl {
	display: grid;
	grid-template-columns: minmax(10em, 35%) 1fr;
	gap: 0.4em 1em;
	margin: 0;
}

.wdes-declaration dt {
	font-weight: 600;
}

.wdes-declaration dd {
	margin: 0;
	overflow-wrap: anywhere;
}

.wdes-declaration dd ul {
	margin: 0;
	padding-left: 1.2em;
}

.wdes-hash {
	font-family: ui-monospace, Consolas, monospace;
	font-size: 0.8em;
	word-break: break-all;
}

@media (max-width: 600px) {
	.wdes-declaration dl {
		grid-template-columns: 1fr;
	}

	.wdes-declaration dd {
		margin-bottom: 0.6em;
	}
}

/* ---------- Artículos ---------- */

.wdes-scope {
	border: 0;
	padding: 0;
	margin: 0 0 1em;
}

.wdes-scope legend {
	font-weight: 700;
	margin-bottom: 0.4em;
}

.wdes-radio {
	margin: 0.2em 0;
}

.wdes-items__table {
	width: 100%;
	border-collapse: collapse;
	margin: 0 0 1.2em;
}

.wdes-items__table caption {
	text-align: left;
	color: var(--wdes-muted);
	font-size: 0.9em;
	padding-bottom: 0.4em;
}

.wdes-items__table th,
.wdes-items__table td {
	border-bottom: 1px solid var(--wdes-border);
	padding: 0.5em;
	text-align: left;
	vertical-align: top;
}

.wdes-items.is-hidden {
	display: none;
}

/* ---------- Otros ---------- */

.wdes-hp {
	position: absolute !important;
	left: -10000px !important;
	top: auto !important;
	width: 1px !important;
	height: 1px !important;
	overflow: hidden !important;
}

.wdes-aviso-exclusion {
	margin: 1em 0;
	padding: 0.6em 0.8em;
	border-left: 4px solid var(--wdes-warning-border);
	background: var(--wdes-warning-bg);
	font-size: 0.95em;
}

.wdes-order-box {
	margin: 2em 0;
	padding: 1em;
	border: 1px solid var(--wdes-border);
	border-radius: var(--wdes-radius);
}

.wdes-order-box h2 {
	margin-top: 0;
	font-size: 1.2em;
}

.wdes-return,
.wdes-tracking {
	margin: 1.5em 0;
}

.wdes-anexo-b__sheet {
	border: 1px solid var(--wdes-border);
	padding: 1.5em;
	margin: 1em 0;
}

.wdes-anexo-b__line {
	min-height: 1.6em;
	border-bottom: 1px dotted var(--wdes-muted);
}

.wdes-anexo-b__line--tall {
	min-height: 3.5em;
}

@media print {
	.wdes-anexo-b__online,
	.wdes-anexo-b .wdes-actions {
		display: none;
	}
}
