/* Main hero carousel */
.hero-board.hero-carousel {
  position: relative;
  display: block;
  min-width: 0;
  outline: none;
  isolation: isolate;
  container-type: inline-size;
  touch-action: pan-y;
}

.hero-track-window {
  width: 100%;
  overflow: hidden;
  border-radius: 26px;
  background: #0a0b10;
  box-shadow: 0 30px 80px rgba(16, 18, 27, 0.22);
}

.hero-track {
  width: 100%;
  display: flex;
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform 720ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-track.is-jumping {
  transition: none;
}

.hero-carousel .hero-card {
  flex: 0 0 100%;
  width: 100%;
  height: 580px;
  min-height: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 26px;
  background: #0a0b10;
  box-shadow: none;
  animation: none;
}

.hero-carousel .hero-card::after {
  z-index: 2;
  background: none;
  pointer-events: none;
}

.hero-carousel .hero-backdrop {
  inset: -12%;
  width: 124%;
  height: 124%;
  object-fit: cover;
  filter: blur(34px) brightness(0.68) saturate(1.18);
  transform: scale(1.08);
  opacity: 0.92;
  animation: heroBackdropDrift 9s ease-out both;
}

.hero-carousel .hero-poster {
  position: absolute;
  inset: 0;
  left: 0;
  z-index: 1;
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transform: none;
  user-select: none;
  filter: saturate(1.03) contrast(1.01);
  transition: transform 720ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-carousel .hero-slide:not(.active) .hero-poster {
  transform: scale(0.985);
}

.hero-carousel .hero-slide.active .hero-poster {
  transform: scale(1);
}

.hero-image-vignette {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(6, 7, 11, 0.34), transparent 52%),
    linear-gradient(0deg, rgba(6, 7, 11, 0.42), transparent 44%),
    radial-gradient(circle at center, transparent 46%, rgba(4, 5, 8, 0.18) 100%);
}

.hero-carousel .hero-copy {
  position: absolute;
  left: 30px;
  bottom: 30px;
  z-index: 3;
  width: min(620px, calc(100% - 180px));
  min-height: 0;
  padding: 24px 26px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  display: block;
  background: rgba(8, 9, 14, 0.72);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(20px) saturate(1.25);
  -webkit-backdrop-filter: blur(20px) saturate(1.25);
  animation: none;
}

.hero-carousel .hero-meta {
  margin-bottom: 12px;
}

.hero-carousel .hero-meta span {
  min-height: 27px;
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.1);
  font-size: 11px;
}

.hero-carousel .hero-copy h1 {
  margin: 0 0 10px;
  color: #fff;
  font-size: 48px;
  line-height: 1.08;
  letter-spacing: 0;
  text-wrap: balance;
  text-shadow: 0 3px 18px rgba(0, 0, 0, 0.48);
}

.hero-carousel .hero-copy p {
  display: -webkit-box;
  max-width: 560px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.86);
  font-size: 15px;
  line-height: 1.62;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.36);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.hero-carousel .hero-actions {
  margin-top: 18px;
}

.hero-carousel .hero-actions button {
  min-height: 44px;
  border-radius: 12px;
  transition:
    transform 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

.hero-carousel .hero-actions button:first-child {
  box-shadow: 0 12px 26px rgba(255, 77, 66, 0.28);
}

.hero-carousel .hero-actions button:hover,
.hero-carousel .hero-actions button:focus-visible {
  transform: translateY(-2px);
}

.hero-carousel .hero-page-count {
  top: 24px;
  right: 24px;
  left: auto;
  z-index: 4;
  min-width: 62px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(7, 8, 12, 0.54);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(14px);
}

.hero-nav {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(8, 9, 14, 0.58);
  color: #fff;
  cursor: pointer;
  font-family: Arial, sans-serif;
  font-size: 32px;
  line-height: 1;
  transform: translateY(-50%);
  backdrop-filter: blur(16px);
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease;
}

.hero-nav:hover,
.hero-nav:focus-visible {
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(8, 9, 14, 0.82);
}

.hero-nav-prev {
  left: 18px;
}

.hero-nav-next {
  right: 18px;
}

.hero-controls {
  position: absolute;
  right: 28px;
  bottom: 28px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-dots {
  height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(7, 8, 12, 0.55);
  backdrop-filter: blur(14px);
}

.hero-dots button {
  position: relative;
  width: 7px;
  height: 7px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  padding: 0;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
  transition:
    width 220ms ease,
    background 220ms ease;
}

.hero-dots button.active {
  width: 30px;
  background: rgba(255, 255, 255, 0.34);
}

.hero-dots button.active::after {
  content: "";
  position: absolute;
  inset: 0;
  background: #fff;
  transform-origin: left;
  animation: heroProgress var(--hero-duration, 6500ms) linear both;
}

.hero-carousel:focus-within .hero-dots button.active::after,
.hero-carousel:hover .hero-dots button.active::after,
.hero-carousel.is-paused .hero-dots button.active::after {
  animation-play-state: paused;
}

.hero-pause {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(7, 8, 12, 0.55);
  color: #fff;
  cursor: pointer;
  font-size: 11px;
  backdrop-filter: blur(14px);
}

/* Hero banner admin studio */
.admin-hero-manager {
  display: grid;
  gap: 18px;
}

.admin-hero-manager-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 22px;
  padding: 6px 2px 18px;
  border-bottom: 1px solid #e5e7eb;
}

.admin-hero-manager-head > div > span {
  color: #ef5148;
  font-size: 11px;
  font-weight: 950;
}

.admin-hero-manager-head h2,
.admin-hero-section-title h3 {
  margin: 5px 0 0;
  letter-spacing: 0;
}

.admin-hero-manager-head h2 {
  font-size: 28px;
}

.admin-hero-manager-head p {
  margin: 7px 0 0;
  color: #667085;
  font-size: 14px;
  font-weight: 700;
}

.admin-hero-save {
  min-height: 44px;
  border: 0;
  border-radius: 10px;
  padding: 0 18px;
  background: #111827;
  color: #fff;
  cursor: pointer;
  font-weight: 900;
  box-shadow: 0 12px 25px rgba(17, 24, 39, 0.16);
}

.admin-hero-save:disabled {
  background: #e5e7eb;
  color: #98a2b3;
  cursor: default;
  box-shadow: none;
}

.admin-hero-settings {
  padding: 17px 18px;
  border: 1px solid #e4e7ec;
  border-radius: 12px;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(260px, 0.8fr);
  align-items: center;
  gap: 24px;
  background: #f8fafc;
}

.admin-hero-settings .admin-checkbox {
  margin: 0;
}

.admin-hero-speed {
  display: grid;
  gap: 9px;
}

.admin-hero-speed > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: #344054;
  font-size: 13px;
}

.admin-hero-speed b {
  color: #ef5148;
}

.admin-hero-speed input {
  width: 100%;
  accent-color: #ef5148;
}

.admin-hero-add {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 10px;
}

.admin-hero-add label {
  display: grid;
  gap: 7px;
  color: #475467;
  font-size: 12px;
  font-weight: 900;
}

.admin-hero-add select {
  width: 100%;
  min-height: 44px;
  border: 1px solid #d0d5dd;
  border-radius: 9px;
  padding: 0 12px;
  background: #fff;
  color: #101828;
}

.admin-hero-add > button {
  min-width: 84px;
  min-height: 44px;
  border: 1px solid #ef5148;
  border-radius: 9px;
  background: #fff4f2;
  color: #d92d20;
  cursor: pointer;
  font-weight: 900;
}

.admin-hero-add > button:disabled {
  border-color: #e4e7ec;
  background: #f2f4f7;
  color: #98a2b3;
  cursor: default;
}

.admin-hero-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  align-items: start;
  gap: 18px;
}

.admin-hero-order,
.admin-hero-preview {
  border: 1px solid #e4e7ec;
  border-radius: 12px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.06);
}

.admin-hero-preview {
  position: sticky;
  top: 18px;
}

.admin-hero-section-title {
  min-height: 28px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-hero-section-title h3 {
  font-size: 16px;
}

.admin-hero-section-title span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #ecfdf3;
  color: #067647;
  font-size: 10px;
  font-weight: 950;
}

.admin-banner-list {
  display: grid;
  gap: 8px;
}

.admin-banner-row {
  min-height: 80px;
  border: 1px solid #eaecf0;
  border-radius: 10px;
  padding: 9px 10px;
  display: grid;
  grid-template-columns: 28px 28px 60px minmax(0, 1fr) 42px auto;
  align-items: center;
  gap: 10px;
  background: #fff;
  transition:
    transform 170ms ease,
    border-color 170ms ease,
    box-shadow 170ms ease,
    opacity 170ms ease;
}

.admin-banner-row:hover {
  border-color: #f1a39c;
  box-shadow: 0 10px 22px rgba(16, 24, 40, 0.08);
  transform: translateY(-1px);
}

.admin-banner-row.dragging {
  border-color: #ef5148;
  opacity: 0.55;
  transform: scale(0.99);
}

.admin-banner-row.disabled {
  background: #f9fafb;
  opacity: 0.62;
}

.admin-banner-grip {
  width: 28px;
  height: 38px;
  border: 0;
  padding: 0;
  background: transparent;
  color: #98a2b3;
  cursor: grab;
  font-size: 18px;
  letter-spacing: 0;
}

.admin-banner-grip:active {
  cursor: grabbing;
}

.admin-banner-index {
  color: #98a2b3;
  font-size: 11px;
  font-weight: 950;
}

.admin-banner-row > img {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  background: #eef0f3;
}

.admin-banner-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.admin-banner-copy > span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.admin-banner-copy b,
.admin-banner-copy em {
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.admin-banner-copy b {
  color: #175cd3;
}

.admin-banner-copy em {
  color: #667085;
}

.admin-banner-copy strong {
  overflow: hidden;
  color: #101828;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-banner-copy small {
  color: #98a2b3;
  font-size: 11px;
}

.admin-banner-toggle {
  position: relative;
  width: 38px;
  height: 22px;
}

.admin-banner-toggle input {
  position: absolute;
  opacity: 0;
}

.admin-banner-toggle span {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: #d0d5dd;
  cursor: pointer;
  transition: background 160ms ease;
}

.admin-banner-toggle span::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(16, 24, 40, 0.2);
  transition: transform 160ms ease;
}

.admin-banner-toggle input:checked + span {
  background: #12b76a;
}

.admin-banner-toggle input:checked + span::after {
  transform: translateX(16px);
}

.admin-banner-actions {
  display: flex;
  gap: 5px;
}

.admin-banner-actions button {
  width: 30px;
  height: 30px;
  border: 1px solid #e4e7ec;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #fff;
  color: #475467;
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
}

.admin-banner-actions button:disabled {
  color: #d0d5dd;
  cursor: default;
}

.admin-banner-actions button.remove {
  border-color: #fecdca;
  background: #fff4f2;
  color: #ff4d42;
}

.admin-hero-preview-stage {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 10px;
  background: #0b0c10;
}

.admin-hero-preview-stage .preview-backdrop {
  position: absolute;
  inset: -12%;
  width: 124%;
  height: 124%;
  object-fit: cover;
  filter: blur(18px) brightness(0.62) saturate(1.15);
}

.admin-hero-preview-stage .preview-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.admin-hero-preview-stage > div {
  position: absolute;
  right: 12px;
  bottom: 12px;
  left: 12px;
  padding: 11px 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  display: grid;
  gap: 3px;
  background: rgba(7, 8, 12, 0.7);
  color: #fff;
  backdrop-filter: blur(12px);
}

.admin-hero-preview-stage small,
.admin-hero-preview-stage span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
}

.admin-hero-preview-stage strong {
  overflow: hidden;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-hero-preview > p {
  margin: 12px 2px 0;
  color: #667085;
  font-size: 12px;
  line-height: 1.6;
  font-weight: 700;
}

.admin-hero-preview-empty {
  min-height: 210px;
  border: 1px dashed #d0d5dd;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #98a2b3;
  font-size: 13px;
  font-weight: 800;
}

@keyframes heroSlideEnter {
  from {
    opacity: 0;
    transform: scale(0.992);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes heroCopyEnter {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes heroBackdropDrift {
  from {
    transform: scale(1.08) translate3d(-1%, 0, 0);
  }
  to {
    transform: scale(1.14) translate3d(1%, -0.5%, 0);
  }
}

@keyframes heroProgress {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@media (max-width: 980px) {
  .hero-carousel .hero-card {
    height: 540px;
  }

  .hero-carousel .hero-copy {
    width: min(580px, calc(100% - 120px));
  }

  .hero-carousel .hero-copy h1 {
    font-size: 40px;
  }

  .admin-hero-workspace {
    grid-template-columns: 1fr;
  }

  .admin-hero-preview {
    position: static;
  }
}

@media (max-width: 680px) {
  .hero-track-window {
    border-radius: 18px;
  }

  .hero-carousel .hero-card {
    height: 590px;
    border-radius: 18px;
  }

  .hero-carousel .hero-poster {
    object-position: center top;
  }

  .hero-image-vignette {
    background:
      linear-gradient(0deg, rgba(5, 6, 9, 0.78), transparent 60%),
      radial-gradient(
        circle at center,
        transparent 42%,
        rgba(4, 5, 8, 0.18) 100%
      );
  }

  .hero-carousel .hero-copy {
    right: 12px;
    bottom: 52px;
    left: 12px;
    width: auto;
    padding: 18px;
    border-radius: 12px;
  }

  .hero-carousel .hero-copy h1 {
    font-size: 30px;
  }

  .hero-carousel .hero-copy p {
    font-size: 13px;
    -webkit-line-clamp: 2;
  }

  .hero-carousel .hero-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .hero-carousel .hero-actions button {
    min-height: 42px;
    padding: 0 12px;
    font-size: 12px;
  }

  .hero-carousel .hero-page-count {
    top: 14px;
    right: 14px;
  }

  .hero-nav {
    top: 40%;
    width: 38px;
    height: 38px;
    font-size: 26px;
  }

  .hero-nav-prev {
    left: 10px;
  }

  .hero-nav-next {
    right: 10px;
  }

  .hero-controls {
    right: 14px;
    bottom: 12px;
  }

  .admin-hero-manager-head {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-hero-save {
    width: 100%;
  }

  .admin-hero-settings {
    grid-template-columns: 1fr;
  }

  .admin-hero-add {
    grid-template-columns: 1fr;
  }

  .admin-banner-row {
    grid-template-columns: 24px 48px minmax(0, 1fr) 38px;
    gap: 8px;
  }

  .admin-banner-index {
    display: none;
  }

  .admin-banner-row > img {
    width: 48px;
    height: 48px;
  }

  .admin-banner-actions {
    grid-column: 2 / -1;
    justify-content: flex-end;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-track,
  .hero-carousel .hero-card,
  .hero-carousel .hero-backdrop,
  .hero-carousel .hero-copy,
  .hero-dots button.active::after {
    animation: none;
  }

  .hero-track {
    transition-duration: 1ms;
  }
}

/* The public app stays phone-width on many desktop layouts. Size the hero by
   its real container instead of the browser viewport. */
.hero-carousel .hero-copy {
  right: 16px;
  bottom: 66px;
  left: 16px;
  width: auto;
  padding: 20px;
}

.hero-carousel .hero-copy h1 {
  font-size: 34px;
}

.hero-carousel .hero-copy p {
  font-size: 14px;
}

.hero-carousel .hero-nav {
  top: 41%;
}

.hero-carousel .hero-controls {
  right: 16px;
  bottom: 14px;
}

@container (min-width: 700px) {
  .hero-carousel .hero-copy {
    right: auto;
    bottom: 30px;
    left: 30px;
    width: min(620px, calc(100% - 180px));
    padding: 24px 26px;
  }

  .hero-carousel .hero-copy h1 {
    font-size: 48px;
  }

  .hero-carousel .hero-copy p {
    font-size: 15px;
  }

  .hero-carousel .hero-nav {
    top: 50%;
  }

  .hero-carousel .hero-controls {
    right: 28px;
    bottom: 28px;
  }
}

/* Compact split hero: image on the left, content on the right. */
.hero-carousel.hero-split .hero-track-window,
.hero-carousel.hero-split .hero-card {
  border-radius: 0;
}

.hero-carousel.hero-split {
  --hero-split-height: 330px;
}

.hero-carousel.hero-split .hero-track-window,
.hero-carousel.hero-split .hero-track,
.hero-carousel.hero-split .hero-card,
.hero-carousel.hero-split .hero-poster {
  height: var(--hero-split-height);
}

.hero-carousel.hero-split .hero-track-window {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: #0a0c11;
  box-shadow: 0 18px 42px rgba(16, 18, 27, 0.16);
}

.hero-carousel.hero-split .hero-card {
  border: 0;
  background: #0a0c11;
}

.hero-carousel.hero-split .hero-backdrop {
  top: -8%;
  right: auto;
  bottom: -8%;
  left: -8%;
  width: 70%;
  height: 116%;
  object-fit: cover;
  filter: blur(22px) brightness(0.62) saturate(1.14);
  opacity: 0.8;
  transform: scale(1.06);
  animation: none;
}

.hero-carousel.hero-split .hero-poster {
  top: 0;
  right: auto;
  bottom: 0;
  left: 0;
  width: 61%;
  min-height: var(--hero-split-height);
  max-height: none;
  object-fit: cover;
  object-position: center center;
  -webkit-mask-image: linear-gradient(
    90deg,
    #000 0%,
    #000 74%,
    rgba(0, 0, 0, 0.72) 86%,
    transparent 100%
  );
  mask-image: linear-gradient(
    90deg,
    #000 0%,
    #000 74%,
    rgba(0, 0, 0, 0.72) 86%,
    transparent 100%
  );
}

.hero-carousel.hero-split .hero-image-vignette {
  background: linear-gradient(
    90deg,
    rgba(8, 10, 14, 0.04) 0%,
    rgba(8, 10, 14, 0.08) 38%,
    rgba(10, 12, 17, 0.62) 53%,
    #0a0c11 64%,
    #0a0c11 100%
  );
}

.hero-carousel.hero-split .hero-copy {
  top: 20px;
  right: 14px;
  bottom: 18px;
  left: 60%;
  width: auto;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.hero-carousel.hero-split .hero-meta {
  flex-wrap: nowrap;
  gap: 5px;
  margin: 0 0 10px;
  overflow: hidden;
}

.hero-carousel.hero-split .hero-meta span {
  min-height: 22px;
  padding: 0 7px;
  border-color: rgba(255, 255, 255, 0.13);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 9px;
  white-space: nowrap;
}

.hero-carousel.hero-split .hero-meta span:nth-child(3) {
  display: none;
}

.hero-carousel.hero-split .hero-copy h1 {
  margin: 0 0 9px;
  color: #fff;
  font-size: 24px;
  line-height: 1.14;
  text-wrap: wrap;
  word-break: keep-all;
  overflow-wrap: break-word;
}

.hero-carousel.hero-split .hero-copy p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.72);
  font-size: 11.5px;
  line-height: 1.52;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.hero-carousel.hero-split .hero-actions {
  width: 100%;
  margin-top: auto;
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: 6px;
}

.hero-carousel.hero-split .hero-actions button {
  flex: 1 1 0;
  min-width: 0;
  min-height: 32px;
  height: 32px;
  border-radius: 7px;
  padding: 0 8px;
  gap: 4px;
  font-size: 10.5px;
  box-shadow: none;
}

.hero-carousel.hero-split .hero-actions svg {
  width: 13px;
  height: 13px;
}

.hero-carousel.hero-split .hero-page-count {
  top: 10px;
  right: auto;
  left: 10px;
  min-width: 50px;
  height: 28px;
  font-size: 10px;
}

.hero-carousel.hero-split .hero-nav {
  top: 50%;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 23px;
}

.hero-carousel.hero-split .hero-nav-prev {
  left: 8px;
}

.hero-carousel.hero-split .hero-nav-next {
  right: auto;
  left: calc(52% - 38px);
}

.hero-carousel.hero-split .hero-controls {
  right: auto;
  bottom: 10px;
  left: 10px;
  gap: 6px;
}

.hero-carousel.hero-split .hero-dots {
  height: 28px;
  padding: 0 9px;
  gap: 5px;
}

.hero-carousel.hero-split .hero-pause {
  width: 28px;
  height: 28px;
  font-size: 9px;
}

@container (max-width: 390px) {
  .hero-carousel.hero-split .hero-track-window {
    --hero-split-height: 310px;
  }

  .hero-carousel.hero-split .hero-copy {
    top: 16px;
    right: 10px;
    bottom: 14px;
  }

  .hero-carousel.hero-split .hero-copy h1 {
    font-size: 21px;
  }

  .hero-carousel.hero-split .hero-copy p {
    font-size: 10.5px;
    -webkit-line-clamp: 4;
  }

  .hero-carousel.hero-split .hero-actions button {
    min-height: 30px;
    height: 30px;
    padding: 0 6px;
    font-size: 9.5px;
  }
}

@container (min-width: 700px) {
  .hero-carousel.hero-split .hero-track-window {
    --hero-split-height: 390px;
  }

  .hero-carousel.hero-split .hero-poster {
    width: 62%;
  }

  .hero-carousel.hero-split .hero-copy {
    top: 36px;
    right: 30px;
    bottom: 28px;
    left: 57%;
  }

  .hero-carousel.hero-split .hero-copy h1 {
    font-size: 36px;
  }

  .hero-carousel.hero-split .hero-copy p {
    font-size: 14px;
  }

  .hero-carousel.hero-split .hero-actions {
    width: min(280px, 100%);
    align-self: flex-end;
  }

  .hero-carousel.hero-split .hero-actions button {
    min-height: 36px;
    height: 36px;
    font-size: 11px;
  }

  .hero-carousel.hero-split .hero-nav-next {
    left: calc(57% - 40px);
  }
}

/* Result presentation: overlap the rounded copy card with the image edge. */
.result-layout > .result-image-stack + .result-panel {
  position: relative;
  z-index: 2;
}

/* Fit every detail cover without cropping; blurred duplicate fills letterboxing. */
.detail-visual {
  isolation: isolate;
  overflow: hidden;
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  background: #080b10;
}

.detail-visual > .detail-backdrop {
  position: absolute;
  inset: -8%;
  z-index: 0;
  display: block;
  width: 116%;
  height: 116%;
  object-fit: cover;
  filter: blur(24px) brightness(0.62) saturate(1.05);
  transform: scale(1.08);
  pointer-events: none;
}

.detail-visual > .detail-art {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  aspect-ratio: auto;
  object-fit: contain;
}

/* Tighten poster-to-title and row spacing in the test card grid. */
.card-grid .test-card {
  margin-bottom: 30px;
}

.card-grid .test-card .card-copy {
  bottom: -24px;
}

/* Multiline choice editing and rendering. */
.admin-field-compact-textarea textarea {
  min-height: 64px;
  padding-block: 10px;
}

.choice-text {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* Keep the card title still while preserving poster hover motion. */
.test-card:hover .card-copy,
.test-card:focus-visible .card-copy {
  transform: none;
}
