/*
 * De basis: reset, typografie, focus en de dingen die overal gelden.
 */

/*
 * De letters staan hier zelf, want de site doet geen enkel extern verzoek.
 * EB Garamond en Source Sans 3 zijn allebei variabele fonts onder de SIL Open
 * Font License, dus één bestand per stijl draagt het hele gewichtsbereik.
 */

@font-face {
	font-family: "EB Garamond";
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
	src: url("../fonts/kop-normal-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: "EB Garamond";
	font-style: italic;
	font-weight: 400 700;
	font-display: swap;
	src: url("../fonts/kop-italic-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: "Source Sans 3";
	font-style: normal;
	font-weight: 400 700;
	font-display: swap;
	src: url("../fonts/tekst-normal-latin.woff2") format("woff2");
	/* Source Sans oogt klein voor zijn maat; hiermee valt de systeemletter er
	   tijdens het laden niet naast en springt de tekst niet. */
	size-adjust: 102%;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

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

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

body {
	margin: 0;
	background: var(--kleur-grond);
	color: var(--kleur-tekst);
	font-family: var(--font-tekst);
	font-size: var(--maat-tekst);
	line-height: var(--regelhoogte);
	-webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
	margin: 0 0 var(--r3);
	font-family: var(--font-kop);
	font-weight: 600;
	letter-spacing: 0.005em;
	line-height: var(--regelhoogte-kop);
	text-wrap: balance;
}

h1 { font-size: var(--maat-h1); }
h2 { font-size: var(--maat-h2); }
h3 { font-size: var(--maat-h3); }

p,
ul,
ol,
dl {
	margin: 0 0 var(--r4);
}

p {
	text-wrap: pretty;
}

a {
	color: var(--kleur-primair-donker);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.18em;
}

a:hover {
	color: var(--kleur-accent-donker);
}

img,
svg,
video {
	max-width: 100%;
	height: auto;
}

img {
	display: block;
}

/* Zichtbare focus, ook op elementen die de browser standaard stil houdt. */
:focus-visible {
	outline: 3px solid var(--kleur-focus);
	outline-offset: 2px;
	border-radius: var(--radius-klein);
}

/* De sticky kop mag een gefocust element niet afdekken. */
:target,
[id] {
	scroll-margin-top: calc(var(--headerhoogte) + var(--r4));
}

.verborgen {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.overslaan {
	position: absolute;
	top: var(--r2);
	left: var(--r2);
	z-index: 100;
	padding: var(--r2) var(--r4);
	background: var(--kleur-vlak);
	color: var(--kleur-tekst);
	border-radius: var(--radius);
	box-shadow: var(--schaduw-op);
	transform: translateY(-160%);
}

.overslaan:focus {
	transform: none;
}

.pictogram {
	flex: none;
	width: 1.25em;
	height: 1.25em;
}

@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;
	}
}
