/* --- TEACHER PORTAL SPECIFIC STYLES --- */

/* style.css - Professional Dashboard Theme */
:root {
    --primary: #4a90e2;
    --success: #2ecc71;
    --warning: #f1c40f;
    --danger: #e74c3c;
    --dark: #2c3e50;
    --light: #ecf0f1;
    --bg: #f4f6f9;
}

body {
    font-family: 'Segoe UI', 'Roboto', Helvetica, Arial, sans-serif;
    background-color: var(--bg);
    margin: 0;
    padding: 0;
    color: #333;
}

.container {
    max-width: 900px;
    margin: 40px auto;
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
}

/* Auth Screens */
.hidden { display: none !important; }
h2 { color: var(--dark); margin-top: 0; }
input, select, textarea {
    width: 100%; padding: 12px; margin: 8px 0;
    border: 1px solid #ddd; border-radius: 6px;
    font-size: 14px; box-sizing: border-box;
    transition: border 0.3s;
}
input:focus, textarea:focus { border-color: var(--primary); outline: none; }
button {
    background-color: var(--primary); color: white;
    padding: 12px 20px; border: none; border-radius: 6px;
    cursor: pointer; font-size: 15px; font-weight: 600;
    transition: background 0.2s;
}
button:hover { background-color: #357abd; }

/* --- DASHBOARD HEADER & STATS --- */
.dashboard-header {
    display: flex; justify-content: space-between; align-items: center;
    border-bottom: 2px solid #f0f0f0; padding-bottom: 20px; margin-bottom: 25px;
}
.profile-info h1 { font-size: 24px; margin: 0; color: var(--dark); }
.profile-badges span {
    background: #e1e8ed; color: #555; padding: 4px 10px;
    border-radius: 20px; font-size: 12px; font-weight: bold; margin-right: 5px;
}

.stats-container {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 30px;
}
.stat-card {
    background: white; padding: 20px; border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); text-align: center;
    border-top: 4px solid #ccc;
}
.stat-card h3 { margin: 0; font-size: 32px; color: var(--dark); }
.stat-card p { margin: 5px 0 0; color: #777; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; }

.stat-total { border-color: var(--primary); }
.stat-total h3 { color: var(--primary); }

.stat-pending { border-color: var(--warning); }
.stat-pending h3 { color: var(--warning); }

.stat-done { border-color: var(--success); }
.stat-done h3 { color: var(--success); }

/* --- TASK CARDS --- */
.task-card {
    background: white; border-radius: 8px; padding: 20px;
    margin-bottom: 20px; border: 1px solid #e1e1e1;
    position: relative; transition: transform 0.2s;
}
.task-card:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0,0,0,0.05); }

.task-card.completed { border-left: 5px solid var(--success); background: #f9fff9; }
.task-card.overdue { border-left: 5px solid var(--danger); background: #fff5f5; }
.task-card.pending { border-left: 5px solid var(--warning); }

.task-header { display: flex; justify-content: space-between; margin-bottom: 10px; }
.task-title { font-size: 18px; font-weight: bold; color: var(--dark); }
.task-deadline { font-size: 13px; color: #666; background: #eee; padding: 3px 8px; border-radius: 4px; }

.status-tag {
    position: absolute; top: 20px; right: 20px;
    font-size: 12px; font-weight: bold; padding: 4px 8px; border-radius: 4px;
}
.tag-done { background: #d4edda; color: #155724; }
.tag-pending { background: #fff3cd; color: #856404; }
.tag-overdue { background: #f8d7da; color: #721c24; }

/* Update Section */
.update-section {
    margin-top: 15px; padding-top: 15px; border-top: 1px dashed #ddd;
}
.update-box textarea { background: #fcfcfc; font-size: 13px; height: 60px; }
.last-update { font-size: 12px; color: #888; margin-bottom: 5px; display: block; }


/* Login Centering */
.login-wrapper {
    display: flex; justify-content: center; align-items: center; height: 80vh;
}
.login-box {
    width: 100%; max-width: 400px; padding: 40px; text-align: center;
}

/* Header */
.admin-navbar {
    background: white; padding: 15px 30px; display: flex; justify-content: space-between; align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05); margin-bottom: 30px; border-radius: 8px;
}
.admin-brand { font-size: 20px; font-weight: bold; color: var(--primary); display: flex; align-items: center; gap: 10px; }

/* Student Grid Layout */
.student-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px;
}

.student-card-item {
    background: white; padding: 20px; border-radius: 10px; border: 1px solid #eee;
    transition: transform 0.2s, box-shadow 0.2s; cursor: pointer; position: relative; overflow: hidden;
}
.student-card-item:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.08); border-color: var(--primary); }
.student-card-item::before {
    content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 100%; background: var(--primary);
}
.student-name { font-size: 18px; font-weight: bold; color: var(--dark); margin-bottom: 5px; }
.student-detail { font-size: 13px; color: #777; margin-bottom: 15px; }
.view-btn { width: 100%; background: #eef2f7; color: var(--primary); font-weight: bold; }
.view-btn:hover { background: var(--primary); color: white; }

/* Action Panel (Split View) */
.split-view { display: flex; gap: 30px; }
.sidebar-info { flex: 1; background: white; padding: 20px; border-radius: 10px; height: fit-content; }
.main-tasks-area { flex: 3; }

/* Task Items in Teacher View */
.teacher-task-card {
    background: white; border-radius: 8px; padding: 20px; margin-bottom: 15px;
    border-left: 5px solid #ccc; box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.teacher-task-card.completed { border-left-color: var(--success); }
.teacher-task-card.pending { border-left-color: var(--warning); }

/* Grading Controls */
.grading-area {
    background: #f8f9fa; padding: 15px; border-radius: 6px; margin-top: 15px;
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.grading-area input { width: 70px; margin: 0; text-align: center; font-weight: bold; }

/* Student Note Highlight */
.student-update-box {
    background: #e3f2fd; border: 1px solid #bbdefb; padding: 12px; border-radius: 6px; margin: 10px 0;
}