/* BPT Slider - Standalone Slider Component */
.bpt-slider {
  --bpt-slider-gap: 30px;
  --bpt-slider-primary-size: 1.75rem;
  --bpt-slider-secondary-size: 1.5rem;
  --bpt-slider-border-radius: 0px;
  --bpt-slider-transition: 0.3s ease;
  margin: 0;
  padding: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
}

/* Splide customization */
.bpt-slider .splide {
  position: relative;
  width: 100%;
  max-width: 100%;
}

.bpt-slider .splide .splide__track {
  overflow: hidden;
  width: 100%;
}

.bpt-slider .splide .splide__list {
  width: 100%;
}

/* Constrain slider height */
.bpt-slider .splide,
.bpt-slider .splide .splide__track,
.bpt-slider .splide .splide__list,
.bpt-slider .splide .splide__slide {
  max-height: 700px;
}

.bpt-slider .splide .splide__slide {
  width: 100%;
}

/* Stretch to match fixed slider height (multi-slide only) */
.bpt-slider .splide:not(.splide--single) .splide__slide,
.bpt-slider .splide:not(.splide--single) .bpt-slider__item,
.bpt-slider .splide:not(.splide--single) .bpt-slider__media {
  height: 100%;
}
.bpt-slider .splide:not(.splide--single) .splide__slide { display: flex; }
.bpt-slider .splide:not(.splide--single) .bpt-slider__media {
  aspect-ratio: auto;
}
/* Reduce vertical padding when centered to avoid overflow in fixed height */
.bpt-slider .splide:not(.splide--single) .bpt-slider__content {
  padding-top: 40px;
  padding-bottom: 40px;
}

/* Ensure proper stacking and height for fade */
.bpt-slider .splide .splide__list {
  position: relative;
  width: 100%;
}

.bpt-slider .splide .splide__track {
  overflow: hidden;
  width: 100%;
}

/* Single item styling - no slider */
.bpt-slider .splide--single {
  display: block;
}

.bpt-slider .splide--single .splide__track {
  overflow: visible;
}

.bpt-slider .splide--single .splide__list {
  display: block;
}

.bpt-slider .splide--single .splide__slide {
  display: block;
  width: 100%;
  position: relative; /* Override absolute for single item */
  opacity: 1; /* Override opacity for single item */
}

/* Single item overrides to ensure natural height */
.bpt-slider .splide--single .bpt-slider__item {
  height: auto;
}

.bpt-slider .splide--single .bpt-slider__media {
  height: auto;
}

/* Slider item styling */
.bpt-slider__item {
  position: relative;
  box-sizing: border-box;
  background: #ffffff;
  border: none;
  border-radius: 0px;
  overflow: hidden;
  height: auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  margin: 0;
  transition: transform var(--bpt-slider-transition), box-shadow var(--bpt-slider-transition);
}

/* Flat overlay over media (no shapes) */
.bpt-slider__item::before {
  content: '';
  position: absolute;
  pointer-events: none;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--ast-global-color-2);
  opacity: 0.75;
  z-index: 1;
}

/* Media section - now full height */
.bpt-slider__media {
  position: relative;
  overflow: hidden;
  border-radius: 0px;
  aspect-ratio: 21/9;
  height: auto;
  width: 100%;
  flex: 0 0 auto;
}

.bpt-slider__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--bpt-slider-transition);
}

.bpt-slider__item:hover .bpt-slider__img {
  transform: scale(1.05);
}

/* Content section - now overlay */
.bpt-slider__content {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 60px 80px;
  display: flex;
  flex-direction: column;
  justify-content: center; /* vertically center content */
  gap: 16px;
  background: transparent;
  color: #ffffff;
  height: 100%;
  z-index: 2; /* above overlay */
}

/* Constrain inner content to 1300px while keeping overlay full width */
.bpt-slider__content > .bpt-slider__header,
.bpt-slider__content > .bpt-slider__description,
.bpt-slider__content > .bpt-slider__actions {
  max-width: 1300px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-right: clamp(0, 10vw, 300px);
}

.bpt-slider__header {
  display: flex;
  flex-direction: column;
  gap: 8px;
  
}

.bpt-slider__date {
  font-size: 0.875rem;
  color: rgba(255,255,255,0.8);
  font-weight: 500;
}

.bpt-slider__title {
  font-size: 3em;
  line-height: 1.5em;
  letter-spacing: 0em;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
}

.bpt-slider__description {
  font-size: 1rem;
  color: rgba(255,255,255,0.9);
  line-height: 1.6;
  margin: 0;
}

/* Actions section */
.bpt-slider__actions {
  display: flex;
  gap: 16px;
  margin-top: 0; /* avoid pushing actions out when centering vertically */
}

.bpt-slider__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 15px 30px;
  border-radius: 0px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1em;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: box-shadow 0.2s ease, background-color var(--bpt-slider-transition), color var(--bpt-slider-transition), border-color var(--bpt-slider-transition);
  border: 1px solid var(--ast-global-color-0);
  cursor: pointer;
  border-radius: 9999px;
  text-decoration: none;
}

/* Remove underline in all states */
.bpt-slider__btn,
.bpt-slider__btn:hover,
.bpt-slider__btn:focus,
.bpt-slider__btn:visited {
  text-decoration: none !important;
}

/* Accessible focus style */
.bpt-slider__btn:focus-visible {
  outline: 2px solid var(--ast-global-color-4);
  outline-offset: 2px;
}

.bpt-slider__btn--primary {
  background: var(--ast-global-color-0);
  color: #fff;
  border-color: var(--ast-global-color-0);
}

.bpt-slider__btn--primary:hover {
  background: var(--ast-global-color-0);
  border-color: var(--ast-global-color-0);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

.bpt-slider__btn--secondary {
  background: transparent;
  color: var(--ast-global-color-4);
  border-color: var(--ast-global-color-0);
}

.bpt-slider__btn--secondary:hover {
  background: var(--ast-global-color-0);
  color: var(--ast-global-color-2);
  border-color: var(--ast-global-color-0);
}

.bpt-slider__btn-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* Splide arrows customization */
.bpt-slider .splide .splide__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: 2px solid rgba(255,255,255,0.3);
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  z-index: 10;
  transition: all var(--bpt-slider-transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Hide arrows for single item */
.bpt-slider .splide--single .splide__arrow {
  display: none;
}

.bpt-slider .splide .splide__arrow:hover {
  background: rgba(255,255,255,1);
  border-color: rgba(255,255,255,0.8);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.bpt-slider .splide .splide__arrow svg {
  width: 20px;
  height: 20px;
  fill: #1a1a1a;
}

.bpt-slider .splide .splide__arrow--prev {
  left: 20px;
}

.bpt-slider .splide .splide__arrow--next {
  right: 20px;
}

/* No content fallback */
.bpt-slider__no-content {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 200px;
  background: #f8f9fa;
  color: #667085;
  font-size: 1rem;
  border-radius: 24px;
}

/* Responsive design */
@media (max-width: 768px) {
  .bpt-slider .splide .splide__arrow--prev {
    left: 10px;
  }
  
  .bpt-slider .splide .splide__arrow--next {
    right: 10px;
  }
  
  .bpt-slider .splide .splide__arrow {
    width: 40px;
    height: 40px;
  }
  
  .bpt-slider__content {
    padding: 40px 30px;
    gap: 12px;
  }
  
  .bpt-slider__title {
    font-size: 1.75rem;
  }
  
  .bpt-slider__actions {
    gap: 12px;
  }
  
  .bpt-slider__btn {
    padding: 10px 20px;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .bpt-slider__content {
    padding: 30px 20px;
  }
  
  .bpt-slider__title {
    font-size: 1.5rem;
  }
  
  .bpt-slider__actions {
    flex-direction: column;
  }
  
  .bpt-slider__btn {
    justify-content: center;
  }
}

/* Visually hidden but accessible */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
