#reviews {
    display: flex;
    align-items: center;
    flex-direction: column;
}

#reviews h1 {
    text-align: center;
    font-size: 40px;
    margin-bottom: 20px;
}

.reviews_block {
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
}

.reviews_block h2 {
    font-size: 40px;
    text-align: center;
    margin: 0;
}

#reviews-block {
    display: flex;
    align-items: center;
    position: relative;
}

.reviews_images {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    gap: 16px;
    position: relative;
    align-items: center;
    width: 932px; /* 3 × 300px + 2 × 16px for three reviews */
    margin: 0 auto;
    padding: 0 20px;
}

.reviews_images::-webkit-scrollbar {
    display: none;
}

.review_item {
    flex-shrink: 0;
    width: 300px;
    height: 300px;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    scroll-snap-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
}

.review-head {
    display: flex;
    justify-content: space-between;
    background: var(--main-color);
    width: 100%;
    border-radius: 12px 12px 0 0;
    gap: 10px;
}

.review-head-left {
    padding: 10px 0 10px 10px;
}

.review-head-right {
    padding: 10px 10px 10px 0;
    width: 80px;
}

.review-head-left p,
.review-head-right p {
    margin: 0;
    text-align: left;
    width: 170px;
}

.review-head-left-name {
    font-size: 20px;
}

.review-head-left-address {
    font-size: 10px;
}

.review-head-right-stars span {
    font-size: 24px;
}

.review-text {
    margin: 8px;
    color: #000;
    flex-grow: 1;
    overflow-y: auto;
}

.review-text::-webkit-scrollbar {
    display: none;
}

.arrow {
    display: none;
    position: absolute;
    top: 50%;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 24px;
    cursor: pointer;
    z-index: 20;
    user-select: none;
}

.arrow.left {
    left: -80px;
}

.arrow.right {
    right: -80px;
}

.review-button-main {
    margin-top: 20px;
    font-size: 20px;
}

@media (min-width: 1121px) {
    .arrow {
        display: block;
    }
}

@media (max-width: 1120px) {
    #reviews h1 {
        font-size: 8vw;
    }

    .reviews_block h2 {
        font-size: 8vw;
    }

    .reviews_images {
        gap: 10px;
        width: 80vw;
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fff;
    margin: 15% auto;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
    width: 80%;
    max-width: 500px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: var(--main-color);
}

#review-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

#review-form input[type="text"],
#review-form textarea {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 10px;
    font-size: 16px;
    font-family: 'Days', sans-serif;
}

#review-form textarea {
    height: 100px;
    resize: vertical;
}

.star-rating {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 5px;
}

.star-rating input {
    display: none;
}

.star-rating label {
    font-size: 24px;
    color: #ccc;
    cursor: pointer;
}

.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label {
    color: #ffd700;
}

#review-form button {
    background-color: var(--main-color);
    color: white;
    padding: 10px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    font-family: 'Days', sans-serif;
    transition: 0.3s;
}

#review-form button:hover {
    opacity: 0.9;
}

#add-review-btn {
    background-color: var(--main-color);
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-family: 'Days', sans-serif;
    cursor: pointer;
    transition: 0.3s;
    margin: 20px auto;
    display: block;
}

#add-review-btn:hover {
    opacity: 0.9;
}