﻿/*       Student Profile       */
.modal-overlay {
    display: none; 
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: white;
    padding: 35px;
    border-radius: 12px;
    width: 750px;
    max-width: 90%;
    min-height: 500px;
    position: relative;
    font-family: var(--font);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    animation: fadeIn 0.3s ease-in-out;
}

.modal-body-layout {
    display: flex;
    flex-direction: row;
    gap: 30px;
    margin-bottom: 20px;
}

.modal-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

   
.modal-col:first-child {
     border-right: 1px solid #e2e8f0;
     padding-right: 30px;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #aaa;
}

.close-btn:hover {
     color: #333;
}

.profile-header {
    text-align: center;
    margin-bottom: 20px;
    font-family: var(--font);
}

.profile-avatar {
    font-size: 60px;
    color: var(--red); 
    margin-bottom: 10px;
}

.profile-info-group {
    margin-bottom: 15px;
}

.profile-info-group label {
    font-weight: 600;
    color: #666;
    font-size: 14px;
    font-family: var(--font);
}

.profile-info-group input {
    width: 100%;
    padding: 10px 12px;
    margin-top: 5px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
     font-family: var(--font);
    box-sizing: border-box;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.profile-info-group input:focus {
     border-color: var(--red);
     box-shadow: 0 0 5px rgba(224, 62, 62, 0.2);
     outline: none;
}

.assigned-courses-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
    max-height: 150px;
    overflow-y: auto;
    padding-right: 5px;
}

.assigned-courses-list::-webkit-scrollbar {
    width: 5px;
}
.assigned-courses-list::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 4px;
}

.course-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fcfcfc;
    border: 1px solid #e2e8f0;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.course-card-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.course-card-left i {
    color: #64748b; 
    font-size: 16px;
}

.course-title {
    color: #1e293b; 
    font-weight: 600;
    font-size: 14px;
}

.arrow-icon {
    color: #94a3b8;
    font-size: 14px;
    transition: transform 0.2s ease, color 0.2s ease;
}

.course-card:hover {
    background-color: #fff5f5; 
    border-color: #e03e3e;    
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.course-card:hover .course-title {
    color: #e03e3e; 
}

.course-card:hover .course-card-left i {
    color: #e03e3e;
}

.course-card:hover .arrow-icon {
    color: #e03e3e;
    transform: translateX(4px); 
}

/* Change password form */
.password-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-wrapper input {
    width: 100%;
    padding-right: 40px !important;
}

.password-wrapper .toggle-password {
    position: absolute;
    right: 15px;
    color: #64748b;
    cursor: pointer;
    transition: color 0.2s ease;
}

.password-wrapper .toggle-password:hover {
    color: var(--red); 
}

/* Modal Footer Buttons */
.profile-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.btn-outline-cancel {
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: 1px solid #ccc;
    color: #666 !important;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-family: var(--font);
    transition: background 0.2s;
}

.btn-outline-cancel:hover {
    background: #f5f5f5;
}

.btn-solid-save {
    appearance: none;
    -webkit-appearance: none;
    background: var(--red) !important;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-family: var(--font);
    transition: background 0.2s;
}

.btn-solid-save:hover {
     background: #c02929;
}

/* Smooth entry animation for courses */
@keyframes slideDownFade {
    0% { opacity: 0; transform: translateY(-10px); }
    100% { opacity: 1; transform: translateY(0); }
}


/* Smooth fade-in animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media screen and (max-width: 768px) {
    .modal-content {
        width: 95%;
        padding: 20px;
        margin: 10px;
        max-height: 90vh; 
        overflow-y: auto;
    }

    .modal-body-layout {
        flex-direction: column;
        gap: 40px;
    }

    .modal-col:first-child {
        border-right: none;
        border-bottom: 1px solid #e2e8f0; 
        padding-right: 0;
        padding-bottom: 30px;
    }

    .profile-avatar {
        font-size: 50px;
    }
    
    .profile-header h2 {
        font-size: 1.25rem;
    }

    .profile-footer {
        flex-direction: column; 
        width: 100%;
    }

    .profile-footer button {
        width: 100%;
        margin-bottom: 5px;
    }
}