/* Cats catalog */
.cats-cafe-page { padding-bottom: 64px; }

.cats-cafe-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 36px;
  align-items: center;
  padding: clamp(42px, 7vw, 86px) 0 46px;
}

.cats-cafe-hero h1 {
  max-width: 850px;
  margin: 14px 0 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(48px, 6vw, 82px);
  line-height: 0.98;
  font-weight: 500;
  letter-spacing: -0.045em;
  overflow-wrap: break-word;
  hyphens: auto;
}

.cats-cafe-hero p { max-width: 770px; margin: 0; color: var(--muted); font-size: 18px; line-height: 1.6; }
.cats-cafe-hero__doodle {
  position: relative;
  display: grid;
  place-content: center;
  min-height: 220px;
  border-radius: 48% 52% 44% 56%;
  color: var(--accent);
  background: #fff1c8;
  font-family: Georgia, serif;
  text-align: center;
  transform: rotate(2deg);
}

.cats-cafe-hero__slogan {
  max-width: 620px;
  margin: 22px 0 0 !important;
  color: var(--accent) !important;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(20px, 2vw, 28px) !important;
  font-style: italic;
  line-height: 1.22 !important;
}

.cats-cafe-hero__doodle span { position: absolute; right: 18px; top: 2px; color: #eeb000; font-size: 76px; }
.cats-cafe-hero__doodle strong { font-size: 44px; font-style: italic; font-weight: 500; }
.cats-cafe-tools {
  display: grid;
  gap: 24px;
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: 28px;
  background: rgba(255, 250, 241, 0.9);
  box-shadow: var(--shadow);
}

.cats-filter-group { display: grid; gap: 10px; }
.cats-filter-group__label,
.cats-name-search > span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.cats-filter-pills { display: flex; gap: 9px; flex-wrap: wrap; }
.cats-filter-pill {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid rgba(86, 113, 63, 0.24);
  border-radius: 999px;
  color: var(--accent);
  background: #fffdf8;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}

.cats-filter-pill:hover { background: #f0f5ea; }
.cats-filter-pill.is-active { color: #fff; border-color: var(--accent); background: var(--accent); }
.cats-filter-pills--categories .cats-filter-pill.is-active { color: #2f311f; border-color: #efb200; background: #ffe28b; }
.cats-filter-pill small {
  display: grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 5px;
  border-radius: 999px;
  color: inherit;
  background: rgba(255, 255, 255, 0.45);
  font-size: 11px;
}

.cats-name-search { display: grid; gap: 9px; max-width: 420px; }
.cats-name-search input {
  width: 100%;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  outline: none;
  background: #fff;
  font: inherit;
}

.cats-name-search input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(86, 113, 63, 0.12); }
.cats-catalog-section,
.cats-at-cafe,
.cat-related-section { padding: 58px 0 20px; }
.cats-catalog-section__head {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  align-items: end;
  margin-bottom: 24px;
}

.cats-catalog-section__head h2 {
  margin: 8px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(34px, 4vw, 50px);
  line-height: 1.05;
  font-weight: 500;
}

.cats-catalog-section__head > p { max-width: 470px; margin: 0; color: var(--muted); line-height: 1.55; }
.cats-all-link { color: var(--accent); font-weight: 800; text-decoration: none; }
.cats-state,
.kgorod-cats__empty {
  padding: 26px;
  border-radius: 20px;
  color: var(--muted);
  background: #fff6dc;
  text-align: center;
}

.kgorod-cats__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.kgorod-cats__card {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 24px;
  color: var(--text);
  background: var(--surface);
  box-shadow: var(--shadow);
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.kgorod-cats__card:hover { transform: translateY(-4px); box-shadow: 0 20px 44px rgba(75, 58, 35, 0.12); }
.kgorod-cats__card[hidden] { display: none; }
.kgorod-cats__image-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: #f2eadc;
}

.kgorod-cats__image-wrap::after {
  content: "♡";
  position: absolute;
  right: 14px;
  bottom: 8px;
  z-index: 2;
  color: #f2b000;
  font-family: Georgia, serif;
  font-size: 46px;
  line-height: 1;
  filter: drop-shadow(0 1px 0 #fff);
}

.kgorod-cats__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

.kgorod-cats__card:hover .kgorod-cats__image { transform: scale(1.025); }
.kgorod-cats__badge {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 2;
  padding: 6px 10px;
  border-radius: 999px;
  color: #63502b;
  background: rgba(255, 246, 220, 0.92);
  font-size: 12px;
  font-weight: 800;
  backdrop-filter: blur(8px);
}

.kgorod-cats__body { display: flex; flex: 1; flex-direction: column; padding: 18px; }
.kgorod-cats__name {
  margin: 0 0 8px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 500;
}

.kgv-cat-category { align-self: flex-start; margin-bottom: 9px; color: var(--accent); font-size: 13px; font-weight: 800; }
.kgorod-cats__facts { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 10px; }
.kgorod-cats__fact { padding: 4px 8px; border-radius: 999px; color: var(--muted); background: #f3eee5; font-size: 12px; }
.kgorod-cats__desc {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

@media (max-width: 1050px) {
  .kgorod-cats__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .cats-cafe-hero { grid-template-columns: 1fr; padding-top: 34px; }
  .cats-cafe-hero__doodle { display: none; }
  .cats-cafe-hero h1 { font-size: clamp(44px, 14vw, 62px); }
  .cats-cafe-tools { padding: 18px; border-radius: 22px; }
  .cats-filter-pills { flex-wrap: nowrap; margin-right: -18px; padding-right: 18px; overflow-x: auto; }
  .cats-filter-pill { flex: 0 0 auto; }
  .cats-catalog-section__head { display: block; }
  .cats-catalog-section__head > p,
  .cats-catalog-section__head > a { display: block; margin-top: 12px; }
  .kgorod-cats__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kgorod-cats__card { border-radius: 18px; }
  .kgorod-cats__body { padding: 13px; }
  .kgorod-cats__name { font-size: 23px; }
  .kgorod-cats__desc { display: none; }
  .kgorod-cats__image-wrap { aspect-ratio: 1 / 1.18; }
  .kgorod-cats__badge { left: 9px; top: 9px; padding: 5px 8px; font-size: 10px; }
  .kgorod-cats__image-wrap::after { right: 8px; bottom: 4px; font-size: 36px; }
}

.cats-catalog-section__title-row {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.cats-cafe-tools[hidden] { display: none; }

.cats-search-toggle {
  display: inline-grid;
  width: 42px;
  height: 42px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(86, 113, 63, .34);
  border-radius: 50%;
  color: var(--accent);
  background: #fffdf8;
  box-shadow: 0 5px 14px rgba(47, 39, 28, .09);
  cursor: pointer;
  transition: transform 160ms ease, color 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.cats-search-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2.2;
}

.cats-search-toggle:hover,
.cats-search-toggle:focus-visible,
.cats-search-toggle[aria-expanded="true"] {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
  transform: translateY(-1px);
}

/* Компактная панель каталога: подсказка слева, поиск у правого края. */
.cats-catalog-section__head { align-items: center; }
.cats-catalog-section__head > p { max-width: 640px; }
.cats-catalog-section__head > .cats-search-toggle { flex: 0 0 auto; margin-left: auto; }
@media (max-width: 760px) {
  .cats-catalog-section__head { display: flex; align-items: center; gap: 16px; }
  .cats-catalog-section__head > p { margin: 0; max-width: none; }
  .cats-catalog-section__head > .cats-search-toggle { margin-left: auto; }
}

/* Выпадающие фильтры и поиск закреплены у кнопки-лупы. */
.cats-catalog-section__head { position: relative; }
.cats-catalog-section__head > .cats-cafe-tools {
  position: absolute;
  z-index: 30;
  top: calc(100% + 12px);
  right: 0;
  width: min(720px, calc(100vw - 48px));
  margin: 0;
}
@media (max-width: 760px) {
  .cats-catalog-section__head > .cats-cafe-tools {
    width: min(520px, calc(100vw - 32px));
  }
}
