/* ==========================================================
   Portfolio Projects
   ========================================================== */

.project {
  padding: 50px 0;

  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.project:last-child {
  border-bottom: none;
}

/* ==========================================================
   Banner Preview
   ========================================================== */

.banner-preview {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.banners {
  position: absolute;
  top: 20px;
  left: 20px;

  width: 955px;
  height: 600px;

  transform-origin: top left;
}

/* ==========================================================
   Banner Positions
   ========================================================== */

.banner {
  display: block;
  overflow: hidden;

  position: absolute;
}

.banner iframe {
  display: block;
  border: 0;

  position: relative;
  z-index: 2;
  opacity: 1;
  /* transition: opacity 0.35s; */
}

.poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 3;
  opacity: 1;
  /* transition: opacity 0.35s ease; */
  pointer-events: none;
}

.poster.hide {
  opacity: 0;
}

.w300 {
  position: absolute;
}

.w160 {
  position: absolute;
  left: 305px;
}

.w970 {
  position: absolute;
  left: 470px;
  transform: scale(0.5);
  transform-origin: top left;
}

.w728 {
  position: absolute;
  top: 130px;
  left: 470px;
  transform: scale(0.666);
  transform-origin: top left;
}

.w300h250 {
  position: absolute;
  top: 196px;
  left: 470px;
  transform: scale(1.616);
  transform-origin: top left;
}

.quidel-video {
  width: 955px;
  height: 600px;
  background: #191a1a;
}

.quidel-video video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.subaru-brochure {
  width: 955px;
  height: 600px;
  background: #191a1a;
}

.subaru-brochure img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ==========================================================
   Floating Carousel Buttons
   ========================================================== */

.carousel-control-prev,
.carousel-control-next {
  position: absolute;
  width: 48px;
  height: 48px;
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
  opacity: 1;
  z-index: 100;
}

.carousel-control-prev {
  left: 25px;
}

.carousel-control-next {
  right: 25px;
}

/* Arrow-only carousel controls */

.carousel-control-prev-icon,
.carousel-control-next-icon {
  width: 24px;
  height: 24px;
  background-image: none;
  border: solid #fff;
  border-width: 0 3px 3px 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.65));
  transition:
    border-color 0.2s ease,
    transform 0.2s ease;
}

.carousel-control-prev-icon {
  transform: rotate(135deg);
}

.carousel-control-next-icon {
  transform: rotate(-45deg);
}

.carousel-control-prev:hover .carousel-control-prev-icon,
.carousel-control-prev:focus-visible .carousel-control-prev-icon,
.carousel-control-next:hover .carousel-control-next-icon {
  border-color: #f8c206;
}

.carousel-control-next:focus-visible .carousel-control-next-icon {
  border-color: #f8c206;
}

/* Anchor indicators below the slide without viewport-based spacing. */
.portfolio-carousel .carousel-indicators {
  top: 100%;
  bottom: auto;
  transform: translateY(20%);
  display: flex;
  justify-content: center;
  gap: 14px;
}

.portfolio-carousel .carousel-indicators button {
  width: auto;
  height: auto;
  padding: 0;
  margin: 0;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.45);
  font-size: 1rem;
  font-weight: 500;
  text-indent: 0;
  opacity: 1;
  transition: color 0.25s;
  font-weight: 300;
}

.portfolio-carousel .carousel-indicators button:hover {
  color: #fff;
}

.portfolio-carousel .carousel-indicators button.active {
  color: #f8c206;
  font-weight: 700;
}

/* ==========================================
   Carousel Header
========================================== */

.carousel-header {
  display: flex;

  justify-content: center;

  align-items: center;

  gap: 20px;

  margin-bottom: 35px;
}

/* Tabs */

.carousel-tabs {
  display: flex;

  align-items: center;

  gap: 18px;
}

.carousel-tab {
  background: none;

  border: none;

  color: #999;

  font-size: 18px;

  cursor: pointer;

  transition: 0.25s;
}

.carousel-tab:hover {
  color: white;
}

.carousel-tab.active {
  color: #f8c206;

  font-weight: 600;
}

.divider {
  color: #555;
}

/* ==========================================================
   Responsive
   ========================================================== */

@media (max-width: 1200px) {
  #web-banners .banner-preview {
    min-height: calc((100vw - 40px) * 600 / 1200 + 40px);
  }
}

@media (min-width: 1440px) {
  .carousel-control-prev {
    left: calc((100% - 1440px) / 2 + 25px);
  }

  .carousel-control-next {
    right: calc((100% - 1440px) / 2 + 25px);
  }
}

@media (max-width: 1024px) {
  .carousel-control-prev,
  .carousel-control-next {
    top: 40%;
  }
}

@media (max-width: 768px) {
  .project {
    margin: 0;
  }

  .project h2 {
    font-size: 1.4rem;
  }
  .carousel-control-prev,
  .carousel-control-next {
    display: none;
  }
  .portfolio-carousel .carousel-indicators button {
    font-size: 0.8rem;
  }
  .project-header p {
    width: 100%;
  }
  .project-header h2 {
    font-size: 1rem;
  }
  .project-header p {
    font-size: 0.9rem;
  }
}
