/* ============================================================
   project.css
   Page-specific styles for /projects/ index and /projects/{slug}/
   detail pages.

   REQUIRES theme.css to be loaded FIRST.
   ============================================================ */

/* ── Breadcrumb ──────────────────────────────────────────── */
.breadcrumb-bar { padding: 112px 0 20px; }
.breadcrumb-bar a {
  font-family: var(--font-text); font-weight: 500; font-size: 14px;
  color: var(--color-neutral-70); transition: color .3s;
}
.breadcrumb-bar a:hover { color: var(--color-accent); }
.breadcrumb-bar span { font-size: 14px; color: var(--color-neutral-60); margin: 0 8px; }

/* ── Project hero (detail) ───────────────────────────────── */
.project-hero      { padding: 0 0 60px; }
.project-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.project-hero-image {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--color-neutral-40);
  position: relative;
}
.project-hero-image img { width: 100%; height: 100%; object-fit: cover; }
.project-hero-image::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(221deg, rgba(0,215,238,.12) 0%, rgba(97,0,255,.08) 100%);
  pointer-events: none;
}

.project-hero-text h1 {
  font-family: var(--font-display); font-weight: 700;
  font-size: 44px; line-height: 46px;
  color: var(--color-neutral-100);
  margin-bottom: 20px;
}
.project-hero-text .project-year {
  font-family: var(--font-display); font-weight: 800;
  font-size: 12px; letter-spacing: 1.71px; text-transform: uppercase;
  color: var(--color-neutral-60); margin-bottom: 16px;
}
.project-hero-text .project-summary {
  font-size: 21px; line-height: 35px; color: var(--color-neutral-80);
}

@media (max-width: 991px) {
  .project-hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .project-hero-text h1 { font-size: 36px; line-height: 42px; }
  .project-hero-text .project-summary { font-size: 19px; line-height: 28px; }
}

/* ── Project hero text — description appended below summary ──
   The hero is a 1fr 1fr grid (image | text). The text column now
   contains: year, title, summary, AND the multi-paragraph
   description. Fills the right column nicely instead of leaving
   it sparse below the summary line. */
.project-hero-text .project-description {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--color-neutral-30);
}
.project-hero-text .project-description p {
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 26px;
  color: var(--color-neutral-80);
  margin-bottom: 14px;
}
.project-hero-text .project-description p:last-child { margin-bottom: 0; }

/* ── Project body (detail) ───────────────────────────────────
   Single-column body, no sidebar. People come first as a
   horizontal row, then publications as full-width long rows. */
.project-body { padding: 60px 0 80px; border-top: 2px solid var(--color-neutral-30); }
.project-people-row { margin-bottom: 60px; }
.project-publications-row { /* spacing only; container is full-width */ }

/* ── People row (horizontal grid of avatars) ─────────────────
   Each person is a small card: circular avatar on top with the
   name beneath. Wraps automatically — no fixed column count.
   Auto-fill at ~120px each so 6-7 people typically fit on one
   row at desktop width. */
.project-people-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 24px 16px;
  margin-top: 20px;
}
.project-person-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  padding: 8px 4px;
  border-radius: var(--radius);
  transition: background .25s, transform .25s;
}
.project-person-card:hover {
  background: var(--color-neutral-20);
}
.project-person-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  padding: 2px;
  background: var(--gradient);
  position: relative;
}
.project-person-avatar img,
.project-person-avatar-placeholder {
  width: 100%; height: 100%;
  border-radius: 50%;
  display: block;
}
.project-person-avatar img { object-fit: cover; }
.project-person-avatar-placeholder {
  display: flex; align-items: center; justify-content: center;
  background: var(--color-neutral-30);
  color: var(--color-neutral-70);
  font-family: var(--font-display); font-weight: 700;
  font-size: 24px;
}
.project-person-name {
  font-family: var(--font-text); font-weight: 600;
  font-size: 13px; line-height: 1.3;
  color: var(--color-neutral-100);
  transition: color .3s;
}
.project-person-card:hover .project-person-name { color: var(--color-accent); }

/* ── Publications list (long-row cards, matches publications archive) ──
   Numbered list, each item has title (linked), citation in muted text,
   and a row of small DOI/PDF buttons. Same pattern as the person profile
   page's publications, restyled without the leading number column for
   simplicity (project pages typically have 1-3 publications). */
.project-pub-list {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
}
.project-pub-item {
  padding: 24px 0;
  border-top: 1px solid var(--color-neutral-30);
}
.project-pub-item:last-child { border-bottom: 1px solid var(--color-neutral-30); }
.project-pub-title {
  display: block;
  font-family: var(--font-display); font-weight: 700;
  font-size: 19px; line-height: 1.35;
  color: var(--color-neutral-100);
  margin-bottom: 8px;
  transition: color .25s;
}
a.project-pub-title:hover { color: var(--color-accent); }
.project-pub-citation {
  font-family: var(--font-text);
  font-size: 14px; line-height: 22px;
  color: var(--color-neutral-70);
  margin-bottom: 12px;
}
.project-pub-links {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.project-pub-link {
  font-family: var(--font-display); font-weight: 600;
  font-size: 11px; letter-spacing: .8px;
  color: var(--color-accent);
  padding: 5px 12px;
  border: 1px solid var(--color-neutral-30);
  border-radius: var(--radius-sm);
  transition: all .25s;
}
.project-pub-link:hover {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

@media (max-width: 767px) {
  .project-pub-title { font-size: 17px; }
  .project-people-grid { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
  .project-person-avatar { width: 60px; height: 60px; }
}

/* ── Project images ──────────────────────────────────────── */
.project-images     { margin-top: 48px; }
.project-images img { margin-bottom: 20px; border-radius: var(--radius-lg); }