/*
 * Policy Pages — Clean reading typography.
 *
 * Used by: page-policy.html template (Privacy Policy, Returns, Terms).
 * Layout: constrained 42.5rem reading column — same as single-post.
 * No decorative patterns — content is pure text: title → paragraphs →
 * headings → lists → optional table.
 *
 * Tokens read:
 *   semantic.color.text.primary    — title, headings, strong
 *   semantic.color.text.muted      — body paragraphs, list items, updated line
 *   semantic.color.border.base     — table borders, h2 rule, hr
 *   semantic.color.bg.surface      — table header row bg
 *   semantic.typography.display    — title, H2 (Cormorant)
 *   semantic.typography.body       — everything else (Jost)
 *   space.1 – 10
 */

/* ── Page wrapper ─────────────────────────────────────────────────── */

.wpdl-policy.wp-block-group {
	padding-block: var(--wp--custom--space--10) var(--wp--custom--space--11);
}

/* ── Title (wp:post-title → .wp-block-post-title) ─────────────────── */

.wpdl-policy__title.wp-block-post-title {
	font-family: var(--wp--custom--semantic--typography--display--font-family);
	font-size: clamp(1.75rem, 1.2rem + 2.38vw, 3rem);
	font-weight: 500;
	line-height: 1.1;
	color: var(--wp--custom--semantic--color--text--primary);
	margin-block: 0 var(--wp--custom--space--8);
	padding-block-end: var(--wp--custom--space--7);
	border-block-end: 0.0625rem solid var(--wp--custom--semantic--color--border--base);
}

/* ── Content area ─────────────────────────────────────────────────── */

.wpdl-policy__content .wp-block-post-content {
	margin-block: 0;
}

/* Body paragraphs */
.wpdl-policy__content .wp-block-post-content p,
.wpdl-policy__content .wp-block-post-content .wp-block-paragraph {
	font-family: var(--wp--custom--semantic--typography--body--font-family);
	font-size: 0.875rem;
	font-weight: 300;
	line-height: 1.85;
	color: var(--wp--custom--semantic--color--text--muted);
	margin-block: 0 var(--wp--custom--space--6);
}

/* "Last updated: …" — first paragraph styled as muted label (more specific, comes after base) */
.wpdl-policy__content .wp-block-post-content > p:first-child,
.wpdl-policy__content .wp-block-post-content > .wp-block-paragraph:first-child {
	font-size: 0.75rem;
	font-weight: 400;
	margin-block: 0 var(--wp--custom--space--8);
	letter-spacing: 0.04em;
}

/* H2 — section title (Cormorant) */
.wpdl-policy__content .wp-block-post-content h2.wp-block-heading {
	font-family: var(--wp--custom--semantic--typography--display--font-family);
	font-size: clamp(1.0625rem, 0.85rem + 0.89vw, 1.375rem);
	font-weight: 500;
	color: var(--wp--custom--semantic--color--text--primary);
	margin-block: var(--wp--custom--space--9) var(--wp--custom--space--5);
	line-height: 1.2;
}

/* H3 — sub-section (Jost, uppercase) */
.wpdl-policy__content .wp-block-post-content h3.wp-block-heading {
	font-family: var(--wp--custom--semantic--typography--body--font-family);
	font-size: 0.6875rem;
	font-weight: 500;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--wp--custom--semantic--color--text--primary);
	margin-block: var(--wp--custom--space--7) var(--wp--custom--space--4);
}

/* Lists */
.wpdl-policy__content .wp-block-post-content ul,
.wpdl-policy__content .wp-block-post-content ol {
	font-family: var(--wp--custom--semantic--typography--body--font-family);
	font-size: 0.875rem;
	font-weight: 300;
	line-height: 1.85;
	color: var(--wp--custom--semantic--color--text--muted);
	padding-inline-start: var(--wp--custom--space--7);
	margin-block: 0 var(--wp--custom--space--6);
}

.wpdl-policy__content .wp-block-post-content ul li::marker {
	color: var(--wp--custom--semantic--color--accent--primary);
}

.wpdl-policy__content .wp-block-post-content li {
	margin-block-end: var(--wp--custom--space--2);
}

/* Strong / bold */
.wpdl-policy__content .wp-block-post-content strong {
	font-weight: 500;
	color: var(--wp--custom--semantic--color--text--primary);
}

/* Horizontal rule */
.wpdl-policy__content .wp-block-post-content hr.wp-block-separator {
	border: none;
	border-block-end: 0.0625rem solid var(--wp--custom--semantic--color--border--base);
	margin-block: var(--wp--custom--space--8);
	opacity: 1;
}

/* Table */
.wpdl-policy__content .wp-block-post-content table,
.wpdl-policy__content .wp-block-table table {
	width: 100%;
	border-collapse: collapse;
	font-family: var(--wp--custom--semantic--typography--body--font-family);
	font-size: 0.8125rem;
	font-weight: 300;
	color: var(--wp--custom--semantic--color--text--muted);
	margin-block: 0 var(--wp--custom--space--7);
}

.wpdl-policy__content .wp-block-post-content th,
.wpdl-policy__content .wp-block-table th {
	font-weight: 500;
	font-size: 0.6875rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--wp--custom--semantic--color--text--primary);
	background-color: var(--wp--custom--semantic--color--surface--primary);
	padding: var(--wp--custom--space--4) var(--wp--custom--space--5);
	text-align: start;
	border-block-end: 0.0625rem solid var(--wp--custom--semantic--color--border--base);
}

.wpdl-policy__content .wp-block-post-content td,
.wpdl-policy__content .wp-block-table td {
	padding: var(--wp--custom--space--4) var(--wp--custom--space--5);
	border-block-end: 0.0625rem solid var(--wp--custom--semantic--color--border--base);
	vertical-align: top;
}

/* ── Mobile (< 40em) ──────────────────────────────────────────────── */

@media (width < 40em) {
	.wpdl-policy.wp-block-group {
		padding-block: var(--wp--custom--space--8) var(--wp--custom--space--9);
	}

	.wpdl-policy__content .wp-block-post-content table {
		display: block;
		overflow-x: auto;
	}
}
