:root {
    --primary: #087d9a;
    --primary-dark: #065a6e;
    --primary-light: #e6f7fc;
    --secondary: #FEAF39;
    --dark: #0f172a;
    --gray: #64748b;
    --light: #f8fafc;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #087d9a 0%, #0a5c7a 100%);
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.06);
    --shadow-md: 0 10px 40px rgba(0,0,0,0.08);
    --shadow-lg: 0 20px 60px rgba(8, 125, 154, 0.15);
    --radius: 16px;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tajawal', 'Segoe UI', sans-serif;
    background: linear-gradient(160deg, #f0f9ff 0%, #ffffff 40%, #fff8f0 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: -20%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(254, 175, 57, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 8s ease-in-out infinite;
}

body::after {
    content: '';
    position: fixed;
    bottom: -20%;
    left: -10%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(8, 125, 154, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 10s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-30px); }
}

.auth-container {
    width: 100%;
    max-width: 440px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    padding: 3rem 2.5rem;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, 0.8);
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.auth-logo {
    width: 70px;
    height: 70px;
    background: var(--gradient);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    box-shadow: 0 8px 25px rgba(8, 125, 154, 0.35);
}

.auth-header h1 {
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--gray);
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.form-input {
    width: 100%;
    padding: 0.9rem 1.2rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
    color: var(--dark);
    font-family: 'Tajawal', 'Segoe UI', sans-serif;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(8, 125, 154, 0.15);
}

.form-input::placeholder {
    color: #94a3b8;
}

.form-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.form-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border-radius: 5px;
    border: 2px solid #cbd5e1;
    cursor: pointer;
    accent-color: var(--primary);
}

.form-checkbox label {
    font-size: 0.9rem;
    color: var(--gray);
    cursor: pointer;
}

.btn-submit {
    width: 100%;
    padding: 1rem;
    background: var(--gradient);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Tajawal', 'Segoe UI', sans-serif;
    box-shadow: 0 8px 25px rgba(8, 125, 154, 0.35);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(8, 125, 154, 0.5);
}

.btn-submit:active {
    transform: translateY(0);
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition);
}

.auth-footer a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.error-message {
    background: #fef2f2;
    color: #dc2626;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    border: 1px solid #fecaca;
}

.language-switcher {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 10;
}

[dir="rtl"] .language-switcher {
    right: auto;
    left: 2rem;
}

.btn-lang {
    padding: 0.65rem 1.5rem;
    border: 2px solid var(--primary);
    color: var(--primary);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    cursor: pointer;
    font-family: 'Tajawal', 'Segoe UI', sans-serif;
}

.btn-lang:hover {
    background: var(--primary);
    color: white;
    box-shadow: 0 5px 20px rgba(8, 125, 154, 0.3);
}

@media (max-width: 480px) {
    .auth-container {
        padding: 2rem 1.5rem;
    }

    .auth-header h1 {
        font-size: 1.5rem;
    }

    .language-switcher {
        top: 1rem;
        right: 1rem;
    }

    [dir="rtl"] .language-switcher {
        left: 1rem;
    }
}
.password-wrapper {
    position: relative;
}

.password-wrapper .form-input {
    padding-inline-end: 3rem;
}

.toggle-password {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    inset-inline-end: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray);
    transition: var(--transition);
}

.toggle-password:hover {
    color: var(--primary);
}

.eye-icon {
    width: 22px;
    height: 22px;
}