/* --- اصلاح فونت‌ها (آدرس‌ها اصلاح شدند) --- */
@font-face { font-family: 'iransans'; src: url('../assets/fonts/Iranian Sans.ttf'); font-display: swap; }
@font-face { font-family: 'byekanbold'; src: url('../assets/fonts/BYekan+ Bold.ttf'); font-display: swap; }
@font-face { font-family: 'Shabnam'; src: url('../assets/fonts/Shabnam.ttf'); font-display: swap; }
@font-face { font-family: 'ShabnamBold'; src: url('../assets/fonts/Shabnam-Bold.ttf'); font-display: swap; }
@font-face { font-family: 'ShabnamLight'; src: url('../assets/fonts/Shabnam-Light.ttf'); font-display: swap; }
@font-face { font-family: 'ShabnamMedium'; src: url('../assets/fonts/Shabnam-Medium.ttf'); font-display: swap; }
@font-face { font-family: 'ShabnamThin'; src: url('../assets/fonts/Shabnam-Thin.ttf'); font-display: swap; }

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: "ShabnamBold", sans-serif;
    height: 100vh;
    overflow: hidden;
    background: #0f2742;
}

.page {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url("../assets/img/login_bg2.png") center center / cover no-repeat;
}

.page::before {
    content: "";
    position: absolute;
    inset: 0;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    background: rgba(32, 64, 100, 0.1);
}

.card {
    position: relative;
    z-index: 2;
    width: 900px;
    height: 500px;
    display: flex;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.25);
    background: #fff;
}

/* --- Login Panel & Form --- */
.login-panel {
    width: 50%;
    background: rgba(255, 255, 255, 0.92);
    padding: 70px 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.login-title {
    font-size: 22px;
    font-weight: 800;
    color: #2f2f2f;
    margin-bottom: 23px;
    font-family: "ShabnamMedium", sans-serif;
}

.form { width: 100%; max-width: 340px; }

/* --- استایل بهینه‌شده فیلدها --- */
.input-group {
    position: relative;
    margin-bottom: 17px;
}

.input-group input {
    font-family: "Shabnam", sans-serif;
    width: 100%;
    padding: 18px 15px; /* کمی پدینگ بیشتر برای ظاهر بهتر */
    border: 1px solid #ccc;
    border-radius: 10px;
    outline: none;
    background: transparent;
    font-size: 15px;
}

.input-group label {
    position: absolute;
    top: 50%;
    right: 15px; /* تنظیم برای RTL */
    transform: translateY(-50%);
    color: #999;
    transition: all 0.2s ease;
    pointer-events: none;
    background: white;
    padding: 0 5px;
    font-size: 14px;
}

/* افکت شناور */
.input-group input:focus + label,
.input-group input:not(:placeholder-shown) + label {
    top: 0;
    font-size: 15px;
    color: #007bff;
}

/* --- آیکون‌ها --- */
.input-group .icon {
    position: absolute;
    left: 15px;
    top: 59%;
    transform: translateY(-50%);
    color: #a5afbb;
    font-size: 18px;
    cursor: pointer;
    z-index: 1;
}

.login-btn {
    width: 100%;
    height: 56px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(180deg, #2b8be7 0%, #2378d0 100%);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s ease;
    font-family: "ShabnamBold", sans-serif;
}

.login-btn:hover { transform: translateY(-1px); filter: brightness(1.03); }

/* --- Brand Panel --- */
.brand-panel {
    width: 50%;
    background: #2583d9;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
}

.brand-logo {
    width: 165px;
    height: 165px;
    object-fit: contain;
    margin-bottom: 22px;
    filter: brightness(0) invert(1);
    animation: logoFloat 3s ease-in-out infinite;
    will-change: transform;
}
@keyframes logoFloat {

    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
    100% {
        transform: translateY(0);
    }
}
.brand-title { font-size: 26px; font-weight: 800; line-height: 1.7; margin: 0; }
.brand-subtitle { font-size: 20px; font-weight: 500; margin: 0; margin-top: 4px; line-height: 1.6; }

.footer {
    position: absolute; bottom: 0; left: 0; right: 0; z-index: 3;
    text-align: center; color: rgba(255,255,255,0.95); font-size: 16px;
    padding: 10px 16px; background: linear-gradient(180deg, rgba(30, 58, 95, 0.35), rgba(30, 58, 95, 0.55));
    font-family: "Shabnam", sans-serif;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: inline-block;
}

/* انیمیشن چرخش */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* وقتی دکمه لودینگ است (غیرفعال شود) */
.login-btn:disabled {
    cursor: not-allowed;
    opacity: 0.8;
}

/* --- Responsive --- */
@media (max-width: 920px) {
    .card { width: 94%; height: auto; flex-direction: column; }
    .login-panel, .brand-panel { width: 100%; }
    .footer { position: static; }
}
.register-link {
    margin-top: 20px;
    font-size: 14px;
    text-align: center;
    font-family: "Shabnam", sans-serif;
    color: #666;
}

.register-link a {
    color: #2b8be7; /* همان آبی دکمه */
    text-decoration: none;
    font-weight: 700;
    transition: 0.3s;
    margin-right: 5px; /* فاصله بین متن و لینک */
}

.register-link a:hover {
    color: #1a5ea3; /* کمی تیره‌تر در حالت هاور */
    text-decoration: underline;
}
