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

:root {
    --primary-color: #ffc107;
    --secondary-color: #28a745;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --gradient-start: #667eea;
    --gradient-end: #764ba2;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Poppins', sans-serif;
    /*background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);*/
    background: #012E67;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

    body.arabic {
        font-family: 'Cairo', sans-serif;
    }

        body.arabic .english-text {
            display: none;
        }

        body.arabic .arabic-text {
            display: inline-block;
        }

    body:not(.arabic) .arabic-text {
        display: none;
    }

    body.arabic {
        direction: rtl;
        text-align: right;
    }

/* Floating Orbs */
.floating-orb {
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.2), rgba(255,255,255,0.05));
    pointer-events: none;
    z-index: 0;
}

.orb-1 {
    top: -100px;
    left: -100px;
    animation: float 20s ease-in-out infinite;
}

.orb-2 {
    bottom: -100px;
    right: -100px;
    width: 400px;
    height: 400px;
    animation: float 25s ease-in-out infinite reverse;
}

.orb-3 {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 500px;
    height: 500px;
    opacity: 0.1;
    animation: pulse 15s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(50px, 50px);
    }

    50% {
        transform: translate(0, 100px);
    }

    75% {
        transform: translate(-50px, 50px);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.1;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.15;
    }
}

/* Main Container */
.login-container {
    width: 100%;
    max-width: 1200px;
    padding: 20px;
    position: relative;
    z-index: 10;
    margin: 0 auto;
}

.login-wrapper {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 30px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    min-height: 600px;
}

/* Left Side - Branding */
.brand-side {
    flex: 1;
    /*background: linear-gradient(135deg, rgba(102, 126, 234, 0.95) 0%, rgba(118, 75, 162, 0.95) 100%);*/
    background: #012E67;
    padding: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
    min-width: 300px;
}

    .brand-side::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,154.7C960,171,1056,181,1152,170.7C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>');
        background-repeat: no-repeat;
        background-position: bottom;
        background-size: cover;
        opacity: 0.2;
    }

.brand-content {
    position: relative;
    z-index: 2;
    color: white;
}

.brand-icon {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 30px;
    backdrop-filter: blur(5px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.brand-content h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.brand-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 30px;
    line-height: 1.6;
}

.brand-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .brand-features li {
        display: flex;
        align-items: center;
        margin-bottom: 15px;
        font-size: 1rem;
    }

        .brand-features li i {
            width: 30px;
            height: 30px;
            background: rgba(255, 255, 255, 0.2);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-right: 15px;
            font-size: 0.9rem;
            color: var(--primary-color);
        }

body.arabic .brand-features li i {
    margin-right: 0;
    margin-left: 15px;
}

/* Right Side - Login Form */
.form-side {
    flex: 1;
    padding: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: white;
    min-width: 350px;
}

.language-switcher {
    position: absolute;
    top: 30px;
    right: 30px;
    z-index: 20;
}

body.arabic .language-switcher {
    right: auto;
    left: 30px;
}

.lang-toggle {
    background: white;
    border: none;
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: 600;
    color: var(--dark-color);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

    .lang-toggle:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(0,0,0,0.15);
        color: var(--gradient-start);
    }

    .lang-toggle i {
        font-size: 1.1rem;
    }

.form-header {
    margin-bottom: 40px;
    text-align: center;
}

    .form-header h2 {
        font-size: 2rem;
        font-weight: 700;
        color: var(--dark-color);
        margin-bottom: 10px;
    }

    .form-header p {
        color: #6c757d;
        font-size: 0.95rem;
    }

        .form-header p a {
            color: var(--gradient-start);
            text-decoration: none;
            font-weight: 600;
        }

            .form-header p a:hover {
                text-decoration: underline;
            }

/* Login Form */
.login-form {
    max-width: 350px;
    margin: 0 auto;
    width: 100%;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

    .form-group label {
        display: block;
        margin-bottom: 8px;
        font-weight: 500;
        color: var(--dark-color);
        font-size: 0.95rem;
    }

.input-wrapper {
    position: relative;
}

    .input-wrapper i {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        left: 15px;
        color: #adb5bd;
        transition: var(--transition);
        font-size: 1.1rem;
    }

body.arabic .input-wrapper i {
    left: auto;
    right: 15px;
}

.input-wrapper .toggle-password {
    left: auto;
    right: 15px;
    cursor: pointer;
    color: #adb5bd;
}

body.arabic .input-wrapper .toggle-password {
    right: auto;
    left: 15px;
}

.input-wrapper .toggle-password:hover {
    color: var(--gradient-start);
}

.form-control {
    width: 100%;
    padding: 15px 45px;
    border: 2px solid #e9ecef;
    border-radius: 15px;
    font-size: 1rem;
    transition: var(--transition);
    background: #f8f9fa;
}

body.arabic .form-control {
    padding: 15px 45px 15px 45px;
}

.form-control:focus {
    outline: none;
    border-color: var(--gradient-start);
    background: white;
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.1);
}

    .form-control:focus + i {
        color: var(--gradient-start);
    }

.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 10px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

    .remember-me input[type="checkbox"] {
        width: 18px;
        height: 18px;
        cursor: pointer;
        accent-color: var(--gradient-start);
    }

    .remember-me span {
        color: #6c757d;
        font-size: 0.95rem;
    }

.forgot-link {
    color: var(--gradient-start);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
}

    .forgot-link:hover {
        text-decoration: underline;
    }

.btn-login {
    width: 100%;
    padding: 15px;
    /*background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);*/
    background: #012E67;
    color: white;
    border: none;
    border-radius: 15px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
    position: relative;
    overflow: hidden;
}

    .btn-login::before {
        content: "";
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.2);
        transform: translate(-50%, -50%);
        transition: width 0.6s, height 0.6s;
    }

    .btn-login:hover::before {
        width: 300px;
        height: 300px;
    }

    .btn-login:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    }

    .btn-login i {
        font-size: 1.2rem;
        transition: var(--transition);
    }

    .btn-login:hover i {
        transform: translateX(5px);
    }

body.arabic .btn-login:hover i {
    transform: translateX(-5px);
}

/* Social Login */
.social-login {
    text-align: center;
    margin-bottom: 25px;
}

    .social-login p {
        color: #6c757d;
        margin-bottom: 15px;
        position: relative;
    }

        .social-login p::before,
        .social-login p::after {
            content: "";
            position: absolute;
            top: 50%;
            width: 30%;
            height: 1px;
            background: #e9ecef;
        }

        .social-login p::before {
            left: 0;
        }

        .social-login p::after {
            right: 0;
        }

body.arabic .social-login p::before {
    left: auto;
    right: 0;
}

body.arabic .social-login p::after {
    right: auto;
    left: 0;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.social-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    color: var(--dark-color);
    text-decoration: none;
    transition: var(--transition);
    border: 2px solid transparent;
}

    .social-icon:hover {
        transform: translateY(-3px);
        border-color: var(--gradient-start);
        background: white;
        box-shadow: 0 5px 15px rgba(102, 126, 234, 0.2);
    }

    .social-icon.google:hover {
        color: #DB4437;
    }

    .social-icon.facebook:hover {
        color: #4267B2;
    }

    .social-icon.twitter:hover {
        color: #1DA1F2;
    }

    .social-icon.linkedin:hover {
        color: #0077b5;
    }

/* Demo Credentials */
.demo-credentials {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    margin-top: 25px;
    border: 2px dashed #e9ecef;
}

    .demo-credentials h6 {
        color: var(--dark-color);
        font-weight: 600;
        margin-bottom: 15px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

        .demo-credentials h6 i {
            color: var(--gradient-start);
        }

.credential-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 0.95rem;
    color: #6c757d;
}

    .credential-item:last-child {
        margin-bottom: 0;
    }

    .credential-item i {
        width: 20px;
        color: var(--gradient-start);
    }

    .credential-item span {
        font-weight: 600;
        color: var(--dark-color);
        margin-left: 5px;
    }

body.arabic .credential-item span {
    margin-left: 0;
    margin-right: 5px;
}

.copy-btn {
    background: none;
    border: none;
    color: var(--gradient-start);
    cursor: pointer;
    font-size: 0.9rem;
    margin-left: 10px;
    transition: var(--transition);
}

    .copy-btn:hover {
        color: var(--gradient-end);
    }

/* Alert Messages */
.alert-message {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 15px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideDown 0.5s ease;
}

    .alert-message.error {
        background: #f8d7da;
        color: #721c24;
    }

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .login-wrapper {
        flex-direction: column;
        min-height: auto;
    }

    .brand-side {
        padding: 40px 30px;
        text-align: center;
    }

    .brand-icon {
        margin: 0 auto 30px;
    }

    .brand-features li {
        justify-content: center;
    }

    .form-side {
        padding: 40px 30px;
    }

    .language-switcher {
        top: 20px;
        right: 20px;
    }

    body.arabic .language-switcher {
        right: auto;
        left: 20px;
    }

    .orb-1, .orb-2, .orb-3 {
        display: none;
    }
}

@media (max-width: 480px) {
    .form-side {
        padding: 30px 20px;
    }

    .brand-side {
        padding: 30px 20px;
    }

    .form-header h2 {
        font-size: 1.8rem;
    }

    .social-icons {
        gap: 10px;
    }

    .social-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* Loading State */
.btn-login.loading {
    pointer-events: none;
    opacity: 0.8;
}

    .btn-login.loading i {
        animation: spin 1s linear infinite;
    }

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* RTL Specific Adjustments */
body.arabic .form-options {
    flex-direction: row-reverse;
}

body.arabic .remember-me {
    flex-direction: row-reverse;
}

body.arabic .social-icons {
    flex-direction: row-reverse;
}

