:root {
  color-scheme: light;
  --paper: #f4f7fb;
  --surface: #ffffff;
  --ink: #15243a;
  --muted: #56677d;
  --blue: #315fce;
  --line: #d7e0ed;
}

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 4px;
}

body {
  margin: 0;
  padding: 0 clamp(1.25rem, 6vw, 6rem);
  background: var(--paper);
  color: var(--ink);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: var(--blue);
}

.site-header {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 1rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--line);
}

.site-header nav {
  display: flex;
  gap: 1.5rem;
}

.wordmark {
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 700;
  text-decoration: none;
}

main {
  max-width: 1100px;
  margin: 0 auto;
}

.intro {
  max-width: 720px;
  padding: clamp(4rem, 11vw, 8rem) 0;
}

.eyebrow,
.project-topic {
  color: var(--blue);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.project-topic {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

h1,
h2,
h3 {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.2;
}

h1 {
  max-width: 15ch;
  margin: 0.75rem 0 1rem;
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  letter-spacing: -0.045em;
}

.intro > p:last-child,
.project-card p {
  color: var(--muted);
}

#projets {
  padding-bottom: 5rem;
}

#projets h2 {
  margin-bottom: 1.5rem;
  font-size: clamp(1.7rem, 3vw, 2.25rem);
}

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

.project-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 1.5rem;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
}

.project-topic {
  align-self: flex-start;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid var(--blue);
}

.project-card h3 {
  margin: 1.25rem 0 0.25rem;
  font-size: 1.25rem;
}

.project-card p {
  flex: 1;
  margin-top: 0.5rem;
}

.project-action {
  margin-top: 1rem;
  color: var(--blue);
  font-weight: 650;
}

.project-card:hover {
  border-color: var(--blue);
  background: var(--surface);
}

.project-card:hover .project-action {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

footer {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 700px) {
  body {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
  }

  .site-header,
  .project-grid {
    grid-template-columns: 1fr;
  }

  .site-header nav {
    flex-wrap: wrap;
  }
}
