/* Layout отзывов */
.js-stroi-reviews.reviews__content {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: clamp(52.8px, 4.1666666667vw, 80px);
    width: 100%;
}

.js-stroi-reviews .reviews__main {
    flex: 1 1 auto;
    min-width: 0;
    order: 1;
}

.js-stroi-reviews .reviews__aside {
    flex: 0 0 clamp(244.2px, 19.2708333333vw, 370px);
    width: clamp(244.2px, 19.2708333333vw, 370px);
    min-width: 280px;
    max-width: 370px;
    order: 2;
    position: sticky;
    top: clamp(99px, 7.8125vw, 150px);
}

.review-card__avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #f0f0f0 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='%23bbb' viewBox='0 0 16 16'%3E%3Cpath d='M8 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6zm2-3a2 2 0 1 1-4 0 2 2 0 0 1 4 0zm4 8c0 1-1 1-1 1H3s-1 0-1-1 1-4 6-4 6 3 6 4zm-1-.004c-.001-.246-.154-.986-.832-1.664C11.516 10.68 10.289 10 8 10c-2.29 0-3.516.68-4.168 1.332-.678.678-.83 1.418-.832 1.664h10z'/%3E%3C/svg%3E") center / 24px no-repeat;
    flex-shrink: 0;
}

.reviews__empty,
.reviews__gallery-empty {
    color: #4d5c6b;
    font-size: 14px;
}

.review-card__gallery a,
.reviews__slider a {
    cursor: zoom-in;
}

/* Попап формы */
.review-popup {
    z-index: 10050;
    position: fixed;
    inset: 0;
    overflow: auto;
    padding: 24px 16px;
    background: rgba(40, 39, 45, 0.45);
    display: none;
    box-sizing: border-box;
}

.review-popup.open {
    display: block;
}

.review-popup[hidden]:not(.open) {
    display: none !important;
}

.review-popup__wrapper {
    width: min(720px, 100%);
    margin: 0 auto;
    background: #fff;
    border-radius: 20px;
    padding: 28px 32px 32px;
    box-sizing: border-box;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

.review-popup__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.review-popup__header h3 {
    margin: 0 0 8px;
    font-size: 24px;
    font-weight: 700;
}

.review-popup__lead {
    margin: 0;
    font-size: 14px;
    color: #4d5c6b;
    line-height: 1.45;
}

.review-popup__close {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 14px;
    background: #f0f0f0;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.review-form__section {
    margin-bottom: 24px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f0f0f0;
}

.review-form__section:last-of-type {
    border-bottom: none;
}

.review-form__section-title {
    margin: 0 0 16px;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.review-form__field {
    display: block;
    margin-bottom: 16px;
}

.review-form__label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #28272d;
}

.review-form__label em {
    color: #e94d11;
    font-style: normal;
}

.review-form__input,
.review-form__textarea {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 16px;
    font-family: inherit;
    background: #fff;
    transition: border-color 0.2s;
}

.review-form__input:focus,
.review-form__textarea:focus {
    outline: none;
    border-color: #e94d11;
}

.review-form__textarea {
    resize: vertical;
    min-height: 88px;
}

.review-form__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px 16px;
}

@media (max-width: 600px) {
    .review-form__grid {
        grid-template-columns: 1fr;
    }
}

.review-form__stars {
    display: flex;
    gap: 4px;
}

.review-form__star {
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
    line-height: 0;
}

.review-form__star:hover path,
.review-form__star.is-active path {
    fill: #ffbd16;
}

.review-form__file {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    cursor: pointer;
}

.review-form__file input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
}

.review-form__file-btn {
    display: inline-block;
    padding: 12px 20px;
    border-radius: 10px;
    background: #f0f0f0;
    font-weight: 600;
    font-size: 14px;
}

.review-form__file-hint {
    font-size: 13px;
    color: #4d5c6b;
}

.review-form__file-list {
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
    font-size: 13px;
    color: #4d5c6b;
}

.review-form__file-list li {
    padding: 4px 0;
}

.review-form__message {
    min-height: 1.2em;
    font-size: 14px;
    margin: 0 0 16px;
}

.review-form__message.is-error {
    color: #df1313;
}

.review-form__message.is-success {
    color: #2bb41f;
}

.review-form__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.review-form__btn {
    flex: 1;
    min-width: 140px;
    padding: 16px 24px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.review-form__btn_primary {
    background: #e94d11;
    color: #fff;
}

.review-form__btn_secondary {
    background: #f0f0f0;
    color: #28272d;
}

@media (max-width: 991px) {
    .js-stroi-reviews.reviews__content {
        flex-direction: column-reverse;
        gap: 40px;
    }

    .js-stroi-reviews .reviews__aside {
        width: 100%;
        min-width: 0;
        max-width: none;
        position: static;
    }

    .review-popup__wrapper {
        padding: 20px 16px 24px;
    }
}
