/* Project page — separate from canvas styles */

body.project-page {
  overflow-x: hidden;
  overflow-y: auto;
  cursor: default;
}

body.project-page .site-header {
  position: fixed;
  mix-blend-mode: normal;
  background: var(--bg);
  border-bottom: 1px solid var(--fg-dim);
  transition: background-color 1s ease, border-color 1s ease;
}

.back-link {
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--fg);
  text-decoration: none;
  opacity: 0.6;
  pointer-events: all;
  transition: opacity 0.2s, color 1s ease;
}

.back-link:hover {
  opacity: 1;
}

/* ---- Main layout ---- */

.project-main {
  padding-top: 72px; /* header height */
}

/* ---- Hero ---- */

.project-hero {
  width: 100%;
  height: 70vh;
  overflow: hidden;
}

.project-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ---- Content: title + description + credits ---- */

.project-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  padding: 64px 60px;
  max-width: 1200px;
}

.project-heading {
  font-size: 28px;
  font-weight: 300;
  letter-spacing: -0.01em;
  line-height: 1.2;
  color: var(--fg);
  margin-bottom: 20px;
  transition: color 1s ease;
}

.project-description {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.75;
  color: var(--fg);
  opacity: 0.75;
  transition: color 1s ease;
}

/* ---- Credits ---- */

.project-credits {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 6px;
}

.credit-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.credit-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg);
  opacity: 0.4;
  transition: color 1s ease;
}

.credit-values {
  font-size: 13px;
  font-weight: 300;
  color: var(--fg);
  opacity: 0.85;
  line-height: 1.5;
  transition: color 1s ease;
}

/* ---- Gallery ---- */

.project-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
  padding: 0 0 120px;
}

.gallery-img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  display: block;
}

/* Single image spans full width */
.project-gallery:has(.gallery-img:only-child) .gallery-img,
.gallery-img.full-width {
  grid-column: span 2;
  height: 600px;
}

/* Odd last image spans full width */
.gallery-img:last-child:nth-child(odd) {
  grid-column: span 2;
  height: 600px;
}

/* ---- Contact page ---- */

.contact-main {
  padding: 100px 60px 120px;
  max-width: 900px;
}

.contact-top {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-bottom: 60px;
}

.contact-photo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  filter: grayscale(1);
  transition: filter 0.4s ease;
}

.contact-photo:hover {
  filter: grayscale(0);
}

.contact-name {
  font-size: 28px;
  font-weight: 300;
  letter-spacing: -0.01em;
  color: var(--fg);
  margin-bottom: 8px;
  transition: color 1s ease;
}

.contact-email {
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.04em;
  color: var(--fg);
  opacity: 0.5;
  text-decoration: none;
  transition: opacity 0.2s, color 1s ease;
}

.contact-email:hover {
  opacity: 1;
}

.contact-bio {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 560px;
}

.contact-bio p {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.8;
  color: var(--fg);
  opacity: 0.7;
  transition: color 1s ease;
}

/* ---- Mobile ---- */

@media (max-width: 768px) {
  .project-content {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 40px 24px;
  }

  .project-gallery {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .gallery-img,
  .gallery-img:last-child:nth-child(odd) {
    grid-column: span 1;
    height: 280px;
  }

  .project-hero {
    height: 50vw;
    min-height: 220px;
  }
}
