﻿/* ============================================
   PROJECT DETAIL PAGE — redesigned
   ============================================ */

.project-detail-page {
  padding-top: 22px;
  padding-bottom: 80px;
}

/* ── Photo grid (Airbnb style) ── */
.project-photo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 290px 290px;
  gap: 8px;
  height: 582px;
  overflow: hidden;
  position: relative;
  margin-bottom: 0;
}

.project-photo-main {
  grid-row: 1 / 3;
  overflow: hidden;
  background: #e5e5e5;
  display: block;
}

.project-photo-side {
  overflow: hidden;
  background: #e5e5e5;
  display: block;
}

.project-photo-main img,
.project-photo-side img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.project-photo-main:hover img,
.project-photo-side:hover img {
  transform: scale(1.03);
}

.project-view-all-btn {
  position: absolute;
  bottom: 18px;
  right: 18px;
  background: #ffffff;
  border: 1px solid #dddddd;
  border-radius: 8px;
  padding: 0 16px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: #111111;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  z-index: 10;
}

.project-view-all-btn:hover { background: #f7f7f7; }
.project-view-all-btn i { font-size: 15px; }



/* ── Page head ── */
.project-page-head {
  margin-top: 26px;
  margin-bottom: 20px;
}

.project-page-head h1 {
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 700;
  color: #111111;
  margin: 0 0 12px;
  letter-spacing: -0.4px;
  line-height: 1.2;
}

.project-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.project-meta-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 11px;
  border-radius: 7px;
  background: #f5f5f5;
  color: #555555;
  font-size: 12.5px;
  font-weight: 500;
}

.project-meta-tag i { color: #e8a50f; font-size: 12px; }

/* ── Hero image ── */
.project-hero-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16/8;
  border-radius: 14px;
  overflow: hidden;
  background: #f0f0f0;
  display: block;
  margin-bottom: 12px;
}

.project-hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

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

.project-hero-zoom {
  position: absolute;
  right: 18px;
  bottom: 18px;
  height: 38px;
  padding: 0 14px;
  border-radius: 8px;
  background: rgba(255,255,255,0.92);
  color: #111111;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 600;
  backdrop-filter: blur(4px);
}

/* ── Facts bar ── */
.project-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 36px;
}

.project-fact {
  padding: 16px 18px;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.project-fact i {
  color: #e8a50f;
  font-size: 18px;
}

.project-fact span {
  color: #888888;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.project-fact strong {
  color: #111111;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
}

/* ── Story full width ── */
.project-story-full {
  border: 1px solid #e8e8e8;
  border-radius: 14px;
  padding: 32px;
  background: #ffffff;
  margin-bottom: 28px;
}

.project-section-label {
  font-size: 11.5px;
  font-weight: 700;
  color: #e8a50f;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}

.project-story-full h2 {
  font-size: 20px;
  font-weight: 700;
  color: #111111;
  margin: 0 0 16px;
  letter-spacing: -0.2px;
  line-height: 1.3;
}

.project-richtext {
  color: #444444;
  font-size: 15px;
  line-height: 1.8;
}

.project-richtext p,
.project-richtext ul,
.project-richtext ol { margin-top: 0; margin-bottom: 14px; }
.project-richtext img { max-width: 100%; height: auto; border-radius: 8px; }

.project-note ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.project-note li {
  position: relative;
  padding-left: 20px;
  color: #555555;
  font-size: 14px;
  line-height: 1.55;
}

.project-note li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e8a50f;
}

/* ── Actions row ── */
.project-actions-row {
  display: flex;
  gap: 10px;
  margin-bottom: 40px;
}

.project-primary-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 48px;
  padding: 0 22px;
  border-radius: 10px;
  background: #e8a50f;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.15s;
}

.project-primary-btn:hover { background: #cf9108; color: #ffffff; }

.project-secondary-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 48px;
  padding: 0 22px;
  border-radius: 10px;
  border: 1.5px solid #222222;
  background: #ffffff;
  color: #111111;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.project-secondary-btn:hover {
  background: #111111;
  color: #ffffff;
}

/* ── Gallery ── */
.project-gallery-section {
  margin-bottom: 40px;
}

.project-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid #ebebeb;
}

.project-section-head h2 {
  font-size: 20px;
  font-weight: 700;
  color: #111111;
  margin: 0;
  letter-spacing: -0.2px;
}

.project-section-head span {
  font-size: 13px;
  color: #888888;
  font-weight: 500;
  white-space: nowrap;
}

.project-gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-flow: dense;
  gap: 8px;
}

.project-gallery-item {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  background: #f0f0f0;
  aspect-ratio: 4/3;
}

.project-gallery-item.large {
  grid-column: span 2;
  grid-row: span 2;
  aspect-ratio: auto;
}

.project-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.28s ease;
}

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

.project-gallery-zoom {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255,255,255,0.9);
  color: #111111;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.18s, transform 0.18s;
}

.project-gallery-item:hover .project-gallery-zoom {
  opacity: 1;
  transform: translateY(0);
}

/* ── Related ── */
.project-related {
  border-top: 1px solid #ebebeb;
  padding-top: 36px;
}

/* ── Project Card (shared with projects page) ── */
.project-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  height: 100%;
}

.project-card-link:hover { color: inherit; }

.project-card {
  height: 100%;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  overflow: hidden;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.18s, border-color 0.18s;
}

.project-card-link:hover .project-card {
  border-color: #cccccc;
  box-shadow: 0 4px 24px rgba(0,0,0,0.09);
}

.project-card-img {
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f0f0f0;
  flex-shrink: 0;
}

.project-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.32s ease;
}

.project-card-link:hover .project-card-img img {
  transform: scale(1.05);
}

.project-card-body {
  padding: 14px 16px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}

.project-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.project-card-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 9px;
  border-radius: 6px;
  background: #f5f5f5;
  color: #555555;
  font-size: 12px;
  font-weight: 500;
}

.project-card-tag i {
  color: #e8a50f;
  font-size: 12px;
}

.project-card-title {
  font-size: 15px;
  font-weight: 700;
  color: #111111;
  line-height: 1.35;
  margin: 0;
  flex: 1;
}

.project-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #888888;
  margin-top: 4px;
  transition: color 0.15s;
}

.project-card-link:hover .project-card-cta {
  color: #e8a50f;
}

.project-card-cta i { font-size: 14px; }

/* ── Lightbox ── */
.project-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1200;
  padding: 28px;
  background: rgba(0,0,0,0.86);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}

.project-lightbox.active { opacity: 1; visibility: visible; }

.project-lightbox img {
  max-width: min(100%, 1240px);
  max-height: 88vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
}

.project-lightbox-close,
.project-lightbox-nav {
  border: 0;
  border-radius: 50%;
  background: #ffffff;
  color: #111111;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.project-lightbox-close {
  position: absolute;
  right: 20px;
  top: 20px;
  width: 44px;
  height: 44px;
  font-size: 17px;
}

.project-lightbox-nav {
  position: absolute;
  top: 50%;
  width: 50px;
  height: 50px;
  font-size: 22px;
  transform: translateY(-50%);
}

.project-lightbox-nav.prev { left: 20px; }
.project-lightbox-nav.next { right: 20px; }
body.project-lightbox-open { overflow: hidden; }

/* ── Empty ── */
.project-empty {
  max-width: 600px;
  padding: 80px 0;
}

.project-empty h1 {
  font-size: 34px;
  font-weight: 700;
  color: #111111;
  margin: 0 0 12px;
}

.project-empty p {
  color: #555555;
  font-size: 16px;
  margin: 0 0 24px;
  line-height: 1.6;
}

/* ── Responsive ── */
@media (max-width: 1100px) {
  .project-facts { grid-template-columns: repeat(2, 1fr); }
  .project-gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .project-gallery-item.large { grid-column: span 2; aspect-ratio: 16/9; }
}

@media (max-width: 860px) {
  .project-story-grid { grid-template-columns: 1fr; }
}

@media (max-width: 767px) {
  .project-photo-grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    height: auto;
  }
  .project-photo-main {
    grid-row: auto;
    aspect-ratio: 16/10;
    height: auto;
  }
  .project-photo-side { display: none; }
}

@media (max-width: 575px) {
  .project-detail-page { padding-top: 14px; padding-bottom: 52px; }
  .project-hero-image { aspect-ratio: 4/3; border-radius: 10px; }
  .project-facts { grid-template-columns: repeat(2, 1fr); }
  .project-story, .project-note { padding: 20px; }
  .project-actions-row { flex-direction: column; }
  .project-primary-btn, .project-secondary-btn { justify-content: center; }
  .project-card-title { font-size: 14px; }
  .project-gallery-grid { grid-template-columns: 1fr 1fr; }
  .project-gallery-item.large { grid-column: span 2; grid-row: span 1; aspect-ratio: 16/9; }
  .project-lightbox { padding: 14px; }
  .project-lightbox-close { right: 14px; top: 14px; }
  .project-lightbox-nav { width: 40px; height: 40px; font-size: 18px; }
  .project-lightbox-nav.prev { left: 12px; }
  .project-lightbox-nav.next { right: 12px; }
}
