
@font-face {
    font-family: 'Vazir';
    src: url('../assets/Vazir-Medium-FD.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* اگر نسخه Bold را هم در فایل‌ها دارید (پیشنهاد می‌شود اضافه کنید) */
@font-face {
    font-family: 'Vazir';
    src: url('../assets/Vazir-Bold-FD.woff') format('woff');
    font-weight: bold;
    font-style: normal;
    font-display: swap;
}

:root {
    --bg-dark: #0a0f1c;
    --glass-bg: rgba(22, 30, 50, 0.55);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    
    --primary: #ff9f1c;
    --primary-glow: rgba(255, 159, 28, 0.3);
    --danger: #ff4d4d;
    --danger-glow: rgba(255, 77, 77, 0.2);
    --success: #2ecc71;
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    
    --radius-card: 24px;
    --radius-pill: 50px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Vazir', Tahoma, sans-serif;
}

/* =========================================================
   2. UTILITIES & BASE CLASSES
   ========================================================= */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: var(--radius-card);
}

.glass-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 14px 24px;
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 15px;
    outline: none;
}

.glass-btn:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-2px);
}

.glass-btn.primary {
    background: var(--primary);
    color: #000;
    font-weight: bold;
    border: none;
    box-shadow: 0 0 20px var(--primary-glow);
}

.glass-btn.primary:hover {
    box-shadow: 0 0 30px var(--primary-glow);
    transform: translateY(-3px);
}

.btn-block {
    width: 100%;
    padding: 16px;
    font-size: 16px;
}

.glass-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 16px 20px 16px 45px;
    border-radius: var(--radius-pill);
    font-size: 16px !important; /* جلوگیری از زوم خودکار کیبورد موبایل */
    outline: none;
    transition: all 0.3s ease;
    touch-action: manipulation;
}

.glass-input:focus {
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 10px var(--primary-glow);
}

.glass-input::placeholder {
    color: #64748b;
}

/* =========================================================
   3. LOGIN PAGE STYLES
   ========================================================= */
html, body.login-body {
    width: 100vw !important;
    max-width: 100% !important;
    overflow-x: hidden !important; 
}

   .login-body {
    background: var(--bg-dark);
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    height: 100dvh !important; 
    min-height: 100vh !important;
    margin: 0 !important;
    padding: 0 20px !important;
    position: relative !important;
    overflow: hidden !important; 
    box-sizing: border-box !important;
}

/* Abstract Background Glows */
.bg-glow {
    position: absolute;
    border-radius: 30%;
    filter: blur(60px);
    z-index: -1;
    opacity: 0.8;
    animation: float 1s infinite ease-in-out alternate;
}

.shape-1 { width: 400px; height: 400px; background: rgba(211, 127, 8, 0.30); top: -100px; right: 0px; }
.shape-2 { width: 300px; height: 300px; background: rgba(52, 152, 219, 0.30); bottom: -50px; left: -50px; animation-delay: -3s; }
.shape-3 { width: 250px; height: 250px; background: rgba(155, 89, 182, 0.25); top: 20%; left: 30%; animation-delay: -5s; }

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(40px, 80px) scale(1.2);}
}

.login-card {
    width: 100%;
    max-width: 420px;
    padding: 40px 35px;
    z-index: 10;
    animation: scaleUp 0.5s ease-out forwards;
}

@keyframes scaleUp {
    from { opacity: 0; transform: scale(0.5); }
    to { opacity: 1; transform: scale(0.8); }
}

.login-header {
    text-align: center;
    margin-bottom: 35px;
}

.logo-container {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px auto;
    background: rgba(0,0,0,0.3);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 2px solid var(--glass-border);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.05);
}

.logo-container img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.login-header h2 {
    color: var(--primary);
    font-size: 24px;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-header p {
    color: var(--text-muted);
    font-size: 14px;
}

.input-group {
    position: relative;
    margin-bottom: 20px;
}

.input-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 16px;
    transition: 0.3s;
    pointer-events: none;
}

.glass-input:focus + .input-icon {
    color: var(--primary);
    stroke: var(--primary);
}

.error-msg {
    background: var(--danger-glow);
    color: var(--danger);
    padding: 12px;
    border-radius: 12px;
    font-size: 13px;
    margin-top: 20px;
    text-align: center;
    display: none;
    border: 1px solid rgba(255, 77, 77, 0.3);
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-5px); }
}

/* استایل اختصاصی ابعاد فرم لاگین در موبایل */
@media (max-width: 600px) {
    .login-card {
        width: 100% !important;
        max-width: 400px !important;
        margin: 0 auto !important; /* تضمین وسط‌چین شدن کادر */
        padding: 30px 20px !important;
        position: relative !important;
        z-index: 10 !important;
        box-sizing: border-box !important;
    }
    
    .logo-container {
        width: 70px !important;
        height: 70px !important;
        margin-bottom: 15px !important;
    }
    
    .logo-container img {
        width: 40px !important;
        height: 40px !important;
    }
    
    .login-header h2 { font-size: 20px !important; }
    .login-header p { font-size: 13px !important; }
    .input-group { margin-bottom: 15px !important; }
    .glass-btn.btn-block { padding: 14px !important; }
}

/* =========================================================
   زیباسازی دکمه پیش‌فرض انتخاب فایل در فرم‌ها
   ========================================================= */
input[type="file"].form-input {
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: 0.3s;
}
input[type="file"].form-input:hover {
    background: rgba(0, 0, 0, 0.4);
    border-color: var(--primary);
}
input[type="file"].form-input::file-selector-button {
    background: var(--primary);
    color: #000;
    border: none;
    padding: 6px 16px;
    border-radius: 16px;
    font-family: inherit;
    font-weight: bold;
    cursor: pointer;
    margin-left: 12px;
    transition: 0.3s ease;
}
input[type="file"].form-input::file-selector-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255, 159, 28, 0.4);
}