:root {
  --ink: #161616;
  --muted: #4a4a4a;
  --line: #e6e6e6;
  --chip: #f3f3f3;
  --button: #2a2a2a;
  --paper: #ffffff;
  --shadow: 0 1px 0 rgba(0, 0, 0, 0.02);
  --radius: 18px;
  --max: 1120px;
  --font: Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

a { color: inherit; }

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  background: var(--ink);
  color: white;
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 5;
}

.skip:focus { top: 12px; }

.wrap {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.top {
  padding: 28px 0 18px;
}

.top-rule {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--chip);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
}

.brand:hover { background: #e9e9e9; }

.brand:focus-visible,
.btn:focus-visible,
.text-link:focus-visible,
.project-media:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

main { padding: 28px 0 64px; }

.intro {
  display: grid;
  grid-template-columns: 1.05fr 1.25fr 0.85fr;
  gap: 16px;
  align-items: stretch;
}

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.hero {
  display: flex;
  flex-direction: column;
  padding: 14px 14px 22px;
  min-height: 100%;
}

.hero-art {
  position: relative;
}

.hero-art .brush {
  width: 100%;
  height: 188px;
  object-fit: cover;
  border-radius: 12px;
}

.hero-art .avatar {
  position: absolute;
  left: 14px;
  bottom: -34px;
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 4px solid #fff;
  object-fit: cover;
  object-position: center 42%;
  background: #ddd;
}

.hero h1 {
  margin: auto 0 0;
  padding: 52px 10px 4px;
  font-size: clamp(32px, 3vw, 44px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 700;
}

.panel { padding: 22px 22px 20px; }

.panel h2,
.project-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.panel p {
  margin: 12px 0 0;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.55;
}

#contact { align-self: start; }

.about {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.about h2 {
  max-width: 10em;
  font-size: clamp(26px, 2.4vw, 32px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.about p { margin-top: 16px; }

.contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  padding: 0 16px;
  border-radius: 12px;
  background: var(--button);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
}

.btn:hover { background: #111; }

.work { margin-top: 54px; }

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.projects {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 18px;
}

.project {
  display: grid;
  grid-template-columns: minmax(280px, 0.92fr) 1.15fr;
  gap: 22px 28px;
  padding: 22px;
  align-items: center;
}

.project-head {
  display: flex;
  gap: 14px;
  align-items: center;
}

.logo {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: cover;
  background: #f6f6f6;
  border: 1px solid var(--line);
  flex: none;
}

.project-head p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.project-copy > p {
  margin: 18px 0 0;
  font-size: 15px;
}

.facts {
  display: grid;
  gap: 14px;
  margin: 20px 0 0;
}

.facts div { display: grid; gap: 2px; }

.facts dt {
  font-size: 13px;
  color: var(--muted);
}

.facts dd { margin: 0; font-size: 15px; }

.facts a { color: var(--ink); }

.text-link {
  display: inline-flex;
  margin-top: 18px;
  font-weight: 600;
  font-size: 15px;
  text-underline-offset: 3px;
}

.text-link:hover { text-decoration-thickness: 2px; }

.project-media {
  display: block;
  align-self: start;
  width: 100%;
  aspect-ratio: 1200 / 630;
  border-radius: 14px;
  overflow: hidden;
  background: #f4f4f4;
}

.project-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.35s ease;
}

.project-media:hover img { transform: scale(1.015); }

.back {
  display: inline-flex;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.back:hover { color: var(--ink); }

.lede {
  max-width: 38rem;
  margin: 12px 0 0;
  font-size: 18px;
  line-height: 1.45;
}

.frame {
  margin: 0;
}

.frame img {
  width: 100%;
  height: auto;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: #fafafa;
}

.stack {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.stack li + li { margin-top: 12px; }

.essay-head { max-width: 40rem; }

.essay-head .logo { margin-bottom: 18px; }

.byline {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 15px;
}

.byline a {
  color: inherit;
  font-weight: 600;
}

.stage {
  display: flex;
  justify-content: center;
  margin: 36px 0 0;
  padding: 48px 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #f6f1ea;
}

.stage img {
  width: min(100%, 340px);
  height: auto;
  border-radius: 22px;
  box-shadow: 0 16px 40px rgba(22, 22, 22, 0.08);
}

.chapter {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
  margin-top: 72px;
}

.chapter-copy { max-width: 40rem; }

.chapter h2 {
  margin: 0;
  max-width: 11em;
  color: var(--ink);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.12;
  text-transform: none;
  text-wrap: balance;
}

.lede,
.byline,
.chapter-copy p,
.shipped li,
.panel p,
.project-copy > p {
  text-wrap: pretty;
}

.chapter-copy p {
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
}

.chapter-copy p + p { margin-top: 12px; }

.chapter .stage,
.chapter .frame {
  align-self: stretch;
  width: 100%;
  margin-top: 12px;
}

.essay > .frame { width: 100%; }

.shipped {
  max-width: 40rem;
  margin-top: 64px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.shipped h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.03em;
}

.shipped .stack { margin-top: 16px; }

.next-project {
  margin: 36px 0 0;
  font-size: 15px;
  font-weight: 600;
}

.next-project a { text-underline-offset: 3px; }

.site-footer {
  padding: 8px 0 36px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 980px) {
  .intro { grid-template-columns: 1fr 1fr; }
  .hero { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .wrap { width: min(var(--max), calc(100% - 28px)); }
  .intro,
  .project { grid-template-columns: 1fr; }
  .hero { grid-column: auto; }
  .hero h1 { font-size: 36px; }
  .panel { padding-left: 16px; padding-right: 16px; }
}

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