/* =============================================================================
   project.css — Case-study page styles. Loaded AFTER style.css on
   /projects/*.html. Adds: project header, hero media, prose width, media
   gallery, and back-link styles.
   ============================================================================= */


/* Page header — title, meta, tags, external links. */
.project-header {
  padding: var(--space-16) 0 var(--space-8);
}
.project-header__eyebrow {
  color: var(--accent);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-3);
}
.project-header h1 { margin-bottom: var(--space-4); }
.project-header__meta {
  color: var(--muted);
  margin-bottom: var(--space-4);
}
.project-header__links {
  display: flex; flex-wrap: wrap; gap: var(--space-3);
  margin-top: var(--space-6);
}

/* Hero media — large screenshot or embedded video at the top of the case study. */
.project-hero-media {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--accent-soft);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted);
  margin-bottom: var(--space-12);
}
.project-hero-media img,
.project-hero-media video { width: 100%; height: 100%; object-fit: cover; }

/* Constrain body copy width for comfortable reading line length. */
.prose {
  max-width: 70ch;
  font-size: var(--fs-lg);
  line-height: 1.7;
}
.prose h2 { margin-top: var(--space-12); }
.prose h3 { margin-top: var(--space-8); }
.prose ul { padding-left: var(--space-6); }
.prose li { margin-bottom: var(--space-2); }

/* Media gallery — responsive grid that handles mixed img + video. */
.gallery {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: 1fr;
  margin-top: var(--space-6);
}
.gallery__item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--accent-soft);
  aspect-ratio: 16 / 9;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted);
  font-size: var(--fs-sm);
}
.gallery__item img,
.gallery__item video { width: 100%; height: 100%; object-fit: cover; }

@media (min-width: 720px) {
  .gallery { grid-template-columns: repeat(2, 1fr); }
}

/* Back-to-projects link at the bottom of each case study. */
.project-back {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-12);
  font-weight: 600;
}
