/* ===== GALLERY PAGE STYLES =====
   Used by all portfolio category pages (advertising, architectural, etc.)
   Layout: H1 → Slider → H2 + SEO text → Gallery → Post-gallery text → CTA
*/

/* --- H1 — Lightweight --- */
.page-h1 {
  padding-top: 24px;
  padding-bottom: 16px;
}
.page-h1 h1 {
  font-size: 34px;
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

/* --- Portfolio Slider --- */
.portfolio-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: var(--gray-100);
  margin-bottom: 12px;
}

/* --- H2 — Lightweight --- */
.page-h2 {
  margin-bottom: 12px;
}
.page-h2 h2 {
  font-size: 26px;
  font-weight: 300;
  line-height: 1.3;
  letter-spacing: 0.3px;
}

/* --- SEO Text --- */
.seo-text {
  margin-bottom: 24px;
}
.seo-text p {
  font-size: var(--body-lg);
  color: var(--gray-700);
  line-height: var(--body-line-height);
  margin-bottom: 16px;
}
.seo-text p:last-child {
  margin-bottom: 0;
}

/* --- Gallery Section --- */
.gallery-section {
  padding-top: 0;
}

/* --- Gallery Grid --- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.gallery-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.gallery-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.gallery-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.gallery-grid.cols-1 { grid-template-columns: 1fr; max-width: 600px; }

.gallery-item {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--gray-100);
}
.gallery-item.portrait { aspect-ratio: 3 / 4; }
.gallery-item img {
  transition: transform var(--transition-slow);
}
.gallery-item:hover img {
  transform: scale(1.05);
}

/* --- Placeholder (until real images arrive) --- */
.gallery-item.placeholder {
  border: 2px dashed var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-item.placeholder span {
  font-size: var(--label-sm);
  font-weight: var(--label-weight);
  text-transform: uppercase;
  letter-spacing: var(--label-tracking);
  color: var(--gray-400);
  text-align: center;
  padding: 8px;
}

/* --- Project Groups --- */
.project-group {
  margin-bottom: 48px;
}
.project-group-title {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 16px;
  padding-top: 2px;
  color: var(--black);
}
.project-group-meta {
  font-size: var(--body-sm);
  color: var(--gray-500);
  margin-bottom: 16px;
}

/* --- Post-gallery text --- */
.post-gallery-text {
  padding-top: 24px;
}
.post-gallery-text h3 {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 16px;
}
.post-gallery-text p {
  font-size: var(--body-md);
  color: var(--gray-700);
  line-height: var(--body-line-height);
  margin-bottom: 16px;
}
.post-gallery-text p:last-child {
  margin-bottom: 0;
}

/* --- Touch devices: disable hover zoom --- */
@media (hover: none) {
  .gallery-item:hover img { transform: none; }
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .page-h1 { padding-top: 32px; padding-bottom: 24px; }
  .page-h1 h1 { font-size: 28px; }
  .portfolio-slider { margin-bottom: 20px; }
  .page-h2 h2 { font-size: 22px; }
  .page-h2 { margin-bottom: 16px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .gallery-grid.cols-1 { grid-template-columns: 1fr; }
  .post-gallery-text { padding-top: 32px; }
}
@media (max-width: 480px) {
  .page-h1 { padding-top: 24px; padding-bottom: 20px; }
  .page-h1 h1 { font-size: 24px; }
  .portfolio-slider { aspect-ratio: 16 / 9; margin-bottom: 16px; }
  .page-h2 h2 { font-size: 20px; }
  .page-h2 { margin-bottom: 14px; }
  .seo-text { margin-bottom: 32px; }
  .gallery-grid { grid-template-columns: 1fr; gap: 10px; }
  .post-gallery-text { padding-top: 32px; }
  .post-gallery-text h3 { font-size: 15px; }
}
