/* ─────────────────────────────────────────────────────────────
   Прейскурант: поиск по услугам, шесть разделов, таблицы цен.
   849 позиций, поэтому блоки свёрнуты, а поиск ищет сразу по всем.
   ───────────────────────────────────────────────────────────── */

.pl { padding-bottom: 110px; }

/* ── Поиск ──────────────────────────────────────────────────── */
.pl__search {
  position: relative;
  max-width: 560px;
  margin-inline: auto;
}
.pl__search > svg {
  position: absolute;
  left: 22px;
  top: 50%;
  width: 18px;
  height: 18px;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.pl__input {
  width: 100%;
  padding: 15px 52px;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 24px;
  color: var(--ink);
  background: var(--white);
  border: 1px solid rgba(var(--brand-rgb), 0.18);
  border-radius: var(--radius-pill);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.pl__input::placeholder { color: var(--muted); }
.pl__input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(var(--brand-rgb), 0.1);
}
.pl__clear {
  position: absolute;
  right: 16px;
  top: 50%;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  transform: translateY(-50%);
  color: var(--muted);
  border-radius: 50%;
  transition: background 0.2s, color 0.2s;
}
.pl__clear svg { width: 11px; height: 11px; }
.pl__clear:hover { color: var(--ink); background: var(--line); }

.pl__meta {
  margin-top: 12px;
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 22px;
  text-align: center;
  color: var(--muted);
}

/* ── Разделы ────────────────────────────────────────────────── */
.pl__tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 30px;
}
.pl__tab {
  padding: 10px 20px;
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 22px;
  font-weight: 500;
  color: var(--brand-deep);
  background: var(--badge-bg);
  border-radius: var(--radius-pill);
  transition: background 0.2s, color 0.2s;
}
.pl__tab:hover { background: rgba(var(--brand-rgb), 0.16); }
.pl__tab.is-active {
  color: var(--white);
  background: var(--brand);
}

.pl__panel { margin-top: 34px; }
.pl__panel[hidden] { display: none; }

/* Во время поиска показываем сразу несколько разделов —
   тогда над каждым нужен заголовок, иначе непонятно, что откуда. */
.pl__group-title {
  margin-bottom: 16px;
  font-family: var(--font-body);
  font-size: 22px;
  line-height: 30px;
  font-weight: 700;
  color: var(--ink);
}
.pl__group-title[hidden] { display: none; }

/* ── Раскрывающийся блок ────────────────────────────────────── */
.pl__block {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.pl__block + .pl__block { margin-top: 12px; }
.pl__block[open] { border-color: rgba(var(--brand-rgb), 0.3); }

.pl__block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 24px;
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 25px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
  transition: color 0.2s;
}
.pl__block-head::-webkit-details-marker { display: none; }
.pl__block-head:hover { color: var(--brand); }
.pl__block[open] .pl__block-head { color: var(--brand); }
.pl__block-head svg {
  width: 13px;
  height: 13px;
  flex: none;
  color: var(--muted);
  transition: transform 0.3s cubic-bezier(0.22, 0.61, 0.36, 1), color 0.2s;
}
.pl__block[open] .pl__block-head svg { color: var(--brand); transform: rotate(180deg); }

.pl__block-body { padding: 0 24px 22px; }

.pl__section {
  margin: 18px 0 10px;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 24px;
  font-weight: 600;
  color: var(--brand-deep);
}

/* ── Таблица ────────────────────────────────────────────────── */
/* На телефоне названия услуг длинные — таблица прокручивается
   внутри себя, а страница вбок не едет. */
.pl__scroll { overflow-x: auto; }

.pl__table {
  min-width: 420px;
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 22px;
}
.pl__table th {
  padding: 11px 14px;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  color: var(--muted);
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
}
.pl__table th:first-child { border-radius: var(--radius-btn) 0 0 0; }
.pl__table th:last-child { border-radius: 0 var(--radius-btn) 0 0; }

.pl__table td {
  padding: 12px 14px;
  /* названия услуг бывают слитными на 40 знаков — иначе строка едет вбок */
  overflow-wrap: anywhere;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.pl__table tbody tr:hover td { background: var(--bg-soft); }
.pl__table tr[hidden] { display: none; }

.pl__sum {
  width: 150px;
  text-align: right;
  white-space: nowrap;
  font-weight: 600;
}
.pl__unit {
  color: var(--muted);
  font-size: 13px;
}

/* Подсветка найденного */
.pl__hit { background: rgba(var(--brand-rgb), 0.18); border-radius: 3px; }

.pl__empty {
  margin-top: 40px;
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 26px;
  text-align: center;
  color: var(--muted);
}

/* ── Планшет ────────────────────────────────────────────────── */
@media (max-width: 1199px) {
  .pl { padding-bottom: 70px; }
  .pl__tabs { gap: 8px; }
  .pl__tab { padding: 9px 16px; font-size: 13px; }
}

/* ── Телефон ────────────────────────────────────────────────── */
@media (max-width: 767px) {
  .pl__block-head { padding: 15px 16px; font-size: 15px; }
  .pl__block-body { padding: 0 12px 18px; }
  .pl__section { font-size: 14px; }

  /* Прокручивать прайс вбок неудобно: цена уезжает за край и её не
     видно. На телефоне строка разворачивается в две — название
     сверху, сумма снизу крупно. */
  .pl__scroll { overflow-x: visible; }
  .pl__table { min-width: 0; font-size: 15px; }
  .pl__table thead { display: none; }
  .pl__table,
  .pl__table tbody,
  .pl__table tr { display: block; width: 100%; }
  .pl__table td { display: block; padding: 0; border: 0; }
  .pl__table tr {
    display: block;
    padding: 12px 2px 13px;
    border-bottom: 1px solid var(--line);
  }
  .pl__table tbody tr:hover td { background: none; }
  .pl__sum {
    width: auto;
    margin-top: 5px;
    text-align: left;
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 24px;
    font-weight: 700;
    color: var(--brand-deep);
  }
  .pl__unit { display: block; margin-top: 2px; font-size: 13px; }
}
