/* ========================================
   OFFICE DETAIL PAGE - Chi tiết văn phòng
   Figma Design Implementation
   ======================================== */

.office-detail-page {
    background: #fff;
    min-height: calc(100vh - 150px);
    padding: 0 0 50px;
}

/* Page Title */
.office-title {
    font-size: 20px;
    font-weight: 700;
    color: #0036a5;
    text-align: center;
    margin: 25px 0;
}

/* Image Carousel */
.office-carousel {
    margin-bottom: 25px;
}

.carousel-main {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-image {
    width: 100%;
    height: 400px;
    background: #d9d9d9;
    border-radius: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-image .image-placeholder {
    text-align: center;
    color: #000;
    font-size: 16px;
    font-weight: 700;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #333;
    transition: all 0.2s;
    z-index: 2;
}

.carousel-nav:hover {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.carousel-nav.prev {
    left: 15px;
}

.carousel-nav.next {
    right: 15px;
}

.carousel-thumbs {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.thumb-item {
    flex: 0 0 calc((100% - 60px) / 7);
    height: 80px;
    background: #d9d9d9;
    border-radius: 0;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.2s;
}

.thumb-item:hover,
.thumb-item.active {
    border-color: #0036a5;
}

.thumb-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumb-placeholder {
    width: 100%;
    height: 100%;
    background: #d9d9d9;
}

/* Office Info Section */
.office-info-section {
    background: #fff;
    padding: 25px 0;
    margin-bottom: 25px;
}

.section-title {
    font-size: 16px;
    font-weight: 700;
    color: #000;
    margin: 0 0 20px;
}

.office-info-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
}

.office-info-list li {
    padding: 8px 0;
    font-size: 14px;
    color: #000;
    line-height: 1.5;
}

.info-label {
    font-weight: 700;
    margin-right: 8px;
}

.info-value {
    font-weight: 400;
}

.btn-view-map {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 25px;
    background: #0036a5;
    color: #fff;
    border-radius: 10px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.2s;
}

.btn-view-map:hover {
    background: #002a7a;
    color: #fff;
}

/* Reviews Section */
.office-reviews-section {
    background: #fff;
    padding: 25px 0;
}

.reviews-header {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: flex-start;
    padding-bottom: 20px;
    border-bottom: 1px solid #b9b9b9;
    margin-bottom: 20px;
}

.reviews-summary {
    flex: 0 0 auto;
}

.reviews-title {
    font-size: 16px;
    font-weight: 700;
    color: #000;
    margin: 0 0 10px;
}

.rating-display {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rating-score {
    font-size: 24px;
    font-weight: 700;
    color: #000;
}

.rating-stars i {
    color: #fbbf24;
    font-size: 14px;
}

.reviews-filters {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.filter-btn {
    padding: 8px 14px;
    background: #fff;
    color: #000;
    border: 1px solid #b9b9b9;
    border-radius: 20px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-btn:hover {
    border-color: #0036a5;
    color: #0036a5;
}

.filter-btn.active {
    background: #0036a5;
    color: #fff;
    border-color: #0036a5;
}

.filter-btn i {
    color: #fbbf24;
    font-size: 11px;
}

.filter-btn.active i {
    color: #fff;
}

.reviews-action {
    flex: 0 0 auto;
    text-align: right;
}

.reviews-action p {
    font-size: 13px;
    color: #666;
    margin: 0 0 10px;
}

.btn-write-review {
    padding: 10px 20px;
    background: #0036a5;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-write-review:hover {
    background: #002a7a;
}

/* Review Form */
.review-form-container {
    background: #f5f5f5;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.review-form .form-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.review-form .form-header span:first-child {
    font-size: 14px;
    font-weight: 500;
    color: #000;
}

.rating-input i {
    font-size: 20px;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s;
}

.rating-input i.active,
.rating-input i:hover {
    color: #fbbf24;
}

.rating-text {
    font-size: 13px;
    color: #666;
}

.review-form textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    border: 1px solid #b9b9b9;
    border-radius: 10px;
    font-size: 14px;
    resize: vertical;
    margin-bottom: 15px;
}

.review-form textarea:focus {
    outline: none;
    border-color: #0036a5;
}

.form-upload {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
}

.form-upload span {
    font-size: 13px;
    color: #666;
}

.btn-upload {
    padding: 8px 15px;
    background: #0036a5;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-upload:hover {
    background: #002a7a;
}

.upload-preview {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.preview-item {
    position: relative;
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
}

.preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-item button {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 20px;
    height: 20px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 15px;
}

.btn-cancel {
    padding: 10px 20px;
    background: #fff;
    color: #666;
    border: 1px solid #b9b9b9;
    border-radius: 10px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-cancel:hover {
    border-color: #999;
    color: #333;
}

.btn-submit {
    padding: 10px 20px;
    background: #0036a5;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-submit:hover {
    background: #002a7a;
}

/* Reviews List - Fixed */
.reviews-list {
    margin-top: 20px;
}

.review-item {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: start;
    -ms-flex-align: start;
    align-items: flex-start;
    padding: 15px 0;
    border-bottom: 1px solid #e5e5e5;
}

.review-item:first-child {
    padding-top: 0;
}

.review-item:last-child {
    border-bottom: none;
}

.review-avatar {
    -webkit-box-flex: 0;
    -ms-flex: 0 0 44px;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    margin-right: 12px;
}

.review-avatar img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    background: #d9d9d9;
}

.review-content {
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    min-width: 0;
}

.review-meta {
    margin: 0 0 4px 0;
    padding: 0;
    line-height: 1.4;
}

.review-author {
    font-size: 14px;
    font-weight: 600;
    color: #000;
    margin-right: 8px;
}

.review-rating {
    display: inline;
    margin-right: 4px;
}

.review-rating i {
    font-size: 12px;
    color: #fbbf24;
}

.review-rating i.fa-star-o {
    color: #ddd;
}

.review-date {
    font-size: 12px;
    color: #999;
}

.review-text {
    font-size: 14px;
    color: #000;
    line-height: 1.5;
    margin: 0;
    padding: 0;
}

.review-divider {
    display: none;
}

/* Responsive */
@media (max-width: 1200px) {
    .thumb-item {
        flex: 0 0 100px;
    }
}

@media (max-width: 991px) {
    .carousel-image {
        height: 300px;
    }

    .reviews-header {
        flex-direction: column;
    }

    .reviews-action {
        text-align: left;
        width: 100%;
    }
}

@media (max-width: 767px) {
    .office-title {
        font-size: 18px;
    }

    .carousel-image {
        height: 250px;
    }

    .carousel-nav {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }

    .thumb-item {
        flex: 0 0 60px;
        height: 50px;
    }

    .reviews-filters {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 5px;
    }

    .filter-btn {
        white-space: nowrap;
    }

    .review-form .form-header {
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .office-detail-page {
        padding-bottom: 30px;
    }

    .office-title {
        font-size: 16px;
        margin: 20px 0;
    }

    .carousel-image {
        height: 200px;
    }

    .thumb-item {
        flex: 0 0 50px;
        height: 40px;
    }

    .rating-score {
        font-size: 20px;
    }

    .review-item {
        padding: 12px 0;
    }

    .review-avatar {
        -ms-flex: 0 0 36px;
        flex: 0 0 36px;
        width: 36px;
        height: 36px;
        margin-right: 10px;
    }

    .review-avatar img {
        width: 36px;
        height: 36px;
    }
    
    .review-author {
        font-size: 13px;
    }
    
    .review-text {
        font-size: 13px;
    }

    .office-info-section,
    .office-reviews-section {
        padding: 20px 0;
    }

    .section-title {
        font-size: 15px;
    }
}
