/* ============================================================
   RSA — Project Detail Pages Stylesheet
   Extends css/style.css
   ============================================================ */

.project-page {
  background: var(--color-bg);
}

/* Project hero */
.project-hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: var(--space-xl);
  overflow: hidden;
  background-color: var(--color-surface);
}

.project-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-hero .hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,0.8));
}

.project-hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding: 0 var(--space-md);
  max-width: 800px;
}

.project-hero-content h1 {
  color: #fff;
  font-size: clamp(2rem, 4vw, 3.5rem);
  margin-bottom: var(--space-sm);
}

.project-hero-meta {
  display: flex;
  justify-content: center;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.project-hero-meta span {
  font-size: var(--font-size-small);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.7);
}

.project-hero-meta span strong {
  color: #fff;
  font-weight: 500;
}

/* Project content */
.project-content {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--space-2xl) var(--space-md);
}

.project-content h2 {
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
}

.project-content p {
  line-height: 1.9;
  margin-bottom: var(--space-md);
}

/* Material palette */
.material-palette {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--space-sm);
  margin: var(--space-lg) 0;
}

.material-item {
  padding: var(--space-md);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  text-align: center;
  background: var(--color-surface);
}

.material-swatch {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin: 0 auto var(--space-sm);
  border: 1px solid var(--color-border);
}

.material-item h4 {
  font-family: var(--font-sans);
  font-size: var(--font-size-small);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0;
}

/* Project gallery */
.project-gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-sm);
  margin: var(--space-xl) 0;
}

.project-gallery img {
  width: 100%;
  height: 100%;
  min-height: 300px;
  object-fit: cover;
  border-radius: 4px;
  transition: transform 0.4s ease;
}

.project-gallery img:hover {
  transform: scale(1.02);
}

.project-gallery .full-width {
  grid-column: 1 / -1;
}

/* Credits */
.project-credits {
  margin: var(--space-xl) 0;
  padding: var(--space-lg);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 4px;
}

.project-credits h3 {
  margin-bottom: var(--space-md);
}

.credit-row {
  display: flex;
  justify-content: space-between;
  padding: var(--space-xs) 0;
  border-bottom: 1px solid var(--color-border);
  font-size: var(--font-size-small);
}

.credit-row:last-child {
  border-bottom: none;
}

.credit-row span:first-child {
  color: var(--color-muted);
  font-weight: 500;
}

/* Project navigation */
.project-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-xl) 0;
  border-top: 1px solid var(--color-border);
  margin-top: var(--space-xl);
}

.project-nav-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--font-size-small);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-muted);
  transition: color 0.2s ease;
}

.project-nav-link:hover {
  color: var(--color-accent);
}

.project-nav-link .arrow {
  font-size: 1.2rem;
}

.project-nav-back {
  font-size: var(--font-size-small);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
  font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
  .project-gallery {
    grid-template-columns: 1fr;
  }

  .project-hero-meta {
    flex-direction: column;
    gap: var(--space-xs);
    align-items: center;
  }

  .project-nav {
    flex-direction: column;
    gap: var(--space-md);
  }

  .material-palette {
    grid-template-columns: repeat(2, 1fr);
  }

  .project-credits {
    padding: var(--space-md);
  }
}
