/*
 * Design tokens: pop-art comic.
 *
 * Contrast (WCAG 2.2), checked 11 Nov 2026:
 *   ink on paper 17.8 · ink on yellow 13.4 · ink on cyan 8.1 · ink on pink 6.2
 *   white on red 5.2 · paper on red 5.0 · white on ink 18.9 · faded ink on aged paper 8.9
 *   ink on red 3.6: NEVER for text. White on yellow or cyan: never.
 */

:root {
	/* Full-colour palette */
	--jb-ink:    #111111;
	--jb-paper:  #FFF8E7;
	--jb-white:  #FFFFFF;
	--jb-yellow: #FFD60A;
	--jb-red:    #D7141A;
	--jb-cyan:   #00B7EB;
	--jb-pink:   #FF4FA3;

	/* Newsprint set for the "before" pages */
	--jb-aged:       #EDE3C8;
	--jb-faded-ink:  #3A3A3A;
	--jb-dull-red:   #B5564E;
	--jb-dull-blue:  #6E8FA3;

	--jb-muted: #4A4A4A;      /* secondary text on paper, 8.4:1 */
	--jb-line:  rgba(17, 17, 17, 0.14);

	/* Roles */
	--jb-bg:     var(--jb-paper);
	--jb-fg:     var(--jb-ink);
	--jb-accent: var(--jb-yellow);

	/* Kept for the sample-site component */
	--jb-blue:      #1D4ED8;
	--jb-orange:    var(--jb-red);
	--jb-ink-soft:  var(--jb-muted);
	--jb-ink-faint: #8A8A8A;
	--jb-clay:      var(--jb-aged);

	/* Type */
	--jb-font-display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
	--jb-font-text:    "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	--jb-font-sfx:     "Bangers", "Impact", "Arial Black", sans-serif;
	--jb-font-comic:   "Comic Neue", "Comic Sans MS", "Chalkboard SE", sans-serif;
	--jb-font-mono:    ui-monospace, "Cascadia Mono", Consolas, monospace;

	--jb-step--1: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
	--jb-step-0:  clamp(1rem, 0.96rem + 0.19vw, 1.125rem);
	--jb-step-1:  clamp(1.2rem, 1.1rem + 0.45vw, 1.5rem);
	--jb-step-2:  clamp(1.5rem, 1.3rem + 0.9vw, 2.125rem);
	--jb-step-3:  clamp(2rem, 1.6rem + 1.85vw, 3.25rem);
	--jb-step-4:  clamp(2.5rem, 1.9rem + 3vw, 4.5rem);
	--jb-step-5:  clamp(3rem, 1.9rem + 5vw, 6.75rem);

	--jb-leading-tight: 0.92;
	--jb-leading-text:  1.55;

	/* Space */
	--jb-space-1: 0.25rem;
	--jb-space-2: 0.5rem;
	--jb-space-3: 0.75rem;
	--jb-space-4: 1rem;
	--jb-space-5: 1.5rem;
	--jb-space-6: 2rem;
	--jb-space-7: clamp(2.5rem, 2rem + 2vw, 4rem);
	--jb-space-8: clamp(4rem, 3rem + 4vw, 7rem);
	--jb-space-9: clamp(5rem, 3.5rem + 6vw, 9rem);

	/* Layout */
	--jb-gutter: clamp(0.75rem, 0.5rem + 1vw, 1.25rem);   /* comic gutter between panels */
	--jb-margin: clamp(1rem, 0.2rem + 4vw, 4.5rem);
	--jb-max: 84rem;

	/* Comic surfaces */
	--jb-border: 4px solid var(--jb-ink);
	--jb-shadow: 6px 6px 0 var(--jb-ink);
	--jb-radius-l: 14px;
	--jb-radius-m: 10px;
	--jb-shadow-frame: 6px 6px 0 var(--jb-ink);

	/* Motion: one easing curve throughout */
	--jb-ease: cubic-bezier(0.22, 1, 0.36, 1);
	--jb-dur-fast: 400ms;
	--jb-dur: 550ms;
	--jb-dur-slow: 700ms;

	--jb-z-rail: 40;
	--jb-z-cta: 50;
}

@media (max-width: 47.99em) {
	:root {
		--jb-border: 3px solid var(--jb-ink);
		--jb-shadow: 4px 4px 0 var(--jb-ink);
	}
}

@media (prefers-reduced-motion: reduce) {
	:root {
		--jb-dur-fast: 1ms;
		--jb-dur: 1ms;
		--jb-dur-slow: 1ms;
	}
}
