/* StickerBridge public site.
 *
 * Riso Sheet, ported from the app's theme.dart: risograph spot inks on
 * newsprint. Flat colour, no gradients, hard borders, offset shadows that read
 * as print misregistration. Same fonts as the app, self-hosted as woff2 so the
 * page makes no third-party request. */

@font-face {
	font-family: "Bricolage Grotesque";
	src: url("fonts/BricolageGrotesque.woff2") format("woff2-variations");
	font-weight: 200 800;
	font-display: swap;
}

@font-face {
	font-family: "Hanken Grotesk";
	src: url("fonts/HankenGrotesk.woff2") format("woff2-variations");
	font-weight: 100 900;
	font-display: swap;
}

@font-face {
	font-family: "JetBrains Mono";
	src: url("fonts/JetBrainsMono.woff2") format("woff2-variations");
	font-weight: 100 800;
	font-display: swap;
}

:root {
	/* Light is the default, whatever the operating system prefers. The toggle in
	 * the header sets data-theme="dark" and stores the choice; nothing here
	 * reads prefers-color-scheme, so a visitor on a dark desktop still lands on
	 * the newsprint version the app was designed around. */
	color-scheme: light;

	/* Inks, straight from AppTheme. */
	--newsprint: #fbf7f0;
	--soot: #16130f;
	--blue: #0b5cff;
	--pink: #ff3d9a;
	--marigold: #ffb020;

	--bg: var(--newsprint);
	--panel: #fffdf9;
	--panel-2: #f5f0e6;
	--fg: var(--soot);
	--muted: #5c564c;
	--line: #b8b0a2;
	--line-soft: #dcd5c8;
	--accent: var(--blue);
	--on-accent: #ffffff;

	--display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
	--body: "Hanken Grotesk", ui-sans-serif, system-ui, -apple-system, sans-serif;
	--mono: "JetBrains Mono", ui-monospace, sfmono-regular, consolas, monospace;

	/* Print-shop geometry: the app's radius scale. */
	--r-sm: 8px;
	--r-md: 12px;
	--r-lg: 16px;
	--r-xl: 22px;

	--edge: 2px solid var(--soot);
	/* The offset behind buttons and cards: misregistration, not a soft shadow.
	 * On the dark ground soot is invisible, so it goes to black there. */
	--shadow: var(--soot);
	--gutter: 22px;
}

:root[data-theme="dark"] {
	color-scheme: dark;
	--bg: #12100c;
	--panel: #1c1915;
	--panel-2: #262219;
	--fg: #f6f1e8;
	--muted: #a8a093;
	--line: #5a5347;
	--line-soft: #34302a;
	--accent: #7fa6ff;
	--on-accent: #061a33;
	--edge: 2px solid #433d33;
	--shadow: #000;
}

* {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

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

body {
	margin: 0;
	background: var(--bg);
	color: var(--fg);
	font-family: var(--body);
	font-size: 17px;
	line-height: 1.55;
	-webkit-text-size-adjust: 100%;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

/* Paper grain. One inline SVG turbulence, no image request. */
body::after {
	content: "";
	position: fixed;
	inset: 0;
	z-index: 9999;
	pointer-events: none;
	opacity: 0.035;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap {
	width: 100%;
	max-width: 68rem;
	margin: 0 auto;
	padding: 0 var(--gutter);
}

.narrow {
	max-width: 46rem;
}

/* ----------------------------------------------------------------- type */

h1,
h2,
h3 {
	font-family: var(--display);
	font-weight: 800;
	margin: 0;
}

h1 {
	font-size: clamp(2.6rem, 7vw, 4.4rem);
	line-height: 0.96;
	letter-spacing: -0.045em;
}

h2 {
	font-size: clamp(1.7rem, 3.6vw, 2.4rem);
	line-height: 1.05;
	letter-spacing: -0.03em;
}

h3 {
	font-size: 1.15rem;
	line-height: 1.2;
	letter-spacing: -0.02em;
	font-weight: 700;
}

p {
	margin: 0 0 1rem;
}

a {
	color: var(--accent);
	text-underline-offset: 3px;
}

strong {
	font-weight: 650;
}

code,
.mono {
	font-family: var(--mono);
	font-size: 0.9em;
}

.eyebrow {
	font-family: var(--mono);
	font-size: 0.69rem;
	font-weight: 500;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--muted);
	margin: 0 0 1rem;
	display: block;
}

.eyebrow.hot {
	color: var(--fg);
	background: var(--marigold);
	display: inline-block;
	padding: 0.3rem 0.6rem;
	border-radius: var(--r-sm);
}

.lede {
	font-size: clamp(1.05rem, 2.2vw, 1.3rem);
	color: var(--muted);
	max-width: 34rem;
}

/* --------------------------------------------------------------- chrome */

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

header.site .wrap {
	display: flex;
	align-items: center;
	gap: 1.5rem;
	height: 62px;
}

.brand {
	font-family: var(--display);
	font-weight: 800;
	font-size: 1.15rem;
	letter-spacing: -0.03em;
	color: var(--fg);
	text-decoration: none;
	margin-right: auto;
	display: flex;
	align-items: center;
	gap: 0.55rem;
}

.brand .mark {
	width: 22px;
	height: 22px;
	border-radius: 6px;
	background: var(--blue);
	position: relative;
	flex: none;
}

.brand .mark::after {
	content: "";
	position: absolute;
	inset: 5px 5px auto auto;
	width: 12px;
	height: 12px;
	border-radius: 4px;
	background: var(--pink);
}

header.site nav {
	display: flex;
	gap: 1.35rem;
	font-size: 0.95rem;
}

header.site nav a {
	color: var(--muted);
	text-decoration: none;
}

header.site nav a:hover {
	color: var(--fg);
}

@media (max-width: 640px) {
	header.site nav a.hide-sm {
		display: none;
	}
}

.theme-toggle {
	width: 36px;
	height: 36px;
	flex: none;
	display: grid;
	place-items: center;
	padding: 0;
	border: 1px solid var(--line-soft);
	border-radius: var(--r-sm);
	background: transparent;
	color: var(--muted);
	cursor: pointer;
}

.theme-toggle:hover {
	color: var(--fg);
	background: var(--panel-2);
}

.theme-toggle svg {
	width: 17px;
	height: 17px;
	display: block;
}

/* Show the destination, not the current state: a moon while light, a sun while
 * dark. */
:root:not([data-theme="dark"]) .theme-toggle .sun,
:root[data-theme="dark"] .theme-toggle .moon {
	display: none;
}

/* --------------------------------------------------------------- pieces */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	height: 52px;
	padding: 0 1.5rem;
	border-radius: var(--r-lg);
	border: var(--edge);
	background: var(--blue);
	color: #fff;
	font-family: var(--body);
	font-weight: 650;
	font-size: 1rem;
	text-decoration: none;
	box-shadow: 4px 4px 0 var(--shadow);
	transition:
		transform 0.16s ease,
		box-shadow 0.16s ease;
}

.btn:hover {
	transform: translate(2px, 2px);
	box-shadow: 2px 2px 0 var(--shadow);
}

.btn:active {
	transform: translate(4px, 4px);
	box-shadow: 0 0 0 var(--shadow);
}

.btn.pink {
	background: var(--pink);
	color: var(--soot);
}

.btn.ghost {
	background: transparent;
	color: var(--fg);
	box-shadow: none;
}

.btn.ghost:hover {
	background: var(--panel-2);
	transform: none;
}

.card {
	background: var(--panel);
	border: 1px solid var(--line-soft);
	border-radius: var(--r-xl);
	padding: 1.5rem;
}

.card.ink {
	border: var(--edge);
	box-shadow: 6px 6px 0 var(--shadow);
}

section {
	padding: clamp(3.5rem, 9vw, 6.5rem) 0;
}

section + section {
	border-top: 1px solid var(--line-soft);
}

.grid {
	display: grid;
	gap: 1.25rem;
	grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
	margin-top: 2.5rem;
}

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

.hero {
	padding-top: clamp(3rem, 8vw, 5.5rem);
	padding-bottom: clamp(3rem, 8vw, 5rem);
	position: relative;
	overflow: hidden;
}

.hero-grid {
	display: grid;
	grid-template-columns: 1.15fr 0.85fr;
	gap: clamp(2rem, 5vw, 4rem);
	align-items: center;
}

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

	/* Stacked, the sheet would stretch the full column and each tile becomes a
	 * 150px slab. Keep it a sheet of stickers, not a wall of them. */
	.sheet {
		max-width: 19rem;
		margin: 0 auto;
	}
}

.hero h1 .ink-blue {
	color: var(--blue);
}

.hero h1 .ink-pink {
	color: var(--pink);
}

.cta-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	margin-top: 2rem;
}

.hero-note {
	margin-top: 1.25rem;
	font-size: 0.92rem;
	color: var(--muted);
}

/* The sticker sheet: a perforated page of tiles, the thing the app produces. */
.sheet {
	background: var(--panel);
	border: var(--edge);
	border-radius: var(--r-xl);
	box-shadow: 8px 8px 0 var(--shadow);
	padding: 1rem;
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 0.75rem;
	transform: rotate(-1.5deg);
}

.tile {
	aspect-ratio: 1;
	border-radius: var(--r-md);
	background: var(--panel-2);
	border: 1px solid var(--line-soft);
	display: grid;
	place-items: center;
	font-size: clamp(1.5rem, 4vw, 2.1rem);
	line-height: 1;
	will-change: transform;
}

.tile.b {
	background: color-mix(in srgb, var(--blue) 14%, var(--panel));
}

.tile.p {
	background: color-mix(in srgb, var(--pink) 16%, var(--panel));
}

.tile.m {
	background: color-mix(in srgb, var(--marigold) 22%, var(--panel));
}

/* ---------------------------------------------------------------- steps */

.steps {
	list-style: none;
	counter-reset: step;
	padding: 0;
	margin: 2.5rem 0 0;
	max-width: 44rem;
}

.steps li {
	counter-increment: step;
	position: relative;
	padding: 0 0 2rem 3.5rem;
}

.steps li::before {
	content: counter(step);
	position: absolute;
	left: 0;
	top: 0;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--blue);
	color: #fff;
	font-family: var(--mono);
	font-size: 0.85rem;
	font-weight: 600;
	display: grid;
	place-items: center;
}

/* The rail, from the app's vertical stepper. */
.steps li::after {
	content: "";
	position: absolute;
	left: 16px;
	top: 40px;
	bottom: 6px;
	width: 2px;
	background: var(--line-soft);
}

.steps li:last-child {
	padding-bottom: 0;
}

.steps li:last-child::after {
	display: none;
}

.steps h3 {
	margin-bottom: 0.35rem;
}

.steps p {
	color: var(--muted);
	margin: 0;
}

/* ------------------------------------------------------------- pricing */

.price-row {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
	gap: 1.25rem;
	margin-top: 2.5rem;
	align-items: start;
}

.price {
	font-family: var(--display);
	font-size: 2.6rem;
	font-weight: 800;
	letter-spacing: -0.04em;
	line-height: 1;
	display: block;
	margin: 0.5rem 0 0.25rem;
}

.price small {
	font-family: var(--body);
	font-size: 0.85rem;
	font-weight: 400;
	letter-spacing: 0;
	color: var(--muted);
	display: block;
	margin-top: 0.4rem;
}

.ticks {
	list-style: none;
	padding: 0;
	margin: 1rem 0 0;
}

.ticks li {
	position: relative;
	padding-left: 1.5rem;
	margin-bottom: 0.5rem;
	color: var(--muted);
}

.ticks li::before {
	content: "→";
	position: absolute;
	left: 0;
	color: var(--blue);
	font-family: var(--mono);
}

/* --------------------------------------------------------------- tables */

table {
	border-collapse: collapse;
	width: 100%;
	margin: 1.25rem 0;
	font-size: 0.97rem;
}

th,
td {
	text-align: left;
	padding: 0.65rem 0.9rem 0.65rem 0;
	border-bottom: 1px solid var(--line-soft);
	vertical-align: top;
}

th {
	font-weight: 650;
	white-space: nowrap;
	padding-right: 1.5rem;
}

/* ----------------------------------------------------------- legal pages */

.legal {
	padding: clamp(2.5rem, 6vw, 4rem) 0 5rem;
}

.legal h1 {
	font-size: clamp(2rem, 5vw, 3rem);
}

.legal h2 {
	font-size: 1.3rem;
	margin: 2.5rem 0 0.6rem;
}

.legal ul,
.legal ol {
	color: var(--muted);
	padding-left: 1.2rem;
}

.legal li {
	margin-bottom: 0.5rem;
}

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

.legal .updated {
	font-family: var(--mono);
	font-size: 0.78rem;
	color: var(--muted);
	letter-spacing: 0.05em;
	margin-bottom: 2.5rem;
}

.callout {
	background: color-mix(in srgb, var(--marigold) 18%, var(--panel));
	border: var(--edge);
	border-radius: var(--r-lg);
	padding: 1.25rem 1.4rem;
	margin: 1.5rem 0 2rem;
}

.callout p {
	color: var(--fg);
	margin: 0;
}

/* --------------------------------------------------------------- footer */

footer.site {
	border-top: var(--edge);
	background: var(--panel);
	padding: 3rem 0 3.5rem;
	font-size: 0.93rem;
	color: var(--muted);
}

footer.site nav {
	display: flex;
	flex-wrap: wrap;
	gap: 0.6rem 1.5rem;
	margin-bottom: 1.5rem;
	font-weight: 550;
}

footer.site nav a {
	text-decoration: none;
}

footer.site nav a:hover {
	text-decoration: underline;
}

footer.site p {
	max-width: 44rem;
}

/* ------------------------------------------------------------- animation */

/* Hidden only when GSAP is actually going to run them. No JS, no class, no
 * invisible page -- which is also what a crawler and Paddle's verifier see. */
html.js [data-anim] {
	opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
	html.js [data-anim] {
		opacity: 1;
	}
}
