/* ================= CAROUSEL (shared) =================
   Markup: .carousel > .carousel-viewport > .carousel-track > .carousel-slide*
   Behaviour lives in assets/js/carousel.js. Slides visible at once: --pv. */
.carousel{
  --pv:3;
  --gap:24px;
  position:relative;
}
.carousel-viewport{overflow:hidden;}
/* Edge bleed: the viewport is not clipped, so slides run past the container out to the screen edge.
   The section around the carousel clips at the screen (overflow:hidden). */
.carousel--bleed .carousel-viewport{overflow:visible;}
.carousel-track{
  display:flex;
  gap:var(--gap);
  will-change:transform;
}
.carousel-slide{
  flex:0 0 calc((100% - (var(--pv) - 1) * var(--gap)) / var(--pv));
  min-width:0;
}

.carousel-controls{
  display:flex;
  gap:10px;
}
.carousel-btn{
  display:flex;
  align-items:center;
  justify-content:center;
  width:40px;
  height:40px;
  color:var(--text);
  background:var(--white);
  border:1px solid rgba(13,13,13,.35);
  transition:background .2s ease, color .2s ease, border-color .2s ease;
}
.carousel-btn svg{width:16px;height:16px;}
.carousel-btn:hover{background:var(--text);color:var(--white);border-color:var(--text);}
.carousel-btn:focus-visible{outline:2px solid var(--text);outline-offset:3px;}
.carousel-btn:disabled{opacity:.3;cursor:default;pointer-events:none;} /* no more cards that way */

/* round arrows + page dots (used by the Industrial deep-dive and news carousels) */
.carousel-btn--round{
  width:38px;
  height:38px;
  border:none;
  border-radius:50%;
  background:rgba(13,13,13,.08);
}
.carousel-btn--round:hover{background:var(--text);color:var(--white);}
.carousel-dots{
  display:flex;
  align-items:center;
  gap:10px;
}
.carousel-dot{
  width:11px;
  height:11px;
  padding:0;
  border-radius:50%;
  background:rgba(13,13,13,.16);
  transition:background .25s ease, transform .25s ease;
}
.carousel-dot:hover{background:rgba(13,13,13,.4);}
.carousel-dot[aria-current="true"]{background:var(--text);}
.carousel-dot:focus-visible{outline:2px solid var(--text);outline-offset:3px;}

@media (max-width:980px){
  .carousel{--pv:2;}
}
@media (max-width:640px){
  .carousel{--pv:1;--gap:16px;}
}
