/* ===== Отзывы по направлениям: форма (assets/js/review-criteria.js) и блок средних (виджет epil_review_criteria) ===== */

/* Общая звезда Listivo выставляется сама - из направлений */
.listivo-review-form.has-epil-rc .listivo-review-form__rating {
    display: none !important;
}

.epil-rc {
    margin: 16px 0 18px;
    padding: 16px 18px;
    border: 1px solid #ecdcf3;
    border-radius: 16px;
    background: #fdf8ff;
}

.epil-rc__head {
    margin: 0 0 10px !important;
    color: #374b5c;
    font-size: 15px;
    font-weight: 700;
}

.epil-rc__row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 4px 12px;
    padding: 6px 0;
    border-bottom: 1px dashed #eadff0;
}

.epil-rc__row:last-of-type {
    border-bottom: 0;
}

.epil-rc__label {
    flex: 1 1 220px;
    color: #374b5c;
    font-size: 14px;
    line-height: 1.35;
}

.epil-rc__label em {
    color: #8a96a0;
    font-size: 12px;
    font-style: normal;
}

.epil-rc__stars {
    display: inline-flex;
    gap: 2px;
}

html body .epil-rc__star {
    display: inline-grid;
    place-items: center;
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: none;
    color: #d5dbe1;
    cursor: pointer;
    transition: color .12s ease, transform .12s ease;
}

.epil-rc__star svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
}

html body .epil-rc__star.is-on {
    color: #ffb800;
}

html body .epil-rc__star:hover {
    background: none;
    transform: scale(1.12);
}

.epil-rc__star:focus-visible {
    outline: 2px solid #d86eec;
    outline-offset: 1px;
}

.epil-rc__stars:hover .epil-rc__star {
    color: #ffb800;
}

.epil-rc__stars .epil-rc__star:hover ~ .epil-rc__star {
    color: #d5dbe1;
}

.epil-rc__total {
    margin: 10px 0 0 !important;
    color: #374b5c;
    font-size: 14px;
}

.epil-rc__total b {
    font-size: 16px;
}

.epil-rc__error {
    margin: 8px 0 0 !important;
    color: #dc2626;
    font-size: 14px;
    font-weight: 600;
}

@media (max-width: 767px) {
    .epil-rc {
        padding: 12px 14px;
    }

    .epil-rc__label {
        flex-basis: 100%;
    }
}

/* --- Блок «Оценки клиентов по направлениям» (виджет epil_review_criteria) --- */
.epil-rcb {
    margin: 0 0 24px;
    padding: 22px 24px;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .06);
}

.epil-rcb__head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 6px 16px;
    margin-bottom: 14px;
}

html body .epil-rcb__title {
    margin: 0;
    color: #374b5c;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
}

.epil-rcb__total {
    margin: 0 !important;
    color: #73818c;
    font-size: 14px;
}

.epil-rcb__total b {
    margin-right: 4px;
    color: #374b5c;
    font-size: 24px;
    font-weight: 800;
}

.epil-rcb__list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.epil-rcb__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px 76px;
    align-items: center;
    gap: 12px;
    margin: 0;
}

.epil-rcb__name {
    color: #374b5c;
    font-size: 14px;
    line-height: 1.35;
}

.epil-rcb__bar {
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #f0eef4;
}

.epil-rcb__bar i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #ffb800, #ffcf4d);
}

.epil-rcb__value {
    color: #374b5c;
    font-size: 15px;
    font-weight: 700;
    text-align: right;
}

.epil-rcb__row.is-empty .epil-rcb__value {
    color: #a3adb5;
    font-size: 12px;
    font-weight: 500;
}

/* --- Чипсы направлений в каждом отзыве (assets/js/review-criteria.js) --- */
.epil-rc-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 8px 0 4px;
}

.epil-rc-chips span {
    padding: 3px 9px;
    border-radius: 999px;
    background: #f6f1fa;
    color: #5b4a68;
    font-size: 12.5px;
    line-height: 1.4;
}

.epil-rc-chips b {
    color: #b44fc9;
}

@media (max-width: 767px) {
    .epil-rcb {
        padding: 18px 16px;
    }

    .epil-rcb__row {
        grid-template-columns: minmax(0, 1fr) 64px 44px;
        gap: 8px;
    }

    .epil-rcb__row.is-empty .epil-rcb__value {
        font-size: 11px;
    }
}

/* --- Защита от спама (assets/js/review-guard.js): капча Turnstile и невидимая ловушка --- */
.epil-guard__trap {
    position: absolute !important;
    left: -10000px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.epil-guard.has-captcha {
    margin: 4px 0 14px;
    border-radius: 12px;
}

.epil-guard.is-missing .epil-guard__widget {
    border-radius: 10px;
    box-shadow: 0 0 0 2px #dc2626;
}

.epil-guard--listivo.has-captcha {
    margin: 0 0 16px;
}
