/* CHG-262 P6.4 — copied + trimmed from the root SPA's static/styles/tokens.css
 * (Exon UI design tokens). Trimmed: no safe-area / bottom-nav / touch-target
 * variables (those are Capacitor-mobile concerns; this app is desktop-first
 * web, no Capacitor). Colors/spacing/typography kept identical so an admin
 * switching between apps sees a consistent palette. */
:root {
	/* Colors - Light mode */
	--color-primary: #3b82f6;
	--color-primary-hover: #2563eb;
	--color-primary-active: #1d4ed8;
	--color-primary-alpha: rgba(59, 130, 246, 0.1);

	--color-success: #10b981;
	--color-success-bg: #ecfdf5;
	--color-warning: #f59e0b;
	--color-warning-bg: #fffbeb;
	--color-error: #ef4444;
	--color-error-bg: #fef2f2;
	--color-error-alpha: rgba(239, 68, 68, 0.1);

	--color-text: #1f2937;
	--color-text-secondary: #4b5563;
	--color-text-muted: #6b7280;
	--color-text-inverse: #ffffff;

	--color-bg: #ffffff;
	--color-bg-muted: #f3f4f6;
	--color-bg-elevated: #ffffff;

	--color-border: #e5e7eb;
	--color-border-hover: #d1d5db;

	/* Admin-portal-only accent — distinguishes this app's chrome from the
	 * product SPA's --color-primary at a glance (nav rail, active state). */
	--color-admin-accent: #1e293b;
	--color-admin-accent-hover: #0f172a;

	/* Spacing (4px base) */
	--space-xs: 0.25rem;
	--space-sm: 0.5rem;
	--space-md: 1rem;
	--space-lg: 1.5rem;
	--space-xl: 2rem;
	--space-2xl: 3rem;

	/* Typography */
	--text-xs: 0.8125rem;
	--text-sm: 0.9375rem;
	--text-base: 1rem;
	--text-lg: 1.125rem;
	--text-xl: 1.25rem;
	--text-2xl: 1.5rem;
	--text-3xl: 1.875rem;

	--line-height-tight: 1.25;
	--line-height-normal: 1.5;
	--line-height-relaxed: 1.625;

	--radius-sm: 0.25rem;
	--radius-md: 0.375rem;
	--radius-lg: 0.5rem;
	--radius-xl: 0.75rem;
	--radius-full: 9999px;

	--shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
	--shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
	--shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);

	--transition-fast: 150ms ease;
	--transition-base: 200ms ease;

	--font-family:
		'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
		sans-serif;

	/* Desktop-first layout */
	--nav-width: 15rem;
	--topbar-height: 3.5rem;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	font-family: var(--font-family);
	font-size: 16px;
	line-height: 1.5;
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	padding: 0;
	background-color: var(--color-bg-muted);
	color: var(--color-text);
	min-height: 100vh;
}

/* CHG-052 (root SPA) precedent kept: visible focus indicators, WCAG 2.1 AA */
:focus-visible {
	outline: 3px solid var(--color-primary, #3b82f6);
	outline-offset: 3px;
	box-shadow: 0 0 0 6px rgba(59, 130, 246, 0.25);
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
	outline: 3px solid var(--color-primary, #3b82f6);
	outline-offset: 3px;
	box-shadow: 0 0 0 6px rgba(59, 130, 246, 0.25);
}

:focus:not(:focus-visible) {
	outline: none;
	box-shadow: none;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}
