/* Khối Đánh Giá & Nhận Xét Học Viên - Phần 3: Modal & Lightbox */
.tdlx-review-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    box-sizing: border-box;
}
.tdlx-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
}
.tdlx-modal-dialog {
    position: relative;
    z-index: 10;
    background: #FFFFFF;
    width: 100%;
    max-width: 540px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    padding: 16px 14px;
    box-sizing: border-box;
    animation: tdlxModalIn 0.25s ease-out;
}
@keyframes tdlxModalIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}
.tdlx-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1.5px solid #F1F5F9;
    padding-bottom: 12px;
    margin-bottom: 14px;
    gap: 8px;
}
.tdlx-modal-title {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
    color: #8B1E1E;
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1.35;
}
.tdlx-modal-title i {
    color: #F59E0B;
    flex-shrink: 0;
}
.btn-close-modal {
    background: none;
    border: none;
    font-size: 26px;
    color: #94A3B8;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
    flex-shrink: 0;
    min-width: 32px;
    min-height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}
.btn-close-modal:hover {
    color: #1E293B;
}
.tdlx-modal-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    box-sizing: border-box;
}
.form-star-picker-wrap {
    background: #FFFDF8;
    border: 1px solid #FDE68A;
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    width: 100%;
    box-sizing: border-box;
}
.form-star-picker-wrap label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    margin-bottom: 5px;
}
.star-rating-select {
    display: inline-flex;
    flex-direction: row-reverse;
    justify-content: center;
    gap: 8px;
}
.star-rating-select input {
    display: none;
}
.star-rating-select label {
    font-size: 28px;
    color: #CBD5E1;
    cursor: pointer;
    transition: color 0.2s, transform 0.2s;
    margin: 0;
    padding: 2px;
}
.star-rating-select label:hover,
.star-rating-select label:hover ~ label,
.star-rating-select input:checked ~ label {
    color: #F59E0B;
    transform: scale(1.12);
}
.modal-form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
}
.modal-form-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
    box-sizing: border-box;
}
.modal-form-field label {
    font-size: 12.5px;
    font-weight: 700;
    color: #334155;
}
.modal-form-field input,
.modal-form-field select,
.modal-form-field textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1.5px solid #CBD5E1;
    border-radius: 6px;
    font-size: 16px;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color 0.2s;
}
.modal-form-field input:focus,
.modal-form-field select:focus,
.modal-form-field textarea:focus {
    border-color: #8B1E1E;
}
.modal-form-actions {
    margin-top: 4px;
    width: 100%;
}
.btn-submit-review {
    width: 100%;
    background: linear-gradient(135deg, #8B1E1E 0%, #6B1212 100%);
    color: #FFFFFF;
    border: none;
    padding: 13px 18px;
    border-radius: 8px;
    font-size: 14.5px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    box-sizing: border-box;
    box-shadow: 0 4px 12px rgba(139, 30, 30, 0.25);
    transition: transform 0.2s, box-shadow 0.2s;
}
.btn-submit-review:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(139, 30, 30, 0.35);
}
.review-form-status {
    font-size: 12.5px;
    font-weight: 600;
    text-align: center;
    margin-top: 4px;
    width: 100%;
    box-sizing: border-box;
}
.review-form-status.success {
    color: #059669;
    background: #ECFDF5;
    padding: 8px;
    border-radius: 6px;
}
.tdlx-photo-lightbox {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    box-sizing: border-box;
}
.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
}
.lightbox-content {
    position: relative;
    z-index: 10;
    max-width: 96vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.btn-close-lightbox {
    position: absolute;
    top: -42px;
    right: 0;
    background: none;
    border: none;
    color: #FFFFFF;
    font-size: 32px;
    cursor: pointer;
    line-height: 1;
    min-width: 40px;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lightbox-img {
    max-width: 100%;
    max-height: 75vh;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}
.lightbox-caption {
    color: #FFFFFF;
    margin-top: 8px;
    font-size: 13px;
    text-align: center;
}

@media (min-width: 600px) {
    .tdlx-modal-dialog {
        padding: 22px;
    }
    .tdlx-modal-title {
        font-size: 18px;
    }
    .modal-form-grid {
        grid-template-columns: 1fr 1fr;
    }
    .modal-form-field input,
    .modal-form-field select,
    .modal-form-field textarea {
        font-size: 13px;
    }
}
