/* Portfolio archive + single project pages. Prefix: pf- */

/* ---------- Archive: intro ---------- */
.pf-intro { margin-top: 110px; text-align: center; }
.pf-intro__text { max-width: 853px; margin: 40px auto 14px; color: var(--text); }

/* ---------- Archive: project grid ---------- */
.pf-showcase { margin-top: 147px; }
.pf-showcase__title { text-align: center; }
.pf-showcase__text { text-align: center; color: var(--text); margin-bottom: 14px; }
.pf-grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 1fr; gap: 40px; margin-top: 40px; }
.pf-card { display: flex; flex-direction: column; overflow: hidden; }
.pf-card__media { display: block; overflow: hidden; }
.pf-card__media img { width: 100%; aspect-ratio: 406 / 400; object-fit: cover; transition: transform .3s; }
.pf-card:hover .pf-card__media img, .pf-card:focus-visible .pf-card__media img { transform: scale(1.025); }
.pf-card__title { margin-top: 40px; transition: color .3s; }
.pf-card__title:hover { color: var(--tan); }
@media (max-width: 1024px) { .pf-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 767px) {
  .pf-intro__text { margin-top: 20px; }
  .pf-grid { grid-template-columns: 1fr; }
  .pf-card__title { margin-top: 14px; }
}

/* ---------- Featured-projects slider (archive + single) ---------- */
.pf-slider { margin-top: 140px; overflow: hidden; }
.pf-slider .carousel__track { align-items: flex-start; }
.pf-slide { padding: 10px; }
.pf-slide__inner { display: flex; gap: 20px 140px; padding: 0 60px; }
.pf-slide__text, .pf-slide__media { flex: 1 1 0; min-width: 0; }
.pf-slide__text { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 74px 0; }
.pf-slide__excerpt { margin-top: 40px; color: var(--text); }
.pf-slide__btn { margin-top: 40px; font-weight: 400; background: var(--tan); }
.pf-slide__btn:hover, .pf-slide__btn:focus-visible { background: var(--accent); }
.pf-slide__media { background-size: cover; background-position: center; background-repeat: no-repeat; align-self: stretch; }
.pf-slider__arrow { margin-top: -25px; transform: none; }
@media (max-width: 1024px) {
  .pf-slide__inner { flex-wrap: wrap; }
  .pf-slide__text, .pf-slide__media { flex: 1 1 100%; }
  .pf-slide__text { padding: 40px 0; }
  .pf-slide__media { min-height: 300px; }
  .pf-slider .carousel { display: flex; flex-wrap: wrap; justify-content: center; column-gap: 30px; }
  .pf-slider .carousel__viewport { flex: 0 0 100%; }
  .pf-slider__arrow.carousel__arrow--side { position: static; margin-top: 40px; }
}
@media (max-width: 767px) {
  .pf-slide__inner { gap: 0; padding: 0 20px; }
  .pf-slide__excerpt { margin-top: 20px; }
}

/* ---------- Archive: CTA box over image band ---------- */
.pf-cta { margin: 175px 0 120px; }
.pf-cta__bg { display: flex; justify-content: center; align-items: flex-start; min-height: 375px; padding: 0 var(--gutter); background-size: cover; background-position: center; background-repeat: no-repeat; }
.pf-cta__box { width: 796px; max-width: 100%; margin-top: -60px; display: flex; flex-direction: column; gap: 20px; padding: 60px; border: 1px solid var(--black); background: var(--accent); text-align: center; }
.pf-cta__text { color: var(--black); }
.pf-cta__btns { display: flex; flex-direction: row-reverse; flex-wrap: wrap-reverse; justify-content: center; align-items: center; gap: 20px; }
@media (max-width: 767px) {
  .pf-cta { margin-top: 525px; }
  .pf-cta__bg { min-height: 500px; }
  .pf-cta__box { width: 100%; margin-top: -300px; }
}

/* ---------- Single: hero ---------- */
.pf-hero { position: relative; display: flex; align-items: center; justify-content: center; min-height: 636px; background-size: cover; background-position: center; background-repeat: no-repeat; }
.pf-hero__overlay { position: absolute; inset: 0; background: var(--text); opacity: .35; }
.pf-hero__inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; }
.pf-hero__title { color: var(--white); }
.pf-hero__text { max-width: 853px; margin-top: 40px; color: var(--white); }
@media (max-width: 767px) { .pf-hero { min-height: 500px; } }

/* ---------- Single: details ---------- */
.pf-details { display: flex; gap: 40px 140px; margin-top: 80px; }
.pf-details__meta { flex: 0 1 35%; }
.pf-details__body { flex: 0 1 65%; font-size: 18px; line-height: 1.444; color: var(--text); }
.pf-details__body p { margin: 0 0 .8em; }
.pf-details__value { margin-top: 20px; font-size: 18px; line-height: 1.444; color: var(--grey); }
.pf-details__label { margin-top: 32px; }
@media (max-width: 1024px) { .pf-details { column-gap: 50px; } }
@media (max-width: 767px) {
  .pf-details { flex-direction: column; }
  .pf-details__meta, .pf-details__body { flex: none; }
}

/* ---------- Single: masonry galleries ---------- */
.pf-gallery-section { margin-top: 120px; }
.pf-gallery-section__title { margin-bottom: 30px; }
.pf-masonry { --pf-gap: 30px; gap: var(--pf-gap); }
.pf-masonry.is-masonry { display: flex; align-items: flex-start; }
.pf-masonry__col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: var(--pf-gap); }
.pf-masonry .gallery__item { position: relative; }
.pf-masonry .gallery__item img { height: auto; }
.pf-masonry .gallery__item::after { content: ''; position: absolute; inset: 0; background: rgba(0, 0, 0, 0); transition: background-color .8s; }
.pf-masonry .gallery__item:hover::after, .pf-masonry .gallery__item:focus-visible::after { background: rgba(0, 0, 0, .5); }
@media (max-width: 1366px) { .pf-masonry { --pf-gap: 10px; } }

.pf-contact { margin-top: 120px; }
