﻿/* =========================================================
   فونت
   ========================================================= */
@font-face {
    font-family: 'Vazir';
    src: url('../fonts/Vazir.woff2') format('woff2'), url('../fonts/Vazir.woff') format('woff'), url('../fonts/Vazir.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}


/* =========================================================
   تنظیمات پایه
   ========================================================= */

:root {
    --primary-color: #1b6ec2;
    --primary-dark: #1861ac;
    --primary-light: #f1f9fc;
    --text-color: #333;
    --border-color: #d9e1e8;
    /* MudBlazor */
    --mud-typography-font-family: 'Vazir', sans-serif !important;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    direction: rtl;
    font-family: 'Vazir', sans-serif;
}

body {
    margin: 0;
    padding: 0;
    direction: rtl;
    font-family: 'Vazir', sans-serif !important;
    color: var(--text-color);
    background: linear-gradient( 135deg, #f5f7fa 0%, #e8edf3 100% );
    background-repeat: no-repeat;
    background-size: cover;
    min-height: 100vh;
}


/* =========================================================
   فونت MudBlazor
   ========================================================= */

.mud-typography,
.mud-button,
.mud-input,
.mud-input-control,
.mud-select,
.mud-select-input,
.mud-table,
.mud-table-container,
.mud-chip,
.mud-list,
.mud-list-item,
.mud-snackbar,
.mud-tooltip,
.mud-alert,
.mud-dialog,
.mud-dialog-title,
.mud-dialog-content,
.mud-dialog-actions,
.mud-expansion-panel,
.mud-expansion-panel-header,
.mud-tabs,
.mud-tab,
.mud-stepper,
.mud-step,
.mud-text-field,
.mud-numeric-field {
    font-family: 'Vazir', sans-serif !important;
}


/* =========================================================
   لینک‌ها
   ========================================================= */

a, .btn-link {
    color: #006bb7;
}

a {
    text-decoration: none;
}
    a:hover {
        text-decoration: underline;
    }


/* =========================================================
   دکمه‌های Bootstrap
   ========================================================= */

.btn-primary {
    color: #fff;
    background-color: var(--primary-color);
    border-color: var(--primary-dark);
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.1rem #fff, 0 0 0 0.25rem #258cfb;
}


/* =========================================================
   ساختار کلی صفحه
   ========================================================= */

.page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

    .page main {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    .page .content {
        flex: 1;
        min-height: 0;
        padding: 1rem;
    }


/* =========================================================
   عنوان
   ========================================================= */

.title-box {
    border: 1px solid #555;
    padding: 12px;
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    border-radius: 10px;
    margin: 10px 0;
    background: linear-gradient( 135deg, #00c6ff, #0072ff );
    color: #fff;
    transition: all 0.3s ease;
}


/* =========================================================
   Login
   ========================================================= */

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 1rem;
}

.login-box {
    width: 100%;
    max-width: 400px;
    background: #93bef3;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(250, 106, 46, 0.2);
    text-align: center;
}

.logo-box {
    margin-bottom: 30px;
}

.university-logo {
    width: 120px;
    height: auto;
    margin-bottom: 10px;
}


/* =========================================================
   فرم
   ========================================================= */

.form-group {
    margin-bottom: 20px;
    text-align: right;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    font-family: 'Vazir', sans-serif;
    font-size: 1rem;
    direction: rtl;
}

    .form-control::placeholder {
        font-family: 'Vazir', sans-serif;
    }


/* =========================================================
   دکمه اصلی
   ========================================================= */

.btn-main {
    width: 100%;
    padding: 12px;
    font-family: 'Vazir', sans-serif;
    font-size: 1rem;
    color: #fff;
    background: var(--primary-color);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

    .btn-main:hover {
        background: var(--primary-dark);
    }

    .btn-main:active {
        transform: translateY(1px);
    }


/* =========================================================
   Footer فرم
   ========================================================= */

.form-footer {
    margin-top: 15px;
}

    .form-footer a {
        font-size: 13px;
        text-decoration: none;
    }


/* =========================================================
   جدول MudBlazor
   ========================================================= */

.my-grid-header .mud-table-container table thead th {
    background-color: #1F3A5F !important;
    color: #fff !important;
    font-family: 'Vazir', sans-serif !important;
}

.my-grid-header2 .mud-table-container table thead th {
    background-color: aliceblue !important;
    color: #000 !important;
    font-family: 'Vazir', sans-serif !important;
}


/* =========================================================
   Login Page جدید
   ========================================================= */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: var(--primary-light);
    background-position: center;
    background-repeat: no-repeat;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 121, 167, 0.12);
    border-radius: 16px;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.08);
}


/* =========================================================
   Header
   ========================================================= */

.header-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}


/* =========================================================
   Dialog
   ========================================================= */

.custom-dialog-title {
    background-color: #f0f8fe;
    color: #000;
    font-family: 'Vazir', sans-serif !important;
    font-weight: 400;
    text-align: center;
}

.custom-dialog-content {
    /* محتوای Dialog */
}

.custom-dialog-actions {
    background-color: #f3f6fa;
}


/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 768px) {

    .login-page {
        padding: 15px;
        background-image: none;
    }

    .login-card {
        max-width: 100%;
        border-radius: 12px;
    }

    .login-box {
        padding: 25px 20px;
    }

    .university-logo {
        width: 100px;
    }
}


@media (max-width: 600px) {

    .header-info {
        flex-direction: column;
        text-align: center;
        gap: 5px;
    }

    .page .content {
        padding: 0.75rem;
    }
}

/* =====================================================
   Fix MudBlazor NavLink underline
   ===================================================== */

/*a.mud-nav-link,
a.mud-nav-link:hover,
a.mud-nav-link:focus,
a.mud-nav-link:active,
a.mud-nav-link:visited {
    text-decoration: none !important;
}*/


/* =========================================================
   Dark Navigation Drawer - MudBlazor
   ========================================================= */

/* Drawer */

.app-dark-drawer {
    background-color: #40464b !important;
    color: #ffffff !important;
}


    /* NavMenu */

    .app-dark-drawer .mud-nav-menu {
        background-color: #40464b !important;
        color: #ffffff !important;
    }


    /* =========================================================
   MENU ITEM - NORMAL
   ========================================================= */

    .app-dark-drawer .mud-nav-link {
        background-color: transparent !important;
        color: #ffffff !important;
        border-radius: 6px;
        transition: background-color 0.2s ease, color 0.2s ease;
    }


        /* متن */

        .app-dark-drawer .mud-nav-link .mud-nav-link-text {
            color: #ffffff !important;
        }


        /* آیکون */

        .app-dark-drawer .mud-nav-link .mud-nav-link-icon,
        .app-dark-drawer .mud-nav-link .mud-icon-root {
            color: #ffffff !important;
        }


    /* =========================================================
   HOVER
   ========================================================= */

    .app-dark-drawer .mud-nav-menu .mud-nav-link:hover,
    .app-dark-drawer .mud-nav-menu a.mud-nav-link:hover {
        background-color: #eeeeee !important;
        color: #222222 !important;
    }


        /* متن Hover */

        .app-dark-drawer .mud-nav-menu .mud-nav-link:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-menu a.mud-nav-link:hover .mud-nav-link-text {
            color: #222222 !important;
        }


        /* آیکون Hover */

        .app-dark-drawer .mud-nav-menu .mud-nav-link:hover .mud-nav-link-icon,
        .app-dark-drawer .mud-nav-menu .mud-nav-link:hover .mud-icon-root {
            color: #222222 !important;
        }


    /* =========================================================
   اگر MudNavLink دارای Color="Primary" باشد
   ========================================================= */

    .app-dark-drawer .mud-nav-link.mud-primary-text:hover,
    .app-dark-drawer .mud-nav-link.mud-info-text:hover,
    .app-dark-drawer .mud-nav-link.mud-secondary-text:hover,
    .app-dark-drawer .mud-nav-link.mud-success-text:hover,
    .app-dark-drawer .mud-nav-link.mud-warning-text:hover,
    .app-dark-drawer .mud-nav-link.mud-error-text:hover {
        background-color: #eeeeee !important;
        color: #222222 !important;
    }


        /* متن لینک‌های دارای Color */

        .app-dark-drawer .mud-nav-link.mud-primary-text:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-link.mud-info-text:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-link.mud-secondary-text:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-link.mud-success-text:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-link.mud-warning-text:hover .mud-nav-link-text,
        .app-dark-drawer .mud-nav-link.mud-error-text:hover .mud-nav-link-text {
            color: #222222 !important;
        }


    /* =========================================================
   ACTIVE
   ========================================================= */

    .app-dark-drawer .mud-nav-link.active {
        background-color: #596168 !important;
        color: #ffffff !important;
    }

        .app-dark-drawer .mud-nav-link.active .mud-nav-link-text {
            color: #ffffff !important;
        }

        .app-dark-drawer .mud-nav-link.active .mud-nav-link-icon,
        .app-dark-drawer .mud-nav-link.active .mud-icon-root {
            color: #ffffff !important;
        }


        /* =========================================================
   ACTIVE + HOVER
   ========================================================= */

        .app-dark-drawer .mud-nav-link.active:hover {
            background-color: #eeeeee !important;
            color: #222222 !important;
        }

            .app-dark-drawer .mud-nav-link.active:hover .mud-nav-link-text {
                color: #222222 !important;
            }

            .app-dark-drawer .mud-nav-link.active:hover .mud-nav-link-icon,
            .app-dark-drawer .mud-nav-link.active:hover .mud-icon-root {
                color: #222222 !important;
            }


    /* =========================================================
   NAV GROUP
   ========================================================= */

    .app-dark-drawer .mud-nav-group {
        color: #ffffff !important;
    }


        /* عنوان گروه */

        .app-dark-drawer .mud-nav-group > .mud-nav-link {
            color: #ffffff !important;
        }


            /* عنوان گروه Hover */

            .app-dark-drawer .mud-nav-group > .mud-nav-link:hover {
                background-color: #eeeeee !important;
                color: #222222 !important;
            }

                .app-dark-drawer .mud-nav-group > .mud-nav-link:hover .mud-nav-link-text {
                    color: #222222 !important;
                }

                .app-dark-drawer .mud-nav-group > .mud-nav-link:hover .mud-icon-root {
                    color: #222222 !important;
                }


        /* =========================================================
   GROUP EXPAND ICON
   ========================================================= */

        .app-dark-drawer .mud-nav-group .mud-nav-link-expand-icon {
            color: #ffffff !important;
        }

        .app-dark-drawer .mud-nav-group > .mud-nav-link:hover .mud-nav-link-expand-icon {
            color: #222222 !important;
        }