:root {
  color-scheme: light;
  --bg: #f5f0e8;
  --fg: #171b17;
  --muted: rgba(23, 27, 23, 0.18);
  --soft: rgba(23, 27, 23, 0.055);
  --line: rgba(23, 27, 23, 0.12);
  --accent: #a96e54;
  --fit: 4.35;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100svh;
  overflow: hidden;
  background: var(--bg);
  color: var(--fg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body::before,
body::after {
  position: fixed;
  content: "";
  pointer-events: none;
}

body::before {
  inset: 1.15rem;
  border: 1px solid var(--line);
}

body::after {
  right: clamp(1.8rem, 5vw, 5rem);
  bottom: clamp(1.8rem, 5vw, 5rem);
  width: clamp(7rem, 18vw, 18rem);
  height: 1px;
  background: var(--fg);
  opacity: 0.28;
}

canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
}

main {
  position: relative;
  display: grid;
  min-height: 100svh;
  align-items: end;
  justify-items: start;
  padding: clamp(2.5rem, 7vw, 7rem);
}

h1 {
  max-width: 100%;
  margin: 0;
  color: var(--fg);
  font-size: min(clamp(3rem, 10vw, 9rem), calc((100vw - 5rem) / var(--fit)));
  font-weight: 620;
  font-variation-settings: "wght" 620;
  letter-spacing: 0;
  line-height: 0.92;
  text-wrap: balance;
  text-shadow: 0 1rem 2.6rem rgba(23, 27, 23, 0.08);
}

h1::selection {
  background: var(--accent);
  color: var(--bg);
}

@media (max-width: 42rem) {
  main {
    padding: 2.25rem;
  }

  h1 {
    font-size: min(clamp(2.7rem, 16vw, 5.5rem), calc((100vw - 4.5rem) / var(--fit)));
  }
}
