/* Royal Original design tokens (Email Template Examples brand book v1.0).
   Generated from docs/brand/tokens.json, the canonical data. Change values there first, then here.
   Naming per book p21: --color-{key}, --font-{key}, --font-size-{role}, --font-weight-{role}, --line-height-{role},
   --letter-spacing-{role}, --space-0..10, --radius-*, --shadow-*, --motion-*, plus layout aliases per breakpoint.
   Light only: the site has no dark theme (owner decision 2026-10-29), so the book's dark column is not used.
   Email previews never use these tokens: they keep their own colors. */

:root {
	color-scheme: light;

	/* Color (book p04-05) */
	--color-page: #FFFFFF;
	--color-surface: #FFFFFF;
	--color-surface-tint: #F5F9FF;
	--color-surface-raised: #FFFFFF;
	--color-text: #090914;
	--color-text-muted: #4B5768;
	--color-border: #CBD5E1;
	--color-control-border: #64748B;
	--color-primary: #1D4ED8;
	--color-primary-hover: #1E40AF;
	--color-primary-active: #1E3A8A;
	--color-on-primary: #FFFFFF;
	--color-accent: #456FE0;
	--color-link: #1D4ED8;
	--color-focus: #1D4ED8;
	--color-success: #166534;
	--color-success-bg: #F0FDF4;
	--color-warning: #854D0E;
	--color-warning-bg: #FEFCE8;
	--color-error: #B91C1C;
	--color-error-bg: #FEF2F2;
	--color-info: #1E40AF;
	--color-info-bg: #EFF6FF;
	--color-disabled-bg: #E2E8F0;  /* not in book: sampled from the p23 specimen */
	--color-disabled-text: #4B5768;  /* not in book: sampled from the p23 specimen */
	--color-overlay: rgba(9, 9, 20, 0.5);  /* not in book: our value */

	/* Font (book p07) */
	--font-display: 'DM Sans', 'DM Sans Fallback', system-ui, -apple-system, 'Segoe UI', sans-serif;
	--font-body: 'DM Sans', 'DM Sans Fallback', system-ui, -apple-system, 'Segoe UI', sans-serif;
	--font-mono: 'IBM Plex Mono', 'IBM Plex Mono Fallback', ui-monospace, 'Cascadia Mono', Consolas, monospace;

	/* Type scale (book p07). Phone sizes below 768px, desktop sizes from 768px. */
	--font-size-display: 44px;
	--font-size-h1: 36px;
	--font-size-h2: 32px;
	--font-size-h3: 26px;
	--font-size-h4: 22px;
	--font-size-lead: 18px;
	--font-size-body: 16px;
	--font-size-small: 16px;
	--font-size-caption: 16px;
	--font-size-label: 16px;
	--font-size-code: 16px;
	--font-weight-display: 300;
	--font-weight-h1: 300;
	--font-weight-h2: 300;
	--font-weight-h3: 400;
	--font-weight-h4: 500;
	--font-weight-lead: 400;
	--font-weight-body: 400;
	--font-weight-small: 400;
	--font-weight-caption: 400;
	--font-weight-label: 500;
	--font-weight-code: 400;
	--line-height-display: 1.06;
	--line-height-h1: 1.1;
	--line-height-h2: 1.15;
	--line-height-h3: 1.2;
	--line-height-h4: 1.3;
	--line-height-lead: 1.5;
	--line-height-body: 1.6;
	--line-height-small: 1.4;
	--line-height-caption: 1.4;
	--line-height-label: 1.25;
	--line-height-code: 1.5;
	--letter-spacing-display: -2px;
	--letter-spacing-h1: -1.5px;
	--letter-spacing-h2: -1px;
	--letter-spacing-h3: -0.5px;
	--letter-spacing-h4: -0.25px;
	--letter-spacing-lead: 0px;
	--letter-spacing-body: 0px;
	--letter-spacing-small: 0px;
	--letter-spacing-caption: 0px;
	--letter-spacing-label: 0px;
	--letter-spacing-code: 0px;

	/* Space (book p08) */
	--space-0: 0px;
	--space-1: 4px;
	--space-2: 8px;
	--space-3: 12px;
	--space-4: 16px;
	--space-5: 24px;
	--space-6: 32px;
	--space-7: 48px;
	--space-8: 64px;
	--space-9: 96px;
	--space-10: 128px;

	/* Radius (book p09) */
	--radius-pill: 999px;
	--radius-control: 8px;
	--radius-card: 12px;
	--radius-tooltip: 4px;
	--radius-dropdown: 12px;
	--radius-toast: 12px;
	--radius-modal: 20px;
	--radius-panel: 28px;
	--radius-canvas: 4px;

	/* Shadow (book p09) */
	--shadow-card: 0 4px 16px rgba(9,9,20,0.08);
	--shadow-raised: 0 12px 32px rgba(9,9,20,0.12);
	--shadow-modal: 0 24px 64px rgba(9,9,20,0.20);

	/* Motion (book p11) */
	--motion-duration-fast: 150ms;
	--motion-duration-base: 250ms;
	--motion-duration-exit: 150ms;
	--motion-duration-story: 400ms;
	--motion-ease: cubic-bezier(0.2,0,0,1);

	/* Layout (book p08, p16). Phone values here, larger breakpoints below. */
	--page-max: 1600px;
	--page-gutter: 20px;
	--grid-columns: 4;
	--grid-gap: 16px;
	--section-padding: 48px;
	--gallery-columns: 1;
	--blog-columns: 1;
	--panel-padding: 24px;  /* book gives this as prose */
	--header-height: 64px;
}

@media (min-width: 768px) {
	:root {
		--font-size-display: 80px;
		--font-size-h1: 64px;
		--font-size-h2: 48px;
		--font-size-h3: 32px;
		--font-size-h4: 24px;
		--font-size-lead: 20px;
		--page-gutter: 32px;
		--grid-columns: 8;
		--grid-gap: 24px;
		--section-padding: 64px;
		--gallery-columns: 2;
		--blog-columns: 2;
		--panel-padding: 32px;
		--header-height: 80px;
	}
}
@media (min-width: 1024px) {
	:root {
		--page-gutter: 40px;
		--grid-columns: 12;
		--grid-gap: 24px;
		--section-padding: 80px;
		--gallery-columns: 3;
		--blog-columns: 3;
		--panel-padding: 48px;
		--header-height: 80px;
	}
}
@media (min-width: 1440px) {
	:root {
		--page-gutter: 64px;
		--grid-columns: 12;
		--grid-gap: 24px;
		--section-padding: 96px;
		--gallery-columns: 4;
		--blog-columns: 3;
		--panel-padding: 48px;
		--header-height: 80px;
	}
}

