/* ==========================================================================
   VoxelQuant landing page (voxelquant.io). Same design system as voxelflow.io
   (../voxelflow-website: base.css + demo1.css), with Inter self-hosted so the
   page makes no third-party requests.
   ========================================================================== */

@font-face {
	font-family: 'Inter';
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url(/fonts/inter-latin.woff2) format('woff2');
}

/* ==========================================================================
   design system + layout (from voxelflow.io)
   Shares the visual language of the VoxelFlow app's pre-auth screens:
   brand-dark surface, aurora backdrop, isometric-cube mark, Inter, and the
   cyan → violet → magenta brand gradient.
   ========================================================================== */

/* --- minimal normalize ---------------------------------------------------- */
*,
*::after,
*::before {
	box-sizing: border-box;
}
main,
header,
footer,
nav,
section {
	display: block;
}
body {
	margin: 0;
}

:root {
	font-size: 16px;

	--radius: 0.625rem;
	--radius-md: calc(var(--radius) - 2px);
	--radius-lg: var(--radius);
	--radius-full: 999px;

	/* Semantic tokens mirror the app's .dark palette (globals.css). */
	--background: oklch(0.145 0.012 252);
	--foreground: oklch(0.93 0.008 255);
	--muted-foreground: oklch(0.66 0.015 257);
	--primary: oklch(0.8 0.13 205);
	--primary-foreground: oklch(0.16 0.04 215);
	--border: oklch(0.3 0.02 264);
	--info: oklch(0.72 0.13 230);
	--chart-5: oklch(0.7 0.2 330);
	--ring: oklch(0.8 0.13 205);

	--panel: color-mix(in oklab, var(--background) 55%, transparent);
}

body {
	color: var(--foreground);
	background-color: var(--background);
	font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
	font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	line-height: 1.5;
}

a {
	color: var(--primary);
	text-decoration: none;
	outline: none;
}
a:hover,
a:focus-visible {
	color: color-mix(in oklab, var(--primary) 80%, white);
}

/* --- page shell ----------------------------------------------------------- */
/* The overlay never eats pointer events meant for the interactive particle
   hand underneath; only genuinely interactive children opt back in. */
.page {
	position: relative;
	z-index: 4;
	min-height: 100vh;
	min-height: 100svh;
	display: grid;
	grid-template-rows: auto 1fr auto;
	padding: clamp(1.25rem, 3.5vw, 2.75rem);
	pointer-events: none;
}
/* The overlay stays click-through so the particle hand underneath keeps its
   hover ripple in the open areas; the content blocks opt back in so their text
   is selectable and their links/buttons are clickable. */
.site-header,
.hero,
.site-footer {
	pointer-events: auto;
}

/* --- header --------------------------------------------------------------- */
.site-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}
.brand {
	display: inline-flex;
	align-items: center;
	gap: 0.6rem;
	color: var(--foreground);
}
.brand:hover {
	color: var(--foreground);
}
.brand__mark {
	width: 2.1rem;
	height: 2.1rem;
	display: block;
	filter: drop-shadow(0 2px 10px color-mix(in oklab, var(--primary) 35%, transparent));
}
.brand__name {
	font-size: 1.2rem;
	font-weight: 600;
	letter-spacing: -0.02em;
}

.site-nav {
	display: flex;
	align-items: center;
	gap: 1.25rem;
}
.nav-link {
	color: var(--muted-foreground);
	font-size: 0.9rem;
	font-weight: 500;
}
.nav-link:hover {
	color: var(--foreground);
}

/* --- hero ----------------------------------------------------------------- */
.hero {
	align-self: center;
	max-width: 46rem;
	padding: clamp(1.5rem, 5vh, 4rem) 0;
	/* Soft dark halo keeps copy readable where it crosses bright hand particles. */
	text-shadow: 0 1px 22px color-mix(in oklab, var(--background) 78%, transparent);
}
.eyebrow {
	margin: 0 0 1.1rem;
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: color-mix(in oklab, var(--primary) 78%, var(--foreground));
}
.hero__title {
	margin: 0 0 1.4rem;
	font-size: clamp(2.5rem, 6vw, 4.25rem);
	font-weight: 600;
	line-height: 1.03;
	letter-spacing: -0.03em;
	text-wrap: balance;
}
/* Keep "clinical trials" together so it never orphans "trials" on its own line. */
.nowrap {
	white-space: nowrap;
}
.text-gradient-brand {
	background-image: linear-gradient(100deg, oklch(0.8 0.14 200), oklch(0.62 0.22 295) 55%, oklch(0.68 0.22 330));
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}
.hero__lead {
	margin: 0 0 1.1rem;
	max-width: 40rem;
	font-size: clamp(1.02rem, 1.5vw, 1.2rem);
	color: color-mix(in oklab, var(--foreground) 82%, transparent);
}
.hero__lead--sub {
	font-size: clamp(0.95rem, 1.3vw, 1.05rem);
	color: var(--muted-foreground);
}

/* --- feature pills -------------------------------------------------------- */
.pills {
	display: flex;
	flex-wrap: wrap;
	gap: 0.55rem;
	margin: 1.9rem 0 2.4rem;
	padding: 0;
	list-style: none;
}
.pill {
	padding: 0.4rem 0.85rem;
	font-size: 0.82rem;
	font-weight: 500;
	color: color-mix(in oklab, var(--foreground) 88%, transparent);
	background: color-mix(in oklab, var(--background) 45%, transparent);
	border: 1px solid color-mix(in oklab, var(--primary) 30%, var(--border));
	border-radius: var(--radius-full);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}

/* --- buttons -------------------------------------------------------------- */
.hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.85rem;
}
.btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	height: 2.5rem;
	padding: 0 1.15rem;
	border: 1px solid transparent;
	border-radius: var(--radius-md);
	font: inherit;
	font-size: 0.9rem;
	font-weight: 600;
	white-space: nowrap;
	cursor: pointer;
	overflow: hidden;
	transition: transform 0.12s ease, background-color 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.btn:active {
	transform: scale(0.985);
}
.btn:focus-visible {
	outline: none;
	box-shadow: 0 0 0 3px color-mix(in oklab, var(--ring) 50%, transparent);
}
.btn__icon {
	width: 1.05rem;
	height: 1.05rem;
	flex-shrink: 0;
}

.btn--primary {
	background: var(--primary);
	color: var(--primary-foreground);
	box-shadow: 0 6px 20px -8px color-mix(in oklab, var(--primary) 70%, transparent);
}
.btn--primary:hover {
	color: var(--primary-foreground);
	background: color-mix(in oklab, var(--primary) 92%, white);
	box-shadow: 0 10px 28px -8px color-mix(in oklab, var(--primary) 75%, transparent);
}
/* Slow light sweep — the app's ShimmerButton, in CSS. */
.btn--primary::after {
	content: '';
	position: absolute;
	inset: 0;
	background-image: linear-gradient(
		110deg,
		transparent 35%,
		color-mix(in oklab, var(--primary-foreground) 22%, transparent) 50%,
		transparent 65%
	);
	background-size: 200% 100%;
	animation: vf-shimmer 2.6s linear infinite;
	pointer-events: none;
}

.btn--ghost {
	background: color-mix(in oklab, var(--background) 40%, transparent);
	color: var(--foreground);
	border-color: color-mix(in oklab, var(--foreground) 22%, transparent);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}
.btn--ghost:hover {
	color: var(--foreground);
	border-color: color-mix(in oklab, var(--foreground) 42%, transparent);
	background: color-mix(in oklab, var(--foreground) 8%, transparent);
}

.btn--lg {
	height: 3rem;
	padding: 0 1.5rem;
	font-size: 0.98rem;
	border-radius: var(--radius-lg);
}

@keyframes vf-shimmer {
	from {
		background-position: 200% 0;
	}
	to {
		background-position: -200% 0;
	}
}

/* --- footer --------------------------------------------------------------- */
.site-footer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.4rem 1.25rem;
	font-size: 0.8rem;
	color: var(--muted-foreground);
}
.site-footer__copy a {
	color: var(--muted-foreground);
	font-weight: 500;
}
.site-footer__copy a:hover {
	color: var(--foreground);
}
.site-footer__note {
	margin-left: auto;
	text-align: right;
}

/* --- entrance animation --------------------------------------------------- */
.eyebrow,
.hero__title,
.hero__lead,
.pills,
.hero__actions {
	animation: vf-rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.hero__title {
	animation-delay: 0.06s;
}
.hero__lead {
	animation-delay: 0.12s;
}
.hero__lead--sub {
	animation-delay: 0.16s;
}
.pills {
	animation-delay: 0.2s;
}
.hero__actions {
	animation-delay: 0.26s;
}
@keyframes vf-rise {
	from {
		opacity: 0;
		transform: translateY(14px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* --- responsive ----------------------------------------------------------- */
@media screen and (max-width: 48em) {
	.nav-link {
		display: none;
	}
	.hero {
		text-align: left;
		padding-top: 2rem;
	}
	/* The non-medical-device note is regulatory small print, not a headline
	   question a visitor would ask, so it earns its keep only on wide screens. */
	.site-footer__note {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.btn--primary::after {
		animation: none;
		display: none;
	}
	.eyebrow,
	.hero__title,
	.hero__lead,
	.pills,
	.hero__actions {
		animation: none;
	}
}

/* ==========================================================================
   background stack (from voxelflow.io)
   z-order (back → front): aurora (0) · dot grid (1) · particle hand (2) ·
   legibility scrim (3) · page content (4, in base.css)
   ========================================================================== */

body {
	margin: 0;
	min-height: 100vh;
	overflow-x: hidden;
	background-color: var(--background);
}

/* The particle hand draws into .container's <canvas> with a transparent clear,
   so the aurora + grid below show through the gaps between particles. */
.container {
	position: fixed;
	inset: 0;
	z-index: 2;
}
.container canvas {
	display: block;
	width: 100%;
	height: 100%;
}

/* --- aurora --------------------------------------------------------------- */
.bg-aurora {
	position: fixed;
	inset: 0;
	z-index: 0;
	overflow: hidden;
	background: var(--background);
}
.bg-aurora .blob {
	position: absolute;
	border-radius: 50%;
	filter: blur(90px);
	opacity: 0.9;
	will-change: transform;
}
.blob--1 {
	top: -20%;
	left: -10%;
	width: 55vw;
	height: 55vw;
	background: radial-gradient(circle at center, color-mix(in oklab, var(--primary) 22%, transparent), transparent 70%);
	animation: blob-1 26s ease-in-out infinite alternate;
}
.blob--2 {
	top: 6%;
	right: -15%;
	width: 50vw;
	height: 50vw;
	background: radial-gradient(circle at center, color-mix(in oklab, var(--info) 22%, transparent), transparent 70%);
	animation: blob-2 32s ease-in-out infinite alternate;
}
.blob--3 {
	bottom: -25%;
	left: 18%;
	width: 60vw;
	height: 45vw;
	background: radial-gradient(circle at center, color-mix(in oklab, var(--chart-5) 14%, transparent), transparent 70%);
	animation: blob-3 38s ease-in-out infinite alternate;
}
@keyframes blob-1 {
	from {
		transform: translate(0, 0) scale(1);
	}
	to {
		transform: translate(80px, 70px) scale(1.12);
	}
}
@keyframes blob-2 {
	from {
		transform: translate(0, 0) scale(1);
	}
	to {
		transform: translate(-90px, 50px) scale(0.92);
	}
}
@keyframes blob-3 {
	from {
		transform: translate(0, 0) scale(1);
	}
	to {
		transform: translate(60px, -50px) scale(1.1);
	}
}

/* --- faint dot grid ------------------------------------------------------- */
.bg-grid {
	position: fixed;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	background-image: radial-gradient(
		color-mix(in oklab, var(--foreground) 8%, transparent) 1px,
		transparent 1px
	);
	background-size: 22px 22px;
	opacity: 0.5;
	-webkit-mask-image: radial-gradient(ellipse 120% 100% at 50% 40%, #000 55%, transparent 100%);
	mask-image: radial-gradient(ellipse 120% 100% at 50% 40%, #000 55%, transparent 100%);
}

/* --- legibility scrim ----------------------------------------------------- */
/* Darkens the left of the viewport so the hero copy reads over the particle
   hand; fades out toward the right where the hand should stay crisp. */
.scrim {
	position: fixed;
	inset: 0;
	z-index: 3;
	pointer-events: none;
	background: linear-gradient(
		100deg,
		color-mix(in oklab, var(--background) 92%, transparent) 0%,
		color-mix(in oklab, var(--background) 78%, transparent) 38%,
		color-mix(in oklab, var(--background) 34%, transparent) 60%,
		transparent 82%
	);
}

@media screen and (max-width: 48em) {
	/* On narrow screens the hand sits behind the copy, so wash the whole
	   viewport top-down instead of left-right. */
	.scrim {
		background: linear-gradient(
			180deg,
			color-mix(in oklab, var(--background) 70%, transparent) 0%,
			color-mix(in oklab, var(--background) 82%, transparent) 45%,
			color-mix(in oklab, var(--background) 92%, transparent) 100%
		);
	}
}

@media (prefers-reduced-motion: reduce) {
	.bg-aurora .blob {
		animation: none;
	}
}
