/* Reset mínimo y elementos base. */

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

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
	margin: 0;
	background: var(--color-bg);
	color: var(--color-text);
	font-family: var(--font-sans);
	font-size: var(--text-base);
	line-height: 1.65;
	font-feature-settings: "cv11", "ss01";
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

h1, h2, h3 {
	margin: 0 0 var(--space-3);
	line-height: 1.12;
	letter-spacing: -0.03em;
	font-weight: 650;
	text-wrap: balance;
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); letter-spacing: -0.02em; }

p, ul, ol { margin: 0 0 var(--space-4); }

ul, ol { padding-left: 1.25rem; }

a {
	color: var(--color-brand);
	text-underline-offset: 0.2em;
	text-decoration-thickness: 1px;
}

a:hover { text-decoration-thickness: 2px; }

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

::selection { background: var(--glow); }

:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 3px;
	border-radius: 4px;
}

code, pre {
	font-family: var(--font-mono);
	font-size: 0.9em;
}

pre { overflow-x: auto; }

.visually-hidden {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

.skip-link {
	position: absolute;
	left: var(--space-4);
	top: -4rem;
	z-index: 100;
	padding: var(--space-2) var(--space-4);
	background: var(--color-brand-solid);
	color: var(--color-on-brand-solid);
	border-radius: var(--radius-sm);
}

.skip-link:focus { top: var(--space-4); }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		animation-delay: 0ms !important;
		transition-duration: 0.01ms !important;
	}
}
