@import url("https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700&display=swap");

:root {
    --primary: #e6b9a6;
    --dark: #2f3645;
    --gray: #939185;
    --light: #eeedeb;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Tajawal", sans-serif;
}

body {
    background-color: #f5f5f5;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-image: radial-gradient(
        circle at 10% 20%,
        rgba(248, 219, 83, 0.1) 0%,
        rgba(248, 219, 83, 0.05) 90%
    );
    overflow-x: hidden;
}

.login-container {
    display: flex;
    width: 900px;
    height: 550px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
    animation: fadeIn 0.8s ease-out;
}

.brand-section {
    flex: 1;
    background: linear-gradient(135deg, var(--primary), var(--dark));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px;
    color: white;
    position: relative;
    overflow: hidden;
}

.brand-section::before {
    content: "";
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: -100px;
    left: -100px;
}

.brand-section::after {
    content: "";
    position: absolute;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    bottom: -50px;
    right: -50px;
}

.logo {
    width: 150px;
    margin-bottom: 30px;
    filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.2));
    animation: float 4s ease-in-out infinite;
}

.brand-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.brand-subtitle {
    font-size: 16px;
    opacity: 0.9;
    text-align: center;
    line-height: 1.6;
}

.login-section {
    flex: 1;
    padding: 60px 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-title {
    color: var(--dark);
    font-size: 24px;
    margin-bottom: 30px;
    position: relative;
    text-align: center;
}

.login-title::after {
    content: "";
    position: absolute;
    width: 50px;
    height: 3px;
    background: var(--primary);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

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

.form-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    transition: all 0.3s;
}

.form-control {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s;
    background-color: #f9f9f9;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(250, 211, 83, 0.2);
}

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

.btn-login {
    background: var(--primary);
    color: var(--dark);
    border: none;
    padding: 15px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
    box-shadow: 0 4px 6px rgba(219, 219, 219, 0.3);
}

.btn-login:hover {
    background: #939185;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(219, 219, 219, 0.3);
}

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

.btn-login i {
    margin-right: 8px;
    transition: transform 0.3s;
}

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

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

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

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .login-container {
        flex-direction: column;
        height: auto;
        width: 90%;
    }

    .brand-section {
        padding: 30px;
    }

    .login-section {
        padding: 40px 30px;
    }
}

.error-message {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }
    20%,
    60% {
        transform: translateX(-5px);
    }
    40%,
    80% {
        transform: translateX(5px);
    }
}

@keyframes pulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(220, 53, 69, 0);
    }
}
