/* Секція відгуків - не перекриває глобальні стилі */
.reviews-section {
    /* Ніяких стилів - використовує стилі білдера */
}

.reviews-container {
    /* Ніяких обмежень ширини */
}

.reviews-header {
    text-align: center;
    margin-bottom: 50px;
}

.reviews-header h2 {
    background: linear-gradient(135deg, #013040 0%, #41b6d7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 32px;
    margin-bottom: 15px;
    animation: titleShine 3s ease-in-out infinite;
}

@keyframes titleShine {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.reviews-header p {
    color: #013040;
    opacity: 0.7;
    font-size: 18px;
}

/* Середній рейтинг */
.average-rating {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
}

.rating-stars {
    display: flex;
    gap: 3px;
}

.rating-text {
    display: flex;
    align-items: center;
    gap: 5px;
}

.rating-number {
    font-size: 24px;
    font-weight: bold;
    color: #013040;
}

.rating-count {
    font-size: 16px;
    color: #013040;
    opacity: 0.6;
}

/* Стилі для зірок в тексті */
.rating-stars-text {
    color: #013040;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.rating-stars-text .star-symbol {
    color: #41b6d7;
    font-size: 18px;
    opacity: 0.8;
}

.rating-stars-text .star-symbol.filled {
    color: #f6ca00;
    opacity: 1;
	font-size: 30px;
}

.rating-stars-text .star-symbol.empty {
    color: #8c8c8c;
    opacity: 0.6;
	font-size: 30px;
}

/* Сітка відгуків */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

@media (min-width: 1200px) {
    .reviews-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.review-card {
    background: #c6e8f1;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(30px);
    position: relative;
    overflow: hidden;
}

.review-card.animate {
    animation: fadeInUp 0.6s ease forwards;
}

.review-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(65, 182, 215, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s;
    opacity: 0;
}

.review-card:hover::before {
    animation: wave 1.5s ease-in-out;
}

@keyframes wave {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); opacity: 0; }
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.review-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
}

/* Хвильова анімація появи */
.review-card.animate:nth-child(1) { animation-delay: 0.1s; }
.review-card.animate:nth-child(2) { animation-delay: 0.2s; }
.review-card.animate:nth-child(3) { animation-delay: 0.3s; }
.review-card.animate:nth-child(4) { animation-delay: 0.4s; }
.review-card.animate:nth-child(5) { animation-delay: 0.5s; }
.review-card.animate:nth-child(6) { animation-delay: 0.6s; }

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.review-author h4 {
    color: #013040;
    margin: 0;
    font-size: 16px;
}

.quote-icon {
    color: #41b6d7;
    opacity: 0.3;
}

/* Рейтинг */
.review-rating {
    display: flex;
    gap: 3px;
    margin-bottom: 15px;
}

.star {
    fill: #fafafa;
    stroke: none;
    width: 20px;
    height: 20px;
}

.star.filled {
    fill: #f6ca00;
    animation: starGlow 2s ease-in-out infinite alternate;
}

@keyframes starGlow {
    from { filter: drop-shadow(0 0 2px #ffe56d); }
    to { filter: drop-shadow(0 0 8px #ffe56d); }
}

.review-text {
    color: #013040;
    opacity: 0.8;
    line-height: 1.5;
    margin-bottom: 10px;
    font-size: 14px;
}

.review-date {
    color: #013040;
    opacity: 0.5;
    font-size: 12px;
    margin: 0;
}

/* Кнопка залишити відгук */
.reviews-cta {
    text-align: center;
}

.leave-review-btn {
    background: linear-gradient(135deg, #41b6d7 0%, #013040 100%);
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 15px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.leave-review-btn:hover {
    transform: translateY(-2px);
}

/* Модальне вікно */
.review-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
}

.review-modal.active {
    display: flex;
}

.review-modal-content {
    background: white;
    padding: 40px;
    border-radius: 15px;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.review-modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #013040;
}

.review-modal h3 {
    color: #013040;
    margin-bottom: 30px;
    text-align: center;
    font-size: 24px;
}

/* Форма */
.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    color: #013040;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #41b6d7;
}

/* Рейтинг інпут */
.rating-input {
    display: flex;
    gap: 5px;
    margin-bottom: 10px;
}

.rating-star {
    font-size: 30px;
    color: #e5e5e5;
    cursor: pointer;
    transition: color 0.2s;
}

.rating-star:hover,
.rating-star.active {
    color: #ffe56d;
}

/* Кнопка відправки */
.submit-review-btn {
    width: 100%;
    background: linear-gradient(135deg, #ffe56d 0%, #41b6d7 100%);
    color: #013040;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.submit-review-btn:hover {
    transform: translateY(-2px);
}

/* Кнопка дивитися ще */
.load-more-reviews {
    text-align: center;
    margin: 30px 0;
}

.load-more-btn {
    background: transparent;
    color: #41b6d7;
    border: 1px solid #41b6d7;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.load-more-btn:hover {
    background: #41b6d7;
    color: white;
}

/* Повідомлення в формі */
.form-message {
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-weight: 500;
}

.form-message-success {
    background: #e8f5e8;
    color: #388e3c;
    border: 1px solid #4caf50;
}

.form-message-error {
    background: #ffebee;
    color: #d32f2f;
    border: 1px solid #f44336;
}

/* Адаптивність */
@media (max-width: 768px) {
    .reviews-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .review-card {
        padding: 20px;
    }
    
    .reviews-header h2 {
        font-size: 28px;
    }
    
    .review-modal-content {
        padding: 30px 20px;
    }
}