/*
 * Viewport tokens: tablet and mobile values of the Figma "Viewport" collection.
 * Desktop values are the defaults in theme.json (settings.custom). Only this file
 * and theme.json may contain raw pixel values.
 *
 * Breakpoints: mobile < 768px, tablet 768px to 1023px, desktop >= 1024px.
 */

/*
 * Presets that point at a viewport token. WordPress declares presets on :root, where var() resolves
 * once with the desktop value, so the body overrides below never reached has-display-font-size or the
 * section-y paddings. Declaring them again on body makes them resolve against the body values.
 */
body {
	--wp--preset--font-size--lead: var(--wp--custom--type--lead);
	--wp--preset--font-size--display: var(--wp--custom--type--display);
	--wp--preset--spacing--grid-gap: var(--wp--custom--grid-gap);
	--wp--preset--spacing--section-gap: var(--wp--custom--section-gap);
	--wp--preset--spacing--section-y-small: var(--wp--custom--section-y-small);
	--wp--preset--spacing--section-y: var(--wp--custom--section-y);
	--wp--preset--spacing--section-y-big: var(--wp--custom--section-y-big);
	--wp--preset--spacing--gutter: var(--wp--custom--gutter);
}

@media (max-width: 1023px) {
	body {
		--wp--custom--gutter: var(--wp--custom--spacing--8);          /* 32 */
		--wp--custom--section-y: var(--wp--custom--spacing--18);      /* 72 */
		--wp--custom--section-y-small: var(--wp--custom--spacing--12);/* 48 */
		--wp--custom--section-y-big: var(--wp--custom--spacing--24);  /* 96 */
		--wp--custom--section-gap: var(--wp--custom--spacing--10);    /* 40 */
		--wp--custom--grid-gap: var(--wp--custom--spacing--6);        /* 24 */
		--wp--custom--section-min--hero: 0px;
		--wp--custom--section-min--cta: 600px;
		--wp--custom--layout--hero-video: 300px;
		--wp--custom--layout--about-media: 360px;
		--wp--custom--type--display: var(--wp--custom--font-size--52);
		--wp--custom--type--heading-1: var(--wp--custom--font-size--44);
		--wp--custom--type--heading-2: var(--wp--custom--font-size--36);
		--wp--custom--type--heading-3: var(--wp--custom--font-size--22);
		--wp--custom--type--heading-4: var(--wp--custom--font-size--18);
		--wp--custom--type--lead: var(--wp--custom--font-size--18);
	}
}

@media (max-width: 767px) {
	body {
		--wp--custom--gutter: var(--wp--custom--spacing--5);          /* 20 */
		--wp--custom--section-y: var(--wp--custom--spacing--14);      /* 56 */
		--wp--custom--section-y-small: var(--wp--custom--spacing--10);/* 40 */
		--wp--custom--section-y-big: var(--wp--custom--spacing--18);  /* 72 */
		--wp--custom--section-gap: var(--wp--custom--spacing--8);     /* 32 */
		--wp--custom--grid-gap: var(--wp--custom--spacing--4);        /* 16 */
		--wp--custom--section-min--hero: 0px;
		--wp--custom--section-min--cta: 600px;
		--wp--custom--layout--hero-video: 240px;
		--wp--custom--layout--about-media: 220px;
		--wp--custom--type--display: var(--wp--custom--font-size--40);
		--wp--custom--type--heading-1: var(--wp--custom--font-size--36);
		--wp--custom--type--heading-2: var(--wp--custom--font-size--28);
		--wp--custom--type--heading-3: var(--wp--custom--font-size--20);
		--wp--custom--type--heading-4: var(--wp--custom--font-size--18);
		--wp--custom--type--lead: var(--wp--custom--font-size--18);
	}
}
