/* =================================================
   GIAO DIỆN MUA LINK & LỊCH SỬ MUA (buy-link-form.css)
================================================= */

.buy-link-container {
    max-width: 850px;
    margin: 0 auto;
    padding: 20px 0;
    font-family: inherit;
}

/* --- CARD CHUNG --- */
.bl-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    border: 1px solid #f1f5f9;
    margin-bottom: 35px;
    overflow: hidden;
}

.bl-card-header {
    padding: 25px 30px;
    border-bottom: 1px solid #f1f5f9;
    background: #fafbfc;
}

.bl-card-header h2 { margin: 0 0 5px 0; font-size: 22px; color: #0f172a; font-weight: 700; }
.bl-card-header h3 { margin: 0; font-size: 18px; color: #1e293b; font-weight: 700; }
.bl-card-header p { margin: 0; font-size: 14px; color: #64748b; }

.bl-card-body {
    padding: 30px;
}

/* --- THÔNG BÁO LỖI / THÀNH CÔNG --- */
.bl-alert {
    padding: 14px 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    font-size: 15px;
    font-weight: 500;
}
.bl-alert.error { background: #fef2f2; color: #ef4444; border: 1px solid #fecaca; }
.bl-alert.success { background: #f0fdf4; color: #16a34a; border: 1px solid #bbf7d0; }

/* --- FORM KIỂM TRA MÃ --- */
.bl-form-group { margin-bottom: 20px; }
.bl-form-group label { display: block; margin-bottom: 8px; font-weight: 600; color: #334155; font-size: 14px; }

.bl-input-wrapper {
    position: relative;
    width: 100%;
}

.bl-input-wrapper svg {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: #94a3b8;
}

.bl-input-wrapper input {
    width: 100%;
    padding: 14px 16px 14px 45px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background-color: #f8fafc;
    font-size: 16px;
    color: #334155;
    transition: all 0.3s ease;
    box-sizing: border-box;
    outline: none;
}

.bl-input-wrapper input:focus {
    border-color: #3b82f6;
    background-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* --- NÚT BẤM --- */
.bl-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 28px; border: none; border-radius: 10px; font-size: 16px; font-weight: 600;
    cursor: pointer; transition: all 0.2s ease; text-decoration: none; outline: none;
}

.bl-btn svg { width: 20px; height: 20px; }

.bl-btn-primary { background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%); color: #ffffff; width: 100%; }
.bl-btn-primary:hover { box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3); transform: translateY(-1px); }

.bl-btn-success { background: linear-gradient(135deg, #10b981 0%, #059669 100%); color: #ffffff; flex: 1; }
.bl-btn-success:hover { box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3); transform: translateY(-1px); }

.bl-btn-secondary { background: #f1f5f9; color: #475569; border: 1px solid #e2e8f0; }
.bl-btn-secondary:hover { background: #e2e8f0; color: #1e293b; }

.bl-action-buttons { display: flex; gap: 15px; margin-top: 25px; }

/* --- BIÊN LAI THANH TOÁN --- */
.bl-receipt-box {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    padding: 25px;
    margin-top: 10px;
}

.receipt-title { margin: 0 0 20px 0; font-size: 16px; color: #1e293b; text-align: center; text-transform: uppercase; letter-spacing: 0.5px; }

.receipt-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; font-size: 15px; color: #475569; }
.receipt-row .code-highlight { background: #eff6ff; color: #3b82f6; padding: 4px 10px; border-radius: 6px; font-weight: 700; letter-spacing: 1px; }

.receipt-row.vip-row { color: #10b981; }
.receipt-row.vip-row .vip-price { font-weight: 600; }

.receipt-divider { height: 1px; background: dashed 1px #cbd5e1; margin: 20px 0; }

.total-row { font-size: 18px; color: #0f172a; }
.total-price { font-size: 24px; font-weight: 800; color: #3b82f6; }

/* --- BẢNG LỊCH SỬ LINK MUA --- */
.table-responsive { overflow-x: auto; }
.bl-table { width: 100%; border-collapse: collapse; min-width: 600px; }
.bl-table th { background: #f8fafc; color: #475569; font-weight: 600; text-align: left; padding: 16px 25px; font-size: 14px; border-bottom: 1px solid #e2e8f0; }
.bl-table td { padding: 16px 25px; color: #334155; font-size: 15px; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
.bl-table tbody tr:last-child td { border-bottom: none; }
.bl-table tbody tr:hover { background-color: #f8fafc; }

.bl-code-badge { background: #f1f5f9; color: #3b82f6; padding: 6px 12px; border-radius: 6px; font-weight: 600; font-size: 13.5px; letter-spacing: 0.5px; }
.bl-price { color: #ef4444 !important; font-weight: 600; }
.bl-time { color: #64748b !important; font-size: 14px !important; }

.bl-btn-open {
    display: inline-block; padding: 6px 14px; background-color: #eff6ff; color: #3b82f6;
    border-radius: 6px; font-weight: 600; font-size: 13px; text-decoration: none; transition: all 0.2s; border: 1px solid #bfdbfe;
}
.bl-btn-open:hover { background-color: #3b82f6; color: #ffffff; }

/* Mobile Responsive */
@media (max-width: 600px) {
    .bl-card-header, .bl-card-body { padding: 20px; }
    .bl-action-buttons { flex-direction: column-reverse; }
    .bl-btn { width: 100%; }
    .total-row { flex-direction: column; align-items: flex-start; gap: 5px; }
}
/* --- BỔ SUNG GIAO DIỆN HIỂN THỊ SỐ DƯ VÀ TICK CHỌN VIP --- */

.account-info-row {
    font-size: 14px;
    background: #f1f5f9;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 8px !important;
}

.vip-checkbox-area {
    margin-top: 15px;
    background: #fffbeb;
    border: 1px dashed #fcd34d;
    border-radius: 10px;
    padding: 12px 15px;
    transition: all 0.3s;
}

.vip-checkbox-area:hover {
    background: #fef3c7;
    border-color: #f59e0b;
}

.vip-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    margin: 0;
}

.vip-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #f59e0b;
}

.vip-checkbox-text {
    font-size: 14.5px;
    color: #b45309;
}