/* ===========================================================
   Shared site layout — split view used across every page.
   Left column = about rail (identical on every page).
   Right column = page-specific content.
   =========================================================== */

:root {
  --ink: #111;
  --muted: #666;
  --faint: #999;
  --rule: #ddd;
  --accent: #1a5fd0;
}
* { box-sizing: border-box; }
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  background: #fff;
  color: var(--ink);
  font-family: -apple-system, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}
body { overflow: hidden; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
.arrow { color: var(--faint); font-size: 0.85em; }

.wrap {
  display: grid;
  grid-template-columns: 340px 1px 1fr;
  max-width: 1180px;
  margin: 0 auto;
  height: 100vh;
}

/* ---- Column shell ---- */
.col-left {
  height: 100vh;
  overflow-y: auto;
  box-sizing: border-box;
  padding: 72px 48px 48px 40px;
}
.rule {
  background: #e6e6e6;   /* bare-minimum hairline divider */
  width: 1px;
  height: 100vh;
}
.col-right {
  height: 100vh;
  overflow-y: auto;
  box-sizing: border-box;
  padding: 72px 40px 48px 56px;
}

/* ---- Custom scrollbars: invisible until you scroll ----
   Panes stay scrollable, but the bar is hidden by default and a very thin
   one fades in only while scrolling (a .scrolling class is toggled by JS). */
.col-left, .col-right {
  scrollbar-width: thin;                     /* Firefox: thin track... */
  scrollbar-color: transparent transparent;  /* ...but invisible by default */
}
.col-left::-webkit-scrollbar,
.col-right::-webkit-scrollbar { width: 6px; height: 6px; }
.col-left::-webkit-scrollbar-track,
.col-right::-webkit-scrollbar-track { background: transparent; }
.col-left::-webkit-scrollbar-thumb,
.col-right::-webkit-scrollbar-thumb {
  background: transparent;
  border-radius: 999px;
  transition: background 0.3s ease;
}
/* reveal a subtle thin thumb only while actively scrolling */
.col-left.scrolling, .col-right.scrolling {
  scrollbar-color: rgba(17, 17, 17, 0.26) transparent;
}
.col-left.scrolling::-webkit-scrollbar-thumb,
.col-right.scrolling::-webkit-scrollbar-thumb {
  background: rgba(17, 17, 17, 0.26);
}

/* ---- Micro labels ---- */
.micro {
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
  font-weight: 600;
  margin: 0 0 14px 0;
}
.built-heading {
  font-size: 12px;
  letter-spacing: 0.13em;
  color: var(--ink);
  font-weight: 700;
}

/* ---- Left content ---- */
.name {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 6px 0;
  line-height: 1.1;
}
.subtitle {
  font-size: 15px;
  color: var(--muted);
  margin: 0 0 26px 0;
}
.bio {
  font-size: 14px;
  color: var(--ink);
  margin: 0 0 10px 0;
}
.bio.two { color: var(--muted); }
.block { margin-bottom: 40px; }

ul.list {
  list-style: none;
  margin: 0;
  padding: 0;
}
ul.list li {
  font-size: 14px;
  padding: 5px 0;
}
ul.list li .role {
  color: var(--faint);
  display: inline-block;
  min-width: 78px;
}

/* ---- Page nav (left rail) ---- */
ul.pagenav a { color: var(--muted); }
ul.pagenav a:hover { color: var(--ink); }
ul.pagenav li.here a { color: var(--ink); font-weight: 700; text-decoration: none; }
ul.pagenav li.here a::before {
  content: "→ ";
  color: var(--ink);
}

/* ---- Highlighted email ---- */
li.email-row .role { color: var(--ink); font-weight: 600; }
.email-hi {
  cursor: pointer;
  font-weight: 600;
  color: var(--accent);
  background: #eef3fd;
  padding: 2px 8px;
  border-radius: 5px;
}
.email-hi:hover { background: #e3ecfb; }

/* ---- notes to myself — simple underlined link ---- */
.notes-foot { margin-top: 16px; }
.notes-pill {
  font-size: 14px;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.notes-pill:hover { color: var(--accent); }

/* ---- Right: numbered index (home) ---- */
.index { margin-top: 2px; }
.row {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 18px;
  padding: 20px 0;
  border-top: 1px solid var(--rule);
}
.row:first-child { border-top: none; padding-top: 0; }
.num {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  font-size: 13px;
  color: var(--faint);
  font-weight: 600;
  padding-top: 2px;
}
.proj-name {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.head-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 10px;
  margin-bottom: 6px;
}
.badge {
  display: inline-block;
  font-size: 10.5px;
  letter-spacing: 0.03em;
  color: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 999px;
  padding: 1px 8px;
  line-height: 1.5;
  white-space: nowrap;
}
.secondary {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 4px;
}
.secondary a { color: var(--accent); }
.desc {
  font-size: 13px;
  color: var(--muted);
}

/* ---- Nested iOS apps (home) ---- */
.nested { margin-top: 14px; }
.subrow {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 14px;
  padding: 12px 0 0 0;
}
.sublabel {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--faint);
  font-weight: 600;
  padding-top: 2px;
}

/* ---- Random things list (home) ---- */
.random { margin-top: 10px; }
.rand-item {
  padding: 12px 0;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
}
.rand-item .rand-text {
  font-size: 14px;
  flex: 1 1 auto;
  min-width: 200px;
}

/* ---- Writing list (writing page right column) ---- */
.subhead {
  font-size: 15px;
  font-weight: 700;
  margin: 2px 0 6px;
}
.writing-list { margin-top: 2px; }
.writing-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 16px 0;
  border-top: 1px solid var(--rule);
}
.writing-row:first-child { border-top: none; padding-top: 2px; }
.writing-row .w-title { font-size: 16px; font-weight: 600; }
.writing-row:hover .w-title { text-decoration: underline; }
.writing-row .w-date {
  font-size: 12px;
  color: var(--faint);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ---- Image grid (images page right column) ---- */
.image-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 4px;
}
.image-grid img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
}

/* ---- Responsive ---- */
@media (max-width: 720px) {
  html, body { height: auto; }
  body { overflow: auto; }
  .wrap {
    grid-template-columns: 1fr;
    max-width: 620px;
    height: auto;
  }
  .rule { display: none; }
  .col-left {
    height: auto;
    overflow: visible;
    padding: 44px 22px 28px 22px;
    border-bottom: 1px solid var(--rule);
  }
  .col-right {
    height: auto;
    overflow: visible;
    padding: 36px 22px 52px 22px;
  }
  .notes-foot { margin-top: 16px; }
  .name { font-size: 30px; }
  .row { grid-template-columns: 26px 1fr; gap: 12px; padding: 18px 0; }
  .subrow { grid-template-columns: 18px 1fr; gap: 10px; }
  ul.list li .role { min-width: 74px; }
  .image-grid { grid-template-columns: 1fr; }
}
