:root {
  --page-no: #d0d0d0;
}
.dark-theme {
  --page-no: #d0d0d0;
}

.gallery-wrapper {
  height: 100vh;
  overflow: hidden;
  position: relative;
  padding-top: 8rem;
  padding-bottom: 5rem;
}

.gallery {
  display: flex;
  /* gap: 1rem; */
  height: 100%;
  padding-inline: 2rem;
  will-change: transform;
}

.gallery article {
  position: relative;
  flex: 0 0 auto;
  /* width: 34rem; */
  /* height: calc(100vh - 16rem); */
  /* aspect-ratio: 547/590; */
  padding-right: 30px;
  font-size: 18px;
  color: var(--primary-color);
  overflow: hidden;
  transition: transform 0.3s;
}
/* .gallery article video { */
.gallery article figure,
.gallery article .video-wrapper {
  margin: 0 0 0.5rem;
  padding: 0;
  height: 82%;
  aspect-ratio: 0.73;

  /* margin: 0 0 0.5rem; */
  /* height: 82%; */
  /* aspect-ratio: 0.73; */
  overflow: hidden;
  border-radius: 10px;
}
.gallery article img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  /* border-radius: 10px; */
}
.gallery article video {
  width: 100%;
  object-fit: cover;
  display: block;
  /* border-radius: 10px; */
}
.gallery article h4 {
  /* font-family: "acumin-pro", sans-serif; */
  font-weight: normal;
  font-style: normal;
  font-size: 18px;
  line-height: 24px;
  letter-spacing: -2%;
  margin: 0 0 0.125rem;
}
.gallery article p {
  margin: 0;
  padding: 0;
  color: var(--footer-text-secondary);
  letter-spacing: -2%;
}
.gallery article .cover-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  text-decoration: none;
}

.filters {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 41;
  display: flex;
  width: fit-content;
  padding: 0.625rem 1.25rem;
  margin: auto;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  border-radius: 0.6875rem;
  background: linear-gradient(90deg, #f0f0f0 0%, #e4e4e4 57.21%, #f4f4f4 100%);
}

.filters button {
  color: #0d0d0d;
  border: 0 none;
  background: none transparent;
  font-size: 14px;
  font-style: normal;
  font-weight: 200;
  line-height: normal;
  letter-spacing: -3%;
  text-transform: uppercase;
  cursor: pointer;
}

.filters button:hover {
  color: #2a2a2a;
}
.filters button.active {
  font-weight: 600;
}

.hidden {
  display: none !important;
}

/* project details  */
.showcase {
  display: flex;
  flex-wrap: nowrap;
  /* justify-content: center; */
  /* align-items: center; */
  /* padding: 0 2rem; */
  height: 100vh;
  will-change: transform;
  touch-action: pan-y;
}

.showcase article {
  flex: 0 0 99vw;
  display: grid;
  grid-template-columns: 56% 1fr;
  /* min-height: 100vh; */
}
.showcase article.no-detail {
  flex: 0 0 auto;
  grid-template-columns: 1fr 19.75rem;
}
.showcase article.last {
  flex: 0 0 auto;
  grid-template-columns: 1fr;
  grid-template-rows: 9rem 1fr 8rem;
  align-content: center;
  padding-inline: 2rem;
}

.product-image {
  min-height: 0;
  position: relative;
  overflow: clip;
  transform-origin: center;
  will-change: transform, opacity;
}

@media (hover: hover) and (pointer: fine) {
  .cursor-hover {
    cursor: none;
  }
}

.cursor-hover {
  overflow: clip;
}
.cursor-hover .cursor-figure {
  position: absolute;
  top: 0;
  left: 0;
  width: 190px;
  height: 190px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 1);
  border: 1px solid rgba(255,255,255,0.35);
  box-shadow: 2px 2px 0 -2px rgba(255, 255, 255, 0.5) inset;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.9);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s ease;
  z-index: 10;
  color: #0d0d0d;
  font-size: 1.5rem;
  font-style: normal;
  text-transform: uppercase;
  font-weight: 200;
}

.product-image figure {
  padding: 0;
  margin: 0;
}

.product-image img,
.product-image video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform-origin: center;
}

.product-image img[data-parallax-speed] {
  width: calc(100% + 1rem);
  max-width: none;
  margin-left: -0.5rem;
  will-change: transform;
}
.product-image.vertical {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  aspect-ratio: 0.875;
}

.product-image.vertical > * {
  flex-basis: 50dvh;
  overflow: hidden;
}

.product-details {
  background: var(--background-color);
  color: var(--primary-color);
  padding: clamp(8rem, 16.5vh, 9.5rem) clamp(40px, 6.25vw, 120px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  /* overflow-y: auto; */
  min-height: 0;
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
  position: relative;
}

article.no-detail .product-details {
  /* padding: 4rem 3rem; */
  justify-content: flex-end;
}
article.last .product-image {
  /* width: 42.75rem; */
  /* height: 48.4375rem; */
  aspect-ratio: 218/247;
}
article.last .product-details {
  flex-direction: row;
  justify-content: space-between;
  padding: 1rem 0;
}
article.last a {
  color: var(--primary-color);
  text-decoration: none;
}

.product-details h1 {
  color: var(--primary-color);
  font-family: "degular", sans-serif;
  font-size: 2.125rem;
  font-style: normal;
  font-weight: 600;
  line-height: 1.75rem;
  letter-spacing: -1px;
  margin: 0 0 0.5rem;
}
.product-details h3 {
  color: var(--primary-color);
  font-family: "degular", sans-serif;
  font-size: 1.25rem;
  font-style: normal;
  font-weight: 600;
  line-height: 1.5rem;
  letter-spacing: -1px;
  margin: 0 0;
}
.product-details > span {
  color: var(--primary-color);
  font-size: 1.25rem;
  font-style: normal;
  font-weight: 200;
  line-height: 1.75rem;
  position: absolute;
  bottom: 4rem;
  left: 3rem;
}

.product-details h1,
.product-details h2,
.product-details h3,
.product-details h4,
.product-details p {
  opacity: 0;
  transform: translate(0, 20px);
}

.description {
  font-size: 1rem;
  font-style: normal;
  font-weight: 200;
  line-height: 22px;
  /* letter-spacing: -0.045rem; */
  margin: 6px 0;
}

.specs {
  margin-top: clamp(3rem, 8.75vh, 5rem);
  font-size: 1rem;
  font-style: normal;
  font-weight: 200;
  line-height: 22px;
  /* letter-spacing: -0.045rem; */
}
.specs h4 {
  color: var(--footer-text-secondary);
  font-size: 1.5rem;
  font-style: normal;
  font-weight: 400;
  line-height: 1.5625rem; /* 104.167% */
  letter-spacing: -4%;
  margin: 0;
}
.specs p {
  margin: 6px 0;
}

.product-details .discuss {
  max-width: clamp(14vw, 16.25rem, 18rem);
  color: var(--footer-text-secondary);
  font-size: 1.125rem;
  font-style: normal;
  font-weight: 300;
  line-height: normal;
  letter-spacing: -0.045rem;
}

.product-details .discuss h4 {
  color: var(--secondary-color);
  font-size: 1.25rem;
  font-style: normal;
  font-weight: 600;
  line-height: 1.5rem;
  letter-spacing: -2%;
  margin: 0;
}

.product-details .discuss p {
  margin-block: 0.5rem 1.5rem;
  font-size: 1.125rem;
  font-style: normal;
  font-weight: 200;
  line-height: normal;
  /* letter-spacing: -4%; */
}
.product-details .mag-zone {
  width: auto;
  height: auto;
  padding: 1rem;
  justify-self: flex-start;
  left: -1rem;
}
.product-details .btn {
  padding: 1rem 1.5rem;
  justify-content: center;
  border-radius: 5rem;
  background: var(--secondary-color);
  color: var(--background-color);
  font-weight: 600;
  letter-spacing: -0.02625rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 300ms ease;
}
.product-details .btn img {
  height: 16px;
  flex-shrink: 0;
}
.product-details .btn:hover {
  opacity: 0.9;
}

.video-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.video-actions .btn {
  min-width: 12rem;
  justify-content: center;
  border: 1px solid transparent;
}

.video-actions .btn.secondary {
  background: transparent;
  color: var(--primary-color);
  border-color: rgba(255, 255, 255, 0.24);
}

.video-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  /* padding: clamp(1rem, 3vw, 2rem); */
  background: rgba(0, 0, 0, 0.94);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.video-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.video-modal-frame {
  position: relative;
  /* width: min(100%, 1120px); */
  /* aspect-ratio: 16 / 9; */
  background: #000;
  /* border-radius: 1rem; */
  overflow: hidden;
  /* box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45); */
  transform: scale(0.96);
  transition: transform 0.25s ease;
}

.video-modal.is-open .video-modal-frame {
  transform: scale(1);
  width: 100%;
  height: 100%;
}

.video-modal-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-modal-content video,
.video-modal-content iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}
.video-modal-content video {
  object-fit: contain;
}
.video-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #0d0d0d;
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
}

body.modal-open {
  overflow: hidden;
}

.product-image .hover {
  position: absolute;
  inset: 0;
  top: calc(50% - 80px);
  left: calc(50% - 80px);
  width: 190px;
  height: 190px;
  background: transparent url("../images/circle.svg") no-repeat center;
  background-size: contain;
  color: #0d0d0d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-style: normal;
  font-weight: 400;
  line-height: 1.5625rem;
  letter-spacing: -0.06rem;
  text-transform: uppercase;
}

.product-image .video-trigger {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: none transparent;
  border: 0 none;
}

.services-list {
  font-size: 18px;
  font-style: normal;
  font-weight: 200;
  line-height: 24px;
  letter-spacing: -2%;
  margin: 6px 0;
}
.services-list p {
  margin-block: 0 0;
}
.desktop-only {
  display: block;
}
.mobile-only {
  display: none;
}

@media screen and (max-width: 1600px) {
  .specs {
    margin-top: 2rem;
  }
  
}

@media screen and (max-width: 800px) {
  html, body {
    overflow: auto;
    overflow-x: auto;
    overflow-y: auto !important;
  }
  .desktop-only {
    display: none;
  }
  .mobile-only {
    display: block;
  }
  .navbar {
    inset: 0;
    transform: none;
  }
  .container {
    grid-template-columns: 1fr;
    padding-top: 6rem;
  }
  .product-details {
    padding: 2rem;
  }
  .filters {
    display: none;
  }
  .gallery-wrapper {
    padding-top: 6rem;
    padding-bottom: 3rem;
    height: auto;
  }
  .gallery {
    flex-direction: column;
    gap: 2rem;
    height: auto;
    padding-inline: 1rem;
  }
  .gallery article {
    width: 100%;
    height: auto;
    padding-right: 0;
  }
  .showcase {
    flex-direction: column;
    height: auto;
  }
  .showcase article {
    flex: 0 0 auto;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 1rem;
  }
  .showcase article.no-detail {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    /* padding: 1rem; */
  }
  .showcase article.outcome .product-image,
  .showcase article.no-detail .product-image {
    padding:0 2rem;
  }
  .showcase article.last {
    display: flex;
    gap: 0;
    flex-direction: column-reverse;
    padding: 1rem;
  }
  .product-details.mobile-only {
    padding: 1rem;
  }
  
  .product-details > span {
    bottom: calc(100% - 1.125rem);
    left: calc(100% - 3rem);
  }
  .product-image.vertical {
    gap: 1rem;
  }
  .product-image video {
    object-fit: contain;
  }
  article.outcome .description {
    max-width: 312px;
  }
  article.outcome .product-details .discuss {
    margin-top: 3.75rem !important;
  }
  .product-details h1,
  .product-details h2,
  .product-details h3,
  .product-details h4,
  .product-details p {
    opacity: 1;
    transform: none;
  }
}
