/* Visual asset placement styles. */
.hero-section,
.page-hero {
  isolation: isolate;
}

.hero-section__media,
.page-hero__media {
  position: absolute;
  inset: 0;
  z-index: -3;
  display: block;
}

.hero-section__media img,
.page-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  image-rendering: auto;
}

.hero-section::after,
.page-hero::after {
  position: absolute;
  inset: 0;
  z-index: -2;
  content: "";
  background: rgba(0, 0, 0, .62);
  pointer-events: none;
}

.capability-card__media {
  display: block;
  flex: 0 0 auto;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  margin: calc(clamp(1.5rem, 4vw, 2.5rem) * -1);
  margin-bottom: 1.5rem;
}

.capability-card__media img,
.production-section__media img {
  display: block;
  width: 100%;
  object-fit: cover;
  image-rendering: auto;
}

.capability-card__media img {
  height: 100%;
  aspect-ratio: auto;
}

.production-section__media {
  display: block;
  overflow: hidden;
  margin-bottom: 2rem;
  border: 1px solid rgba(211, 211, 211, .14);
}

.production-section__media img {
  height: auto;
  aspect-ratio: 8 / 5;
}

/* Shared information panels: keep all body content in the wide column. */
.notice-panel {
  grid-template-columns: minmax(13rem, .36fr) minmax(0, 1fr);
  column-gap: clamp(2rem, 4vw, 4rem);
  row-gap: .7rem;
  align-items: start;
}

.notice-panel > h2 {
  grid-column: 1;
  grid-row: 1;
  margin-bottom: 0;
}

.notice-panel > :not(h2) {
  grid-column: 2;
}

.notice-panel > p {
  max-width: 70ch;
  margin-bottom: .15rem;
  color: #4f5155;
}

/* Information panels inside dark sections should belong to the section, not look like white placeholders. */
.section-space--dark .notice-panel {
  color: #fff;
  background: rgba(255, 255, 255, .045);
  border-color: rgba(211, 211, 211, .2);
  border-left-color: #b87332;
  box-shadow: none;
}

.section-space--dark .notice-panel > p {
  color: rgba(255, 255, 255, .7);
}

/* Projects: product gallery on the left, project information on the right. */
.project-showcase {
  display: grid;
  grid-template-columns: minmax(24rem, .92fr) minmax(0, 1.08fr);
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: start;
  padding: clamp(1.5rem, 4vw, 3rem);
  background: #fff;
  border: 1px solid rgba(29, 31, 35, .14);
  border-left: 4px solid #b87332;
  box-shadow: 0 18px 50px rgba(17, 19, 22, .08);
  scroll-margin-top: 7rem;
}

.product-gallery {
  min-width: 0;
}

.product-gallery__main {
  position: relative;
  display: grid;
  width: 100%;
  overflow: hidden;
  aspect-ratio: 1;
  padding: clamp(1rem, 2vw, 1.75rem);
  place-items: center;
  background: #f4f2ed;
  border: 1px solid rgba(29, 31, 35, .14);
  cursor: zoom-in;
}

.product-gallery__main:hover,
.product-gallery__main:focus-visible {
  border-color: #b87332;
}

.product-gallery__main:focus-visible,
.product-gallery__thumb:focus-visible,
.product-lightbox__close:focus-visible {
  outline: 3px solid #d39a68;
  outline-offset: 2px;
}

.product-gallery__main img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-gallery__zoom {
  position: absolute;
  right: .85rem;
  bottom: .85rem;
  padding: .45rem .65rem;
  color: #fff;
  background: rgba(29, 31, 35, .82);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.product-gallery__thumbs {
  display: flex;
  gap: .65rem;
  margin-top: .75rem;
  padding: .1rem .05rem .55rem;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-color: #b87332 #e9e6df;
  scrollbar-width: thin;
}

.product-gallery__thumb {
  display: grid;
  flex: 0 0 5.4rem;
  overflow: hidden;
  aspect-ratio: 1;
  padding: .3rem;
  place-items: center;
  scroll-snap-align: start;
  background: #fff;
  border: 1px solid rgba(29, 31, 35, .16);
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.product-gallery__thumb:hover {
  border-color: #8c8982;
  transform: translateY(-1px);
}

.product-gallery__thumb.is-active {
  border-color: #b87332;
  box-shadow: inset 0 0 0 1px #b87332;
}

.product-gallery__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.project-showcase__content {
  min-width: 0;
  padding-top: .35rem;
}

.project-showcase__title {
  margin-bottom: 1.25rem;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 1.02;
}

.project-showcase__lead {
  max-width: 64ch;
  margin-bottom: 2rem;
  color: #4f5155;
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.project-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0 0 2rem;
  border-top: 1px solid rgba(29, 31, 35, .16);
  border-left: 1px solid rgba(29, 31, 35, .16);
}

.project-facts > div {
  min-width: 0;
  padding: 1rem 1.1rem;
  border-right: 1px solid rgba(29, 31, 35, .16);
  border-bottom: 1px solid rgba(29, 31, 35, .16);
}

.project-facts dt {
  margin-bottom: .25rem;
  color: #737579;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.project-facts dd {
  margin: 0;
  color: #111316;
  font-family: var(--ruel-font-display);
  font-size: 1rem;
  font-weight: 650;
}

.project-showcase__copy {
  max-width: 64ch;
  margin-bottom: 1.25rem;
}

.project-showcase__source {
  max-width: 64ch;
  color: #737579;
  font-size: .86rem;
}

.product-lightbox {
  width: min(92vw, 68rem);
  max-width: none;
  height: min(92vh, 58rem);
  max-height: none;
  padding: 3.5rem 2rem 2rem;
  overflow: hidden;
  background: #f4f2ed;
  border: 0;
  box-shadow: 0 30px 90px rgba(0, 0, 0, .45);
}

.product-lightbox::backdrop {
  background: rgba(10, 11, 13, .82);
}

.product-lightbox img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-lightbox__close {
  position: absolute;
  top: .8rem;
  right: .8rem;
  display: grid;
  width: 2.6rem;
  height: 2.6rem;
  padding: 0;
  place-items: center;
  color: #fff;
  background: #1d1f23;
  border: 0;
  font-size: 1.7rem;
  line-height: 1;
}

/* Services production block: balanced desktop composition with full-width process steps. */
@media (min-width: 992px) {
  #production .row.g-5 {
    display: grid;
    grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr);
    gap: clamp(2.5rem, 5vw, 5rem);
    align-items: center !important;
    margin: 0;
    --bs-gutter-x: 0;
    --bs-gutter-y: 0;
  }

  #production .row.g-5 > .col-lg-5 {
    width: auto;
    padding: 0;
  }

  #production .row.g-5 > .col-lg-7 {
    display: contents;
  }

  #production .section-heading {
    margin-bottom: 0;
  }

  #production .production-section__media {
    grid-column: 2;
    margin-bottom: 0;
  }

  #production .process-list {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: clamp(2.5rem, 5vw, 4.5rem);
  }

  #production .process-list li {
    grid-template-columns: 2.75rem minmax(0, 1fr);
    gap: .75rem;
    padding: 1.5rem clamp(1rem, 2vw, 1.75rem);
    border-right: 1px solid rgba(211, 211, 211, .22);
  }

  #production .process-list li:last-child {
    border-right: 0;
  }
}

@media (max-width: 991.98px) {
  .project-showcase {
    grid-template-columns: 1fr;
  }

  .product-gallery {
    max-width: 40rem;
  }
}

@media (max-width: 767.98px) {
  .notice-panel > h2,
  .notice-panel > :not(h2) {
    grid-column: 1;
    grid-row: auto;
  }

  .notice-panel > h2 {
    margin-bottom: .5rem;
  }

  .project-showcase {
    padding: 1.25rem;
  }

  .product-gallery__thumb {
    flex-basis: 4.8rem;
  }

  .project-facts {
    grid-template-columns: 1fr;
  }

  .product-lightbox {
    width: 96vw;
    height: 86vh;
    padding: 3.25rem 1rem 1rem;
  }
}
