@font-face {
  font-family: "Playfair Display";
  src: url("fonts/playfair-display-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Playfair Display";
  src: url("fonts/playfair-display-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* Every colour on the site lives here. Rebrand by changing these. */
:root {
  color-scheme: light dark;
  --bg: #f6f4f0;
  --text: #1c1b19;
  --dim: #6f6c66;
  --rule: #dcd8d0;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141312;
    --text: #ece9e3;
    --dim: #98948c;
    --rule: #2c2a27;
  }
}

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

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

body {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: calc(40rem + 2 * clamp(1rem, 6vw, 3rem));
  min-height: 100vh;
  min-height: 100svh;
  margin: 0 auto;
  padding: clamp(4rem, 16vh, 10rem) clamp(1rem, 6vw, 3rem) 2.5rem;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

main {
  flex: 1;
}

h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(3.25rem, 13vw, 5.5rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.lede {
  margin: 1rem 0 0;
  color: var(--dim);
  font-size: 1.0625rem;
}

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

.lede a:hover {
  color: var(--text);
}

section {
  margin-top: clamp(4rem, 12vh, 7rem);
}

h2 {
  margin: 0;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--rule);
  color: var(--dim);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.items {
  margin: 0;
  padding: 0;
  list-style: none;
}

.items li {
  border-bottom: 1px solid var(--rule);
}

.item {
  display: flex;
  align-items: center;
  gap: 1.125rem;
  padding: 1.25rem 0;
  color: inherit;
  text-decoration: none;
}

.item img {
  flex: none;
  display: block;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  image-rendering: pixelated;
}

.item-text {
  flex: 1;
  min-width: 0;
}

.item-title {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 400;
  line-height: 1.25;
}

.item-line {
  display: block;
  margin-top: 0.125rem;
  color: var(--dim);
  font-size: 0.9375rem;
}

.arrow {
  flex: none;
  color: var(--dim);
  font-size: 1.25rem;
  transition: transform 180ms ease, color 180ms ease;
}

.item:hover .arrow {
  color: var(--text);
  transform: translate(3px, -3px);
}

.empty {
  padding: 1.25rem 0;
  color: var(--dim);
}

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

footer {
  margin-top: 4rem;
  color: var(--dim);
  font-size: 0.8125rem;
}

@media (prefers-reduced-motion: reduce) {
  .arrow {
    transition: none;
  }

  .item:hover .arrow {
    transform: none;
  }
}
