/* ── Wrapper ─────────────────────────────────────────────────────────────────── */
.pricelist-wrap {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 16px 40px;
}

/* ── Заголовок ───────────────────────────────────────────────────────────────── */
.pricelist-heading {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin: 0 0 6px;
    color: #222;
}

.pricelist-subheading {
    font-size: 13px;
    color: #888;
    margin: 0 0 24px;
}

/* ── Поиск ───────────────────────────────────────────────────────────────────── */
.pricelist-search-wrap {
    margin-bottom: 20px;
}

.pricelist-search {
    display: flex;
    align-items: center;
    border: 1px solid #d9d9d9;
    border-radius: 6px;
    background: #fff;
    padding: 0 14px;
    transition: border-color .2s, box-shadow .2s;
}

.pricelist-search:focus-within {
    border-color: #7eb3b0;
    box-shadow: 0 0 0 3px rgba(126,179,176,.15);
}

.pricelist-search-icon {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    margin-right: 10px;
    pointer-events: none;
}

.pricelist-search-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 15px;
    padding: 13px 0;
    background: transparent;
    color: #333;
}

.pricelist-search-input::placeholder {
    color: #bbb;
}

/* ── Секция (аккордеон) ──────────────────────────────────────────────────────── */
.pricelist-section {
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    margin-bottom: 8px;
    overflow: hidden;
}

.pricelist-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    background: #f2f2f2;
    cursor: pointer;
    user-select: none;
    transition: background .2s;
}

.pricelist-section.is-open .pricelist-section-head {
    background: #f5f8f9;
}

.pricelist-section-head:hover {
    background: #e0efed;
}

.pricelist-section:not(.is-open) .pricelist-section-head:hover {
    background: #ececec;
}

.pricelist-section-name {
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

.pricelist-section-arrow {
    display: flex;
    align-items: center;
    color: #666;
    transition: transform .25s;
}

.pricelist-section.is-open .pricelist-section-arrow {
    transform: rotate(180deg);
}

.pricelist-section-body {
    display: none;
    border-top: 1px solid #e5e5e5;
}

.pricelist-section.is-open .pricelist-section-body {
    display: block;
}

/* ── Строка услуги (одна линия: номер код название | цена, боковые границы) ── */
.pricelist-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    gap: 20px;
    border-left: 1px solid #e0e0e0;
    border-right: 1px solid #e0e0e0;
    border-bottom: 1px solid #f0f0f0;
    background: #fff;
    transition: background .15s;
}

.pricelist-item:last-child {
    border-bottom: none;
}

.pricelist-item:hover {
    background: #fafafa;
}

.pricelist-item-left {
    flex: 1;
    min-width: 0;
}

/* Номер, медкод и название — одна строка, один начертание (как в эталоне) */
.pricelist-item-line {
    display: block;
    font-size: 14px;
    line-height: 1.45;
    font-weight: 400;
    color: #3d4a5c;
}

.pricelist-item-line .pricelist-item-name {
    display: inline;
    font-size: inherit;
    font-weight: inherit;
    color: inherit;
    line-height: inherit;
}

/* Подпись секции — только в режиме поиска */
.pricelist-item-section-label {
    display: block;
    margin-top: 4px;
    font-size: 11px;
    color: #7eb3b0;
    line-height: 1.3;
}

.pricelist-item-right {
    flex-shrink: 0;
    white-space: nowrap;
    text-align: right;
}

.pricelist-item-price {
    font-size: 14px;
    font-weight: 700;
    color: #222;
}

.pricelist-price-free {
    font-weight: 400;
    color: #888;
}

.pricelist-rub {
    font-weight: 400;
}

/* ── Результаты поиска ───────────────────────────────────────────────────────── */
.pricelist-search-results {
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    overflow: hidden;
}

.pricelist-search-results .pricelist-item:last-child {
    border-bottom: none;
}

.pricelist-search-empty {
    padding: 24px 20px;
    font-size: 14px;
    color: #999;
    text-align: center;
}

/* ── Адаптив ─────────────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .pricelist-heading {
        font-size: 20px;
    }
    .pricelist-section-head,
    .pricelist-item {
        padding-left: 14px;
        padding-right: 14px;
    }
}
