/* =============================================================
   Erefugia: the public site
   On WIP's Ember design system (whatispossible.org/docs/design):
   warm grays and ink, blaze orange as a spark rather than a fill
   (an underline, a glowing edge, the one word that matters), soft
   corners, mixed-case Archivo headings, and Material elevation (a
   key shadow plus an ambient one). Daylight by default; it follows
   the visitor's own dark setting.

   Every colour is a token below. The sections only use the tokens,
   so both themes come from here.
   ============================================================= */

/* ---------- Fonts: Archivo and Inter, served from fonts/ (SIL Open Font License) ---------- */

@font-face {
	font-family: "Archivo";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	font-stretch: 62% 125%;
	src: url(fonts/archivo-latin-standard-normal.woff2) format("woff2-variations");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
	}

@font-face {
	font-family: "Archivo";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	font-stretch: 62% 125%;
	src: url(fonts/archivo-latin-ext-standard-normal.woff2) format("woff2-variations");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
	}

@font-face {
	font-family: "Inter";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	src: url(fonts/inter-latin-wght-normal.woff2) format("woff2-variations");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
	}

@font-face {
	font-family: "Inter";
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	src: url(fonts/inter-latin-ext-wght-normal.woff2) format("woff2-variations");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
	}

@font-face {
	font-family: "Inter";
	font-style: italic;
	font-display: swap;
	font-weight: 100 900;
	src: url(fonts/inter-latin-wght-italic.woff2) format("woff2-variations");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
	}

/* ---------- Tokens: daylight ---------- */

:root {
	color-scheme: light dark;

	/* The palette */
	--night: #0C090A;
	--eigengrau: #16161D;
	--gray-900: #45454A;
	--gray-700: #737377;
	--gray-500: #A2A2A5;
	--gray-300: #D0D0D2;
	--reverse-eigengrau: #E9E9E2;
	--blaze: #FF7900;
	--copper: #B87333;

	/* What things are */
	--page: var(--reverse-eigengrau);
	--band: #E1E1DA;                     /* a quiet band across the page */
	--surface: #FBFBF8;                  /* a raised card */
	--text: var(--eigengrau);
	--muted: var(--gray-900);            /* 7.8:1 on the page */
	--line: var(--gray-300);
	--line-strong: var(--gray-500);
	--border: var(--gray-700);           /* outlined buttons: 3:1 or better */
	--edge: 1px solid rgba(12, 9, 10, 0.09);

	/* The spark */
	--accent: var(--blaze);              /* marks only: never text on light, never a big fill */
	--accent-strong: #9A4A00;            /* blaze as text: 5.1:1 */
	--accent-soft: #FBE3CC;              /* a blaze wash */
	--strong-bg: var(--eigengrau);       /* the primary action */
	--on-strong: var(--reverse-eigengrau);
	--spark: inset 0 -3px 0 var(--blaze);
	--spark-hover: inset 0 -4px 0 var(--blaze);
	--spark-text: linear-gradient(90deg, #C45A00, #8C5A2B);   /* large text only: 3.6:1 to 4.8:1 */
	--focus: #9A4A00;

	/* The dark section (What Is Possible), in both themes */
	--dark-bg: var(--eigengrau);
	--dark-surface: #1E1E26;
	--dark-text: var(--reverse-eigengrau);
	--dark-muted: #C9C9C4;
	--dark-line: #34343C;
	--dark-accent: #FFB067;

	/* Elevation, after Material: a key shadow and an ambient one */
	--elev-1: 0 1px 2px rgba(12, 9, 10, 0.24), 0 1px 3px 1px rgba(12, 9, 10, 0.12);
	--elev-2: 0 1px 2px rgba(12, 9, 10, 0.24), 0 2px 6px 2px rgba(12, 9, 10, 0.13);

	--radius: 6px;
	--radius-lg: 12px;
	--ease: cubic-bezier(0.2, 0, 0, 1);

	--font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--font-display: "Archivo", "Arial Narrow", "Inter", system-ui, sans-serif;
	--font-mark: "Permanent Marker", "Archivo", cursive;
	}

/* ---------- Tokens: dark, when the visitor's system asks for it ---------- */

@media (prefers-color-scheme: dark) {
	:root {
		--page: var(--eigengrau);
		--band: #1A1A21;
		--surface: #1E1E26;
		--text: var(--reverse-eigengrau);
		--muted: var(--gray-500);          /* 7:1 */
		--line: #34343C;
		--line-strong: #4A4A52;
		--border: var(--gray-700);
		--edge: 1px solid rgba(233, 233, 226, 0.08);

		--accent-strong: #FF9A3D;
		--accent-soft: rgba(255, 121, 0, 0.16);
		--strong-bg: var(--reverse-eigengrau);
		--on-strong: var(--night);
		--spark-text: linear-gradient(90deg, #FF9A3D, #D9955A);
		--focus: #FFB067;

		--dark-bg: var(--night);           /* a step darker than the page */
		--dark-surface: #16161D;

		--elev-1: 0 1px 2px rgba(0, 0, 0, 0.5), 0 1px 3px 1px rgba(0, 0, 0, 0.3);
		--elev-2: 0 1px 2px rgba(0, 0, 0, 0.5), 0 2px 6px 2px rgba(0, 0, 0, 0.3);
		}
	}

/* ---------- Base ---------- */

*,
*::before,
*::after {
	box-sizing: border-box;
	}

html {
	scroll-behavior: smooth;
	scroll-padding-top: 16px;
	}

body {
	margin: 0;
	background: var(--page);
	color: var(--text);
	font-family: var(--font-body);
	font-size: 17px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	}

h1, h2, h3 {
	margin: 0;
	font-family: var(--font-display);
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.01em;
	}

h1 {
	font-size: clamp(40px, 6vw, 72px);
	font-weight: 850;
	font-stretch: 88%;
	line-height: 1.04;
	max-width: 900px;
	}

h2 {
	font-size: clamp(30px, 4vw, 40px);
	font-stretch: 92%;
	}

h3 {
	font-size: 22px;
	font-weight: 750;
	font-stretch: 96%;
	}

p {
	margin: 0;
	}

a {
	color: var(--text);
	text-decoration-color: var(--accent);
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
	}

a:hover {
	text-decoration-thickness: 3px;
	}

:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 3px;
	border-radius: 4px;
	}

.muted {
	color: var(--muted);
	}

.wrap {
	max-width: 1120px;
	margin: 0 auto;
	padding-left: 24px;
	padding-right: 24px;
	}

.stack {
	display: flex;
	flex-direction: column;
	gap: 14px;
	}

/* The word that matters, lit: blaze into copper, as text */
.spark-text {
	background: var(--spark-text);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	}

.skip {
	position: absolute;
	left: -9999px;
	top: 8px;
	z-index: 10;
	padding: 10px 16px;
	border-radius: var(--radius);
	background: var(--strong-bg);
	color: var(--on-strong);
	box-shadow: var(--spark);
	font-weight: 600;
	}

.skip:focus {
	left: 8px;
	}

/* ---------- Header ---------- */

.site-header {
	background: var(--surface);
	border-bottom: 1px solid var(--line);
	box-shadow: var(--elev-1);
	}

.nav {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 24px;
	padding-top: 14px;
	padding-bottom: 14px;
	}

.brand {
	display: flex;
	align-items: center;
	gap: 10px;
	color: var(--text);
	text-decoration: none;
	}

.brand-mark {
	flex: none;
	}

.brand-leaf {
	fill: var(--accent);
	}

.logo {
	font-family: var(--font-mark);
	font-size: 34px;
	font-weight: 400;
	line-height: 1;
	letter-spacing: -0.01em;
	}

.nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0 24px;
	font-size: 15px;
	font-weight: 600;
	}

.nav-links a {
	display: inline-block;
	padding: 10px 0;
	text-decoration: none;
	box-shadow: inset 0 0 0 var(--accent);
	transition: box-shadow 0.2s var(--ease);
	}

.nav-links a:hover {
	box-shadow: inset 0 -3px 0 var(--accent);
	}

/* ---------- Buttons ---------- */

.actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	padding-top: 8px;
	}

.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 22px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--surface);
	color: var(--text);
	font-weight: 600;
	text-decoration: none;
	transition: box-shadow 0.2s var(--ease), transform 0.2s var(--ease);
	}

.button:hover {
	box-shadow: var(--elev-1);
	transform: translateY(-1px);
	}

.button.primary {
	border-color: transparent;
	background: var(--strong-bg);
	color: var(--on-strong);
	box-shadow: var(--spark), var(--elev-1);
	}

.button.primary:hover {
	box-shadow: var(--spark-hover), var(--elev-2);
	}

/* ---------- Sections ---------- */

.hero {
	display: flex;
	flex-direction: column;
	gap: 28px;
	padding-top: 96px;
	padding-bottom: 80px;
	}

.pill {
	align-self: flex-start;
	padding: 6px 14px;
	border-radius: 999px;
	background: var(--accent-soft);
	color: var(--accent-strong);
	font-size: 14px;
	font-weight: 600;
	}

.lede {
	max-width: 720px;
	color: var(--muted);
	font-size: 20px;
	}

.band {
	background: var(--band);
	border-top: 1px solid var(--line);
	border-bottom: 1px solid var(--line);
	}

.name {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 24px 64px;
	padding-top: 48px;
	padding-bottom: 48px;
	}

.name h2 {
	flex: 0 1 280px;
	font-size: 24px;
	font-stretch: 96%;
	}

.name .stack {
	flex: 1 1 480px;
	}

.section {
	display: flex;
	flex-direction: column;
	gap: 40px;
	padding-top: 96px;
	padding-bottom: 96px;
	}

.section-head {
	display: flex;
	flex-direction: column;
	gap: 12px;
	max-width: 720px;
	}

.eyebrow {
	color: var(--dark-accent);
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	}

/* ---------- Cards ---------- */

.cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
	gap: 20px;
	align-items: start;
	}

.card {
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 28px;
	border: var(--edge);
	border-radius: var(--radius-lg);
	background: var(--surface);
	box-shadow: var(--elev-1);
	}

/* A cause: the same card, with a blaze edge along its top */
.cause {
	box-shadow: inset 0 3px 0 var(--accent), var(--elev-1);
	}

/* ---------- What Is Possible: the dark section ---------- */

.dark {
	background: var(--dark-bg);
	color: var(--dark-text);
	--text: var(--dark-text);
	--muted: var(--dark-muted);
	--focus: var(--dark-accent);
	}

.split {
	display: flex;
	flex-wrap: wrap;
	gap: 48px;
	padding-top: 96px;
	padding-bottom: 96px;
	}

.split .intro {
	flex: 1 1 380px;
	}

.split .products {
	flex: 1 1 480px;
	gap: 16px;
	}

.dark .card {
	padding: 24px;
	border: 1px solid var(--dark-line);
	background: var(--dark-surface);
	box-shadow: none;
	}

.dark h3 {
	font-size: 20px;
	}

.dark h3 a {
	color: var(--dark-text);
	}

.dark strong {
	color: var(--dark-text);
	}

.dark summary {
	color: var(--dark-accent);
	}

/* ---------- How we're run ---------- */

.principles {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
	gap: 32px 40px;
	align-items: start;
	}

.principle {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding-top: 16px;
	border-top: 2px solid var(--accent);
	}

.principle h3 {
	font-size: 19px;
	}

/* ---------- Join ---------- */

.join {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: 40px;
	padding-top: 96px;
	padding-bottom: 96px;
	}

.join-text {
	flex: 1 1 460px;
	}

.contact {
	flex: 1 1 360px;
	gap: 14px;
	}

.contact h3 {
	font-size: 20px;
	}

.contact .button {
	white-space: normal;
	text-align: center;
	}

/* ---------- Footer ---------- */

.site-footer {
	border-top: 1px solid var(--line);
	}

.footer {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 12px;
	padding-top: 32px;
	padding-bottom: 32px;
	color: var(--muted);
	font-size: 14px;
	}

/* ---------- Read more ---------- */

details > summary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	list-style: none;
	cursor: pointer;
	color: var(--accent-strong);
	font-weight: 600;
	}

details > summary::-webkit-details-marker {
	display: none;
	}

details > summary .chev {
	transition: transform 0.2s var(--ease);
	}

details > summary .chev path {
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
	}

details[open] > summary .chev {
	transform: rotate(180deg);
	}

.more {
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding-top: 4px;
	color: var(--muted);
	font-size: 16px;
	}

.more ul {
	margin: 0;
	padding-left: 20px;
	display: flex;
	flex-direction: column;
	gap: 6px;
	}

.more strong {
	color: var(--text);
	}

/* ---------- Phones ---------- */

@media (max-width: 640px) {
	.hero {
		padding-top: 56px;
		padding-bottom: 56px;
		}

	.section,
	.split,
	.join {
		padding-top: 64px;
		padding-bottom: 64px;
		}

	.lede {
		font-size: 18px;
		}

	.card {
		padding: 22px;
		}
	}

/* ---------- Less motion ---------- */

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
		}

	details > summary .chev,
	.button,
	.nav-links a {
		transition: none;
		}

	.button:hover {
		transform: none;
		}
	}
