/* =========================================================
   Base / Reset
   ========================================================= */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  -webkit-text-size-adjust: 100%;
  background: var(--night-0);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--moon);
  background: var(--night-0);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg,
canvas {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.03em;
  margin: 0;
}

h2 {
  font-size: var(--fs-h2);
}

h3 {
  font-size: var(--fs-h3);
  letter-spacing: -0.015em;
  line-height: 1.2;
}

p {
  margin: 0 0 1em;
}

em {
  font-style: normal;
  color: var(--ember);
}

.mono {
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}

::selection {
  background: var(--ember);
  color: var(--night-0);
}

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: min(100% - var(--gutter) * 2, var(--container));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: -100px;
  z-index: 1000;
  padding: 0.6rem 1rem;
  background: var(--ember);
  color: var(--night-0);
  border-radius: 8px;
  font-weight: 700;
}

.skip-link:focus {
  top: 1rem;
}

/* Scrollbar */
html {
  scrollbar-color: var(--night-4) var(--night-0);
}

::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--night-0);
}

::-webkit-scrollbar-thumb {
  background: var(--night-4);
  border-radius: 10px;
  border: 2px solid var(--night-0);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--ember-deep);
}
