@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    height: 100vh;
    width: 100%;
    overflow-x: hidden;
    background-color: #f7f9fc;
}

.main-container {
    display: flex;
    height: 100vh;
    width: 100%;
}

/* Left Side - Image/Brand Area */
.visual-side {
    flex: 1.2;
    position: relative;
    background-image: url('../Image/Img01.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 60px;
    color: white;
}

.visual-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.8) 0%, rgba(5, 150, 105, 0.9) 100%);
    z-index: 1;
}

.visual-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
}

.visual-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    text-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.visual-content p {
    font-size: 1.1rem;
    font-weight: 300;
    opacity: 0.9;
    line-height: 1.6;
}

/* Right Side - Form Area */
.form-side {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    padding: 40px;
    position: relative;
}

.login-card {
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.brand-logo-small {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 40px;
}

.brand-logo-small img {
    height: 60px;
    width: auto;
}

.brand-text {
    font-size: 1.25rem;
    font-weight: 700;
    color: #065f46;
    /* Dark emerald */
    line-height: 1.2;
}

.login-header {
    margin-bottom: 40px;
}

.login-header h2 {
    font-size: 2rem;
    color: #1f2937;
    font-weight: 600;
    margin-bottom: 10px;
}

.login-header p {
    color: #6b7280;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    font-size: 1rem;
    color: #111827;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-family: inherit;
}

.form-input:focus {
    outline: none;
    background-color: #fff;
    border-color: #10b981;
    /* Emerald 500 */
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

.submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(to right, #10b981, #059669);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.2s ease;
    font-family: inherit;
    margin-top: 10px;
}

.submit-btn:hover {
    background: linear-gradient(to right, #059669, #047857);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.submit-btn:active {
    transform: scale(0.98);
}

.error-message {
    margin-top: 20px;
    padding: 12px;
    border-radius: 6px;
    background-color: #fee2e2;
    color: #dc2626;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
    display: none;
    /* Controlled by JS */
    border-left: 4px solid #dc2626;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-card {
    animation: fadeIn 0.6s ease-out;
}

/* Responsive Design */
@media (max-width: 960px) {
    .visual-side {
        display: none;
    }

    .form-side {
        background-color: #f3f4f6;
        background-image: url('../Image/Img01.jpg');
        /* Show image as background on mobile */
        background-size: cover;
        background-position: center;
        background-blend-mode: overlay;
    }

    /* Add an overlay effect specifically for the form-side on mobile if image is used there */
    .form-side::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(255, 255, 255, 0.92);
        /* White overlay to make form readable */
        z-index: 1;
    }

    .login-card {
        background: white;
        padding: 40px;
        border-radius: 16px;
        box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
        z-index: 2;
        max-width: 400px;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 30px 20px;
        box-shadow: none;
        background: transparent;
    }

    .form-side::before {
        background: rgba(255, 255, 255, 0.95);
    }
}