/* ==========================================================================
   Custom additions (not part of the Webflow export)
   ========================================================================== */

/* --------------------------------------------------------------------------
   In-project auto slideshow
   Matches the homepage hero slider: 650ms delay, 0ms transition (hard cut).
   -------------------------------------------------------------------------- */

.project_slider {
  width: 100%;
  height: auto;
  aspect-ratio: 1400 / 920;
  background-color: #fff;
  text-align: left;
}

.project_slider_mask {
  height: 100%;
}

.project_slider_mask .w-slide {
  height: 100%;
}

.project_slide_image {
  object-fit: cover;
  width: 100%;
  height: 100%;
  max-width: none;
  display: block;
}

.project_slider_arrow,
.project_slider_nav {
  display: none;
}

/* --------------------------------------------------------------------------
   Browser simulation — scrolls a full-page screenshot up and down, then
   moves on to the next page and loops.
   -------------------------------------------------------------------------- */

.browser_sim {
  width: 100%;
  background-color: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .35);
}

.browser_sim_chrome {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 38px;
  padding: 0 14px;
  background-color: #e8e8e8;
  border-bottom: 1px solid #d5d5d5;
}

.browser_sim_dots {
  display: flex;
  gap: 7px;
  flex: 0 0 auto;
}

.browser_sim_dots span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background-color: #ddd;
}

.browser_sim_dots span:nth-child(1) { background-color: #ff5f57; }
.browser_sim_dots span:nth-child(2) { background-color: #febc2e; }
.browser_sim_dots span:nth-child(3) { background-color: #28c840; }

.browser_sim_url {
  flex: 0 1 420px;
  height: 23px;
  margin: 0 auto;
  background-color: #fff;
  border-radius: 999px;
}

.browser_sim_spacer {
  flex: 0 0 44px;
}

.browser_sim_viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 1440 / 900;
  overflow: hidden;
  background-color: #fff;
}

.browser_sim_page {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: auto;
  max-width: none;
  display: block;
  will-change: transform;
}

@media screen and (max-width: 767px) {
  .browser_sim_chrome {
    height: 30px;
    gap: 10px;
    padding: 0 10px;
  }

  .browser_sim_dots span {
    width: 8px;
    height: 8px;
  }

  .browser_sim_url {
    flex: 0 1 240px;
    height: 17px;
  }

  .browser_sim_spacer {
    flex: 0 0 30px;
  }
}

/* --------------------------------------------------------------------------
   Phone frame — same scroll simulation as the browser frame, in a handset.
   -------------------------------------------------------------------------- */

.phone_sim {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  padding: 10px;
  background-color: #1c1c1e;
  border-radius: 42px;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .45);
}

.phone_sim_viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 393 / 852;
  overflow: hidden;
  border-radius: 32px;
  background-color: #fff;
}

.phone_sim_notch {
  position: absolute;
  z-index: 2;
  top: 9px;
  left: 50%;
  transform: translateX(-50%);
  width: 31%;
  height: 21px;
  border-radius: 999px;
  background-color: #1c1c1e;
}

/* --------------------------------------------------------------------------
   Styleguide slider — panels of mixed proportions fitted whole onto one
   desktop-shaped canvas, so nothing is cropped as they cycle.
   -------------------------------------------------------------------------- */

.styleguide_slider_frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background-color: #f3f3f3;
  overflow: hidden;
}

.styleguide_slider {
  position: relative;
  width: 100%;
  height: 100%;
  background-color: #f3f3f3;
  text-align: left;
}

/* Held over the slider until every panel has decoded, so the cycle never
   runs ahead of the images. Removed by js/styleguide-slider.js. */

.styleguide_slider_loader {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f3f3f3;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}

.styleguide_slider_frame.is-loading .styleguide_slider_loader {
  opacity: 1;
}

.styleguide_slider_spinner {
  width: 28px;
  height: 28px;
  border: 2px solid rgba(28, 28, 30, .15);
  border-top-color: rgba(28, 28, 30, .55);
  border-radius: 50%;
  animation: styleguide_spin .7s linear infinite;
}

@keyframes styleguide_spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .styleguide_slider_spinner {
    border-top-color: rgba(28, 28, 30, .15);
    animation: styleguide_pulse 1.4s ease-in-out infinite;
  }

  @keyframes styleguide_pulse {
    0%, 100% { opacity: .3; }
    50% { opacity: 1; }
  }
}

.styleguide_slider_mask {
  height: 100%;
}

.styleguide_slider_mask .w-slide {
  height: 100%;
}

.styleguide_slide_image {
  object-fit: contain;
  object-position: 50% 50%;
  width: 100%;
  height: 100%;
  max-width: none;
  padding: 3%;
  display: block;
}

@media screen and (max-width: 767px) {
  .phone_sim {
    max-width: 210px;
    padding: 7px;
    border-radius: 30px;
  }

  .phone_sim_viewport {
    border-radius: 23px;
  }

  .phone_sim_notch {
    top: 6px;
    height: 15px;
  }
}
