/* ai.ushost.org — shared foundation (tokens, fonts, reset, nav, buttons, footer). See DESIGN.md. */
@font-face { font-family: "Geist"; src: url("/assets/fonts/geist-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("/assets/fonts/geist-mono-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
/* Metric-matched fallbacks: the page doesn't move when the web fonts arrive. */
@font-face { font-family: "Geist Fallback"; src: local("Arial"), local("Helvetica"), local("Liberation Sans"); size-adjust: 101.76%; ascent-override: 98.77%; descent-override: 28.99%; line-gap-override: 0%; }
@font-face { font-family: "Geist Mono Fallback"; src: local("Courier New"), local("Liberation Mono"); size-adjust: 99.98%; ascent-override: 100.52%; descent-override: 29.5%; line-gap-override: 0%; }

:root {
	color-scheme: dark;
	--bg: #08090b;
	--bg-1: #0e1014;
	--bg-2: #14171c;
	--bg-3: #1b1f26;
	--line: rgba(255, 255, 255, 0.08);
	--line-strong: rgba(255, 255, 255, 0.14);
	--fg: #f4f5f7;
	--fg-2: #a3a8b3;
	--fg-3: #7d8391;
	/* Glacier: ice to cyan. --glow-k scales every coloured glow, --tint-k every accent tint (the customizer sets them). */
	--c1: 139, 216, 255; --c2: 42, 155, 224; --glow-k: 0.4; --tint-k: 1;
	--accent: rgb(var(--c1));
	--accent-2: rgb(var(--c2));
	--accent-grad: linear-gradient(135deg, var(--accent), var(--accent-2));
	--glow: 0 0 80px -20px rgba(var(--c1), calc(0.45 * var(--glow-k)));
	--hairline: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02));

	--font-sans: "Geist", "Geist Fallback", system-ui, sans-serif;
	--font-mono: "Geist Mono", "Geist Mono Fallback", ui-monospace, monospace;
	--h1: clamp(44px, 6.5vw, 76px);
	--h2: clamp(30px, 4vw, 48px);
	--lede: clamp(17px, 1.6vw, 20px);

	--s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 20px; --s-6: 24px;
	--s-7: 32px; --s-8: 40px; --s-9: 48px; --s-10: 64px; --s-11: 80px; --s-12: 96px;
	--space-section: clamp(96px, 12vw, 160px);
	--gutter: clamp(20px, 4vw, 40px);
	--radius-sm: 8px; --radius-md: 12px; --radius: 16px; --radius-lg: 20px;

	--ease-out: cubic-bezier(0.23, 1, 0.32, 1);
	--ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
	--z-bg: 0; --z-content: 1; --z-nav: 50; --z-skip: 100;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--bg); scroll-padding-top: 96px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
@media (pointer: fine) { html { overscroll-behavior: none; } }
body {
	min-height: 100vh; background: var(--bg); color: var(--fg-2);
	font-family: var(--font-sans); font-size: 16px; line-height: 1.6; font-feature-settings: "ss01", "cv11";
	-webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
	overflow-x: clip; -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
h1, h2, h3 { color: var(--fg); font-weight: 560; text-wrap: balance; }
p { text-wrap: pretty; }
::selection { background: rgba(var(--c1), calc(0.28 * var(--tint-k))); color: var(--fg); }

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

.wrap { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right)); }
.mono { font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-3); }
.muted { color: var(--fg-3); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.skip { position: fixed; left: var(--s-4); top: var(--s-4); z-index: var(--z-skip); padding: var(--s-2) var(--s-4); border-radius: var(--radius-sm); background: var(--fg); color: var(--bg); font-weight: 560; transform: translateY(-200%); }
.skip:focus-visible { transform: none; }

/* ── Floating glass pill nav ─────────────────────────── */
.nav-shell { position: sticky; top: calc(12px + env(safe-area-inset-top)); z-index: var(--z-nav); padding-inline: var(--s-3); }
.nav {
	display: flex; align-items: center; justify-content: space-between; gap: var(--s-4);
	max-width: 1136px; height: 56px; margin: 12px auto 0; padding: 0 var(--s-2) 0 var(--s-4);
	border-radius: var(--radius); border: 1px solid var(--line);
	background: linear-gradient(137deg, rgba(17, 18, 22, 0.72) 5%, rgba(10, 11, 14, 0.88) 76%);
	-webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 12px 32px -12px rgba(0, 0, 0, 0.6);
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--fg); font-size: 17px; font-weight: 600; letter-spacing: -0.02em; border-radius: 8px; }
.brand svg { width: 24px; height: 20px; flex: none; }
.brand .mark-path { stroke: url(#mark-grad); }
.nav-links { display: flex; align-items: center; gap: var(--s-1); font-size: 14px; }
.nav-links a:not(.btn) { padding: var(--s-2) var(--s-3); border-radius: var(--radius-sm); color: var(--fg-2); transition: color 200ms ease, background-color 200ms ease; }
@media (hover: hover) and (pointer: fine) { .nav-links a:not(.btn):hover { color: var(--fg); background: rgba(255, 255, 255, 0.04); } }
@media (max-width: 767px) { .nav-links .nav-opt { display: none; } }

/* ── Buttons ─────────────────────────────────────────── */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2);
	height: 44px; padding: 0 var(--s-5); border-radius: var(--radius-md);
	font-size: 15px; font-weight: 560; letter-spacing: -0.01em; white-space: nowrap;
	transition: transform 120ms var(--ease-out), background-color 200ms ease, border-color 200ms ease, box-shadow 200ms ease, color 200ms ease;
}
.btn:active { transform: scale(0.98); }
.btn-sm { height: 40px; padding: 0 var(--s-4); font-size: 14px; }
.btn-primary { background: var(--fg); color: var(--bg); box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.12); }
.btn-ghost { color: var(--fg); border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.02); }
@media (hover: hover) and (pointer: fine) {
	.btn-primary:hover { background: #ffffff; box-shadow: var(--glow), 0 0 0 1px rgba(var(--c1), calc(0.35 * var(--glow-k))); }
	.btn-ghost:hover { background: var(--bg-2); border-color: rgba(255, 255, 255, 0.22); }
}
.btn svg { width: 16px; height: 16px; }

/* ── Footer ──────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--line); padding: var(--s-10) 0 calc(var(--s-9) + env(safe-area-inset-bottom)); font-size: 14px; }
.foot { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--s-8); }
.foot .tagline { margin-top: var(--s-3); max-width: 28ch; color: var(--fg-3); }
.foot h2 { font-size: 12px; font-family: var(--font-mono); font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-3); margin-bottom: var(--s-3); }
.foot ul { list-style: none; display: grid; gap: var(--s-2); }
.foot a { color: var(--fg-2); border-radius: 6px; transition: color 200ms ease; }
@media (hover: hover) and (pointer: fine) { .foot a:hover { color: var(--fg); } }
.foot-base { margin-top: var(--s-10); padding-top: var(--s-6); border-top: 1px solid var(--line); color: var(--fg-3); font-size: 13px; }
@media (max-width: 767px) { .foot { grid-template-columns: 1fr 1fr; } .foot > :first-child { grid-column: 1 / -1; } }

/* The SVG gradients (the mark, the line icons) follow the accent tokens, so a palette change reaches them too. */
.s1 { stop-color: rgb(var(--c1)); }
.s2 { stop-color: rgb(var(--c2)); }
