/*
 * Cases hub archive: /kejsy/
 * Scope: .page--cases-hub and .cases-hub
 */

.page--cases-hub {
  background: #f4f8fc;
}

.cases-hub,
.cases-hub *,
.cases-hub *::before,
.cases-hub *::after {
  box-sizing: border-box;
}

.cases-hub {
  overflow: hidden;
  color: var(--text, #17293a);
  background:
    radial-gradient(circle at 8% 0%, rgba(8, 118, 133, .08), transparent 26%),
    linear-gradient(180deg, #f4f8fc 0%, #fff 38%, #f4f8fc 100%);
}

.cases-hub :where(section, article, div, header, aside, a, p, h1, h2, h3, span) {
  min-width: 0;
}

.cases-hub__breadcrumbs {
  padding-top: 22px;
  padding-bottom: 18px;
}

.cases-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  margin: 0 0 14px;
  color: var(--accent, #087685);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.cases-eyebrow::before {
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 999px;
  content: '';
}

.cases-eyebrow--light {
  color: #8fe7ef;
}

.cases-hero {
  padding: 0 0 82px;
}

.cases-hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr);
  gap: clamp(34px, 6vw, 82px);
  align-items: center;
  overflow: hidden;
  min-height: 520px;
  padding: clamp(46px, 6vw, 78px);
  color: #fff;
  background:
    radial-gradient(circle at 88% 15%, rgba(8, 118, 133, .42), transparent 30%),
    radial-gradient(circle at 8% 100%, rgba(11, 74, 139, .5), transparent 34%),
    linear-gradient(135deg, #0a2136 0%, #0b3455 55%, #09273c 100%);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 32px;
  box-shadow: 0 28px 70px rgba(6, 31, 51, .18);
}

.cases-hero__inner::before,
.cases-hero__inner::after {
  position: absolute;
  pointer-events: none;
  content: '';
}

.cases-hero__inner::before {
  inset: 0;
  opacity: .22;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .26) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(90deg, transparent, #000 62%);
}

.cases-hero__inner::after {
  width: 520px;
  height: 520px;
  right: -250px;
  bottom: -270px;
  border: 1px solid rgba(143, 231, 239, .18);
  border-radius: 50%;
  box-shadow: 0 0 0 60px rgba(143, 231, 239, .035), 0 0 0 125px rgba(143, 231, 239, .025);
}

.cases-hero__content,
.cases-hero__proof {
  position: relative;
  z-index: 1;
}

.cases-hero h1 {
  max-width: 780px;
  margin: 0;
  color: #fff;
  font-size: clamp(44px, 5.1vw, 76px);
  font-weight: 850;
  line-height: .99;
  letter-spacing: -.045em;
}

.cases-hero__lead {
  max-width: 760px;
  margin: 28px 0 0;
  color: rgba(255, 255, 255, .78);
  font-size: clamp(18px, 1.5vw, 21px);
  line-height: 1.6;
}

.cases-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.cases-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 14px 22px;
  border-radius: 14px;
  font-weight: 750;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, border-color .18s ease, color .18s ease;
}

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

.cases-button--accent {
  color: #08243c !important;
  background: #8fe7ef !important;
  border-color: #8fe7ef !important;
  box-shadow: 0 14px 32px rgba(35, 188, 204, .24);
}

.cases-button--ghost {
  color: #fff !important;
  background: rgba(255, 255, 255, .04) !important;
  border: 1px solid rgba(255, 255, 255, .28) !important;
}

.cases-button--ghost:hover,
.cases-button--ghost:focus-visible {
  background: rgba(255, 255, 255, .1) !important;
  border-color: rgba(255, 255, 255, .52) !important;
}

.cases-hero__proof {
  padding: 26px;
  background: rgba(255, 255, 255, .075);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 24px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .07), 0 24px 54px rgba(0, 0, 0, .14);
  backdrop-filter: blur(16px);
}

.cases-hero__proof-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .66);
  font-size: 13px;
}

.cases-hero__proof-head strong {
  color: #fff;
  font-size: 17px;
}

.cases-hero__proof ul {
  display: grid;
  gap: 12px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.cases-hero__proof li {
  position: relative;
  padding-left: 30px;
  color: rgba(255, 255, 255, .82);
  font-size: 15px;
  line-height: 1.5;
}

.cases-hero__proof li::before {
  position: absolute;
  top: 3px;
  left: 0;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  color: #08243c;
  background: #8fe7ef;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 900;
  content: '✓';
}

.cases-hero__proof > p {
  margin: 22px 0 0;
  padding-top: 18px;
  color: rgba(255, 255, 255, .58);
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: 13px;
  line-height: 1.55;
}

.cases-featured {
  padding: 0 0 92px;
}

.cases-featured__card {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(380px, .88fr);
  overflow: hidden;
  background: #fff;
  border: 1px solid #dbe6ee;
  border-radius: 28px;
  box-shadow: 0 22px 54px rgba(31, 74, 103, .11);
}

.cases-featured__media {
  position: relative;
  overflow: hidden;
  min-height: 500px;
  background: #eaf1f5;
}

.cases-featured__media::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, transparent 64%, rgba(7, 35, 56, .06));
  content: '';
}

.cases-featured__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}

.cases-featured__media:hover .cases-featured__image,
.cases-featured__media:focus-visible .cases-featured__image {
  transform: scale(1.025);
}

.cases-featured__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(36px, 5vw, 66px);
}

.cases-featured__meta,
.cases-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cases-featured__meta span,
.cases-card__tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: var(--primary, #0b4a8b);
  background: rgba(11, 74, 139, .07);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.2;
}

.cases-featured__body h2 {
  margin: 22px 0 0;
  font-size: clamp(32px, 3.5vw, 52px);
  font-weight: 850;
  line-height: 1.06;
  letter-spacing: -.035em;
}

.cases-featured__body h2 a {
  color: inherit;
  text-decoration: none;
}

.cases-featured__body > p {
  margin: 20px 0 0;
  color: #5c7182;
  font-size: 16px;
  line-height: 1.68;
}

.cases-featured__result {
  display: grid;
  width: fit-content;
  margin-top: 30px;
  padding: 18px 22px;
  background: rgba(8, 118, 133, .07);
  border: 1px solid rgba(8, 118, 133, .16);
  border-radius: 18px;
}

.cases-featured__result strong {
  color: var(--accent, #087685);
  font-size: clamp(34px, 4vw, 50px);
  line-height: 1;
}

.cases-featured__result span {
  margin-top: 6px;
  font-size: 14px;
  font-weight: 750;
}

.cases-featured__result small {
  margin-top: 8px;
  color: #627586;
  font-size: 12px;
}

.cases-featured__link,
.cases-card__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary, #0b4a8b);
  font-weight: 800;
  text-decoration: none;
}

.cases-featured__link {
  margin-top: 30px;
  font-size: 15px;
}

.cases-featured__link span,
.cases-card__link span {
  transition: transform .18s ease;
}

.cases-featured__link:hover span,
.cases-featured__link:focus-visible span,
.cases-card__link:hover span,
.cases-card__link:focus-visible span {
  transform: translateX(4px);
}

.cases-catalog {
  scroll-margin-top: 100px;
  padding: 88px 0;
  background: #fff;
  border-top: 1px solid rgba(188, 207, 220, .54);
  border-bottom: 1px solid rgba(188, 207, 220, .54);
}

.cases-section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, .8fr);
  gap: 56px;
  align-items: end;
  margin-bottom: 32px;
}

.cases-section-head h2,
.cases-method__head h2,
.cases-cta h2 {
  margin: 0;
  font-size: clamp(34px, 4vw, 54px);
  font-weight: 850;
  line-height: 1.06;
  letter-spacing: -.035em;
}

.cases-section-head > p {
  margin: 0;
  color: #5c7182;
  font-size: 17px;
  line-height: 1.65;
}

.cases-filters {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  margin: 0 0 30px;
  padding: 2px 2px 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(11, 74, 139, .28) transparent;
}

.cases-filter {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 9px 15px;
  color: #0b4a8b;
  background: #fff;
  border: 1px solid #dbe6ee;
  border-radius: 999px;
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
}

.cases-filter:hover,
.cases-filter:focus-visible,
.cases-filter.is-active {
  color: #fff;
  background: #0b4a8b;
  border-color: #0b4a8b;
}

.cases-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.cases-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 100%;
  background: #fff;
  border: 1px solid #dbe6ee;
  border-radius: 20px;
  box-shadow: 0 12px 30px rgba(31, 74, 103, .07);
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.cases-card:hover,
.cases-card:focus-within {
  transform: translateY(-5px);
  border-color: rgba(8, 118, 133, .42);
  box-shadow: 0 22px 44px rgba(31, 74, 103, .13);
}

.cases-card[hidden] {
  display: none !important;
}

.cases-card__media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #eaf1f5;
}

.cases-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}

.cases-card:hover .cases-card__image,
.cases-card:focus-within .cases-card__image {
  transform: scale(1.035);
}

.cases-card__metric {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: grid;
  min-width: 120px;
  padding: 12px 14px;
  color: #fff;
  background: rgba(8, 41, 71, .88);
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 14px;
  backdrop-filter: blur(10px);
}

.cases-card__metric strong {
  font-size: 24px;
  line-height: 1;
}

.cases-card__metric span {
  margin-top: 4px;
  font-size: 11px;
  line-height: 1.25;
}

.cases-card__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  padding: 22px;
}

.cases-card__title {
  margin: 16px 0 0;
  font-size: 23px;
  font-weight: 820;
  line-height: 1.2;
  letter-spacing: -.02em;
}

.cases-card__title a {
  color: inherit;
  text-decoration: none;
}

.cases-card__text {
  margin: 12px 0 22px;
  color: #5c7182;
  font-size: 14px;
  line-height: 1.58;
}

.cases-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: auto;
}

.cases-card__period {
  color: #627586;
  font-size: 12px;
  font-weight: 650;
}

.cases-card__link {
  margin-left: auto;
  font-size: 13px;
}

.cases-method {
  padding: 94px 0;
}

.cases-method__inner {
  position: relative;
  overflow: hidden;
  padding: clamp(44px, 6vw, 72px);
  color: #fff;
  background:
    radial-gradient(circle at 92% 12%, rgba(8, 118, 133, .38), transparent 30%),
    linear-gradient(135deg, #102b45 0%, #0a2034 100%);
  border-radius: 30px;
  box-shadow: 0 26px 60px rgba(6, 31, 51, .17);
}

.cases-method__inner::after {
  position: absolute;
  width: 420px;
  height: 420px;
  right: -220px;
  top: -220px;
  border: 1px solid rgba(143, 231, 239, .2);
  border-radius: 50%;
  box-shadow: 0 0 0 58px rgba(143, 231, 239, .035), 0 0 0 118px rgba(143, 231, 239, .025);
  content: '';
}

.cases-method__head,
.cases-method__grid {
  position: relative;
  z-index: 1;
}

.cases-method__head {
  max-width: 850px;
}

.cases-method__head h2 {
  color: #fff;
}

.cases-method__head > p {
  max-width: 800px;
  margin: 20px 0 0;
  color: rgba(255, 255, 255, .72);
  font-size: 17px;
  line-height: 1.68;
}

.cases-method__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 36px;
}

.cases-method__grid article {
  min-height: 246px;
  padding: 22px;
  background: rgba(255, 255, 255, .065);
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 20px;
}

.cases-method__grid article > span {
  display: inline-flex;
  margin-bottom: 42px;
  color: #8fe7ef;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: .08em;
}

.cases-method__grid h3 {
  margin: 0;
  color: #fff;
  font-size: 19px;
  font-weight: 800;
  line-height: 1.25;
}

.cases-method__grid p {
  margin: 12px 0 0;
  color: rgba(255, 255, 255, .62);
  font-size: 14px;
  line-height: 1.55;
}

.cases-cta {
  padding: 0 0 94px;
}

.cases-cta__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 48px;
  align-items: center;
  padding: clamp(36px, 5vw, 58px);
  background:
    radial-gradient(circle at 96% 0%, rgba(8, 118, 133, .11), transparent 34%),
    #fff;
  border: 1px solid #dbe6ee;
  border-radius: 26px;
  box-shadow: 0 18px 44px rgba(31, 74, 103, .09);
}

.cases-cta__inner > div {
  max-width: 860px;
}

.cases-cta p {
  max-width: 820px;
  margin: 18px 0 0;
  color: #5c7182;
  font-size: 16px;
  line-height: 1.65;
}

.cases-empty {
  padding: 48px 0 88px;
}

.cases-empty .container {
  padding: 38px;
  background: #fff;
  border: 1px solid #dbe6ee;
  border-radius: 22px;
  text-align: center;
}

.cases-empty h2 {
  margin: 0;
}

.cases-empty p {
  margin: 12px 0 0;
  color: #5c7182;
}

@media (max-width: 1120px) {
  .cases-hero__inner {
    grid-template-columns: minmax(0, 1fr) 340px;
    padding: 58px 46px;
  }

  .cases-featured__card {
    grid-template-columns: 1fr 420px;
  }

  .cases-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cases-method__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .cases-hero__inner,
  .cases-featured__card,
  .cases-section-head,
  .cases-cta__inner {
    grid-template-columns: 1fr;
  }

  .cases-hero__inner {
    gap: 42px;
  }

  .cases-hero__proof {
    max-width: 680px;
  }

  .cases-featured__media {
    min-height: 420px;
  }

  .cases-section-head {
    gap: 24px;
    align-items: start;
  }

  .cases-cta__inner {
    gap: 28px;
  }
}

@media (max-width: 700px) {
  .cases-hub__breadcrumbs {
    padding-top: 16px;
    padding-bottom: 12px;
  }

  .cases-hero,
  .cases-featured,
  .cases-cta {
    padding-bottom: 54px;
  }

  .cases-hero__inner,
  .cases-method__inner,
  .cases-cta__inner {
    margin-right: -2px;
    margin-left: -2px;
    border-radius: 22px;
  }

  .cases-hero__inner {
    min-height: auto;
    padding: 40px 22px 24px;
  }

  .cases-hero h1 {
    font-size: clamp(38px, 12vw, 56px);
  }

  .cases-hero__lead {
    margin-top: 22px;
    font-size: 17px;
  }

  .cases-hero__actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .cases-hero__actions .cases-button,
  .cases-cta .cases-button {
    width: 100%;
  }

  .cases-hero__proof {
    padding: 20px;
  }

  .cases-featured__card {
    border-radius: 20px;
  }

  .cases-featured__media {
    min-height: 0;
    aspect-ratio: 16 / 10;
  }

  .cases-featured__body {
    padding: 26px 22px 30px;
  }

  .cases-featured__body h2,
  .cases-section-head h2,
  .cases-method__head h2,
  .cases-cta h2 {
    font-size: clamp(30px, 9vw, 42px);
  }

  .cases-featured__result {
    width: 100%;
  }

  .cases-catalog {
    padding: 58px 0;
  }

  .cases-grid,
  .cases-method__grid {
    grid-template-columns: 1fr;
  }

  .cases-card {
    border-radius: 18px;
  }

  .cases-method {
    padding: 54px 0;
  }

  .cases-method__inner {
    padding: 38px 22px 22px;
  }

  .cases-method__grid article {
    min-height: 0;
  }

  .cases-method__grid article > span {
    margin-bottom: 24px;
  }

  .cases-cta__inner {
    padding: 34px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cases-hub *,
  .cases-hub *::before,
  .cases-hub *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Scalable server-side filter and pagination for 50+ cases. */
.cases-filter-form {
  display: grid;
  grid-template-columns: minmax(240px, 1.15fr) minmax(190px, .8fr) minmax(190px, .8fr) auto;
  gap: 14px;
  align-items: end;
  margin-bottom: 18px;
  padding: 20px;
  background: #f5f8fc;
  border: 1px solid #dce6f0;
  border-radius: 18px;
}

.cases-filter-form > div {
  min-width: 0;
}

.cases-filter-form label {
  display: block;
  margin-bottom: 7px;
  color: #50667c;
  font-size: 11px;
  font-weight: 800;
}

.cases-filter-form input,
.cases-filter-form select {
  width: 100%;
  min-height: 46px;
  padding: 10px 13px;
  color: #173858;
  background: #fff;
  border: 1px solid #cedbe7;
  border-radius: 12px;
  font: inherit;
  font-size: 14px;
}

.cases-filter-form input:focus,
.cases-filter-form select:focus {
  border-color: #0c6cde;
  outline: 3px solid rgba(12, 108, 222, .12);
}

.cases-filter-form__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cases-filter-form__actions .btn {
  min-height: 46px;
  white-space: nowrap;
}

.cases-filter-form__actions > a {
  color: #0b5fc8;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.cases-catalog__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
}

.cases-catalog__summary p {
  margin: 0 8px 0 0;
  color: #5b7188;
  font-size: 13px;
  font-weight: 750;
}

.cases-catalog__summary span {
  display: inline-flex;
  padding: 6px 10px;
  color: #0c5fc8;
  background: #eaf3ff;
  border: 1px solid #d6e8ff;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.cases-pagination {
  margin-top: 34px;
}

.cases-pagination .page-numbers {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cases-pagination a,
.cases-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 42px;
  padding: 9px 13px;
  color: #164c8f;
  background: #fff;
  border: 1px solid #d9e4ef;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.cases-pagination .current,
.cases-pagination a:hover,
.cases-pagination a:focus-visible {
  color: #fff;
  background: #0b63d8;
  border-color: #0b63d8;
}

.cases-empty--filtered {
  padding: 42px;
  text-align: center;
  background: #f5f8fc;
  border: 1px solid #dce6f0;
  border-radius: 20px;
}

.cases-empty--filtered h2 {
  margin: 0;
}

.cases-empty--filtered p {
  margin: 12px auto 22px;
}

@media (max-width: 1020px) {
  .cases-filter-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cases-filter-form__actions {
    justify-content: flex-start;
  }
}

@media (max-width: 700px) {
  .cases-filter-form {
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .cases-filter-form__actions {
    display: grid;
    grid-template-columns: 1fr auto;
  }

  .cases-filter-form__actions .btn {
    width: 100%;
  }

  .cases-pagination a,
  .cases-pagination span {
    min-width: 38px;
    min-height: 38px;
    padding: 8px 10px;
  }
}
