.cambridge-exams {
  width: calc(100% - 40px);
  max-width: 1150px;
  margin: 0 auto;
  padding: 12px 0 36px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.cambridge-exams .ce-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0;
}

.cambridge-exams .ce-breadcrumbs [aria-current] {
  color: #b54210;
}

.cambridge-exams .ce-breadcrumbs a:hover {
  text-decoration: underline;
}

.cambridge-exams .ce-graphic img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  min-height: 0;
  object-fit: contain;
}

.cambridge-exams .ce-hero,
.cambridge-exams .ce-graphic {
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
}

.cambridge-exams .ce-contact {
  display: block;
  border-radius: 8px;
}

.cambridge-exams .ce-carousel {
  min-width: 0;
  width: 100%;
}

/* Keep every slide complete without moving the following sections. */
.cambridge-exams .ce-carousel__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 1672 / 941;
  max-height: calc(100vh - 220px);
  max-height: calc(100svh - 220px);
  overflow: hidden;
  border-radius: 8px;
  background: #fff;
  touch-action: pan-y pinch-zoom;
}

.cambridge-exams .ce-carousel__slide {
  position: absolute;
  inset: 0;
}

.cambridge-exams .ce-is-entering {
  z-index: 1;
  animation: ce-slide-enter 1400ms cubic-bezier(0.22, 0.61, 0.36, 1) both;
  will-change: transform, opacity;
}

/* The soft mask travels from right to left, revealing the next photo below. */
.cambridge-exams .ce-is-leaving {
  z-index: 2;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to right, #000 40%, transparent 60%);
  mask-image: linear-gradient(to right, #000 40%, transparent 60%);
  -webkit-mask-size: 250% 100%;
  mask-size: 250% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  animation: ce-slide-leave 1400ms cubic-bezier(0.22, 0.61, 0.36, 1) both;
  will-change: transform, opacity, filter;
}

@keyframes ce-slide-enter {
  from { transform: translateX(7%); opacity: 0.6; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes ce-slide-leave {
  from {
    transform: translateX(0);
    opacity: 1;
    filter: blur(0);
    -webkit-mask-position: 0% 0%;
    mask-position: 0% 0%;
  }
  to {
    transform: translateX(-6%);
    opacity: 0;
    filter: blur(3px);
    -webkit-mask-position: 100% 0%;
    mask-position: 100% 0%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cambridge-exams .ce-is-entering,
  .cambridge-exams .ce-is-leaving {
    animation: none;
  }
}

.cambridge-exams .ce-carousel__slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cambridge-exams :focus-visible {
  outline: 2px solid #06265a;
  outline-offset: 3px;
}

.cambridge-exams .ce-carousel [hidden] {
  display: none;
}

@media (max-width: 760px) {
  .cambridge-exams {
    width: calc(100% - 24px);
    gap: 20px;
    padding-bottom: 24px;
  }

}

@supports not (aspect-ratio: 1 / 1) {
  .cambridge-exams .ce-carousel__frame::before {
    content: '';
    display: block;
    padding-top: 56.279904%;
  }
}
