
/*
|--------------------------------------------------------------------------
| BASE
|--------------------------------------------------------------------------
*/


/*
|--------------------------------------------------------------------------
| TOP BAR
|--------------------------------------------------------------------------
*/




/*
|--------------------------------------------------------------------------
| CONTAINER
|--------------------------------------------------------------------------
*/

.container {

    width: 100%;

    max-width: 1450px;

    margin:
        20px
        auto;

    padding:
        0 15px;
}


/*
|--------------------------------------------------------------------------
| CARD
|--------------------------------------------------------------------------
*/

.simple-card {

    background: #fff;

    border-radius: 10px;

    padding: 20px;

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


/*
|--------------------------------------------------------------------------
| SEARCH
|--------------------------------------------------------------------------
*/

.page-title {

    margin:
        0 0 8px;

    font-size: 22px;
}

.muted {

    color: #777;

    font-size: 13px;
}

.search-box {

    display: grid;

    grid-template-columns:
        1fr
        1fr
        160px;

    gap: 12px;

    align-items: end;

    margin-top: 20px;
}

.form-group {

    display: flex;

    flex-direction: column;

    gap: 7px;
}

.form-group label {

    font-size: 13px;

    font-weight: bold;
}

.form-group input,
.form-group select {

    height: 42px;

    border:
        1px solid
        #cbd5e1;

    border-radius: 6px;

    padding:
        7px 10px;


}

.search-button {

    height: 42px;

    border: 0;

    border-radius: 6px;

    background: #2563eb;

    color: #fff;

    cursor: pointer;

     
}

.search-button:hover {

    background: #1d4ed8;
}


/*
|--------------------------------------------------------------------------
| ALERT
|--------------------------------------------------------------------------
*/

.alert {

    margin-top: 20px;

    padding:
        12px 15px;

    border-radius: 7px;
}

.alert.error {

    background: #fee2e2;

    color: #991b1b;
}

.alert.info {

    background: #e0f2fe;

    color: #075985;
}


/*
|--------------------------------------------------------------------------
| PRINT BUTTON
|--------------------------------------------------------------------------
*/

.print-area {

    text-align: center;

    margin:
        20px 0;
}

.print-btn {

    height: 42px;

    padding:
        0 25px;

    border: 0;

    border-radius: 6px;

    background: #059669;

    color: #fff;

     

    cursor: pointer;
}


/*
|--------------------------------------------------------------------------
| PAYSLIP
|--------------------------------------------------------------------------
|
| اندازه واقعی A4 Landscape
|
*/

.payslip-wrapper {

    width: 100%;

    overflow-x: auto;

    padding-bottom: 30px;
}

.payslip {

      width: 200mm;
    max-width: 200mm;
    min-height: 0;
    height: auto;
    margin: 0 auto;
    padding: 5mm;
    background: #fff;
    border: 1px solid #999;
    box-shadow:
        0 2px 15px
        rgba(0,0,0,.12);
    color: #000;
    box-sizing: border-box;
}


/*
|--------------------------------------------------------------------------
| REPORT HEADER
|--------------------------------------------------------------------------
*/

.payslip-header {

    width: 100%;

    border:
        1px solid
        #222;

    margin-bottom: 5px;

    text-align: center;
}

.company-name {

    padding: 6px;

    font-size: 16px;

    font-weight: bold;

    border-bottom:
        1px solid
        #222;
}

.report-title {

    padding: 6px;

    font-size: 15px;

    font-weight: bold;
}

.report-period {

    padding: 5px;

    font-size: 12px;
    font-weight: bold;
    border-top:
        1px solid
        #222;
}


/*
|--------------------------------------------------------------------------
| EMPLOYEE INFO
|--------------------------------------------------------------------------
*/

.employee-info {

    display: grid;

    grid-template-columns:
        2fr
        1fr
        1fr
        1fr;

    width: 100%;

    border:
        1px solid
        #222;

    
}

.info-cell {

    min-height: 40px;

    padding:
        4px 7px;

    border-left:
        1px solid
        #222;
}

.info-cell:last-child {

    border-left: 0;
}

.info-label {

    font-size: 14px;

    color: #555;

    margin-bottom: 3px;
}

.info-value {

    font-size: 14;

    font-weight: bold;
}


/*
|--------------------------------------------------------------------------
| THREE COLUMNS
|--------------------------------------------------------------------------
*/

.main-columns {

    display: grid;

    grid-template-columns:
        1fr
        1fr
        1fr;

    gap: 5px;

    width: 100%;

    align-items: start;
}


/*
|--------------------------------------------------------------------------
| COLUMN
|--------------------------------------------------------------------------
*/

.salary-column {

    width: 100%;

    min-width: 0;
}


/*
|--------------------------------------------------------------------------
| TABLE
|--------------------------------------------------------------------------
*/

.salary-table {

    width: 100%;

    border-collapse: collapse;

    table-layout: fixed;

    font-size: 11px;

    margin-bottom: 5px;
	    font-weight: bold;
}

.salary-table th,
.salary-table td {

    border:
        1px solid
        #222;

    padding:
        4px 5px;

    line-height: 1.4;

    vertical-align: middle;
}

.salary-table th {

    background: #e5e7eb;

    text-align: center;

    font-weight: bold;
}

.salary-table .title-col {

    width: 60%;

    text-align: right;

    word-break: break-word;
	    font-size: 13px;
}

.salary-table .amount-col {

    width: 40%;

    text-align: center;

    direction: ltr;

    white-space: nowrap;
	    font-size: 13px;
}


/*
|--------------------------------------------------------------------------
| COLUMN TITLE
|--------------------------------------------------------------------------
*/

.column-title {

    background: #dbe4ef !important;

    text-align: center !important;

    font-size: 10px !important;

    font-weight: bold;
}


/*
|--------------------------------------------------------------------------
| TOTAL
|--------------------------------------------------------------------------
*/

.total-row {

    background: #f3f4f6;

    font-weight: bold;
}


/*
|--------------------------------------------------------------------------
| LEAVE
|--------------------------------------------------------------------------
*/

.leave-section {

    margin-top: 5px;
}

.leave-table {

    width: 100%;

    border-collapse: collapse;

    table-layout: fixed;

    font-size: 8px;
}

.leave-table th,
.leave-table td {

    border:
        1px solid
        #222;

    padding:
        4px 5px;
}

.leave-table th {

    background: #dbe4ef;

    text-align: center;
}

.leave-title {

     

    text-align: right;
}

.leave-value {

    width: 35%;

    text-align: center;
}


/*
|--------------------------------------------------------------------------
| SUMMARY
|--------------------------------------------------------------------------
*/
/*
|--------------------------------------------------------------------------
| SUMMARY
|--------------------------------------------------------------------------
*/

.summary-box {
    margin-top: 6px;
    border: 2px solid #222;
}

.summary-title {
    padding: 5px;
    text-align: center;
    background: #dbe4ef;
    border-bottom: 1px solid #222;
    font-size: 10px;
    font-weight: bold;
}

.summary-grid {
    display: grid;

    /* 3 ستون */
    grid-template-columns: repeat(3, 1fr);

    /* 2 سطر */
    grid-template-rows: repeat(2, 48px);

    width: 100%;
}

.summary-item {
    padding: 4px 5px;
    text-align: center;

    border-left: 1px solid #222;
    border-bottom: 1px solid #222;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.summary-label {
    font-size: 13px;
    color: #555;
    margin-bottom: 5px;
}

.summary-value {
    font-size: 13px;
    font-weight: bold;
    direction: rtl;
}

/* ستون سوم: خالص پرداختی در هر دو سطر */
.summary-item.net-pay {
    grid-column: 3;
    grid-row: 1 / 3;

    border-left: 0;
    border-bottom: 0;
}

/* حذف خط پایین از آخرین آیتم‌های سطر دوم */




/*
|--------------------------------------------------------------------------
| NET PAY SPECIAL
|--------------------------------------------------------------------------
*/

.summary-item.net-pay {

    background: #f1f5f9;
}

.summary-item.net-pay .summary-value {

    font-size: 12px;
}


/*
|--------------------------------------------------------------------------
| SIGNATURE
|--------------------------------------------------------------------------
*/

.signature-area {

    display: grid;

    grid-template-columns:
        1fr
        1fr;

    margin-top: 13px;

    text-align: center;

    font-size: 8px;
}

.signature-box {

    min-height: 35px;
}


/*
|--------------------------------------------------------------------------
| FOOTER
|--------------------------------------------------------------------------
*/

.footer-note {

    margin-top: 6px;

    padding-top: 4px;

    border-top:
        1px solid
        #aaa;

    text-align: center;

    color: #555;

    font-size: 7px;
}


/*
|--------------------------------------------------------------------------
| RESPONSIVE
|--------------------------------------------------------------------------
*/
/*
@media (max-width: 1100px) {

    .main-columns {

        grid-template-columns:
            1fr;
    }

    .summary-grid {

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

    .summary-item {

        border-bottom:
            1px solid
            #222;
    }
}
*/

.summary-box {
    margin-top: 6px;
    border: 2px solid #222;
}

.summary-title {
    padding: 5px;
    text-align: center;
    background: #dbe4ef;
    border-bottom: 1px solid #222;
    font-size: 10px;
    font-weight: bold;
}

.summary-grid {
    display: grid;

    /* سه ستون */
    grid-template-columns: repeat(3, 1fr);

    /* سرتیتر + دو ردیف اطلاعات */
    grid-template-rows:
        24px
        48px
        48px;

    width: 100%;

    /* برای چیدمان فارسی */
    direction: rtl;
}


/* =========================
   سرتیتر ستون‌ها
   ========================= */

.summary-section-title {
    display: flex;
    align-items: center;
    justify-content: center;

    background: #dbe4ef;

    font-size: 12px;
    font-weight: bold;

    border-bottom: 1px solid #222;
}


/* سرتیتر مرخصی */
.leave-title {
    grid-column: 1;
    grid-row: 1;

    border-left: 1px solid #222;
}


/* سرتیتر بیمه */
.insurance-title {
    grid-column: 2;
    grid-row: 1;

    border-left: 1px solid #222;
}


/* =========================
   آیتم‌های اطلاعاتی
   ========================= */

.summary-item {
    padding: 4px 5px;

    text-align: center;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    border-left: 1px solid #222;
}


/* مرخصی استفاده شده */
.leave-used {
    grid-column: 1;
    grid-row: 2;

    border-bottom: 1px solid #222;
}


/* کارکرد موثر */
.insurance-days {
    grid-column: 2;
    grid-row: 2;

    border-bottom: 1px solid #222;
}


/* مانده مرخصی */
.leave-remain {
    grid-column: 1;
    grid-row: 3;
}


/* مزایای مشمول بیمه */
.insurance-benefits {
    grid-column: 2;
    grid-row: 3;
}


/* =========================
   خالص پرداختی
   ========================= */

.summary-item.net-pay {
    grid-column: 3;
    grid-row: 1 / 4;

    background: #f1f5f9;

    border-left: 0;
    border-right: 1px solid #222;
    border-bottom: 0;
}


/* =========================
   متن‌ها
   ========================= */




/* اندازه بزرگ‌تر مبلغ خالص */
.summary-item.net-pay .summary-value {
    font-size: 12px;
}

/*
|--------------------------------------------------------------------------
| PRINT
|--------------------------------------------------------------------------
*/


@page {
    size: A4 portrait;
    margin: 0;
}

@media print {

    @page {
        size: A4 portrait;
        margin: 8mm;
    }

    html,
    body {
        width: 100% !important;
        min-height: 100% !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        background: #fff !important;
        overflow: visible !important;
    }

    body * {
        visibility: hidden;
    }

    .payslip-wrapper,
    .payslip-wrapper * {
        visibility: visible;
    }

    .payslip-wrapper {
        position: static !important;
        width: 100% !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        display: block !important;
    }

    .payslip {
        width: 194mm !important;
        max-width: 194mm !important;
        min-height: 0 !important;
        height: auto !important;
        margin: 5mm auto 0 auto !important;
        padding: 5mm !important;
        border: 1px solid #777 !important;
        box-shadow: none !important;
        background: #fff !important;
        overflow: visible !important;
        box-sizing: border-box !important;
        position: static !important;
        right: auto !important;
        left: auto !important;
        top: auto !important;
    }

    .payslip-header,
    .employee-info,
    .main-columns,
    .leave-section,
     
    .signature-area,
    .footer-note {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    table {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        page-break-inside: auto;
    }

    tr {
        page-break-inside: avoid !important;
        page-break-after: auto !important;
    }

    thead {
        display: table-header-group;
    }

    .main-columns {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        width: 100% !important;
        gap: 2mm !important;
    }

    .salary-column {
        min-width: 0 !important;
        width: 100% !important;
        overflow: hidden !important;
    }

     

    .signature-area {
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    .no-print {
        display: none !important;
    }

    .salary-table th,
    .column-title {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
	
  .summary-grid {
        direction: rtl !important;
    }

    .summary-section-title {
        background: #dbe4ef !important;

        border-left: 1px solid #222 !important;
        border-bottom: 1px solid #222 !important;

        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .summary-title {
        background: #dbe4ef !important;

        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .summary-grid > .net-pay {
        border-left: 0 !important;
        border-right: 1px solid #222 !important;
        border-bottom: 0 !important;
    }
	 
}
*{box-sizing:border-box}body{margin:0;font-family:Vazirmatn,Tahoma,sans-serif;background:#f4f7fb;color:#18212f}a{color:#155eef;text-decoration:none;font-weight:600}
.auth-page{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:24px}.auth-shell{width:min(900px,100%);display:grid;grid-template-columns:42% 58%;background:#fff;border-radius:22px;overflow:hidden;box-shadow:0 18px 60px rgba(31,49,73,.12)}
.brand-panel{padding:55px 38px;color:#fff;background:linear-gradient(145deg,#155eef,#0b3d91);display:flex;flex-direction:column;justify-content:center}.brand-icon{width:64px;height:64px;display:grid;place-items:center;border-radius:18px;background:rgba(255,255,255,.15);font-size:32px;font-weight:800;margin-bottom:25px}.brand-panel h1{margin:0 0 10px;font-size:28px}.brand-panel p{margin:0;opacity:.85;line-height:2}
.form-panel,.simple-card{padding:42px}.form-panel h2,.simple-card h2{margin:0 0 8px;font-size:25px}.muted{color:#718096;margin-top:0}form{margin-top:28px}label{display:block;margin:17px 0 8px;font-weight:600;font-size:14px}
input,select{width:100%;height:50px;border:1px solid #d7deea;border-radius:11px;padding:0 15px;font:inherit;outline:none;background:#fff}input:focus,select:focus{border-color:#155eef;box-shadow:0 0 0 3px rgba(21,94,239,.1)}
button,.button-link{display:inline-flex;align-items:center;justify-content:center;height:51px;padding:0 22px;border:0;border-radius:11px;background:#155eef;color:#fff;font:inherit;font-weight:700;cursor:pointer}.button-link{margin:0}.alert{margin-top:20px;padding:12px 14px;border-radius:10px;font-size:14px}.error{background:#fff0f0;color:#b42318}.success{background:#ecfdf3;color:#067647}.hint{margin-top:18px;padding:12px 14px;border-radius:10px;background:#f5f8ff;color:#526174;font-size:13px}.simple-card{width:min(520px,100%);background:#fff;border-radius:20px;box-shadow:0 18px 60px rgba(31,49,73,.12)}.wide{width:min(1150px,100%)}.actions{text-align:center;margin-top:22px}.topbar{height:70px;background:#fff;border-bottom:1px solid #e6ebf2;display:flex;align-items:center;justify-content:space-between;padding:0 max(24px,calc((100% - 1150px)/2));}.container{width:min(1150px,calc(100% - 32px));margin:32px auto}.card-head{display:flex;align-items:center;justify-content:space-between;gap:15px}table{width:100%;border-collapse:collapse;margin-top:25px;font-size:13px}th,td{padding:12px;border-bottom:1px solid #edf0f5;text-align:right}th{background:#f8fafc}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:20px}
@media(max-width:700px){.auth-shell{grid-template-columns:1fr}.brand-panel{padding:30px}.form-panel,.simple-card{padding:28px 22px}.grid2{grid-template-columns:1fr}.card-head{align-items:flex-start;flex-direction:column}table{display:block;overflow:auto;white-space:nowrap}}


.salary-table{
	margin-top:5px;
}

.company-name {
    padding: 5px 10px;

    font-size: 16px;

    font-weight: bold;

    border-bottom: 1px solid #222;

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 10px;

    min-height: 45px;
}

.company-name img {
    width: 38px;

    height: 38px;

    object-fit: contain;

    display: block;
}

.company-name span {
    display: inline-flex;

    align-items: center;

    line-height: 1.2;
}

 
.net-pay .summary-label,.net-pay .summary-value{
	font-size:22px !important;
	
} 