/* Responsive styles for assign student list page */

/* General responsive improvements */
.filter-title {
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #007bff;
    padding-bottom: 5px;
}

.filter-section {
    margin-bottom: 20px;
}

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

.filter-section label {
    font-weight: 500;
    color: #555;
    margin-bottom: 5px;
}

/* Compact form controls */
.form-control-sm {
    height: calc(1.8rem + 2px);
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    line-height: 1.5;
}

.control-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.25rem;
}

.mb-2 {
    margin-bottom: 0.5rem !important;
}

/* Search functionality styles */
.assign-search-box {
    position: relative;
}

.assign-search-box .form-control {
    border-radius: 0.25rem 0 0 0.25rem;
}

.assign-search-box .input-group-btn {
    display: flex;
}

.assign-search-box .input-group-btn .btn {
    border-radius: 0 0.25rem 0.25rem 0;
    border-left: 0;
}

.assign-search-results-info {
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

.assign-search-results-info i {
    margin-right: 0.25rem;
}

.student-count-display {
    padding-top: 0.25rem;
}

.student-count-display .badge {
    font-size: 0.75em;
    margin-right: 0.25rem;
}

.assign-no-results {
    text-align: center;
    padding: 2rem;
    color: #6c757d;
}

.assign-no-results i {
    color: #dee2e6;
    margin-bottom: 1rem;
}

.assign-no-results p {
    margin-bottom: 0.5rem;
}

.assign-no-results .btn {
    margin-top: 0.5rem;
}

/* Student count display */
.assign-student-count-display {
    padding-top: 0.25rem;
}

.assign-student-count-display .assign-count-badge {
    font-size: 0.75em;
    padding: 0.25em 0.5em;
}

/* Custom badge styles for assign student page */
.assign-count-badge {
    display: inline-block;
    padding: 0.25em 0.5em;
    font-size: 0.75em;
    font-weight: 600;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
    color: #fff;
}

.assign-count-badge-info {
    background-color: #17a2b8;
}

.assign-count-badge-success {
    background-color: #28a745;
}

.assign-count-badge-primary {
    background-color: #007bff;
}

/* Button group improvements */
.assign-btn-group-sm > .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Input group sizing */
.assign-input-group-sm > .form-control {
    height: calc(1.8rem + 2px);
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.assign-input-group-sm > .input-group-addon {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Search section styling */
.assign-search-section {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.assign-student-count-info {
    padding-top: 8px;
}

/* Assign student page specific card improvements */
.assign-student-card {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 1px solid #dee2e6;
    margin-bottom: 20px;
}

.assign-student-card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 12px 15px;
}

.assign-student-card-header h5 {
    margin: 0;
    font-weight: 600;
    color: #333;
}

.assign-student-card-body {
    padding: 15px;
}

/* Table responsive improvements for assign student page */
.assign-table-responsive {
    border-radius: 0.25rem;
}

.assign-table th {
    background-color: #e9ecef;
    font-weight: 600;
    color: #495057;
    border-top: none;
    padding: 12px 8px;
    vertical-align: middle;
}

.assign-table td {
    padding: 10px 8px;
    vertical-align: middle;
}

.assign-table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0,0,0,.02);
}

/* Student info styling */
.student-info strong {
    color: #333;
    font-size: 0.95em;
}

.student-info .small {
    font-size: 0.8em;
    color: #6c757d;
    margin-top: 2px;
}

/* Button improvements */
.btn-lg {
    padding: 12px 24px;
    font-size: 1.1em;
    font-weight: 600;
}

.btn-sm {
    padding: 4px 8px;
    font-size: 0.8em;
}

/* Loading spinner */
.spinner-border {
    width: 1.5rem;
    height: 1.5rem;
}

/* Empty state styling */
.py-4 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
}

.fa-2x {
    font-size: 2em;
}

.mb-2 {
    margin-bottom: 0.5rem !important;
}

.mb-3 {
    margin-bottom: 1rem !important;
}

.mb-4 {
    margin-bottom: 1.5rem !important;
}

.mt-2 {
    margin-top: 0.5rem !important;
}

.mt-3 {
    margin-top: 1rem !important;
}

.ml-1 {
    margin-left: 0.25rem !important;
}

.ml-2 {
    margin-left: 0.5rem !important;
}

/* Mobile specific improvements */
@media (max-width: 767px) {
    .filter-section .col-xs-12 {
        margin-bottom: 10px;
    }
    
    .card-header h5 {
        font-size: 1rem;
    }
    
    .table th,
    .table td {
        padding: 8px 4px;
        font-size: 0.9em;
    }
    
    .btn-block {
        margin-bottom: 10px;
    }
    
    .student-tables-section .col-xs-12 {
        margin-bottom: 20px;
    }
    
    /* Hide less important columns on mobile */
    .hidden-xs {
        display: none !important;
    }
    
    .visible-xs-block {
        display: block !important;
    }
}

/* Tablet specific improvements */
@media (min-width: 768px) and (max-width: 991px) {
    .hidden-sm {
        display: none !important;
    }
    
    .filter-section .col-sm-6 {
        margin-bottom: 15px;
    }
}

/* Desktop improvements */
@media (min-width: 992px) {
    .student-tables-section .col-lg-6 {
        padding-right: 10px;
        padding-left: 10px;
    }
    
    .student-tables-section .col-lg-6:first-child {
        padding-right: 15px;
        padding-left: 15px;
    }
    
    .student-tables-section .col-lg-6:last-child {
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* Prevent text overflow */
.student-info,
.table td,
.table th {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Improve form controls */
.form-control {
    border-radius: 0.25rem;
    border: 1px solid #ced4da;
    padding: 8px 12px;
}

.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
}

/* Input group styling */
.input-group-addon {
    background-color: #e9ecef;
    border: 1px solid #ced4da;
    border-left: none;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    border-radius: 0 0.25rem 0.25rem 0;
}

.input-group .form-control {
    border-right: none;
    border-radius: 0.25rem 0 0 0.25rem;
}

/* Checkbox styling */
.form-check-input {
    margin-top: 0.3rem;
}

/* List styling */
.list-unstyled {
    padding-left: 0;
    list-style: none;
}

.list-unstyled li {
    padding: 1px 0;
}

/* Utility classes */
.text-center {
    text-align: center !important;
}

.text-right {
    text-align: right !important;
}

.text-muted {
    color: #6c757d !important;
}

.small {
    font-size: 0.875em;
}

.p-0 {
    padding: 0 !important;
}

.exam-name-label {
    font-size: 1.2em;
    font-weight: 600;
    color: #333;
}

/* Ensure proper alignment */
.align-items-center {
    align-items: center !important;
}

.d-flex {
    display: flex !important;
}

/* Additional utility classes for assign student page */
.assign-mr-2 {
    margin-right: 0.5rem !important;
}

.assign-ml-1 {
    margin-left: 0.25rem !important;
}

.assign-ml-2 {
    margin-left: 0.5rem !important;
}

.assign-mt-2 {
    margin-top: 0.5rem !important;
}

.assign-mt-3 {
    margin-top: 1rem !important;
}

.assign-mb-0 {
    margin-bottom: 0 !important;
}

.assign-p-0 {
    padding: 0 !important;
}

/* Custom table styling */
.assign-table {
    width: 100%;
    margin-bottom: 1rem;
    color: #212529;
    border-collapse: collapse;
}

.assign-table-bordered {
    border: 1px solid #dee2e6;
}

.assign-table-bordered th,
.assign-table-bordered td {
    border: 1px solid #dee2e6;
}

/* Search box improvements */
.assign-search-box {
    position: relative;
}

.assign-search-box .input-group-btn {
    display: flex;
}

.assign-search-box .input-group-btn .btn {
    border-left: none;
    border-radius: 0;
}

.assign-search-box .input-group-btn .btn:last-child {
    border-top-right-radius: 0.25rem;
    border-bottom-right-radius: 0.25rem;
}

.assign-search-box .input-group-btn .btn:first-child {
    border-right: 1px solid #ced4da;
}

/* Search results styling */
.assign-search-results-info {
    font-size: 0.8em;
    color: #6c757d;
    margin-top: 0.25rem;
}

/* No results styling */
.assign-no-results {
    padding: 2rem 1rem;
    text-align: center;
    color: #6c757d;
}

.assign-no-results i {
    color: #adb5bd;
    margin-bottom: 0.5rem;
}

.assign-no-results p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
}
