:root {
  color-scheme: dark;
  --background: #090909;
  --foreground: #f2f0e9;
  --muted: #b5b5ae;
  --line: #30302e;
  --page-width: 80rem;
  --font-serif: Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

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

body {
  min-width: 20rem;
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  -webkit-font-smoothing: antialiased;
}

.page {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100svh;
  width: min(calc(100% - 3rem), var(--page-width));
  margin-inline: auto;
}

.page > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--line);
}

.page > main {
  display: grid;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--foreground);
  text-decoration: none;
}

.brand img {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
}

h1 {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.email,
.projects p,
.legal {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.76rem;
}

.email,
.projects p {
  letter-spacing: 0.06em;
}

.email,
.privacy a,
.legal a {
  text-decoration-color: transparent;
}

.email {
  text-underline-offset: 0.25em;
}

.email:hover,
.email:focus-visible,
.privacy a:hover,
.privacy a:focus-visible,
.legal a:hover,
.legal a:focus-visible {
  color: var(--foreground);
  text-decoration-color: currentColor;
}

.projects,
.not-found {
  display: grid;
  place-content: center;
  text-align: center;
}

.projects,
.not-found,
.privacy {
  padding-block: 5rem;
}

.projects p {
  margin: 0 0 3.5rem;
  text-transform: uppercase;
}

.projects nav {
  display: flex;
  flex-direction: column;
  align-items: baseline;
  gap: 1.5rem;
}

.projects nav a,
.not-found h2,
.privacy h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 0.9;
}

.projects nav a,
.not-found h2 {
  font-size: clamp(3.5rem, 8vw, 8rem);
  letter-spacing: -0.07em;
}

.projects nav a {
  color: var(--foreground);
  text-decoration-color: var(--line);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.12em;
  transition: text-decoration-color 140ms ease;
}

.projects nav a:hover,
.projects nav a:focus-visible {
  text-decoration-color: var(--foreground);
}

.not-found {
  justify-items: center;
}

.not-found h2 {
  margin: 0;
}

.privacy {
  width: min(100%, 44rem);
  margin-inline: auto;
}

.privacy h2 {
  margin: 0 0 4rem;
  font-size: clamp(3.5rem, 8vw, 7rem);
  letter-spacing: -0.06em;
}

.privacy section + section {
  margin-top: 3rem;
}

.privacy h3 {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.privacy p {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

.privacy a {
  color: var(--foreground);
  text-underline-offset: 0.2em;
}

.legal a {
  color: inherit;
  text-underline-offset: 0.2em;
}

.legal {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--line);
  letter-spacing: 0.015em;
  line-height: 1.5rem;
}

.legal address {
  margin: 0;
  font-style: normal;
}

@media (max-width: 44rem) {
  .page {
    width: min(calc(100% - 2rem), var(--page-width));
  }

  .page > header {
    align-items: flex-start;
    gap: 1rem;
  }

  .projects nav a {
    font-size: clamp(3.2rem, 16vw, 5rem);
  }

  .legal {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }
}
