/* ============================================================
   HOMEPAGE — EDITORIAL INDEX
   Instrument Serif display · Inter body · JetBrains Mono meta
   Design references: brittanychiang.com, paco.me, brianlovin.com
   ============================================================ */

/* ---- DISPLAY FONT ---- */
/* Instrument Serif loaded via <link> in index.html only */
.display-serif {
  font-family: 'Instrument Serif', 'Georgia', serif;
  font-weight: 400;
  font-style: normal;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

/* ============================================================
   HERO — EDITORIAL SPLIT (Refined compact footprint)
   ============================================================ */
.hero-index {
  padding: 40px 0 32px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 108px 1fr;
  gap: 32px;
  align-items: flex-start;
}

/* Photo — circular editorial profile image */
.hero-photo {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  flex-shrink: 0;
  margin-top: 4px;
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  display: block;
}

/* Text block */
.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding-top: 2px;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.hero-name {
  font-family: 'Instrument Serif', Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.3rem, 4.2vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 14px;
}

.hero-bio {
  font-size: 0.95rem;
  line-height: 1.68;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: 22px;
}

/* CTA row */
.hero-ctas {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

/* Socials */
.hero-socials {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.hero-social-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.hero-social-item:hover {
  color: var(--text-primary);
}

.hero-social-item svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* ============================================================
   WORK INDEX — Compact numbered rows
   ============================================================ */
.work-index-section {
  padding: 44px 0;
  border-top: 1px solid var(--border-subtle);
}

.work-index-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}

.work-index-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.work-index-all {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color var(--transition);
}

.work-index-all:hover {
  color: var(--text-primary);
}

/* Row list */
.work-rows {
  display: flex;
  flex-direction: column;
}

.work-row {
  display: grid;
  grid-template-columns: 32px 112px 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-subtle);
  text-decoration: none;
  color: inherit;
  transition: background-color 100ms ease;
  border-radius: 4px;
  margin: 0 -8px;
  padding-left: 8px;
  padding-right: 8px;
}

.work-row:first-child {
  border-top: 1px solid var(--border-subtle);
}

.work-row:hover {
  background-color: var(--bg-surface-hover);
}

@media (prefers-reduced-motion: no-preference) {
  .work-row:hover .work-thumb img {
    transform: scale(1.04);
  }
}

/* Number */
.work-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  align-self: center;
}

/* Thumbnail */
.work-thumb {
  width: 112px;
  height: 70px;
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  flex-shrink: 0;
}

.work-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 200ms ease;
}

/* Meta */
.work-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.work-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.work-row:hover .work-name {
  color: var(--text-primary);
}

.work-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.work-status {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
  margin-top: 4px;
}

.work-status.live {
  color: #4ade80;
}

.work-status.staging {
  color: var(--accent);
}

.work-status.verified {
  color: var(--text-secondary);
}

/* Arrow */
.work-arrow {
  color: var(--text-muted);
  font-size: 0.95rem;
  transition: transform 150ms ease, color 150ms ease;
  flex-shrink: 0;
}

.work-row:hover .work-arrow {
  transform: translateX(3px);
  color: var(--text-primary);
}

/* ============================================================
   AREAS OF WORK — Compact typographic grid
   ============================================================ */
.areas-section {
  padding: 36px 0;
  border-top: 1px solid var(--border-subtle);
}

.areas-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 18px;
}

.areas-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.areas-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.area-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.area-item:nth-child(3n+1) { border-right: 1px solid var(--border-subtle); padding-left: 0; padding-right: 20px; }
.area-item:nth-child(3n+2) { border-right: 1px solid var(--border-subtle); padding-left: 20px; padding-right: 20px; }
.area-item:nth-child(3n+3) { padding-left: 20px; padding-right: 0; }
.area-item:nth-last-child(-n+3) { border-bottom: none; }

.area-name {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
}

/* ============================================================
   EXPERIENCE — Compact inline rows
   ============================================================ */
.exp-section {
  padding: 44px 0;
  border-top: 1px solid var(--border-subtle);
}

.exp-section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}

.exp-section-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.exp-section-link {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color var(--transition);
}

.exp-section-link:hover {
  color: var(--text-primary);
}

.exp-row-list {
  display: flex;
  flex-direction: column;
}

.exp-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: baseline;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.exp-row:first-child {
  border-top: 1px solid var(--border-subtle);
}

.exp-row-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.exp-row-role {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.exp-row-org {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.exp-row-date {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  white-space: nowrap;
}

/* ============================================================
   CONTACT CLOSING — Simple text
   ============================================================ */
.contact-section {
  padding: 44px 0 56px;
  border-top: 1px solid var(--border-subtle);
}

.contact-section-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.contact-heading {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.25;
  margin-bottom: 10px;
  letter-spacing: -0.015em;
}

.contact-subtext {
  font-size: 0.92rem;
  color: var(--text-secondary);
  max-width: 480px;
  line-height: 1.65;
  margin-bottom: 24px;
}

.contact-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .hero-photo {
    width: 88px;
    height: 88px;
    border-radius: 50%;
  }

  .hero-name {
    font-size: clamp(2rem, 7vw, 2.8rem);
  }

  .work-row {
    grid-template-columns: 28px 90px 1fr auto;
    gap: 12px;
  }

  .work-thumb {
    width: 90px;
    height: 56px;
  }

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

  .area-item:nth-child(3n+1),
  .area-item:nth-child(3n+2),
  .area-item:nth-child(3n+3) {
    padding-left: 0;
    padding-right: 0;
    border-right: none;
    border-bottom: 1px solid var(--border-subtle);
  }

  .area-item:nth-last-child(-n+3) {
    border-bottom: 1px solid var(--border-subtle);
  }

  .area-item:nth-child(2n+1) {
    padding-right: 20px;
    border-right: 1px solid var(--border-subtle);
  }

  .area-item:nth-child(2n+2) {
    padding-left: 20px;
  }

  .area-item:nth-last-child(-n+2):nth-child(2n+1),
  .area-item:last-child {
    border-bottom: none;
  }
}

@media (max-width: 540px) {
  .hero-index {
    padding: 36px 0 32px;
  }

  .work-row {
    grid-template-columns: 28px 72px 1fr;
    gap: 10px;
  }

  .work-thumb {
    width: 72px;
    height: 46px;
  }

  .work-arrow {
    display: none;
  }

  .work-name {
    white-space: normal;
    font-size: 0.88rem;
    line-height: 1.35;
  }

  .work-desc {
    display: none;
  }

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

  .area-item:nth-child(2n+1) {
    padding-right: 0;
    border-right: none;
  }

  .area-item:nth-child(2n+2) {
    padding-left: 0;
  }

  .area-item:nth-last-child(-n+2):nth-child(2n+1) {
    border-bottom: 1px solid var(--border-subtle);
  }

  .area-item:last-child {
    border-bottom: none;
  }

  .exp-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* ============================================================
   SHARED QUIET FOOTER
   ============================================================ */
.footer-quiet {
  margin-top: auto;
  border-top: 1px solid var(--border-subtle);
  padding: 22px 0;
  font-size: 0.78rem;
  color: var(--text-muted);
  width: 100%;
}

.footer-quiet-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-quiet-brand {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: -0.01em;
}

.footer-quiet-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 20px;
  font-size: 0.78rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-quiet-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition);
  display: inline-block;
  line-height: 1.5;
}

.footer-quiet-links a:hover {
  color: var(--text-primary);
}

@media (max-width: 640px) {
  .footer-quiet-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .footer-quiet-links {
    gap: 8px 16px;
  }
}

