/* ===========================================================
   wapper.ai — one-page landing
   Brand tokens are hand-copied from app/src/app.css on purpose,
   so the site and the product read as the same object. The
   expression is deliberately flatter than the product UI:
   hairlines instead of cards, one continuous stroke instead of
   a grid of panels.
   =========================================================== */

:root {
	--canvas: #f1efe9;
	--card: #ffffff;

	--ink: #191720;
	--ink-body: #43404b;
	--ink-mute: #6b6875;
	--ink-meta: #9a968e;

	--brand: #6d4ee0;
	--brand-hover: #5a3ec9;
	--ok: #2fa36b;

	--line: rgb(0 0 0 / 0.08);
	--line-strong: rgb(0 0 0 / 0.14);
	--shadow-brand: 0 3px 12px rgb(109 78 224 / 0.3);

	--display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
	--sans: 'Instrument Sans', ui-sans-serif, system-ui, sans-serif;
	--mono: 'DM Mono', ui-monospace, 'SFMono-Regular', monospace;

	--wrap: 1000px;
	--gut: clamp(20px, 5vw, 40px);
	--r: 11px;
}

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

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

body {
	margin: 0;
	background: var(--canvas);
	color: var(--ink-body);
	font-family: var(--sans);
	font-size: 1.0625rem;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

h1,
h2 {
	margin: 0;
	font-family: var(--display);
	color: var(--ink);
	font-weight: 500;
	letter-spacing: -0.025em;
	line-height: 1.06;
}

p {
	margin: 0;
}

a {
	color: inherit;
}

.wrap {
	width: 100%;
	max-width: var(--wrap);
	margin-inline: auto;
	padding-inline: var(--gut);
}

.skip {
	position: absolute;
	left: -9999px;
}

.skip:focus {
	left: 12px;
	top: 12px;
	z-index: 20;
	background: var(--card);
	padding: 10px 14px;
	border-radius: var(--r);
	box-shadow: 0 2px 10px rgb(0 0 0 / 0.15);
}

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

/* --- shared bits ---------------------------------------------------- */

.tag {
	font-family: var(--mono);
	font-size: 0.75rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--ink-meta);
}

.lede {
	max-width: 46ch;
	color: var(--ink-mute);
	font-size: 1.0625rem;
}

.btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--sans);
	font-size: 0.9375rem;
	font-weight: 500;
	text-decoration: none;
	padding: 10px 16px;
	border-radius: var(--r);
	border: 1px solid transparent;
	transition: background 0.15s, transform 0.15s;
}

.btn-primary {
	background: var(--brand);
	color: #fff;
	box-shadow: var(--shadow-brand);
}

.btn-primary:hover {
	background: var(--brand-hover);
}

.btn-lg {
	padding: 14px 22px;
	font-size: 1rem;
}

.btn .arrow {
	transition: transform 0.15s;
}

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

.mark {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	font-family: var(--display);
	font-weight: 700;
	font-size: 1.0625rem;
	letter-spacing: -0.02em;
	color: var(--ink);
	text-decoration: none;
}

.mark-name {
	white-space: nowrap;
}

.mark em {
	font-style: normal;
	font-weight: 500;
	color: var(--brand);
}

.mark-ico {
	display: block;
	width: 28px;
	height: 28px;
}

/* --- bar ------------------------------------------------------------ */

.bar {
	border-bottom: 1px solid var(--line);
	background: color-mix(in srgb, var(--canvas) 88%, transparent);
	backdrop-filter: blur(8px);
	position: sticky;
	top: 0;
	z-index: 10;
}

.bar-in {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	height: 62px;
}

/* --- receipt: one sentence in, one link out -------------------------- */

.receipt {
	padding-block: clamp(3.5rem, 8vw, 6.5rem) clamp(3rem, 6vw, 5rem);
}

.say {
	margin-top: 1.1rem;
	font-size: clamp(2.35rem, 7.4vw, 5rem);
	letter-spacing: -0.035em;
	text-wrap: balance;
}

.say-lead {
	color: var(--ink-meta);
}

.say-rest {
	color: var(--ink);
}

.say-caret {
	display: inline-block;
	width: 3px;
	height: 0.78em;
	margin-left: 0.06em;
	vertical-align: -0.06em;
	background: var(--brand);
	animation: blink 1.1s steps(1) infinite;
}

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

.receipt .lede {
	margin-top: 1.6rem;
	font-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
	max-width: 52ch;
}

.go {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 14px 18px;
	margin-top: 2rem;
}

.go-note {
	font-family: var(--mono);
	font-size: 0.8125rem;
	color: var(--ink-meta);
}

/* the stroke */

.run {
	position: relative;
	list-style: none;
	margin: 4.5rem 0 0;
	padding: 0;
	max-width: 640px;
}

.run::before {
	content: '';
	position: absolute;
	left: 4px;
	top: -44px;
	width: 1px;
	height: 44px;
	background: linear-gradient(to bottom, transparent, var(--line-strong));
}

.job {
	position: relative;
	display: grid;
	grid-template-columns: 3.6rem 6.2rem max-content auto;
	align-items: baseline;
	gap: 0 1.1rem;
	padding: 0.95rem 0 0.95rem 2.1rem;
	font-family: var(--mono);
	font-size: 0.875rem;
}

/* segment of the stroke, one per row */
.job::before {
	content: '';
	position: absolute;
	left: 4px;
	top: 0;
	bottom: 0;
	width: 1px;
	background: var(--line-strong);
}

.job:last-child::before {
	bottom: 50%;
}

/* station */
.job::after {
	content: '';
	position: absolute;
	left: 0;
	top: 50%;
	width: 9px;
	height: 9px;
	margin-top: -4.5px;
	border-radius: 50%;
	background: var(--canvas);
	border: 1px solid var(--ink-meta);
	transition: background 0.3s, border-color 0.3s;
}

.job.on::after {
	background: var(--brand);
	border-color: var(--brand);
}

.job-end.on::after {
	background: var(--ok);
	border-color: var(--ok);
}

.job-t {
	color: var(--ink-meta);
	font-variant-numeric: tabular-nums;
}

.job-k {
	color: var(--ink);
	font-weight: 500;
}

.job-v {
	color: var(--ink-mute);
	font-family: var(--sans);
	font-size: 0.9375rem;
}

.job-url {
	color: var(--brand);
	text-decoration: none;
	font-family: var(--mono);
	font-size: 0.875rem;
	border-bottom: 1px solid color-mix(in srgb, var(--brand) 35%, transparent);
}

.job-url:hover {
	border-bottom-color: var(--brand);
}

.job-live {
	font-size: 0.6875rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--ok);
	opacity: 0;
	transition: opacity 0.3s;
}

.job-end.on .job-live {
	opacity: 1;
}

/* rows arrive one after another, only once each cycle */
.job {
	opacity: 0.32;
	transition: opacity 0.35s;
}

.job.on {
	opacity: 1;
}

.run-foot {
	margin-top: 1.9rem;
	padding-left: 2.1rem;
	max-width: 46ch;
	font-size: 0.9375rem;
	color: var(--ink-mute);
}

/* --- talk ------------------------------------------------------------ */

.talk {
	padding-block: clamp(3rem, 6vw, 5rem);
	border-top: 1px solid var(--line);
}

.talk-in {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
	gap: clamp(2rem, 5vw, 4rem);
	align-items: start;
}

.talk-copy h2 {
	margin-block: 0.9rem 1rem;
	font-size: clamp(1.6rem, 3vw, 2.15rem);
}

.asks {
	list-style: none;
	margin: 0;
	padding: 0;
	border-top: 1px solid var(--line);
}

.asks li {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 1.5rem;
	padding: 0.95rem 0;
	border-bottom: 1px solid var(--line);
}

.ask {
	color: var(--ink);
	font-size: 0.9375rem;
}

.ask::before {
	content: '“';
	color: var(--ink-meta);
}

.ask::after {
	content: '”';
	color: var(--ink-meta);
}

.ask-r {
	flex: none;
	font-family: var(--mono);
	font-size: 0.8125rem;
	color: var(--ink-meta);
	white-space: nowrap;
}

/* --- close ----------------------------------------------------------- */

.close {
	padding-block: clamp(3.5rem, 8vw, 6rem);
	border-top: 1px solid var(--line);
}

.close h2 {
	max-width: 24ch;
	font-size: clamp(1.9rem, 4.4vw, 3rem);
	text-wrap: balance;
}

.close .lede {
	margin-top: 1.1rem;
}

.close .btn {
	margin-top: 1.9rem;
}

.close .go-note {
	display: block;
	margin-top: 1rem;
}

/* --- foot ------------------------------------------------------------ */

.foot {
	border-top: 1px solid var(--line);
	padding-block: 2.2rem 2.6rem;
}

.foot-in {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 12px 24px;
}

.foot-note {
	flex: 1 1 16rem;
	font-size: 0.875rem;
	color: var(--ink-mute);
}

.foot-meta {
	display: flex;
	gap: 18px;
	font-family: var(--mono);
	font-size: 0.8125rem;
	color: var(--ink-meta);
}

.foot-meta a {
	text-decoration: none;
	border-bottom: 1px solid var(--line-strong);
}

.foot-meta a:hover {
	color: var(--ink);
}

/* --- narrow ---------------------------------------------------------- */

@media (max-width: 720px) {
	.talk-in {
		grid-template-columns: 1fr;
	}

	.job {
		grid-template-columns: 3.6rem 1fr auto;
		row-gap: 0.2rem;
	}

	.job-v {
		grid-column: 2 / -1;
	}

	.asks li {
		flex-direction: column;
		gap: 0.3rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	.say-caret {
		animation: none;
	}

	.btn,
	.btn .arrow,
	.job,
	.job::after,
	.job-live {
		transition: none;
	}
}
