.tobor-slider-section {
  --tobor-slider-bg: #ffffff;
  --tobor-slider-text: #525252;
  --tobor-slider-muted: #525252;
  --tobor-slider-border: #A3A3A3;
  --tobor-slider-accent: #506ccd;
  --tobor-slider-shadow: 0 12px 42px -4px rgba(24, 39, 75, 0.12), 0 8px 18px -6px rgba(24, 39, 75, 0.12);
  /* one shared width so the tab row, viewport and slide all match:
     exactly one card, centered, with no peek of the next card */
  --tobor-slider-w: min(1248px, calc(100vw - 96px));
  box-sizing: border-box;
  width: 100%;
  overflow: hidden;
  padding: 88px 0 78px;
  background: var(--tobor-slider-bg);
  color: var(--tobor-slider-text);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.tobor-slider-section *,
.tobor-slider-section *::before,
.tobor-slider-section *::after {
  box-sizing: border-box;
}

.tobor-slider-section__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.tobor-slider-section__header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  text-align: center;
}

.tobor-slider-section__header h2 {
  width: 100%;
  margin: 0;
  color: var(--tobor-slider-text);
  font-size: 48px;
  font-weight: 700;
  line-height: 56px;
  letter-spacing: 0;
}

.tobor-slider-section .tobor-slider-section__header p {
  width: min(960px, 100%);
  margin: 0;
  color: var(--tobor-slider-text);
  font-size: 20px;
  font-weight: 400;
  line-height: 28px;
}

.tobor-slider-section__nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 20px;
  flex: 1 1 auto;
  min-width: 0;
}

.tobor-slider-section__nav-row {
  display: flex;
  align-items: center;
  gap: 24px;
  width: var(--tobor-slider-w);
  margin: 44px auto 32px;
}

.tobor-slider-section__arrows {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 0 0 auto;
}

.tobor-slider-section__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  padding: 0;
  border: 1px solid #525252;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
  color: #525252;
  cursor: pointer;
  transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
}

.tobor-slider-section__arrow:hover,
.tobor-slider-section__arrow:focus {
  border-color: #171717;
  background: #f7f7f7;
  color: #171717;
}

.tobor-slider-section__arrow span {
  display: block;
  width: 15px;
  height: 15px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.tobor-slider-section__arrow--prev span {
  transform: rotate(-135deg);
  margin-left: 4px;
}

.tobor-slider-section__arrow--next span {
  transform: rotate(45deg);
  margin-right: 4px;
}

.tobor-slider-section__nav-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 14px 32px;
  border: 1.5px solid var(--tobor-slider-border);
  border-radius: 999px;
  background: transparent;
  color: var(--tobor-slider-text);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 24px;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
  white-space: nowrap;
}

.tobor-slider-section__nav-button.is-active {
  border-color: var(--tobor-slider-accent);
  background: var(--tobor-slider-accent);
  color: #ffffff;
}

.tobor-slider-section__viewport {
  /* one card wide + room on each side; the padding lets the card's drop
     shadow render while overflow stays clipped so no next card peeks */
  width: calc(var(--tobor-slider-w) + 80px);
  max-width: calc(100vw - 16px);
  margin: 0 auto;
  padding: 40px 40px 56px;
  overflow: hidden;
}

.tobor-slider-section__track {
  display: flex;
  /* gap must exceed the viewport side-padding + a card's shadow reach, so the
     next card (and its shadow) stay fully clipped and don't bleed in on the right */
  gap: 96px;
  width: max-content;
  transform: translate3d(0, 0, 0);
  transition: transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.tobor-slider-section__slide {
  display: grid;
  /* copy takes the remaining space; media column is a fixed fraction so its
     width is definite (no feedback loop) and it renders as a 4:3 box */
  grid-template-columns: minmax(0, 1fr) minmax(0, 55.6%);
  align-items: center;
  width: var(--tobor-slider-w);
  min-height: 500px;
  overflow: hidden;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: var(--tobor-slider-shadow);
}

.tobor-slider-section__slide-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  min-width: 0;
  padding: 80px 80px;
}

.tobor-slider-section__slide-copy h3 {
  width: 100%;
  margin: 0 0 32px;
  color: #111827;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 34px;
  font-weight: 700;
  line-height: 42px;
  letter-spacing: 0;
}

.tobor-slider-section .tobor-slider-section__slide-copy p {
  width: 100%;
  margin: 0 0 34px;
  color: var(--tobor-slider-muted);
  font-size: 22px;
  font-weight: 400;
  line-height: 32px;
}

.tobor-slider-section__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--tobor-slider-accent);
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
  text-decoration: none;
}

.tobor-slider-section__link:hover,
.tobor-slider-section__link:focus {
  color: var(--tobor-slider-accent);
  text-decoration: none;
}

.tobor-slider-section__link span {
  width: 9px;
  height: 9px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: rotate(45deg);
}

.tobor-slider-section__media {
  position: relative;
  /* 4:3 media box; its width is the (definite) grid column, height follows
     the ratio. Not stretched, so the ratio is preserved. */
  align-self: center;
  aspect-ratio: 4 / 3;
  min-width: 0;
  overflow: hidden;
  background: #f5f5f5;
}

.tobor-slider-section__media img,
.tobor-slider-section__media video,
.tobor-slider-section__placeholder {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tobor-slider-section__placeholder {
  background:
    radial-gradient(circle at 68% 58%, #d8dee7 0 18%, transparent 18.3%),
    linear-gradient(135deg, rgba(80, 108, 205, 0.22), rgba(153, 195, 0, 0.16)),
    linear-gradient(180deg, #f6f7f9, #e3e7ee);
}

.tobor-slider-section__dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 40px;
}

.tobor-slider-section__dots button {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #d4d4d4;
  cursor: pointer;
}

.tobor-slider-section__dots button.is-active {
  background: var(--tobor-slider-accent);
}

/* @media (max-width: 1199px) {
  .tobor-slider-section {
    padding-top: 72px;
  }

  .tobor-slider-section__viewport {
    width: calc(100vw - 32px);
  }

  .tobor-slider-section__slide {
    width: calc(100vw - 80px);
  }

  .tobor-slider-section__viewport {
    padding: 0 24px 42px;
  }

  .tobor-slider-section__header h2 {
    font-size: 40px;
    line-height: 48px;
  }

  .tobor-slider-section__slide {
    min-height: 520px;
  }

  .tobor-slider-section__slide-copy {
    padding: 56px 44px;
  }

  .tobor-slider-section__media img,
  .tobor-slider-section__placeholder {
    min-height: 520px;
  }
} */

@media (max-width: 1024px) {
  .tobor-slider-section {
    padding: 56px 0 48px;
  }

  .tobor-slider-section__header h2 {
    font-size: 34px;
    line-height: 40px;
  }

  .tobor-slider-section__header p {
    font-size: 18px;
    line-height: 26px;
  }

  .tobor-slider-section__nav-row {
        width: 100%;
        margin: 32px 0;
        gap: 0;
    }

  .tobor-slider-section__nav {
        justify-content: flex-start;
        overflow-x: auto;
        padding: 0 20px 4px;
        width: 100%;
        flex-direction: row;
        display: flex;
        flex-wrap: nowrap;
    }

  .tobor-slider-section__arrows {
    display: none;
  }

  .tobor-slider-section__nav-button {
    min-height: 48px;
    padding: 12px 20px;
  }

  .tobor-slider-section__track {
    gap: 72px;
  }

  .tobor-slider-section__viewport {
    width: calc(100vw - 8px);
    /* let vertical page scroll pass through while we handle horizontal swipes */
    touch-action: pan-y;
    cursor: grab;
  }

  .tobor-slider-section.is-dragging .tobor-slider-section__viewport {
    cursor: grabbing;
  }

  /* avoid selecting the card text mid-swipe */
  .tobor-slider-section.is-dragging,
  .tobor-slider-section.is-dragging * {
    user-select: none;
  }

  .tobor-slider-section__slide {
    width: calc(100vw - 40px);
  }

  .tobor-slider-section__viewport {
    padding: 0 16px 34px;
  }

  .tobor-slider-section__slide {
    grid-template-columns: 1fr;
    align-items: stretch;
    min-height: 0;
  }

  .tobor-slider-section__slide-copy {
    padding: 34px 24px;
  }

  .tobor-slider-section__slide-copy h3 {
    margin-bottom: 20px;
    font-size: 28px;
    line-height: 34px;
  }

  .tobor-slider-section__slide-copy p {
    margin-bottom: 24px;
    font-size: 20px;
    line-height: 28px;
  }

  .tobor-slider-section__media {
    order: -1;
    align-self: stretch;
    width: 100%;
  }

  .tobor-slider-section__media img,
  .tobor-slider-section__media video,
  .tobor-slider-section__placeholder {
    min-height: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tobor-slider-section__track,
  .tobor-slider-section__nav-button,
  .tobor-slider-section__arrow {
    transition: none;
  }
}
