/* RelaxJer's landing page: postcards from the trip (DESIGN.md, "Surface: the landing page").
   They lie under one trip day's sky, from a morning sun to lantern night; the night theme is the same page under stars. Each feature is a postcard: its picture side replays
   the synthetic demo trip on a small phone (the .m screens copy the trip page's own layout and tokens), its back is
   written plainly. Everything operated is system sans; headlines are Gabarito; the brand and the brushed lines are
   Ma Shan Zheng. Both faces are self-hosted subsets (fonts/, with their SIL OFL licences). */
@font-face {
	font-family: 'Ma Shan Zheng';
	src: url('fonts/ma-shan-zheng-subset.woff2') format('woff2');
	font-display: swap;
	/* a subset: only the glyphs this page letters (see fonts/OFL.txt) */
}
@font-face {
	font-family: 'Gabarito';
	src: url('fonts/gabarito-latin.woff2') format('woff2');
	font-weight: 400 900;
	font-display: swap;
	/* the Latin subset (see fonts/OFL-gabarito.txt) */
}

:root {
	/* the landing world */
	--table: #c9e0f7; /* the day sky at its plainest: what the ground falls back to */
	/* one slow day, top to bottom: morning, a long clear afternoon, golden hour, the rose before dusk */
	--sky-1: #d3e6f9;
	--sky-2: #c9e0f7;
	--sky-3: #bfd9f4;
	--sky-35: #e6dcf2; /* the turn of the afternoon: blue to gold through lilac, never grey */
	--sky-4: #f7dfc4;
	--sky-5: #f7d9d0;
	--sky-6: #e9dcf1;
	--sun: #ffd79c;
	--sun-low: #ffa977; /* the sun as it sets, low and warm */
	--sun-travel: 1; /* how far down the screen it sinks by the foot of the page */
	--pic-dusk: 0%; /* how far a postcard's colour sinks toward the night sky: by day, not at all */
	--pic-lift: #ffffff; /* the light at the top of a postcard's picture */
	--vault: #15161a; /* the privacy card's picture: a dark room, in both themes */
	--vault-ink: #ffffff;
	--moon-o: 1; /* the moon over the footer: by day only, since the night sky already has one */
	--cloud-o: 1;
	--birds-o: 0.5;
	--stars-o: 0;
	--by-night: 0;
	--table-2: #d2dff0;
	--stock: #ffffff; /* postcard stock */
	--stock-2: #f3f5f9;
	--stock-edge: rgba(24, 44, 84, 0.1);
	--rule: #c9d6e8; /* hairlines on the table */
	--rule-card: #dfe2e8; /* hairlines on a card */
	--red: #d9352b; /* airmail chevrons = lantern 1 */
	--blue: #2466c8; /* airmail chevrons = lantern 2 */
	--blue-ink: #ffffff; /* text on --blue: 5.6:1 by day; at night the picture sinks to #3e60a0, still 6.5:1 */
	--postmark: rgba(31, 46, 79, 0.62);
	--card-shadow: 0 1px 1px rgba(24, 44, 84, 0.06), 0 16px 34px -20px rgba(24, 44, 84, 0.5);
	--lift-shadow: 0 2px 2px rgba(24, 44, 84, 0.06), 0 26px 50px -24px rgba(24, 44, 84, 0.55);
	--device: #15161a;
	--device-edge: transparent;

	/* the trip page's own tokens (DESIGN.md), for text and for the phone screens */
	--paper: #ffffff;
	--paper-2: #f3f4f7;
	--paper-3: #e7e9ee;
	--ink: #15161a;
	--ink-2: #464a53;
	--ink-3: #545963;
	--line: #dfe2e8;
	--seal: #c42a1f;
	--seal-ink: #ffffff;
	--good: #1a7443; /* the trip page's good, for its Planner badge */
	--focus: #1f5fd1;
	--link: #1d5bc4;
	--warn: #9a5700;
	--bad: #b3261e;
	--hl: #ffe45c;
	--hl-ink: #111; /* text on the yellow, dark in both themes, as the trip page writes it */
	--glass: rgba(255, 255, 255, 0.6);
	--glass-edge: rgba(24, 44, 84, 0.1);
	--scrim: rgba(12, 14, 20, 0.5);
	--code: #f3f5f9;

	--l1: #d9352b;
	--l1-ink: #ffffff;
	--l2: #2466c8;
	--l2-ink: #ffffff;
	--l3: #ec6a1c;
	--l3-ink: #1c0d02;
	--l4: #1b7f52;
	--l4-ink: #ffffff;
	--l5: #8a3ca6;
	--l5-ink: #ffffff;
	--l6: #ee82a6;
	--l6-ink: #25070f;
	--l7: #e0b020;
	--l7-ink: #1d1502;
	--night: #1d2a44;
	--night-ink: #ffffff;

	--font-ui:
		-apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', 'Noto Sans SC', 'Microsoft YaHei', 'Segoe UI', Roboto, 'Helvetica Neue',
		Arial, sans-serif;
	--font-head: 'Gabarito', var(--font-ui);
	--font-brush: 'Ma Shan Zheng', 'STKaiti', 'KaiTi', 'Kaiti SC', 'BiauKai', serif;
	--font-code: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

	--wide: 76rem;
	--r-card: 6px; /* postcard stock */
	--r-md: 12px; /* controls, as on the trip page */
	--ease-out: cubic-bezier(0.23, 1, 0.32, 1);
	--ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
	color-scheme: light;
}

/* the night theme: the system's dark, unless the bar's button asked for day (theme.js) … */
@media (prefers-color-scheme: dark) {
	:root:not([data-theme='light']) {
		--table: #0d1426;
		--sky-1: #0c1424;
		--sky-2: #0e172c;
		--sky-3: #121a36;
		--sky-35: #151839;
		--sky-4: #18173a;
		--sky-5: #1d1736;
		--sky-6: #151127;
		--sun: #e9e4ff; /* the moon */
		--sun-low: #e9e4ff; /* the moon keeps its colour */
		--sun-travel: 0.35; /* and only drifts a little */
		--pic-dusk: 40%; /* by night each colour glows like a lantern, not a lamp */
		--pic-lift: #3b4668;
		--vault: #343c52;
		--vault-ink: #eef0f4;
		--moon-o: 0;
		--cloud-o: 0.07;
		--birds-o: 0;
		--stars-o: 0.85;
		--by-night: 1;
		--table-2: #111722;
		--stock: #161b25;
		--stock-2: #1e2430;
		--stock-edge: rgba(238, 240, 244, 0.08);
		--rule: #263041;
		--rule-card: #2a313d;
		--red: #e8564b;
		--blue: #5b8fe6;
		--postmark: rgba(201, 211, 230, 0.82);
		--card-shadow: 0 0 0 1px rgba(238, 240, 244, 0.06), 0 18px 40px -22px rgba(0, 0, 0, 0.9);
		--lift-shadow: 0 0 0 1px rgba(238, 240, 244, 0.08), 0 28px 56px -24px rgba(0, 0, 0, 0.95);
		--device: #000000;
		--device-edge: rgba(238, 240, 244, 0.14);

		--paper: #0c1017;
		--paper-2: #151a23;
		--paper-3: #1e2430;
		--ink: #eef0f4;
		--ink-2: #bcc1cb;
		--ink-3: #969ca8;
		--line: #2a313d;
		--seal: #ff6a5c;
		--seal-ink: #1a0503;
		--good: #5fd49a;
		--focus: #7fb0ff;
		--link: #8ab8ff;
		--warn: #f3b35a;
		--bad: #ff8a80;
		--glass: rgba(12, 18, 36, 0.72);
		--glass-edge: rgba(238, 240, 244, 0.08);
		--scrim: rgba(0, 0, 0, 0.62);
		--code: #1e2430;
		--night: #26324d;
		color-scheme: dark;
	}
}
/* … or the button asked for night. Both blocks must read the same: tests/repo/site.test.mjs holds them to it. */
:root[data-theme='dark'] {
	--table: #0d1426;
	--sky-1: #0c1424;
	--sky-2: #0e172c;
	--sky-3: #121a36;
	--sky-35: #151839;
	--sky-4: #18173a;
	--sky-5: #1d1736;
	--sky-6: #151127;
	--sun: #e9e4ff; /* the moon */
	--sun-low: #e9e4ff; /* the moon keeps its colour */
	--sun-travel: 0.35; /* and only drifts a little */
	--pic-dusk: 40%; /* by night each colour glows like a lantern, not a lamp */
	--pic-lift: #3b4668;
	--vault: #343c52;
	--vault-ink: #eef0f4;
	--moon-o: 0;
	--cloud-o: 0.07;
	--birds-o: 0;
	--stars-o: 0.85;
	--by-night: 1;
	--table-2: #111722;
	--stock: #161b25;
	--stock-2: #1e2430;
	--stock-edge: rgba(238, 240, 244, 0.08);
	--rule: #263041;
	--rule-card: #2a313d;
	--red: #e8564b;
	--blue: #5b8fe6;
	--postmark: rgba(201, 211, 230, 0.82);
	--card-shadow: 0 0 0 1px rgba(238, 240, 244, 0.06), 0 18px 40px -22px rgba(0, 0, 0, 0.9);
	--lift-shadow: 0 0 0 1px rgba(238, 240, 244, 0.08), 0 28px 56px -24px rgba(0, 0, 0, 0.95);
	--device: #000000;
	--device-edge: rgba(238, 240, 244, 0.14);

	--paper: #0c1017;
	--paper-2: #151a23;
	--paper-3: #1e2430;
	--ink: #eef0f4;
	--ink-2: #bcc1cb;
	--ink-3: #969ca8;
	--line: #2a313d;
	--seal: #ff6a5c;
	--seal-ink: #1a0503;
	--good: #5fd49a;
	--focus: #7fb0ff;
	--link: #8ab8ff;
	--warn: #f3b35a;
	--bad: #ff8a80;
	--glass: rgba(12, 18, 36, 0.72);
	--glass-edge: rgba(238, 240, 244, 0.08);
	--scrim: rgba(0, 0, 0, 0.62);
	--code: #1e2430;
	--night: #26324d;
	color-scheme: dark;
}

* {
	box-sizing: border-box;
}
html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: 5.5rem;
	background: var(--table);
}
@supports (font: -apple-system-body) {
	html {
		font: -apple-system-body;
		font-size: max(100%, 1rem);
	}
}
body {
	position: relative;
	margin: 0;
	background: linear-gradient(
		to bottom,
		var(--sky-1) 0,
		var(--sky-2) 8%,
		var(--sky-3) 52%,
		var(--sky-35) 62%,
		var(--sky-4) 72%,
		var(--sky-5) 86%,
		var(--sky-6) 100%
	);
	color: var(--ink);
	font-family: var(--font-ui);
	font-size: 1.0625rem;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
	overflow-x: clip;
}
::selection {
	background: color-mix(in srgb, var(--blue) 26%, transparent);
}

/* ───────── the sky behind everything: a sun over the morning, clouds through the day, stars by night ───────── */
.scene {
	--lane: max(16px, (100% - var(--wide)) / 2 + 16px);
	position: absolute;
	inset: 0;
	z-index: 0;
	overflow: hidden;
	pointer-events: none;
}
.scene::before {
	/* stars: night only (the tokens give them no opacity by day) */
	content: '';
	position: absolute;
	inset: 0;
	opacity: var(--stars-o);
	background: url('stars.svg') 0 0 / 480px 480px;
}
main {
	position: relative;
	z-index: 1;
	/* a tilted postcard or the hero phone can reach past the edge as it settles; the body's clip only hides that
	   (the viewport still pans into it on a phone), clipping here removes it */
	overflow-x: clip;
}
.sunpath {
	/* the sun's frame: the page's first screen, until the scroll can carry it (then the screen itself) */
	position: absolute;
	inset: 0 0 auto;
	height: max(100vh, 760px);
	overflow: hidden;
}
.sun {
	position: absolute;
	top: clamp(-220px, -14vw, -90px);
	right: clamp(-200px, -10vw, -70px);
	width: clamp(380px, 50vw, 720px);
	aspect-ratio: 1;
	border-radius: 50%;
	background: radial-gradient(
		circle,
		color-mix(in srgb, var(--sun) 80%, #fff) 0 13%,
		color-mix(in srgb, var(--sun) 72%, transparent) 14%,
		color-mix(in srgb, var(--sun) 30%, transparent) 36%,
		transparent 68%
	);
}
.sun::after {
	/* the same sun at dusk, faded in as it sinks */
	content: '';
	position: absolute;
	inset: 0;
	border-radius: 50%;
	opacity: 0;
	background: radial-gradient(
		circle,
		color-mix(in srgb, var(--sun-low) 80%, #fff) 0 13%,
		color-mix(in srgb, var(--sun-low) 72%, transparent) 14%,
		color-mix(in srgb, var(--sun-low) 30%, transparent) 36%,
		transparent 68%
	);
}
.cloud {
	position: absolute;
	top: var(--y);
	left: var(--x);
	width: var(--w);
	aspect-ratio: 320 / 120;
	opacity: calc(var(--o) * var(--cloud-o));
	background: url('cloud.svg') center / contain no-repeat;
	filter: drop-shadow(0 18px 24px rgba(36, 70, 120, 0.12));
}
.birds {
	position: absolute;
	top: var(--y);
	left: var(--x);
	width: var(--w);
	aspect-ratio: 120 / 50;
	opacity: var(--birds-o);
	background: url('birds.svg') center / contain no-repeat;
}
/* the lanterns keep to the side lanes (--lane), the margin outside the text column, so none ever sits behind a word;
   on a phone the lane is the 16 px gutter and they shrink to fit it */
.scene .lit {
	--s: clamp(10px, var(--lane) - 6px, var(--w));
	position: absolute;
	top: var(--y);
	left: calc((var(--lane) - var(--s)) * var(--j));
	width: var(--s);
	height: var(--s);
	filter: drop-shadow(0 0 8px rgba(255, 178, 84, 0.9)) drop-shadow(0 0 22px rgba(255, 140, 60, 0.4));
}
.scene .lit.r {
	left: auto;
	right: calc((var(--lane) - var(--s)) * var(--j));
}
.scene .by-night {
	opacity: var(--by-night);
}
@media (max-width: 599px) {
	/* a phone has no side lanes: a lantern in the 16 px gutter reads as a speck, so they keep to the footer's night */
	.scene .lit {
		display: none;
	}
	.cloud {
		width: calc(var(--w) * 0.62);
	}
	.birds {
		width: calc(var(--w) * 0.75);
	}
}
a {
	color: var(--link);
	text-decoration-line: underline;
	text-decoration-thickness: max(1px, 0.08em);
	text-underline-offset: 0.18em;
}
@media (hover: hover) and (pointer: fine) {
	a:hover {
		text-decoration-thickness: 2px;
	}
}
:focus-visible {
	outline: 3px solid var(--focus);
	outline-offset: 2px;
	border-radius: 6px;
}
h1,
h2,
h3 {
	margin: 0;
	line-height: 1.12;
	text-wrap: balance;
}
p {
	margin: 0;
	text-wrap: pretty;
}
code {
	font-family: var(--font-code);
	font-size: 0.9em;
}
img {
	display: block;
	max-width: 100%;
	height: auto;
}
.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}
svg.i {
	width: 1.1em;
	height: 1.1em;
	flex: none;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}
.skip {
	position: absolute;
	left: 16px;
	top: -100px;
	z-index: 60;
	padding: 12px 16px;
	background: var(--ink);
	color: var(--paper);
	border-radius: var(--r-md);
}
.skip:focus {
	top: 12px;
}
.brush {
	font-family: var(--font-brush);
	font-weight: 400;
	letter-spacing: 0.02em;
}

/* ───────── the sticky bar ───────── */
.bar {
	position: sticky;
	top: 0;
	z-index: 40;
	background: var(--glass);
	-webkit-backdrop-filter: blur(20px) saturate(180%);
	backdrop-filter: blur(20px) saturate(180%);
	box-shadow: 0 1px 0 var(--glass-edge);
}
.bar-row {
	max-width: var(--wide);
	margin: 0 auto;
	padding: 6px 16px;
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 64px;
}
.brand {
	font-family: var(--font-brush);
	font-size: 1.75rem;
	line-height: 1;
	color: var(--ink);
	text-decoration: none;
	margin-right: auto;
	display: inline-flex;
	align-items: center;
	gap: 2px;
	min-height: 48px;
}
/* the logo's lantern (scripts/docs-update/site-logo.mjs); its box has the lantern's own side margins */
.brand picture {
	flex: none;
}
.brand img {
	display: block;
	max-width: none;
	width: 36px;
	height: 36px;
	margin-left: -7px;
}
.nav {
	display: flex;
	gap: 4px;
}
.nav a,
.nav-theme {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding: 0 12px;
	border-radius: 10px;
	color: var(--ink);
	font-weight: 650;
	font-size: 0.9375rem;
	text-decoration: none;
	transition:
		background-color 160ms ease,
		transform 160ms var(--ease-out);
}
.nav-theme {
	justify-content: center;
	width: 44px;
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	cursor: pointer;
}
.nav-theme[hidden] {
	display: none;
}
.nav-theme svg {
	width: 20px;
	height: 20px;
}
.nav a:active,
.nav-theme:active {
	background: var(--table-2);
	transform: scale(0.97);
	transition-duration: 0ms;
}
.nav .nav-gh {
	background: var(--stock);
	box-shadow: inset 0 0 0 1px var(--stock-edge);
}
@media (hover: hover) and (pointer: fine) {
	.nav a:hover,
	.nav-theme:hover {
		background: var(--table-2);
	}
	.nav .nav-gh:hover {
		background: var(--stock-2);
	}
}
@media (max-width: 599px) {
	.nav-wide {
		display: none !important;
	}
}

/* ───────── shared pieces of the world ───────── */

/* airmail chevrons: red and blue, the edge of every envelope */
.airmail {
	--w: 9px;
	background: repeating-linear-gradient(-45deg, var(--red) 0 13px, transparent 13px 19px, var(--blue) 19px 32px, transparent 32px 38px);
}
.airmail-frame {
	position: absolute;
	inset: 0;
	padding: var(--w, 9px);
	border-radius: inherit;
	pointer-events: none;
	-webkit-mask:
		linear-gradient(#000 0 0) content-box,
		linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask:
		linear-gradient(#000 0 0) content-box exclude,
		linear-gradient(#000 0 0);
}

/* a perforated stamp: the holes punch only the edge, the content box stays whole */
.stamp {
	--hole: 3.2px;
	--pitch: 10px;
	position: relative;
	display: grid;
	width: 84px;
	height: 100px;
	padding: 6px;
	background: #fbfcfe;
	-webkit-mask:
		linear-gradient(#000 0 0) content-box,
		radial-gradient(circle var(--hole), #0000 96%, #000) calc(var(--pitch) / -2) calc(var(--pitch) / -2) / var(--pitch) var(--pitch) round;
	mask:
		linear-gradient(#000 0 0) content-box,
		radial-gradient(circle var(--hole), #0000 96%, #000) calc(var(--pitch) / -2) calc(var(--pitch) / -2) / var(--pitch) var(--pitch) round;
	filter: drop-shadow(0 1px 1px rgba(24, 44, 84, 0.18));
	flex: none;
}
.stamp-face {
	position: relative;
	display: grid;
	grid-template-rows: 1fr auto;
	justify-items: center;
	align-items: center;
	padding: 6px 4px 5px;
	background: var(--c, var(--l1));
	color: var(--ci, #fff);
	overflow: hidden;
}
.stamp-face svg {
	width: 34px;
	height: 40px;
}
.stamp-face b {
	font: 800 0.625rem/1 var(--font-head);
	letter-spacing: 0.08em;
	text-transform: uppercase;
}
.stamp-face .den {
	position: absolute;
	left: 5px;
	top: 4px;
	font: 800 0.6875rem/1 var(--font-head);
}

/* a round postmark, inked over the stamp */
.postmark {
	position: absolute;
	width: 132px;
	height: 92px;
	color: var(--postmark);
	pointer-events: none;
	transform: rotate(-11deg);
}
.postmark text {
	font: 700 9.5px var(--font-ui);
	letter-spacing: 0.14em;
	fill: currentColor;
}

/* the brushed line on a card's back: a short note in the planner's hand */
.note-brush {
	font-family: var(--font-brush);
	font-size: clamp(1.9rem, 3.4vw, 2.5rem);
	line-height: 1.05;
	letter-spacing: 0.04em;
	color: var(--hand, var(--ink));
}

/* the seal: fixed, as on the trip page */
.seal {
	display: inline-grid;
	place-items: center;
	width: 1.35em;
	height: 1.35em;
	border-radius: 3px;
	background: var(--seal);
	color: var(--seal-ink);
	font-family: var(--font-brush);
	font-size: 0.95em;
	line-height: 1;
	transform: rotate(-4deg);
	vertical-align: -0.2em;
}

/* the main button: ink, as on the trip page */
.go {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	min-height: 56px;
	padding: 0 24px;
	border-radius: var(--r-md);
	background: var(--ink);
	color: var(--paper);
	font-weight: 750;
	font-size: 1.0625rem;
	text-decoration: none;
	transition:
		transform 160ms var(--ease-out),
		background-color 160ms ease;
}
.go:active {
	transform: scale(0.97);
	transition-duration: 0ms;
}
/* the second choice beside it: the same size and shape, on postcard stock */
.go-paper {
	background: var(--stock);
	color: var(--ink);
	box-shadow: inset 0 0 0 1px var(--stock-edge);
}
@media (hover: hover) and (pointer: fine) {
	.go-paper:hover {
		background: var(--stock-2);
	}
}

/* ───────── hero ───────── */
.hero {
	max-width: var(--wide);
	margin: 0 auto;
	padding: clamp(36px, 6vw, 80px) 16px clamp(56px, 7vw, 96px);
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 48px;
	align-items: center;
}
@media (min-width: 960px) {
	.hero {
		grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
		gap: 40px;
		padding-inline: 24px;
	}
}
.hero h1 {
	font-size: clamp(4.5rem, 15vw, 8rem);
	line-height: 0.92;
	font-weight: 400;
	letter-spacing: 0.01em;
}
.meaning {
	margin-top: 14px;
	font-size: 1.1875rem;
	font-weight: 650;
	color: var(--ink-2);
}
.lede {
	margin-top: 22px;
	max-width: 22ch;
	font-family: var(--font-head);
	font-size: clamp(1.5rem, 2.9vw, 2.125rem);
	line-height: 1.4;
	font-weight: 700;
	letter-spacing: -0.015em;
}
.actions {
	margin-top: 32px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
}
/* on a phone the pair stacks, each the full width, so neither wraps alone */
@media (max-width: 559px) {
	.actions {
		flex-direction: column;
		align-items: stretch;
	}
	.actions .go {
		justify-content: center;
	}
}

/* the hero's table: a picture postcard under, the back of one on top, a phone lying across it */
.desk {
	position: relative;
	min-height: clamp(430px, 62vw, 560px);
	isolation: isolate;
}
.pc {
	position: absolute;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
}
.pc-front {
	left: 0;
	top: 0;
	width: min(68%, 400px);
	aspect-ratio: 3 / 2;
	padding: 10px;
	transform: rotate(-6deg);
	z-index: 1;
}
/* the sky's own colour is the night at its top, where the caption sits; the dusk glow is a layer under the art and the
   caption, so a contrast check reads the colour really behind the words, not the glow's first stop under the hills */
.sky {
	position: relative;
	height: 100%;
	border-radius: 3px;
	overflow: hidden;
	background: #121a33;
}
.sky::before {
	content: '';
	position: absolute;
	inset: 0;
	background: radial-gradient(120% 90% at 50% 120%, #f6a35c 0%, #c24a4a 30%, #3c2a63 62%, #121a33 100%);
}
.sky .hills {
	position: absolute;
	inset: auto 0 0;
	width: 100%;
	height: 38%;
}
.sky .caption {
	position: absolute;
	left: 12px;
	top: 10px;
	color: #fff;
	font-family: var(--font-brush);
	font-size: 1.5rem;
	line-height: 1;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.sky .flier {
	position: absolute;
	width: 22px;
	left: var(--x);
	bottom: var(--y);
	animation: rise 14s linear infinite;
	animation-delay: var(--d);
	filter: drop-shadow(0 0 6px rgba(255, 186, 92, 0.85));
}
@keyframes rise {
	0% {
		transform: translate(0, 0) scale(1);
		opacity: 0;
	}
	8% {
		opacity: 1;
	}
	50% {
		transform: translate(10px, -90px) scale(0.82);
	}
	100% {
		transform: translate(-6px, -190px) scale(0.6);
		opacity: 0;
	}
}
.pc-back {
	right: 4%;
	top: 15%;
	width: min(88%, 540px);
	aspect-ratio: 3 / 2;
	padding: 22px 22px 20px;
	transform: rotate(2.2deg);
	z-index: 2;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) 1px minmax(0, 1fr);
	gap: 0 18px;
}
.pc-back .airmail-frame {
	--w: 8px;
	inset: 0;
	opacity: 0.95;
}
.pc-msg {
	display: grid;
	align-content: start;
	gap: 10px;
	padding-top: 8px;
}
.pc-msg .note-brush {
	font-size: clamp(1.5rem, 3.4vw, 2.125rem);
}
.pc-msg p {
	font-size: 0.9375rem;
	line-height: 1.45;
	color: var(--ink-2);
}
.pc-msg .sign {
	font-family: var(--font-brush);
	font-size: 1.625rem;
	color: var(--ink);
}
.pc-div {
	background: var(--rule-card);
	margin: 10px 0;
}
.pc-addr {
	position: relative;
	display: grid;
	align-content: start;
	gap: 0;
	/* the address starts right below the stamp and its postmark, however its lines wrap, which leaves the corner the
	   phone lies across empty */
	padding: 116px 0 6px;
}
.pc-addr .stamp {
	position: absolute;
	right: 0;
	top: 4px;
}
.pc-addr .postmark {
	/* level with the stamp, striking its left edge as a real one does, never over the address */
	right: 44px;
	top: 10px;
}
.pc-addr p {
	padding: 7px 0 3px;
	border-bottom: 1px solid var(--rule-card);
	font-size: 0.875rem;
	font-weight: 650;
	color: var(--ink);
}
.pc-addr p:first-child {
	font-weight: 750;
}
.desk .phone {
	position: absolute;
	right: -3%;
	bottom: -14%;
	width: clamp(150px, 26%, 190px);
	transform: rotate(9deg);
	z-index: 3;
}
.pc-addr p {
	margin-right: 30%; /* clear of the phone lying across the corner */
}
@media (max-width: 959px) {
	.desk {
		max-width: 620px;
		width: 100%;
		margin: 0 auto;
	}
}
@media (max-width: 559px) {
	.desk {
		min-height: 440px;
	}
	.pc-front {
		width: 70%;
	}
	.pc-back {
		right: 2%;
		top: 64px;
		width: 96%;
		aspect-ratio: auto;
		min-height: 300px;
		padding: 18px 16px 16px;
		grid-template-columns: minmax(0, 1fr);
		grid-template-rows: auto auto;
		gap: 12px;
	}
	.pc-div {
		display: none;
	}
	.pc-msg {
		padding-right: 84px;
	}
	.pc-addr {
		position: static;
		padding: 0 0 4px; /* the stamp sits beside the message here, and the postmark is left off */
	}
	.pc-addr p {
		margin-right: 34%;
	}
	.pc-addr .stamp {
		top: 18px;
		right: 14px;
		width: 70px;
		height: 84px;
		--pitch: 9px;
		--hole: 2.8px;
	}
	.pc-addr .postmark {
		display: none;
	}
	.desk .phone {
		width: 31%;
		right: 2%; /* the 9° tilt swings a corner past the edge at right: 0 */
		bottom: -8%;
	}
}

/* a phone: an ink device frame, its screen a real capture (hero) or a demo (.m) */
.phone {
	margin: 0;
	padding: 6px;
	border-radius: 26px;
	background: var(--device);
	box-shadow:
		0 0 0 1px var(--device-edge),
		0 26px 46px -22px rgba(12, 18, 34, 0.6);
}
.phone > img,
.phone > picture img {
	width: 100%;
	aspect-ratio: 390 / 844;
	object-fit: cover;
	object-position: top;
	border-radius: 20px;
}

/* ───────── bands ───────── */
.band {
	max-width: var(--wide);
	margin: 0 auto;
	padding: clamp(64px, 9vw, 120px) 16px 0;
}
@media (min-width: 960px) {
	.band {
		padding-inline: 24px;
	}
}
.band > h2,
.band-head h2 {
	font-family: var(--font-head);
	font-size: clamp(2.125rem, 5vw, 3.5rem);
	font-weight: 800;
	letter-spacing: -0.025em;
	line-height: 1.04;
	max-width: 18ch;
}
.section-lede {
	margin-top: 16px;
	max-width: 58ch;
	font-size: 1.1875rem;
	color: var(--ink-2);
}
.band > p:not(.section-lede) {
	margin-top: 16px;
	max-width: 68ch;
}

/* ───────── the postcards: spread on the table ───────── */
.spread {
	margin-top: clamp(36px, 5vw, 56px);
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: clamp(28px, 4vw, 44px);
}
@media (min-width: 900px) {
	.spread {
		grid-template-columns: repeat(12, minmax(0, 1fr));
		gap: 48px 36px;
		align-items: start;
	}
	.w7 {
		grid-column: span 7;
	}
	.w5 {
		grid-column: span 5;
	}
	.w8 {
		grid-column: span 8;
	}
	.w4 {
		grid-column: span 4;
	}
	.w12 {
		grid-column: 1 / -1;
	}
	.drop {
		margin-top: 56px;
	}
}
.card {
	--tilt: 0deg;
	position: relative;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
	transform: rotate(var(--tilt));
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	overflow: hidden;
	scroll-margin-top: 6rem;
}
.card.flat {
	grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 700px) {
	.card.land {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	}
	.card.land.rev .pic {
		order: 2;
	}
}
.t-l {
	--tilt: -0.9deg;
}
.t-r {
	--tilt: 0.8deg;
}
.t-r2 {
	--tilt: 1.3deg;
}
.t-l2 {
	--tilt: -1.4deg;
}
/* stacked on a phone a card runs ~1000 px tall, so a full tilt swings its corners past the 16 px gutter */
@media (max-width: 699px) {
	.t-l,
	.t-l2 {
		--tilt: -0.4deg;
	}
	.t-r,
	.t-r2 {
		--tilt: 0.4deg;
	}
}

/* the picture side: one spot colour at full strength, printed with a faint halftone; by night it sinks toward the sky */
.pic {
	--pic: color-mix(in srgb, var(--spot), var(--sky-3) var(--pic-dusk));
	position: relative;
	display: grid;
	place-items: center;
	padding: 28px 18px 64px;
	background-color: var(--pic);
	background-image:
		radial-gradient(color-mix(in srgb, var(--spot-ink) 12%, transparent) 0.9px, transparent 1.3px),
		radial-gradient(
			circle at 84% 13%,
			color-mix(in srgb, #fff 58%, var(--pic)) 0 30px,
			color-mix(in srgb, #fff 22%, transparent) 31px,
			transparent 130px
		),
		linear-gradient(to bottom, color-mix(in srgb, var(--pic-lift) 24%, var(--pic)), var(--pic) 62%);
	background-size:
		7px 7px,
		100% 100%,
		100% 100%;
	color: var(--spot-ink);
	min-height: 100%;
	isolation: isolate;
}
.pic::after {
	/* the hills, in a deeper shade of the card's colour */
	content: '';
	position: absolute;
	inset: auto 0 0;
	z-index: -1;
	height: 26%;
	background: color-mix(in srgb, var(--pic) 74%, #000);
	-webkit-mask: url('hills.svg') bottom / 100% 100% no-repeat;
	mask: url('hills.svg') bottom / 100% 100% no-repeat;
	pointer-events: none;
}
.pic-cap {
	position: absolute;
	left: 16px;
	top: 14px;
	font-family: var(--font-brush);
	font-size: 1.375rem;
	line-height: 1;
	opacity: 0.9;
}
.back::before,
.packing::before {
	content: '';
	position: absolute;
	inset: 0 0 auto;
	height: 6px;
	background: repeating-linear-gradient(-45deg, var(--red) 0 13px, transparent 13px 19px, var(--blue) 19px 32px, transparent 32px 38px);
	opacity: 0.9;
}
.back {
	position: relative;
	padding: clamp(22px, 3vw, 34px) clamp(20px, 3vw, 34px) clamp(24px, 3vw, 34px);
	display: grid;
	align-content: start;
	gap: 12px;
}
.back h3 {
	font-family: var(--font-head);
	font-size: clamp(1.5rem, 2.4vw, 1.875rem);
	font-weight: 800;
	letter-spacing: -0.02em;
	line-height: 1.1;
	max-width: 20ch;
}
.back:has(> .stamp) > .note-brush {
	min-height: 66px;
	padding-right: 150px;
}
.back p {
	color: var(--ink-2);
	max-width: 46ch;
}
.back .note-brush {
	--hand: color-mix(in srgb, var(--spot) 72%, var(--ink));
	font-size: clamp(1.75rem, 2.8vw, 2.25rem);
}
.back .stamp {
	position: absolute;
	right: 18px;
	top: 18px;
	width: 62px;
	height: 74px;
	--pitch: 8px;
	--hole: 2.6px;
	padding: 5px;
	transform: rotate(3deg);
}
.back .stamp-face svg {
	width: 24px;
	height: 28px;
}
.back .stamp-face b {
	font-size: 0.5rem;
}
.back .postmark {
	right: 50px;
	top: 26px;
	width: 100px;
	height: 70px;
}
.back .small {
	font-size: 0.9375rem;
	color: var(--ink-3);
}
.back .small b {
	color: var(--ink-2);
}

/* the pause button on every demo (WCAG 2.2.2): a round paper disc with the glyph alone, under the phone's right edge
   in the card's bottom margin, so it never covers the screen it controls. Its words are for screen readers */
.pause {
	position: absolute;
	top: 100%;
	right: 0;
	z-index: 5;
	margin-top: 10px;
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--stock);
	color: var(--ink);
	box-shadow:
		0 0 0 1px var(--stock-edge),
		0 6px 14px -8px rgba(12, 18, 34, 0.5);
	cursor: pointer;
	transition: transform 160ms var(--ease-out);
}
.pause:focus-visible {
	border-radius: 50%;
}
.pause:active {
	transform: scale(0.96);
	transition-duration: 0ms;
}
.pause svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
	stroke: none;
}
.pause .play-i,
.pause[data-paused] .pause-i {
	display: none;
}
.pause[data-paused] .play-i {
	display: block;
}
@media (hover: hover) and (pointer: fine) {
	.pause:hover {
		background: var(--stock-2);
	}
}

/* ───────── the demo phones ───────── */
.demo {
	position: relative;
	margin: 0;
	display: grid;
	justify-items: center;
	--k: 0.6;
	--T: 10s;
}
.demo .phone {
	width: calc(390px * var(--k) + 12px);
	padding: 6px;
	border-radius: calc(44px * var(--k) + 6px);
}
.demo .screen {
	width: calc(390px * var(--k));
	height: calc(760px * var(--k));
	border-radius: calc(44px * var(--k));
	overflow: hidden;
	position: relative;
}
.demo .m {
	position: absolute;
	left: 0;
	top: 0;
	transform: scale(var(--k));
	transform-origin: 0 0;
}
@media (min-width: 900px) {
	.demo {
		--k: 0.64;
	}
	.w12 .demo {
		--k: 0.6;
	}
}
@media (max-width: 420px) {
	.demo {
		--k: 0.5;
	}
	.pic {
		padding: 22px 14px 66px;
	}
}

/* the sync postcard: two phones and the airmail route between them; the pair is one demo */
.demo.pair {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 8px;
	align-items: start;
	width: 100%;
	max-width: 640px;
	margin: 0 auto;
	--k: 0.42;
}
@media (min-width: 520px) {
	.demo.pair {
		--k: 0.5;
	}
}
@media (min-width: 900px) {
	.w12 .demo.pair {
		--k: 0.58;
		gap: 40px;
		max-width: 720px;
	}
}
.pair figure {
	margin: 0;
	display: grid;
	justify-items: center;
}
.pair figcaption {
	margin-top: 10px;
	text-wrap: balance;
	font-weight: 750;
	font-size: 0.9375rem;
	text-align: center;
	color: var(--spot-ink);
}
.route {
	grid-column: 1 / -1;
	width: 100%;
	height: auto;
	margin-bottom: -2%;
	overflow: visible;
	pointer-events: none;
}
.route .arc {
	fill: none;
	stroke: var(--spot-ink);
	stroke-width: 2.4;
	stroke-dasharray: 7 7;
	stroke-linecap: round;
	opacity: 0.75;
}

/* ───────── the mini trip page (.m): the trip page's layout at 390 px, scaled down ───────── */
.m {
	--c: var(--l3);
	--ci: var(--l3-ink);
	--m-bar-h: 70px; /* the bottom bar: its 56 px items and a strip for the home bar */
	width: 390px;
	height: 760px;
	overflow: hidden;
	background: var(--paper);
	color: var(--ink);
	font: 400 17px/1.45 var(--font-ui);
	text-align: left;
	-webkit-font-smoothing: antialiased;
}
.m * {
	animation-duration: var(--T);
	animation-iteration-count: infinite;
	animation-fill-mode: both;
	animation-timing-function: var(--ease-out);
}
.m svg {
	width: 18px;
	height: 18px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
	flex: none;
}
.d3 {
	--c: var(--l3);
	--ci: var(--l3-ink);
}
.d5 {
	--c: var(--l5);
	--ci: var(--l5-ink);
}
.d6 {
	--c: var(--l6);
	--ci: var(--l6-ink);
}
.m-sb,
.m-hd,
.m-daybar {
	position: relative;
	z-index: 2;
	background: var(--paper);
}
.m-sb {
	height: 34px;
	padding: 0 28px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	font: 650 15px/1 var(--font-ui);
}
.m-sb .sig {
	display: inline-flex;
	gap: 6px;
	align-items: center;
}
.m-sb .sig svg {
	width: 17px;
	height: 17px;
}
/* the header: one 54 px row, as the trip page draws it on a phone (the brand, then search, currency and language), over
   the Now stripe: the day's colour on a day, a hairline on Today and the other views (--now) */
.m-hd {
	height: 57px;
	padding: 0 16px 0 18px;
	display: flex;
	align-items: center;
	gap: 8px;
	border-bottom: 3px solid var(--now, var(--c));
}
.m-brand {
	margin-right: auto;
	font: 400 27px/1 var(--font-brush);
	letter-spacing: 0.04em;
}
.m-ib {
	width: 44px;
	height: 44px;
	display: grid;
	place-items: center;
	border-radius: 12px;
}
.m-ib svg {
	width: 22px;
	height: 22px;
}
.m-lang {
	background: var(--paper-3);
	font-weight: 750;
}
.m-daybar {
	height: 40px;
	padding: 8px 18px;
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 15px;
	white-space: nowrap;
	overflow: hidden;
	border-bottom: 1px solid var(--line);
}
.m-daybar::before {
	content: '';
	width: 12px;
	height: 12px;
	border-radius: 3px;
	background: var(--c);
	flex: none;
}
.m-daybar b {
	font-weight: 750;
}
.m-daybar span {
	color: var(--ink-2);
	overflow: hidden;
	text-overflow: ellipsis;
}
.m-body {
	position: relative;
	padding: 14px 16px 0;
}

/* the Now/Next card */
.m-now {
	border-radius: 18px;
	background: var(--paper-2);
	padding: 18px 18px 16px;
}
.m-now-h {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 19px;
	font-weight: 750;
}
.m-chip-day {
	padding: 3px 9px;
	border-radius: 6px;
	background: var(--c);
	color: var(--ci);
	font-size: 17px;
	font-weight: 750;
}
.m-wish {
	margin: 8px 0 6px;
	font: 400 36px/1.1 var(--font-brush);
	letter-spacing: 0.06em;
}
.m-kv {
	position: relative;
	display: grid;
	grid-template-columns: 86px minmax(0, 1fr);
	height: 158px;
	overflow: hidden;
}
.m-kv .keys {
	display: grid;
	grid-template-rows: 79px 79px;
	font-size: 14px;
	font-weight: 750;
	letter-spacing: 0.06em;
	color: var(--ink-3);
	padding-top: 14px;
}
.m-kv .vals {
	display: grid;
	grid-template-rows: repeat(3, 79px);
}
.m-kv .v {
	padding-top: 10px;
	font-size: 17px;
	line-height: 1.35;
	font-weight: 650;
}
.m-kv .v span {
	display: block;
	text-decoration: underline;
	text-decoration-color: var(--line);
	text-underline-offset: 4px;
}
.m-link {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 10px;
	min-height: 44px;
	color: var(--link);
	font-size: 15px;
	font-weight: 700;
}
.m-go {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	height: 48px;
	padding: 0 18px;
	border-radius: 12px;
	background: var(--ink);
	color: var(--paper);
	font-weight: 700;
	font-size: 16px;
}
/* the bottom bar (ADR-20261124-bottom-app-bar; DESIGN.md, Bottom bar): Today, Days, Map and More, each a 24 px mark
   over its word, on plain paper along the screen's foot. The lit item fills its mark's 56 × 30 px tile at 18 %
   and goes 800 in ink, two cues; the tile takes the day's colour on a day (.m-tabbar.day), ink elsewhere. Today's mark
   carries the date (data-d). Sheets, the scrim and the toast sit over the bar, as on the phone */
.m-tabbar {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 3;
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(0, 1fr);
	height: var(--m-bar-h);
	padding: 0 8px calc(var(--m-bar-h) - 56px);
	/* plain paper, not the trip page's glass: a backdrop blur inside each scaled, rounded screen escapes its corners in
	   Chromium, isn't drawn in WebKit, and on a GPU-less WebKit (CI) fourteen of them slow the page to a crawl */
	background: var(--paper);
	box-shadow: 0 -1px 0 var(--glass-edge);
}
.m-tabbar.day {
	--tb-c: var(--c);
}
.m-tb {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 2px;
	min-width: 0;
	height: 56px;
	padding: 4px 2px 5px; /* the 30 px tile, a 2 px gap and the label's whole line, so nothing clips its descenders */
	color: var(--ink-2);
	font-size: 13px;
	font-weight: 650;
	line-height: 1.15;
}
.m-tb svg {
	box-sizing: border-box;
	width: 56px;
	height: 30px;
	padding: 3px 16px;
	border-radius: 10px;
	stroke-width: 1.9;
}
.m-tb > span {
	flex: none;
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.m-tb[data-d]::before {
	content: attr(data-d);
	position: absolute;
	left: 0;
	right: 0;
	top: 16px; /* 12 px into the tile, under the calendar's top rule */
	font-size: 9.5px;
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.02em;
	text-align: center;
}
.m-tb.on {
	color: var(--ink);
	font-weight: 800;
}
.m-tb.on svg {
	background: color-mix(in srgb, var(--tb-c, var(--ink)) 18%, transparent);
	stroke-width: 2.2;
}

/* the schedule string */
.m-sched {
	list-style: none;
	margin: 0;
	padding: 6px 0 0;
}
.m-row {
	display: grid;
	grid-template-columns: 70px 26px minmax(0, 1fr);
	column-gap: 6px;
	padding-bottom: 18px;
	position: relative;
}
.m-row::before {
	content: '';
	position: absolute;
	left: 87px;
	top: 0;
	bottom: 0;
	width: 2px;
	background: color-mix(in srgb, var(--c) 55%, transparent);
}
.m-t {
	position: relative;
	text-align: right;
	font-size: 15px;
	font-weight: 750;
	line-height: 1.3;
	padding-top: 1px;
	font-variant-numeric: tabular-nums;
}
.m-t.big {
	font-size: 21px;
	letter-spacing: -0.02em;
	line-height: 1.15;
}
.m-k {
	position: relative;
	display: grid;
	justify-items: center;
	padding-top: 4px;
	z-index: 1;
}
.m-k i {
	display: block;
	width: 14px;
	height: 14px;
	border-radius: 50%;
	background: var(--paper);
	border: 2.5px solid var(--c);
}
.m-k i.now {
	background: color-mix(in srgb, var(--c) 55%, var(--ink));
	border-color: color-mix(in srgb, var(--c) 55%, var(--ink));
	box-shadow: 0 0 0 5px color-mix(in srgb, var(--c) 28%, transparent);
}
.m-k i.fix {
	width: 13px;
	height: 13px;
	margin-top: 2px;
	border: 0;
	border-radius: 1px;
	background: var(--seal);
	transform: rotate(45deg);
}
.m-k i.split {
	border-style: dashed;
	border-color: var(--c);
}
.m-s {
	min-width: 0;
}
.m-name {
	font-size: 17px;
	font-weight: 700;
	line-height: 1.3;
}
.m-note {
	margin-top: 3px;
	font-size: 15px;
	color: var(--ink-2);
	line-height: 1.4;
}
.m-tag {
	display: inline-block;
	margin-left: 6px;
	padding: 1px 7px;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 750;
	vertical-align: 2px;
}
.m-tag.now {
	background: var(--c);
	color: var(--ci);
}
.m-tag.next {
	box-shadow: inset 0 0 0 1.5px var(--ink);
}
.m-tag.who {
	box-shadow: inset 0 0 0 1.5px var(--line);
	color: var(--ink-2);
}
.m-tag.mine {
	background: color-mix(in srgb, var(--c) 22%, var(--paper));
	color: var(--ink);
}
.m-fixed {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	margin-left: 6px;
	color: var(--seal);
	font-size: 13px;
	font-weight: 750;
	vertical-align: 1px;
}
.m-fixed .seal {
	font-size: 14px;
	width: 20px;
	height: 20px;
}
.m-links {
	display: flex;
	gap: 8px;
	margin-top: 8px;
}
.m-links span {
	width: 44px;
	height: 44px;
	border-radius: 10px;
	background: var(--paper-2);
	color: var(--link);
	display: grid;
	place-items: center;
}
.m-box {
	margin: 0 0 16px 0;
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--paper-2);
}
.m-box-h {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 15px;
	font-weight: 700;
	color: var(--ink-2);
}
.m-pill {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 8px;
	padding: 9px 12px;
	border-radius: 8px;
	background: var(--paper);
	font-size: 15px;
	font-weight: 700;
	box-shadow: 0 1px 0 var(--line);
}
.m-pill.dash {
	box-shadow: none;
	outline: 1.5px dashed var(--line);
	outline-offset: -1.5px;
	display: flex;
	justify-content: space-between;
}
.m-pill small {
	font-size: 14px;
	font-weight: 600;
	color: var(--ink-2);
}
.m-wc {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	margin: 0 0 16px;
	height: 44px;
	border-radius: 12px;
	box-shadow: inset 0 0 0 1px var(--line);
	font-size: 15px;
	font-weight: 700;
}
.m-wc svg {
	color: var(--link);
}
.m-add {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 8px;
	height: 48px;
	margin: 4px 0 0;
	border-radius: 12px;
	box-shadow: inset 0 0 0 1.5px var(--line);
	font-size: 16px;
	font-weight: 700;
}
.m-rejoin {
	display: flex;
	gap: 8px;
	align-items: flex-start;
	margin-top: 8px;
	font-size: 15px;
	color: var(--ink-2);
	border-radius: 6px;
}
.m-rejoin svg {
	margin-top: 2px;
}

/* the sheet, the scrim, the toast and the finger */
.m-scrim {
	position: absolute;
	inset: 0;
	background: var(--scrim);
	opacity: 0;
	z-index: 4;
}
.m-sheet {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 5;
	padding: 26px 20px 24px;
	border-radius: 20px 20px 0 0;
	background: var(--paper);
	box-shadow: 0 -10px 40px -16px rgba(0, 0, 0, 0.45);
	transform: translateY(105%);
}
.m-sheet::before {
	content: '';
	position: absolute;
	left: 50%;
	top: 8px;
	width: 40px;
	height: 5px;
	margin-left: -20px;
	border-radius: 3px;
	background: var(--paper-3);
}
.m-sheet .x {
	position: absolute;
	right: 14px;
	top: 14px;
}
.m-sh-h {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 20px;
	font-weight: 800;
	letter-spacing: -0.01em;
	padding-right: 30px;
}
.m-sh-sub {
	margin-top: 6px;
	font-size: 15px;
	color: var(--ink-2);
	line-height: 1.45;
}
.m-row-btn {
	display: flex;
	align-items: center;
	gap: 14px;
	margin-top: 10px;
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--paper-2);
	font-size: 16px;
	font-weight: 700;
	line-height: 1.3;
}
.m-row-btn .lbl {
	width: 46px;
	flex: none;
	font-size: 15px;
	color: var(--ink-2);
}
.m-row-btn.ink {
	background: var(--ink);
	color: var(--paper);
}
.m-row-btn.blue {
	background: var(--link);
	color: var(--paper);
}
.m-row-btn .k {
	width: 14px;
	height: 14px;
	flex: none;
	border-radius: 50%;
	border: 2.5px solid color-mix(in srgb, var(--c) 55%, var(--ink));
}
.m-row-btn .k.now {
	background: color-mix(in srgb, var(--c) 55%, var(--ink));
	box-shadow: 0 0 0 5px color-mix(in srgb, var(--c) 28%, transparent);
}
.m-opts {
	display: grid;
	gap: 8px;
	margin-top: 12px;
}
.m-opt {
	display: flex;
	gap: 14px;
	padding: 12px 14px;
	border-radius: 10px;
	box-shadow: inset 0 0 0 1px var(--line);
	font-size: 15px;
	font-weight: 650;
}
.m-opt b {
	font-weight: 750;
	font-variant-numeric: tabular-nums;
}
.m-opt.on {
	background: var(--ink);
	color: var(--paper);
	box-shadow: none;
}
.m-seg {
	display: flex;
	gap: 4px;
	margin-top: 10px;
	padding: 4px;
	border-radius: 11px;
	background: var(--paper-3);
}
.m-seg span {
	flex: 1;
	height: 40px;
	display: grid;
	place-items: center;
	border-radius: 8px;
	font-size: 15px;
	font-weight: 650;
	color: var(--ink-2);
}
.m-seg span.on {
	background: var(--ink);
	color: var(--paper);
}
.m-subh {
	margin-top: 14px;
	font-size: 15px;
	font-weight: 750;
	color: var(--ink-2);
}
.m-toast {
	position: absolute;
	left: 50%;
	bottom: calc(var(--m-bar-h) + 12px); /* just above the bottom bar */
	z-index: 6;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 18px;
	border-radius: 12px;
	background: var(--ink);
	color: var(--paper);
	font-size: 15px;
	font-weight: 700;
	white-space: nowrap;
	box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.4);
	transform: translate(-50%, 16px);
	opacity: 0;
}
.m-toast u {
	text-decoration: none;
	color: color-mix(in srgb, var(--paper) 70%, var(--hl));
}
.m-finger {
	position: absolute;
	z-index: 9;
	width: 46px;
	height: 46px;
	margin: -23px 0 0 -23px;
	border-radius: 50%;
	background: color-mix(in srgb, var(--ink) 16%, transparent);
	box-shadow:
		0 0 0 2px color-mix(in srgb, var(--paper) 80%, transparent),
		0 0 0 4px color-mix(in srgb, var(--ink) 30%, transparent);
	opacity: 0;
	pointer-events: none;
}
.m-hl {
	border-radius: 6px;
}
/* the toast's action chip (Undo), the phone's own confirm dialog, and the Group sync sheet's lists */
.m-toast .act {
	margin: -4px -6px -4px 4px;
	padding: 6px 12px;
	border-radius: 8px;
	background: color-mix(in srgb, var(--paper) 20%, transparent);
	font-weight: 750;
}
.m-dlg {
	position: absolute;
	left: 34px;
	right: 34px;
	top: 172px;
	z-index: 6;
	padding: 20px 20px 16px;
	border-radius: 16px;
	background: var(--paper);
	box-shadow: 0 18px 50px -14px rgba(0, 0, 0, 0.5);
	font-size: 16px;
	line-height: 1.45;
	opacity: 0;
	transform: scale(0.94);
}
.m-dlg-acts {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	margin-top: 16px;
}
.m-dlg-acts span {
	padding: 10px 18px;
	border-radius: 10px;
	background: var(--paper-2);
	font-weight: 700;
}
.m-dlg-acts .ok {
	background: var(--ink);
	color: var(--paper);
}
.m-glist {
	margin: 6px 0 0;
	padding: 0;
	list-style: none;
}
.m-glist li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 10px 0;
	border-top: 1px solid var(--line);
	font-size: 16px;
	line-height: 1.35;
}
.m-glist small {
	display: block;
	font-size: 14px;
	color: var(--ink-2);
}
.m-glist small.m-flip {
	display: grid;
}
.m-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	flex: none;
	padding: 9px 12px;
	border-radius: 10px;
	background: var(--paper-2);
	color: var(--link);
	font-size: 15px;
	font-weight: 700;
	white-space: nowrap;
}
.m-chip.danger {
	background: color-mix(in srgb, var(--seal) 12%, var(--paper));
	color: var(--seal);
}
.m-chip svg {
	width: 15px;
	height: 15px;
}
.m-badge {
	display: inline-block;
	margin-left: 8px;
	padding: 1px 7px;
	border-radius: 6px;
	background: color-mix(in srgb, var(--good) 16%, transparent);
	color: var(--good);
	font-size: 12px;
	font-weight: 750;
	vertical-align: 2px;
}
.m-flip {
	display: grid;
}
.m-flip > * {
	grid-area: 1 / 1;
}
.m-banner {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	padding: 10px 12px;
	border-radius: 12px;
	background: color-mix(in srgb, var(--warn) 14%, var(--paper));
	font-size: 14px;
	line-height: 1.4;
}
.m-banner svg {
	color: var(--warn);
	margin-top: 1px;
}
.m-check {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 0;
	border-bottom: 1px solid var(--line);
	font-size: 16px;
	font-weight: 650;
}
.m-check i {
	position: relative;
	width: 26px;
	height: 26px;
	flex: none;
	border-radius: 7px;
	box-shadow: inset 0 0 0 2px var(--ink-3);
}
.m-check i b {
	position: absolute;
	inset: 0;
	border-radius: 7px;
	background: var(--good)
		url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7'/%3E%3C/svg%3E")
		center / 18px no-repeat;
	opacity: 0;
}
.m-check.done i b {
	opacity: 1;
}
.m-check.done span {
	color: var(--ink-3);
	text-decoration: line-through;
}
.m-prog {
	height: 8px;
	margin: 10px 0 4px;
	border-radius: 4px;
	background: var(--paper-3);
	overflow: hidden;
}
.m-prog i {
	display: block;
	height: 100%;
	width: 100%;
	border-radius: inherit;
	background: var(--good);
	transform-origin: 0 50%;
	transform: scaleX(0.25);
}
.m-card {
	margin-top: 12px;
	padding: 16px;
	border-radius: 12px;
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
}
.m-card.rec {
	box-shadow: inset 0 0 0 2px var(--ink);
}
.m-card-top {
	display: grid;
	grid-template-columns: 36px minmax(0, 1fr);
	gap: 4px 10px;
	align-items: start;
}
.m-card-top .m-amt {
	grid-column: 1 / -1;
}
.m-card-top .ico {
	width: 32px;
	height: 32px;
	border-radius: 8px;
	background: var(--paper-2);
	display: grid;
	place-items: center;
}
.m-card-top .nm {
	font-size: 17px;
	font-weight: 750;
	line-height: 1.25;
}
.m-card-top .nm small {
	display: block;
	font-size: 15px;
	font-weight: 650;
	color: var(--ink-2);
}
.m-amt {
	text-align: right;
	font-size: 15px;
	line-height: 1.35;
	color: var(--ink-2);
	font-variant-numeric: tabular-nums;
}
.m-amt b {
	display: block;
	font-size: 19px;
	font-weight: 800;
	color: var(--ink);
}
.m-amt span {
	display: block;
	border-radius: 4px;
	padding: 0 3px;
	margin-right: -3px;
}
.m-facts {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 8px;
	margin-top: 12px;
}
.m-facts span {
	padding: 8px;
	border-radius: 8px;
	background: var(--paper-2);
	font-size: 15px;
	font-weight: 750;
	line-height: 1.25;
}
.m-facts small {
	display: block;
	font-size: 11px;
	font-weight: 650;
	color: var(--ink-2);
}
.m-search {
	display: flex;
	align-items: center;
	gap: 10px;
	height: 46px;
	margin-top: 14px;
	padding: 8px 12px;
	border-radius: 12px;
	background: var(--paper-3);
	font-size: 17px;
}
.m-search svg {
	color: var(--ink-3);
}
.m-type {
	display: inline-block;
	overflow: hidden;
	white-space: nowrap;
	vertical-align: bottom;
	width: 0;
	border-right: 2px solid var(--link);
}
.m-res {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 0;
	border-bottom: 1px solid var(--line);
}
.m-res .nm {
	flex: 1;
	font-size: 16px;
	font-weight: 750;
	line-height: 1.3;
}
.m-res .nm small {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: var(--ink-2);
}
.m-res .add {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	height: 40px;
	padding: 0 12px;
	border-radius: 10px;
	background: var(--paper-2);
	color: var(--seal);
	font-size: 15px;
	font-weight: 700;
}
.m-lock {
	display: grid;
	justify-items: center;
	gap: 14px;
	padding: 120px 28px 0;
	text-align: center;
}
.m-lock .lk {
	width: 64px;
	height: 64px;
	border-radius: 18px;
	background: var(--paper-2);
	display: grid;
	place-items: center;
}
.m-lock .lk svg {
	width: 30px;
	height: 30px;
}
.m-lock .h {
	font-size: 22px;
	font-weight: 800;
}
.m-lock .fld {
	width: 100%;
	height: 50px;
	border-radius: 12px;
	background: var(--paper-3);
	display: flex;
	align-items: center;
	padding: 8px 16px;
	font-size: 22px;
	letter-spacing: 0.3em;
	text-align: left;
}
.m-lock .m-go {
	width: 100%;
	justify-content: center;
}

/* Now and Next as rows that can change (the running-late and home-screen demos) */
.m-nn {
	display: grid;
	grid-template-columns: 86px minmax(0, 1fr);
	row-gap: 12px;
	align-content: start;
}
.m-nn .k {
	padding-top: 3px;
	font-size: 14px;
	font-weight: 750;
	letter-spacing: 0.06em;
	color: var(--ink-3);
}
.m-nn .v {
	font-size: 17px;
	line-height: 1.35;
	font-weight: 650;
	font-variant-numeric: tabular-nums;
}
.m-nn .v span {
	display: block;
	text-decoration: underline;
	text-decoration-color: var(--line);
	text-underline-offset: 4px;
}
.m-nn .v b {
	font-weight: 650;
}
.m-shifted {
	grid-column: 1 / -1;
	display: grid;
	gap: 6px;
	padding-top: 4px;
	font-size: 15px;
	font-weight: 650;
}
.m-shifted > span {
	display: flex;
	gap: 8px;
	align-items: center;
}
.m-shifted svg {
	color: var(--warn);
}
.m-shifted .a {
	gap: 28px;
	padding-left: 26px;
	color: var(--link);
	font-weight: 700;
}
.m-shifted u {
	text-decoration: none;
}
/* the running-late box, as the trip page draws it */
.m-late-wrap {
	overflow: hidden;
	max-height: 0;
}
.m-late {
	display: grid;
	justify-items: start;
	gap: 8px;
	margin-top: 14px;
	padding: 12px 14px 14px;
	border-radius: 12px;
	background: var(--paper);
	border: 1px solid color-mix(in srgb, var(--warn) 45%, var(--line));
}
.m-late .h {
	display: flex;
	gap: 8px;
	align-items: flex-start;
	font-size: 17px;
	font-weight: 800;
	line-height: 1.3;
}
.m-late .h svg {
	margin-top: 2px;
	color: var(--warn);
}
.m-late .h b {
	font-weight: 800;
}
.m-late .t {
	font-size: 15px;
	line-height: 1.45;
	color: var(--ink-2);
}
.m-ghost {
	display: inline-flex;
	align-items: center;
	height: 48px;
	padding: 0 18px;
	border-radius: 12px;
	box-shadow: inset 0 0 0 1.5px var(--line);
	font-size: 16px;
	font-weight: 700;
}
.m-now > .m-go {
	margin-top: 14px;
}
/* location in use: the arrow beside the clock, as the phone shows it */
.m-clk {
	display: inline-flex;
	align-items: center;
	gap: 5px;
}
.m-clk .loc svg {
	width: 13px;
	height: 13px;
	fill: currentColor;
	stroke-width: 1.5;
}

/* the home-screen demo: the page in the browser, the home screen, then the page full screen */
.m-pg {
	position: absolute;
	inset: 0;
	background: var(--paper);
	transform-origin: 58px 98px;
}
.m-inst {
	display: inline-flex;
	align-items: center;
	max-width: 120px;
	height: 44px;
	padding: 0 10px;
	overflow: hidden;
	white-space: nowrap;
	border-radius: 12px;
	background: color-mix(in srgb, var(--link) 12%, transparent);
	color: var(--link);
	font-size: 16px;
	font-weight: 750;
}
/* while Install shows beside the currency, the trip page's phone header keeps Install's word without its mark and steps
   the brand down, so the row still fits; on the home screen Install is gone and the brand is whole again (home-brand) */
.x-home .m-brand {
	font-size: 20px;
	animation-name: home-brand;
	animation-timing-function: step-end;
}
.m-tbar {
	position: relative;
	z-index: 2;
	height: 52px;
	padding: 5px 16px;
	overflow: hidden;
	background: var(--paper-2);
	border-bottom: 1px solid var(--line);
}
.m-tbar .url {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 6px;
	height: 40px;
	border-radius: 10px;
	background: var(--paper);
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
	color: var(--ink-2);
	font-size: 15px;
	font-weight: 600;
}
.m-tbar .url svg {
	width: 14px;
	height: 14px;
}
.m-steps {
	display: grid;
	gap: 8px;
	margin: 12px 0 0;
	padding-left: 24px;
	font-size: 17px;
	font-weight: 650;
	line-height: 1.38;
}
.m-steps b {
	font-weight: 800;
}
.x-home .m-sheet .m-sh-sub {
	margin-top: 12px;
	font-size: 16px;
	color: var(--ink);
}
.m-home {
	position: absolute;
	inset: 0;
	z-index: 7;
	color: #ffffff;
	background:
		radial-gradient(120% 70% at 20% 0%, rgba(236, 106, 28, 0.38), transparent 60%),
		radial-gradient(90% 60% at 100% 100%, rgba(36, 102, 200, 0.45), transparent 65%), linear-gradient(175deg, #2a3560 0%, #1d2a44 50%, #0f1424 100%);
	opacity: 0;
}
.m-home .m-sb {
	background: none;
}
.m-home .app {
	position: absolute;
	left: 27px;
	top: 66px;
	width: 62px;
	display: grid;
	justify-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 600;
	line-height: 1;
	white-space: nowrap;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.m-home .tile {
	width: 62px;
	height: 62px;
	display: grid;
	place-items: center;
	border-radius: 15px;
	background: var(--l1);
	color: #ffffff;
	box-shadow: 0 6px 16px -8px rgba(0, 0, 0, 0.6);
}
.m-home .tile svg {
	width: 30px;
	height: 36px;
}
.m-home .find {
	position: absolute;
	left: 50%;
	bottom: 34px;
	display: flex;
	align-items: center;
	gap: 6px;
	height: 34px;
	padding: 0 16px;
	border-radius: 17px;
	background: rgba(255, 255, 255, 0.2);
	font-size: 14px;
	font-weight: 600;
	transform: translateX(-50%);
}
.m-home .find svg {
	width: 15px;
	height: 15px;
}

/* ───────── the grouped list (.m-gl), as the trip page draws Days, More and the rail (ADR-20261124-grouped-lists) ─────────
   A sheet on the Fog Grey ground (.m-gl-sheet) holds one rounded card per group (.m-gl). Its rows (.m-rl) are full
   width, edge to edge, split by a hairline that starts where the words start; each leads with its mark (a day's
   lantern) and ends in › for a row that goes somewhere. At night the ground is the page's dark and the card a step
   lighter, so both theme selectors set the pair. */
.m-gl-sheet {
	--gl-ground: var(--paper-2);
	--gl-card: var(--paper);
	--gl-end: var(--ink-3);
	padding: 0 14px 30px;
	background: var(--gl-ground);
}
@media (prefers-color-scheme: dark) {
	:root:not([data-theme='light']) .m-gl-sheet {
		--gl-ground: var(--paper);
		--gl-card: var(--paper-2);
		--gl-end: var(--ink-2);
	}
}
:root[data-theme='dark'] .m-gl-sheet {
	--gl-ground: var(--paper);
	--gl-card: var(--paper-2);
	--gl-end: var(--ink-2);
}
.m-gl-sheet::before {
	display: none; /* the trip page's sheets have no grabber */
}
.m-gl-sheet .x {
	right: 10px;
	top: 10px;
}
.m-gl-sheet .m-sh-h {
	height: 63px;
	padding: 10px 54px 8px 4px;
	font-size: 23px;
}
.m-gl {
	margin-top: 10px;
	overflow: hidden;
	border-radius: 14px; /* the trip page's --gl-r */
	background: var(--gl-card);
}
.m-rl {
	position: relative;
	display: grid;
	grid-template-columns: 34px minmax(0, 1fr) auto;
	align-items: center;
	column-gap: 12px;
	min-height: 52px;
	padding: 9px 14px;
}
.m-rl + .m-rl::before {
	content: '';
	position: absolute;
	top: 0;
	right: 0;
	left: 60px; /* where the words start: 14 + 34 + 12 px */
	height: 1px;
	background: var(--line);
}
.m-rl-t {
	display: grid;
	gap: 1px;
	min-width: 0;
	font-size: 15px;
	line-height: 1.35;
	color: var(--ink-2);
	text-wrap: pretty;
}
.m-rl-t b {
	font-size: 17px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--ink);
}
.m .m-rl .ch {
	margin-left: -4px;
	color: var(--gl-end);
	stroke-width: 2.3;
}
.m .m-lan {
	width: 34px;
	height: 40px;
}

/* Today under Now and Next: its two buttons (Go to next stop only while the next stop has a place), then the week */
.m-acts {
	margin-top: 10px;
}
.m-acts > span {
	display: flex;
	gap: 8px;
	align-items: start;
}
.m-acts .m-go {
	flex: 1 1 0;
	justify-content: center;
	gap: 8px;
	height: 55px;
	padding: 6px 12px;
	font-size: 17px;
	line-height: 1.2;
	text-align: center;
}
.m-acts .clk-b .m-go {
	height: 48px;
}
.m-go.ghost {
	background: transparent;
	color: var(--ink);
	box-shadow: inset 0 0 0 1px var(--line);
}
.m-wk-h {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 22px 0 12px;
	font-size: 19px;
	font-weight: 750;
	line-height: 1.25;
}
.m .m-wk-h svg {
	width: 22px;
	height: 22px;
	color: var(--ink-2);
}
.m-wk {
	display: grid;
	grid-template-columns: 34px 50px minmax(0, 1fr) 18px;
	align-items: center;
	column-gap: 13px;
	min-height: 108px;
	margin-bottom: 8px;
	padding: 10px 14px 10px 12px;
	border-radius: 14px;
	background: var(--paper-2);
}
.m-wk-d {
	display: grid;
	justify-items: center;
	font-size: 15px;
	line-height: 1.2;
	color: var(--ink-2);
}
.m-wk-d b {
	font-size: 21px;
	font-weight: 800;
	color: var(--ink);
}
.m-wk-t {
	display: grid;
	gap: 4px;
	font-size: 15px;
	line-height: 1.35;
	color: var(--ink-2);
}
.m-wk-t b {
	font-size: 17px;
	font-weight: 650;
	line-height: 1.3;
	color: var(--ink);
}
.m-wk > svg:last-child {
	color: var(--ink-2);
}

/* ───────── the demos' choreography ───────── */
/* every loop runs only while its card is in view and not paused; under reduced motion, or without the script, each
   holds its --still frame, which shows what the feature does */
.js .demo:not([data-run]) .m *,
.js .demo:not([data-run]) .route * {
	animation-play-state: paused;
}
.still .m *,
.still .route *,
html:not(.js) .demo .m *,
html:not(.js) .demo .route * {
	animation-play-state: paused !important;
	animation-delay: calc(var(--T) * var(--still, 0.6) * -1) !important;
}
@media (prefers-reduced-motion: reduce) {
	.demo .m *,
	.demo .route * {
		animation-play-state: paused !important;
		animation-delay: calc(var(--T) * var(--still, 0.6) * -1) !important;
	}
	.pause {
		display: none !important;
	}
	.sky .flier {
		animation: none;
		transform: translateY(-40px);
	}
}

/* what's next: on Today the clock passes 10:45, the rows move up and Go to next stop goes (lunch has no place); then a
   tap on Days in the bar opens the days as a grouped list, today's flagged. The still frame (0.56) is Today at 10:45 */
.x-now .m-hd {
	box-shadow: 0 1px 0 var(--glass-edge);
}
.x-now .clk-a {
	animation-name: now-clk-a;
}
.x-now .clk-b {
	animation-name: now-clk-b;
}
@keyframes now-clk-a {
	0%,
	36% {
		opacity: 1;
	}
	38%,
	96% {
		opacity: 0;
	}
	98%,
	100% {
		opacity: 1;
	}
}
@keyframes now-clk-b {
	0%,
	36% {
		opacity: 0;
	}
	38%,
	96% {
		opacity: 1;
	}
	98%,
	100% {
		opacity: 0;
	}
}
.x-now .vals {
	animation-name: now-vals;
}
@keyframes now-vals {
	0%,
	38% {
		transform: translateY(0);
		opacity: 1;
	}
	46%,
	93% {
		transform: translateY(-79px);
		opacity: 1;
	}
	96% {
		transform: translateY(-79px);
		opacity: 0;
	}
	97% {
		transform: translateY(0);
		opacity: 0;
	}
	100% {
		transform: translateY(0);
		opacity: 1;
	}
}
.x-now .v1 {
	animation-name: now-v1;
}
@keyframes now-v1 {
	0%,
	38% {
		opacity: 1;
	}
	43%,
	96% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}
.x-now .v2 {
	animation-name: now-v2;
}
@keyframes now-v2 {
	0%,
	45% {
		background: transparent;
	}
	48% {
		background: color-mix(in srgb, var(--hl) 70%, transparent);
		color: var(--hl-ink);
	}
	56%,
	100% {
		background: transparent;
	}
}
/* the finger on Days: the second of four items across 374 px, at the middle of the bar's 56 px items (760 − 14 − 28) */
.x-now .m-finger {
	left: 148px;
	top: 718px;
	animation-name: tap-62;
}
@keyframes tap-62 {
	0%,
	56% {
		opacity: 0;
		transform: scale(1.3);
	}
	60% {
		opacity: 1;
		transform: scale(1);
	}
	62% {
		opacity: 1;
		transform: scale(0.82);
	}
	66%,
	100% {
		opacity: 0;
		transform: scale(1);
	}
}
/* pressed as the trip page's bar item is: at once on touch-down its tile greys and sinks, and the release eases back */
.x-now .m-tb.days svg {
	animation-name: press-62;
}
@keyframes press-62 {
	0%,
	60% {
		transform: scale(1);
		background-color: transparent;
	}
	62% {
		transform: scale(0.92);
		background-color: var(--paper-3);
	}
	65%,
	100% {
		transform: scale(1);
		background-color: transparent;
	}
}
.x-now .m-scrim {
	animation-name: scrim-63-93;
}
@keyframes scrim-63-93 {
	0%,
	63% {
		opacity: 0;
	}
	68%,
	92% {
		opacity: 1;
	}
	97%,
	100% {
		opacity: 0;
	}
}
.x-now .m-sheet {
	animation-name: sheet-63-93;
}
@keyframes sheet-63-93 {
	0%,
	63% {
		transform: translateY(105%);
	}
	69%,
	92% {
		transform: translateY(0);
	}
	97%,
	100% {
		transform: translateY(105%);
	}
}

/* fixed times: push the rest of Day 5 back 30 min; the flexible stops move, the sealed ones hold */
.x-fixed .m-finger {
	animation-name: fixed-finger;
}
@keyframes fixed-finger {
	0%,
	11% {
		opacity: 0;
		transform: translate(130px, 187px) scale(1.3);
	}
	14% {
		opacity: 1;
		transform: translate(130px, 187px) scale(1);
	}
	16% {
		opacity: 1;
		transform: translate(130px, 187px) scale(0.82);
	}
	19% {
		opacity: 0;
		transform: translate(130px, 187px) scale(1);
	}
	32% {
		opacity: 0;
		transform: translate(110px, 700px) scale(1.3);
	}
	35% {
		opacity: 1;
		transform: translate(110px, 700px) scale(1);
	}
	37% {
		opacity: 1;
		transform: translate(110px, 700px) scale(0.82);
	}
	40%,
	100% {
		opacity: 0;
		transform: translate(110px, 700px) scale(1);
	}
}
.x-fixed .m-finger {
	left: 0;
	top: 0;
}
.x-fixed .m-scrim {
	animation-name: scrim-17-40;
}
@keyframes scrim-17-40 {
	0%,
	17% {
		opacity: 0;
	}
	22%,
	38% {
		opacity: 1;
	}
	43%,
	100% {
		opacity: 0;
	}
}
.x-fixed .m-sheet {
	animation-name: sheet-17-40;
}
@keyframes sheet-17-40 {
	0%,
	17% {
		transform: translateY(105%);
	}
	23%,
	38% {
		transform: translateY(0);
	}
	44%,
	100% {
		transform: translateY(105%);
	}
}
.x-fixed .m-toast {
	animation-name: toast-44-66;
}
@keyframes toast-44-66 {
	0%,
	43% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	47%,
	64% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	68%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}
.x-fixed .old {
	animation-name: flip-out-47;
}
.x-fixed .new {
	animation-name: flip-in-47, hl-48;
}
@keyframes flip-out-47 {
	0%,
	46% {
		opacity: 1;
	}
	49%,
	95% {
		opacity: 0;
	}
	99%,
	100% {
		opacity: 1;
	}
}
@keyframes flip-in-47 {
	0%,
	46% {
		opacity: 0;
	}
	49%,
	95% {
		opacity: 1;
	}
	99%,
	100% {
		opacity: 0;
	}
}
@keyframes hl-48 {
	0%,
	47% {
		background: transparent;
	}
	51%,
	66% {
		background: color-mix(in srgb, var(--hl) 75%, transparent);
		color: var(--hl-ink);
	}
	80%,
	100% {
		background: transparent;
	}
}
.x-fixed .held .seal,
.x-fixed .held .fix {
	animation-name: thunk-52;
}
@keyframes thunk-52 {
	0%,
	50% {
		scale: 1;
	}
	53% {
		scale: 1.35;
	}
	58%,
	100% {
		scale: 1;
	}
}
.x-fixed .ask {
	animation-name: flip-out-47;
}
.x-fixed .m-banner {
	animation-name: flip-in-47;
}

/* costs: the plan says the group's total; the page adds each person's share and the home currency */
.x-costs .s1 {
	animation-name: hl-a;
}
.x-costs .s2 {
	animation-name: hl-b;
}
.x-costs .s3 {
	animation-name: hl-c;
}
.x-costs .s4 {
	animation-name: hl-d;
}
@keyframes hl-a {
	0%,
	8% {
		background: transparent;
	}
	12%,
	30% {
		background: color-mix(in srgb, var(--hl) 80%, transparent);
		color: var(--hl-ink);
	}
	36%,
	100% {
		background: transparent;
	}
}
@keyframes hl-b {
	0%,
	28% {
		background: transparent;
	}
	32%,
	50% {
		background: color-mix(in srgb, var(--hl) 80%, transparent);
		color: var(--hl-ink);
	}
	56%,
	100% {
		background: transparent;
	}
}
@keyframes hl-c {
	0%,
	48% {
		background: transparent;
	}
	52%,
	70% {
		background: color-mix(in srgb, var(--hl) 80%, transparent);
		color: var(--hl-ink);
	}
	76%,
	100% {
		background: transparent;
	}
}
@keyframes hl-d {
	0%,
	68% {
		background: transparent;
	}
	72%,
	90% {
		background: color-mix(in srgb, var(--hl) 80%, transparent);
		color: var(--hl-ink);
	}
	96%,
	100% {
		background: transparent;
	}
}
.x-costs .slide {
	animation-name: costs-slide;
}
@keyframes costs-slide {
	0%,
	44% {
		transform: translateY(0);
	}
	50%,
	94% {
		transform: translateY(-150px);
	}
	100% {
		transform: translateY(0);
	}
}

/* nearby: lunch and a toilet hang under the stop; a tap opens the place over the day */
.x-near .pop1 {
	animation-name: pop-8;
}
.x-near .pop2 {
	animation-name: pop-16;
}
@keyframes pop-8 {
	0%,
	6% {
		opacity: 0;
		transform: translateY(10px);
	}
	12%,
	94% {
		opacity: 1;
		transform: translateY(0);
	}
	98%,
	100% {
		opacity: 0;
		transform: translateY(10px);
	}
}
@keyframes pop-16 {
	0%,
	14% {
		opacity: 0;
		transform: translateY(10px);
	}
	20%,
	94% {
		opacity: 1;
		transform: translateY(0);
	}
	98%,
	100% {
		opacity: 0;
		transform: translateY(10px);
	}
}
.x-near .m-finger,
.x-opt .m-finger {
	animation-name: tap-34;
}
@keyframes tap-34 {
	0%,
	28% {
		opacity: 0;
		transform: scale(1.3);
	}
	32% {
		opacity: 1;
		transform: scale(1);
	}
	34% {
		opacity: 1;
		transform: scale(0.82);
	}
	38%,
	100% {
		opacity: 0;
		transform: scale(1);
	}
}
.x-near .m-scrim,
.x-opt .m-scrim {
	animation-name: scrim-35-88;
}
@keyframes scrim-35-88 {
	0%,
	35% {
		opacity: 0;
	}
	40%,
	88% {
		opacity: 1;
	}
	93%,
	100% {
		opacity: 0;
	}
}
.x-near .m-sheet,
.x-opt .m-sheet {
	animation-name: sheet-35-88;
}
@keyframes sheet-35-88 {
	0%,
	35% {
		transform: translateY(105%);
	}
	41%,
	88% {
		transform: translateY(0);
	}
	94%,
	100% {
		transform: translateY(105%);
	}
}
.x-near .m-finger {
	left: 120px;
	top: 271px;
}
.x-opt .m-finger {
	left: 150px;
	top: 249px;
}
.x-opt .chip-press,
.x-near .chip-press {
	animation-name: press-34;
}
@keyframes press-34 {
	0%,
	32% {
		transform: scale(1);
	}
	34% {
		transform: scale(0.96);
	}
	37%,
	100% {
		transform: scale(1);
	}
}

/* a split day: the plan's rules fold out, then the string shows where the rider rejoins */
.x-split .m-finger {
	left: 0;
	top: 0;
	animation-name: split-finger;
}
@keyframes split-finger {
	0%,
	9% {
		opacity: 0;
		transform: translate(200px, 368px) scale(1.3);
	}
	12% {
		opacity: 1;
		transform: translate(200px, 368px) scale(1);
	}
	14% {
		opacity: 1;
		transform: translate(200px, 368px) scale(0.82);
	}
	17% {
		opacity: 0;
		transform: translate(200px, 368px) scale(1);
	}
	32% {
		opacity: 0;
		transform: translate(110px, 617px) scale(1.3);
	}
	35% {
		opacity: 1;
		transform: translate(110px, 617px) scale(1);
	}
	37% {
		opacity: 1;
		transform: translate(110px, 617px) scale(0.82);
	}
	40%,
	100% {
		opacity: 0;
		transform: translate(110px, 617px) scale(1);
	}
}
.x-split .fold-body {
	animation-name: split-body;
	transform-origin: 50% 0;
}
@keyframes split-body {
	0%,
	14% {
		clip-path: inset(0 0 100% 0);
		opacity: 0;
	}
	22%,
	52% {
		clip-path: inset(0 0 0 0);
		opacity: 1;
	}
	58%,
	100% {
		clip-path: inset(0 0 100% 0);
		opacity: 0;
	}
}
.x-split .below {
	animation-name: split-below;
}
@keyframes split-below {
	0%,
	14% {
		transform: translateY(0);
	}
	22%,
	52% {
		transform: translateY(226px);
	}
	58%,
	100% {
		transform: translateY(0);
	}
}
.x-split .scrolls {
	animation-name: split-scroll;
}
@keyframes split-scroll {
	0%,
	58% {
		transform: translateY(0);
	}
	66%,
	93% {
		transform: translateY(-142px);
	}
	100% {
		transform: translateY(0);
	}
}
.x-split .chev {
	animation-name: split-chev;
}
@keyframes split-chev {
	0%,
	14% {
		rotate: 0deg;
	}
	20%,
	52% {
		rotate: 180deg;
	}
	58%,
	100% {
		rotate: 0deg;
	}
}
.x-split .seg-short {
	animation-name: split-short;
}
.x-split .seg-long {
	animation-name: split-long;
}
@keyframes split-short {
	0%,
	36% {
		background: transparent;
		color: var(--ink-2);
	}
	38%,
	100% {
		background: var(--ink);
		color: var(--paper);
	}
}
@keyframes split-long {
	0%,
	36% {
		background: var(--ink);
		color: var(--paper);
	}
	38%,
	100% {
		background: transparent;
		color: var(--ink-2);
	}
}
.x-split .sub-long {
	animation-name: split-sub-long;
}
.x-split .sub-short {
	animation-name: split-sub-short;
}
@keyframes split-sub-long {
	0%,
	36% {
		opacity: 1;
	}
	38%,
	96% {
		opacity: 0;
	}
	100% {
		opacity: 1;
	}
}
@keyframes split-sub-short {
	0%,
	36% {
		opacity: 0;
	}
	38%,
	96% {
		opacity: 1;
	}
	100% {
		opacity: 0;
	}
}
.x-split .m-rejoin {
	animation-name: split-rejoin;
}
@keyframes split-rejoin {
	0%,
	66% {
		background: transparent;
	}
	70%,
	88% {
		background: color-mix(in srgb, var(--hl) 75%, transparent);
		color: var(--hl-ink);
	}
	94%,
	100% {
		background: transparent;
	}
}

/* group sync: Ana adds a stop; it flies to the other phone and lands there, with Ana's name on it */
.x-syncA .m-finger {
	left: 0;
	top: 0;
	animation-name: sync-finger;
}
@keyframes sync-finger {
	0%,
	4% {
		opacity: 0;
		transform: translate(191px, 305px) scale(1.3);
	}
	7% {
		opacity: 1;
		transform: translate(191px, 305px) scale(1);
	}
	9% {
		opacity: 1;
		transform: translate(191px, 305px) scale(0.82);
	}
	12% {
		opacity: 0;
		transform: translate(191px, 305px) scale(1);
	}
	27% {
		opacity: 0;
		transform: translate(300px, 708px) scale(1.3);
	}
	30% {
		opacity: 1;
		transform: translate(300px, 708px) scale(1);
	}
	32% {
		opacity: 1;
		transform: translate(300px, 708px) scale(0.82);
	}
	35%,
	100% {
		opacity: 0;
		transform: translate(300px, 708px) scale(1);
	}
}
.x-syncA .m-scrim {
	animation-name: scrim-10-34;
}
@keyframes scrim-10-34 {
	0%,
	10% {
		opacity: 0;
	}
	14%,
	33% {
		opacity: 1;
	}
	37%,
	100% {
		opacity: 0;
	}
}
.x-syncA .m-sheet {
	animation-name: sheet-10-34;
}
@keyframes sheet-10-34 {
	0%,
	10% {
		transform: translateY(105%);
	}
	15%,
	33% {
		transform: translateY(0);
	}
	38%,
	100% {
		transform: translateY(105%);
	}
}
.x-syncA .m-type {
	animation-name: sync-type;
	animation-timing-function: steps(5, end);
}
@keyframes sync-type {
	0%,
	16% {
		width: 0;
	}
	24%,
	100% {
		width: 3.05em;
	}
}
.x-syncA .res {
	animation-name: sync-res;
}
@keyframes sync-res {
	0%,
	22% {
		opacity: 0;
	}
	25%,
	100% {
		opacity: 1;
	}
}
.x-syncA .add-press {
	animation-name: press-32;
}
@keyframes press-32 {
	0%,
	30% {
		transform: scale(1);
	}
	32% {
		transform: scale(0.95);
	}
	35%,
	100% {
		transform: scale(1);
	}
}
.x-syncA .newstop {
	animation-name: new-a;
}
@keyframes new-a {
	0%,
	37% {
		opacity: 0;
		transform: translateY(-8px);
		background: transparent;
	}
	41% {
		opacity: 1;
		transform: translateY(0);
		background: color-mix(in srgb, var(--hl) 70%, transparent);
		color: var(--hl-ink);
	}
	60%,
	93% {
		opacity: 1;
		transform: translateY(0);
		background: transparent;
	}
	97%,
	100% {
		opacity: 0;
		transform: translateY(0);
		background: transparent;
	}
}
.x-syncA .after,
.x-syncB .after {
	animation-name: shift-a;
}
@keyframes shift-a {
	0%,
	37% {
		transform: translateY(-100px);
	}
	41%,
	95% {
		transform: translateY(0);
	}
	100% {
		transform: translateY(-100px);
	}
}
.x-syncB .after {
	animation-name: shift-b;
}
@keyframes shift-b {
	0%,
	60% {
		transform: translateY(-100px);
	}
	64%,
	95% {
		transform: translateY(0);
	}
	100% {
		transform: translateY(-100px);
	}
}
.x-syncB .newstop {
	animation-name: new-b;
}
@keyframes new-b {
	0%,
	60% {
		opacity: 0;
		transform: translateY(-8px);
		background: transparent;
	}
	64% {
		opacity: 1;
		transform: translateY(0);
		background: color-mix(in srgb, var(--hl) 70%, transparent);
		color: var(--hl-ink);
	}
	82%,
	93% {
		opacity: 1;
		transform: translateY(0);
		background: transparent;
	}
	97%,
	100% {
		opacity: 0;
		transform: translateY(0);
		background: transparent;
	}
}
.x-syncB .m-toast {
	animation-name: toast-62-84;
}
@keyframes toast-62-84 {
	0%,
	61% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	65%,
	82% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	86%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}
/* undo: Ana removes her stop, says OK, and Undo on the toast brings it back; later, Put back from Recently removed.
   The finger's targets are custom properties, measured off the drawn screen */
.x-undoA {
	--p1: 294px, 299px; /* the stop's Remove */
	--p2: 293px, 284px; /* the dialog's OK */
	--p3: 324px, 619px; /* the toast's Undo */
	--oops-h: 141px; /* the removed row's height */
}
.x-undoA .m-finger,
.x-undoB .m-finger {
	left: 0;
	top: 0;
}
.x-undoA .m-finger {
	animation-name: undo-finger;
}
@keyframes undo-finger {
	0%,
	7% {
		opacity: 0;
		transform: translate(var(--p1)) scale(1.3);
	}
	9% {
		opacity: 1;
		transform: translate(var(--p1)) scale(1);
	}
	11% {
		opacity: 1;
		transform: translate(var(--p1)) scale(0.82);
	}
	13% {
		opacity: 0;
		transform: translate(var(--p1)) scale(1);
	}
	19% {
		opacity: 0;
		transform: translate(var(--p2)) scale(1.3);
	}
	21% {
		opacity: 1;
		transform: translate(var(--p2)) scale(1);
	}
	23% {
		opacity: 1;
		transform: translate(var(--p2)) scale(0.82);
	}
	25% {
		opacity: 0;
		transform: translate(var(--p2)) scale(1);
	}
	39% {
		opacity: 0;
		transform: translate(var(--p3)) scale(1.3);
	}
	41% {
		opacity: 1;
		transform: translate(var(--p3)) scale(1);
	}
	43% {
		opacity: 1;
		transform: translate(var(--p3)) scale(0.82);
	}
	45%,
	100% {
		opacity: 0;
		transform: translate(var(--p3)) scale(1);
	}
}
.x-undoA .del {
	animation-name: press-11;
}
@keyframes press-11 {
	0%,
	9% {
		transform: scale(1);
	}
	11% {
		transform: scale(0.9);
	}
	13%,
	100% {
		transform: scale(1);
	}
}
.x-undoA .m-scrim {
	animation-name: scrim-12-26;
}
@keyframes scrim-12-26 {
	0%,
	12% {
		opacity: 0;
	}
	15%,
	24% {
		opacity: 1;
	}
	27%,
	100% {
		opacity: 0;
	}
}
.x-undoA .m-dlg {
	animation-name: dlg-12-26;
}
@keyframes dlg-12-26 {
	0%,
	12% {
		opacity: 0;
		transform: scale(0.94);
	}
	15%,
	24% {
		opacity: 1;
		transform: scale(1);
	}
	27%,
	100% {
		opacity: 0;
		transform: scale(0.98);
	}
}
.x-undoA .ok {
	animation-name: press-23;
}
@keyframes press-23 {
	0%,
	21% {
		transform: scale(1);
	}
	23% {
		transform: scale(0.94);
	}
	25%,
	100% {
		transform: scale(1);
	}
}
.x-undoA .oops {
	animation-name: oops-row;
}
@keyframes oops-row {
	0%,
	25% {
		opacity: 1;
		background: transparent;
	}
	29%,
	44% {
		opacity: 0;
		background: transparent;
	}
	48% {
		opacity: 1;
		background: color-mix(in srgb, var(--hl) 70%, transparent);
		color: var(--hl-ink);
	}
	64%,
	100% {
		opacity: 1;
		background: transparent;
	}
}
.x-undoA .after {
	animation-name: oops-after;
}
@keyframes oops-after {
	0%,
	27% {
		transform: translateY(0);
	}
	31%,
	44% {
		transform: translateY(calc(var(--oops-h) * -1));
	}
	48%,
	100% {
		transform: translateY(0);
	}
}
.x-undoA .t-gone {
	animation-name: toast-29-46;
}
@keyframes toast-29-46 {
	0%,
	29% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	32%,
	44% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	47%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}
.x-undoA .act {
	animation-name: press-43;
}
@keyframes press-43 {
	0%,
	41% {
		transform: scale(1);
	}
	43% {
		transform: scale(0.92);
	}
	45%,
	100% {
		transform: scale(1);
	}
}
.x-undoA .t-back {
	animation-name: toast-47-70;
}
@keyframes toast-47-70 {
	0%,
	47% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	50%,
	66% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	70%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}
.x-undoB {
	--q: 318px, 669px; /* Put back */
}
.x-undoB .m-scrim {
	opacity: 1;
}
.x-undoB .m-sheet {
	transform: none;
}
.x-undoB .m-finger {
	animation-name: undo-finger-b;
}
@keyframes undo-finger-b {
	0%,
	60% {
		opacity: 0;
		transform: translate(var(--q)) scale(1.3);
	}
	62% {
		opacity: 1;
		transform: translate(var(--q)) scale(1);
	}
	64% {
		opacity: 1;
		transform: translate(var(--q)) scale(0.82);
	}
	66%,
	100% {
		opacity: 0;
		transform: translate(var(--q)) scale(1);
	}
}
.x-undoB .back-press {
	animation-name: press-64;
}
@keyframes press-64 {
	0%,
	62% {
		transform: scale(1);
	}
	64% {
		transform: scale(0.95);
	}
	66%,
	100% {
		transform: scale(1);
	}
}
.x-undoB .gone-part,
.x-undoB .c1 {
	animation-name: undo-out-66;
}
@keyframes undo-out-66 {
	0%,
	65% {
		opacity: 1;
	}
	69%,
	95% {
		opacity: 0;
	}
	99%,
	100% {
		opacity: 1;
	}
}
.x-undoB .c2 {
	animation-name: undo-in-66;
}
@keyframes undo-in-66 {
	0%,
	65% {
		opacity: 0;
	}
	69%,
	95% {
		opacity: 1;
	}
	99%,
	100% {
		opacity: 0;
	}
}
.x-undoB .m-toast {
	animation-name: toast-67-90;
}
@keyframes toast-67-90 {
	0%,
	67% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	70%,
	86% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	90%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}
.route .arc {
	animation: route-draw var(--T) linear infinite both;
}
@keyframes route-draw {
	0%,
	38% {
		stroke-dashoffset: 56;
		opacity: 0;
	}
	41% {
		opacity: 0.75;
	}
	60%,
	88% {
		stroke-dashoffset: 0;
		opacity: 0.75;
	}
	94%,
	100% {
		stroke-dashoffset: 0;
		opacity: 0;
	}
}
.route .letter {
	animation: route-fly var(--T) var(--ease-in-out) infinite both;
}
/* the arc is drawn in viewBox units; translate() on an SVG element uses them too, so the letter follows it at any width */
@keyframes route-fly {
	0%,
	39% {
		transform: translate(125px, 100px) rotate(-34deg) scale(0.5);
		opacity: 0;
	}
	41% {
		transform: translate(152px, 71px) rotate(-30deg) scale(1);
		opacity: 1;
	}
	45% {
		transform: translate(206px, 33px) rotate(-16deg) scale(1);
	}
	50% {
		transform: translate(260px, 20px) rotate(0deg) scale(1);
	}
	55% {
		transform: translate(314px, 33px) rotate(16deg) scale(1);
	}
	59% {
		transform: translate(368px, 71px) rotate(30deg) scale(1);
		opacity: 1;
	}
	62%,
	100% {
		transform: translate(395px, 100px) rotate(34deg) scale(0.5);
		opacity: 0;
	}
}

/* running late: the phone's location comes in, the page offers the push-back, and only a tap makes it */
.x-late .loc {
	animation-name: late-loc;
}
@keyframes late-loc {
	0%,
	5% {
		opacity: 0;
	}
	8%,
	95% {
		opacity: 1;
	}
	98%,
	100% {
		opacity: 0;
	}
}
.x-late .m-late-wrap {
	animation-name: late-box;
}
@keyframes late-box {
	0%,
	10% {
		max-height: 0;
		opacity: 0;
	}
	16%,
	33% {
		max-height: 320px;
		opacity: 1;
	}
	35% {
		opacity: 0;
	}
	39%,
	100% {
		max-height: 0;
		opacity: 0;
	}
}
.x-late .m-late .m-hl {
	animation-name: late-hl;
}
@keyframes late-hl {
	0%,
	17% {
		background: transparent;
	}
	20%,
	29% {
		background: color-mix(in srgb, var(--hl) 75%, transparent);
		color: var(--hl-ink);
	}
	33%,
	100% {
		background: transparent;
	}
}
.x-late .push {
	animation-name: late-press;
}
@keyframes late-press {
	0%,
	29% {
		scale: 1;
	}
	30.5% {
		scale: 0.96;
	}
	32%,
	100% {
		scale: 1;
	}
}
.x-late .m-finger {
	left: 0;
	top: 0;
	animation-name: late-finger;
}
@keyframes late-finger {
	0%,
	26% {
		opacity: 0;
		transform: translate(182px, 500px) scale(1.3);
	}
	28.5% {
		opacity: 1;
		transform: translate(182px, 500px) scale(1);
	}
	30.5% {
		opacity: 1;
		transform: translate(182px, 500px) scale(0.82);
	}
	33%,
	100% {
		opacity: 0;
		transform: translate(182px, 500px) scale(1);
	}
}
.x-late .was {
	animation-name: late-was;
}
.x-late .now {
	animation-name: late-now;
}
@keyframes late-was {
	0%,
	33% {
		opacity: 1;
	}
	36%,
	95% {
		opacity: 0;
	}
	99%,
	100% {
		opacity: 1;
	}
}
@keyframes late-now {
	0%,
	33% {
		opacity: 0;
	}
	36%,
	95% {
		opacity: 1;
	}
	99%,
	100% {
		opacity: 0;
	}
}
.x-late .now .m-hl {
	animation-name: late-hl-new;
}
@keyframes late-hl-new {
	0%,
	36% {
		background: transparent;
	}
	40%,
	62% {
		background: color-mix(in srgb, var(--hl) 75%, transparent);
		color: var(--hl-ink);
	}
	76%,
	100% {
		background: transparent;
	}
}
.x-late .m-toast {
	animation-name: toast-36-58;
}
@keyframes toast-36-58 {
	0%,
	35% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
	39%,
	56% {
		opacity: 1;
		transform: translate(-50%, 0);
	}
	60%,
	100% {
		opacity: 0;
		transform: translate(-50%, 16px);
	}
}

/* the home screen: Install shows the steps, the icon lands on the home screen, and the page opens full screen */
.x-home .m-finger {
	left: 0;
	top: 0;
	animation-name: home-finger;
}
@keyframes home-finger {
	0%,
	4% {
		opacity: 0;
		transform: translate(172px, 114px) scale(1.3);
	}
	6.5% {
		opacity: 1;
		transform: translate(172px, 114px) scale(1);
	}
	8.5% {
		opacity: 1;
		transform: translate(172px, 114px) scale(0.82);
	}
	11% {
		opacity: 0;
		transform: translate(172px, 114px) scale(1);
	}
	47% {
		opacity: 0;
		transform: translate(58px, 97px) scale(1.3);
	}
	49.5% {
		opacity: 1;
		transform: translate(58px, 97px) scale(1);
	}
	51.5% {
		opacity: 1;
		transform: translate(58px, 97px) scale(0.82);
	}
	54%,
	100% {
		opacity: 0;
		transform: translate(58px, 97px) scale(1);
	}
}
.x-home .m-scrim {
	animation-name: scrim-10-36;
}
@keyframes scrim-10-36 {
	0%,
	10% {
		opacity: 0;
	}
	14%,
	33% {
		opacity: 1;
	}
	37%,
	100% {
		opacity: 0;
	}
}
.x-home .m-sheet {
	animation-name: sheet-10-36;
}
@keyframes sheet-10-36 {
	0%,
	10% {
		transform: translateY(105%);
	}
	16%,
	32% {
		transform: translateY(0);
	}
	37%,
	100% {
		transform: translateY(105%);
	}
}
.x-home .m-home {
	animation-name: home-screen;
}
@keyframes home-screen {
	0%,
	35% {
		opacity: 0;
		transform: scale(1.06);
	}
	40%,
	54% {
		opacity: 1;
		transform: scale(1);
	}
	60%,
	100% {
		opacity: 0;
		transform: scale(1.1);
	}
}
.x-home .tile {
	animation-name: home-tile;
}
@keyframes home-tile {
	0%,
	39% {
		opacity: 0;
		scale: 0.4;
	}
	43% {
		opacity: 1;
		scale: 1.08;
	}
	45%,
	51% {
		scale: 1;
	}
	52.5% {
		scale: 0.9;
	}
	54%,
	100% {
		opacity: 1;
		scale: 1;
	}
}
/* full screen: it grows out of the icon, without the browser's bar or the Install button */
.x-home .m-pg {
	animation-name: home-open;
}
@keyframes home-open {
	0%,
	53% {
		transform: scale(1);
		border-radius: 0;
	}
	54% {
		transform: scale(0.16);
		border-radius: 90px;
	}
	62%,
	100% {
		transform: scale(1);
		border-radius: 0;
	}
}
.x-home .m-tbar {
	animation-name: home-bar;
}
@keyframes home-bar {
	0%,
	37% {
		height: 52px;
		border-bottom-width: 1px;
	}
	38%,
	95% {
		height: 0;
		border-bottom-width: 0;
	}
	99%,
	100% {
		height: 52px;
		border-bottom-width: 1px;
	}
}
.x-home .m-inst {
	animation-name: home-inst;
}
@keyframes home-inst {
	0%,
	37% {
		max-width: 120px;
		padding-inline: 10px;
		opacity: 1;
	}
	38%,
	95% {
		max-width: 0;
		padding-inline: 0;
		opacity: 0;
	}
	99%,
	100% {
		max-width: 120px;
		padding-inline: 10px;
		opacity: 1;
	}
}
@keyframes home-brand {
	0%,
	37% {
		font-size: 20px;
	}
	38%,
	95% {
		font-size: 27px;
	}
	99%,
	100% {
		font-size: 20px;
	}
}

/* offline: the signal drops, the page says so, and the checklist still ticks */
.x-off .on-sig {
	animation-name: off-sig;
}
.x-off .off-sig {
	animation-name: off-plane;
}
@keyframes off-sig {
	0%,
	12% {
		opacity: 1;
	}
	15%,
	80% {
		opacity: 0;
	}
	84%,
	100% {
		opacity: 1;
	}
}
@keyframes off-plane {
	0%,
	12% {
		opacity: 0;
	}
	15%,
	80% {
		opacity: 1;
	}
	84%,
	100% {
		opacity: 0;
	}
}
.x-off .m-banner {
	animation-name: off-banner;
}
@keyframes off-banner {
	0%,
	15% {
		opacity: 0;
		transform: translateY(-10px);
	}
	20%,
	82% {
		opacity: 1;
		transform: translateY(0);
	}
	87%,
	100% {
		opacity: 0;
		transform: translateY(-10px);
	}
}
.x-off .c1 b {
	animation-name: tick-32;
}
.x-off .c2 b {
	animation-name: tick-46;
}
.x-off .c3 b {
	animation-name: tick-60;
}
@keyframes tick-32 {
	0%,
	30% {
		opacity: 0;
		transform: scale(0.6);
	}
	33%,
	95% {
		opacity: 1;
		transform: scale(1);
	}
	99%,
	100% {
		opacity: 0;
	}
}
@keyframes tick-46 {
	0%,
	44% {
		opacity: 0;
		transform: scale(0.6);
	}
	47%,
	95% {
		opacity: 1;
		transform: scale(1);
	}
	99%,
	100% {
		opacity: 0;
	}
}
@keyframes tick-60 {
	0%,
	58% {
		opacity: 0;
		transform: scale(0.6);
	}
	61%,
	95% {
		opacity: 1;
		transform: scale(1);
	}
	99%,
	100% {
		opacity: 0;
	}
}
.x-off .m-prog i {
	animation-name: off-prog;
}
@keyframes off-prog {
	0%,
	30% {
		transform: scaleX(0.143);
	}
	34%,
	44% {
		transform: scaleX(0.286);
	}
	48%,
	58% {
		transform: scaleX(0.429);
	}
	62%,
	95% {
		transform: scaleX(0.571);
	}
	100% {
		transform: scaleX(0.143);
	}
}
.x-off .cnt-a {
	animation-name: cnt-a;
}
.x-off .cnt-b {
	animation-name: cnt-b;
}
.x-off .cnt-c {
	animation-name: cnt-c;
}
.x-off .cnt-d {
	animation-name: cnt-d;
}
@keyframes cnt-a {
	0%,
	31% {
		opacity: 1;
	}
	32%,
	98% {
		opacity: 0;
	}
	99%,
	100% {
		opacity: 1;
	}
}
@keyframes cnt-b {
	0%,
	31% {
		opacity: 0;
	}
	32%,
	45% {
		opacity: 1;
	}
	46%,
	100% {
		opacity: 0;
	}
}
@keyframes cnt-c {
	0%,
	45% {
		opacity: 0;
	}
	46%,
	59% {
		opacity: 1;
	}
	60%,
	100% {
		opacity: 0;
	}
}
@keyframes cnt-d {
	0%,
	59% {
		opacity: 0;
	}
	60%,
	98% {
		opacity: 1;
	}
	99%,
	100% {
		opacity: 0;
	}
}

/* only your group: the host asks for the password, then the trip page opens */
.x-lock .dots {
	animation-name: lock-type;
	animation-timing-function: steps(8, end);
}
@keyframes lock-type {
	0%,
	10% {
		clip-path: inset(0 100% 0 0);
	}
	30%,
	100% {
		clip-path: inset(0 0 0 0);
	}
}
.x-lock .m-finger {
	left: 195px;
	top: 665px;
	animation-name: tap-36;
}
@keyframes tap-36 {
	0%,
	31% {
		opacity: 0;
		transform: scale(1.3);
	}
	34% {
		opacity: 1;
		transform: scale(1);
	}
	36% {
		opacity: 1;
		transform: scale(0.82);
	}
	40%,
	100% {
		opacity: 0;
		transform: scale(1);
	}
}
.x-lock .gate {
	animation-name: lock-gate;
}
.x-lock .inside {
	position: relative; /* the trip page behind the password, its bottom bar at its foot */
	animation-name: lock-inside;
}
@keyframes lock-gate {
	0%,
	38% {
		opacity: 1;
	}
	44%,
	94% {
		opacity: 0;
	}
	98%,
	100% {
		opacity: 1;
	}
}
@keyframes lock-inside {
	0%,
	38% {
		opacity: 0;
		transform: translateY(18px);
	}
	46%,
	94% {
		opacity: 1;
		transform: translateY(0);
	}
	98%,
	100% {
		opacity: 0;
		transform: translateY(0);
	}
}

/* ───────── the packing list and the luggage tag ───────── */
.duo {
	margin-top: clamp(40px, 6vw, 72px);
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 32px;
	align-items: start;
}
@media (min-width: 900px) {
	.duo {
		grid-template-columns: minmax(0, 1fr) minmax(0, 22rem);
		gap: 48px;
	}
}
/* the packing list: a sheet the planner wrote on, under the same airmail edge as the postcards, ticked in ballpoint */
.packing {
	--hand: color-mix(in srgb, var(--blue) 72%, var(--ink));
	position: relative;
	padding: 30px 26px 26px;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
	transform: rotate(-0.6deg);
}
.packing::before {
	border-radius: var(--r-card) var(--r-card) 0 0;
}
.packing .note-brush {
	margin-bottom: 6px;
}
.packing h3,
.tag h3 {
	font-family: var(--font-head);
	font-size: 1.625rem;
	font-weight: 800;
	letter-spacing: -0.02em;
}
.packing ul {
	list-style: none;
	margin: 18px 0 0;
	padding: 0;
	display: grid;
}
.packing li {
	display: grid;
	grid-template-columns: 28px minmax(0, 1fr);
	gap: 12px;
	align-items: start;
	padding: 10px 0;
	/* ruled like a notebook page, in the table's blue: a line under each item, so none runs through a wrapped one */
	border-bottom: 1px solid color-mix(in srgb, var(--blue) 16%, transparent);
	font-weight: 600;
	line-height: 1.4;
}
.packing li svg {
	width: 26px;
	height: 26px;
	color: var(--blue);
	stroke-width: 2.6;
}
/* a hand never ticks the same way twice */
.packing li:nth-child(3n + 2) svg {
	rotate: -7deg;
}
.packing li:nth-child(3n) svg {
	rotate: 5deg;
	scale: 0.94;
}
.packing li span {
	padding-top: 2px;
}
/* the list in groups, flowing down two columns where they fit (so a short group leaves no hole beside a long one);
   each heading takes one ruled line */
.pack-groups {
	column-gap: 36px;
	margin-top: 18px;
}
@media (min-width: 700px) {
	.pack-groups {
		columns: 2;
	}
}
.pack-group {
	break-inside: avoid;
}
.pack-group h4 {
	margin: 0;
	padding-top: 10px;
	font-family: var(--font-head);
	font-size: 1.0625rem;
	font-weight: 800;
	line-height: 34px;
	color: var(--blue);
}
.pack-group ul {
	margin: 0 0 8px;
}
.tag {
	position: relative;
	padding: 28px 26px 26px 54px;
	border-radius: 10px 22px 22px 10px;
	background: var(--l7);
	color: var(--l7-ink);
	box-shadow: var(--card-shadow);
	transform: rotate(1.2deg);
}
.tag::before {
	/* the punched eyelet the string goes through */
	content: '';
	position: absolute;
	left: 18px;
	top: 30px;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: var(--table);
	box-shadow:
		0 0 0 3px color-mix(in srgb, var(--l7-ink) 30%, transparent),
		inset 0 1px 2px rgba(0, 0, 0, 0.25);
}
.tag::after {
	/* the string */
	content: '';
	position: absolute;
	left: -40px;
	top: 37px;
	width: 66px;
	height: 2px;
	background: color-mix(in srgb, var(--l7-ink) 70%, transparent);
	transform: rotate(-12deg);
	transform-origin: 100% 50%;
}
.facts {
	margin: 16px 0 0;
}
.facts > div {
	display: grid;
	grid-template-columns: minmax(0, 6.5rem) minmax(0, 1fr);
	gap: 2px 16px;
	padding: 11px 0;
	border-top: 1px solid color-mix(in srgb, var(--l7-ink) 22%, transparent);
}
.facts dt {
	font-weight: 750;
	font-size: 0.9375rem;
	padding-top: 2px;
	color: color-mix(in srgb, var(--l7-ink) 78%, transparent);
}
.facts dd {
	margin: 0;
	font-weight: 650;
}
.facts .num {
	font-family: var(--font-head);
	font-size: 1.4375rem;
	font-weight: 800;
	font-variant-numeric: tabular-nums;
	letter-spacing: -0.02em;
}
@media (max-width: 420px) {
	.facts > div {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* ───────── how a trip becomes a page: the route, then four stamps on it ───────── */
.routemap {
	margin-top: 32px;
	padding: 14px;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scrollbar-color: var(--ink-3) transparent;
}
.routemap img {
	width: 928px;
	max-width: none;
}
@media (min-width: 980px) {
	.routemap {
		overflow: visible;
	}
	.routemap img {
		width: 100%;
		max-width: 1000px;
		margin: 0 auto;
	}
}
@media (max-width: 979px) {
	.routemap {
		/* the right edge fades while there's more to see */
		-webkit-mask-image: linear-gradient(to right, #000 calc(100% - 40px), transparent);
		mask-image: linear-gradient(to right, #000 calc(100% - 40px), transparent);
	}
}
.flow-hint {
	margin-top: 8px;
	font-size: 0.9375rem;
	color: var(--ink-3);
}
@media (min-width: 980px) {
	.flow-hint {
		display: none;
	}
}
.steps {
	list-style: none;
	margin: clamp(40px, 6vw, 64px) 0 0;
	padding: 0;
	display: grid;
	gap: 28px;
	max-width: 60rem;
	position: relative;
}
.steps::before {
	/* the airmail route the stamps sit on */
	content: '';
	position: absolute;
	left: 41px;
	top: 40px;
	bottom: 40px;
	width: 3px;
	background: repeating-linear-gradient(to bottom, var(--red) 0 12px, transparent 12px 18px, var(--blue) 18px 30px, transparent 30px 36px);
	opacity: 0.8;
}
.step {
	position: relative;
	display: grid;
	grid-template-columns: 84px minmax(0, 1fr);
	gap: 20px;
	align-items: start;
}
.step .stamp {
	width: 84px;
	height: 100px;
	transform: rotate(var(--r, -3deg));
}
.step:nth-child(2) .stamp {
	--r: 2.5deg;
}
.step:nth-child(3) .stamp {
	--r: -1.5deg;
}
.step:nth-child(4) .stamp {
	--r: 3deg;
}
.step .stamp-face .wish {
	font-family: var(--font-brush);
	font-size: 1.375rem;
	line-height: 1;
	writing-mode: vertical-rl;
	letter-spacing: 0.04em;
}
.step .stamp-face .wish.w4 {
	font-size: 1.0625rem;
	letter-spacing: 0;
}
.step-card {
	padding: 20px 22px 22px;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
	display: grid;
	gap: 12px;
}
.step-card h3 {
	font-family: var(--font-head);
	font-size: clamp(1.3125rem, 2.2vw, 1.5rem);
	font-weight: 800;
	letter-spacing: -0.015em;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 12px;
}
.rec-tag {
	display: inline-flex;
	align-items: center;
	min-height: 28px;
	padding: 2px 10px;
	border-radius: 8px;
	background: var(--l2);
	color: var(--l2-ink);
	font: 750 0.8125rem/1 var(--font-ui);
	letter-spacing: 0.02em;
}
.step-card pre {
	margin: 0;
	padding: 12px 14px;
	border-radius: 10px;
	background: var(--code);
	white-space: pre-wrap;
	overflow-wrap: break-word; /* after a / (the <wbr>s), a word breaks only as a last resort */
	font-size: 0.9375rem;
	line-height: 1.6;
}
.note {
	font-size: 0.9375rem;
	color: var(--ink-2);
}
@media (max-width: 559px) {
	.steps::before {
		left: 31px;
	}
	.step {
		grid-template-columns: 64px minmax(0, 1fr);
		gap: 14px;
	}
	.step .stamp {
		width: 64px;
		height: 78px;
		--pitch: 8px;
		--hole: 2.6px;
		padding: 5px;
	}
	.step .stamp-face .wish {
		font-size: 1.0625rem;
	}
	.step .stamp-face .wish.w4 {
		font-size: 0.8125rem;
	}
	.step-card {
		padding: 18px 16px 18px;
	}
}

/* ───────── Google or the free map: the rate card ───────── */
.table-wrap {
	margin-top: 28px;
	max-width: 56rem;
	padding: 8px 18px 12px;
	border-radius: var(--r-card);
	background: var(--stock);
	box-shadow: var(--card-shadow);
	overflow-x: auto;
}
table {
	width: 100%;
	border-collapse: collapse;
	font-size: 1.0625rem;
}
th,
td {
	text-align: left;
	vertical-align: top;
	padding: 14px 12px;
	border-bottom: 1px solid var(--rule-card);
}
tbody tr:last-child th,
tbody tr:last-child td {
	border-bottom: 0;
}
thead th {
	font-family: var(--font-head);
	font-size: 1.125rem;
	font-weight: 800;
	border-bottom: 2px solid var(--ink);
	vertical-align: bottom;
}
tbody th {
	font-weight: 700;
	width: 30%;
}
.th-sub {
	display: block;
	margin-top: 2px;
	font: 600 0.8125rem/1.3 var(--font-ui);
	color: var(--ink-3);
}
td.rec,
th.rec {
	background: color-mix(in srgb, var(--l2) 8%, transparent);
}
thead th.rec {
	border-bottom-color: var(--l2);
}
@media (max-width: 520px) {
	.table-wrap {
		padding: 8px 10px;
	}
	th,
	td {
		padding: 12px 8px;
		font-size: 0.9375rem;
	}
	tbody th {
		width: 28%;
	}
}

/* ───────── footer: lantern night, the end of the day ───────── */
.foot {
	--ink: #eef0f4;
	--ink-2: #c9cfe0;
	--link: #a9c8ff;
	--focus: #a9c8ff;
	margin-top: clamp(64px, 8vw, 104px);
	position: relative;
	z-index: 1;
	color: var(--ink-2);
	background: linear-gradient(to bottom, transparent 0, #3a2d5c 22%, #1d1840 46%, #120f26 70%);
}
.night {
	position: relative;
	height: clamp(220px, 26vw, 320px);
	overflow: hidden;
	background: url('stars.svg') 0 0 / 480px 480px;
	-webkit-mask: linear-gradient(to bottom, transparent, #000 34%);
	mask: linear-gradient(to bottom, transparent, #000 34%);
}
.night .moon {
	position: absolute;
	right: 14%;
	top: 14%;
	width: clamp(34px, 4vw, 54px);
	aspect-ratio: 1;
	border-radius: 50%;
	opacity: var(--moon-o);
	background: radial-gradient(circle at 38% 36%, #fffdf6, #ece7ff 60%, #d3cbf3);
	box-shadow:
		0 0 22px 6px rgba(236, 231, 255, 0.32),
		0 0 80px 22px rgba(236, 231, 255, 0.12);
}
.night .ridge {
	position: absolute;
	inset: auto 0 0;
	width: 100%;
	height: 46%;
}
.night .lit {
	position: absolute;
	left: var(--x);
	top: var(--y);
	filter: drop-shadow(0 0 8px rgba(255, 178, 84, 0.9)) drop-shadow(0 0 22px rgba(255, 140, 60, 0.45));
}
.foot .brush-sm {
	color: #ffffff;
	line-height: 0; /* the larger brush word mustn't push its line down */
}
.foot-in {
	max-width: var(--wide);
	margin: 0 auto;
	padding: 4px 16px 48px;
	display: grid;
	gap: 12px;
	color: var(--ink-2);
	font-size: 0.9375rem;
}
@media (min-width: 960px) {
	.foot-in {
		padding-inline: 24px;
	}
}
/* the row of links gets 44 px taps; a link inside a sentence stays inline, so its line keeps the paragraph's spacing */
.foot-links a {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
}
.brush-sm {
	font-size: 1.5rem;
	color: var(--ink);
}

/* ───────── arrival: a postcard settles once on the table the first time it comes into view ───────── */
@media (prefers-reduced-motion: no-preference) {
	.js .settle {
		opacity: 0;
		transform: translateY(26px) rotate(calc(var(--tilt, 0deg) - 2.5deg));
		transition:
			opacity 520ms var(--ease-out),
			transform 900ms var(--ease-out);
	}
	.js .settle.in {
		opacity: 1;
		transform: rotate(var(--tilt, 0deg));
	}
	/* the packing list is tall: an extra tilt would swing its corners past a phone's edge, so it only rises */
	.js .packing.settle:not(.in) {
		transform: translateY(26px) rotate(var(--tilt, 0deg));
	}
	/* the same on a phone, where every postcard is stacked full width and tall */
	@media (max-width: 699px) {
		.js .card.settle:not(.in) {
			transform: translateY(26px) rotate(calc(var(--tilt, 0deg) - 0.6deg));
		}
	}
	.js .settle .postmark {
		opacity: 0;
		scale: 1.25;
		transition:
			opacity 180ms ease-out 520ms,
			scale 260ms var(--ease-out) 520ms;
	}
	.js .settle.in .postmark {
		opacity: 1;
		scale: 1;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
	*,
	*::before,
	*::after {
		transition-duration: 1ms !important;
	}
}
@media (prefers-reduced-transparency: reduce) {
	.bar {
		background: var(--table);
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
		box-shadow: 0 1px 0 var(--rule);
	}
}
@media (prefers-contrast: more) {
	.bar {
		background: var(--table);
		-webkit-backdrop-filter: none;
		backdrop-filter: none;
		box-shadow: 0 1px 0 var(--ink);
	}
	.m-tabbar {
		box-shadow: 0 -1px 0 var(--ink);
	}
	.nav .nav-gh,
	.card,
	.step-card,
	.packing,
	.table-wrap,
	.pause {
		box-shadow: 0 0 0 1px var(--ink);
	}
}

/* scrolling is the day passing: clouds drift with the page, and the footer's lanterns rise as it comes into view.
   Tied to the scroll, so nothing in the background moves by itself (WCAG 2.2.2); where the browser can't, they hold */
@supports (animation-timeline: scroll()) {
	@media (prefers-reduced-motion: no-preference) {
		.cloud,
		.birds {
			animation: drift linear both;
			animation-timeline: scroll(root);
		}
		/* the sun keeps to the screen and sets as the page nears night, warming as it goes */
		.sunpath {
			position: fixed;
			inset: 0;
			height: auto;
		}
		.sun {
			animation: sunset linear both;
			animation-timeline: scroll(root);
		}
		.sun::after {
			animation: dusk linear both;
			animation-timeline: scroll(root);
		}
		.night .moon {
			animation: moonrise linear both;
			animation-timeline: view();
			animation-range: entry 0% cover 60%;
		}
		.scene .lit {
			animation: float-up linear both;
			animation-timeline: scroll(root);
		}
		.night .lit {
			animation: lift linear both;
			animation-timeline: view();
			animation-range: entry 0% cover 70%;
		}
	}
}
@keyframes drift {
	from {
		translate: calc(var(--drift) * -1) 0;
	}
	to {
		translate: var(--drift) 0;
	}
}
@keyframes sunset {
	0% {
		translate: 0 0;
	}
	55% {
		translate: calc(var(--sun-travel) * -4vw) calc(var(--sun-travel) * 40vh);
	}
	86% {
		translate: calc(var(--sun-travel) * -8vw) calc(var(--sun-travel) * 78vh);
	}
	100% {
		translate: calc(var(--sun-travel) * -10vw) calc(var(--sun-travel) * 115vh);
	}
}
@keyframes dusk {
	0%,
	30% {
		opacity: 0;
	}
	80%,
	100% {
		opacity: 1;
	}
}
@keyframes moonrise {
	from {
		translate: 0 70px;
	}
	to {
		translate: 0 0;
	}
}
@keyframes float-up {
	from {
		translate: 0 140px;
	}
	to {
		translate: 0 -140px;
	}
}
@keyframes lift {
	from {
		translate: 0 calc(60px + var(--d) * 50px);
		scale: 0.8;
	}
	to {
		translate: 0 0;
		scale: 1;
	}
}

/* the two phases of the fall, so neighbouring flakes don't drop in step; each jump happens off the screen */
@keyframes snow-a {
	0% {
		translate: 0 -10vh;
	}
	10% {
		translate: 0 110vh;
	}
	10% {
		translate: 0 -10vh;
	}
	20% {
		translate: 0 110vh;
	}
	20% {
		translate: 0 -10vh;
	}
	30% {
		translate: 0 110vh;
	}
	30% {
		translate: 0 -10vh;
	}
	40% {
		translate: 0 110vh;
	}
	40% {
		translate: 0 -10vh;
	}
	50% {
		translate: 0 110vh;
	}
	50% {
		translate: 0 -10vh;
	}
	60% {
		translate: 0 110vh;
	}
	60% {
		translate: 0 -10vh;
	}
	70% {
		translate: 0 110vh;
	}
	70% {
		translate: 0 -10vh;
	}
	80% {
		translate: 0 110vh;
	}
	80% {
		translate: 0 -10vh;
	}
	90% {
		translate: 0 110vh;
	}
	90% {
		translate: 0 -10vh;
	}
	100% {
		translate: 0 110vh;
	}
}
@keyframes snow-b {
	0% {
		translate: 0 50vh;
	}
	5% {
		translate: 0 110vh;
	}
	5% {
		translate: 0 -10vh;
	}
	15% {
		translate: 0 110vh;
	}
	15% {
		translate: 0 -10vh;
	}
	25% {
		translate: 0 110vh;
	}
	25% {
		translate: 0 -10vh;
	}
	35% {
		translate: 0 110vh;
	}
	35% {
		translate: 0 -10vh;
	}
	45% {
		translate: 0 110vh;
	}
	45% {
		translate: 0 -10vh;
	}
	55% {
		translate: 0 110vh;
	}
	55% {
		translate: 0 -10vh;
	}
	65% {
		translate: 0 110vh;
	}
	65% {
		translate: 0 -10vh;
	}
	75% {
		translate: 0 110vh;
	}
	75% {
		translate: 0 -10vh;
	}
	85% {
		translate: 0 110vh;
	}
	85% {
		translate: 0 -10vh;
	}
	95% {
		translate: 0 110vh;
	}
	95% {
		translate: 0 -10vh;
	}
	100% {
		translate: 0 50vh;
	}
}

/* ───────── the Snow world: Snow Light Path (DESIGN.md, "Surface: the landing page") ─────────
   Keyed to :root[data-world='snow'] and the .world-* classes, so the Lanterns world (no attribute) is the rules above,
   unchanged. The day tokens and both night blocks define the same keys, so a night value can't leak into the day. The
   snowfall is the only motion here, and it stops under reduced motion. */

/* each world's parts are hidden in the other world */
:root:not([data-world='snow']) .world-snow,
:root[data-world='snow'] .world-lanterns,
:root[data-world='snow'] .scene .lit,
:root[data-world='snow'] .birds {
	display: none;
}

/* the sky by day: a pale winter morning, a blue afternoon with a cool lilac turn, and a cold dusk, never gold */
:root[data-world='snow'] {
	--table: #eaf2fb;
	--sky-1: #f6fafe;
	--sky-2: #edf4fb;
	--sky-3: #e2edf8;
	--sky-35: #dbe5f5;
	--sky-4: #d6dff1;
	--sky-5: #d0daee;
	--sky-6: #cad5ea;
	--sun: #ffefc4; /* the low winter sun */
	--sun-low: #ffc9a0;
	--sun-travel: 1;
	--cloud-o: 1;
	--birds-o: 0;
	--stars-o: 0;
	--moon-o: 0;
	--table-2: #dbe7f5;
	--flake: #7f9fc8; /* a snowflake against the pale sky */
}

/* the night: navy, lit only by the candles, so no stars, no sun and no moon. Same keys as the day block above. */
@media (prefers-color-scheme: dark) {
	:root[data-world='snow']:not([data-theme='light']) {
		--table: #0a1424;
		--sky-1: #0a1424;
		--sky-2: #0b1628;
		--sky-3: #0d1a31;
		--sky-35: #0f1e39;
		--sky-4: #112141;
		--sky-5: #13264a;
		--sky-6: #152b52;
		--sun: #e6eefb;
		--sun-low: #e6eefb;
		--sun-travel: 0.35;
		--cloud-o: 0.07;
		--birds-o: 0;
		--stars-o: 0;
		--moon-o: 0;
		--table-2: #111d33;
		--flake: #eaf2fb;
	}
	:root[data-world='snow']:not([data-theme='light']) .sun {
		display: none;
	}
}
:root[data-world='snow'][data-theme='dark'] {
	--table: #0a1424;
	--sky-1: #0a1424;
	--sky-2: #0b1628;
	--sky-3: #0d1a31;
	--sky-35: #0f1e39;
	--sky-4: #112141;
	--sky-5: #13264a;
	--sky-6: #152b52;
	--sun: #e6eefb;
	--sun-low: #e6eefb;
	--sun-travel: 0.35;
	--cloud-o: 0.07;
	--birds-o: 0;
	--stars-o: 0;
	--moon-o: 0;
	--table-2: #111d33;
	--flake: #eaf2fb;
}
:root[data-world='snow'][data-theme='dark'] .sun {
	display: none;
}

/* the bar's world button: a 44 px target that shows the other world's glyph; in Snow it sits on a filled, ringed tile */
.nav-world {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	min-height: 44px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: none;
	color: var(--ink);
	cursor: pointer;
	transition:
		background-color 160ms ease,
		transform 160ms var(--ease-out);
}
.nav-world[hidden] {
	display: none;
}
.nav-world svg {
	width: 20px;
	height: 20px;
}
.nav-world:active {
	background: var(--table-2);
	transform: scale(0.97);
	transition-duration: 0ms;
}
@media (hover: hover) and (pointer: fine) {
	.nav-world:hover {
		background: var(--table-2);
	}
}
:root[data-world='snow'] .nav-world {
	background: var(--stock);
	box-shadow: inset 0 0 0 1.5px var(--ink);
}

/* the hero's second demo link, under the pair of buttons */
.other-demo {
	margin-top: 8px;
	font-size: 0.9375rem;
	color: var(--ink-2);
}
.other-demo a {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	font-weight: 650;
}

/* the postcard's front in Snow: a snowy night with candles in the snow, and its caption 札幌 */
:root[data-world='snow'] .pc-front .sky {
	background: #08111f;
}
:root[data-world='snow'] .pc-front .sky::before {
	background: radial-gradient(120% 90% at 50% 120%, #2c4f7e 0%, #18305a 38%, #0e1d38 70%, #08111f 100%);
}
.snow-art {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	display: block;
}

/* the footer's night: a snowy navy ground, candles standing in the snow, no stars */
:root[data-world='snow'] .foot {
	background: linear-gradient(to bottom, transparent 0, #1a2f52 22%, #0f1f3a 46%, #0a1528 70%);
}
:root[data-world='snow'] .night {
	background: none;
}
:root[data-world='snow'] .night .ridge path:first-child {
	fill: #213a62; /* the snow behind the candles */
}
:root[data-world='snow'] .night .ridge path:last-child {
	fill: #e6eff9; /* the snow the candles stand in */
}
.snow-path {
	position: absolute;
	inset: 0;
	pointer-events: none;
}
/* a candle: its foot is a cup of snow, its wax stands in it, and the flame is the one warm light */
.candle {
	position: absolute;
	left: var(--x);
	top: var(--y);
	width: 12px;
	height: 22px;
	translate: -50% -100%;
	scale: 1.8;
	transform-origin: 50% 100%; /* grows up from its snow, never down into it */
}
.candle::before {
	content: '';
	position: absolute;
	left: -4px;
	right: -4px;
	bottom: -3px;
	height: 6px;
	border-radius: 50%;
	background: #f7fbff;
}
.candle::after {
	content: '';
	position: absolute;
	left: 50%;
	bottom: 0;
	width: 5px;
	height: 9px;
	translate: -50% 0;
	border-radius: 1px;
	background: #fff3cf;
}
.candle i {
	position: absolute;
	left: 50%;
	bottom: 10px;
	width: 5px;
	height: 9px;
	translate: -50% 0;
	border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
	background: #ffb43c;
	box-shadow: 0 0 8px 3px rgba(255, 176, 60, 0.42);
}

/* the falling snow: flakes held in the viewport, each falling once for every tenth of the page the visitor scrolls, so
   they fall as the page moves and hang still when it doesn't. Where scroll timelines are missing they stay as still dots. */
.flake {
	position: fixed;
	top: var(--y);
	left: var(--x);
	width: var(--s);
	height: var(--s);
	border-radius: 50%;
	background: var(--flake);
	opacity: 0.8;
}
@supports (animation-timeline: scroll()) {
	@media (prefers-reduced-motion: no-preference) {
		:root[data-world='snow'] .flake {
			animation: snow-a linear both;
			animation-timeline: scroll(root);
		}
		:root[data-world='snow'] .flake:nth-child(2n) {
			animation-name: snow-b;
		}
	}
}
@media (prefers-reduced-motion: reduce) {
	:root[data-world='snow'] .flake {
		display: none;
	}
}

/* the two phases of the fall, so neighbouring flakes don't drop in step; each jump happens off the screen */
@keyframes snow-a {
	0% {
		translate: 0 -10vh;
	}
	10% {
		translate: 0 110vh;
	}
	10% {
		translate: 0 -10vh;
	}
	20% {
		translate: 0 110vh;
	}
	20% {
		translate: 0 -10vh;
	}
	30% {
		translate: 0 110vh;
	}
	30% {
		translate: 0 -10vh;
	}
	40% {
		translate: 0 110vh;
	}
	40% {
		translate: 0 -10vh;
	}
	50% {
		translate: 0 110vh;
	}
	50% {
		translate: 0 -10vh;
	}
	60% {
		translate: 0 110vh;
	}
	60% {
		translate: 0 -10vh;
	}
	70% {
		translate: 0 110vh;
	}
	70% {
		translate: 0 -10vh;
	}
	80% {
		translate: 0 110vh;
	}
	80% {
		translate: 0 -10vh;
	}
	90% {
		translate: 0 110vh;
	}
	90% {
		translate: 0 -10vh;
	}
	100% {
		translate: 0 110vh;
	}
}
@keyframes snow-b {
	0% {
		translate: 0 50vh;
	}
	5% {
		translate: 0 110vh;
	}
	5% {
		translate: 0 -10vh;
	}
	15% {
		translate: 0 110vh;
	}
	15% {
		translate: 0 -10vh;
	}
	25% {
		translate: 0 110vh;
	}
	25% {
		translate: 0 -10vh;
	}
	35% {
		translate: 0 110vh;
	}
	35% {
		translate: 0 -10vh;
	}
	45% {
		translate: 0 110vh;
	}
	45% {
		translate: 0 -10vh;
	}
	55% {
		translate: 0 110vh;
	}
	55% {
		translate: 0 -10vh;
	}
	65% {
		translate: 0 110vh;
	}
	65% {
		translate: 0 -10vh;
	}
	75% {
		translate: 0 110vh;
	}
	75% {
		translate: 0 -10vh;
	}
	85% {
		translate: 0 110vh;
	}
	85% {
		translate: 0 -10vh;
	}
	95% {
		translate: 0 110vh;
	}
	95% {
		translate: 0 -10vh;
	}
	100% {
		translate: 0 50vh;
	}
}
