/* Стили для секции отзывов */

.object-reviews {
    margin: 60px 0;
    animation: fadeInUp 0.6s ease-out 0.5s both;
}

/* Шапка с кнопкой */
.reviews-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.reviews-header h2 {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
}

.reviews-header h2 i {
    color: #ff385c;
}

.write-review-btn {
    padding: 14px 28px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.write-review-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Горизонтальная фотогалерея */
.reviews-photo-gallery {
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
    border-radius: 16px;
    border: 1px solid #e0e5ff;
}

.reviews-photo-gallery h3 {
    font-size: 22px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 20px;
}

.photo-gallery-scroll {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding-bottom: 10px;
    scrollbar-width: thin;
    scrollbar-color: #667eea #f0f0f0;
}

.photo-gallery-scroll::-webkit-scrollbar {
    height: 6px;
}

.photo-gallery-scroll::-webkit-scrollbar-track {
    background: #f0f0f0;
    border-radius: 3px;
}

.photo-gallery-scroll::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 3px;
}

.gallery-photo-item {
    flex-shrink: 0;
    width: 200px;
    height: 150px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-photo-item:hover {
    transform: scale(1.05);
}

.gallery-photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Рейтинги */
.reviews-ratings {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.rating-item {
    display: grid;
    grid-template-columns: 120px 1fr auto;
    align-items: center;
    gap: 15px;
}

.rating-label {
    font-size: 15px;
    color: #333;
}

.rating-bar {
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.rating-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    transition: width 0.3s ease;
}

.rating-value {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    min-width: 30px;
    text-align: right;
}

/* Список отзывов */
.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-bottom: 30px;
}

.review-item {
    padding: 30px;
    background: white;
    border-radius: 16px;
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
}

.review-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.review-author {
    display: flex;
    gap: 15px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.author-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.author-info strong {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
}

.review-date {
    font-size: 14px;
    color: #666;
}

.review-rating {
    display: flex;
    gap: 4px;
}

.review-rating i {
    color: #ff385c;
    font-size: 14px;
}

.review-text {
    font-size: 15px;
    line-height: 1.6;
    color: #484848;
    margin: 0;
}

.review-pros,
.review-cons,
.review-impression {
    margin-top: 16px;
}

.review-pros strong,
.review-cons strong,
.review-impression strong {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #222;
    font-size: 14px;
    margin-bottom: 8px;
}

.review-pros strong i {
    color: #00a699;
}

.review-cons strong i {
    color: #ff385c;
}

.review-impression strong i {
    color: #717171;
}

.review-pros p,
.review-cons p,
.review-impression p {
    color: #484848;
    line-height: 1.6;
    margin: 0;
    padding-left: 24px;
}

.gallery-photo-clickable {
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gallery-photo-clickable:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Фотографии в отзывах */
.review-photos {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.review-photo-item {
    width: 120px;
    height: 90px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.review-photo-item:hover {
    transform: scale(1.05);
}

.review-photo-clickable {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
}

/* Lightbox стили */
.photo-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
}

.lightbox-content {
    position: fixed;
    top: 5vh;
    left: 5vw;
    width: 90vw;
    height: 90vh;
    z-index: 1001;
    pointer-events: none;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: fixed;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #222;
    transition: all 0.2s ease;
    z-index: 1002;
}

.lightbox-close {
    top: 20px;
    right: 20px;
}

.lightbox-close:hover {
    background: #fff;
    transform: rotate(90deg);
}

.lightbox-prev {
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-next {
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev:active,
.lightbox-next:active {
    transform: translateY(-50%) scale(0.95);
}

#lightbox-image {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    pointer-events: auto;
}

.lightbox-counter {
    pointer-events: auto;
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.9);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    color: #222;
    font-weight: 500;
    z-index: 1003;
}

.show-all-reviews-btn {
    width: 100%;
    padding: 16px;
    background: white;
    border: 2px solid #667eea;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    color: #667eea;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.show-all-reviews-btn:hover {
    background: #667eea;
    color: white;
}

/* Попап формы отзыва */
.review-form-popup {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
}

.review-form-popup.active {
    display: flex;
}

.review-form-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.review-form-container {
    position: relative;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    background: white;
    border-radius: 20px;
    padding: 40px;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.review-form-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: #f0f0f0;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.review-form-close:hover {
    background: #e0e0e0;
    transform: rotate(90deg);
}

.review-form-container h3 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.review-form-subtitle {
    font-size: 15px;
    color: #666;
    margin-bottom: 30px;
}

/* Форма */
.review-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

.required {
    color: #ff385c;
}

.form-group input,
.form-group textarea {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* Загрузка фото */
.photo-upload-area {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.photo-upload-label {
    padding: 30px;
    border: 2px dashed #667eea;
    border-radius: 12px;
    background: #f8f9ff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.photo-upload-label:hover {
    background: #f0f2ff;
    border-color: #5568d3;
}

.photo-upload-label i {
    font-size: 32px;
    color: #667eea;
}

.photo-upload-label span {
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

.photo-upload-label small {
    font-size: 13px;
    color: #666;
}

.photo-preview-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}

.photo-preview-item {
    position: relative;
    width: 100%;
    padding-bottom: 100%;
    border-radius: 8px;
    overflow: hidden;
}

.photo-preview-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-preview-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 24px;
    height: 24px;
    background: rgba(255, 56, 92, 0.9);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: all 0.3s ease;
}

.photo-preview-remove:hover {
    background: #ff385c;
    transform: scale(1.1);
}

/* Кнопки формы */
.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.btn-cancel {
    flex: 1;
    padding: 14px;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-cancel:hover {
    border-color: #c0c0c0;
    background: #f8f8f8;
}

.btn-submit {
    flex: 2;
    padding: 14px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Адаптивность */
@media (max-width: 768px) {
    .reviews-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    
    .reviews-ratings {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .review-form-container {
        padding: 30px 20px;
    }
    
    .gallery-photo-item {
        width: 150px;
        height: 120px;
    }
}

/* Выбор звёзд рейтинга */
.star-rating-input {
    display: flex;
    align-items: center;
    gap: 8px;
}

.star-rating-input .star-input {
    font-size: 28px;
    color: #ddd;
    cursor: pointer;
    transition: all 0.2s ease;
}

.star-rating-input .star-input:hover,
.star-rating-input .star-input.active {
    color: #ffc107;
    transform: scale(1.1);
}

.star-rating-input .star-input.active {
    text-shadow: 0 0 8px rgba(255, 193, 7, 0.5);
}

.star-rating-input .rating-text {
    margin-left: 12px;
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Плюсы и минусы в отзывах */
.review-pros,
.review-cons,
.review-impression {
    margin-bottom: 12px;
    padding: 12px 15px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
}

.review-pros {
    border-left: 3px solid #4CAF50;
}

.review-cons {
    border-left: 3px solid #f44336;
}

.review-impression {
    border-left: 3px solid #2196F3;
}

.review-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: rgba(255, 255, 255, 0.7);
}

.review-label i {
    margin-right: 6px;
}

.review-pros .review-label i {
    color: #4CAF50;
}

.review-cons .review-label i {
    color: #f44336;
}

.review-impression .review-label i {
    color: #2196F3;
}

.review-pros p,
.review-cons p,
.review-impression p {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.5;
}

/* Фото в отзывах - черный фон с неоновым свечением */
.review-photos {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
    padding: 20px;
    background: #0a0a0a;
    border-radius: 16px;
    border: 1px solid rgba(201, 162, 39, 0.3);
    box-shadow: 
        0 0 20px rgba(201, 162, 39, 0.15),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
    position: relative;
}

.review-photos::before {
    content: "Фото от гостя";
    position: absolute;
    top: -12px;
    left: 20px;
    background: #0a0a0a;
    padding: 2px 12px;
    font-size: 12px;
    color: #c9a227;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 0 10px rgba(201, 162, 39, 0.5);
}

.review-photo-item {
    width: 130px;
    height: 100px;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.review-photo-item:hover {
    transform: scale(1.08);
    border-color: #c9a227;
    box-shadow: 
        0 0 15px rgba(201, 162, 39, 0.5),
        0 0 30px rgba(201, 162, 39, 0.3);
}

.review-photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: filter 0.3s ease;
}

.review-photo-item:hover img {
    filter: brightness(1.1);
}

/* === LIGHTBOX ДЛЯ ФОТО ОТЗЫВОВ === */
.review-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.review-lightbox.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.review-lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    cursor: pointer;
}

.review-lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.review-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.review-lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.review-lightbox-arrow:hover {
    background: rgba(255, 255, 255, 0.2);
}

.review-lightbox-arrow-left {
    left: 20px;
}

.review-lightbox-arrow-right {
    right: 20px;
}

.review-lightbox-content {
    position: relative;
    z-index: 10001;
    max-width: 90%;
    max-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.review-lightbox-content img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 8px;
}

.review-lightbox-counter {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    font-size: 16px;
    z-index: 10001;
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 16px;
    border-radius: 20px;
}

.review-lightbox-thumbs {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10001;
    max-width: 90%;
    overflow-x: auto;
    padding: 10px;
}

.review-lightbox-thumb {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s, transform 0.3s;
    border: 2px solid transparent;
}

.review-lightbox-thumb:hover {
    opacity: 0.9;
}

.review-lightbox-thumb.active {
    opacity: 1;
    border-color: var(--accent-color, #c9a227);
    transform: scale(1.1);
}

.review-lightbox-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
