﻿
/* =========================================================
   DISCIPLINE DASHBOARD
   Modern Colorful — Safe UI Refresh
   ========================================================= */
.discipline-dashboard {
    direction: rtl;
    width: 100%;
    font-family: inherit;
}


/* =========================================================
   HEADER
   ========================================================= */

.discipline-header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 4px 14px 10px 0;
}

    .discipline-header::before {
        content: "";
        position: absolute;
        right: 0;
        top: 2px;
        bottom: 8px;
        width: 4px;
        border-radius: 4px;
        background: #f97316;
    }

.discipline-title {
    margin: 0;
    font-size: 22px;
    line-height: 1.4;
    font-weight: 700;
    color: #172033;
}

.discipline-subtitle {
    margin-top: 4px;
    font-size: 13px;
    line-height: 1.6;
    font-weight: 400;
    color: #64748b;
}


/* =========================================================
   FILTER
   ========================================================= */

.discipline-filter-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 15px 18px;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #ffffff 0%, #fffaf5 100%);
    border: 1px solid #eadfd5;
    border-radius: 13px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, .05);
    overflow: visible;
}

    .discipline-filter-card::before {
        content: "";
        position: absolute;
        right: 0;
        top: 12px;
        bottom: 12px;
        width: 3px;
        border-radius: 3px;
        background: #f97316;
    }

.discipline-date-box {
    display: flex;
    align-items: center;
    gap: 10px;
}

.discipline-date-label {
    font-size: 12px;
    line-height: 1.5;
    font-weight: 600;
    color: #334155;
}


/* =========================================================
   GRID CARD
   ========================================================= */

.discipline-grid-card {
    width: 100%;
    background: #fff;
    border: 1px solid #dce5ef;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 5px 18px rgba(15, 23, 42, .055);
}


/* =========================================================
   DISCIPLINE TABLE
   ========================================================= */

.discipline-table-wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

.discipline-table {
    width: 100%;
    min-width: 720px;
    table-layout: fixed;
    border-collapse: collapse;
    direction: rtl;
}

.discipline-class-column {
    width: 220px;
}

.discipline-total-column {
    width: 130px;
}

.discipline-period-column {
    width: auto;
}

.discipline-table th,
.discipline-table td {
    padding: 10px 14px;
    text-align: right;
    border-bottom: 1px solid #edf1f5;
}

.discipline-table th {
    position: relative;
    background: #fffaf5;
    font-size: 12px;
    line-height: 1.5;
    font-weight: 600;
    color: #475569;
}

    .discipline-table th::after {
        content: "";
        position: absolute;
        right: 14px;
        left: 14px;
        bottom: 0;
        height: 2px;
        border-radius: 2px;
        background: #fed7aa;
    }

.discipline-table td {
    font-size: 13px;
    line-height: 1.6;
    color: #334155;
    vertical-align: middle;
}

.discipline-table tbody tr:last-child td {
    border-bottom: none;
}


/* =========================================================
   CLASS
   ========================================================= */

.discipline-class-name {
    display: block;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 600;
    color: #172033;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.discipline-total-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    font-size: 14px;
    line-height: 1;
    font-weight: 700;
    color: #b42318;
}


/* =========================================================
   PERIOD BUTTON
   ========================================================= */

.discipline-period {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 32px;
    padding: 5px 9px;
    border-radius: 7px;
    border: 1px solid transparent;
    font-size: 11px;
    line-height: 1.3;
    font-weight: 600;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
    -webkit-tap-highlight-color: transparent;
}

    .discipline-period:hover {
        transform: translateY(-1px);
        box-shadow: 0 3px 8px rgba(15, 23, 42, .08);
    }

    .discipline-period:disabled {
        cursor: default;
    }

.discipline-period-no-item {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #15803d;
}

.discipline-period-has-item {
    background: #fef2f2;
    border-color: #fecaca;
    color: #b42318;
}

.discipline-period-empty-cell {
    color: #cbd5e1;
}


/* =========================================================
   MAIN MODAL
   ========================================================= */

.discipline-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.discipline-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .46);
}

.discipline-dialog {
    position: relative;
    z-index: 1;
    width: min(1100px, calc(100vw - 30px));
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .20);
}


/* =========================================================
   MODAL HEADER
   ========================================================= */

.discipline-dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: linear-gradient(135deg, #ffffff 0%, #fffaf5 100%);
    border-bottom: 1px solid #eee4dc;
}

.discipline-popup-title {
    font-size: 17px;
    line-height: 1.5;
    font-weight: 700;
    color: #172033;
}

.discipline-dialog-close,
.discipline-small-close {
    border: 0;
    background: transparent;
    color: #64748b;
    font-size: 24px;
    cursor: pointer;
    transition: color .15s ease, background .15s ease;
    border-radius: 7px;
}

    .discipline-dialog-close:hover,
    .discipline-small-close:hover {
        color: #ea580c;
        background: #fff7ed;
    }


/* =========================================================
   MODAL BODY
   ========================================================= */

.discipline-popup-body {
    padding: 16px;
    overflow-y: auto;
}


/* =========================================================
   SESSION INFO
   ========================================================= */

.discipline-session-info {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 24px;
    padding: 11px 13px;
    margin-bottom: 14px;
    background: #fffaf5;
    border: 1px solid #fed7aa;
    border-radius: 9px;
    font-size: 12px;
    line-height: 1.6;
    color: #334155;
}

.info-label {
    margin-left: 5px;
    font-weight: 600;
    color: #ea580c;
}


/* =========================================================
   TOOLBAR
   ========================================================= */

.discipline-items-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.discipline-items-title {
    font-size: 13px;
    line-height: 1.5;
    font-weight: 600;
    color: #334155;
}


/* =========================================================
   BUTTONS
   ========================================================= */

.discipline-btn-primary,
.discipline-btn-secondary {
    min-height: 36px;
    padding: 7px 16px;
    border-radius: 7px;
    font-size: 12px;
    line-height: 1.4;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

.discipline-btn-primary {
    border: 1px solid #2563eb;
    background: #2563eb;
    color: #fff;
}

    .discipline-btn-primary:hover {
        background: #1d4ed8;
        box-shadow: 0 4px 10px rgba(37, 99, 235, .18);
        transform: translateY(-1px);
    }

.discipline-btn-secondary {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #475569;
}

    .discipline-btn-secondary:hover {
        background: #f8fafc;
        border-color: #cbd5e1;
    }


/* =========================================================
   FORM
   ========================================================= */

.discipline-form-card,
.discipline-review-card {
    padding: 14px;
    margin-bottom: 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.discipline-form-title {
    margin-bottom: 12px;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 600;
    color: #334155;
}

.discipline-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.discipline-form-field {
    margin-bottom: 14px;
}

    .discipline-form-field label {
        display: block;
        margin-bottom: 6px;
        font-size: 12px;
        line-height: 1.5;
        font-weight: 600;
        color: #475569;
    }

.discipline-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
}


/* =========================================================
   REVIEW
   ========================================================= */

.discipline-review-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.discipline-review-info {
    display: grid;
    gap: 7px;
    padding: 10px;
    margin-bottom: 12px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 12px;
    line-height: 1.6;
    color: #334155;
}


/* =========================================================
   TELERIK GRID
   ========================================================= */

.discipline-grid-container {
    width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
}

.discipline-grid {
    direction: rtl;
}

    .discipline-grid .k-grid-header th:last-child,
    .discipline-grid .k-grid-content td:last-child {
        min-width: 200px;
        white-space: nowrap;
    }

    .discipline-grid,
    .discipline-grid .k-grid,
    .discipline-grid .k-grid-header,
    .discipline-grid .k-grid-content {
        direction: rtl !important;
    }


/* =========================================================
   STATUS
   ========================================================= */

.discipline-status-pending,
.discipline-status-reviewed {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 110px;
    min-width: 110px;
    height: 30px;
    padding: 0 8px;
    border-radius: 15px;
    font-size: 11px;
    line-height: 1;
    font-weight: 600;
    white-space: nowrap;
    cursor: default;
    user-select: none;
}

.discipline-status-pending {
    background: #fff7ed;
    color: #c2410c;
    border: 1px solid #fed7aa;
}

.discipline-status-reviewed {
    background: #f0fdf4;
    color: #15803d;
    border: 1px solid #bbf7d0;
}


/* =========================================================
   REVIEW BUTTON
   ========================================================= */

.discipline-review-button {
    min-width: 68px;
    padding: 5px 9px;
    border: 1px solid #93c5fd;
    border-radius: 6px;
    background: #eff6ff;
    color: #2563eb;
    font-size: 11px;
    line-height: 1.4;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background .15s ease, box-shadow .15s ease, transform .15s ease;
}

    .discipline-review-button:hover {
        background: #dbeafe;
        box-shadow: 0 3px 8px rgba(37, 99, 235, .12);
        transform: translateY(-1px);
    }

.discipline-review-done {
    border-color: #86efac;
    background: #f0fdf4;
    color: #15803d;
}

    .discipline-review-done:hover {
        background: #dcfce7;
    }


/* =========================================================
   EMPTY / ERROR / LOADING
   ========================================================= */

.discipline-empty,
.discipline-empty-box {
    padding: 25px 20px;
    text-align: center;
    color: #64748b;
    font-size: 13px;
    line-height: 1.6;
}

.discipline-empty-box {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
}

.discipline-error {
    padding: 10px 12px;
    margin-bottom: 12px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 7px;
    color: #b42318;
    font-size: 12px;
    line-height: 1.6;
}

.discipline-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 160px;
    color: #64748b;
    font-size: 13px;
}


/* =========================================================
   FOOTER
   ========================================================= */

.discipline-popup-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 16px;
    border-top: 1px solid #e2e8f0;
    background: #fff;
}

.discipline-summary {
    font-size: 12px;
    line-height: 1.5;
    color: #64748b;
}

    .discipline-summary strong {
        margin-right: 4px;
        color: #b42318;
    }


/* =========================================================
   GRADE ROW COLORS
   Professional 4-Group Color System
   ========================================================= */

/* ---------- Grades 1–3 : Blue ---------- */

.discipline-table tbody tr.discipline-grade-1 td {
    background: #f5f9ff;
}

.discipline-table tbody tr.discipline-grade-2 td {
    background: #eef5ff;
}

.discipline-table tbody tr.discipline-grade-3 td {
    background: #e7f0ff;
}


/* ---------- Grades 4–6 : Green ---------- */

.discipline-table tbody tr.discipline-grade-4 td {
    background: #f4fbf6;
}

.discipline-table tbody tr.discipline-grade-5 td {
    background: #ecf8f0;
}

.discipline-table tbody tr.discipline-grade-6 td {
    background: #e3f4e9;
}


/* ---------- Grades 7–9 : Orange ---------- */

.discipline-table tbody tr.discipline-grade-7 td {
    background: #fff9f2;
}

.discipline-table tbody tr.discipline-grade-8 td {
    background: #fff2e5;
}

.discipline-table tbody tr.discipline-grade-9 td {
    background: #ffebdd;
}


/* ---------- Grades 10–12 : Purple ---------- */

.discipline-table tbody tr.discipline-grade-10 td {
    background: #f8f5ff;
}

.discipline-table tbody tr.discipline-grade-11 td {
    background: #f1ecff;
}

.discipline-table tbody tr.discipline-grade-12 td {
    background: #eae1ff;
}


/* =========================================================
   PRINT
   ========================================================= */

.discipline-print-option {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    font-weight: 500;
    white-space: nowrap;
}


/* =========================================================
   REVIEW DIALOG
   ========================================================= */

.discipline-review-dialog {
    width: 600px;
    max-width: 90vw;
    max-height: 90vh;
    overflow-y: auto;
}


/* =========================================================
   ADD / EDIT DISCIPLINE MODAL
   ========================================================= */

.discipline-form-modal {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    direction: rtl;
}

.discipline-form-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .48);
}

.discipline-form-dialog {
    position: relative;
    z-index: 10002;
    width: min(700px, calc(100vw - 30px));
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .22);
    overflow: hidden;
    direction: rtl;
}

.discipline-form-body {
    padding: 20px;
    overflow-y: auto;
}


/* =========================================================
   OPERATION BUTTONS
   ========================================================= */

.discipline-operation-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    white-space: nowrap;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 768px) {

    /* -----------------------------------------------------
       HEADER
       ----------------------------------------------------- */

    .discipline-header {
        align-items: flex-start;
        margin-bottom: 12px;
    }

    .discipline-title {
        font-size: 18px;
    }

    .discipline-subtitle {
        font-size: 11px;
    }


    /* -----------------------------------------------------
       FILTER
       ----------------------------------------------------- */

    .discipline-filter-card {
        padding: 10px 12px;
        margin-bottom: 12px;
    }

        .discipline-filter-card::before {
            top: 9px;
            bottom: 9px;
        }

    .discipline-date-box {
        gap: 7px;
    }

    .discipline-date-label {
        font-size: 12px;
    }


    /* -----------------------------------------------------
       MAIN TABLE
       ----------------------------------------------------- */

    .discipline-grid-card {
        width: 100%;
        overflow: hidden;
    }

    .discipline-table-wrapper {
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .discipline-table {
        width: 720px;
        min-width: 720px;
        table-layout: fixed;
    }

    .discipline-class-column {
        width: 115px !important;
        min-width: 115px !important;
        max-width: 115px !important;
    }

    .discipline-total-column {
        width: 100px;
        min-width: 100px;
    }

    .discipline-period-column {
        width: 110px;
        min-width: 110px;
    }

    .discipline-table th,
    .discipline-table td {
        padding: 8px 10px;
        font-size: 11px;
    }

    .discipline-table th {
        font-size: 11px;
        white-space: nowrap;
    }

    .discipline-table td {
        font-size: 11px;
    }


        /* -----------------------------------------------------
       STICKY CLASS COLUMN
       ----------------------------------------------------- */

        .discipline-table th:first-child,
        .discipline-table td:first-child {
            position: sticky;
            right: 0;
            z-index: 5;
            width: 115px !important;
            min-width: 115px !important;
            max-width: 115px !important;
            box-sizing: border-box;
            white-space: nowrap;
        }

    .discipline-table th:first-child {
        background: #fffaf5;
        z-index: 7;
    }

    .discipline-table tbody tr.discipline-grade-1 td:first-child {
        background: #f5f9ff;
    }

    .discipline-table tbody tr.discipline-grade-2 td:first-child {
        background: #eef5ff;
    }

    .discipline-table tbody tr.discipline-grade-3 td:first-child {
        background: #e7f0ff;
    }

    .discipline-table tbody tr.discipline-grade-4 td:first-child {
        background: #f4fbf6;
    }

    .discipline-table tbody tr.discipline-grade-5 td:first-child {
        background: #ecf8f0;
    }

    .discipline-table tbody tr.discipline-grade-6 td:first-child {
        background: #e3f4e9;
    }

    .discipline-table tbody tr.discipline-grade-7 td:first-child {
        background: #fff9f2;
    }

    .discipline-table tbody tr.discipline-grade-8 td:first-child {
        background: #fff2e5;
    }

    .discipline-table tbody tr.discipline-grade-9 td:first-child {
        background: #ffebdd;
    }

    .discipline-table tbody tr.discipline-grade-10 td:first-child {
        background: #f8f5ff;
    }

    .discipline-table tbody tr.discipline-grade-11 td:first-child {
        background: #f1ecff;
    }

    .discipline-table tbody tr.discipline-grade-12 td:first-child {
        background: #eae1ff;
    }


    /* -----------------------------------------------------
       CLASS / TOTAL
       ----------------------------------------------------- */

    .discipline-class-name {
        font-size: 11px;
    }

    .discipline-total-count {
        min-width: 30px;
        font-size: 16px;
    }


    /* -----------------------------------------------------
       PERIOD BUTTONS
       ----------------------------------------------------- */

    .discipline-period {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 42px;
        min-width: 42px;
        height: 32px;
        min-height: 32px;
        padding: 4px 7px;
        border-radius: 7px;
        font-size: 11px;
        font-weight: 600;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

        .discipline-period:disabled {
            cursor: default;
        }


    /* -----------------------------------------------------
       MAIN MODAL
       ----------------------------------------------------- */

    .discipline-modal {
        position: fixed;
        inset: 0;
        padding: 8px;
        align-items: center;
        justify-content: center;
        overflow: hidden;
    }

    .discipline-dialog {
        position: relative;
        width: calc(100vw - 16px);
        max-width: none;
        height: calc(100vh - 16px);
        max-height: calc(100vh - 16px);
        margin: 0;
        border-radius: 10px;
        overflow: hidden;
    }

    .discipline-dialog-header {
        flex: 0 0 auto;
        min-height: 48px;
        padding: 0 12px;
    }

    .discipline-popup-title {
        font-size: 14px;
    }

    .discipline-dialog-close,
    .discipline-small-close {
        font-size: 22px;
    }

    .discipline-popup-body {
        flex: 1 1 auto;
        min-height: 0;
        padding: 10px;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }

    .discipline-popup-footer {
        flex: 0 0 auto;
        min-height: 50px;
        padding: 8px 10px;
    }


    /* -----------------------------------------------------
       SESSION INFO
       ----------------------------------------------------- */

    .discipline-session-info {
        flex-direction: column;
        gap: 7px;
        padding: 9px 10px;
        margin-bottom: 10px;
        font-size: 11px;
    }


    /* -----------------------------------------------------
       TOOLBAR
       ----------------------------------------------------- */

    .discipline-items-toolbar {
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 10px;
    }

    .discipline-items-title {
        font-size: 12px;
    }


    /* -----------------------------------------------------
       TELERIK GRID
       ----------------------------------------------------- */

    .discipline-grid-container {
        width: 100%;
        overflow-x: auto;
        overflow-y: visible;
        -webkit-overflow-scrolling: touch;
    }


    /* -----------------------------------------------------
       FORM MODAL
       ----------------------------------------------------- */

    .discipline-form-modal {
        position: fixed;
        inset: 0;
        padding: 10px;
        align-items: center;
        justify-content: center;
        overflow: hidden;
    }

    .discipline-form-dialog {
        position: relative;
        width: calc(100vw - 20px);
        max-width: none;
        height: auto;
        max-height: calc(100vh - 20px);
        border-radius: 10px;
        overflow: hidden;
    }

    .discipline-form-body {
        padding: 14px;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }


    /* -----------------------------------------------------
       FORM
       ----------------------------------------------------- */

    .discipline-form-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .discipline-form-field {
        margin-bottom: 10px;
    }

    .discipline-form-actions {
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 8px;
    }


    /* -----------------------------------------------------
       BUTTONS
       ----------------------------------------------------- */

    .discipline-btn-primary,
    .discipline-btn-secondary {
        min-height: 34px;
        padding: 6px 12px;
        font-size: 11px;
    }


    /* -----------------------------------------------------
       OPERATION BUTTONS
       ----------------------------------------------------- */

    .discipline-operation-buttons {
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 6px;
    }

    .discipline-review-button {
        min-width: 68px;
        padding: 5px 8px;
        font-size: 10px;
    }


    /* -----------------------------------------------------
       STATUS
       ----------------------------------------------------- */

    .discipline-status-pending,
    .discipline-status-reviewed {
        width: 100px;
        min-width: 100px;
        height: 28px;
        font-size: 10px;
    }


    /* -----------------------------------------------------
       REVIEW DIALOG
       ----------------------------------------------------- */

    .discipline-review-dialog {
        width: calc(100vw - 20px);
        max-width: none;
        max-height: calc(100vh - 20px);
    }
}

/* =========================================================
   DISCIPLINE MODAL & FORM — FINAL POLISH
   ========================================================= */

/* ---------- Modal Header ---------- */

.discipline-dialog-header {
    position: relative;
    min-height: 54px;
    padding: 12px 18px;
    background: linear-gradient(135deg, #ffffff 0%, #fffaf5 100%);
    border-bottom: 1px solid #eee4dc;
}

    .discipline-dialog-header::after {
        content: "";
        position: absolute;
        right: 0;
        left: 0;
        bottom: 0;
        height: 2px;
        background: #f97316;
    }

.discipline-popup-title {
    color: #172033;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -.1px;
}


/* ---------- Close Button ---------- */

.discipline-dialog-close,
.discipline-small-close {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: #64748b;
}

    .discipline-dialog-close:hover,
    .discipline-small-close:hover {
        background: #fff7ed;
        border-color: #fed7aa;
        color: #ea580c;
    }


/* ---------- Session Information ---------- */

.discipline-session-info {
    position: relative;
    padding: 12px 14px;
    background: #fffaf5;
    border: 1px solid #fed7aa;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, .03);
}

    .discipline-session-info .info-label,
    .discipline-review-info .info-label {
        color: #ea580c;
        font-weight: 700;
    }


/* ---------- Form / Review Cards ---------- */

.discipline-form-card,
.discipline-review-card {
    background: #fbfcfe;
    border: 1px solid #e2e8f0;
    border-radius: 11px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, .025);
}

.discipline-form-title {
    position: relative;
    padding-right: 10px;
    color: #172033;
    font-size: 13px;
    font-weight: 700;
}

    .discipline-form-title::before {
        content: "";
        position: absolute;
        right: 0;
        top: 2px;
        bottom: 2px;
        width: 3px;
        border-radius: 3px;
        background: #f97316;
    }


/* ---------- Form Fields ---------- */

.discipline-form-field label {
    margin-bottom: 6px;
    color: #334155;
    font-size: 12px;
    font-weight: 600;
}


/* ---------- Telerik Inputs ---------- */

.discipline-form-field .k-input,
.discipline-form-field .k-picker,
.discipline-form-field .k-dropdownlist,
.discipline-form-field .k-multiselect,
.discipline-form-field textarea,
.discipline-form-field input,
.discipline-form-field select {
    border-radius: 7px;
}


    /* ---------- Focus ---------- */

    .discipline-form-field .k-input:focus,
    .discipline-form-field .k-input.k-focus,
    .discipline-form-field .k-picker:focus,
    .discipline-form-field .k-picker.k-focus,
    .discipline-form-field .k-dropdownlist:focus,
    .discipline-form-field .k-dropdownlist.k-focus,
    .discipline-form-field textarea:focus,
    .discipline-form-field input:focus,
    .discipline-form-field select:focus {
        border-color: #93c5fd;
        box-shadow: 0 0 0 2px rgba(37, 99, 235, .08);
    }


/* ---------- Form Actions ---------- */

.discipline-form-actions {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
}


/* ---------- Primary Button ---------- */

.discipline-btn-primary {
    min-height: 36px;
    padding: 7px 17px;
    border-radius: 7px;
    border: 1px solid #2563eb;
    background: #2563eb;
    color: #fff;
    box-shadow: 0 2px 5px rgba(37, 99, 235, .10);
}

    .discipline-btn-primary:hover {
        background: #1d4ed8;
        box-shadow: 0 4px 10px rgba(37, 99, 235, .16);
    }


/* ---------- Secondary Button ---------- */

.discipline-btn-secondary {
    min-height: 36px;
    padding: 7px 17px;
    border-radius: 7px;
    border: 1px solid #d1d5db;
    background: #fff;
    color: #475569;
}

    .discipline-btn-secondary:hover {
        background: #f8fafc;
        border-color: #cbd5e1;
        color: #334155;
    }


/* ---------- Review Info ---------- */

.discipline-review-info {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 9px;
}


/* ---------- Review Header ---------- */

.discipline-review-header {
    padding-bottom: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid #e2e8f0;
}

    .discipline-review-header .discipline-items-title {
        color: #172033;
        font-weight: 700;
    }


/* ---------- Review Button ---------- */

.discipline-review-button {
    border-radius: 7px;
}

.discipline-review-done {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #15803d;
}


/* ---------- Operation Buttons ---------- */

.discipline-operation-buttons {
    gap: 7px;
}

    .discipline-operation-buttons button {
        transition: transform .15s ease, box-shadow .15s ease;
    }

        .discipline-operation-buttons button:hover {
            transform: translateY(-1px);
        }


/* ---------- Form Modal ---------- */

.discipline-form-dialog {
    border: 1px solid #e2e8f0;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .20);
}


/* ---------- Form Modal Header ---------- */

.discipline-form-modal .discipline-dialog-header {
    background: linear-gradient(135deg, #ffffff 0%, #fffaf5 100%);
}


/* ---------- Footer ---------- */

.discipline-popup-footer {
    background: #fbfcfe;
    border-top: 1px solid #e2e8f0;
}


/* =========================================================
   TELERIK POPUP Z-INDEX FIX
   پاپ‌آپ‌های تلریک (دراپ‌داون و...) به ریشه اپلیکیشن append می‌شوند،
   پس باید همیشه بالاتر از بالاترین مودال سفارشی ما (10002) باشند.
   ========================================================= */

.k-popup,
.k-list-container,
.k-animation-container {
    z-index: 10999 !important;
}


/* =========================================================
   MOBILE POLISH
   ========================================================= */

@media (max-width: 768px) {

    .discipline-dialog-header {
        min-height: 48px;
        padding: 9px 12px;
    }

    .discipline-popup-title {
        font-size: 14px;
    }

    .discipline-dialog-close,
    .discipline-small-close {
        width: 31px;
        height: 31px;
        font-size: 20px;
    }

    .discipline-session-info {
        padding: 9px 10px;
        border-radius: 8px;
    }

    .discipline-form-card,
    .discipline-review-card {
        padding: 11px;
        border-radius: 9px;
    }

    .discipline-form-title {
        font-size: 12px;
    }

    .discipline-form-actions {
        margin-top: 14px;
        padding-top: 11px;
    }

    .discipline-btn-primary,
    .discipline-btn-secondary {
        min-height: 34px;
        padding: 6px 13px;
        border-radius: 7px;
        font-size: 11px;
    }

    .discipline-popup-footer {
        padding: 8px 10px;
    }
}



