.baro-review-grid {
    display: flex;
    align-items: center;
    border-bottom: 1px solid #eee;
}

.baro-review-wrapper h2 {
    text-transform: uppercase;
    font-weight: bold;
    font-size: 1.5rem;
}

.baro-review-left, .baro-review-middle, .baro-review-right {
    flex: 1;
}

.baro-review-middle {
    border-right: 1px solid #eee;
    border-left: 1px solid #eee;
    padding: 20px 40px;
}

.baro-review-right, .baro-review-left {
    text-align: center;
}

.baro-review-average {
    font-size: 2.5em;
    color: green;
    font-weight: bold;
}

.baro-stars .star {
    color: #ccc;
    font-size: 1.2em;
}

.baro-review-average-container{
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-around;
}

.baro-rating-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 4px 0;
}

.baro-bar {
    flex: 1;
    height: 6px;
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
}

.baro-bar .fill {
    height: 100%;
    background: green;
}

.baro-review-btn {
    padding: 8px 14px;
    border: 2px solid green;
    background: white;
    color: green;
    cursor: pointer;
}

#baro-review-form input,
#baro-review-form textarea {
    width: 100%;
    padding: 8px;
    margin: 5px 0;
    box-sizing: border-box;
}

#baro-review-form .baro-stars-input label {
    font-size: 20px;
    color: #ccc;
    cursor: pointer;
}

#baro-review-form .baro-stars-input input {
    display: none;
}

#baro-review-form .baro-stars-input input:checked ~ label {
    color: gold;
}

.baro-submit {
    padding: 10px 20px;
    background: orange;
    border: none;
    color: white;
    cursor: pointer;
}

.baro-stars-input {
    display: flex;
    flex-direction: row-reverse; 
    justify-content: flex-end;
}

.baro-stars-input input {
    display: none;
}

.baro-stars-input label {
    font-size: 24px;
    color: #ccc;
    cursor: pointer;
    padding: 0 2px;
}

.baro-stars-input input:checked ~ label {
    color: gold;
}

.baro-review-list {
    margin-top: 30px;
}

.baro-single-review {
    border-bottom: 1px solid #eee;
    padding: 10px 0;
}

.baro-review-stars .star-rating {
    font-size: 16px;
    color: gold;
}

.baro-review-author {
    margin: 5px 0 0;
}

.baro-review-content {
    margin: 5px 0;
}

.baro-review-date {
    font-size: 12px;
    color: #888;
}

.baro-pagination {
    margin-top: 15px;
    text-align: center;
}

.baro-pagination .page-numbers {
    display: inline-block;
    margin: 0 4px;
    padding: 6px 12px;
    border: 1px solid #ddd;
    color: #333;
    text-decoration: none;
}

.baro-pagination .current {
    background: green;
    color: white;
    border-color: green;
}

/* =================================
   RESPONSIVE DESIGN
   ================================= */

/* Tablet (768px và nhỏ hơn) */
@media (max-width: 768px) {
    .baro-review-wrapper h2 {
        font-size: 1.3rem;
        text-align: center;
        margin-bottom: 15px;
    }
    
    .baro-review-grid {
        flex-direction: column;
        align-items: stretch;
    }
    
    .baro-review-left, .baro-review-middle, .baro-review-right {
        flex: none;
        width: 100%;
    }
    
    .baro-review-middle {
        border: none;
        border-top: 1px solid #eee;
        border-bottom: 1px solid #eee;
        padding: 15px 20px;
        order: 3;
    }
    
    .baro-review-left {
        order: 1;
        padding: 15px 0;
    }
    
    .baro-review-right {
        order: 2;
        padding: 15px 0;
    }
    
    .baro-review-average {
        font-size: 2em;
    }
    
    .baro-rating-row {
        gap: 8px;
        margin: 6px 0;
    }
    
    .baro-stars-input label {
        font-size: 20px;
    }
    
    .baro-pagination .page-numbers {
        padding: 8px 10px;
        margin: 0 2px;
    }
}

/* Mobile (480px và nhỏ hơn) */
@media (max-width: 480px) {
    .baro-review-wrapper h2 {
        font-size: 1.1rem;
        margin-bottom: 10px;
    }
    
    .baro-review-middle {
        padding: 12px 15px;
    }
    
    .baro-review-left, .baro-review-right {
        padding: 10px 0;
    }
    
    .baro-review-average {
        font-size: 1.8em;
    }
    
    .baro-stars .star {
        font-size: 1em;
    }
    
    .baro-rating-row {
        gap: 6px;
        margin: 8px 0;
        font-size: 0.9em;
    }
    
    .baro-review-btn {
        padding: 10px 16px;
        font-size: 14px;
        width: 100%;
        max-width: 200px;
    }
    
    #baro-review-form input,
    #baro-review-form textarea {
        padding: 10px;
        font-size: 16px; /* Tránh zoom trên iOS */
    }
    
    .baro-stars-input {
        justify-content: center;
        margin: 10px 0;
    }
    
    .baro-stars-input label {
        font-size: 24px;
        padding: 0 4px;
    }
    
    .baro-submit {
        padding: 12px 24px;
        width: 100%;
        max-width: 200px;
        font-size: 16px;
    }
    
    .baro-single-review {
        padding: 15px 0;
    }
    
    .baro-review-stars .star-rating {
        font-size: 14px;
    }
    
    .baro-pagination {
        margin-top: 20px;
    }
    
    .baro-pagination .page-numbers {
        padding: 10px 8px;
        margin: 0 1px;
        font-size: 14px;
        min-width: 35px;
        text-align: center;
    }
}

/* Mobile nhỏ (320px và nhỏ hơn) */
@media (max-width: 320px) {
    .baro-review-wrapper h2 {
        font-size: 1rem;
    }
    
    .baro-review-average {
        font-size: 1.6em;
    }
    
    .baro-rating-row {
        font-size: 0.85em;
        flex-wrap: wrap;
    }
    
    .baro-stars-input label {
        font-size: 20px;
        padding: 0 2px;
    }
    
    .baro-pagination .page-numbers {
        padding: 8px 6px;
        font-size: 12px;
        min-width: 30px;
    }
}

/* Landscape orientation trên mobile */
@media (max-width: 768px) and (orientation: landscape) {
    .baro-review-grid {
        flex-direction: row;
    }
    
    .baro-review-left, .baro-review-middle, .baro-review-right {
        flex: 1;
    }
    
    .baro-review-middle {
        border: none;
        border-left: 1px solid #eee;
        border-right: 1px solid #eee;
        order: 2;
        padding: 10px 20px;
    }
    
    .baro-review-left {
        order: 1;
    }
    
    .baro-review-right {
        order: 3;
    }
}

/* Cải thiện touch targets cho mobile */
@media (hover: none) and (pointer: coarse) {
    .baro-review-btn,
    .baro-submit,
    .baro-stars-input label,
    .baro-pagination .page-numbers {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 auto;
    }

    .baro-pagination{
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 10px;
    }

    .baro-pagination .page-numbers{
        margin: unset;
    }

    
    
    .baro-stars-input label {
        min-width: 44px;
        margin: 0 auto;
    }
}