.tnb-wc-card {
    background: #f7f7f7;
    padding: 10px 12px;
    border-radius: 4px;
}
/* error */
.tnb-wc-error {
    background: #fef2f2;
    color: #b91c1c;
    padding: 8px 10px;
}
.tnb-error-field {
    border: 2px solid #dc2626 !important;
    background-color: #fff5f5 !important;
}

/* layout */
/* ===== FORM TRA CỨU NGẮN GỌN & CĂN GIỮA ===== */
.tnb-wc-lookup-form-wrap {
    display: flex;
    justify-content: center;
}
form.tnb-wc-lookup-form {
    width: 50%;
}
.tnb-wc-lookup-form input[type="text"] {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    height: 40px;
}
.tnb-wc-lookup-group-btn {
    display: flex;
    gap: 10px;
}
.tnb-wc-lookup-group-btn button {
    margin: 0;
    width: 50%;
    border-radius: 5px;
}
.tnb-wc-lookup-group-btn .btn-history {
    background: no-repeat;
    color: #000;
}
/* Nút nằm cạnh input, cùng hàng */
.tnb-wc-btn {
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s ease;
    height: 36px;
    align-self: flex-end;
}

.tnb-wc-btn:hover {
    background: #185a8a;
}








/* ===== Giữ giao diện kết quả tra cứu như cũ ===== */
.tnb-wc-result {
    margin-top: 20px;
}
/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
    form.tnb-wc-lookup-form {
        width: 100%;
    }

}
@media (max-width: 476px) {
    .tnb-wc-lookup-group-btn {
    display: flex;
    flex-direction: column;
    }
    .tnb-wc-lookup-group-btn button {
        width: 100%;
    }

}
.tnb-wc-lookup-wrap {
    border: 1px solid #ddd;
    padding: 15px;
    background: #fff;
}

.tnb-wc-lookup-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
}

.tnb-wc-btn {
    background: #2271b1;
    color: #fff;
}

.tnb-wc-loading {
    margin-top: 10px;
}

.tnb-wc-result {
    margin-top: 15px;
}

/* ==========================================
   GIAO DIỆN TRA CỨU BAO HANH
   ========================================== */
.tnb-bh-ticket {
    background: #fff;
    font-size: 15px;
    line-height: 1.5;
    color: #333;
    margin: 10px 0;
    box-shadow: 0 0 4px 0px rgb(0 0 0 / 25%);
    border-radius: 10px;
}

.tnb-bh-header {
    background: #f5821f;
    
    padding: 10px 16px;
    text-transform: uppercase;
    font-weight: 700;
    font-size: 14px;
    text-align: center;
}
.tnb-bh-header h3 {
    margin: 0;
    color: #fff;
}
.tnb-bh-custom-content {
    display: flex;
}

.tnb-bh-custom-content .tnb-bh-box {
    border: 1px solid #f1f1f1;
}
.tnb-bh-box {
    background: #fff;
    width: 100%;
}
.tnb-bh-box-title {
    background: #fff7e6;
    padding: 8px 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}

.tnb-bh-box-title span {
    display: inline-block;
    background: #f5821f;
    color: #fff;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    text-align: center;
    line-height: 22px;
    font-size: 13px;
}

.tnb-bh-box-body {
    padding: 12px 12px 14px;
}
.tnb-bh-box-body.table-products {
    padding: 0;
}

.tnb-bh-box-body p {
    margin: 4px 0;
}

.tnb-bh-table-wrap {
    overflow-x: auto;
}

.tnb-bh-table {
    width: 100%;
    border-collapse: collapse;
}

.tnb-bh-table th {
    background: #535353;
    color: #fff;
    padding: 8px 6px;
    text-align: left;
    font-weight: 600;
}

.tnb-bh-table td {
    border: 1px solid #eee;
    padding: 6px 10px;
    vertical-align: top;
}
/* ==== BANG THONG TIN SAN PHAM ==== */
.tnb-bh-table-wrap {
    width: 100%;
    overflow-x: auto;           /* Cho phép cuộn ngang */
    -webkit-overflow-scrolling: touch; /* Cuộn mượt trên iOS */
    border-radius: 6px;
}

/* Giữ cho bảng không bị co cột quá nhỏ khi cuộn */
.tnb-bh-table {
    width: 100%;
    min-width: 600px;           /* Đặt chiều rộng tối thiểu để tạo vùng cuộn */
    border-collapse: collapse;
    background: #fff;
}

/* ==== HÌNH ẢNH THI CÔNG (CẬP NHẬT) ==== */
.tnb-bh-images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
}

/* Mỗi ảnh là 1 item riêng biệt */
.tnb-bh-img-item {
    flex: 0 0 calc(20% - 10px); /* Desktop: 5 ảnh 1 hàng */
    box-sizing: border-box;
}

/* Ảnh thi công */
.tnb-bh-img-item img {
    width: 100%;
    aspect-ratio: 1 / 1; /* Giữ hình vuông */
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #ccc;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tnb-bh-img-item img:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* Mobile: 2 ảnh / hàng */
@media (max-width: 768px) {
    .tnb-bh-img-item {
        flex: 0 0 calc(50% - 10px);
    }
}

/* trên mobile */
@media (max-width: 512px) {

    .tnb-bh-img-item {
        width: calc(50% - 10px);
    }
}

@media (max-width: 768px) {
    .tnb-bh-header {
        font-size: 16px;
    }
    .tnb-bh-custom-content {
    display: unset;
}
}

/* ==== POPUP ẢNH ==== */
.tnb-bh-popup {
    display: none;
    position: fixed;
    z-index: 9999;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8);
}

.tnb-bh-popup-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 80%;
    border-radius: 6px;
    box-shadow: 0 0 15px rgba(0,0,0,0.5);
}

.tnb-bh-close {
    position: absolute;
    top: 25px;
    right: 40px;
    color: #fff;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s ease-in-out;
}

.tnb-bh-close:hover {
    color: #f5821f;
}
/* ==========================================
   GIAO DIỆN TRA CỨU LỊCH SỬ DỊCH VỤ Ô TÔ
   ========================================== */

/* ========== ITEM ========== */
.tnb-service-item {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.2s ease-in-out;
}

.tnb-service-item:hover {
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

/* ========== HEADER ========== */
.tnb-service-header {
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 10px;
    color: #111827;
}

.tnb-service-header .date {
    color: #6b7280;
    font-weight: 400;
    margin-left: 8px;
}

.tnb-service-header .ticket {
    color: #0073aa;
    margin-left: 10px;
    font-size: 14px;
}

/* ========== BODY ========== */
.tnb-service-body {
    background: #f9fafb;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
}

.tnb-service-body p {
    margin: 6px 0;
    font-size: 14px;
}

.tnb-service-body strong {
    color: #111827;
}

/* ========== BẢNG CHI TIẾT DỊCH VỤ ========== */
.tnb-service-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    margin-bottom: 15px;
    font-size: 14px;
}

.tnb-service-table th {
    background: #0073aa;
    color: #fff;
    padding: 8px 10px;
    text-align: left;
    font-weight: 600;
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
}

.tnb-service-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #e5e7eb;
    background: #fff;
}

.tnb-service-table tr:nth-child(even) td {
    background: #f3f4f6;
}

/* Hiển thị danh sách công việc và phụ tùng */
.service-list,
.parts-list {
    margin-top: 10px;
    margin-bottom: 15px;
}

.service-list strong,
.parts-list strong {
    display: block;
    margin-bottom: 6px;
    color: #0073aa;
}

/* ========== ẢNH THI CÔNG ========== */
.tnb-bh-img-item {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.tnb-bh-thumb {

    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.tnb-bh-thumb:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* ========== GHI CHÚ ========== */
.tnb-service-body p:last-child {
    background: #fff8e1;
    border-left: 4px solid #f59e0b;
    padding: 8px 10px;
    border-radius: 6px;
    margin-top: 8px;
    font-style: italic;
    color: #92400e;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    .tnb-service-table th,
    .tnb-service-table td {
        font-size: 13px;
        padding: 6px;
    }
   
}
/* Overlay toàn trang khi đang gửi AJAX */
.tnb-global-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.05); /* mờ nhẹ */
    z-index: 9998;
    cursor: wait;
}

/* Đổi cursor toàn trang khi busy */
body.tnb-global-busy {
    cursor: wait;
}
/* Spinner animation 3 dots */
/* === Modern loading spinner === */
.tnb-spinner {
    margin: 10px auto;
    width: 70px;
    text-align: center;
}

.tnb-spinner > div {
    width: 14px;
    height: 14px;
    background-color: #0073aa;
    border-radius: 100%;
    display: inline-block;
    animation: tnb-bouncedelay 1.4s infinite ease-in-out both;
}

.tnb-spinner .tnb-bounce1 {
    animation-delay: -0.32s;
}
.tnb-spinner .tnb-bounce2 {
    animation-delay: -0.16s;
}

@keyframes tnb-bouncedelay {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1.0); }
}

/* text dưới spinner */
.tnb-loading-text {
    text-align: center;
    font-size: 13px;
    color: #333;
    margin-top: 6px;
}

/* Overlay toàn trang khi busy */
.tnb-global-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.5);
    z-index: 9998;
    cursor: wait;
}
body.tnb-global-busy {
    cursor: wait;
}

