:root {
  --background: #fafaf8;
  --text: #1a1a1a;
  --muted: #5f5f5a;
  --border: #deded8;
  --accent: #3a5a8c;
  --accent-hover: #273f66;
  --content-width: 720px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--background);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.7;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

a:hover,
a:focus-visible {
  color: var(--accent-hover);
}

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

.site-header,
main,
.site-footer {
  width: min(var(--content-width), calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 0 72px;
}

.wordmark {
  color: var(--text);
  font-family: Fraunces, Georgia, "Times New Roman", serif;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.1;
  text-decoration: none;
}

nav a {
  font-size: 15px;
  font-weight: 500;
}

section {
  padding: 0 0 72px;
}

.hero {
  padding-bottom: 86px;
}

.hero.compact {
  max-width: 620px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 700px;
  margin-bottom: 20px;
  font-family: Fraunces, Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 8vw, 68px);
  font-weight: 500;
  line-height: 1.03;
}

h2 {
  margin-bottom: 14px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
}

h3 {
  margin-bottom: 10px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
}

p {
  margin-bottom: 0;
  color: var(--muted);
}

.hero p {
  max-width: 560px;
  color: var(--text);
  font-size: 20px;
  line-height: 1.55;
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.work-card {
  min-height: 228px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.work-card p {
  font-size: 15px;
  line-height: 1.6;
}

.site-footer {
  padding: 16px 0 42px;
  border-top: 1px solid var(--border);
}

.site-footer p {
  font-size: 14px;
  line-height: 1.6;
}

@media (max-width: 760px) {
  body {
    font-size: 16px;
  }

  .site-header,
  main,
  .site-footer {
    width: min(var(--content-width), calc(100% - 32px));
  }

  .site-header {
    padding: 26px 0 56px;
  }

  section,
  .hero {
    padding-bottom: 58px;
  }

  h1 {
    font-size: clamp(38px, 13vw, 54px);
  }

  .hero p {
    font-size: 18px;
  }

  .work-grid {
    grid-template-columns: 1fr;
  }

  .work-card {
    min-height: auto;
  }
}
