/**
 * Legal pages — Aviso legal, Política de privacidad, Política de cookies,
 * Términos y condiciones. Enqueued only on those 4 pages (see
 * inc/enqueue.php). Reuses .ed-guide-hero / .ed-guide-breadcrumb from
 * guide-page.css for the page header; this file is only the long-form
 * prose layout underneath.
 */

.ed-legal {
	max-width: var(--ed-container-narrow);
	margin-inline: auto;
}

.ed-legal__updated {
	display: inline-block;
	margin-bottom: var(--ed-space-lg);
	padding: var(--ed-space-3xs) var(--ed-space-sm);
	background-color: var(--ed-color-surface-alt);
	border-radius: var(--ed-radius-full);
	color: var(--ed-color-muted);
	font-size: var(--ed-font-size-xs);
	font-weight: 600;
}

/* Index / table of contents — plain numbered jump links to each H2 */

.ed-legal__toc {
	margin: 0 0 var(--ed-space-2xl);
	padding: var(--ed-space-lg);
	background-color: var(--ed-color-surface-alt);
	border-radius: var(--ed-radius-md);
}

.ed-legal__toc-title {
	margin: 0 0 var(--ed-space-sm);
	color: var(--ed-color-heading);
	font-size: var(--ed-font-size-sm);
	font-weight: 600;
	letter-spacing: var(--ed-letter-spacing-eyebrow);
	text-transform: uppercase;
}

.ed-legal__toc ol {
	margin: 0;
	padding-left: 1.25em;
	display: flex;
	flex-direction: column;
	gap: var(--ed-space-2xs);
}

.ed-legal__toc a {
	color: var(--ed-color-link);
	text-decoration: none;
	font-size: var(--ed-font-size-sm);
}

.ed-legal__toc a:hover {
	color: var(--ed-color-link-hover);
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Prose */

.ed-legal__body h2 {
	margin: var(--ed-space-2xl) 0 var(--ed-space-sm);
	/*
	 * --ed-header-stack-offset (published by header-scroll.js, see
	 * header.css) is the global sticky header's current on-screen height,
	 * already admin-bar-aware — without it, jumping here from
	 * .ed-legal__toc would land the heading partly under the header.
	 */
	scroll-margin-top: calc(64px + var(--ed-space-lg) + var(--ed-header-stack-offset, 0px));
}

.ed-legal__body h2:first-child {
	margin-top: 0;
}

.ed-legal__body h3 {
	margin: var(--ed-space-lg) 0 var(--ed-space-2xs);
}

.ed-legal__body p {
	margin: 0 0 var(--ed-space-md);
	color: var(--ed-color-text);
}

.ed-legal__body ul,
.ed-legal__body ol {
	margin: 0 0 var(--ed-space-md);
	padding-left: 1.25em;
	color: var(--ed-color-text);
}

.ed-legal__body li {
	margin-bottom: var(--ed-space-2xs);
}

.ed-legal__body a {
	color: var(--ed-color-link);
}

.ed-legal__body strong {
	color: var(--ed-color-heading);
}

/* Missing-data placeholder — visually flagged so it can't ship unnoticed */

.ed-legal-pending {
	background-color: rgba(201, 122, 26, 0.12);
	color: #8a5814;
	padding: 0.1em 0.4em;
	border-radius: var(--ed-radius-sm);
	font-weight: 600;
	/*
	 * white-space: nowrap here forced long placeholders (e.g. the
	 * hosting/email/payment-gateway one) onto a single unbreakable line
	 * wider than the viewport, causing sitewide horizontal overflow on
	 * mobile/tablet. Placeholders must wrap like any other inline text.
	 */
	overflow-wrap: break-word;
}
