:root {
	--bg: #f3f7f8;
	--surface: #ffffff;
	--text: #1c2a30;
	--muted: #55696f;
	--accent: #1d5c70;
	--accent-soft: #dce9ee;
	--line: #cad9df;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #121c21;
		--surface: #1a272d;
		--text: #e5eef1;
		--muted: #9db2b9;
		--accent: #7fc0d3;
		--accent-soft: #21343c;
		--line: #2f434b;
	}
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
	font-family: "Alef", sans-serif;
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font-size: 1.15rem;
	line-height: 1.75;
}

.wrap {
	max-width: 46rem;
	margin: 0 auto;
	padding: 0 16px;
}

header.site {
	border-bottom: 1px solid var(--line);
	padding: 1rem 0;
	font-size: 1rem;
}

header.site .wrap {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 1rem;
	flex-wrap: wrap;
}

header.site a.brand {
	color: var(--accent);
	font-weight: 700;
	text-decoration: none;
	font-size: 1.15rem;
}

nav a {
	color: var(--muted);
	text-decoration: none;
	margin-inline-start: 1rem;
}

nav a:hover, nav a[aria-current] { color: var(--accent); }

h1, h2, h3 {
	line-height: 1.3;
	font-weight: 700;
}

h1 {
	font-size: clamp(2rem, 6vw, 2.9rem);
	margin: 0 0 .5rem;
}

h2 {
	font-size: 1.55rem;
	margin: 2.5rem 0 .75rem;
	color: var(--accent);
}

h3 {
	font-size: 1.2rem;
	margin: 1.75rem 0 .5rem;
}

a { color: var(--accent); }

.hero {
	display: grid;
	grid-template-columns: 1fr 15rem;
	gap: 2rem;
	align-items: center;
	padding: 2.5rem 0 1rem;
}

.hero .lead {
	font-size: 1.3rem;
	color: var(--muted);
	margin: 0;
}

.hero .dates {
	font-size: 1rem;
	color: var(--muted);
	letter-spacing: .05em;
	margin: 0 0 .25rem;
}

figure {
	margin: 1.75rem 0;
}

figure img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 4px;
	filter: sepia(.15);
}

figcaption {
	font-size: .9rem;
	color: var(--muted);
	margin-top: .4rem;
	line-height: 1.5;
}

.hero figure { margin: 0; }

.pair {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1.25rem;
}

blockquote {
	margin: 2rem 0;
	padding: 1rem 1.5rem;
	background: var(--accent-soft);
	border-inline-start: 4px solid var(--accent);
	border-radius: 4px;
	font-size: 1.25rem;
}

blockquote p { margin: 0; }

blockquote cite {
	display: block;
	margin-top: .5rem;
	font-size: .95rem;
	font-style: normal;
	color: var(--muted);
}

ul.goals {
	padding-inline-start: 1.25rem;
}

ul.goals li { margin-bottom: .4rem; }

.note {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: 1rem 1.25rem;
	font-size: 1rem;
	line-height: 1.6;
}

footer.site {
	margin-top: 3.5rem;
	border-top: 1px solid var(--line);
	padding: 1.5rem 0 2.5rem;
	font-size: .9rem;
	color: var(--muted);
	line-height: 1.6;
}

footer.site p { margin: .35rem 0; }

/* Code (takanon) page */
.code ol {
	padding-inline-start: 1.5rem;
}

.code ol ol {
	list-style: hebrew;
	margin-top: .35rem;
}

.code li { margin-bottom: .45rem; }

.code section {
	border-bottom: 1px solid var(--line);
	padding-bottom: .75rem;
}

.code section:last-of-type { border-bottom: none; }

.code h2 {
	font-size: 1.3rem;
	margin-top: 2rem;
}

.code .num {
	color: var(--muted);
	margin-inline-end: .4rem;
}



/* Press kit page */
.press { max-width: 56rem; }

.press h2 {
	border-top: 2px solid var(--line);
	padding-top: .75rem;
	margin-top: 3rem;
}

.press .when {
	color: var(--muted);
	font-size: 1rem;
	margin: -.25rem 0 .75rem;
}

.press table {
	width: 100%;
	border-collapse: collapse;
	font-size: 1rem;
	line-height: 1.6;
	margin: 1rem 0;
}

.press th, .press td {
	border: 1px solid var(--line);
	padding: .45rem .7rem;
	text-align: start;
	vertical-align: top;
}

.press th { background: var(--accent-soft); }

.toc {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: .8rem 1.25rem;
	font-size: 1rem;
	columns: 2 15rem;
}

.toc ol { margin: .25rem 0 0; padding-inline-start: 1.3rem; }

details { margin: .6rem 0; }

summary { cursor: pointer; color: var(--accent); font-weight: 700; }

.draft {
	white-space: pre-wrap;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: .8rem 1rem;
	margin: .5rem 0;
	font-size: 1rem;
	line-height: 1.7;
	unicode-bidi: plaintext;
}

.copy {
	font: inherit;
	font-size: .85rem;
	padding: .15rem .7rem;
	border: 1px solid var(--accent);
	border-radius: 4px;
	background: var(--surface);
	color: var(--accent);
	cursor: pointer;
}

.copy:hover { background: var(--accent); color: var(--surface); }

.small { font-size: .9rem; color: var(--muted); }

mark { background: #ffe58a; color: #222; padding: 0 .25em; }

@media print {
	details { display: block; }
	details > summary, .copy { display: none; }
}

@media (max-width: 640px) {
	.press table, .press thead, .press tbody, .press tr, .press td, .press th { display: block; }
	.press thead { display: none; }
	.press tr { border: 1px solid var(--line); border-radius: 6px; margin: 0 0 .8rem; }
	.press td { border: 0; padding: .25rem .7rem; }
	.press td::before { content: attr(data-label); display: block; font-size: .8rem; color: var(--muted); }
}

@media (max-width: 640px) {
	.hero {
		grid-template-columns: 1fr;
		padding-top: 1.5rem;
	}
	.hero figure {
		max-width: 14rem;
		order: -1;
	}
	.pair { grid-template-columns: 1fr; }
	nav a { margin-inline-start: 0; margin-inline-end: 1rem; }
}
