.project-detail__hero {
  min-height: calc(100vh - 110px);
  padding: 72px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.9fr);
  align-items: center;
  gap: 48px;
}

.project-detail__intro,
.project-detail__cover,
.detail-grid > *,
.decision-grid > * {
  min-width: 0;
}

.project-detail__intro h1 {
  margin: 14px 0 18px;
  color: var(--cream);
  font-size: clamp(2.8rem, 6vw, 5.8rem);
  line-height: 0.98;
  overflow-wrap: anywhere;
}

.project-detail__role {
  color: var(--cream);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.9rem;
}

.project-detail__labels {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.project-detail__summary {
  max-width: 680px;
  margin: 22px 0;
  color: var(--cream);
  font-size: 1.15rem;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.back-link,
.project-detail__footer a {
  color: var(--cream);
  font-weight: 700;
  text-decoration: none;
}

.back-link:hover,
.project-detail__footer a:hover {
  text-decoration: underline;
}

.project-detail__cover {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--espresso-brown);
  aspect-ratio: 16 / 10;
}

.project-detail__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-section {
  padding: 64px 0;
}

.detail-section .section-heading {
  margin-bottom: 28px;
}

.detail-section .section-heading h2 {
  color: var(--cream);
}

.detail-grid,
.decision-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.decision-card h3,
.detail-section .panel h2 {
  margin: 10px 0 14px;
  color: var(--espresso-brown);
}

.decision-card p {
  color: var(--muted);
  line-height: 1.7;
}

.detail-list {
  padding-left: 24px;
  color: var(--muted);
  line-height: 1.7;
}

.detail-list li + li {
  margin-top: 10px;
}

.media-gallery {
  display: grid;
  gap: 32px;
}

.media-item {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
}

.media-item img,
.project-video {
  display: block;
  width: 100%;
  max-height: 720px;
  background: #1d1814;
  object-fit: contain;
}

.media-item figcaption {
  padding: 22px;
}

.media-item figcaption h3 {
  margin-bottom: 8px;
  color: var(--espresso-brown);
}

.media-item figcaption p {
  color: var(--muted);
  line-height: 1.65;
}

.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #1d1814;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.project-not-found {
  margin: 100px 0;
  text-align: center;
}

.project-not-found h1 {
  margin: 12px 0;
}

.project-not-found .button {
  margin-top: 24px;
}

.project-detail__footer {
  padding: 40px 0 70px;
}

@media (max-width: 900px) {
  .project-detail__hero,
  .detail-grid,
  .decision-grid {
    grid-template-columns: 1fr;
  }

  .project-detail__hero {
    padding: 56px 0;
    gap: 30px;
    min-height: auto;
  }
}

@media (max-width: 520px) {
  .project-detail__intro h1 {
    font-size: clamp(2.25rem, 11vw, 2.8rem);
    line-height: 1.04;
  }

  .detail-section {
    padding: 44px 0;
  }
}
