/* Custom Table and Pagination Styles */
.table-wrapper {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 20px;
}

.table-header {
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    background: #f8f9fa;
}

.search-box {
    width: 300px;
}

.per-page-selector {
    width: 130px;
}

.table-container {
    height: 400px;
    overflow-y: hidden;
    overflow-x: auto;
    position: relative;
}

.table-container::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.table-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Horizontal scrollbar styling */
.table-container::-webkit-scrollbar:horizontal {
    height: 8px;
}

.table-container::-webkit-scrollbar-track:horizontal {
    background: #f1f1f1;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:horizontal {
    background: #c1c1c1;
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:horizontal:hover {
    background: #a8a8a8;
}

.table-container table {
    margin-bottom: 0 !important;
}

.table-container thead {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    height: 50px;
}

.table-container thead th {
    white-space: nowrap;
    min-width: 120px;
}

.table-footer {
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
}

/* Custom Pagination Styles */
.pagination-container {
    background: transparent;
    border-top: none;
    padding: 15px 20px;
    margin-top: 0;
}

.pagination-info {
    font-size: 0.875rem;
    color: #6c757d;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-controls .btn {
    border-radius: 6px;
    font-size: 0.875rem;
    padding: 6px 12px;
    min-width: 40px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.pagination-controls .btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.pagination-controls .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-controls .btn-primary {
    background-color: #007bff;
    border-color: #007bff;
}

.pagination-controls .btn-outline-primary {
    color: #007bff;
    border-color: #007bff;
}

.pagination-controls .btn-outline-primary:hover {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.pagination-controls .btn-outline-secondary {
    color: #6c757d;
    border-color: #6c757d;
}

.pagination-controls .btn-outline-secondary:hover {
    background-color: #6c757d;
    border-color: #6c757d;
    color: white;
}

.pagination-ellipsis {
    color: #6c757d;
    font-weight: bold;
    padding: 0 8px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .table-header {
        padding: 15px;
    }
    
    .search-box {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .per-page-selector {
        width: 100%;
    }
    
    .table-header .d-flex {
        flex-direction: column;
        gap: 10px;
    }
    
    .table-container {
        height: 300px;
        overflow-x: auto;
    }
    
    .table-container tbody {
        height: 250px;
    }
    
    .table-container thead th {
        min-width: 100px;
    }
    
    .pagination-container {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .pagination-controls {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .pagination-controls .btn {
        font-size: 0.8rem;
        padding: 4px 8px;
        min-width: 36px;
        height: 32px;
    }
}

/* Additional improvements */
.table-container tbody {
    height: 350px;
    overflow-y: hidden;
}

.table-container tbody tr:last-child td {
    border-bottom: none;
}

.table-container tbody tr:hover {
    background-color: #f8f9fa;
}

.table-container .table {
    border-collapse: separate;
    border-spacing: 0;
    min-width: 100%;
    width: max-content;
}

.table-container .table td,
.table-container .table th {
    border-top: 1px solid #dee2e6;
    padding: 8px 15px;
    vertical-align: middle;
    white-space: nowrap;
    height: 45px;
}

.table-container .table th {
    font-weight: 600;
    color: #495057;
    background: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    height: 50px;
} 