/* the app's own token file, copied in here by brand-sync: these pages have no bundler to
   resolve a package specifier, so the import names the served path. must precede the rules below */
@import "/tokens.css";

/* self-hosted: the pages must not hand a visitor's ip to a font cdn, least of all the privacy one.
   variable files, latin subset only — these pages are english */
@font-face {
	font-family: "Red Hat Display";
	font-style: normal;
	font-weight: 700 800;
	font-display: swap;
	src: url("/fonts/red-hat-display-latin.woff2") format("woff2");
}

@font-face {
	font-family: "Red Hat Text";
	font-style: normal;
	font-weight: 400 500;
	font-display: swap;
	src: url("/fonts/red-hat-text-latin.woff2") format("woff2");
}

/* the page gutter is this site's own spacing, on no token scale: the app's frame is Tailwind's step */
:root {
	--gutter: 1.5rem;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	background: var(--white);
	color: var(--slate-900);
	font-family: var(--font-sans);
	font-size: 1rem;
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
	font-family: var(--font-display);
	line-height: 1.2;
	letter-spacing: -0.02em;
	margin: 0;
}

a {
	color: var(--slate-900);
}

a:focus-visible {
	outline: 2px solid var(--slate-900);
	outline-offset: 3px;
	border-radius: 4px;
}

code {
	font-family: var(--font-mono);
	font-size: 0.9em;
	background: var(--slate-100);
	padding: 0.1em 0.35em;
	border-radius: 4px;
}

.mark {
	display: block;
	border-radius: 14px;
}

/* ------------------------------------------------------------------ frame
   every page is header / middle / footer, so the footer sits at the bottom of
   a short page instead of floating under the fold */

body {
	min-height: 100svh;
	display: grid;
	grid-template-rows: auto 1fr auto;
}

.masthead {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1.5rem;
	width: 100%;
	max-width: 62rem;
	margin-inline: auto;
	padding: 1.125rem var(--gutter);
}

.doc .masthead {
	max-width: 42rem;
	border-bottom: 1px solid var(--slate-200);
}

.brand {
	display: flex;
	align-items: center;
	gap: 0.625rem;
	font-family: var(--font-display);
	font-weight: 800;
	font-size: 1.0625rem;
	letter-spacing: -0.02em;
	text-decoration: none;
}

.brand .mark {
	width: 28px;
	height: 28px;
	border-radius: 8px;
}

/* pushed right whether or not a brand sits on the left */
.about {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem 1.25rem;
	margin-left: auto;
	font-size: 0.9375rem;
}

.about a {
	display: inline-flex;
	align-items: center;
	gap: 0.4375rem;
	min-height: 2rem;
	color: var(--slate-500);
	text-decoration: none;
	transition: color 120ms ease;
}

.about a:hover {
	color: var(--slate-900);
}

.i {
	flex: none;
	stroke-width: 1.75;
}

/* ------------------------------------------------------------------- home */

.home main {
	display: grid;
	place-content: center;
	justify-items: center;
	text-align: center;
	padding: 2rem var(--gutter) 4rem;
}

.mark.hero {
	width: 72px;
	height: 72px;
	margin-bottom: 1.5rem;
}

.home h1 {
	font-size: 2.5rem;
	font-weight: 800;
}

.tagline {
	margin: 0.75rem 0 0;
	max-width: 28rem;
	color: var(--slate-500);
	font-size: 1.0625rem;
	text-wrap: balance;
}

/* ------------------------------------------------------ privacy and terms */

.doc main {
	width: 100%;
	max-width: 42rem;
	margin-inline: auto;
	padding: clamp(2.5rem, 7vw, 3.75rem) var(--gutter) 0;
}

.doc h1 {
	font-size: clamp(1.75rem, 5vw, 2.125rem);
	font-weight: 800;
}

.titled {
	display: flex;
	align-items: center;
	gap: 0.625rem;
}

.titled .i {
	color: var(--slate-300);
}

.doc .stamp {
	margin: 0.625rem 0 0;
	color: var(--slate-500);
	font-size: 0.875rem;
}

.doc h2 {
	font-size: 1.25rem;
	font-weight: 700;
	margin: 3rem 0 0.75rem;
	padding-top: 1.5rem;
	border-top: 1px solid var(--slate-200);
}

.doc h3 {
	font-size: 1rem;
	font-weight: 700;
	margin: 1.75rem 0 0.4rem;
}

.doc p,
.doc li {
	color: var(--slate-700);
}

.doc p {
	margin: 0.875rem 0;
}

.doc ul {
	padding-left: 1.25rem;
	margin: 0.875rem 0;
}

.doc li {
	margin-block: 0.45rem;
}

.doc a {
	text-underline-offset: 0.2em;
	text-decoration-color: var(--slate-300);
}

.doc a:hover {
	text-decoration-color: currentColor;
}

/* ----------------------------------------------------------------- footer
   quiet by construction: the legal pages are a duty, not a destination */

footer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 1.25rem;
	width: 100%;
	max-width: 62rem;
	margin: 3rem auto 0;
	padding: 1.25rem var(--gutter) 2rem;
	font-size: 0.8125rem;
	color: var(--slate-500);
}

.doc footer {
	max-width: 42rem;
}

.legal {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.legal a {
	color: inherit;
	text-decoration: none;
}

.legal a:hover {
	color: var(--slate-900);
}

.legal span {
	color: var(--slate-300);
}

.copyright {
	margin: 0;
	margin-left: auto;
}

/* the github mark is a filled glyph, not a stroked one like the lucide set: it needs no stroke,
   and it reads a shade heavy beside them at the same box, so it sits a touch smaller */
.i.gh {
	stroke: none;
	width: 15px;
	height: 15px;
}

/* a link that is only its glyph: square, so it keeps a pressable area once the word is gone */
.about a.only-icon {
	justify-content: center;
	width: 2rem;
	gap: 0;
}

.about a.only-icon .i {
	width: 17px;
	height: 17px;
}
