/* =========================================================
   ESPACES UTILISATEURS
   Parent / Étudiant / Enseignant
========================================================= */


/* =========================================================
   RESET LOCAL
========================================================= */

.user-space,
.user-space * {
    box-sizing: border-box;
}


/* =========================================================
   PAGE
========================================================= */

.user-space {
    min-height: 100vh;

    background: #f4f7fb;

    padding: 30px 20px 60px;

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;

    color: #212529;
}


/* =========================================================
   CONTAINER
========================================================= */

.user-space-container {
    max-width: 1400px;

    margin: 0 auto;
}


/* =========================================================
   HEADER
========================================================= */

.user-space-header {
    background:
        linear-gradient(
            135deg,
            #0d6efd 0%,
            #084298 100%
        );

    color: #fff;

    border-radius: 20px;

    padding: 30px 35px;

    margin-bottom: 25px;

    box-shadow:
        0 10px 30px rgba(13, 110, 253, .20);
}


.user-space-header-content {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 25px;

    flex-wrap: wrap;
}


.user-space-header-left {
    display: flex;

    align-items: center;

    gap: 20px;
}


.user-space-avatar {
    width: 65px;
    height: 65px;

    min-width: 65px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background:
        rgba(255,255,255,.18);

    border:
        1px solid rgba(255,255,255,.30);

    font-size: 28px;
}


.user-space-header h1 {
    margin: 0 0 5px;

    font-size: 28px;

    font-weight: 700;
}


.user-space-header p {
    margin: 0;

    font-size: 15px;

    opacity: .88;
}


.user-space-role {
    display: inline-flex;

    align-items: center;

    gap: 7px;

    padding: 9px 15px;

    border-radius: 30px;

    background:
        rgba(255,255,255,.15);

    border:
        1px solid rgba(255,255,255,.25);

    font-size: 13px;

    font-weight: 600;
}


/* =========================================================
   TITRES DE SECTION
========================================================= */

.user-section-title {
    display: flex;

    align-items: center;

    gap: 10px;

    margin-bottom: 15px;
}


.user-section-title-icon {
    width: 38px;
    height: 38px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background: #eaf2ff;

    color: #0d6efd;
}


.user-section-title h2 {
    margin: 0;

    font-size: 19px;

    font-weight: 700;
}


.user-section-title p {
    margin: 2px 0 0;

    font-size: 13px;

    color: #6c757d;
}


/* =========================================================
   GRILLE INFORMATIONS
========================================================= */

.user-info-grid {
    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 20px;

    margin-bottom: 25px;
}


/* =========================================================
   CARTE
========================================================= */

.user-card {
    background: #fff;

    border:
        1px solid #e9ecef;

    border-radius: 16px;

    box-shadow:
        0 4px 15px rgba(0,0,0,.05);

    overflow: hidden;
}


.user-card-body {
    padding: 22px;
}


/* =========================================================
   TITRE CARTE
========================================================= */

.user-card-heading {
    display: flex;

    align-items: center;

    gap: 10px;

    margin-bottom: 18px;

    font-size: 16px;

    font-weight: 700;
}


.user-card-heading-icon {
    width: 36px;
    height: 36px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #eef5ff;

    color: #0d6efd;
}


/* =========================================================
   INFORMATIONS
========================================================= */

.user-info-row {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 15px;

    padding: 10px 0;

    border-bottom:
        1px solid #f0f1f3;

    font-size: 14px;
}


.user-info-row:last-child {
    border-bottom: none;

    padding-bottom: 0;
}


.user-info-label {
    color: #6c757d;
}


.user-info-value {
    font-weight: 600;

    text-align: right;
}


/* =========================================================
   STATISTIQUE
========================================================= */

.user-stat {
    display: flex;

    align-items: center;

    gap: 15px;
}


.user-stat-icon {
    width: 50px;
    height: 50px;

    min-width: 50px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 13px;

    background: #eaf2ff;

    color: #0d6efd;

    font-size: 21px;
}


.user-stat-number {
    font-size: 25px;

    font-weight: 700;

    line-height: 1;
}


.user-stat-label {
    margin-top: 5px;

    color: #6c757d;

    font-size: 13px;
}


/* =========================================================
   SERVICES
========================================================= */

.user-services {
    display: grid;

    grid-template-columns:
        repeat(4, 1fr);

    gap: 15px;

    margin-bottom: 25px;
}


.user-service {
    display: flex;

    align-items: center;

    gap: 13px;

    padding: 17px;

    background: #fff;

    border:
        1px solid #e9ecef;

    border-radius: 13px;

    text-decoration: none;

    color: #343a40;

    box-shadow:
        0 3px 12px rgba(0,0,0,.04);

    transition:
        all .2s ease;
}


.user-service:hover {
    transform: translateY(-3px);

    border-color: #b6d4fe;

    color: #0d6efd;

    box-shadow:
        0 7px 18px rgba(13,110,253,.10);
}


.user-service-icon {
    width: 42px;
    height: 42px;

    min-width: 42px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 10px;

    background: #eef5ff;

    color: #0d6efd;
}


.user-service-title {
    font-size: 13px;

    font-weight: 700;
}


.user-service-description {
    margin-top: 2px;

    font-size: 11px;

    color: #6c757d;
}


/* =========================================================
   SERVICE DÉSACTIVÉ
========================================================= */

.user-service-disabled {
    cursor: default;

    opacity: .60;
}


.user-service-disabled:hover {
    transform: none;

    color: #343a40;

    border-color: #e9ecef;

    box-shadow:
        0 3px 12px rgba(0,0,0,.04);
}


/* =========================================================
   CARTES DE CONTENU
========================================================= */

.user-content-grid {
    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 20px;

    margin-bottom: 25px;
}


.user-content-card {
    background: #fff;

    border:
        1px solid #e9ecef;

    border-radius: 16px;

    padding: 20px;

    box-shadow:
        0 4px 15px rgba(0,0,0,.05);

    transition:
        all .2s ease;
}


.user-content-card:hover {
    transform: translateY(-3px);

    box-shadow:
        0 8px 20px rgba(0,0,0,.08);
}


/* =========================================================
   EMPLOI DU TEMPS
========================================================= */

.user-timetable-card {
    background: #fff;

    border-radius: 16px;

    overflow: hidden;

    box-shadow:
        0 4px 15px rgba(0,0,0,.06);

    margin-top: 25px;
}


.user-timetable-header {
    padding: 22px 25px;

    border-bottom:
        1px solid #e9ecef;

    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 15px;

    flex-wrap: wrap;
}


.user-timetable-title {
    margin: 0;

    font-size: 19px;

    font-weight: 700;
}


.user-timetable-subtitle {
    margin-top: 4px;

    color: #6c757d;

    font-size: 13px;
}


.user-class-badge {
    display: inline-block;

    padding: 7px 12px;

    background: #eef5ff;

    color: #0d6efd;

    border-radius: 20px;

    font-size: 12px;

    font-weight: 700;
}


/* =========================================================
   WRAPPER TABLEAU
========================================================= */

.user-timetable-wrapper {
    width: 100%;

    overflow-x: auto;
}


/* =========================================================
   TABLEAU
========================================================= */

.user-timetable {
    width: 100%;

    min-width: 1000px;

    border-collapse:
        separate;

    border-spacing: 0;

    margin: 0;
}


.user-timetable th {
    background: #f8f9fa;

    padding: 15px 12px;

    text-align: center;

    font-size: 13px;

    font-weight: 700;

    color: #495057;

    border-bottom:
        1px solid #dee2e6;

    border-right:
        1px solid #e9ecef;
}


.user-timetable th:first-child {
    width: 100px;
}


.user-timetable th:last-child {
    border-right: none;
}


/* =========================================================
   CELLULE HEURE
========================================================= */

.user-time-cell {
    background: #fafbfc;

    padding: 12px 8px;

    text-align: center;

    vertical-align: middle;

    border-right:
        1px solid #e9ecef;

    border-bottom:
        1px solid #e9ecef;
}


.user-time-main {
    display: block;

    font-size: 13px;

    font-weight: 700;

    color: #343a40;
}


.user-time-secondary {
    display: block;

    margin-top: 3px;

    font-size: 11px;

    color: #adb5bd;
}


/* =========================================================
   CELLULE VIDE
========================================================= */

.user-empty-cell {
    height: 80px;

    background: #fff;

    border-right:
        1px solid #f0f1f3;

    border-bottom:
        1px solid #f0f1f3;
}


/* =========================================================
   CELLULE COURS
========================================================= */

.user-course-cell {
    padding: 5px !important;

    vertical-align: top;

    background: #fff;

    border-right:
        1px solid #f0f1f3;

    border-bottom:
        1px solid #f0f1f3;
}


/* =========================================================
   CARTE COURS
========================================================= */

.user-course-card {
    height: 100%;

    min-height: 70px;

    padding: 11px;

    background: #eef6ff;

    border-left:
        4px solid #0d6efd;

    border-radius: 9px;

    box-shadow:
        0 2px 6px rgba(0,0,0,.07);

    transition:
        all .2s ease;
}


.user-course-card:hover {
    transform: translateY(-2px);

    box-shadow:
        0 5px 12px rgba(0,0,0,.12);
}


.user-course-time {
    font-size: 11px;

    color: #6c757d;

    font-weight: 600;

    margin-bottom: 5px;
}


.user-course-name {
    font-size: 13px;

    font-weight: 700;

    color: #212529;

    line-height: 1.35;

    margin-bottom: 7px;
}


.user-course-detail {
    font-size: 11px;

    color: #495057;

    line-height: 1.7;
}


.user-course-detail i {
    width: 14px;

    color: #6c757d;
}


.user-course-type {
    display: inline-block;

    margin-top: 7px;

    padding: 3px 8px;

    border-radius: 12px;

    background: #fff;

    border:
        1px solid #dee2e6;

    font-size: 10px;

    color: #495057;

    font-weight: 600;
}


/* =========================================================
   EMPTY STATE
========================================================= */

.user-empty-state {
    padding: 60px 20px;

    text-align: center;

    color: #6c757d;
}


.user-empty-state-icon {
    width: 60px;
    height: 60px;

    margin:
        0 auto 15px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #f1f3f5;

    color: #adb5bd;

    font-size: 24px;
}


.user-empty-state h5 {
    color: #495057;

    font-weight: 700;
}


/* =========================================================
   BADGES
========================================================= */

.user-badge-success {

    display: inline-flex;

    align-items: center;

    gap: 5px;

    padding: 5px 9px;

    border-radius: 15px;

    background: #d1e7dd;

    color: #146c43;

    font-size: 11px;

    font-weight: 700;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 1100px) {

    .user-info-grid {
        grid-template-columns:
            repeat(2, 1fr);
    }

    .user-services {
        grid-template-columns:
            repeat(2, 1fr);
    }

    .user-content-grid {
        grid-template-columns:
            repeat(2, 1fr);
    }
}


@media (max-width: 700px) {

    .user-space {
        padding:
            15px 10px 40px;
    }


    .user-space-header {
        padding: 23px;

        border-radius: 15px;
    }


    .user-space-header h1 {
        font-size: 23px;
    }


    .user-space-header-left {
        align-items: flex-start;
    }


    .user-space-avatar {
        width: 52px;
        height: 52px;

        min-width: 52px;

        font-size: 21px;
    }


    .user-info-grid,
    .user-services,
    .user-content-grid {
        grid-template-columns:
            1fr;
    }


    .user-card-body {
        padding: 18px;
    }


    .user-timetable {
        min-width: 1000px;
    }
}