/* =========================================================
   DepthCarousel — ported from React Bits, retinted to Hairmix brand
========================================================= */
.depth-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: var(--dc-perspective, 1400px);
  perspective-origin: 50% 50%;
  touch-action: pan-y;
  outline: none;
  user-select: none;
  -webkit-user-select: none;
  cursor: grab;
}
.depth-carousel:active{ cursor: grabbing; }
.depth-carousel:focus-visible{
  outline: 2px solid var(--gold);
  outline-offset: 6px;
  border-radius: 12px;
}

.depth-carousel__stage{
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
}

.depth-carousel__card{
  position: absolute;
  top: 50%;
  left: 50%;
  transform-origin: center center;
  overflow: hidden;
  background: var(--espresso);
  box-shadow: var(--shadow-soft);
  will-change: transform, opacity, filter;
  cursor: pointer;
  transform: translate(-50%, -50%);
}

.depth-carousel__img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  -webkit-user-drag: none;
  transition: transform 160ms var(--ease), filter 160ms var(--ease);
}
.depth-carousel__card:active .depth-carousel__img{
  transform: scale(.96);
  filter: brightness(.92);
}

.depth-carousel__tint{
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  mix-blend-mode: multiply;
}

.depth-carousel__arrow{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3000;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--ink);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease);
}
@media (hover: hover) and (pointer: fine){
  .depth-carousel__arrow:hover{
    background: var(--gold);
    border-color: var(--gold);
    transform: translateY(-50%) scale(1.06);
  }
}
.depth-carousel__arrow:active{ transform: translateY(-50%) scale(0.94); }
.depth-carousel__arrow--prev{ left: clamp(.5rem, 2vw, 1.5rem); }
.depth-carousel__arrow--next{ right: clamp(.5rem, 2vw, 1.5rem); }

.depth-carousel__dots{
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3000;
  display: flex;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(20, 23, 19, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.depth-carousel__dot{
  position: relative;
  width: 22px;
  height: 7px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transform: scaleX(.318);
  transition: transform var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}
.depth-carousel__dot::before{
  content: "";
  position: absolute;
  inset: -9px;
}
.depth-carousel__dot.is-active{
  transform: scaleX(1);
  background: var(--gold);
}
.depth-carousel__dot:active{ transform: scaleX(.318) scale(.8); }
.depth-carousel__dot.is-active:active{ transform: scaleX(1) scale(.8); }

.gallery-carousel{
  position: relative;
  height: clamp(400px, 46vw, 580px);
  margin-top: .5rem;
}

@media (prefers-reduced-motion: reduce){
  .depth-carousel__card{ will-change: auto; }
  .depth-carousel__arrow, .depth-carousel__dot{ transition: none; }
}

@media (max-width: 640px){
  .depth-carousel__arrow{ width: 40px; height: 40px; }
}
