/* LWFS Frontend Styles - Enhanced Version */

/* ===== GENERAL STYLES ===== */
.lwfs-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.lwfs-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #0073aa;
    color: white;
}

.lwfs-button:hover {
    background: #005a87;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.lwfs-button-primary {
    background: #0073aa;
}

.lwfs-button-secondary {
    background: #6c757d;
}

.lwfs-button-success {
    background: #28a745;
}

.lwfs-button-danger {
    background: #dc3545;
}

.lwfs-button-small {
    padding: 6px 12px;
    font-size: 12px;
}

/* ===== STUDENT LIST ENHANCED STYLES ===== */
.lwfs-student-list {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}

.lwfs-student-list-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lwfs-student-list-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.lwfs-student-stats {
    display: flex;
    gap: 20px;
}

.stat-item {
    text-align: center;
}

.stat-item strong {
    display: block;
    font-size: 18px;
    font-weight: 700;
}

/* ===== FILTERS SECTION ===== */
.lwfs-filters-section {
    background: #f8f9fa;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

.lwfs-filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.lwfs-filter-group {
    display: flex;
    flex-direction: column;
}

.lwfs-filter-group label {
    font-weight: 500;
    margin-bottom: 5px;
    color: #495057;
}

.lwfs-filter-group input,
.lwfs-filter-group select {
    padding: 8px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
}

.lwfs-filter-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ===== TABLE STYLES ===== */
.lwfs-table-container {
    overflow-x: auto;
}

.lwfs-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.lwfs-table th {
    background: #f8f9fa;
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
    position: sticky;
    top: 0;
    z-index: 10;
}

.lwfs-table td {
    padding: 12px 8px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

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

.lwfs-sortable {
    cursor: pointer;
    position: relative;
}

.lwfs-sortable a {
    color: inherit;
    text-decoration: none;
    display: block;
    padding-right: 20px;
}

.lwfs-sort-asc::after {
    content: '↑';
    position: absolute;
    right: 8px;
    color: #0073aa;
}

.lwfs-sort-desc::after {
    content: '↓';
    position: absolute;
    right: 8px;
    color: #0073aa;
}

/* ===== SERIAL NUMBER STYLES ===== */
.lwfs-serial-number {
    background: #e3f2fd;
    color: #1976d2;
    padding: 4px 8px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-weight: 600;
    font-size: 12px;
}

.lwfs-serial-number.lwfs-missing {
    background: #ffebee;
    color: #d32f2f;
}

/* ===== STATUS BADGES ===== */
.lwfs-status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.lwfs-status-yes {
    background: #e8f5e8;
    color: #2e7d32;
}

.lwfs-status-no {
    background: #ffebee;
    color: #d32f2f;
}

.lwfs-attendance-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.lwfs-attendance-present {
    background: #e8f5e8;
    color: #2e7d32;
}

.lwfs-attendance-absent {
    background: #ffebee;
    color: #d32f2f;
}

.lwfs-attendance-late {
    background: #fff3e0;
    color: #f57c00;
}

.lwfs-class-badge {
    background: #f3e5f5;
    color: #7b1fa2;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 11px;
}

.lwfs-testifier-badge {
    background: #e8f5e8;
    color: #2e7d32;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
}

/* ===== ACTION BUTTONS ===== */
.lwfs-action-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

/* ===== PAGINATION ===== */
.lwfs-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 20px;
    background: #f8f9fa;
}

.lwfs-page-link {
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    background: white;
    color: #0073aa;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.lwfs-page-link:hover {
    background: #0073aa;
    color: white;
    border-color: #0073aa;
}

.lwfs-page-current {
    padding: 8px 12px;
    border: 1px solid #0073aa;
    background: #0073aa;
    color: white;
    border-radius: 4px;
    font-weight: 600;
}

/* ===== NO RESULTS ===== */
.lwfs-no-students,
.lwfs-no-reports {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.lwfs-no-students i,
.lwfs-no-reports i {
    font-size: 48px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.lwfs-no-students h4,
.lwfs-no-reports h4 {
    margin: 0 0 10px 0;
    font-size: 20px;
    font-weight: 600;
}

.lwfs-no-students p,
.lwfs-no-reports p {
    margin: 0 0 20px 0;
    font-size: 16px;
}

/* ===== TEACHER REPORTS STYLES ===== */
.lwfs-teacher-reports {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}

.lwfs-reports-header {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lwfs-reports-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.lwfs-reports-stats {
    display: flex;
    gap: 20px;
}

.lwfs-reports-filters {
    background: #f8f9fa;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

.lwfs-teacher-name,
.lwfs-student-name {
    font-weight: 600;
    color: #495057;
}

/* ===== WEEKLY REPORT FORM STYLES ===== */
.lwfs-weekly-report-form {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}

.lwfs-form-header {
    background: linear-gradient(135deg, #4ecdc4 0%, #44a08d 100%);
    color: white;
    padding: 20px;
    text-align: center;
}

.lwfs-form-header h3 {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: 600;
}

.lwfs-form-header p {
    margin: 0;
    opacity: 0.9;
}

.lwfs-form {
    padding: 20px;
}

.lwfs-form-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #0073aa;
}

.lwfs-form-section h4 {
    margin: 0 0 15px 0;
    color: #495057;
    font-size: 18px;
    font-weight: 600;
}

.lwfs-form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.lwfs-form-group {
    display: flex;
    flex-direction: column;
}

.lwfs-form-group label {
    font-weight: 500;
    margin-bottom: 5px;
    color: #495057;
}

.lwfs-form-group input,
.lwfs-form-group select,
.lwfs-form-group textarea {
    padding: 10px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.lwfs-form-group input:focus,
.lwfs-form-group select:focus,
.lwfs-form-group textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.2);
}

.lwfs-form-submit {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding: 20px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

/* ===== MESSAGE STYLES ===== */
.lwfs-message {
    padding: 15px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.lwfs-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.lwfs-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.lwfs-error-list {
    margin: 10px 0 0 0;
    padding-left: 20px;
}

/* ===== MODAL STYLES ===== */
#report-modal {
    backdrop-filter: blur(5px);
}

#report-modal > div {
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .lwfs-student-list-header,
    .lwfs-reports-header,
    .lwfs-form-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .lwfs-student-stats,
    .lwfs-reports-stats {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .lwfs-filters-grid {
        grid-template-columns: 1fr;
    }
    
    .lwfs-form-row {
        grid-template-columns: 1fr;
    }
    
    .lwfs-filter-actions,
    .lwfs-form-submit {
        flex-direction: column;
    }
    
    .lwfs-table {
        font-size: 12px;
    }
    
    .lwfs-table th,
    .lwfs-table td {
        padding: 8px 4px;
    }
    
    .lwfs-action-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .lwfs-container {
        padding: 10px;
    }
    
    .lwfs-student-list-header h3,
    .lwfs-reports-header h3,
    .lwfs-form-header h3 {
        font-size: 20px;
    }
    
    .lwfs-button {
        padding: 8px 16px;
        font-size: 13px;
    }
} 