tga 10.2.0

Developer productivity analytics — git commit collection, classification, and reporting
@tailwind base;
@tailwind components;
@tailwind utilities;

/* Why: the Foundry v2 token layer for this site, on the same convention every
 * other trusty-* Tailwind consumer uses (trusty-tools/website, trusty-agents/ui,
 * trusty-code-gui, trusty-mpm-gui): every custom property below is a
 * SPACE-SEPARATED RGB TRIPLE ("R G B", not "#rrggbb"), because
 * tailwind.config.js consumes them as `rgb(var(--color-*) / <alpha-value>)` —
 * the only form from which Tailwind can generate opacity-modified utilities
 * (`bg-foundry-primary/10`). A bare `var(--color-*)` silently generates no
 * rule for those.
 *
 * The light block is the default; the dark block overrides every property.
 * `.dark` (not a data-attribute) is the activation selector, matching
 * tailwind.config.js's `darkMode: 'class'` and src/lib/theme/index.ts, which
 * toggles that class on <html>.
 *
 * Test: this site carries no automated drift check against a canonical
 * tokens.css (unlike trusty-tools/website, which has one in-repo to diff
 * against) — these values were hand-transcribed from the same Foundry v2
 * palette trusty-tools/website uses, at trusty-tools 603e6039.
 */
:root {
	color-scheme: light dark;

	--color-content-bg: 245 239 231; /* #F5EFE7 */
	--color-card-bg: 255 253 249; /* #FFFDF9 */
	--color-surface-raised: 239 230 216; /* #EFE6D8 */
	--color-border: 216 201 180; /* #D8C9B4 */
	--color-border-strong: 196 176 150; /* #C4B096 */
	--color-text-primary: 43 28 18; /* #2B1C12 */
	--color-text-secondary: 110 88 67; /* #6E5843 */
	--color-text-muted: 138 116 96; /* #8A7460 */
	--color-text-inverse: 255 255 255; /* #FFFFFF */
	--color-primary: 183 65 14; /* #B7410E */
	--color-primary-hover: 138 47 11; /* #8A2F0B */
	--color-success: 63 111 42; /* #3F6F2A */
	--color-warning: 176 125 16; /* #B07D10 */
	--color-danger: 194 51 31; /* #C2331F */
	--color-info: 61 107 138; /* #3D6B8A */
	--color-sidebar-bg: 43 28 18; /* #2B1C12 */
	--color-sidebar-text: 230 216 200; /* #E6D8C8 */
	--color-sidebar-muted: 165 138 107; /* #A58A6B */
	--color-sidebar-accent: 233 185 138; /* #E9B98A */
	--color-sidebar-border: 70 49 31; /* #46311F */
}

.dark {
	--color-content-bg: 32 22 18; /* #201612 */
	--color-card-bg: 43 28 18; /* #2B1C12 */
	--color-surface-raised: 56 37 19; /* #382513 */
	--color-border: 70 49 31; /* #46311F */
	--color-border-strong: 92 65 38; /* #5C4126 */
	--color-text-primary: 240 231 216; /* #F0E7D8 */
	--color-text-secondary: 203 182 156; /* #CBB69C */
	--color-text-muted: 165 138 107; /* #A58A6B */
	--color-text-inverse: 32 22 18; /* #201612 */
	--color-primary: 217 119 66; /* #D97742 */
	--color-primary-hover: 232 144 92; /* #E8905C */
	--color-success: 143 191 106; /* #8FBF6A */
	--color-warning: 217 168 58; /* #D9A83A */
	--color-danger: 224 106 82; /* #E06A52 */
	--color-info: 123 167 196; /* #7BA7C4 */
	--color-sidebar-bg: 23 16 9; /* #171009 */
	--color-sidebar-text: 230 216 200; /* #E6D8C8 */
	--color-sidebar-muted: 165 138 107; /* #A58A6B */
	--color-sidebar-accent: 233 185 138; /* #E9B98A */
	--color-sidebar-border: 56 37 19; /* #382513 */
}

/* Self-hosted OFL faces from static/fonts/. Deliberately no CDN: the site
   must render with no external font host. */
@font-face {
	font-family: 'Chakra Petch';
	font-style: normal;
	font-weight: 500;
	font-display: swap;
	src: url('/fonts/chakra-petch-500.woff2') format('woff2');
}
@font-face {
	font-family: 'Chakra Petch';
	font-style: normal;
	font-weight: 600;
	font-display: swap;
	src: url('/fonts/chakra-petch-600.woff2') format('woff2');
}
@font-face {
	font-family: 'Chakra Petch';
	font-style: normal;
	font-weight: 700;
	font-display: swap;
	src: url('/fonts/chakra-petch-700.woff2') format('woff2');
}
@font-face {
	font-family: 'IBM Plex Sans';
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
	src: url('/fonts/ibm-plex-sans-var.woff2') format('woff2');
}
@font-face {
	font-family: 'IBM Plex Mono';
	font-style: normal;
	font-weight: 400;
	font-display: swap;
	src: url('/fonts/ibm-plex-mono-400.woff2') format('woff2');
}
@font-face {
	font-family: 'IBM Plex Mono';
	font-style: normal;
	font-weight: 500;
	font-display: swap;
	src: url('/fonts/ibm-plex-mono-500.woff2') format('woff2');
}
@font-face {
	font-family: 'IBM Plex Mono';
	font-style: normal;
	font-weight: 600;
	font-display: swap;
	src: url('/fonts/ibm-plex-mono-600.woff2') format('woff2');
}

@layer base {
	body {
		@apply bg-foundry-bg font-sans text-foundry-text antialiased;
	}

	/* Foundry: "machines talk mono" — ids, paths, counts, versions. */
	code,
	pre,
	kbd,
	samp {
		@apply font-mono;
	}

	/* Why: the default UA focus ring is invisible against the rust palette in
	   dark mode, and `:focus-visible` keeps it off mouse clicks. The accent is
	   the only token that clears WCAG 1.4.11's 3:1 non-text minimum against
	   every surface here — the border tokens do not, so they must never carry
	   a focus indicator. */
	:focus-visible {
		@apply outline-none ring-2 ring-foundry-primary ring-offset-2 ring-offset-foundry-bg;
	}
}

@layer components {
	.btn {
		@apply inline-flex items-center justify-center gap-2 rounded border-[1.5px] px-4 py-2 text-sm font-semibold transition-colors;
	}

	.btn-primary {
		@apply border-foundry-primary bg-foundry-primary text-foundry-inverse hover:border-foundry-primary-hover hover:bg-foundry-primary-hover;
	}

	.btn-secondary {
		@apply border-foundry-border-strong bg-foundry-card text-foundry-text hover:border-foundry-primary;
	}

	.card {
		@apply rounded-lg border-[1.5px] border-foundry-border bg-foundry-card p-6;
	}

	.badge {
		@apply inline-block rounded-sm border border-foundry-border-strong px-2 py-0.5 font-mono text-[11px] uppercase tracking-wider text-foundry-secondary;
	}

	.eyebrow {
		@apply font-mono text-xs uppercase tracking-[0.18em] text-foundry-secondary;
	}

	/* Minimal prose helpers for the usage/audit pages — headings, lists, and
	   code, without the full documentation-reader pipeline trusty-tools/website
	   carries (this site renders no markdown at runtime; every page is Svelte). */
	.prose-block h2 {
		@apply mt-12 border-b border-foundry-border pb-2 font-display text-2xl font-semibold tracking-tight first:mt-0;
	}

	.prose-block h3 {
		@apply mt-8 font-display text-xl font-semibold;
	}

	.prose-block p {
		@apply mt-4 max-w-3xl text-foundry-secondary;
	}

	.prose-block ul {
		@apply mt-4 max-w-3xl list-disc space-y-2 pl-6 text-foundry-secondary;
	}

	.prose-block :not(pre) > code {
		@apply rounded-sm border border-foundry-border bg-foundry-card px-1 py-px text-[0.9em] text-foundry-text;
	}

	.prose-block pre {
		@apply mt-4 max-w-3xl overflow-x-auto rounded border-[1.5px] border-foundry-border bg-foundry-raised p-4 text-sm leading-relaxed text-foundry-text;
	}

	.doc-table {
		@apply my-6 overflow-x-auto rounded border-[1.5px] border-foundry-border;
	}

	table {
		@apply w-full border-collapse text-left text-sm;
	}

	thead {
		@apply bg-foundry-card;
	}

	th {
		@apply border-b-[1.5px] border-foundry-border px-3 py-2 font-semibold;
	}

	td {
		@apply border-b border-foundry-border px-3 py-2 align-top;
	}

	tbody tr:last-child td {
		@apply border-b-0;
	}
}