:root {
  color-scheme: light;
  --page: #f5f6f2;
  --surface: #fff;
  --surface-soft: #edf0e9;
  --ink: #20251f;
  --muted: #656d63;
  --quiet: #7d857a;
  --line: #dce1d8;
  --accent: #c3ec76;
  --accent-ink: #28331c;
  --header: rgb(245 246 242 / 94%);
  --shadow: 0 12px 32px rgb(23 35 18 / 5%);
  --font: "DM Sans", sans-serif;
  --display: "Manrope", sans-serif;
  font-family: var(--font);
  color: var(--ink);
  background: var(--page);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --page: #11130f;
  --surface: #191c17;
  --surface-soft: #20241d;
  --ink: #e8e8e2;
  --muted: #b6bdb0;
  --quiet: #929a8b;
  --line: #343a30;
  --accent: #c3ec76;
  --accent-ink: #20271b;
  --header: rgb(17 19 15 / 94%);
  --shadow: 0 12px 32px rgb(0 0 0 / 18%);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 85px;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  transition: background-color 180ms ease, color 180ms ease;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid #76934c;
  outline-offset: 4px;
}

button {
  color: inherit;
  font: inherit;
}

.page-shell {
  width: min(1120px, calc(100% - 64px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 3;
  top: 0;
  display: flex;
  min-height: 76px;
  align-items: center;
  gap: 30px;
  border-bottom: 1px solid var(--line);
  background: var(--header);
  backdrop-filter: blur(14px);
}

.wordmark {
  flex: 0 0 auto;
  color: var(--ink);
  font-family: var(--display);
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -0.5px;
}

.theme-toggle,
.menu-toggle,
.nav-contact {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: transparent;
  color: var(--ink);
  font-size: 11px;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease;
}

.theme-toggle {
  margin-left: auto;
}

.theme-toggle:hover,
.menu-toggle:hover,
.nav-contact:hover {
  border-color: var(--quiet);
  background: var(--surface-soft);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 27px;
  color: var(--muted);
  font-size: 12px;
}

.site-nav > a:not(.nav-contact):hover,
.text-link:hover,
.footer-link:hover {
  color: var(--ink);
}

.nav-contact {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
}

.menu-toggle {
  display: none;
}

main {
  display: block;
}

.hero {
  display: flex;
  min-height: 510px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.hero-copy {
  max-width: 760px;
  padding: 76px 0 84px;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

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

h1,
h2,
h3 {
  color: var(--ink);
  font-family: var(--display);
}

h1 {
  margin-bottom: 22px;
  font-size: clamp(58px, 9vw, 104px);
  font-weight: 650;
  letter-spacing: -0.075em;
  line-height: 1;
}

.hero-description {
  max-width: 530px;
  margin-bottom: 25px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 22px;
}

.button {
  display: inline-flex;
  min-height: 43px;
  align-items: center;
  justify-content: center;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 650;
  transition: background-color 150ms ease, transform 150ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.button-primary:hover {
  background: #d0f18f;
}

.text-link,
.footer-link {
  color: var(--muted);
  font-size: 12px;
  transition: color 150ms ease;
}

.hero-note {
  margin: 34px 0 0;
  color: var(--quiet);
  font-size: 12px;
}

.section-wrap {
  width: min(100% - 64px, 1040px);
  margin-inline: auto;
}

.work-section {
  padding-block: 92px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.section-heading .eyebrow,
.about-intro .eyebrow {
  margin-bottom: 10px;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(32px, 4vw, 46px);
  font-weight: 650;
  letter-spacing: -0.06em;
  line-height: 1.12;
}

.section-link {
  flex: 0 0 auto;
  margin-bottom: 5px;
}

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

.project-card {
  display: block;
  min-width: 0;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.project-card:hover {
  transform: translateY(-2px);
  border-color: var(--quiet);
  box-shadow: var(--shadow);
}

.project-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 28px;
  color: var(--quiet);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.project-meta span:last-child {
  color: #638044;
}

:root[data-theme="dark"] .project-meta span:last-child {
  color: #bdd39a;
}

.project-title-row h3 {
  margin-bottom: 10px;
  font-size: 24px;
  font-weight: 650;
  letter-spacing: -0.05em;
}

.project-card > p {
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-list span {
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  font-size: 10px;
}

.about-section {
  border-top: 1px solid var(--line);
  background: var(--surface-soft);
}

.about-inner {
  display: grid;
  min-height: 320px;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
  gap: 60px;
  padding-block: 68px;
}

.about-copy {
  max-width: 510px;
}

.about-lead {
  margin-bottom: 12px;
  color: var(--ink);
  font-family: var(--display);
  font-size: 16px;
  font-weight: 650;
}

.about-copy > p:not(.about-lead) {
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}

.button-outline {
  margin-top: 3px;
  border-color: var(--line);
  color: var(--ink);
}

.button-outline:hover {
  background: var(--page);
}

.site-footer {
  display: flex;
  min-height: 82px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.site-footer > p,
.copyright {
  margin: 0;
  color: var(--quiet);
  font-size: 11px;
}

.footer-wordmark {
  font-size: 13px;
}

.copyright {
  white-space: nowrap;
}

@media (max-width: 760px) {
  html {
    scroll-padding-top: 68px;
  }

  .page-shell {
    width: calc(100% - 40px);
  }

  .section-wrap {
    width: calc(100% - 40px);
  }

  .site-header {
    min-height: 66px;
    gap: 10px;
  }

  .wordmark {
    font-size: 14px;
  }

  .theme-toggle,
  .menu-toggle {
    min-height: 34px;
    padding-inline: 9px;
    font-size: 10px;
  }

  .menu-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 1px);
    right: -20px;
    left: -20px;
    display: none;
    align-items: stretch;
    gap: 0;
    padding: 8px 20px 16px;
    border-bottom: 1px solid var(--line);
    background: var(--page);
  }

  .site-nav.is-open {
    display: flex;
    flex-direction: column;
  }

  .site-nav > a:not(.nav-contact) {
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
  }

  .site-nav .nav-contact {
    align-self: flex-start;
    margin-top: 12px;
  }

  .hero {
    min-height: 430px;
  }

  .hero-copy {
    padding-block: 64px;
  }

  h1 {
    font-size: clamp(54px, 12vw, 78px);
  }

  .hero-description {
    font-size: 14px;
  }

  .work-section {
    padding-block: 68px;
  }

  .section-heading {
    align-items: start;
  }

  h2 {
    font-size: 34px;
  }

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

  .project-card {
    padding: 21px 18px;
  }

  .project-meta {
    margin-bottom: 23px;
    font-size: 9px;
  }

  .about-inner {
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 22px;
    padding-block: 54px;
  }

  .site-footer {
    min-height: 76px;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 10px 18px;
    padding-block: 20px;
  }

  .site-footer > p {
    width: 100%;
    order: 2;
  }

  .footer-link {
    margin-left: auto;
  }

  .copyright {
    width: 100%;
    order: 3;
  }
}

@media (max-width: 380px) {
  .section-heading {
    flex-direction: column;
  }

  .theme-toggle,
  .menu-toggle {
    padding-inline: 7px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
