/*
|--------------------------------------------------------------------------
| Student Dashboard Styles (Final)
|--------------------------------------------------------------------------
*/

/* --- Global Dashboard Layout & Reset --- */
body {
    background-color: #F5F7FA;
}

.dashboard-container {
    padding: 50px 0 80px 0;
    font-family: 'Inter', sans-serif !important;
}

/* --- 1. Sidebar Component Styles --- */
.dashboard-sidebar {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    position: sticky;
    top: 100px;
    border: 1px solid rgba(44, 76, 156, 0.08);
    margin-bottom: 30px;
}

.user-profile-section {
    padding: 30px 20px;
    text-align: center;
    background: linear-gradient(135deg, rgba(44, 76, 156, 0.05) 0%, rgba(255, 255, 255, 0) 100%);
    border-bottom: 1px solid #eee;
}

.user-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ffffff;
    box-shadow: 0 5px 15px rgba(44, 76, 156, 0.2);
    margin-bottom: 15px;
}

.user-name {
    font-weight: 700;
    color: #1a2a4a;
    font-size: 1.1rem;
    margin-bottom: 5px;
    font-family: 'Inter', sans-serif;
}

.user-id {
    color: #718096;
    font-size: 0.85rem;
    background: rgba(44, 76, 156, 0.1);
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-block;
    font-family: 'Inter', sans-serif;
}

.dashboard-menu {
    padding: 15px 0;
    list-style: none;
    margin: 0;
}

.dashboard-menu li a {
    display: flex;
    align-items: center;
    padding: 12px 25px;
    color: #5a6c8f;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
}

.dashboard-menu li a i {
    margin-right: 15px;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

.dashboard-menu li a:hover,
.dashboard-menu li a.active {
    background: rgba(44, 76, 156, 0.05);
    color: #2C4C9C;
    border-left-color: #2C4C9C;
}

/* --- 2. Dashboard Content Styles --- */

/* Welcome Banner */
.welcome-banner {
    background: linear-gradient(135deg, #2C4C9C 0%, #1a2a4a 100%);
    border-radius: 16px;
    padding: 30px;
    color: #fff;
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(44, 76, 156, 0.2);
}

.welcome-banner h2 {
    font-weight: 700;
    margin-bottom: 10px;
    position: relative;
    z-index: 2;
    font-size: 1.8rem;
}

.welcome-banner p {
    opacity: 0.9;
    margin-bottom: 0;
    position: relative;
    z-index: 2;
    font-size: 0.95rem;
}

/* General Circle Style */
.banner-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    pointer-events: none;
}
.bc-1 { width: 150px; height: 150px; top: -50px; right: -20px; }
.bc-2 { width: 100px; height: 100px; bottom: -30px; right: 80px; }

/* Stat Cards */
.stat-card {
    background: #fff;
    border-radius: 16px;
    padding: 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform 0.3s ease;
    border: 1px solid rgba(0,0,0,0.02);
    height: 100%;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.icon-blue { background: rgba(44, 76, 156, 0.1); color: #2C4C9C; }
.icon-green { background: rgba(16, 185, 129, 0.1); color: #10B981; }
.icon-purple { background: rgba(139, 92, 246, 0.1); color: #8B5CF6; }
.icon-orange { background: rgba(245, 158, 11, 0.1); color: #F59E0B; }

.stat-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1a2a4a;
    margin: 0;
}

.stat-info p {
    color: #718096;
    margin: 0;
    font-size: 0.9rem;
}

/* General Content Card */
.content-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    margin-top: 30px;
    border: 1px solid rgba(0,0,0,0.02);
}

.card-header-custom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.card-header-custom h4 {
    font-weight: 700;
    color: #1a2a4a;
    margin: 0;
    font-size: 1.1rem;
}

/* Custom Table Styling */
.custom-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 10px;
}

.custom-table thead th {
    border: none;
    color: #718096;
    font-weight: 600;
    padding: 15px;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.custom-table tbody tr {
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
    transition: transform 0.2s;
    border-radius: 10px;
}

.custom-table tbody tr:hover {
    transform: scale(1.01);
    background: #fdfdfd;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.custom-table td {
    padding: 15px;
    vertical-align: middle;
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
    color: #4a5568;
    font-weight: 500;
    font-size: 0.95rem;
}

.custom-table td:first-child {
    border-left: 1px solid #f0f0f0;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

.custom-table td:last-child {
    border-right: 1px solid #f0f0f0;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
}

/* Badge Styles (General Dashboard) */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}
.status-active { background: rgba(16, 185, 129, 0.1); color: #10B981; }
.status-pending { background: rgba(245, 158, 11, 0.1); color: #F59E0B; }

/* Notice Board */
.notice-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px dashed #e2e8f0;
    transition: all 0.3s ease;
}
.notice-item:last-child { border-bottom: none; }
.notice-item:hover { transform: translateX(5px); }

.notice-date {
    text-align: center;
    background: #F5F7FA;
    padding: 10px;
    border-radius: 10px;
    min-width: 70px;
    height: fit-content;
}

.notice-date span {
    display: block;
    font-weight: 700;
    color: #2C4C9C;
    line-height: 1;
    font-size: 1.2rem;
}
.notice-date small { font-size: 11px; color: #718096; font-weight: 600; }

.notice-content h5 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: #2d3748;
}

.notice-content p { font-size: 0.85rem; color: #718096; margin: 0; line-height: 1.5; }


/* --- 3. Profile Settings Form Styles (Refined & Balanced) --- */

.profile-banner-card {
    background: #ffffff;
    border-radius: 20px;
    overflow: visible; /* Allows Avatar to overlap nicely */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
    border: 1px solid rgba(0,0,0,0.02);
}

/* UPDATED: Uses the Dashboard Welcome Banner Gradient & Height */
.banner-cover {
    height: 150px;
    background: linear-gradient(135deg, #2C4C9C 0%, #1a2a4a 100%);
    position: relative;
    border-radius: 20px 20px 0 0;
    overflow: hidden; /* Clips the circles */
}

/* Positioning circles specifically for profile header */
.banner-cover .banner-circle.bc-1 {
    top: -50px;
    right: -20px;
    width: 150px;
    height: 150px;
}

.banner-cover .banner-circle.bc-2 {
    bottom: -30px;
    left: 20px;
    width: 100px;
    height: 100px;
}

/* Content Alignment:
   - margin-top: -85px pulls the avatar halfway up the banner (150px banner, ~140px avatar)
   - creates a perfect "floating" split effect.
*/
.banner-content {
    padding: 0 40px 30px 40px;
    position: relative;
    display: flex;
    align-items: flex-end;
    margin-top: -85px;
    gap: 30px;
    z-index: 5;
}

.avatar-wrapper {
    position: relative;
    flex-shrink: 0;
    z-index: 6;
}

.banner-avatar {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 5px solid #ffffff;
    object-fit: cover;
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    background: #fff;
    position: relative;
}

.camera-icon {
    position: absolute;
    bottom: 10px;
    right: 5px;
    background: #2C4C9C;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #fff;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 3px 8px rgba(0,0,0,0.2);
    z-index: 10;
}
.camera-icon:hover { background: #1a2a4a; transform: scale(1.1); }

/* Text Area */
.user-details {
    padding-bottom: 5px;
    flex-grow: 1;
    z-index: 10;
    padding-top: 90px; /* Pushes text down so it doesn't overlap the blue banner */
}

/* Name and Badge Row */
.name-row {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.user-name-large {
    font-size: 2rem;
    font-weight: 800;
    color: #1a2a4a;
    margin: 0;
    line-height: 1.2;
}

/* The "Pill" Style Badge (Reverted to your preferred look) */
.profile-banner-card .status-badge {
    padding: 5px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    letter-spacing: normal;
    text-transform: capitalize;
    box-shadow: none;
}

.badge-verified {
    background: rgba(16, 185, 129, 0.1) !important;
    color: #10B981 !important;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.badge-unverified {
    background: rgba(239, 68, 68, 0.1) !important;
    color: #EF4444 !important;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Meta Data */
.user-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: #64748b;
    font-size: 0.95rem;
    font-weight: 500;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.program-pill {
    background: #F1F5F9;
    color: #334155;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-block;
    margin-top: 5px;
    border: 1px solid #e2e8f0;
    width: fit-content;
}

/* Form Styling */
.form-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0,0,0,0.02);
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e2e8f0;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2C4C9C;
    margin: 0;
}

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

.form-group label {
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
    font-size: 0.9rem;
    display: block;
}

.form-control {
    border: 1px solid #cbd5e1;
    padding: 12px 16px;
    border-radius: 10px;
    color: #1e293b;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    background-color: #fff;
}

.form-control:focus {
    border-color: #2C4C9C;
    box-shadow: 0 0 0 4px rgba(44, 76, 156, 0.1);
    outline: none;
}

.form-control:disabled, .form-control[readonly] {
    background-color: #f8fafc;
    color: #64748b;
    border-color: #e2e8f0;
    cursor: not-allowed;
}

.btn-update {
    background: #2C4C9C;
    color: white;
    padding: 14px 40px;
    border-radius: 10px;
    font-weight: 600;
    border: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 12px rgba(44, 76, 156, 0.25);
}

.btn-update:hover {
    background: #1e3a8a;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(44, 76, 156, 0.35);
    color: #fff;
}

.btn-update:disabled {
    background: #94a3b8;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

/* --- 4. Responsive Media Queries --- */
@media (max-width: 991px) {
    .stat-card { margin-bottom: 15px; }
    .welcome-banner { margin-top: 0; }
}

@media(max-width: 768px) {
    .banner-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: -60px;
        padding: 0 20px 30px 20px;
        gap: 15px;
    }

    .user-details {
        padding-top: 10px; /* Remove padding top on mobile to let it stack naturally */
    }

    .name-row {
        justify-content: center;
        flex-direction: column;
        gap: 10px;
    }

    .user-name-large { font-size: 1.6rem; }

    .user-meta { align-items: center; }

    .form-card { padding: 25px; }
}
