﻿html,
body {
    margin: 0;
    padding: 0;
    direction: rtl;
    text-align: right;
    min-height: 100vh;
    font-family: Tahoma, Arial, sans-serif;
}

/* دکمه بازگشت عمومی */
.back {
    cursor: pointer;
    position: fixed;
    left: 8px;
    bottom: 58px;
    width: 105px;
    min-height: 38px;
    background-color: #dff7ef;
    border: 1px solid #38bdf8;
    color: #0f172a;
    font-size: 15px;
    font-family: Tahoma, Arial, sans-serif;
    border-radius: 10px;
    text-align: center;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(15, 76, 129, 0.16);
}

    .back:hover {
        background-color: #c8f2e3;
    }

/* هدر عمومی پروژه */
.header {
    direction: rtl;
    background-color: #4fc3f7;
    top: 0;
    right: 0;
    left: 0;
    padding: 10px 16px;
    height: 82px;
    width: 100%;
    position: fixed;
    z-index: 55;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.16);
    box-sizing: border-box;
}

/* لوگوهای بالای صفحات قدیمی، اگر در بعضی صفحات باقی مانده باشند */
#flip-box-front,
#flip-box-back {
    position: absolute;
    width: 65px;
    height: 65px;
    perspective: 1000px;
    background-color: transparent;
    transition: transform 0.35s ease;
    transform-style: preserve-3d;
}

/* کارت‌های عمومی، در صورت استفاده در صفحات قدیمی */
.card {
    cursor: pointer;
    background-color: #ffffff;
    border-radius: 18px;
    border: 1px solid rgba(15, 76, 129, 0.12);
    box-shadow: 0 10px 28px rgba(15, 76, 129, 0.12);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    overflow: hidden;
}

    .card:hover {
        transform: translateY(-3px);
        box-shadow: 0 16px 36px rgba(15, 76, 129, 0.18);
        border-color: rgba(14, 165, 233, 0.45);
    }

.card-body {
    text-align: center;
    padding: 14px;
    font-family: Tahoma, Arial, sans-serif;
}

.card-text {
    color: #0f4c81;
    font-size: 18px;
    font-weight: 700;
}

/* فرم‌ها و ورودی‌های عمومی */
.labl {
    color: #0f172a;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 16px;
    font-weight: 600;
}

.inp,
.input_no,
.input_no_admin {
    border: 1px solid #38bdf8;
    background-color: #f0f9ff;
    color: #0f172a;
    border-radius: 10px;
    padding: 10px 12px;
    font-family: Tahoma, Arial, sans-serif;
    outline: none;
}

    .inp:focus,
    .input_no:focus,
    .input_no_admin:focus {
        border-color: #0f9ed5;
        box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.18);
    }

/* دکمه عمومی */
.button {
    cursor: pointer;
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    border: none;
    border-radius: 14px;
    color: #ffffff;
    padding: 10px 18px;
    text-align: center;
    text-decoration: none;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 16px;
    font-weight: 700;
    box-shadow: 0 8px 22px rgba(14, 165, 233, 0.24);
}

    .button:hover {
        filter: brightness(1.04);
    }

/* امضا، اگر صفحه امضا هنوز از signature_pad استفاده کند */
.m-signature-pad--body canvas {
    position: relative;
    left: 0;
    top: 0;
    width: 325px;
    height: 250px;
    border: 2px solid #38bdf8;
    border-radius: 12px;
    background-color: #ffffff;
}

/* فوتر عمومی پروژه */
.footer,
.supervisor-footer {
    z-index: 55;
    position: fixed;
    background-color: #4fc3f7;
    bottom: 0;
    right: 0;
    left: 0;
    width: 100%;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.12);
}

.copyright,
.supervisor-copyright {
    margin: 0;
    padding: 0;
    text-align: center;
    color: #003f5c;
    font-family: Tahoma, Arial, sans-serif;
    font-size: 15px;
    font-weight: 600;
}

/* کادرهای عمومی ورود یا فرم */
.first_input_page,
.first_input,
.admin_pass {
    text-align: center;
    background-color: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(15, 76, 129, 0.12);
    border-radius: 20px;
    width: min(555px, calc(100% - 32px));
    margin: 95px auto 0 auto;
    padding: 24px;
    font-size: 18px;
    font-weight: bold;
    box-shadow: 0 14px 36px rgba(15, 76, 129, 0.12);
    box-sizing: border-box;
}

.generate_icon {
    margin-top: 55px;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

/* سازگاری موبایل */
@media (max-width: 640px) {
    .header {
        height: 74px;
        padding: 8px 12px;
    }

    #flip-box-front,
    #flip-box-back {
        width: 56px;
        height: 56px;
    }

    .back {
        width: 92px;
        font-size: 14px;
        bottom: 56px;
    }

    .first_input_page,
    .first_input,
    .admin_pass {
        width: calc(100% - 24px);
        margin-top: 84px;
        padding: 18px;
        font-size: 16px;
    }

    .footer,
    .supervisor-footer {
        height: 42px;
    }

    .copyright,
    .supervisor-copyright {
        font-size: 13px;
    }
}
