/* ==================================================
   CALPE LOCAL — LEGAL PAGES
   ================================================== */

body.cl-legal-page-active {
	overflow-x: clip;
	background: #f6f1e8;
}

/*
 * GeneratePress opens custom page templates inside its normal flex/grid
 * content wrapper. Reset that wrapper so legal pages use the full viewport
 * instead of being treated like a narrow content column with an empty side.
 */
body.cl-legal-page-active #page,
body.cl-legal-page-active #page.site,
body.cl-legal-page-active .site-content,
body.cl-legal-page-active .content-area,
body.cl-legal-page-active .site-main,
body.cl-legal-page-active .inside-article,
body.cl-legal-page-active .entry-content {
	width: 100% !important;
	max-width: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

body.cl-legal-page-active #page,
body.cl-legal-page-active .site-content {
	display: block !important;
}

body.cl-legal-page-active .cl-legal-page {
	position: relative;
	left: 50%;
	width: 100vw;
	max-width: 100vw;
	margin-right: -50vw;
	margin-left: -50vw;
	flex: 0 0 100vw;
}

.cl-legal-page,
.cl-legal-page * {
	box-sizing: border-box;
}

.cl-legal-page {
	--cl-legal-width: 1320px;
	--cl-serif: "Newsreader", Georgia, "Times New Roman", serif;
	--cl-sans: "Manrope", Arial, Helvetica, sans-serif;
	background: #f6f1e8;
	color: #2d3333;
	font-family: var(--cl-sans);
}

.cl-legal-shell {
	width: min(calc(100% - 48px), var(--cl-legal-width));
	margin-inline: auto;
}

.cl-legal-kicker {
	margin: 0;
	color: #d8764a;
	font-size: 11px;
	font-weight: 800;
	line-height: 1.3;
	letter-spacing: .14em;
	text-transform: uppercase;
}

.cl-legal-page h1,
.cl-legal-page h2,
.cl-legal-page h3 {
	color: #102a2e;
	font-family: var(--cl-serif);
	font-weight: 700;
	letter-spacing: -.035em;
}

/* Hero */

.cl-legal-hero {
	padding: 64px 0 58px;
	border-bottom: 1px solid #d8d0c4;
	background: #f6f1e8;
}

.cl-legal-hero__content {
	max-width: 860px;
}

.cl-legal-hero h1 {
	max-width: 800px;
	margin: 10px 0 0;
	font-size: clamp(44px, 4.2vw, 60px);
	line-height: 1;
}

.cl-legal-intro {
	max-width: 760px;
	margin: 20px 0 0;
	color: #56605f;
	font-size: 17px;
	line-height: 1.68;
}

.cl-legal-updated {
	margin: 20px 0 0;
	color: #747c7a;
	font-size: 12px;
	font-weight: 650;
}

/* Main legal layout */

.cl-legal-content {
	padding: 68px 0 82px;
	background: #fffdf8;
}

.cl-legal-layout {
	display: grid;
	grid-template-columns: 270px minmax(0, 860px);
	justify-content: space-between;
	align-items: start;
	gap: 70px;
}

.cl-legal-toc {
	position: sticky;
	top: 110px;
	padding: 23px 22px 21px;
	border: 1px solid #d8d0c4;
	background: #f6f1e8;
}

.cl-legal-toc__title {
	margin: 0 0 14px;
	color: #102a2e;
	font-size: 12px;
	font-weight: 800;
	letter-spacing: .1em;
	text-transform: uppercase;
}

.cl-legal-toc ol {
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: legal-toc;
}

.cl-legal-toc li {
	counter-increment: legal-toc;
	border-top: 1px solid #ded6cb;
}

.cl-legal-toc a {
	display: grid;
	grid-template-columns: 27px minmax(0, 1fr);
	gap: 7px;
	padding: 10px 0;
	color: #4d5755;
	font-size: 12px;
	font-weight: 650;
	line-height: 1.35;
	text-decoration: none;
}

.cl-legal-toc a::before {
	content: counter(legal-toc, decimal-leading-zero);
	color: #d8764a;
	font-size: 9px;
	font-weight: 800;
	letter-spacing: .08em;
}

.cl-legal-toc a:hover,
.cl-legal-toc a:focus-visible {
	color: #102a2e;
}

.cl-legal-article {
	min-width: 0;
}

.cl-legal-section {
	scroll-margin-top: 120px;
	padding: 0 0 48px;
}

.cl-legal-section + .cl-legal-section {
	padding-top: 48px;
	border-top: 1px solid #ddd5ca;
}

.cl-legal-section__number {
	margin: 0 0 7px;
	color: #d8764a;
	font-size: 10px;
	font-weight: 800;
	letter-spacing: .13em;
}

.cl-legal-section h2 {
	margin: 0;
	font-size: clamp(30px, 2.5vw, 40px);
	line-height: 1.04;
}

.cl-legal-prose {
	margin-top: 20px;
	color: #46504e;
	font-size: 16px;
	line-height: 1.72;
}

.cl-legal-prose p {
	margin: 0 0 18px;
}

.cl-legal-prose p:last-child {
	margin-bottom: 0;
}

.cl-legal-prose ul,
.cl-legal-prose ol {
	margin: 18px 0 22px;
	padding-left: 24px;
}

.cl-legal-prose li + li {
	margin-top: 8px;
}

.cl-legal-prose a {
	color: #1f6672;
	font-weight: 700;
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

.cl-legal-prose a:hover,
.cl-legal-prose a:focus-visible {
	color: #d8764a;
}

.cl-legal-details {
	margin: 0 0 24px;
	border-top: 1px solid #d8d0c4;
}

.cl-legal-details > div {
	display: grid;
	grid-template-columns: 155px minmax(0, 1fr);
	gap: 22px;
	padding: 12px 0;
	border-bottom: 1px solid #e2dbd1;
}

.cl-legal-details dt {
	color: #102a2e;
	font-size: 12px;
	font-weight: 800;
}

.cl-legal-details dd {
	margin: 0;
}

.cl-legal-details--compact {
	max-width: 620px;
}

.cl-legal-table-wrap {
	max-width: 100%;
	overflow-x: auto;
	margin: 7px 0 24px;
}

.cl-legal-table {
	width: 100%;
	min-width: 760px;
	border-collapse: collapse;
	background: #fff;
	font-size: 13px;
	line-height: 1.55;
}

.cl-legal-table th,
.cl-legal-table td {
	padding: 14px 15px;
	border: 1px solid #d8d0c4;
	text-align: left;
	vertical-align: top;
}

.cl-legal-table th {
	background: #edf3f2;
	color: #102a2e;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: .04em;
	text-transform: uppercase;
}

.cl-legal-table code {
	font-size: 12px;
}

/* Related policy links */

.cl-legal-links {
	padding: 64px 0 72px;
	background: #f6f1e8;
}

.cl-legal-links h2 {
	margin: 9px 0 26px;
	font-size: clamp(32px, 3vw, 44px);
	line-height: 1.04;
}

.cl-legal-links__grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 12px;
}

.cl-legal-links__grid a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 15px;
	min-height: 62px;
	padding: 16px 17px;
	border: 1px solid #d8d0c4;
	background: #fffdf8;
	color: #102a2e;
	font-size: 13px;
	font-weight: 750;
	text-decoration: none;
}

.cl-legal-links__grid a:hover,
.cl-legal-links__grid a:focus-visible {
	border-color: #d8764a;
	color: #d8764a;
}

@media (max-width: 1000px) {
	.cl-legal-layout {
		grid-template-columns: 230px minmax(0, 1fr);
		gap: 45px;
	}

	.cl-legal-links__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 780px) {
	.cl-legal-shell {
		width: min(calc(100% - 32px), var(--cl-legal-width));
	}

	.cl-legal-hero {
		padding: 48px 0 50px;
	}

	.cl-legal-layout {
		grid-template-columns: 1fr;
	}

	.cl-legal-content {
		padding: 52px 0 64px;
	}

	.cl-legal-toc {
		position: static;
	}

	.cl-legal-toc ol {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		column-gap: 22px;
	}
}

@media (max-width: 560px) {
	.cl-legal-shell {
		width: calc(100% - 24px);
	}

	.cl-legal-hero h1 {
		font-size: 40px;
	}

	.cl-legal-intro {
		font-size: 16px;
	}

	.cl-legal-toc ol {
		grid-template-columns: 1fr;
	}

	.cl-legal-section {
		padding-bottom: 38px;
	}

	.cl-legal-section + .cl-legal-section {
		padding-top: 38px;
	}

	.cl-legal-section h2 {
		font-size: 30px;
	}

	.cl-legal-prose {
		font-size: 15px;
	}

	.cl-legal-details > div {
		grid-template-columns: 1fr;
		gap: 4px;
	}

	.cl-legal-links {
		padding: 52px 0;
	}

	.cl-legal-links__grid {
		grid-template-columns: 1fr;
	}
}
