/* Global fix for all table headers */
table th {
    display: table-cell !important;
    padding: 16px 20px !important;
    text-align: left !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: #ffffff !important;
    border: none !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    vertical-align: middle !important;
    white-space: nowrap !important;
}

table th i {
    display: none !important;
}

table thead {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

table thead tr {
    display: table-row !important;
}

table {
    display: table !important;
}
/* Compact page titles */
.page-header {
    margin-bottom: 15px !important;
}

.page-title {
    font-size: 22px !important;
    margin-bottom: 10px !important;
}
/* Compact header layout for all components */
.page-header {
    margin-bottom: 10px !important;
    padding-bottom: 10px !important;
}

.page-title {
    font-size: 20px !important;
    margin: 0 !important;
}

.content-card {
    margin-top: 0 !important;
}

.btn-primary {
    padding: 8px 16px !important;
    font-size: 14px !important;
}
/* Table controls layout */
.table-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.table-controls .search-bar {
    margin-bottom: 0;
    max-width: 400px;
}
/* Table controls layout */
.table-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.table-controls .search-bar {
    margin-bottom: 0;
    max-width: 400px;
}
/* Modern Modal Styles */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-dialog {
    background: white;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    transform: scale(1);
    transition: all 0.3s ease;
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 24px 30px;
    border-bottom: none;
}

.modal-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.modal-close:hover {
    opacity: 1;
}

.modal-body {
    padding: 30px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 20px 30px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* Modern Form Styles */
.form-group {
    margin-bottom: 24px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #374151;
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
    background: #ffffff;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    background: #ffffff;
}

.form-control:disabled {
    background: #f9fafb;
    color: #9ca3af;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    cursor: pointer;
}

/* Form Buttons */
.btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #e5e7eb;
    color: #374151;
}

.btn-secondary:hover {
    background: #d1d5db;
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

/* Form Validation */
.form-control.is-invalid {
    border-color: #ef4444;
}

.invalid-feedback {
    display: block;
    color: #ef4444;
    font-size: 12px;
    margin-top: 4px;
}

/* Checkbox and Radio Styles */
.form-check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.form-check-input {
    width: 18px;
    height: 18px;
    border: 2px solid #d1d5db;
    border-radius: 4px;
}

.form-check-input:checked {
    background: #667eea;
    border-color: #667eea;
}

.form-check-label {
    font-size: 14px;
    color: #374151;
    cursor: pointer;
}

/* File Upload */
.file-upload {
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    transition: all 0.2s ease;
    cursor: pointer;
}

.file-upload:hover {
    border-color: #667eea;
    background: #f8fafc;
}

.file-upload-icon {
    font-size: 32px;
    color: #9ca3af;
    margin-bottom: 8px;
}

.file-upload-text {
    color: #6b7280;
    font-size: 14px;
}

/* Responsive Modal */
@media (max-width: 768px) {
    .modal-dialog {
        width: 95%;
        margin: 20px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 20px;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
}
/* KYC Section Styles */
.kyc-section {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 2px solid #e2e8f0;
}

.kyc-section h4 {
    color: #2d3748;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.kyc-section h4::before {
    content: "🆔";
    font-size: 18px;
}
/* KYC Image Display */
.kyc-image-display {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    background: #f8fafc;
}

.kyc-document-img {
    max-width: 100%;
    height: auto;
    max-height: 200px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.no-kyc-image {
    padding: 20px;
    text-align: center;
    color: #6b7280;
    background: #f9fafb;
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    font-style: italic;
}
/* Profile Image Display */
.profile-image-display {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    background: #f8fafc;
    text-align: center;
}

.profile-img-modal {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #667eea;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.no-profile-image {
    padding: 20px;
    text-align: center;
    color: #6b7280;
    background: #f9fafb;
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    font-style: italic;
}
/* Image Thumbnails */
.profile-img-thumbnail {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #667eea;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.profile-img-thumbnail:hover {
    transform: scale(1.1);
}

.kyc-document-thumbnail {
    max-width: 120px;
    height: auto;
    max-height: 80px;
    border-radius: 6px;
    cursor: pointer;
    transition: transform 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.kyc-document-thumbnail:hover {
    transform: scale(1.05);
}

/* Image Modal */
.image-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.image-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.full-size-image {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
/* Customer Dialog Layout */
.customer-dialog {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.customer-dialog .mat-dialog-content {
    flex: 1;
    overflow: hidden;
    padding: 0 24px;
}

.dialog-grid {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 25px;
    height: 100%;
}

.left-column {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.right-column {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    font-size: 12px;
    margin-bottom: 4px;
}

.form-control {
    padding: 8px 12px;
    font-size: 13px;
}

textarea.form-control {
    rows: 2;
    min-height: 60px;
}

.right-column .profile-image-display,
.right-column .kyc-image-display {
    text-align: center;
    padding: 10px;
}

.right-column .kyc-section {
    margin-top: 0;
    padding-top: 10px;
    border-top: 1px solid #e2e8f0;
}

.kyc-section h4 {
    font-size: 14px;
    margin-bottom: 10px;
}

@media (max-width: 768px) {
    .dialog-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}
/* Provider Dialog Layout */
.provider-dialog {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.provider-dialog .mat-dialog-content {
    flex: 1;
    overflow: hidden;
    padding: 0 20px;
}

.provider-dialog .form-group {
    margin-bottom: 4px;
}

.provider-dialog .form-group label {
    font-size: 12px;
    margin-bottom: 1px;
}

.provider-dialog .form-control {
    padding: 4px 8px;
    font-size: 13px;
    margin-bottom: 2px;
}

.provider-dialog .row {
    margin-bottom: 2px;
}

.bank-section {
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px solid #e2e8f0;
}

.bank-section h4 {
    font-size: 13px;
    margin-bottom: 6px;
    color: #2d3748;
}

.approval-section {
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px solid #e2e8f0;
}

.kyc-info {
    background: #f8fafc;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    color: #4a5568;
    margin: 0;
    border: 1px solid #e2e8f0;
}