/* ai.ushost.org marketing page. Tokens and shared pieces: base.css. Rules: DESIGN.md. */

/* ── Hero ─────────────────────────────────────────────── */
.hero { position: relative; padding-top: clamp(64px, 9vw, 120px); isolation: isolate; overflow-x: clip; }
.hero-copy { position: relative; z-index: var(--z-content); }
.hero h1 { margin-top: var(--s-6); font-size: var(--h1); line-height: 1.02; letter-spacing: -0.04em; font-weight: 560; max-width: 15ch; }
.lede { margin-top: var(--s-5); max-width: 52ch; font-size: var(--lede); line-height: 1.5; letter-spacing: -0.005em; color: var(--fg-2); }
.cta { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-7); }

/* The hero's background pattern, drawn in the accent through a mask so any colour and any of the
   patterns in assets/pat/ can be chosen (--pat, --pat-size; the customizer switches them).
   A fine grid by default, faint, fading out toward every edge; the tiled logo was too much. */
.lattice {
	position: absolute; inset: -80px 0 auto; height: 900px; z-index: var(--z-bg); pointer-events: none; opacity: var(--lat-o, 0.055);
	background: rgb(var(--lat, var(--c1)));
	-webkit-mask-image: X, var(--pat);
	mask-image: X, var(--pat);
	-webkit-mask-size: 100% 100%, var(--pat-size); mask-size: 100% 100%, var(--pat-size);
	-webkit-mask-repeat: no-repeat, repeat; mask-repeat: no-repeat, repeat;
	-webkit-mask-composite: source-in; mask-composite: intersect;
}
:root { --pat: url("/assets/pat/grid.svg"); --pat-size: 32px 32px; }
:root[data-pat="lattice"] { --pat: url("/assets/pat/lattice.svg"); --pat-size: 124px 104px; }
:root[data-pat="frost"] { --pat: url("/assets/pat/frost.svg"); --pat-size: 31.18px 54px; }
:root[data-pat="contour"] { --pat: url("/assets/pat/contour.svg"); --pat-size: 420px 420px; }
:root[data-pat="crystals"] { --pat: url("/assets/pat/crystals.svg"); --pat-size: 260px 260px; }
:root[data-pat="dots"] { --pat: url("/assets/pat/dots.svg"); --pat-size: 20px 20px; }
:root[data-pat="none"] .lattice { display: none; }

/* ── Product window on a lit floor ───────────────────── */
.stage { position: relative; margin: clamp(56px, 7vw, 88px) auto 0; max-width: 1200px; padding-inline: var(--gutter); }
.floor { position: absolute; left: 50%; top: -160px; width: min(140%, 1700px); height: 420px; transform: translateX(-50%); z-index: -1; pointer-events: none;
	background:
		radial-gradient(closest-side, rgba(var(--c1), calc(0.17 * var(--tint-k))), transparent),
		radial-gradient(closest-side at 64% 50%, rgba(var(--c2), calc(0.10 * var(--tint-k))), transparent);
}
.floor::before { content: ""; position: absolute; left: 22%; right: 22%; top: 160px; height: 1px; background: linear-gradient(90deg, transparent, rgba(var(--c1), calc(0.6 * var(--tint-k))), rgba(var(--c2), calc(0.6 * var(--tint-k))), transparent); }
.window {
	position: relative; border-radius: var(--radius-lg); padding: 1px; background: var(--hairline);
	box-shadow: 0 40px 120px -40px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(0, 0, 0, 0.4);
	-webkit-mask-image: linear-gradient(#000 78%, transparent 100%);
	mask-image: linear-gradient(#000 78%, transparent 100%);
}
.w-frame { display: grid; grid-template-columns: 232px 1fr; height: clamp(500px, 44vw, 600px); border-radius: calc(var(--radius-lg) - 1px); overflow: hidden; background: #0b0c0f; font-size: 13.5px; color: var(--fg-2); }
.w-side { display: flex; flex-direction: column; gap: var(--s-1); padding: var(--s-4) var(--s-3); border-right: 1px solid var(--line); background: #0a0b0e; }
.w-brand { display: flex; align-items: center; gap: var(--s-2); padding: 0 var(--s-2) var(--s-3); color: var(--fg); font-weight: 600; letter-spacing: -0.01em; }
.w-brand svg { width: 18px; height: 15px; }
.w-nav, .w-chats { list-style: none; display: grid; gap: 2px; }
.w-nav li, .w-chats li { display: flex; align-items: center; gap: var(--s-2); padding: 7px var(--s-2); border-radius: var(--radius-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.w-chats li { display: block; color: var(--fg-3); }
.w-chats li.on { background: var(--bg-2); color: var(--fg); }
.w-label { margin: var(--s-4) var(--s-2) var(--s-1); font-size: 11.5px; color: var(--fg-3); }
.w-user { margin-top: auto; display: flex; align-items: center; gap: var(--s-2); padding: var(--s-2); border-top: 1px solid var(--line); padding-top: var(--s-3); }
.av { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: var(--accent-grad); color: #0b0c0f; font-size: 10px; font-weight: 700; }
.ico { width: 14px; height: 14px; flex: none; border-radius: 3px; background: currentColor; opacity: 0.55; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.i-plus { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E"); }
.i-folder { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpath d='M3 7a2 2 0 0 1 2-2h4l2 2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3C/svg%3E"); }
.i-lib { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M5 4v16M10 4v16M15 5l4 15'/%3E%3C/svg%3E"); }
.i-img { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Crect x='3' y='3' width='18' height='18' rx='3'/%3E%3Ccircle cx='9' cy='9' r='2'/%3E%3Cpath d='m21 15-5-5L5 21'/%3E%3C/svg%3E"); }
.i-mic { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Crect x='9' y='3' width='6' height='11' rx='3'/%3E%3Cpath d='M5 11a7 7 0 0 0 14 0M12 18v3'/%3E%3C/svg%3E"); }

.w-main { display: grid; grid-template-rows: auto 1fr auto; min-width: 0; }
.w-top { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); padding: var(--s-3) var(--s-6); border-bottom: 1px solid var(--line); color: var(--fg); font-weight: 500; }
.w-model { font-size: 12px; color: var(--fg-3); padding: 3px 8px; border: 1px solid var(--line); border-radius: 6px; }
.w-thread { padding: var(--s-6) clamp(16px, 4vw, 56px); overflow: hidden; display: grid; align-content: start; gap: var(--s-5); }
.w-user-msg { justify-self: end; max-width: 78%; padding: 10px 14px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); color: var(--fg); }
.w-reply { display: grid; gap: var(--s-3); max-width: 640px; }
.w-steps { display: flex; align-items: center; gap: var(--s-2); font-size: 12.5px; color: var(--fg-3); }
.w-steps .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.w-text { display: grid; gap: var(--s-2); font-size: 14.5px; line-height: 1.65; color: #d6d9df; }
.w-text strong { color: var(--fg); font-weight: 600; }
.w-text sup { color: var(--accent); font-size: 10px; margin-left: 1px; }
.w-after { display: flex; align-items: flex-start; gap: var(--s-4); flex-wrap: wrap; }
.w-sources { display: flex; flex-wrap: wrap; gap: 6px; max-width: 300px; }
.w-sources span { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 9px; border-radius: 7px; background: var(--bg-2); border: 1px solid var(--line); font-size: 12px; color: var(--fg-2); }
.w-sources span::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--accent-grad); opacity: 0.8; }
.w-image { position: relative; width: 280px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.w-image img { width: 100%; height: auto; }
.w-image span { position: absolute; left: 8px; bottom: 8px; padding: 3px 8px; border-radius: 6px; font-size: 11.5px; color: var(--fg); background: rgba(8, 9, 11, 0.7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.w-composer { display: flex; align-items: center; gap: var(--s-3); margin: 0 clamp(16px, 4vw, 56px) var(--s-5); padding: 12px 12px 12px 16px; border-radius: 16px; border: 1px solid var(--line-strong); background: var(--bg-1); box-shadow: 0 0 0 4px rgba(var(--c1), calc(0.04 * var(--glow-k))); }
.w-ph { flex: 1; color: var(--fg-3); }
.w-send { width: 28px; height: 28px; border-radius: 9px; background: var(--fg); -webkit-mask: none; position: relative; }
.w-send::after { content: ""; position: absolute; inset: 7px; background: var(--bg); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 19V5M5 12l7-7 7 7'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 19V5M5 12l7-7 7 7'/%3E%3C/svg%3E") center / contain no-repeat; }

/* Typed reply (site.js): words appear one by one; sources and the picture follow. */
.w-text .w { opacity: 0; }
.w-text .w.on { opacity: 1; transition: opacity 160ms var(--ease-out); }
.w-reply.typing .w-after { opacity: 0; transform: translateY(6px); }
.w-reply .w-after { transition: opacity 500ms var(--ease-out), transform 500ms var(--ease-out); }

@media (max-width: 1023px) {
	.w-frame { grid-template-columns: 1fr; height: 560px; }
	.w-side { display: none; }
}
@media (max-width: 767px) {
	.w-frame { font-size: 13px; }
	.w-top { padding-inline: var(--s-4); }
	.w-thread { padding: var(--s-4); gap: var(--s-4); }
	.w-user-msg { max-width: 92%; }
	.w-image { width: 100%; max-width: 280px; }
	.w-composer { margin: 0 var(--s-3) var(--s-3); }
	.window { -webkit-mask-image: linear-gradient(#000 70%, transparent 100%); mask-image: linear-gradient(#000 70%, transparent 100%); }
}

/* ── Trust strip ──────────────────────────────────────── */
.trust { padding: var(--s-9) 0 0; }
.trust-row { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: var(--radius-lg); background: rgba(14, 16, 20, 0.6); }
.trust-row li { display: grid; gap: var(--s-2); padding: var(--s-6); }
.trust-row li + li { border-left: 1px solid var(--line); }
.stat { font-family: var(--font-mono); font-size: clamp(22px, 2.2vw, 28px); font-weight: 500; letter-spacing: -0.03em; color: var(--fg); font-variant-numeric: tabular-nums; }
.trust-row .mono { line-height: 1.5; }
@media (max-width: 899px) { .trust-row { grid-template-columns: 1fr 1fr; } .trust-row li:nth-child(3) { border-left: 0; } .trust-row li:nth-child(n+3) { border-top: 1px solid var(--line); } }

/* ── Sections ─────────────────────────────────────────── */
.section { padding-top: var(--space-section); }
.section-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--s-6) var(--s-10); align-items: end; margin-bottom: var(--s-10); }
.section-head h2 { font-size: var(--h2); line-height: 1.08; letter-spacing: -0.03em; font-weight: 540; }
.section-head p { max-width: 46ch; font-size: 16px; color: var(--fg-2); }
@media (max-width: 899px) { .section-head { grid-template-columns: 1fr; margin-bottom: var(--s-8); } }

/* ── Bento ────────────────────────────────────────────── */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--s-4); }
.t-research { grid-column: span 4; } .t-memory { grid-column: span 2; }
.t-docs { grid-column: span 2; } .t-media { grid-column: span 4; }
.t-apps, .t-3d, .t-day { grid-column: span 2; } .t-connect { grid-column: span 6; }
@media (min-width: 900px) { .t-connect .tile-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); column-gap: var(--s-8); align-items: center; } .t-connect .tile-ui { grid-row: 1 / 3; grid-column: 2; } .t-connect h3 { margin-top: 0; padding-top: 0; } }
/* Each tile is as tall as its own content: nothing stretches to a taller neighbour. */
.bento { align-items: start; }
@media (max-width: 899px) { .bento { grid-template-columns: 1fr 1fr; } .bento > * { grid-column: span 2 !important; } }
@media (min-width: 600px) and (max-width: 899px) { .t-memory, .t-docs { grid-column: span 1 !important; } }

.tile { position: relative; border-radius: var(--radius-lg); padding: 1px; background: var(--hairline); transition: transform 200ms var(--ease-out), box-shadow 200ms ease; }
.tile-in { position: relative; height: 100%; display: flex; flex-direction: column; padding: var(--s-6); border-radius: calc(var(--radius-lg) - 1px); background: var(--bg-1); overflow: hidden; }
.tile-in::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 200ms ease;
	background: radial-gradient(420px circle at var(--x, 50%) var(--y, 0%), rgba(var(--c1), calc(0.09 * var(--tint-k))), transparent 45%); }
.tile h3 { margin-top: auto; padding-top: var(--s-6); font-size: 17px; line-height: 1.3; letter-spacing: -0.01em; }
.tile-in > p { margin-top: var(--s-2); font-size: 15px; line-height: 1.55; max-width: 48ch; }
@media (hover: hover) and (pointer: fine) {
	.tile:hover, .js .tile.reveal.in:hover { transform: translateY(-2px); background: linear-gradient(180deg, rgba(var(--c1), calc(0.35 * var(--tint-k))), rgba(var(--c2), calc(0.08 * var(--tint-k))) 60%, rgba(255, 255, 255, 0.03)); box-shadow: 0 24px 60px -30px rgba(var(--c1), calc(0.35 * var(--glow-k))); }
	.tile:hover .tile-in::before { opacity: 1; }
}

.tile-ui { position: relative; font-size: 13px; }
/* research */
.ui-research { display: grid; gap: var(--s-3); padding: var(--s-4); border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.ui-research .q { color: var(--fg); font-weight: 500; }
.ui-research .a { color: #c9ccd3; line-height: 1.6; }
.ui-research b { color: var(--fg); font-weight: 600; }
.ui-research sup { color: var(--accent); font-size: 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips span { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 9px 0 4px; border-radius: 7px; background: var(--bg-1); border: 1px solid var(--line); font-size: 12px; color: var(--fg-2); }
.chips i { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; font-style: normal; font-size: 10px; font-family: var(--font-mono); color: var(--accent); background: rgba(var(--c1), calc(0.1 * var(--tint-k))); }
/* memory */
.ui-memory { display: grid; gap: var(--s-2); justify-items: start; }
.mem { display: inline-flex; align-items: center; gap: var(--s-2); padding: 7px 11px; border-radius: 9px; background: var(--bg-2); border: 1px solid var(--line); color: var(--fg); font-size: 12.5px; }
.mem i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-grad); }
.mem.dim { color: var(--fg-3); text-decoration: line-through; text-decoration-color: rgba(255, 255, 255, 0.25); }
.mem.dim i { background: var(--fg-3); }
/* docs */
.ui-docs { display: grid; gap: var(--s-3); }
.pdf { display: flex; align-items: center; gap: var(--s-3); padding: 10px 12px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); }
.pdf-ico { display: grid; place-items: center; width: 32px; height: 38px; border-radius: 6px; font-family: var(--font-mono); font-size: 9px; font-weight: 600; letter-spacing: 0.06em; color: var(--accent); background: rgba(var(--c1), calc(0.1 * var(--tint-k))); border: 1px solid rgba(var(--c1), calc(0.25 * var(--tint-k))); }
.pdf b { display: block; color: var(--fg); font-weight: 500; }
.pdf em { font-style: normal; font-size: 12px; color: var(--fg-3); }
.ui-docs ul { list-style: none; display: grid; gap: 6px; padding-left: var(--s-1); }
.ui-docs li { position: relative; padding-left: 14px; color: #c9ccd3; }
.ui-docs li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
/* media */
.ui-media { display: grid; grid-template-columns: 1fr; gap: var(--s-4); align-items: end; }
.shots { display: grid; grid-template-columns: repeat(3, minmax(0, 120px)); gap: var(--s-2); }
.shots img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.track { display: grid; grid-template-columns: auto 1fr; gap: var(--s-2) var(--s-3); align-items: center; padding: var(--s-3); border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); }
.track .mono { grid-column: 1 / -1; }
.play { width: 30px; height: 30px; border-radius: 50%; background: var(--fg); position: relative; }
.play::after { content: ""; position: absolute; left: 11px; top: 9px; border-left: 10px solid var(--bg); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.wave { display: flex; align-items: center; gap: 3px; height: 30px; }
.wave i { flex: 1; min-width: 2px; border-radius: 2px; background: linear-gradient(var(--accent), var(--accent-2)); opacity: 0.85; height: 40%; }
.wave i:nth-child(3n) { height: 75%; } .wave i:nth-child(4n) { height: 55%; } .wave i:nth-child(5n) { height: 95%; } .wave i:nth-child(7n) { height: 30%; } .wave i:nth-child(n+15) { opacity: 0.35; }
@media (max-width: 767px) { .ui-media { grid-template-columns: 1fr; } .shots { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* apps */
.app { border-radius: 14px; border: 1px solid var(--line); background: var(--bg-2); overflow: hidden; }
.app-bar { display: flex; justify-content: space-between; align-items: center; padding: 9px 12px; border-bottom: 1px solid var(--line); color: var(--fg); font-weight: 500; }
.app-bar .mono { color: var(--accent); }
.habits { display: grid; grid-template-columns: 52px repeat(7, 1fr); gap: 6px; align-items: center; padding: 12px; }
.habits span { font-size: 12px; color: var(--fg-3); }
.habits i { aspect-ratio: 1; max-height: 22px; border-radius: 5px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); }
.habits i.on { background: var(--accent-grad); border-color: transparent; opacity: 0.9; }
/* day */
.ui-day { display: grid; gap: var(--s-3); }
.agenda { list-style: none; display: grid; gap: 2px; }
.agenda li { display: grid; grid-template-columns: 52px 1fr; gap: var(--s-2); padding: 7px 10px; border-radius: 9px; background: var(--bg-2); border: 1px solid var(--line); color: var(--fg); }
.agenda time { font-family: var(--font-mono); font-size: 12px; color: var(--fg-3); font-variant-numeric: tabular-nums; }
.ping { display: flex; align-items: center; gap: var(--s-2); font-size: 12.5px; color: var(--fg-2); }
.ping i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(var(--c1), calc(0.15 * var(--glow-k))); }

/* ── Privacy diagram ──────────────────────────────────── */
.diagram { display: grid; gap: var(--s-4); padding: var(--s-7); border-radius: var(--radius-lg); border: 1px solid var(--line); background: radial-gradient(80% 120% at 50% 100%, rgba(var(--c1), calc(0.06 * var(--tint-k))), transparent 60%), var(--bg-1); }
.lane { display: grid; grid-template-columns: 104px 72px minmax(40px, 1fr) 196px minmax(40px, 1fr) 236px; align-items: center; gap: var(--s-3); }
.lane-name { color: var(--fg-3); }
.lane-manifold .lane-name { color: var(--accent); }
.node { display: inline-flex; align-items: center; gap: var(--s-2); height: 40px; padding: 0 var(--s-4); border-radius: 12px; border: 1px solid var(--line-strong); background: var(--bg-2); color: var(--fg); font-weight: 500; white-space: nowrap; }
.node-far { color: var(--fg-2); }
.node-home { border-color: rgba(var(--c1), calc(0.45 * var(--tint-k))); box-shadow: 0 0 40px -12px rgba(var(--c1), calc(0.6 * var(--glow-k))); }
.node-home svg { width: 18px; height: 15px; }
.wire { height: 4px; }
.wire svg { width: 100%; height: 4px; overflow: visible; }
.wire line { stroke: rgba(255, 255, 255, 0.22); stroke-width: 1.5; stroke-dasharray: 1.2 1.6; }
/* A flat line has a zero-height box, so a box-relative gradient paints nothing: the line uses its own, in its viewBox units. */
.wire-live line { stroke: url(#wire-line); stroke-width: 2.5; stroke-dasharray: none; }
.wire-stop line { stroke: rgba(255, 255, 255, 0.08); stroke-dasharray: 0.6 2.4; }
.fate { display: flex; flex-wrap: wrap; gap: 6px; }
.fate span { padding: 4px 9px; border-radius: 7px; font-size: 12.5px; color: var(--fg-2); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line); }
.fate-none { padding: 6px 12px; border-radius: 9px; font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg); border: 1px solid rgba(var(--c2), calc(0.45 * var(--tint-k))); background: rgba(var(--c2), calc(0.08 * var(--tint-k))); }
@media (max-width: 899px) {
	.diagram { padding: var(--s-5); gap: var(--s-6); }
	.lane { grid-template-columns: 1fr; justify-items: start; gap: var(--s-2); }
	.wire { width: 4px; height: 28px; margin-left: 22px; }
	.wire svg { display: none; }
	.wire::before { content: ""; display: block; width: 2px; height: 100%; margin-inline: auto; background: repeating-linear-gradient(rgba(255, 255, 255, 0.22) 0 4px, transparent 4px 9px); }
	.wire-live::before { width: 3px; border-radius: 2px; background: linear-gradient(var(--accent), var(--accent-2)); transform-origin: top; }
	.wire-stop::before { background: repeating-linear-gradient(rgba(255, 255, 255, 0.08) 0 2px, transparent 2px 8px); }
}

.pillars { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s-7); margin-top: var(--s-10); }
.pillars svg { width: 24px; height: 24px; fill: none; stroke: url(#wire-grad); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pillars h3 { margin-top: var(--s-4); font-size: 16px; letter-spacing: -0.01em; }
.pillars p { margin-top: var(--s-2); font-size: 15px; line-height: 1.55; }
@media (max-width: 899px) { .pillars { grid-template-columns: 1fr 1fr; } }
@media (max-width: 599px) { .pillars { grid-template-columns: 1fr; } }

/* ── How it works ─────────────────────────────────────── */
.how .section-head { margin-bottom: var(--s-8); }
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-4); counter-reset: none; }
.steps li { position: relative; padding: var(--s-6); border-radius: var(--radius-lg); border: 1px solid var(--line); background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent); }
.steps li + li::before { content: ""; position: absolute; left: calc(-1 * var(--s-4)); top: 42px; width: var(--s-4); height: 1px; background: linear-gradient(90deg, rgba(var(--c1), calc(0.6 * var(--tint-k))), rgba(var(--c2), calc(0.6 * var(--tint-k)))); }
.step-n { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; border: 1px solid rgba(var(--c1), calc(0.35 * var(--tint-k))); color: var(--accent); font-size: 13px; }
.steps h3 { margin-top: var(--s-5); font-size: 17px; letter-spacing: -0.01em; }
.steps p { margin-top: var(--s-2); font-size: 15px; }
@media (max-width: 767px) { .steps { grid-template-columns: 1fr; } .steps li + li::before { left: 40px; top: calc(-1 * var(--s-4)); width: 1px; height: var(--s-4); background: linear-gradient(rgba(var(--c1), calc(0.6 * var(--tint-k))), rgba(var(--c2), calc(0.6 * var(--tint-k)))); } }

/* ── Final CTA ────────────────────────────────────────── */
.final { padding-bottom: var(--space-section); }
.cta-panel { position: relative; padding: 1px; border-radius: 24px; background: linear-gradient(135deg, rgba(var(--c1), calc(0.55 * var(--tint-k))), rgba(255, 255, 255, 0.06) 40%, rgba(var(--c2), calc(0.5 * var(--tint-k)))); box-shadow: 0 0 120px -40px rgba(var(--c1), calc(0.45 * var(--glow-k))); }
.cta-in { display: grid; justify-items: center; gap: var(--s-6); padding: clamp(48px, 7vw, 88px) var(--s-6); border-radius: 23px; text-align: center;
	background: radial-gradient(60% 80% at 50% 0%, rgba(var(--c1), calc(0.12 * var(--tint-k))), transparent 70%), var(--bg-1); }
.cta-in h2 { font-size: var(--h2); letter-spacing: -0.03em; line-height: 1.08; }

/* ── Motion (all of it lives here, and only without reduced motion) ── */
@media (prefers-reduced-motion: no-preference) {
	@keyframes rise { from { opacity: 0; transform: translateY(16px); filter: blur(2px); } to { opacity: 1; transform: none; filter: none; } }
	@keyframes rise-big { from { opacity: 0; transform: translateY(40px) scale(0.985); } to { opacity: 1; transform: none; } }
	.stage-1, .stage-2, .stage-3, .stage-4 { animation: rise 650ms var(--ease-out) both; }
	.stage-2 { animation-delay: 70ms; } .stage-3 { animation-delay: 140ms; } .stage-4 { animation-delay: 210ms; }
	.stage-5 { animation: rise-big 800ms var(--ease-out) 300ms both; }

	.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out); transition-delay: calc(var(--i, 0) * 70ms); }
	.js .reveal.in { opacity: 1; transform: none; }
	.js .tile.reveal.in { transition: opacity 600ms var(--ease-out), transform 200ms var(--ease-out), box-shadow 200ms ease; transition-delay: calc(var(--i, 0) * 70ms), 0ms, 0ms; }

	/* The Manifold path draws itself once when the diagram is revealed. */
	.js .wire-live line { stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 800ms var(--ease-in-out) 200ms; }
	.diagram.in .wire-live line { stroke-dashoffset: 0; }
	.node-home { transition: box-shadow 600ms ease 700ms, border-color 600ms ease 700ms; }
	.js .diagram:not(.in) .node-home { box-shadow: none; border-color: var(--line-strong); }

	/* Lattice drifts with the page as you scroll (no autoplay). */
	@supports (animation-timeline: scroll()) {
		@keyframes drift { to { transform: translateY(120px); } }
		.lattice { animation: drift linear both; animation-timeline: scroll(root); animation-range: 0 900px; }
	}
}
@media (prefers-reduced-motion: no-preference) and (max-width: 899px) {
	.js .wire-live::before { transform: scaleY(0); transition: transform 600ms var(--ease-in-out) 200ms; }
	.diagram.in .wire-live::before { transform: none; }
}
/* Round-1 refinements */
.hero::after { content: ""; position: absolute; z-index: var(--z-bg); pointer-events: none; right: -10%; top: 40px; width: 60%; height: 560px;
	background: radial-gradient(closest-side, rgba(var(--c1), calc(0.10 * var(--tint-k))), rgba(var(--c2), calc(0.05 * var(--tint-k))) 55%, transparent); }
.lane .node { justify-self: stretch; justify-content: center; }
.lane .node:first-of-type { justify-self: stretch; }
.lane .fate { justify-content: flex-end; }
.how .section-head h2 { max-width: 15ch; }
@media (max-width: 899px) { .lane .node { justify-self: start; } .lane .fate { justify-content: flex-start; } }
.notfound .hero-copy { padding-bottom: var(--space-section); }

/* Round-2 refinements: product higher, layered depth, a glint of light on the window edge. */
.hero { padding-top: clamp(48px, 7vw, 96px); }
.stage { margin-top: clamp(48px, 5vw, 64px); }
.floor { background:
	radial-gradient(closest-side, rgba(var(--c1), calc(0.22 * var(--tint-k))), transparent),
	radial-gradient(closest-side at 64% 50%, rgba(var(--c2), calc(0.14 * var(--tint-k))), transparent); }
.window::before { content: ""; position: absolute; z-index: 2; left: 8%; right: 30%; top: 0; height: 1px; pointer-events: none;
	background: linear-gradient(90deg, transparent, rgba(var(--c1), calc(0.9 * var(--tint-k))) 35%, rgba(var(--c2), calc(0.7 * var(--tint-k))) 70%, transparent); }
@media (min-width: 1024px) { .w-thread .w-reply { max-width: min(560px, calc(100% - 250px)); } }

/* ── Hero copy, and the tool icons the window's steps use ── */
.hero-top { position: relative; z-index: var(--z-content); }
.hero-copy h1 { margin-top: 0; }
.ti { width: 14px; height: 14px; background: currentColor; opacity: 0.7; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.ti-web { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M3 12h18M12 3a14 14 0 0 1 0 18M12 3a14 14 0 0 0 0 18'/%3E%3C/svg%3E"); }
.ti-read { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Cpath d='M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z'/%3E%3Cpath d='M14 3v6h6M8 13h8M8 17h5'/%3E%3C/svg%3E"); }
.ti-mem { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Ccircle cx='6' cy='7' r='2.5'/%3E%3Ccircle cx='18' cy='6' r='2.5'/%3E%3Ccircle cx='12' cy='17' r='2.5'/%3E%3Cpath d='M8 8l3 7M16 8l-3 7M8.5 7h7'/%3E%3C/svg%3E"); }
.ti-img { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Crect x='3' y='3' width='18' height='18' rx='3'/%3E%3Ccircle cx='9' cy='9' r='2'/%3E%3Cpath d='m21 15-5-5L5 21'/%3E%3C/svg%3E"); }
.ti-pen { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 20h4L19 9l-4-4L4 16z'/%3E%3C/svg%3E"); }
.ts { width: 14px; height: 14px; }
@media (prefers-reduced-motion: no-preference) { @keyframes spin { to { transform: rotate(360deg); } } }

/* ── Tiles that do what they show ─────────────────────── */
.shot { display: block; padding: 0; border-radius: 10px; cursor: zoom-in; transition: transform 200ms var(--ease-out), box-shadow 200ms ease; }
.shot img { pointer-events: none; }
.shot:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) {
	.shot:hover { transform: translateY(-2px); box-shadow: 0 10px 30px -12px rgba(var(--c1), calc(0.5 * var(--glow-k))); }
	.play:hover { box-shadow: 0 0 0 4px rgba(var(--c1), calc(0.2 * var(--glow-k))); }
}
.play { flex: none; cursor: pointer; transition: transform 120ms var(--ease-out), box-shadow 200ms ease; }
.play:active { transform: scale(0.94); }
.track.playing .play::after { left: 10px; top: 9px; width: 10px; height: 12px; border: 0; border-left: 3px solid var(--bg); border-right: 3px solid var(--bg); }
.wave { cursor: pointer; }
.wave i, .wave i:nth-child(n) { height: var(--h, 40%); opacity: 0.35; }
.wave i.played { opacity: 1; }

/* ── Lightbox (native dialog: focus trap, Esc, focus return) ── */
.lightbox { position: fixed; inset: 0; margin: auto; width: min(1120px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 0; background: transparent; color: var(--fg-2); overflow: visible; }
.lightbox::backdrop { background: rgba(4, 5, 7, 0.72); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.lb-inner { display: flex; flex-direction: column; max-height: calc(100dvh - 32px); border-radius: var(--radius-lg); border: 1px solid var(--line-strong); background: linear-gradient(160deg, rgba(22, 25, 31, 0.96), rgba(10, 11, 14, 0.98)); box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.9), 0 0 100px -40px rgba(var(--c1), calc(0.35 * var(--glow-k))); overflow: hidden; }
.lb-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-4); padding: var(--s-5) var(--s-5) var(--s-4); border-bottom: 1px solid var(--line); }
.lb-head h2 { font-size: 18px; letter-spacing: -0.015em; }
.lb-sub { margin-top: 4px; }
.lb-close { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line-strong); color: var(--fg-2); flex: none; }
.lb-close svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
@media (hover: hover) and (pointer: fine) { .lb-close:hover { color: var(--fg); border-color: rgba(255, 255, 255, 0.25); } }
.lb-body { overflow: auto; overscroll-behavior: contain; padding: var(--s-5); }
.lb-vision { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: var(--s-5); align-items: start; }
.lightbox.is-pic .lb-vision:not(:has(.lb-side)) { grid-template-columns: 1fr; }
.lb-stage { position: relative; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: var(--ar, 1); justify-self: center; width: min(100%, calc((100dvh - 180px) * var(--r, 1))); touch-action: manipulation; }
.lb-stage img { width: 100%; height: 100%; object-fit: cover; }
/* Boxes keep 8px clear of the picture's rounded corners and edges; the pointer is matched in code (the smallest box under it), so boxes take no pointer events. */
.lb-box { position: absolute; left: max(8px, var(--x)); top: max(8px, var(--y)); right: max(8px, calc(100% - var(--x2))); bottom: max(8px, calc(100% - var(--y2))); pointer-events: none; border: 1.5px solid rgba(var(--c1), calc(0.85 * var(--tint-k))); border-radius: 6px; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(0, 0, 0, 0.2); transition: opacity 180ms ease, background-color 180ms ease, border-color 180ms ease; }
.lb-tag { position: absolute; left: -1px; top: -1px; transform: translateY(-100%); padding: 2px 7px; border-radius: 6px 6px 6px 0; font-size: 11.5px; font-weight: 500; color: #04131e; background: rgba(var(--c1), calc(0.92 * var(--tint-k))); white-space: nowrap; }
.lb-box.top .lb-tag { transform: none; border-radius: 5px 0 6px 0; }
.lb-box.end .lb-tag { left: auto; right: -1px; border-radius: 6px 6px 0 6px; }
.lb-box.top.end .lb-tag { border-radius: 0 5px 0 6px; }
.focus .lb-box { opacity: 0.25; }
.focus .lb-box.on { opacity: 1; background: rgba(var(--c1), calc(0.14 * var(--tint-k))); border-color: rgb(var(--c1)); }
.lb-side .mono { margin-bottom: var(--s-3); }
.lb-list { list-style: none; display: grid; gap: 4px; }
.lb-list button { width: 100%; text-align: left; padding: 8px 10px; border-radius: 9px; border: 1px solid var(--line); background: var(--bg-2); color: var(--fg); font-size: 13.5px; transition: border-color 150ms ease, background-color 150ms ease; }
.lb-list button.on { border-color: rgba(var(--c1), calc(0.5 * var(--tint-k))); background: rgba(var(--c1), calc(0.1 * var(--tint-k))); }
/* The PDF alone: its page fitted to the screen, no frame, no labels; only a close button beside it. */
.lightbox.is-doc { width: fit-content; max-width: calc(100vw - 32px); }
.is-doc .lb-inner { position: relative; background: none; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
.is-doc .lb-head { position: absolute; top: 10px; right: 10px; z-index: 1; padding: 0; border: 0; }
.is-doc .lb-head > div { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.is-doc .lb-close { background: rgba(8, 9, 11, 0.72); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
@media (min-width: 900px) { .is-doc .lb-head { top: 0; right: -52px; } }
.is-doc .lb-body { padding: 0; overflow: visible; }
.lb-page { display: block; width: auto; height: auto; max-height: calc(100dvh - 32px); max-width: calc(100vw - 32px); border-radius: 4px; box-shadow: 0 30px 90px -20px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.06); }
@media (min-width: 900px) { .lb-page { max-width: calc(100vw - 152px); } }
@media (max-width: 767px) {
	.lb-vision { grid-template-columns: 1fr; }
	.lb-stage { width: 100%; }
}
@media (prefers-reduced-motion: no-preference) {
	.lightbox[open] .lb-inner { animation: lb-in 260ms var(--ease-out); }
	@keyframes lb-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } }
}
.lb-tag { opacity: 0; transition: opacity 150ms ease; }
.lb-box.on .lb-tag { opacity: 1; }
.focus .lb-box.on { z-index: 3000 !important; }

/* ── Tool calls, as the app shows them: each runs, opens to show its work, then folds to one line ── */
.fstep { border-radius: 10px; opacity: 0.32; transition: opacity 300ms var(--ease-out), background-color 300ms ease; }
.fstep.run, .fstep.ok { opacity: 1; }
.fstep.run { background: rgba(255, 255, 255, 0.03); }
.fh { display: grid; grid-template-columns: 18px 1fr 16px; align-items: center; gap: 8px; min-height: 30px; padding: 0 8px; color: var(--fg-2); }
.fstep.run .fh { color: var(--fg); }
.fh .tl { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fh .v-ok { display: none; }
.fstep.ok .v-run { display: none; } .fstep.ok .v-ok { display: inline; }
.fh code { font-family: var(--font-mono); font-size: 11.5px; color: var(--fg-3); margin-left: 4px; }
.fstep .ts { width: 14px; height: 14px; }
.fstep.run .ts { border-radius: 50%; border: 2px solid rgba(var(--c1), calc(0.25 * var(--tint-k))); border-top-color: var(--accent); }
.fstep.ok .ts { background: var(--accent); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat; }
.ti-sheet { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2'%3E%3Crect x='3' y='3' width='18' height='18' rx='2'/%3E%3Cpath d='M3 9h18M3 15h18M9 3v18'/%3E%3C/svg%3E"); }
.ti-code { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m8 9-4 3 4 3M16 9l4 3-4 3M13.5 6l-3 12'/%3E%3C/svg%3E"); }
/* The running step opens to show its work; finished steps fold back to one line. */
.fstep .fd { display: none; margin: 2px 8px 10px 34px; }
.fstep.run .fd { display: block; }
.fnote { margin-top: 6px; font-size: 11.5px; color: var(--fg-3); display: flex; align-items: center; gap: 6px; }
.fd-web span + span { margin-top: 4px; }
.fd-web span { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border-radius: 8px; background: var(--bg-2); border: 1px solid var(--line); font-size: 12px; color: var(--fg-2); }
.fd-web i { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; font-style: normal; font-family: var(--font-mono); font-size: 10px; color: var(--accent); background: rgba(var(--c1), calc(0.1 * var(--tint-k))); }
.fd-img img { width: 100%; max-width: 300px; height: auto; border-radius: 10px; border: 1px solid var(--line); }
@media (prefers-reduced-motion: no-preference) {
	.fstep.run .ts { animation: spin 800ms linear infinite; }
	.fstep.run .fd { animation: fd-in 320ms var(--ease-out); }
	@keyframes fd-in { from { opacity: 0; transform: translateY(-4px); } }
}
html:not(.js) .fstep { opacity: 1; } html:not(.js) .fstep .v-run { display: none; } html:not(.js) .fstep .v-ok { display: inline; }
html:not(.js) .fstep:last-child .fd { display: block; }
/* ── Made by Manifold: pictures from its image model, each opening with what its vision model found ── */
.gal { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--s-3); }
.g { position: relative; display: block; padding: 0; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); background: var(--bg-1); cursor: zoom-in; text-align: left; grid-column: span 2; transition: transform 240ms var(--ease-out), box-shadow 240ms ease, border-color 240ms ease; }
.g.g-wide { grid-column: span 3; }
.g img { display: block; width: 100%; height: 100%; aspect-ratio: 1; object-fit: cover; pointer-events: none; }
.g.g-wide img { aspect-ratio: 16 / 10; }
.g-cap { position: absolute; inset: auto 0 0; display: grid; gap: 4px; padding: 28px 14px 12px; font-size: 12.5px; line-height: 1.4; color: rgba(244, 245, 247, 0.92); background: linear-gradient(180deg, transparent, rgba(5, 7, 10, 0.86)); }
.g-cap .mono { font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.g:active { transform: scale(0.99); }
@media (hover: hover) and (pointer: fine) {
	.g-cap { opacity: 0; transform: translateY(6px); transition: opacity 220ms var(--ease-out), transform 220ms var(--ease-out); }
	.g:hover, .g:focus-visible { transform: translateY(-3px); border-color: rgba(var(--c1), calc(0.35 * var(--tint-k))); box-shadow: 0 18px 50px -20px rgba(var(--c1), calc(0.45 * var(--glow-k))); }
	.g:hover .g-cap, .g:focus-visible .g-cap { opacity: 1; transform: none; }
}
@media (max-width: 767px) { .gal { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g, .g.g-wide { grid-column: span 1; } .g.g-wide { grid-column: 1 / -1; } }
.track { grid-template-columns: auto auto minmax(0, 1fr); }
.track .art { width: 48px; height: 48px; border-radius: 9px; border: 1px solid var(--line); }
.track .wave { gap: 2px; min-width: 0; }
.track .wave i { min-width: 1px; }
@media (max-width: 1180px) { .ui-media { grid-template-columns: 1fr; } .shots { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ── Every kind of work, in Glacier: frosted panels, an ice-lit edge on each card, the hero's pattern in a corner ── */
.tile { background: linear-gradient(160deg, rgba(var(--c1), calc(0.30 * var(--tint-k))), rgba(255, 255, 255, 0.07) 32%, rgba(255, 255, 255, 0.03) 70%, rgba(var(--c2), calc(0.16 * var(--tint-k)))); }
.tile-in { background: radial-gradient(120% 70% at 0% 0%, rgba(var(--c1), calc(0.07 * var(--tint-k))), transparent 55%), linear-gradient(180deg, #0d1117, var(--bg-1) 60%); }
/* The lit top edge: the same blue line as the hero floor, fading out at both ends. */
.tile-in::after { content: ""; position: absolute; left: 8%; right: 8%; top: 0; height: 1px; pointer-events: none;
	background: linear-gradient(90deg, transparent, rgba(var(--c1), calc(0.75 * var(--tint-k))), transparent);
	box-shadow: 0 0 18px 1px rgba(var(--c1), calc(0.45 * var(--glow-k))); }
/* The page's background pattern, faint, in each card's top right corner. */
.tile-pat { position: absolute; top: 0; right: 0; width: 60%; height: 70%; pointer-events: none; opacity: calc(var(--lat-o, 0.07) * 1.3); background: rgb(var(--lat, var(--c1)));
	-webkit-mask-image: radial-gradient(70% 80% at 100% 0%, #000, transparent 75%), var(--pat); mask-image: radial-gradient(70% 80% at 100% 0%, #000, transparent 75%), var(--pat);
	-webkit-mask-size: 100% 100%, var(--pat-size); mask-size: 100% 100%, var(--pat-size); -webkit-mask-repeat: no-repeat, repeat; mask-repeat: no-repeat, repeat; -webkit-mask-composite: source-in; mask-composite: intersect; }
:root[data-pat="none"] .tile-pat { display: none; }
.tile-ui { z-index: 1; } .tile h3, .tile-in > p { position: relative; z-index: 1; }
/* Frosted ice panels inside the cards. */
.ui-research, .mem, .pdf, .app, .agenda li, .track, .chips span {
	background: linear-gradient(180deg, rgba(var(--c1), calc(0.06 * var(--tint-k))), rgba(var(--c1), calc(0.02 * var(--tint-k)))), rgba(14, 18, 24, 0.85);
	border-color: rgba(var(--c1), calc(0.14 * var(--tint-k)));
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05); }
.mem i { box-shadow: 0 0 8px rgba(var(--c1), calc(0.8 * var(--glow-k))); }
.mem.dim i { box-shadow: none; }
.habits i { background: rgba(var(--c1), calc(0.04 * var(--tint-k))); border-color: rgba(var(--c1), calc(0.12 * var(--tint-k))); }
.habits i.on { box-shadow: 0 0 12px -2px rgba(var(--c1), calc(0.7 * var(--glow-k))), inset 0 1px 0 rgba(255, 255, 255, 0.3); }
.agenda li.next { border-color: rgba(var(--c1), calc(0.45 * var(--tint-k))); box-shadow: 0 0 22px -8px rgba(var(--c1), calc(0.6 * var(--glow-k))), inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.agenda li.next time { color: var(--accent); }
.shots img, .track .art { border-color: rgba(var(--c1), calc(0.18 * var(--tint-k))); }
@media (hover: hover) and (pointer: fine) {
	.shot:hover { box-shadow: 0 10px 30px -10px rgba(var(--c1), calc(0.6 * var(--glow-k))); }
	.tile:hover .tile-in::after { box-shadow: 0 0 26px 2px rgba(var(--c1), calc(0.7 * var(--glow-k))); }
}
/* The PDF Manifold made: the top of its page, fading into the card; opens to the whole page. */
.pdf-peek { display: block; width: 100%; height: 150px; padding: 0; overflow: hidden; border-radius: 12px 12px 4px 4px; cursor: zoom-in; position: relative;
	border: 1px solid rgba(var(--c1), calc(0.18 * var(--tint-k))); background: #f6f8fb;
	-webkit-mask-image: linear-gradient(#000 62%, transparent); mask-image: linear-gradient(#000 62%, transparent);
	transition: transform 240ms var(--ease-out), box-shadow 240ms ease; }
.pdf-peek img { display: block; width: 100%; height: auto; pointer-events: none; }
.pdf-peek:active { transform: scale(0.99); }
@media (hover: hover) and (pointer: fine) { .pdf-peek:hover { transform: translateY(-2px); box-shadow: 0 16px 40px -18px rgba(var(--c1), calc(0.6 * var(--glow-k))); } }

/* ── Hero: centred, with an ask box; Manifold at work in its window below ── */
.hero-top, .hero-top .hero-copy { display: grid; justify-items: center; text-align: center; }
@media (min-width: 1024px) { .hero-top { display: grid; grid-template-columns: 1fr; } .hero-top h1 { font-size: clamp(44px, 5vw, 68px); } }
.hero-copy h1 { max-width: none; }
.hero-copy .lede { margin-inline: auto; }
.ask { display: flex; align-items: center; gap: 10px; width: min(100%, 640px); margin-top: var(--s-7); padding: 10px 10px 10px 16px; border-radius: 18px; text-align: left;
	background: linear-gradient(180deg, rgba(var(--c1), calc(0.06 * var(--tint-k))), rgba(var(--c1), calc(0.02 * var(--tint-k)))), rgba(14, 18, 24, 0.9);
	border: 1px solid rgba(var(--c1), calc(0.3 * var(--tint-k)));
	box-shadow: 0 0 0 4px rgba(var(--c1), calc(0.05 * var(--tint-k))), 0 20px 60px -24px rgba(var(--c1), calc(0.5 * var(--glow-k))); color: var(--fg); font-size: 16px; }
.ask-file { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 10px 0 4px; border-radius: 9px; font-size: 13px; color: var(--fg-2); background: rgba(var(--c1), calc(0.06 * var(--tint-k))); border: 1px solid rgba(var(--c1), calc(0.2 * var(--tint-k))); }
.ask-file[hidden] { display: none; }
.ask-file .pdf-ico { width: 26px; height: 24px; font-size: 7.5px; border-radius: 5px; }
.ask-text { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ask-text::after { content: ""; display: inline-block; width: 2px; height: 1.1em; margin-left: 2px; vertical-align: -0.15em; background: var(--accent); }
@media (prefers-reduced-motion: no-preference) { .ask-text::after { animation: caret 1s steps(1) infinite; } @keyframes caret { 50% { opacity: 0; } } }
.ask-go { flex: none; height: 40px; padding: 0 16px; border-radius: 12px; background: var(--fg); color: var(--bg); font-size: 14px; font-weight: 600; display: grid; place-items: center; }
.ask-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: var(--s-4); }
.ask-chips span { height: 32px; padding: 0 12px; display: inline-flex; align-items: center; gap: 7px; border-radius: 999px; font-size: 13px; color: var(--fg-2); border: 1px solid rgba(var(--c1), calc(0.16 * var(--tint-k))); background: rgba(var(--c1), calc(0.03 * var(--tint-k))); }
.ask-chips .ti { width: 14px; height: 14px; }
.hero-copy .cta { justify-content: center; margin-top: var(--s-6); }
.w-live { list-style: none; display: grid; gap: 2px; margin: 0 0 2px; font-size: 12.5px; }
.w-live .fstep { transform: translateY(3px); transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out), background-color 300ms ease; }
.w-live .fstep.run, .w-live .fstep.ok { transform: none; }
.w-live .fh { min-height: 28px; padding: 0 8px; grid-template-columns: 16px 1fr 14px; }
.w-live .fd { margin: 2px 8px 10px 32px; }
.w-live .fd-img img { max-width: 240px; }
.fd-note { font-size: 12px; line-height: 1.5; color: var(--fg-2); padding: 6px 10px; border-left: 2px solid rgba(var(--c1), calc(0.5 * var(--tint-k))); background: rgba(var(--c1), calc(0.04 * var(--tint-k))); border-radius: 0 8px 8px 0; }
.js .w-reply:not(.done) .w-text, .js .w-reply:not(.done) .w-after { display: none; }
@media (max-width: 600px) { .ask { font-size: 15px; } .ask-file { display: none; } }
.js .w-live .fstep { opacity: 0; } .js .w-live .fstep.run, .js .w-live .fstep.ok { opacity: 1; }
/* The picture viewer shows no boxes until you point at something: only that one box and its name appear. */
.lb-box { opacity: 0; }
.focus .lb-box { opacity: 0; }
.focus .lb-box.on { opacity: 1; }
/* The hero's single column never grows past the screen (its content, the ask box's long line, would widen it). */
.hero-top, .hero-top .hero-copy { grid-template-columns: minmax(0, 1fr); }
.ask { max-width: 100%; text-decoration: none; cursor: pointer; transition: border-color 200ms ease, box-shadow 200ms ease; }
@media (hover: hover) and (pointer: fine) { .ask:hover { border-color: rgba(var(--c1), calc(0.55 * var(--tint-k))); } }
.ask:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.ask.typed .ask-text::after { animation: none; opacity: 0; }
/* A phone held sideways: the hero fits the short screen with its buttons in view. */
@media (orientation: landscape) and (max-height: 520px) {
	.hero { padding-top: 24px; }
	.hero-top h1 { font-size: clamp(30px, 6vh, 40px); }
	.hero-copy .lede { margin-top: var(--s-3); font-size: 15px; }
	.ask { margin-top: var(--s-4); }
	.ask-chips { display: none; }
	.hero-copy .cta { margin-top: var(--s-4); }
}

/* Footer links are easy to tap on touch screens (DESIGN.md: 44px targets on coarse pointers). */
@media (pointer: coarse) { .site-footer a { display: inline-flex; align-items: center; min-height: 44px; } }
/* Encryption on the Manifold lane: the connection, and what is encrypted on the server. */
.wire-live { position: relative; }
.wire-tag { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: 999px; white-space: nowrap;
	font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--fg);
	background: var(--bg-1); border: 1px solid rgba(var(--c1), calc(0.4 * var(--tint-k))); box-shadow: 0 0 18px -6px rgba(var(--c1), calc(0.6 * var(--glow-k))); }
.lk, .wire .lk { width: 11px; height: 11px; overflow: visible; fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; flex: none; }
.node-home { flex-wrap: wrap; height: auto; min-height: 40px; padding-block: 8px; row-gap: 2px; }
.node-sub { flex-basis: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 5px; font-size: 11px; font-weight: 400; color: var(--fg-2); }
@media (max-width: 899px) {
	.wire-live { width: auto; }
	.wire-live::before { margin-left: 0; width: 3px; }
	.wire-tag { left: 18px; bottom: auto; top: 50%; transform: translateY(-50%); }
	.wire-live svg.lk { display: block; }
	.node-sub { justify-content: flex-start; }
}
/* ── Apps card: Manifold-made apps, live in a frame ── */
/* A small inline widget, as Manifold shows one in a chat: a few rows, sized to its content. */
.wg { padding: var(--s-3) var(--s-4) var(--s-4); border-radius: 12px; border: 1px solid rgba(var(--c1), calc(0.14 * var(--tint-k))); background: linear-gradient(180deg, rgba(var(--c1), calc(0.06 * var(--tint-k))), rgba(var(--c1), calc(0.02 * var(--tint-k)))), rgba(14, 18, 24, 0.85); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05); }
.wg-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-3); font-size: 13px; color: var(--fg); }
.wg-head .mono, .wg-list .mono { font-size: 11.5px; color: var(--fg-3); font-variant-numeric: tabular-nums; }
.wg-list { list-style: none; display: grid; gap: 2px; margin-top: var(--s-3); }
.wg-list li { display: grid; grid-template-columns: 16px 1fr auto; align-items: center; gap: var(--s-2); padding: 5px 0; color: var(--fg-2); border-top: 1px solid var(--line); }
.wg-list li:first-child { border-top: 0; }
.wg-list i { width: 14px; height: 14px; border-radius: 4px; border: 1px solid var(--line-strong); }
.wg-list li.done { color: var(--fg); }
.wg-list li.done i { border-color: transparent; background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%2308090b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat; }
.wg-bar { margin-top: var(--s-3); height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.wg-bar span { display: block; width: 75%; height: 100%; background: linear-gradient(90deg, var(--accent), rgb(var(--c2))); }
/* A 3D model Manifold made: a poster until the viewer loads near the screen (site.js), sized to the tile. */
.m3d { position: relative; aspect-ratio: 3 / 2; border-radius: 12px; overflow: hidden; border: 1px solid rgba(var(--c1), calc(0.14 * var(--tint-k))); background: radial-gradient(70% 60% at 50% 45%, rgba(var(--c1), calc(0.10 * var(--tint-k))), transparent 70%), rgba(14, 18, 24, 0.85); }
.m3d-poster, .m3d model-viewer { position: absolute; inset: 0; width: 100%; height: 100%; }
.m3d-poster { object-fit: contain; }
.m3d model-viewer { --poster-color: transparent; background: transparent; touch-action: pan-y; }
.m3d.live .m3d-poster { opacity: 0; transition: opacity 300ms ease; }
.m3d-hint { margin-top: var(--s-2); font-size: 11.5px; color: var(--fg-3); }
/* The Google services it can read when connected: a row of read-only chips. */
.ui-connect { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.svc { display: inline-flex; align-items: center; gap: var(--s-2); padding: 6px 10px; border-radius: 9px; font-size: 13px; color: var(--fg); border: 1px solid rgba(var(--c1), calc(0.14 * var(--tint-k))); background: rgba(14, 18, 24, 0.85); }
.svc em { font-style: normal; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }

/* Join the waitlist: an email and a button, with what the address is for. */
.wl { margin-top: var(--s-7); max-width: 30rem; display: grid; gap: var(--s-2); }
.wl-lead { font-size: 14px; color: var(--fg-2); }
.wl-row { display: flex; gap: var(--s-2); }
.wl-input { flex: 1; min-width: 0; height: 44px; padding: 0 var(--s-4); border-radius: var(--radius-sm); border: 1px solid var(--line-strong); background: var(--bg-2); color: var(--fg); font: inherit; font-size: 15px; }
.wl-input::placeholder { color: var(--fg-3); }
.wl-input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.wl-btn { height: 44px; flex: none; }
.wl-btn[disabled] { opacity: 0.6; cursor: progress; }
.wl-msg:empty { display: none; }
.wl-msg { font-size: 14px; }
.wl[data-state="ok"] .wl-msg { color: var(--fg); }
.wl[data-state="ok"] .wl-row { display: none; }
.wl[data-state="error"] .wl-msg { color: #ff9a9a; }
.wl[data-state="error"] .wl-input { border-color: rgba(255, 120, 120, 0.6); }
.wl-note { font-size: 12.5px; color: var(--fg-3); }
.cta-in .wl { margin-top: 0; width: 100%; justify-items: center; text-align: center; }
.cta-in .wl-row { width: 100%; }
@media (max-width: 479px) { .wl-row { flex-direction: column; } .wl-input { flex: none; width: 100%; } .wl-btn { width: 100%; } }
/* The reply's itinerary, the way the app draws its itinerary widget: one row a day. */
.w-itin { list-style: none; display: grid; gap: 4px; margin: 0; padding: 10px; border-radius: 12px; font-size: 13px; line-height: 1.45;
	background: rgba(var(--c1), calc(0.04 * var(--tint-k))); border: 1px solid rgba(var(--c1), calc(0.16 * var(--tint-k))); }
.w-itin li { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 10px; padding: 5px 6px; border-radius: 8px; color: var(--fg-2); }
.w-itin li + li { border-top: 1px solid rgba(255, 255, 255, 0.04); }
.w-itin b { color: var(--accent); font-weight: 600; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.04em; padding-top: 1px; }
.js .w-reply:not(.done) .w-itin { display: none; }
@media (prefers-reduced-motion: no-preference) { .w-reply.done .w-itin { animation: fd-in 420ms var(--ease-out) 900ms both; } }
.w-image-top, .w-image.w-image-top { width: 100%; max-width: none; }
.w-image-top img { display: block; width: 100%; height: 200px; object-fit: cover; object-position: center 40%; }
@media (max-width: 767px) { .w-image-top img { height: auto; aspect-ratio: 2.4 / 1; } }
.js .w-reply:not(.done) .w-image-top { display: none; }
@media (prefers-reduced-motion: no-preference) { .w-reply.done .w-image-top { animation: fd-in 420ms var(--ease-out) 600ms both; } }
/* Finished, the steps fold into one line, as the app does. */
.w-steps-done { display: none; align-items: center; gap: var(--s-2); font-size: 12.5px; color: var(--fg-3); }
.w-steps-done .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.w-reply.done .w-live { display: none; }
.w-reply.done .w-steps-done, html:not(.js) .w-steps-done { display: flex; }
html:not(.js) .w-live { display: none; }
