:root {
  color-scheme: dark;
  --background: #1f0f0b;
  --surface: #281712;
  --surface-high: #382620;
  --text: #fcdcd3;
  --muted: #e6beb2;
  --outline: #5c4037;
  --accent: #ff571a;
  --accent-soft: #ffb59e;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    linear-gradient(rgba(255, 87, 26, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 87, 26, .035) 1px, transparent 1px),
    var(--background);
  background-size: 44px 44px;
}

a { color: inherit; }
a:focus-visible { outline: 2px solid var(--accent-soft); outline-offset: 5px; }

header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(255, 87, 26, .22);
  background: rgba(31, 15, 11, .92);
  backdrop-filter: blur(18px);
}

nav, main, footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
nav { min-height: 76px; display: flex; align-items: center; gap: 28px; }
nav a { text-decoration: none; color: var(--muted); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; }
nav a:hover, nav a[aria-current="page"] { color: var(--accent-soft); }
nav .brand { margin-right: auto; color: var(--text); font-family: Georgia, "Times New Roman", serif; font-size: 1.05rem; font-weight: 800; letter-spacing: .02em; }

main { padding: 104px 0 80px; }
.intro { max-width: 900px; margin-bottom: 84px; }
.eyebrow { margin: 0 0 18px; color: var(--accent); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; }
h1, h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; letter-spacing: -.035em; }
h1 { font-size: clamp(3.3rem, 8.8vw, 7.7rem); line-height: .88; }
.lede { max-width: 650px; margin: 34px 0 0; color: var(--muted); font-family: system-ui, sans-serif; font-size: clamp(1.08rem, 2vw, 1.35rem); line-height: 1.7; }

.projects { border-top: 1px solid var(--outline); }
.project {
  position: relative;
  display: grid;
  grid-template-columns: minmax(90px, .55fr) minmax(0, 2.4fr);
  gap: 40px;
  padding: 58px 0 64px;
  border-bottom: 1px solid var(--outline);
  overflow: hidden;
}
.project::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, transparent, rgba(255, 87, 26, .08));
  opacity: 0;
  transform: translateX(-12%);
  transition: opacity .25s ease, transform .35s ease;
}
.project:hover::after { opacity: 1; transform: translateX(0); }
.project-number { color: var(--accent); font-size: .8rem; letter-spacing: .15em; padding-top: 13px; }
.project-meta { display: flex; justify-content: space-between; gap: 18px; margin-bottom: 18px; color: var(--muted); font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; }
.project h2 { font-size: clamp(2.65rem, 6vw, 5.2rem); line-height: .95; }
.project p { max-width: 720px; margin: 24px 0 28px; color: var(--muted); font-family: system-ui, sans-serif; font-size: 1.05rem; line-height: 1.7; }
.project-link, .closing a { display: inline-flex; gap: 10px; align-items: center; color: var(--accent-soft); font-size: .8rem; letter-spacing: .08em; text-decoration-thickness: 1px; text-underline-offset: 7px; text-transform: uppercase; }
.project-link:hover, .closing a:hover { color: var(--text); }
.project-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.secondary-link { color: var(--muted); font-size: .76rem; text-underline-offset: 6px; }
.secondary-link:hover { color: var(--text); }

.closing { margin: 110px 0 70px; padding: 58px; border: 1px solid rgba(255, 87, 26, .42); background: linear-gradient(130deg, var(--surface), var(--surface-high)); }
.closing h2 { margin-bottom: 32px; font-size: clamp(2.4rem, 5vw, 4.5rem); }

footer { display: flex; justify-content: space-between; gap: 24px; padding: 30px 0 42px; border-top: 1px solid var(--outline); color: var(--muted); font-size: .72rem; letter-spacing: .08em; }
footer a { text-underline-offset: 5px; }

@media (max-width: 680px) {
  nav, main, footer { width: min(100% - 28px, 1180px); }
  nav { gap: 16px; }
  nav a { font-size: .62rem; }
  main { padding-top: 72px; }
  .intro { margin-bottom: 60px; }
  .project { grid-template-columns: 1fr; gap: 14px; padding: 42px 0 48px; }
  .project-number { padding: 0; }
  .project-meta { flex-direction: column; gap: 7px; }
  .closing { margin: 72px 0 50px; padding: 36px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .project::after { transition: none; }
}
