/* bchn.io — "Quiet Index" (variant 1A from Claude Design). No JavaScript. */

@font-face {
  font-family: "Geist";
  src: url("/assets/fonts/Geist-var.woff2") format("woff2");
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("/assets/fonts/GeistMono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f6f4ef;
  --ink: #1c1b19;
  --muted: #66625a;
  --rule: #dedad1;
  --thumb: #efe9dc;
  --accent: #0058db;
  --underline: #0066ff;
  --hover: rgba(28, 27, 25, 0.035);
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.65;
  padding: 0 24px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
p { margin: 0; }
img { display: block; max-width: 100%; height: auto; }

.page { max-width: 640px; margin: 0 auto; padding: 120px 0 64px; }

.muted { color: var(--muted); }
.mono { font-family: var(--mono); font-size: 12px; color: var(--muted); }

/* Header */
.intro { display: flex; flex-direction: column; gap: 2px; margin-bottom: 64px; }
.intro h1 { margin: 0; font-size: 15px; font-weight: 500; }

/* About */
.about { display: flex; flex-direction: column; gap: 16px; margin-bottom: 64px; text-wrap: pretty; }

/* Projects */
.projects { margin-bottom: 80px; }
.projects .label { margin: 0 0 12px; font-weight: 400; }
.project-list { display: flex; flex-direction: column; border-top: 1px solid var(--rule); }

.row {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) 20px;
  gap: 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
}
.row .num { padding-top: 2px; }
.row .body { display: flex; flex-direction: column; gap: 2px; }
.row .title { font-weight: 500; }
.row .desc { color: var(--muted); text-wrap: pretty; }

a.row {
  position: relative;
  padding: 18px 12px 20px;
  margin: 0 -12px;
  border-bottom: 0;
  border-radius: 8px;
  transition: background-color 0.15s ease;
}
/* Keep the row rule aligned with the column while the hover area bleeds 12px. */
a.row::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 1px;
  background: var(--rule);
}
a.row:hover, a.row:focus-visible { background: var(--hover); }
a.row:focus-visible { outline: 2px solid var(--underline); outline-offset: 2px; }
.row .arrow {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--accent);
  padding-top: 1px;
  transition: transform 0.15s ease;
}
a.row:hover .arrow { transform: translateX(3px); }

.thumb {
  display: block;
  margin-top: 14px;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--rule);
  background: var(--thumb);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }

/* Footer */
.site-footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
}
.site-footer nav { display: flex; gap: 8px; }
.link-u {
  text-decoration: underline;
  text-decoration-color: var(--underline);
  text-underline-offset: 3px;
}
.link-u:hover { color: var(--ink); }

/* Case study */
.back { display: inline-block; margin-bottom: 64px; }
.back:hover { color: var(--ink); }
.case-head { display: flex; flex-direction: column; gap: 6px; margin-bottom: 40px; }
.case-head h1 { margin: 0; font-size: 22px; font-weight: 500; line-height: 1.3; letter-spacing: -0.01em; }
.case-head .lede { color: var(--muted); text-wrap: pretty; }
.case-shot { margin: 0 0 56px; }
.case-shot .thumb { margin-top: 0; }
.case-shot figcaption { margin-top: 10px; }
.case section { margin-bottom: 44px; }
.case h2 { margin: 0 0 12px; font-family: var(--mono); font-size: 12px; font-weight: 400; color: var(--muted); }
.case section > p + p { margin-top: 14px; }
.case ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.case li { text-wrap: pretty; }
.case strong { font-weight: 500; }
.case .after-p { margin-top: 12px; }

@media (max-width: 520px) {
  .page { padding-top: 72px; }
  .intro, .about { margin-bottom: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
