/*
 * Student Dashboard (Template-Style) - SCOPED STYLESHEET
 *
 * IMPORTANT:
 * - These styles are scoped to the student dashboard wrapper to avoid affecting the theme.
 * - This file intentionally avoids global resets (no `* { border: none; }`, no `body { ... }`).
 * - Color palette follows the bundled `syolearning` template (blue/black gradients; no purple gradients).
 */

.student-dashboard-page .syolms-dashboard,
.student-dashboard-page .syolms-dashboard * {
    box-sizing: border-box;
}

.student-dashboard-page .syolms-dashboard {
    font-family: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    background: whitesmoke;
    color: #0f172a;
}

.student-dashboard-page .syolms-dashboard img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ===== Full-bleed (break out of theme content container) =====
 * Works with classic themes AND Block Themes (is-layout-constrained).
 */
.student-dashboard-page.syolms-fullbleed {
    /* overflow-x: clip; */
    /* Override Block Theme constrained layout - Modified to prevent horizontal scrollbar */
    max-width: 100% !important;
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.student-dashboard-page.syolms-fullbleed .syolms-dashboard {
    width: 100%;
    max-width: 100%;
}

/* Override WP Block Theme global padding on parent containers */
.entry-content.has-global-padding > .student-dashboard-page.syolms-fullbleed,
.wp-block-post-content.has-global-padding > .student-dashboard-page.syolms-fullbleed,
[class*="is-layout-constrained"] > .student-dashboard-page.syolms-fullbleed {
    max-width: 100% !important;
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* ===== Desktop layout (template-like) ===== */
.student-dashboard-page .syolms-dashboard .Dashbord-cont {
    width: 100%;
    display: flex;
    gap: 1.5rem;
    flex-wrap: nowrap;
    padding: 2rem 2rem;
    align-items: flex-start;
}

/* Allow wrapping only when space is truly tight */
@media (max-width: 1100px) {
    .student-dashboard-page .syolms-dashboard .Dashbord-cont {
        flex-wrap: wrap;
    }
}

.student-dashboard-page .syolms-dashboard .dashbord-cont-left {
    flex: 0 0 230px;
    width: 230px;
    background: #fff;
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    border-radius: 10px;
}

.student-dashboard-page .syolms-dashboard .logo-size {
    width: 100%;
    /* height: 150px; */
    height: auto;
    max-height: 150px;
    /* object-fit: cover; */
    object-position: center;
    margin: 10px 0 18px;
}

.student-dashboard-page .syolms-dashboard .syolms-sidebar-nav {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.student-dashboard-page .syolms-dashboard .icon-cont {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    text-decoration: none;
    color: #082588;
    background: #fff;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 150ms ease, transform 150ms ease;
}

.student-dashboard-page .syolms-dashboard .icon-cont:hover {
    background: #f6f9ff;
    transform: translateY(1px);
}

.student-dashboard-page .syolms-dashboard .icon-cont.is-active {
    background: #eef6ff;
    box-shadow: inset 0 0 0 1px rgba(46, 157, 255, 0.25);
}

.student-dashboard-page .syolms-dashboard .icon-cont.is-disabled {
    /* opacity: 0.55; */
    cursor: not-allowed;
    pointer-events: none;
    justify-content: space-between;
    align-items: center;
    gap: 0px;
}

.student-dashboard-page .syolms-dashboard .icon-cont p {
    margin: 0;
}

.student-dashboard-page .syolms-dashboard .icon-size {
    width: 18px;
    flex: 0 0 auto;
}

.student-dashboard-page .syolms-dashboard .syolms-coming-soon {
    margin-left: 8px;
    padding: 5px 5px;
    border-radius: 50px;
    font-size: 7px;
    font-weight: 600;
    color: white;
    background-color: #2E9DFF;
}

.student-dashboard-page .syolms-dashboard .logout-cont {
    width: 100%;
    margin-top: 22px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 12px;
    text-decoration: none;
    color: #082588;
    background: #fff;
    font-size: 13px;
    font-weight: 600;
    transition: background 150ms ease;
}

.student-dashboard-page .syolms-dashboard .logout-cont:hover {
    background: #f6f9ff;
}

.student-dashboard-page .syolms-dashboard .logout-icon {
    width: 18px;
}

.student-dashboard-page .syolms-dashboard .dashbord-cont-middle {
    flex: 1 1 0;
    min-width: 300px;
}

.student-dashboard-page .syolms-dashboard .cont-middle-one {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 10px;
}

.student-dashboard-page .syolms-dashboard .syolms-middle-spacer {
    flex: 1;
}

.student-dashboard-page .syolms-dashboard .cont-middle-two {
    width: 100%;
    border-radius: 15px;
    margin-top: 1rem;
    background-image: linear-gradient(rgba(0, 0, 0, 0.8), #082588);
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    overflow: hidden;
}

.student-dashboard-page .syolms-dashboard .middle-cont-two-1 {
    width: 55%;
    padding: 18px 20px;
}

.student-dashboard-page .syolms-dashboard .middle-cont-two-1 a {
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 400;
}

.student-dashboard-page .syolms-dashboard .middle-two-tag{
     margin: 0;
    font-size: 28px;
    font-weight: 300;
    line-height: 1.2;
    color: #fff;
}

.student-dashboard-page .syolms-dashboard #Welc-text {
    margin: 10px 0 6px;
    font-size: 13px;
    font-weight: 600;
    color: #2E9DFF;
}

.student-dashboard-page .syolms-dashboard #Name-text {
    margin: 0;
    font-size: 28px;
    font-weight: 300;
    line-height: 1.2;
    color: #fff;
}

.student-dashboard-page .syolms-dashboard .middle-cont-two-2 {
    width: 45%;
    padding: 0 20px;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.student-dashboard-page .syolms-dashboard .middle-cont-two-2 img {
    width: min(320px, 90%);
    margin: 0;
}

/* Quick stats cards */
.student-dashboard-page .syolms-dashboard .cont-middle-three {
    margin-top: 1.5rem;
}

.student-dashboard-page .syolms-dashboard .cont-middle-three-1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    font-weight: 600;
}

.student-dashboard-page .syolms-dashboard .cont-middle-three-1 p {
    margin: 0;
}

.student-dashboard-page .syolms-dashboard #view-link {
    text-decoration: none;
    color: #0f172a;
    padding: 6px 10px;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.student-dashboard-page .syolms-dashboard .single-flex-cont {
    margin-top: 12px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.student-dashboard-page .syolms-dashboard .middle-cont-three-2 {
    flex: 1 1 220px;
    min-width: 220px;
    /* background: linear-gradient(to bottom right, #082588, #2E9DFF); */
    background-color: var(--syolms-tertiary);

    border-radius: 10px;
    padding: 14px 14px;
    /* color: #fff; */
    transition: box-shadow 150ms ease, transform 150ms ease;
}

p.syolms-stat-value {
    color: var(--syolms-primary);

}

.student-dashboard-page .syolms-dashboard .middle-cont-three-2:hover {
    box-shadow: 0 10px 22px rgba(2, 10, 60, 0.18);
    transform: translateY(-1px);
}

.student-dashboard-page .syolms-dashboard .syolms-stat-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.student-dashboard-page .syolms-dashboard .syolms-stat-value {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
}

.student-dashboard-page .syolms-dashboard .syolms-stat-label {
    margin: 10px 0 0;
    font-size: 12px;
    font-weight: 500;
    opacity: 0.95;
}

.student-dashboard-page .syolms-dashboard .img3-resize {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255,255,255,0.15);
    padding: 6px;
}

/* Right profile column */
.student-dashboard-page .syolms-dashboard .dashbord-cont-right {
    flex: 0 0 280px;
    width: 280px;
    background: #fff;
    padding: 12px;
    border-radius: 10px;
    position: sticky;
    top: 0;
}

.student-dashboard-page .syolms-dashboard .profile-cont {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    background: #fff;
}

.student-dashboard-page .syolms-dashboard .profile-cont img {
    width: 50%;
    border-radius: 50%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.student-dashboard-page .syolms-dashboard .profile-cont h4 {
    margin: 10px 0 0;
    font-size: 15px;
    font-weight: 700;
}

.student-dashboard-page .syolms-dashboard .profile-cont p {
    margin: 0;
    font-size: 13px;
    opacity: 0.8;
}

.student-dashboard-page .syolms-dashboard .btn-two {
    margin-top: 12px;
    width: 100%;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #082588;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border-radius: 999px;
    text-decoration: none;
}

.student-dashboard-page .syolms-dashboard .btn-two:hover {
    background: #0a2ea8;
    color: #fff;
}

.student-dashboard-page .syolms-dashboard .syolms-profile-details {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid #eef2f7;
    display: grid;
    gap: 10px;
}

.student-dashboard-page .syolms-dashboard .syolms-profile-row strong {
    display: block;
    font-size: 12px;
    color: #0f172a;
}

.student-dashboard-page .syolms-dashboard .syolms-profile-row span {
    display: block;
    font-size: 13px;
    color: rgba(15, 23, 42, 0.85);
    margin-top: 2px;
    word-break: break-word;
}

/* Notification bell placement tweaks (notifications CSS handles the component itself) */
.student-dashboard-page .syolms-dashboard .syolms-notification-bell {
    position: relative;
}

/* ===== Grades panel (template-styled) ===== */
.student-dashboard-page .syolms-dashboard .syolms-card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
    overflow: hidden;
    margin-top: 16px;
}

.student-dashboard-page .syolms-dashboard .syolms-card__header {
    padding: 16px 18px;
    border-bottom: 1px solid #eef2f7;
}

.student-dashboard-page .syolms-dashboard .syolms-card__title {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
}

.student-dashboard-page .syolms-dashboard .syolms-card__body {
    padding: 16px 18px 18px;
}

.student-dashboard-page .syolms-dashboard .syolms-grades-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 14px;
    align-items: flex-end;
    margin-bottom: 14px;
}

.student-dashboard-page .syolms-dashboard .syolms-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 180px;
}

.student-dashboard-page .syolms-dashboard .syolms-field label {
    font-size: 12px;
    font-weight: 700;
    color: rgba(15, 23, 42, 0.85);
}

.student-dashboard-page .syolms-dashboard .syolms-field select {
    height: 40px;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    padding: 0 12px;
    font-size: 13px;
    background: #fff;
}

.student-dashboard-page .syolms-dashboard .syolms-btn {
    height: 40px;
    padding: 0 14px;
    border-radius: 12px;
    border: 0;
    background: #082588;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.student-dashboard-page .syolms-dashboard .syolms-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
    border: 1px solid #eef2f7;
}

.student-dashboard-page .syolms-dashboard .syolms-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.student-dashboard-page .syolms-dashboard .syolms-table th,
.student-dashboard-page .syolms-dashboard .syolms-table td {
    padding: 10px 8px;
    border-bottom: 1px solid #eef2f7;
    text-align: left;
    font-size: 13px;
}

/* Ensure Subject column doesn't wrap awkwardly (Desktop Only) */
@media (min-width: 601px) {
    .student-dashboard-page .syolms-dashboard .syolms-table th,
    .student-dashboard-page .syolms-dashboard .syolms-table td {
        vertical-align: middle;
    }

    .student-dashboard-page .syolms-dashboard .syolms-table th:first-child,
    .student-dashboard-page .syolms-dashboard .syolms-table td:first-child {
        white-space: wrap;
        width: 20%;
    }

    /* Prevent wrapping on key numeric columns */
    .student-dashboard-page .syolms-dashboard .syolms-table .syolms-col-score,
    .student-dashboard-page .syolms-dashboard .syolms-table .syolms-col-percent,
    .student-dashboard-page .syolms-dashboard .syolms-table .syolms-col-grade {
        white-space: nowrap;
    }
}

.student-dashboard-page .syolms-dashboard .syolms-table th {
    font-size: 12px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: rgba(15, 23, 42, 0.7);
    background: #fafcff;
}

.student-dashboard-page .syolms-dashboard .syolms-table tr.is-final-grade td {
    background: #f0f6fc;
    font-weight: 700;
}

.student-dashboard-page .syolms-dashboard .syolms-grade-letter {
    display: inline-flex;
    min-width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    background: rgba(8, 37, 136, 0.08);
    color: #082588;
}

.student-dashboard-page .syolms-dashboard .syolms-grade-letter.is-a { background: rgba(0, 163, 42, 0.12); color: #00a32a; }
.student-dashboard-page .syolms-dashboard .syolms-grade-letter.is-b { background: rgba(34, 113, 177, 0.12); color: #2271b1; }
.student-dashboard-page .syolms-dashboard .syolms-grade-letter.is-c { background: rgba(219, 166, 23, 0.14); color: #dba617; }
.student-dashboard-page .syolms-dashboard .syolms-grade-letter.is-d { background: rgba(214, 54, 56, 0.12); color: #d63638; }
.student-dashboard-page .syolms-dashboard .syolms-grade-letter.is-f { background: rgba(214, 54, 56, 0.12); color: #d63638; }

.student-dashboard-page .syolms-dashboard .syolms-comment {
    color: rgba(15, 23, 42, 0.75);
    font-style: italic;
}

.student-dashboard-page .syolms-dashboard .syolms-muted {
    color: rgba(15, 23, 42, 0.4);
}

.student-dashboard-page .syolms-dashboard .syolms-alert {
    padding: 12px 14px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #eef2f7;
}

.student-dashboard-page .syolms-dashboard .syolms-alert--warning {
    background: #fff7ed;
    border-color: #fed7aa;
}

.student-dashboard-page .syolms-dashboard .syolms-alert--error {
    background: #fef2f2;
    border-color: #fecaca;
}

/* ===== Mobile: template-style header + off-canvas menu ===== */
.student-dashboard-page .syolms-dashboard .Mobile-first-cont {
    display: none;
}

.student-dashboard-page .syolms-dashboard .syolms-dashboard-overlay {
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.55);
    z-index: 9998;
}

@media (max-width: 900px) {
    .student-dashboard-page .syolms-dashboard .Dashbord-cont {
        padding: 0 1rem 2rem;
    }

    .student-dashboard-page .syolms-dashboard .Mobile-first-cont {
        width: 100%;
        display: block;
        padding: 0 1rem;
    }

    .student-dashboard-page .syolms-dashboard .Mobile-child-one {
        height: 60px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        position: sticky;
        top: 0;
        background: whitesmoke;
        z-index: 9997;
        padding: 6px 0;
    }

    .student-dashboard-page .syolms-dashboard .syolms-mobile-menu-btn {
        background: transparent;
        border: 0;
        padding: 6px;
        border-radius: 10px;
        cursor: pointer;
    }

    .student-dashboard-page .syolms-dashboard .menu-size {
        width: 30px;
    }

    .student-dashboard-page .syolms-dashboard .syolms-mobile-logo {
        height: 36px;
        width: auto;
        max-width: 150px;
        object-fit: cover;
    }

    .student-dashboard-page .syolms-dashboard .syolms-mobile-avatar img {
        width: 35px;
        height: 35px;
        border-radius: 50%;
        /* object-fit: cover; */
    }

    .student-dashboard-page .syolms-dashboard .Mobile-welcome-Parent-cont {
        margin-top: 10px;
        border-radius: 15px;
        padding: 12px 14px;
        background-image: linear-gradient(rgba(0, 0, 0, 0.8), #082588);
        display: flex;
        justify-content: space-between;
        gap: 10px;
        align-items: center;
    }

    .student-dashboard-page .syolms-dashboard .M-wel-first-child a {
        color: #fff;
        text-decoration: none;
        font-size: 13px;
    }

    .student-dashboard-page .syolms-dashboard #M-Wel-text {
        margin: 10px 0 6px;
        font-size: 14px;
        font-weight: 600;
        color: #2E9DFF;
    }

    .student-dashboard-page .syolms-dashboard #M-Name-text {
        margin: 0;
        font-size: 22px;
        font-weight: 300;
        color: #fff;
    }

    /* Hide right column on mobile */
    .student-dashboard-page .syolms-dashboard .dashbord-cont-right {
        display: none;
    }

    /* Hide the desktop welcome banner to avoid duplication with the mobile header */
    .student-dashboard-page .syolms-dashboard .cont-middle-two {
        display: none;
    }

    /* Off-canvas sidebar */
    .student-dashboard-page .syolms-dashboard .dashbord-cont-left {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        z-index: 9999;
        height: 100vh;
        overflow-y: auto;
        transform: translateX(-110%);
        transition: transform 180ms ease;
        border-radius: 0;
    }

    .student-dashboard-page .syolms-dashboard.is-menu-open .dashbord-cont-left {
        transform: translateX(0);
    }

    .student-dashboard-page .syolms-dashboard.is-menu-open .syolms-dashboard-overlay {
        display: block;
    }

    /* Make middle full width */
    .student-dashboard-page .syolms-dashboard .dashbord-cont-middle {
        width: 100%;
    }

    /* Stack table rows on very small screens */
    @media (max-width: 600px) {
        .student-dashboard-page .syolms-dashboard .syolms-table {
            min-width: 0;
        }

        .student-dashboard-page .syolms-dashboard .syolms-table thead {
            display: none;
        }

        .student-dashboard-page .syolms-dashboard .syolms-table tr {
            display: block;
            border-bottom: 0;
            margin-bottom: 12px;
            border: 1px solid #eef2f7;
            border-radius: 12px;
            overflow: hidden;
        }

        .student-dashboard-page .syolms-dashboard .syolms-table td {
            display: flex;
            justify-content: space-between;
            gap: 12px;
            border-bottom: 1px solid #eef2f7;
        }

        .student-dashboard-page .syolms-dashboard .syolms-table td::before {
            content: attr(data-label);
            font-weight: 800;
            color: rgba(15, 23, 42, 0.7);
        }

        .student-dashboard-page .syolms-dashboard .syolms-table tr.is-final-grade td {
            background: #f0f6fc;
        }

        .student-dashboard-page .syolms-dashboard .syolms-grades-filters {
            justify-content: center;
        }

    }
}

/* Constrained desktop containers (common in WP themes): stack the right card below */
@media (max-width: 1100px) {
    .student-dashboard-page .syolms-dashboard .dashbord-cont-right {
        position: static;
        top: auto;
        width: 100%;
        flex: 1 1 100%;
        order: 3;
    }

    .student-dashboard-page .syolms-dashboard .dashbord-cont-left {
        flex: 0 0 220px;
        width: 220px;
    }

    .student-dashboard-page .syolms-dashboard .dashbord-cont-middle {
        flex: 1 1 0;
        min-width: 280px;
    }
}

/* ===== Timetable Tab ===== */
.student-dashboard-page .syolms-dashboard .syolms-timetable-view {
    background: #fff;
    padding: 20px;
    border-radius: 14px; /* Match card radius */
    box-shadow: 0 1px 6px rgba(0,0,0,0.08); /* Match card shadow */
    margin-top: 16px;
}

.student-dashboard-page .syolms-dashboard .syolms-section-header h3 {
    margin: 0 0 20px;
    font-size: 18px;
    font-weight: 700;
}

.student-dashboard-page .syolms-dashboard .syolms-tabs-nav {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
    display: flex;
    border-bottom: 2px solid #eef2f7;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.student-dashboard-page .syolms-dashboard .syolms-tabs-nav li {
    padding: 10px 20px;
    cursor: pointer;
    font-weight: 600;
    color: rgba(15, 23, 42, 0.6);
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    white-space: nowrap;
    transition: color 0.2s, border-bottom-color 0.2s;
    font-size: 14px;
}

.student-dashboard-page .syolms-dashboard .syolms-tabs-nav li.active {
    color: #082588;
    border-bottom-color: #082588;
}

.student-dashboard-page .syolms-dashboard .syolms-tabs-nav li:hover {
    color: #082588;
}

.student-dashboard-page .syolms-dashboard .syolms-tab-pane {
    display: none;
    animation: fadeIn 0.3s ease;
}

.student-dashboard-page .syolms-dashboard .syolms-tab-pane.active {
    display: block;
}

.student-dashboard-page .syolms-dashboard .syolms-timetable-view .syolms-table {
    width: 100%;
    border-collapse: collapse;
}

.student-dashboard-page .syolms-dashboard .syolms-timetable-view .syolms-table tr.is-break td {
    background: #fdfdfd;
    color: #666;
    font-style: italic;
}

.student-dashboard-page .syolms-dashboard .badge-break {
    display: inline-block;
    background: #eef2f7;
    color: #475569;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    margin-left: 8px;
    font-style: normal;
    font-weight: 600;
    text-transform: uppercase;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}
