/* Catalog-only layout from the supplied Results reference. */
.view-cases {
  --catalog-ink: #261c32;
  --catalog-muted: #635a70;
  --catalog-accent: #713cda;
  --catalog-line: #ded9e5;
  background: #faf9fc;
  color: var(--catalog-ink);
}
.view-cases .page-intro, .view-cases .cases-catalog { max-width: 1280px; }
.view-cases .page-intro { padding-block: 23px 34px; }
.view-cases .breadcrumbs { margin: 0 0 27px; }
.view-cases .intro-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, .95fr); gap: 36px; align-items: center; }
.view-cases .intro-grid h1 { margin: 0; font-size: clamp(44px, 5.1vw, 72px); letter-spacing: -.045em; line-height: 1.06; }
.view-cases .intro-grid > p { margin: 0; padding: 0; color: var(--catalog-muted); font-size: clamp(16px, 1.5vw, 21px); line-height: 1.45; }
.case-shortcuts { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.case-shortcuts a, .case-filter-toggle {
  display: inline-flex; align-items: center; padding: 9px 18px; min-height: 42px;
  border: 1px solid var(--catalog-line); border-radius: 30px; background: white; font: inherit; font-size: 15px; line-height: 1.3;
}
.case-shortcuts a:hover, .case-filter-toggle:hover { border-color: var(--catalog-accent); }
.case-shortcuts [aria-current] { color: white; background: var(--catalog-accent); border-color: var(--catalog-accent); }
.view-cases [hidden] { display: none !important; }
.view-cases .catalog-controls {
  display: flex; flex-flow: row nowrap; align-items: center; gap: 0; background: white; border: 1px solid var(--catalog-line);
  border-radius: 17px; padding: 8px 12px;
}
.view-cases .search-field { flex: 1 1 auto; min-width: 0; padding: 0 10px; border: 0; }
.view-cases .search-field:focus-within { outline: 2px solid var(--catalog-accent); outline-offset: -2px; }
.view-cases .search-field button { min-width: 40px; min-height: 40px; align-items: center; justify-content: center; }
.case-selects { display: flex; align-items: center; }
.case-selects > label { padding-inline: 15px; border-left: 1px solid var(--catalog-line); min-width: 0; }
.view-cases .case-selects select { width: clamp(140px,15vw,220px); min-width: 0; border: 0; padding-left: 4px; font-size: 15px; }
.view-cases .catalog-status { margin: 23px 0 25px; font-size: 15px; }
.view-cases .case-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 22px; }

.editorial-case {
  --card-bg: white; --card-ink: #241d31; --card-accent: #713cda; --card-muted: #635a70; --card-line: #ded9e5; --card-button: #f0ebf9;
  position: relative; display: flex; flex-direction: column; min-width: 0; container-type: inline-size;
  border: 1px solid var(--card-line); border-radius: 24px; background: var(--card-bg); color: var(--card-ink);
}
.editorial-case.is-featured {
  --card-bg: #2d1b43; --card-ink: #fff; --card-accent: #e3fc95; --card-muted: #d7cce3; --card-line: #675379; --card-button: #e3fc95;
}
.editorial-art {
  position: relative; aspect-ratio: 628 / 300; width: 100%; isolation: isolate; overflow: hidden;
  background: #ece6f5; border-radius: 23px 23px 0 0;
}
.editorial-art .cs-art { position: absolute; inset: 0; --art-top: max(42px, 11%); }
.catalog-subject { width: 100%; height: 100%; position: absolute; bottom: 0; left: 0; display: block; object-fit: contain; }
.art-vimontale { background: #e7dbf8; }
.art-medportal { background: #ece6f6; }
.art-vimontale .catalog-subject, .art-medportal .catalog-subject {
  mask-image: linear-gradient(90deg, transparent 13%, black 21%, black 79%, transparent 87%);
}
.art-table-tochka { background: #ece7fb; }
.art-table-tochka .catalog-subject { width: 76%; height: auto; left: 15%; bottom: -9.3cqw; }
.art-sidim-doma { background: #eef1e4; }
.art-kardanvalservis { background: #ebe9f0; }
.art-doktor-volos { background: #ece5f6; }
.art-sidim-doma::before, .art-kardanvalservis::before, .art-doktor-volos::before {
  content: ""; position: absolute; aspect-ratio: 1; width: 48%; border-radius: 50%; left: 50%; top: 5%; transform: translateX(-50%); background: #e4ebcb;
}
.art-kardanvalservis::before { width: 45%; background: #e0dde9; }
.art-doktor-volos::before { width: 50%; left: auto; right: 0; top: 6%; transform: none; background: #d8cde9; }
.art-sidim-doma .catalog-subject { width: 44%; left: 28%; }
.art-kardanvalservis .catalog-subject { width: 83%; height: auto; left: 8.5%; bottom: -16cqw; }
.art-doktor-volos .catalog-subject { width: 46%; left: auto; right: 2%; object-position: center bottom; height: 88%; }
.art-note { position: absolute; top: 35%; left: 5%; width: 43%; padding: 2.6% 3%; display: grid; justify-items: start; gap: 5px; border-radius: 18px; background: #fff; color: #573294; }
.art-note small { padding: 2px 9px; border-radius: 15px; background: #f2ecfb; font-size: clamp(10px,2cqw,13px); }
.art-note b { font-size: clamp(18px,4.2cqw,28px); line-height: 1.2; }
.art-note > span { font-size: clamp(11px,2.6cqw,16px); color: #635a70; }
.editorial-badges {
  position: absolute; top: clamp(12px,3.4cqw,21px); left: clamp(12px,3.4cqw,22px); right: clamp(12px,3.4cqw,22px);
  display: flex; justify-content: space-between; align-items: start; gap: 8px; pointer-events: none;
}
.editorial-badges span { border-radius: 999px; padding: 7px 13px; background: #fff; color: #342b3d; font-size: clamp(10px,1.9cqw,12px); font-weight: 600; line-height: 1.3; text-transform: uppercase; }
.editorial-badges span + span { color: #6234b6; }
.editorial-body { flex: 1; display: flex; flex-direction: column; min-width: 0; padding: clamp(18px,4.7cqw,30px) clamp(18px,4.7cqw,30px) 9px; }
.editorial-body :is(h2,h3) { margin: 0; font-size: clamp(25px,5.3cqw,34px); font-weight: 600; line-height: 1.14; letter-spacing: -.03em; overflow-wrap: anywhere; }
.editorial-case .editorial-summary { margin: 8px 0 0; max-width: 25ch; min-height: 2.68em; color: var(--card-ink); font-size: clamp(17px,3.5cqw,22px); font-weight: 500; line-height: 1.34; text-wrap: balance; }
.editorial-evidence { display: grid; align-items: center; grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr); gap: clamp(12px,3cqw,22px); margin-block: 11px 16px; }
.editorial-value { color: var(--card-accent); font-weight: 600; font-size: clamp(44px,11.1cqw,70px); line-height: 1.08; letter-spacing: -.055em; white-space: nowrap; }
.editorial-case .editorial-measure p { margin: 0; color: var(--card-ink); font-size: clamp(15px,3.1cqw,19px); line-height: 1.32; font-weight: 500; }
.editorial-progress { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 9px; margin-top: 9px; color: var(--card-muted); font-size: clamp(13px,2.7cqw,17px); line-height: 1.3; }
.editorial-progress > span { white-space: nowrap; }
.editorial-case .editorial-period { margin: 4px 0 16px; color: var(--card-muted); font-size: clamp(13px,2.25cqw,15px); line-height: 1.5; }
.editorial-link { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 16px; border-top: 1px solid var(--card-line); padding: 10px 0 3px; font-size: 16px; font-weight: 600; }
.editorial-link::before { content: ""; position: absolute; inset: 0; border-radius: 24px; }
.editorial-link > span { background: var(--card-button); color: var(--card-accent); border-radius: 50%; width: 40px; height: 40px; display: grid; place-items: center; }
.is-featured .editorial-link > span { color: #2f2139; }
.editorial-link:focus-visible { outline: 0; }
.editorial-link:focus-visible::before { outline: 3px solid var(--catalog-accent); outline-offset: 3px; }
.editorial-case:hover .editorial-link { text-decoration: underline; text-underline-offset: 3px; }
.case-browse { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; margin-top: 30px; font-size: 15px; }
.case-browse p { margin: 0; color: var(--catalog-muted); }
.case-more { display: inline-flex; align-items: center; justify-content: space-between; gap: 30px; min-height: 48px; padding: 12px 22px; background: #fff; border: 1px solid var(--catalog-line); border-radius: 30px; font-weight: 600; }
.case-more:hover { border-color: var(--catalog-accent); }
.case-pagination { display: flex; flex-wrap: wrap; gap: 3px; }
.case-pagination a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; }
.case-pagination a:hover { background: #f1ecfa; }
.case-pagination [aria-current] { color: white; background: var(--catalog-accent); }
@media (max-width: 810px) {
  .view-cases .case-grid { gap: 16px; }
  .case-selects > label { padding-inline: 8px; }
  .view-cases .case-selects select { width: 138px; }
}
@media (max-width: 700px) {
  .view-cases .intro-grid { grid-template-columns: 1fr; gap: 12px; }
  .view-cases .intro-grid > p br { display: none; }
  .view-cases .page-intro { padding-block: 17px 23px; }
  .view-cases .breadcrumbs { margin-bottom: 17px; }
  .view-cases .case-grid { grid-template-columns: minmax(0,1fr); gap: 22px; }
  .case-shortcuts { gap: 6px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: thin; padding: 4px 2px 6px; }
  .case-shortcuts a { flex: none; padding: 8px 12px; font-size: 14px; min-height: 38px; }
  .view-cases .catalog-controls { flex-wrap: wrap; padding: 7px; }
  .view-cases .catalog-controls > .search-field { flex: 1 1 140px; min-height: 44px; padding-inline: 5px; }
  .case-filter-toggle { min-height: 42px; padding: 8px 12px; border-radius: 10px; font-size: 14px; }
  .case-selects { display: grid; grid-template-columns: 1fr 1fr; width: 100%; border-top: 1px solid var(--catalog-line); margin-top: 5px; }
  .case-selects > label { padding: 0 5px; }
  .case-selects > label:first-child { border-left: 0; }
  .view-cases .case-selects select { width: 100%; height: 45px; font-size: 14px; }
  .view-cases .catalog-status { margin-block: 17px; }
  .case-browse { justify-content: center; text-align: center; }
  .case-browse p, .case-pagination { width: 100%; }
  .case-pagination { justify-content: center; }
}
@container (max-width: 420px) {
  .editorial-art { aspect-ratio: 1.9; }
  .art-vimontale .catalog-subject, .art-medportal .catalog-subject { height: calc(100% - 26px); }
  .editorial-badges span { padding: 5px 10px; }
  .editorial-evidence { grid-template-columns: max-content minmax(0,1fr); gap: 12px; }
  .editorial-value { font-size: clamp(39px,11.1cqw,46px); }
  .editorial-progress { gap: 3px 5px; }
  .art-note { border-radius: 12px; gap: 3px; }
}
@media (max-width: 420px) {
  .case-pagination a { width: 33px; height: 37px; }
}

.service-case-previews {
  --catalog-accent: #713cda;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 22px;
}
.service-case-previews > :only-child { width: 100%; max-width: 720px; }
.service-case-previews .editorial-body h3 { margin: 0; color: var(--card-ink); font-size: clamp(25px,5.3cqw,34px); }
@media (max-width: 700px) { .service-case-previews { grid-template-columns: minmax(0,1fr); } }
.service-case-previews .editorial-body .editorial-link { color: var(--card-ink); }
