:root {
    --primary-color: #2c5364;
    --secondary-color: #203a43;
    --accent-color: #0f2027;
    --light-gray: #f1f5f9;
    --dark: #1a202c;
    --gray: #4a5568;
    --error: #fff;
    --red: #D12027;
    --green: #005028;
    --text-gray: #58595B;
}

/* Main Layout */
.auth-main-layout {
    display: flex;
    min-height: 100vh;
    width: 100vw;
}

/* Left side: background image */
.auth-bg-side {
    flex: 1.3;
    background: url('../Img/bg.jpg') center center/cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 350px;
}

.auth-bg-overlay {
    width: 100%;
    height: 100%;
    background: rgba(44,83,100,0.45);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.auth-logo {
    max-width: 140px;
    margin-bottom: 1.5rem;
}

.auth-bg-overlay h2 {
    color: #fff;
    text-align: center;
    font-size: 2rem;
    font-weight: 400;
    margin: 0;
    text-shadow: 0 2px 8px rgba(32,58,67,0.25);
}

/* Right side: form */
.auth-form-side {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 370px;
    background: var(--light-gray);
}

/* Login Card */
.login-container {
    background-color: #fff;
    padding: 3rem 2.5rem 2rem 2.5rem;
    border-radius: 1.8rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.13);
    width: 100%;
    max-width: 450px;
}

.login-container h1 {
    font-size: 2rem;
    color: var(--red);
    margin-bottom: 0.5rem;
    text-align: center;
}

.login-container p {
    color: var(--text-gray);
    text-align: center;
    margin-bottom: 1.7rem;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.login-form input[type="email"],
.login-form input[type="password"],
.login-form input[type="text"] {
    padding: 0.8rem 1rem;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
    font-size: 1rem;
    transition: border 0.3s;
    background: #f8fafc;
    width: 100%;
    box-sizing: border-box;
}

.login-form input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(44, 83, 100, 0.1);
}

.password-container {
    position: relative;
    width: 100%;
}

.password-container input {
    padding-right: 2.5rem; /* Space for eye icon */
}

.toggle-password {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    color: var(--gray);
    cursor: pointer;
    user-select: none;
    transition: color 0.2s;
}

.toggle-password:hover {
    color: #231F20;
}

.btn {
    background-color: var(--green);
    color: #fff;
    font-weight: bold;
    padding: 0.8rem;
    border: none;
    border-radius: 6px;
    font-size: 1.07rem;
    cursor: pointer;
    margin-top: 0.2rem;
    transition: background-color 0.3s ease;
    width: 100%;
}

.btn:hover {
    background-color: var(--red);
}

.error {
    background-color: var(--red);
    color: var(--error);
    padding: 0.7rem 1rem;
    border-radius: 5px;
    text-align: center;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.login-links {
    text-align: center;
    margin-top: 1.4rem;
    font-size: 0.98rem;
}

.login-links a {
    color: var(--red);
    text-decoration: none;
    font-weight: 500;
}

.login-links a:hover {
    text-decoration: underline;
}

.login-links p {
    margin: 0.5rem 0;
}

@media (max-width: 900px) {
    .auth-main-layout {
        flex-direction: column;
    }
    .auth-bg-side {
        min-height: 240px;
        min-width: 100vw;
        flex: none;
    }
    .auth-form-side {
        min-width: 100vw;
        flex: none;
        padding: 2rem 1rem;
    }
    .login-container {
        border-radius: 1.2rem;
        padding: 2rem 1.5rem;
    }
}
body {
    max-width: 100vw;
    overflow-x: hidden;
}

.auth-main-layout,
.auth-bg-side,
.auth-form-side,
.login-container {
    max-width: 100vw;
    box-sizing: border-box;
    overflow-x: hidden;
}

@media (max-width: 900px) {
    .auth-main-layout,
    .auth-bg-side,
    .auth-form-side,
    .login-container {
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        max-width: 100vw !important;
    }
}
/* Make <a class="btn"> look like a real button */
a.btn {
    display: block;
    background-color: var(--green);
    color: #fff !important;
    font-weight: bold;
    padding: 0.8rem;
    border: none;
    border-radius: 6px;
    font-size: 1.07rem;
    cursor: pointer;
    margin-top: 0.2rem;
    transition: background-color 0.3s ease;
    width: 100%;
    text-align: center;
    text-decoration: none !important;
    box-sizing: border-box;
}

a.btn:hover {
    background-color: var(--red);
    color: #fff !important;
    text-decoration: none !important;
}