@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:ital,wght@0,400;0,600;1,400&family=Space+Grotesk:wght@400;600&display=swap');

:root {
	--bg: #fafaf8;
	--surface: #ffffff;
	--text: #111111;
	--muted: #6b6b6b;
	--line: #e6e6e3;
	--accent: #2b4bff;
	--accent-soft: #e9edff;
	--on-accent: #ffffff;
	--ink: #1b1b1b;
	--display: 'Space Grotesk', system-ui, sans-serif;
	--ui: 'Hanken Grotesk', system-ui, sans-serif;
	--ease: cubic-bezier(0.2, 0.8, 0.2, 1);
	--spring: cubic-bezier(0.34, 1.56, 0.64, 1);
	--max: 1160px;
	color-scheme: light;
}

@media (prefers-color-scheme: dark) {
	:root:not([data-theme='light']) {
		--bg: #121212;
		--surface: #1a1a1a;
		--text: #f1f1ee;
		--muted: #9a9a96;
		--line: #2a2a28;
		--accent: #6b82ff;
		--accent-soft: #1d2340;
		--ink: #e8e8e4;
		color-scheme: dark;
	}
}

* {
	box-sizing: border-box;
	margin: 0;
}

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

body {
	background: var(--bg);
	color: var(--text);
	font: 17px/1.55 var(--ui);
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

a {
	color: inherit;
}

img,
video,
svg {
	display: block;
	max-width: 100%;
}

::selection {
	background: var(--accent);
	color: var(--on-accent);
}

:focus-visible {
	outline: 2px solid var(--accent);
	outline-offset: 3px;
	border-radius: 2px;
}

.wrap {
	width: 100%;
	max-width: var(--max);
	margin: 0 auto;
	padding: 0 24px;
}

.display {
	font-family: var(--display);
	font-weight: 600;
	letter-spacing: -0.02em;
}

.kicker {
	font: 600 13px/1 var(--display);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--accent);
}

.muted {
	color: var(--muted);
}

/* ---------- nav ---------- */

.nav {
	position: sticky;
	top: 0;
	z-index: 20;
	background: color-mix(in srgb, var(--bg) 82%, transparent);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border-bottom: 1px solid transparent;
	transition: border-color 0.2s;
}

.nav.scrolled {
	border-bottom-color: var(--line);
}

.nav .wrap {
	display: flex;
	align-items: center;
	gap: 28px;
	height: 64px;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font: 600 20px/1 var(--display);
	letter-spacing: -0.02em;
	text-decoration: none;
}

.logo {
	width: 28px;
	height: 28px;
	transition: transform 0.4s var(--spring);
}

.brand:hover .logo {
	transform: rotate(-8deg) scale(1.08);
}

.logo .thread {
	stroke-dasharray: 40;
	stroke-dashoffset: 40;
	animation: draw 1.1s 0.2s var(--ease) forwards;
}

.brand:hover .logo .thread {
	animation: draw 0.8s var(--ease) both;
}

@keyframes draw {
	from {
		stroke-dashoffset: 40;
	}
	to {
		stroke-dashoffset: 0;
	}
}

.nav-links {
	display: flex;
	gap: 24px;
	margin-left: auto;
	font-size: 15px;
}

.nav-links a {
	position: relative;
	text-decoration: none;
	color: var(--muted);
	transition: color 0.15s;
}

.nav-links a::after {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	bottom: -4px;
	height: 1.5px;
	background: currentColor;
	transform: scaleX(0);
	transform-origin: left;
	transition: transform 0.25s var(--ease);
}

.nav-links a:hover,
.nav-links a[aria-current='page'] {
	color: var(--text);
}

.nav-links a:hover::after,
.nav-links a[aria-current='page']::after {
	transform: scaleX(1);
}

/* ---------- buttons ---------- */

.btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	height: 48px;
	padding: 0 22px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
	color: var(--text);
	font: 600 16px/1 var(--ui);
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.25s var(--spring), border-color 0.15s, background 0.15s;
	will-change: transform;
}

.btn:hover {
	border-color: var(--text);
}

.btn:active {
	transform: scale(0.96);
}

.btn.primary {
	background: var(--accent);
	border-color: var(--accent);
	color: var(--on-accent);
	overflow: hidden;
}

.btn.primary::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
	transform: translateX(-120%);
	transition: transform 0.7s var(--ease);
}

.btn.primary:hover::before {
	transform: translateX(120%);
}

.btn.small {
	height: 36px;
	padding: 0 16px;
	font-size: 14px;
}

.btn .arrow {
	transition: transform 0.25s var(--spring);
}

.btn:hover .arrow {
	transform: translateX(3px);
}

/* ---------- hero ---------- */

.hero {
	position: relative;
	padding: 72px 0 40px;
}

.hero .wrap {
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
	gap: 48px;
	align-items: center;
}

.badge {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 6px 12px 6px 8px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
	font-size: 13px;
	color: var(--muted);
}

.badge .dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--accent);
	box-shadow: 0 0 0 0 var(--accent);
	animation: ping 2.2s infinite;
}

@keyframes ping {
	0% {
		box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent);
	}
	70%,
	100% {
		box-shadow: 0 0 0 10px transparent;
	}
}

.hero h1 {
	margin: 24px 0 20px;
	font: 600 clamp(48px, 7vw, 88px) / 0.98 var(--display);
	letter-spacing: -0.04em;
}

.hero h1 .word {
	display: inline-block;
	opacity: 0;
	transform: translateY(0.4em);
	animation: rise 0.8s var(--ease) forwards;
}

.hero h1 em {
	font-style: normal;
	color: var(--accent);
	position: relative;
}

.hero h1 em svg {
	position: absolute;
	left: -2%;
	bottom: -0.12em;
	width: 104%;
	height: 0.3em;
	overflow: visible;
}

.hero h1 em path {
	stroke-dasharray: 300;
	stroke-dashoffset: 300;
	animation: draw-long 1.2s 1.1s var(--ease) forwards;
}

@keyframes draw-long {
	to {
		stroke-dashoffset: 0;
	}
}

@keyframes rise {
	to {
		opacity: 1;
		transform: none;
	}
}

.lead {
	max-width: 32em;
	font-size: 20px;
	line-height: 1.5;
	color: var(--muted);
}

.cta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	margin-top: 32px;
}

.meta {
	margin-top: 14px;
	font-size: 14px;
	color: var(--muted);
}

.meta a {
	margin-left: 10px;
	text-underline-offset: 3px;
}

/* stamp desk (hero) */

.desk {
	position: relative;
	height: 520px;
	perspective: 1200px;
	user-select: none;
}

.stamp {
	--paper: #f3efe6;
	--ink: #2b4bff;
	position: absolute;
	width: 210px;
	aspect-ratio: 4 / 5;
	padding: 12px;
	background: var(--paper);
	-webkit-mask: var(--perf) center / 100% 100%;
	mask: var(--perf) center / 100% 100%;
	cursor: pointer;
	transform-style: preserve-3d;
	transition: transform 0.5s var(--spring), filter 0.3s;
	filter: drop-shadow(0 18px 24px rgba(17, 17, 17, 0.12));
}

.stamp-holder {
	position: absolute;
	transition: transform 0.6s var(--spring);
	animation: drop 0.9s var(--spring) both;
}

.stamp-holder:nth-child(2) {
	animation-delay: 0.15s;
}

.stamp-holder:nth-child(3) {
	animation-delay: 0.3s;
}

@keyframes drop {
	from {
		opacity: 0;
		transform: translateY(-60px) rotate(-14deg) scale(1.1);
	}
}

.stamp .face {
	position: relative;
	height: 100%;
	overflow: hidden;
	color: var(--ink);
	border: 1.5px solid color-mix(in srgb, var(--ink) 35%, transparent);
}

.stamp .face svg {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0.55;
}

.stamp .c,
.stamp .v,
.stamp .t {
	position: absolute;
	font-family: var(--display);
	font-weight: 600;
}

.stamp .c {
	left: 10px;
	top: 10px;
	font-size: 10px;
	letter-spacing: 0.12em;
}

.stamp .v {
	right: 10px;
	top: 6px;
	font-size: 26px;
}

.stamp .t {
	left: 10px;
	right: 10px;
	bottom: 10px;
	font-size: 24px;
	line-height: 1;
	letter-spacing: -0.02em;
}

.postmark {
	position: absolute;
	left: 52%;
	top: 12%;
	width: 170px;
	color: var(--ink);
	opacity: 0;
	transform: rotate(-14deg) scale(1.6);
	pointer-events: none;
	mix-blend-mode: multiply;
}

.stamp-holder.posted .postmark {
	animation: slam 0.35s var(--ease) forwards;
}

@keyframes slam {
	60% {
		opacity: 0.8;
		transform: rotate(-14deg) scale(0.94);
	}
	100% {
		opacity: 0.7;
		transform: rotate(-14deg) scale(1);
	}
}

.stamp-holder.shake {
	animation: shake 0.3s linear;
}

@keyframes shake {
	25% {
		translate: -3px 1px;
	}
	50% {
		translate: 3px -1px;
	}
	75% {
		translate: -2px 0;
	}
}

.desk-hint {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 6px;
	text-align: center;
	font-size: 14px;
	color: var(--muted);
	transition: opacity 0.3s;
}

.desk-hint b {
	color: var(--text);
	font-weight: 600;
}

/* ---------- sections ---------- */

section {
	padding: 96px 0;
}

.section-head {
	max-width: 44em;
	margin-bottom: 48px;
}

.section-head h2 {
	margin-top: 14px;
	font: 600 clamp(32px, 4.2vw, 52px) / 1.04 var(--display);
	letter-spacing: -0.03em;
}

.section-head p {
	margin-top: 16px;
	font-size: 19px;
	color: var(--muted);
}

.reveal {
	opacity: 0;
	transform: translateY(24px);
	transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
	transition-delay: var(--d, 0s);
}

.reveal.in {
	opacity: 1;
	transform: none;
}

/* film */

.film {
	position: relative;
	border: 1px solid var(--line);
	border-radius: 16px;
	overflow: hidden;
	background: #fff;
	aspect-ratio: 16 / 9;
}

.film video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.film button {
	position: absolute;
	right: 14px;
	bottom: 14px;
}

/* features */

.features {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 16px;
}

.card {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: 24px;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--surface);
	overflow: hidden;
	transition: border-color 0.2s, transform 0.4s var(--spring);
}

.card:hover {
	border-color: color-mix(in srgb, var(--text) 30%, var(--line));
	transform: translateY(-4px);
}

.card h3 {
	margin-top: 20px;
	font: 600 22px/1.2 var(--display);
	letter-spacing: -0.02em;
}

.card p {
	margin-top: 8px;
	color: var(--muted);
	font-size: 16px;
}

.card .more {
	margin-top: auto;
	padding-top: 16px;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	color: var(--accent);
}

.card .more span {
	display: inline-block;
	transition: transform 0.25s var(--spring);
}

.card:hover .more span {
	transform: translateX(4px);
}

.demo {
	position: relative;
	height: 190px;
	border-radius: 10px;
	background: var(--bg);
	border: 1px solid var(--line);
	overflow: hidden;
}

/* demo: composer */

.mini-blocks {
	position: absolute;
	inset: 10px 10px 56px;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	gap: 6px;
}

.mini-block {
	display: flex;
	gap: 8px;
	align-items: center;
	padding: 8px 10px;
	border: 1px solid var(--line);
	border-radius: 6px;
	background: var(--surface);
	font-size: 13px;
	animation: pop 0.45s var(--spring) both;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.mini-block .tag {
	flex: none;
	padding: 1px 6px;
	border-radius: 4px;
	background: var(--accent-soft);
	color: var(--accent);
	font-size: 11px;
	font-weight: 600;
}

@keyframes pop {
	from {
		opacity: 0;
		transform: translateY(14px) scale(0.96);
	}
}

.mini-input {
	position: absolute;
	left: 10px;
	right: 10px;
	bottom: 10px;
	display: flex;
	align-items: center;
	height: 38px;
	border: 1px solid var(--line);
	border-radius: 6px;
	background: var(--surface);
	transition: border-color 0.15s;
}

.mini-input:focus-within {
	border-color: var(--accent);
}

.mini-input input {
	flex: 1;
	min-width: 0;
	height: 100%;
	padding: 0 10px;
	border: 0;
	background: none;
	font: 14px var(--ui);
	color: var(--text);
	outline: none;
}

.mini-input kbd {
	margin-right: 8px;
	padding: 2px 6px;
	border: 1px solid var(--line);
	border-radius: 4px;
	font: 11px var(--ui);
	color: var(--muted);
}

/* demo: sources */

.sources {
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 100%;
	padding: 0 18px;
}

.apps {
	display: grid;
	gap: 10px;
}

.app {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 6px 10px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	transition: transform 0.3s var(--spring), border-color 0.15s;
}

.app:hover {
	transform: translateX(6px);
	border-color: var(--accent);
}

.app i {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--c);
}

.hub {
	position: relative;
	display: grid;
	place-items: center;
	width: 84px;
	height: 84px;
	border-radius: 18px;
	background: var(--accent);
	color: #fff;
	transition: transform 0.3s var(--spring);
}

.hub.got {
	animation: gulp 0.4s var(--spring);
}

@keyframes gulp {
	50% {
		transform: scale(1.12) rotate(-4deg);
	}
}

.flyer {
	position: absolute;
	padding: 4px 8px;
	border-radius: 999px;
	background: var(--surface);
	border: 1px solid var(--line);
	font-size: 11px;
	font-weight: 600;
	pointer-events: none;
	z-index: 2;
}

/* demo: precedents */

.prec {
	position: absolute;
	inset: 10px;
	display: grid;
	align-content: center;
	gap: 6px;
}

.pcard {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 6px 8px;
	border: 1px solid var(--line);
	border-radius: 8px;
	background: var(--surface);
	transition: border-color 0.2s, transform 0.35s var(--spring), opacity 0.3s;
}

.pcard.kept {
	border-color: var(--accent);
}

.pcard .src {
	width: 30px;
	height: 30px;
	flex: none;
	border-radius: 6px;
	background: var(--bg);
	border: 1px solid var(--line);
	display: grid;
	place-items: center;
	font-size: 10px;
	font-weight: 600;
	color: var(--muted);
}

.pcard div {
	flex: 1;
	min-width: 0;
	font-size: 13px;
	line-height: 1.3;
}

.pcard div small {
	display: block;
	color: var(--muted);
}

.keep {
	flex: none;
	padding: 5px 10px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
	color: var(--text);
	font: 600 12px var(--ui);
	cursor: pointer;
	transition: transform 0.35s var(--spring), background 0.15s, color 0.15s, border-color 0.15s;
}

.keep:active {
	transform: scale(0.88);
}

.kept .keep {
	background: var(--accent);
	border-color: var(--accent);
	color: #fff;
}

/* demo: voice */

.voice {
	display: grid;
	place-items: center;
	align-content: center;
	gap: 16px;
	height: 100%;
}

.bars {
	display: flex;
	align-items: center;
	gap: 4px;
	height: 56px;
}

.bars span {
	width: 5px;
	height: 18%;
	border-radius: 3px;
	background: var(--accent);
	opacity: 0.35;
	transition: height 0.12s, opacity 0.2s;
}

.rec {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 14px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
	color: var(--text);
	font: 600 13px var(--ui);
	cursor: pointer;
	transition: transform 0.3s var(--spring);
}

.rec:active {
	transform: scale(0.92);
}

.rec i {
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: #d2462b;
}

.recording .rec i {
	animation: blink 1s infinite;
}

.recording .bars span {
	opacity: 1;
}

@keyframes blink {
	50% {
		opacity: 0.25;
	}
}

/* demo: envelope */

.env-demo {
	display: grid;
	place-items: center;
	height: 100%;
	perspective: 600px;
	cursor: pointer;
}

.envelope {
	position: relative;
	width: 200px;
	height: 128px;
	background: #efe6d6;
	border-radius: 4px;
	transition: transform 0.5s var(--spring);
}

.env-demo:hover .envelope {
	transform: rotate(-3deg) translateY(-4px);
}

.envelope .flap {
	position: absolute;
	inset: 0 0 auto;
	height: 70px;
	background: #e7dcc8;
	clip-path: polygon(0 0, 100% 0, 50% 100%);
	transform-origin: top;
	transition: transform 0.6s var(--ease);
}

.env-demo:hover .flap {
	transform: rotateX(160deg);
}

.envelope .mini-stamp {
	position: absolute;
	right: 12px;
	top: 12px;
	width: 38px;
	height: 46px;
	background: var(--accent);
	-webkit-mask: var(--perf) center / 100% 100%;
	mask: var(--perf) center / 100% 100%;
	transition: transform 0.5s var(--spring);
}

.env-demo.sent .mini-stamp {
	animation: stampit 0.45s var(--spring);
}

@keyframes stampit {
	0% {
		transform: translateY(-30px) scale(1.4) rotate(-20deg);
		opacity: 0;
	}
}

.envelope .pm {
	position: absolute;
	right: 36px;
	top: 14px;
	width: 70px;
	color: #222;
	opacity: 0;
}

.env-demo.sent .pm {
	animation: slam 0.35s 0.25s var(--ease) forwards;
}

.envelope .lines {
	position: absolute;
	left: 16px;
	bottom: 18px;
	display: grid;
	gap: 6px;
}

.envelope .lines span {
	height: 4px;
	width: 90px;
	border-radius: 2px;
	background: #d6c8ae;
}

.envelope .lines span:last-child {
	width: 60px;
}

/* demo: private */

.vault {
	display: grid;
	place-items: center;
	height: 100%;
	padding-top: 18px;
}

.laptop {
	position: relative;
	width: 150px;
	height: 96px;
	border: 2px solid var(--text);
	border-radius: 8px 8px 2px 2px;
}

.laptop::after {
	content: '';
	position: absolute;
	left: -16px;
	right: -16px;
	bottom: -12px;
	height: 10px;
	border: 2px solid var(--text);
	border-radius: 0 0 8px 8px;
}

.laptop .files {
	position: absolute;
	inset: 12px;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	align-content: flex-start;
}

.laptop .files span {
	width: 22px;
	height: 26px;
	border-radius: 3px;
	background: var(--accent);
	opacity: 0.85;
	animation: settle 2.4s var(--ease) infinite;
	animation-delay: calc(var(--i) * 0.12s);
}

@keyframes settle {
	0%,
	100% {
		transform: none;
	}
	50% {
		transform: translateY(-4px);
	}
}

.cloud-x {
	position: absolute;
	right: 12px;
	top: 12px;
	font: 600 12px var(--ui);
	color: var(--muted);
	padding: 4px 8px;
	border: 1px dashed var(--line);
	border-radius: 999px;
	text-decoration: line-through;
}

/* friends */

.friends {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 16px;
}

.panel {
	padding: 28px;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--surface);
}

.panel h3 {
	font: 600 22px/1.2 var(--display);
	letter-spacing: -0.02em;
	margin-bottom: 14px;
}

.checks {
	list-style: none;
	padding: 0;
	display: grid;
	gap: 10px;
}

.checks li {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	cursor: pointer;
	user-select: none;
}

.checks li::before {
	content: '';
	flex: none;
	width: 20px;
	height: 20px;
	margin-top: 2px;
	border: 1.5px solid var(--line);
	border-radius: 6px;
	transition: background 0.2s, border-color 0.2s, transform 0.3s var(--spring);
}

.checks li.done::before {
	background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3 3 7-7' fill='none' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat;
	border-color: var(--accent);
	transform: scale(1.1);
}

.checks li.done span {
	color: var(--muted);
	text-decoration: line-through;
	text-decoration-color: var(--accent);
}

.progress {
	margin-top: 18px;
	height: 6px;
	border-radius: 3px;
	background: var(--bg);
	border: 1px solid var(--line);
	overflow: hidden;
}

.progress i {
	display: block;
	height: 100%;
	width: 0;
	background: var(--accent);
	transition: width 0.5s var(--spring);
}

/* footer */

footer {
	padding: 48px 0 64px;
	border-top: 1px solid var(--line);
	font-size: 14px;
	color: var(--muted);
}

footer .wrap {
	display: flex;
	flex-wrap: wrap;
	gap: 16px 32px;
	align-items: center;
	justify-content: space-between;
}

footer nav {
	display: flex;
	gap: 20px;
}

/* ---------- docs ---------- */

.docs {
	display: grid;
	grid-template-columns: 240px minmax(0, 1fr);
	gap: 56px;
	padding-top: 40px;
	padding-bottom: 120px;
}

.toc {
	position: sticky;
	top: 88px;
	align-self: start;
	max-height: calc(100vh - 110px);
	overflow-y: auto;
	padding-right: 8px;
	font-size: 14px;
}

.toc h4 {
	margin: 22px 0 8px;
	font: 600 12px/1 var(--display);
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--muted);
}

.toc h4:first-child {
	margin-top: 0;
}

.toc a {
	position: relative;
	display: block;
	padding: 5px 0 5px 14px;
	text-decoration: none;
	color: var(--muted);
	border-left: 1.5px solid var(--line);
	transition: color 0.15s, border-color 0.15s, padding 0.25s var(--spring);
}

.toc a:hover {
	color: var(--text);
	padding-left: 18px;
}

.toc a.active {
	color: var(--text);
	border-left-color: var(--accent);
	font-weight: 600;
}

.doc-search {
	width: 100%;
	height: 38px;
	margin-bottom: 18px;
	padding: 0 12px;
	border: 1px solid var(--line);
	border-radius: 8px;
	background: var(--surface);
	color: var(--text);
	font: 14px var(--ui);
}

.doc-search:focus {
	outline: none;
	border-color: var(--accent);
}

.prose {
	max-width: 760px;
	min-width: 0;
}

.prose table {
	display: block;
	overflow-x: auto;
}

.prose > header h1 {
	font: 600 clamp(40px, 5vw, 60px) / 1 var(--display);
	letter-spacing: -0.035em;
	margin: 12px 0 16px;
}

.prose > header p {
	font-size: 19px;
	color: var(--muted);
}

.prose section {
	padding: 56px 0 0;
	scroll-margin-top: 80px;
}

.prose h2 {
	font: 600 32px/1.1 var(--display);
	letter-spacing: -0.025em;
	margin-bottom: 14px;
}

.prose h2 a {
	text-decoration: none;
}

.prose h2 a::after {
	content: '#';
	margin-left: 10px;
	color: var(--accent);
	opacity: 0;
	transition: opacity 0.15s;
}

.prose h2:hover a::after {
	opacity: 1;
}

.prose h3 {
	font: 600 20px/1.25 var(--display);
	letter-spacing: -0.015em;
	margin: 28px 0 8px;
}

.prose p,
.prose ul,
.prose ol {
	margin-bottom: 14px;
}

.prose ul,
.prose ol {
	padding-left: 1.3em;
}

.prose li {
	margin-bottom: 6px;
}

.prose li::marker {
	color: var(--accent);
}

.prose strong {
	font-weight: 600;
}

.prose code,
kbd {
	padding: 1px 6px;
	border: 1px solid var(--line);
	border-radius: 5px;
	background: var(--surface);
	font: 0.85em ui-monospace, SFMono-Regular, Menlo, monospace;
}

.prose table {
	width: 100%;
	margin: 8px 0 18px;
	border-collapse: collapse;
	font-size: 15px;
}

.prose th,
.prose td {
	padding: 10px 12px 10px 0;
	border-bottom: 1px solid var(--line);
	text-align: left;
	vertical-align: top;
}

.prose th {
	font-weight: 600;
	font-size: 13px;
	color: var(--muted);
}

.tip {
	margin: 18px 0;
	padding: 14px 16px;
	border: 1px solid var(--line);
	border-left: 3px solid var(--accent);
	border-radius: 8px;
	background: var(--surface);
	font-size: 15px;
}

.tip.warn {
	border-left-color: #d2462b;
}

.code {
	position: relative;
	margin: 12px 0 18px;
}

.code pre {
	padding: 16px 18px;
	padding-right: 84px;
	border-radius: 10px;
	background: #151515;
	color: #e9e9e6;
	font: 13.5px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace;
	overflow-x: auto;
}

.copy {
	position: absolute;
	right: 10px;
	top: 10px;
	padding: 6px 10px;
	border: 1px solid #333;
	border-radius: 6px;
	background: #222;
	color: #ddd;
	font: 600 12px var(--ui);
	cursor: pointer;
	transition: transform 0.3s var(--spring), background 0.15s;
}

.copy:active {
	transform: scale(0.9);
}

.copy.done {
	background: var(--accent);
	border-color: var(--accent);
	color: #fff;
}

.os-tabs {
	display: inline-flex;
	gap: 4px;
	padding: 4px;
	margin: 6px 0 14px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--surface);
}

.os-tabs button {
	padding: 6px 14px;
	border: 0;
	border-radius: 999px;
	background: none;
	color: var(--muted);
	font: 600 14px var(--ui);
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
}

.os-tabs button[aria-selected='true'] {
	background: var(--text);
	color: var(--bg);
}

[data-os-panel][hidden] {
	display: none;
}

details.faq {
	border-bottom: 1px solid var(--line);
}

details.faq summary {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	padding: 14px 0;
	font-weight: 600;
	cursor: pointer;
	list-style: none;
}

details.faq summary::-webkit-details-marker {
	display: none;
}

details.faq summary::after {
	content: '+';
	font: 400 22px/1 var(--display);
	color: var(--accent);
	transition: transform 0.3s var(--spring);
}

details.faq[open] summary::after {
	transform: rotate(45deg);
}

details.faq > div {
	padding-bottom: 14px;
	color: var(--muted);
}

.hidden-by-search {
	display: none;
}

.no-results {
	padding: 40px 0;
	color: var(--muted);
}

/* ---------- responsive ---------- */

@media (max-width: 960px) {
	.hero .wrap {
		grid-template-columns: 1fr;
	}

	.desk {
		height: 420px;
	}

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

	.docs {
		grid-template-columns: minmax(0, 1fr);
		gap: 24px;
	}

	.toc-toggle {
		display: inline-flex !important;
	}

	.toc {
		position: static;
		max-height: none;
		border: 1px solid var(--line);
		border-radius: 12px;
		padding: 16px;
		background: var(--surface);
	}

	.toc nav {
		display: none;
	}

	.toc.open nav {
		display: block;
	}
}

@media (max-width: 640px) {
	body {
		font-size: 16px;
	}

	.nav-links a.hide-sm {
		display: none;
	}

	.nav .wrap {
		gap: 16px;
	}

	.hero {
		padding-top: 40px;
	}

	.desk {
		height: 360px;
		transform: scale(0.82);
		transform-origin: top center;
		margin-bottom: -60px;
	}

	.features,
	.friends {
		grid-template-columns: 1fr;
	}

	section {
		padding: 64px 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}

	.reveal,
	.hero h1 .word {
		opacity: 1;
		transform: none;
	}
}
