.cs-wrap { max-width: 1400px; margin-left: auto; margin-right: auto; }

/* ---------- Kicker (numbered section label) ---------- */
.cs-kicker {
  display: inline-flex; align-items: center; gap: 14px;
  font-size: 12px; font-weight: 600; letter-spacing: 2px;
  text-transform: uppercase; color: #6b7280;
}
.cs-kicker::after {
  content: ''; width: 40px; height: 1px;
  background: currentColor; opacity: .45;
}
.cs-kicker__n { color: rgba(var(--primary-color), 1); font-weight: 700; }
.cs-kicker--light { color: rgba(255, 255, 255, .78); }
.cs-kicker--light .cs-kicker__n { color: #fff; }
.cs-kicker--center { justify-content: center; }
.cs-kicker--center::before {
  content: ''; width: 40px; height: 1px;
  background: currentColor; opacity: .45; order: -1;
}

/* ---------- Hero ---------- */
.cs-hero { position: relative; overflow: hidden; }

.cs-hero__stage { position: absolute; inset: 0; z-index: 0; }

.cs-hero__media { position: absolute; inset: 0; overflow: hidden; z-index: 1; }
.cs-hero__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover; display: block;
  opacity: 0;
  transition: opacity .9s ease;
}
.cs-hero__video.is-active { opacity: 1; }
.cs-hero__media iframe,
.cs-hero__media video,
.cs-hero__media .wistia_embed,
.cs-hero__media .wistia_responsive_padding,
.cs-hero__media .wistia_responsive_wrapper {
  position: absolute !important; inset: 0 !important;
  width: 108% !important; height: 100% !important;
  border: 0; object-fit: cover;
}
.cs-hero__scrim {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
            background:
    radial-gradient(120% 82% at 50% 30%,
      rgba(8, 5, 20, .14) 0%, rgba(8, 5, 20, .34) 54%, rgba(8, 5, 20, .62) 100%),
    linear-gradient(180deg,
      rgba(8, 5, 20, .34) 0%, rgba(8, 5, 20, .12) 24%, rgba(8, 5, 20, .48) 74%, rgba(8, 5, 20, .84) 100%);
}

/* In normal flow above the media, so its own height drives the hero. */
.cs-hero__body {
  position: relative; z-index: 3;
  display: flex; flex-direction: column; justify-content: center;
  min-height: 100vh;
  padding: 118px 0 84px;
  text-align: center;
}
.cs-hero h1 {
  letter-spacing: -1.4px;
  text-shadow: 0 2px 40px rgba(0, 0, 0, .35);
}
.cs-hero__lead { color: rgba(255, 255, 255, .8); }
.cs-hero__cta { justify-content: center; }
.cs-hero__cta .btn { flex: 0 0 auto; }
.cs-sentinel { display: block; height: 1px; }

/* ---------- Case study video reel ----------*/
.cs-vs__dots { display: flex; justify-content: center; gap: 10px; padding-top: 48px; }
.cs-vs__dot {
  width: 9px; height: 9px; padding: 0; border: 0; border-radius: 999px;
  background: rgba(255, 255, 255, .34); cursor: pointer;
  transition: width .3s cubic-bezier(.2, .8, .2, 1), background-color .3s ease;
}
.cs-vs__dot[aria-current="true"] { width: 32px; background: #fff; }
.cs-vs__dot:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }


/* ---------- Intro figures ----------*/
.cs-figures {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: #e7e2f4;
  border: 1px solid #ebe7f7;
  border-radius: 22px;
  overflow: hidden;
}
.cs-figures li {
  position: relative;
  padding: 36px 32px;
  background: linear-gradient(160deg, #fbfaff 0%, #f4f1fc 100%);
  transition: background-color .35s ease;
}
.cs-figures li:hover { background: #fff; }
.cs-figures li::before {
  content: ''; position: absolute; left: 32px; top: 38px;
  width: 3px; height: 32px; border-radius: 999px;
  background: rgba(var(--primary-color), 1);
}
.cs-figures__n {
  display: block; padding-left: 24px;
  font-family: var(--number-font);
  font-size: 46px; line-height: 1; letter-spacing: -1.4px;
  color: #14111f;
}
.cs-figures__l {
  display: block; padding: 15px 0 0 24px;
  font-size: 14px; line-height: 1.5; color: #4b5563;
}

/* ---------- Dark statement band ---------- */
.cs-statement { position: relative; overflow: hidden; background: #0d0a18; padding: 110px 0; }
.cs-statement::before {
  content: ''; position: absolute; left: 50%; top: -46%;
  width: 940px; height: 940px; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(var(--primary-color), .3) 0%, rgba(var(--primary-color), 0) 62%);
  pointer-events: none;
}
.cs-statement > .container { position: relative; z-index: 2; }
.cs-statement__glyph { font-size: 30px; line-height: 1; color: rgba(var(--primary-color), 1); }
.cs-statement__text {
  font-size: 30px; font-weight: 700; line-height: 1.28; letter-spacing: -.8px;
  color: #fff; margin: 24px 0 0; padding: 0;
}

/* ---------- Small shared bits ---------- */
.cs-attr { color: #6b7280; }
.cs-impact { background: linear-gradient(180deg, #fff 0%, #f7f5fd 12%, #f7f5fd 100%); }
.cs-footer { border-top: 1px solid #e5e7eb; }
.cs-link {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600; color: rgba(var(--primary-color), 1);
}
.cs-link i { transition: transform .3s cubic-bezier(.2, .8, .2, 1); }
.cs-link:hover { color: rgba(var(--primary-color), 1); }
.cs-link:hover i { transform: translate(3px, -3px); }

.cs-chart circle,
.cs-chart polyline { fill: none; }
.cs-chart--radial { transform: rotate(-90deg); }
.cs-chart circle.cs-chart__dot { fill: currentColor; }

/* ---------- Filter bar ----------*/
.cs-filterbar { position: sticky; top: 80px; z-index: 40; padding: 16px 0; }
.cs-filter {
  background: #fff;
  border: 1px solid #ece9f5;
  border-radius: 20px;
  padding: 6px;
  transition: box-shadow .35s ease, background-color .35s ease;
}
.cs-filterbar.is-stuck .cs-filter {
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(14px);
  box-shadow: 0 18px 40px -26px rgba(17, 24, 39, .45);
}
.cs-filter--tabs { display: flex; flex-direction: column; }

/* ---------- Tabs ---------- */
.cs-tabs {
  display: flex; align-items: stretch; gap: 4px;
  padding: 8px 14px 0;
  border-bottom: 1px solid #f0eef7;
  overflow-x: auto;
  scrollbar-width: none; -ms-overflow-style: none;
}
.cs-tabs::-webkit-scrollbar { display: none; }
.cs-tab {
  position: relative;
  background: none; border: 0;
  padding: 13px 18px 15px;
  font-size: 13px; font-weight: 600; letter-spacing: .2px;
  color: #6b7280; white-space: nowrap; cursor: pointer;
  border-radius: 12px 12px 0 0;
  transition: color .25s ease, background-color .25s ease;
}
.cs-tab:hover { color: #14111f; background: #faf8ff; }

.cs-tab::after {
  content: ''; position: absolute; left: 18px; right: 18px; bottom: -1px;
  height: 2px; border-radius: 2px;
  background: rgba(var(--primary-color), 1);
  transform: scaleX(0);
  transition: transform .3s cubic-bezier(.2, .8, .2, 1);
}
.cs-tab[aria-selected="true"] { color: rgba(var(--primary-color), 1); }
.cs-tab[aria-selected="true"]::after { transform: scaleX(1); }
.cs-tab:focus-visible { outline: 2px solid rgba(var(--primary-color), 1); outline-offset: -3px; }
.cs-tab__count {
  display: inline-block; margin-left: 9px;
  padding: 1px 8px; border-radius: 999px;
  background: #f2eff9; color: #6b7280;
  font-size: 11px; font-weight: 700;
  font-variant-numeric: tabular-nums;
  transition: background-color .25s ease, color .25s ease;
}
.cs-tab[aria-selected="true"] .cs-tab__count {
  background: rgba(var(--primary-color), .14);
  color: rgba(var(--primary-color), 1);
}

.cs-tabpanel { padding: 20px; }
.cs-tabpanel[hidden] { display: none; }
.cs-filter__track { display: flex; flex-wrap: wrap; gap: 8px; }

/* Chips navigate to the category archive — they are links, not toggles. */
.cs-chip {
  display: inline-block;
  background: #fff;
  border: 1px solid #e0e2e7;
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px; font-weight: 500;
  line-height: 1.3; color: #374151;
  white-space: nowrap;
  transition: background-color .25s ease, border-color .25s ease, color .25s ease;
}
.cs-chip:hover {
  background: var(--primary-color-dark);
  border-color: var(--primary-color-dark);
  color: #fff;
}
.cs-chip:focus-visible { outline: 2px solid rgba(var(--primary-color), 1); outline-offset: 2px; }
/* The archive template marks the chip matching the current category. */
.cs-chip.is-current {
  background: var(--primary-color-dark);
  border-color: var(--primary-color-dark);
  color: #fff;
}

/* ---------- Impact bento ---------- */
.cs-tile {
  position: relative;
  height: 100%; min-height: 340px;
  border-radius: 22px;
  overflow: hidden;
  transition: transform .4s cubic-bezier(.2, .8, .2, 1), box-shadow .4s ease;
}
.cs-tile--white { background: #fff; box-shadow: inset 0 0 0 1px #ece9f5; }
.cs-tile--white:hover {
  transform: translateY(-4px);
  box-shadow: inset 0 0 0 1px #e4dff4, 0 34px 60px -34px rgba(17, 24, 39, .3);
}
.cs-tile--purple { background: rgba(var(--primary-color), 1); color: #fff; }
.cs-tile--plum { background: #4c3482; color: #fff; }
.cs-tile--lime { background: #f2f7a1; }
.cs-tile--purple:hover,
.cs-tile--plum:hover,
.cs-tile--lime:hover { transform: translateY(-4px); box-shadow: 0 34px 60px -34px rgba(76, 52, 130, .5); }

.cs-tile__body {
  position: relative; z-index: 2;
  padding: 32px; display: flex; flex-direction: column; height: 100%;
}
.cs-tile__kicker {
  font-size: 11px; font-weight: 700; letter-spacing: 1.6px;
  text-transform: uppercase; color: #6b7280;
  padding: 0 0 18px; margin: 0;
}
.cs-tile--purple .cs-tile__kicker,
.cs-tile--plum .cs-tile__kicker { color: rgba(255, 255, 255, .7); }
.cs-stat { font-family: var(--number-font); font-size: 56px; line-height: 1; letter-spacing: -1px; }
.cs-tile__viz { flex: 1; display: flex; align-items: center; justify-content: center; padding: 20px 0; }
.cs-tile__glyph { font-size: 118px; opacity: .2; }

/* Attribution rail — every number names its source. */
.cs-tile__foot {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: auto; padding-top: 18px;
  border-top: 1px solid rgba(17, 24, 39, .09);
  font-size: 13px; font-weight: 600;
}
.cs-tile--purple .cs-tile__foot,
.cs-tile--plum .cs-tile__foot { border-top-color: rgba(255, 255, 255, .24); }
.cs-tile--lime .cs-tile__foot { border-top-color: rgba(17, 24, 39, .16); }

.cs-bar { width: 84px; border-radius: 14px; height: 0; transition: height 900ms cubic-bezier(.2, .8, .2, 1); }
.cs-bar--muted { background: linear-gradient(180deg, #e5ddf7, #ccbbf0); }
.cs-bar--brand { background: linear-gradient(180deg, #9978e1, #6645ae); transition-delay: 120ms; }
.cs-bar--thin { width: 54px; }

/* ---------- Story tile ----------*/
.cs-story { min-height: 0; display: flex; flex-direction: column; background: #e9eaee; }
.cs-story__img {
  width: 100%; height: 230px; object-fit: cover;
  transition: transform 1.1s cubic-bezier(.2, .8, .2, 1);
}
.cs-story:hover .cs-story__img { transform: scale(1.05); }
.cs-story__panel {
  background: linear-gradient(140deg, #fff 0%, #f1f0f7 100%);
  padding: 30px;
  display: flex; flex-direction: column; justify-content: space-between;
  flex: 1;
}
.cs-story__panel--tint { background: linear-gradient(140deg, #f7f4fd 0%, #e9e3f7 100%); }


.cs-story__logo {
  display: inline-flex; align-items: center;
  height: 48px; padding: 8px 16px;
  background: #fff; border: 1px solid #ece9f5; border-radius: 12px;
}
.cs-story__logo img { height: 24px; width: auto; }
.cs-story__quote {
  font-size: 21px; font-weight: 700; line-height: 1.36;
  letter-spacing: -.3px;
  padding: 24px 0 16px; margin: 0;
}

/* ---------- Figure ledger (platform metrics) ----------*/
.cs-ledger {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  background: #fff;
  border: 1px solid #ece9f5;
  border-radius: 24px;
  box-shadow: 0 44px 90px -64px rgba(17, 24, 39, .5);
  overflow: hidden;
}
.cs-ledger__cell {
  position: relative;
  display: flex; flex-direction: column;
  padding: 40px 36px 34px;
  transition: background-color .35s ease;
}
.cs-ledger__cell:hover { background: #fcfbff; }
.cs-ledger__cell + .cs-ledger__cell { border-left: 1px solid #f0eef7; }
/* Accent rule, flush with the top edge — the one spot of brand colour. */
.cs-ledger__cell::before {
  content: ''; position: absolute; top: 0; left: 36px;
  width: 44px; height: 3px; border-radius: 0 0 3px 3px;
  background: rgba(var(--primary-color), 1);
}
.cs-ledger__head { display: flex; align-items: center; gap: 12px; }
.cs-ledger__icon {
  width: 34px; height: 34px; flex: 0 0 34px;
  border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  background: #f4f0fe; color: rgba(var(--primary-color), 1);
  font-size: 15px;
}
.cs-ledger__tag {
  font-size: 11px; font-weight: 700; letter-spacing: 1.6px;
  text-transform: uppercase; color: #6b7280;
}
.cs-ledger__num {
  font-family: var(--number-font);
  font-size: 60px; line-height: 1; letter-spacing: -2px;
  color: #14111f;
  margin: 0; padding: 28px 0 0;
}
.cs-ledger__copy { color: #4b5563; margin: 0; padding: 14px 0 0; }

.cs-ledger__foot {
  margin: 0 0 0; padding: 24px 0 0; margin-top: auto;
  font-size: 12px; font-weight: 600; letter-spacing: .2px; color: #9ca3af;
}
.cs-ledger__foot::before {
  content: ''; display: block;
  width: 100%; height: 1px; background: #f0eef7;
  margin-bottom: 16px;
}

/* ---------- Closing CTA + customer wall ----------*/
.cs-wall {
  position: relative; overflow: hidden;
  background: #f7f5fd;
  padding: 90px 0 0;
}
.cs-wall__rows {
  display: flex; flex-direction: column; gap: 14px;
  padding-bottom: 90px;
  /* The fade is what stops the wall competing with the CTA above it. */
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 34%, rgba(0, 0, 0, .35) 74%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 34%, rgba(0, 0, 0, .35) 74%, transparent 100%);
}
.cs-wall__row { overflow: hidden; }
.cs-wall__track {
  display: flex; width: max-content; gap: 14px;
  animation: cs-wall-scroll var(--dur) linear infinite;
}
/* Alternating direction is what makes the stack read as a wall, not a list. */
.cs-wall__row:nth-child(even) .cs-wall__track { animation-direction: reverse; }
/* Offsets stop the pill seams lining up into vertical gutters. */
.cs-wall__row:nth-child(2) .cs-wall__track { margin-left: -70px; }
.cs-wall__row:nth-child(3) .cs-wall__track { margin-left: -150px; }
.cs-wall__row:nth-child(4) .cs-wall__track { margin-left: -40px; }
.cs-wall:hover .cs-wall__track { animation-play-state: paused; }

.cs-pill {
  display: inline-flex; align-items: center; justify-content: center;
  flex: 0 0 auto;
  height: 66px; min-width: 156px; padding: 0 30px;
  background: #fff;
  border: 1px solid #eceef2;
  border-radius: 16px;
  box-shadow: 0 8px 20px -14px rgba(17, 24, 39, .28);
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), box-shadow .3s ease, border-color .3s ease;
}

.cs-pill img { max-height: 24px; max-width: 132px; width: auto; height: auto; object-fit: contain; filter: grayscale(1);}
.cs-pill:hover {
  transform: translateY(-3px);
  border-color: rgba(var(--primary-color), .45);
  box-shadow: 0 16px 30px -16px rgba(var(--primary-color), .45);
}
  .cs-pill:hover img{filter:none;}
.cs-pill:focus-visible { outline: 2px solid rgba(var(--primary-color), 1); outline-offset: 3px; }
@keyframes cs-wall-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Scroll reveal (class added by JS, so no-JS shows everything) ---------- */
.cs-reveal { opacity: 0; transform: translateY(24px); }
.cs-reveal.is-in {
  opacity: 1; transform: none;
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1);
}

/* ==========================================================
  * Breakpoints — theme values only (767 / 992 / 1200)
  * ========================================================== */
@media (max-width: 767px) {

  .cs-hero__body { min-height: 0; padding: 92px 0 60px; }
  .cs-vs__dots { padding-top: 34px; }
  .cs-figures { grid-template-columns: minmax(0, 1fr); }
  .cs-figures li { padding: 28px 24px; }
  .cs-figures li::before { left: 24px; top: 30px; }
  .cs-figures__n { font-size: 38px; }
  .cs-stat { font-size: 46px; }
  .cs-ledger__cell { padding: 30px 24px 26px; }
  .cs-ledger__cell::before { left: 24px; }
  .cs-ledger__num { font-size: 50px; }
  .cs-tile__body { padding: 24px; }
  .cs-story__quote { font-size: 19px; }
  .cs-statement { padding: 66px 0; }
  .cs-statement__text { font-size: 25px; }

  /* One swipeable line per group instead of a wrapped block of pills. */
  .cs-filter__track {
    flex-wrap: nowrap; overflow-x: auto;
    scrollbar-width: none; -ms-overflow-style: none;
    margin: 0 -18px; padding: 0 18px 2px;
    /* Fade the trailing edge so a half-cut pill reads as "swipe for more". */
    -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 42px), transparent 100%);
    mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 42px), transparent 100%);
  }
  .cs-filter__track::-webkit-scrollbar { display: none; }
  .cs-tabpanel { padding: 18px; }
  .cs-tab { padding: 12px 14px 14px; }
  .cs-tab::after { left: 14px; right: 14px; }
  .cs-filterbar { position: static; padding: 0 0 8px; }
}

@media (max-width: 991px) {
  .cs-ledger { grid-template-columns: minmax(0, 1fr); }
  .cs-ledger__cell + .cs-ledger__cell { border-left: 0; border-top: 1px solid #f0eef7; }
  .cs-figures { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cs-wall { padding: 60px 0 0; }
  .cs-wall__rows { margin-top: 44px; padding-bottom: 60px; gap: 10px; }
  .cs-pill { height: 56px; min-width: 130px; padding: 0 22px; }
  .cs-pill img { max-height: 20px; max-width: 112px; }
}

@media (min-width: 992px) {
  .cs-story { display: block; min-height: 430px; }
  .cs-story__img { position: absolute; inset: 0; height: 100%; }
  .cs-story__panel {
    position: absolute; top: 16px; bottom: 16px; left: 16px;
    width: 46%; border-radius: 18px; padding: 32px;
  }
}

@media (min-width: 1200px) {
  .cs-hero h1 { letter-spacing: -2px; }
  .cs-stat { font-size: 66px; }
  .cs-ledger__num { font-size: 72px; }
  .cs-figures__n { font-size: 54px; }
  .cs-story__quote { font-size: 24px; }
  .cs-statement__text { font-size: 46px; }
}

@media (prefers-reduced-motion: reduce) {
  .cs-wall__track { animation: none; }
  .cs-bar, .cs-tile, .cs-story__img,
  .cs-ledger__cell, .cs-figures li { transition: none; }
  .cs-reveal { opacity: 1; transform: none; }
}

@media (max-width: 600px) {
  .cs-figures { grid-template-columns: repeat(1, minmax(0, 1fr)); }
}

.cs-tile__link {
  display: inline-flex; align-items: center; gap: 8px;
  color: inherit;
}
.cs-tile__link::after { content: ''; position: absolute; inset: 0; z-index: 4; }
.cs-tile__link:hover { color: inherit; }
.cs-tile__link i { font-size: .9em; transition: transform .3s cubic-bezier(.2, .8, .2, 1); }
.cs-tile:hover .cs-tile__link i { transform: translate(3px, -3px); }
.cs-tile__link:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  .cs-tile__link i { transition: none; }
}

.tax-casestudy-category .cs-cathero,
.tax-casestudy-usecase .cs-cathero {
  position: relative; overflow: hidden;
  background: #0d0a18;
  padding: 72px 0 80px;
}
.tax-casestudy-category .cs-cathero::before,
.tax-casestudy-usecase .cs-cathero::before {
  content: ''; position: absolute; left: 50%; top: -52%;
  width: 1040px; height: 1040px; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(var(--primary-color), .32) 0%, rgba(var(--primary-color), 0) 62%);
  pointer-events: none;
}
/* Hairline grid, barely there — stops the flat black reading as an error. */
.tax-casestudy-category .cs-cathero::after,
.tax-casestudy-usecase .cs-cathero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
  background-size: 96px 96px;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 40%, #000 0%, transparent 100%);
  mask-image: radial-gradient(70% 60% at 50% 40%, #000 0%, transparent 100%);
}
.tax-casestudy-category .cs-cathero > .container,
.tax-casestudy-usecase .cs-cathero > .container { position: relative; z-index: 2; }
.tax-casestudy-category .cs-cathero h1,
.tax-casestudy-usecase .cs-cathero h1 { letter-spacing: -1.4px; }
.tax-casestudy-category .cs-cathero__lead,
.tax-casestudy-usecase .cs-cathero__lead { color: rgba(255, 255, 255, .8); }

/* Breadcrumb */
.tax-casestudy-category .cs-crumbs,
.tax-casestudy-usecase .cs-crumbs {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  list-style: none; margin: 0; padding: 0 0 22px;
  font-size: 13px; color: rgba(255, 255, 255, .55);
}

.tax-casestudy-category .cs-crumbs li,
.tax-casestudy-usecase .cs-crumbs li {
  display: inline-flex; align-items: center;
  width: auto; margin: 0; padding: 0;
  list-style: none;
}
.tax-casestudy-category .cs-crumbs li::marker,
.tax-casestudy-usecase .cs-crumbs li::marker { content: ''; }
.tax-casestudy-category .cs-crumbs a,
.tax-casestudy-usecase .cs-crumbs a { color: rgba(255, 255, 255, .72); }
.tax-casestudy-category .cs-crumbs a:hover,
.tax-casestudy-usecase .cs-crumbs a:hover { color: #fff; }
.tax-casestudy-category .cs-crumbs li + li::before,
.tax-casestudy-usecase .cs-crumbs li + li::before { content: '/'; padding-right: 10px; opacity: .45; }
.tax-casestudy-category .cs-crumbs [aria-current="page"],
.tax-casestudy-usecase .cs-crumbs [aria-current="page"] { color: #fff; }

/* Count rail under the CTAs */
.tax-casestudy-category .cs-catmeta,
.tax-casestudy-usecase .cs-catmeta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px;
  margin: 0; padding: 30px 0 0;
  border-top: 1px solid rgba(255, 255, 255, .14);
}
.tax-casestudy-category .cs-catmeta__n,
.tax-casestudy-usecase .cs-catmeta__n {
  font-family: var(--number-font);
  font-size: 34px; line-height: 1; color: #fff;
}
.tax-casestudy-category .cs-catmeta__l,
.tax-casestudy-usecase .cs-catmeta__l { font-size: 14px; color: rgba(255, 255, 255, .62); }
.tax-casestudy-category .cs-catmeta__sep,
.tax-casestudy-usecase .cs-catmeta__sep { width: 1px; height: 26px; background: rgba(255, 255, 255, .16); }

.tax-casestudy-category .cs-link--light,
.tax-casestudy-usecase .cs-link--light { color: #fff; }
.tax-casestudy-category .cs-link--light:hover,
.tax-casestudy-usecase .cs-link--light:hover { color: #fff; }

.tax-casestudy-category .cs-body,
.tax-casestudy-usecase .cs-body { background: linear-gradient(180deg, #fff 0%, #f7f5fd 10%, #f7f5fd 100%); }

.tax-casestudy-category .cs-filterbar,
.tax-casestudy-usecase .cs-filterbar { padding: 24px 0 8px; }
.tax-casestudy-category .cs-filter,
.tax-casestudy-usecase .cs-filter { padding: 0; }
.tax-casestudy-category .cs-tabs,
.tax-casestudy-usecase .cs-tabs { padding: 0; }


.tax-casestudy-category .cs-tile,
.tax-casestudy-usecase .cs-tile {
  position: relative;
  height: 100%; min-height: 0;
  border-radius: 22px;
  overflow: hidden;
  background: #fff;
  box-shadow: inset 0 0 0 1px #ece9f5;
  transition: transform .4s cubic-bezier(.2, .8, .2, 1), box-shadow .4s ease;
}
.tax-casestudy-category .cs-tile:hover,
.tax-casestudy-usecase .cs-tile:hover {
  transform: translateY(-4px);
  box-shadow: inset 0 0 0 1px #e4dff4, 0 34px 60px -34px rgba(17, 24, 39, .3);
}

.tax-casestudy-category .cs-card,
.tax-casestudy-usecase .cs-card { display: flex; flex-direction: column; }

.tax-casestudy-category .cs-card__plate,
.tax-casestudy-usecase .cs-card__plate {
  display: block; position: relative; overflow: hidden;
  height: 168px;
  background: #fbf1f2;
  box-shadow: inset 0 0 0 1px #efecf7;
}
.tax-casestudy-category .cs-card__img,
.tax-casestudy-usecase .cs-card__img {
  display: block; position: relative; z-index: 2;
  transition: transform 1.1s cubic-bezier(.2, .8, .2, 1), opacity .5s ease;
  margin:0 auto;
}

.tax-casestudy-category .cs-card__img--logo,
.tax-casestudy-usecase .cs-card__img--logo { transform: scale(1.24); }
.tax-casestudy-category .cs-tile:hover .cs-card__img--logo,
.tax-casestudy-usecase .cs-tile:hover .cs-card__img--logo { transform: scale(1.3); }
.tax-casestudy-category .cs-tile:hover .cs-card__img--poster,
.tax-casestudy-usecase .cs-tile:hover .cs-card__img--poster { transform: scale(1.04); }


.tax-casestudy-category .cs-card__video,
.tax-casestudy-usecase .cs-card__video {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: 100%; height: auto; aspect-ratio: 16 / 9; min-height: 100%;
  border: 0;
  pointer-events: none; /* clicks belong to the card link, not the player */
}
.tax-casestudy-category .cs-card__plate.is-playing .cs-card__img,
.tax-casestudy-usecase .cs-card__plate.is-playing .cs-card__img { opacity: 0; }
.tax-casestudy-category .cs-card__play,
.tax-casestudy-usecase .cs-card__play {
  position: absolute; z-index: 3; left: 12px; bottom: 12px;
  display: inline-flex; align-items: center; gap: 6px;
  height: 30px; padding: 0 13px 0 10px; border-radius: 999px;
  background: rgba(13, 10, 24, .78);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  color: #fff; font-size: 12px; font-weight: 600; letter-spacing: .2px;
  transition: background-color .3s ease;
}
.tax-casestudy-category .cs-card__play i,
.tax-casestudy-usecase .cs-card__play i { font-size: 15px; line-height: 1; }
.tax-casestudy-category .cs-tile:hover .cs-card__play,
.tax-casestudy-usecase .cs-tile:hover .cs-card__play { background: rgba(var(--primary-color), .95); }
/* No thumbnail: set the customer name in the display face rather than
    leave a hole where the logo should be. */
.tax-casestudy-category .cs-card__plate--text,
.tax-casestudy-usecase .cs-card__plate--text {
  display: flex; align-items: center; justify-content: center;
  padding: 16px 24px;
  background: linear-gradient(140deg, #f7f4fd 0%, #ece5f9 100%);
  font-family: var(--number-font);
  font-size: 26px; line-height: 1.2; text-align: center;
  color: #4c3482;
}

.tax-casestudy-category .cs-card__body,
.tax-casestudy-usecase .cs-card__body {
  display: flex; flex-direction: column; flex: 1;
  padding: 24px 26px 24px;
}
.tax-casestudy-category .cs-card__headline,
.tax-casestudy-usecase .cs-card__headline {
  font-size: 19px; font-weight: 700;
  color: var(--bs-dark-text-emphasis);
  margin: 0; padding: 0 0 12px;
}
.tax-casestudy-category .cs-card--feature .cs-card__headline,
.tax-casestudy-usecase .cs-card--feature .cs-card__headline { font-size: 23px; }
.tax-casestudy-category .cs-card__customer,
.tax-casestudy-usecase .cs-card__customer {
  font-size: 11px; font-weight: 700; letter-spacing: 1.6px;
  text-transform: uppercase; color: rgba(var(--primary-color), 1);
  margin: 0; padding: 0 0 12px;
}
.tax-casestudy-category .cs-card__quote,
.tax-casestudy-usecase .cs-card__quote {
  font-size: 16px; font-weight: 400; line-height: 1.62;
  color: #374151;
  margin: 0; padding: 0 0 20px;
}
/* Attribution rail — every quote names the person who said it. */
.tax-casestudy-category .cs-card__foot,
.tax-casestudy-usecase .cs-card__foot {
  margin-top: auto; padding-top: 18px;
  border-top: 1px solid #f0eef7;
}
.tax-casestudy-category .cs-card__who,
.tax-casestudy-usecase .cs-card__who { font-size: 14px; font-weight: 600; color: #676769; margin: 0; padding: 0; }
.tax-casestudy-category .cs-card__role,
.tax-casestudy-usecase .cs-card__role { font-size: 13px; color: #6b7280; margin: 0; padding: 2px 0 16px; }

/* ---------- Empty state ---------- */
.tax-casestudy-category .cs-empty,
.tax-casestudy-usecase .cs-empty {
  background: #fff;
  border: 1px solid #ece9f5;
  border-radius: 24px;
  padding: 64px 32px;
  text-align: center;
}
.tax-casestudy-category .cs-empty__glyph,
.tax-casestudy-usecase .cs-empty__glyph {
  display: inline-flex; align-items: center; justify-content: center;
  width: 64px; height: 64px; border-radius: 20px;
  background: #f4f0fe; color: rgba(var(--primary-color), 1); font-size: 26px;
  margin-bottom: 22px;
}

/* ---------- Pagination ---------- */
.tax-casestudy-category .cs-pager,
.tax-casestudy-usecase .cs-pager { padding-top: 56px; }
.tax-casestudy-category .cs-pager .nav-links,
.tax-casestudy-usecase .cs-pager .nav-links {
  display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px;
  background: #fff;
  border: 1px solid #ece9f5;
  border-radius: 999px;
  padding: 8px;
}
.tax-casestudy-category .cs-pager .page-numbers,
.tax-casestudy-usecase .cs-pager .page-numbers {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-width: 40px; height: 40px; padding: 0 14px;
  border-radius: 999px;
  font-size: 14px; font-weight: 600; color: #4b5563;
  transition: background-color .25s ease, color .25s ease;
}
.tax-casestudy-category .cs-pager .page-numbers:hover,
.tax-casestudy-usecase .cs-pager .page-numbers:hover { background: #f4f0fe; color: rgba(var(--primary-color), 1); }
.tax-casestudy-category .cs-pager .page-numbers.current,
.tax-casestudy-usecase .cs-pager .page-numbers.current { background: var(--primary-color-dark); color: #fff; }
.tax-casestudy-category .cs-pager .page-numbers.dots,
.tax-casestudy-usecase .cs-pager .page-numbers.dots { background: none; color: #9ca3af; }
/* The theme sets a blanket svg { fill: var(--text-color) }, so the arrows
    need their own fill to follow the link colour. */
.tax-casestudy-category .cs-pager .page-numbers svg,
.tax-casestudy-usecase .cs-pager .page-numbers svg { height: 12px; width: auto; fill: currentColor; }
.tax-casestudy-category .cs-pager .screen-reader-text,
.tax-casestudy-usecase .cs-pager .screen-reader-text {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Browse other industries ---------- */
.tax-casestudy-category .cs-browse,
.tax-casestudy-usecase .cs-browse {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: #e7e2f4;
  border: 1px solid #ebe7f7;
  border-radius: 22px;
  overflow: hidden;
}
.tax-casestudy-category .cs-browse__cell,
.tax-casestudy-usecase .cs-browse__cell {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 24px 26px;
  background: linear-gradient(160deg, #fbfaff 0%, #f4f1fc 100%);
  font-weight: 600; color: #14111f;
  transition: background-color .3s ease, color .3s ease;
}
.tax-casestudy-category .cs-browse__cell:hover,
.tax-casestudy-usecase .cs-browse__cell:hover { background: #fff; color: rgba(var(--primary-color), 1); }
.tax-casestudy-category .cs-browse__cell i,
.tax-casestudy-usecase .cs-browse__cell i { color: rgba(var(--primary-color), 1); transition: transform .3s cubic-bezier(.2, .8, .2, 1); }
.tax-casestudy-category .cs-browse__cell:hover i,
.tax-casestudy-usecase .cs-browse__cell:hover i { transform: translate(3px, -3px); }
.tax-casestudy-category .cs-browse__n,
.tax-casestudy-usecase .cs-browse__n {
  font-size: 12px; font-weight: 700; color: #9ca3af;
  font-variant-numeric: tabular-nums;
}

/* ---------- Closing CTA ---------- */
.tax-casestudy-category .cs-cta,
.tax-casestudy-usecase .cs-cta { background: #f7f5fd; }

@media (max-width: 991px) {
  .tax-casestudy-category .cs-browse,
  .tax-casestudy-usecase .cs-browse { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
  .tax-casestudy-category .cs-cathero,
  .tax-casestudy-usecase .cs-cathero { padding: 56px 0 56px; }
  .tax-casestudy-category .cs-catmeta,
  .tax-casestudy-usecase .cs-catmeta { gap: 10px 20px; padding-top: 24px; }
  .tax-casestudy-category .cs-catmeta__n,
  .tax-casestudy-usecase .cs-catmeta__n { font-size: 28px; }
  .tax-casestudy-category .cs-card__body,
  .tax-casestudy-usecase .cs-card__body { padding: 20px 22px 22px; }
  .tax-casestudy-category .cs-browse,
  .tax-casestudy-usecase .cs-browse { grid-template-columns: minmax(0, 1fr); }
  .tax-casestudy-category .cs-empty,
  .tax-casestudy-usecase .cs-empty { padding: 44px 22px; }
  /* The listing stylesheet already unpins the bar at this width. */
  .tax-casestudy-category .cs-filterbar,
  .tax-casestudy-usecase .cs-filterbar { padding: 24px 0 0; }
}

@media (min-width: 1200px) {
  .tax-casestudy-category .cs-cathero h1,
  .tax-casestudy-usecase .cs-cathero h1 { letter-spacing: -2px; }
  .tax-casestudy-category .cs-catmeta__n,
  .tax-casestudy-usecase .cs-catmeta__n { font-size: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  .tax-casestudy-category .cs-card__img,
  .tax-casestudy-usecase .cs-card__img,
  .tax-casestudy-category .cs-browse__cell,
  .tax-casestudy-usecase .cs-browse__cell { transition: none; }
}