﻿/* ========== login.css – Fully Responsive Split Screen ========== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Nunito', sans-serif;
    height: 100vh;
    overflow-x: hidden; /* prevent horizontal scroll */
    overflow-y: auto; /* allow vertical scroll if needed */
}

/* ----- Main Split Container ----- */
.login-split {
    display: flex;
    min-height: 100vh; /* grows if content is taller */
}

/* ========== Left Branding Panel ========== */
.split-left {
    width: 45%;
    background: var(--first-background);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    padding: 2rem;
}

.branding-content {
    text-align: center;
    max-width: 100%;
}

.branding-img {
    width: 80%;
    max-width: 300px;
    height: auto;
    margin-bottom: 2rem;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.2));
}

.branding-content h1 {
    font-size: 2.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.branding-content p {
    font-size: 1.1rem;
    opacity: 0.85;
}

/* ========== Right Form Panel ========== */
.split-right {
    width: 55%;
    background: #f8f9fc;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.form-wrapper {
    width: 100%;
    max-width: 420px;
    background: #ffffff;
    padding: 2.5rem 2rem;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.05);
}

.form-logo {
    width: 70px;
    height: 70px;
    object-fit: contain;
}

.form-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    margin-bottom: 0.3rem;
}

.form-subtitle {
    text-align: center;
    color: #6b7280;
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

/* Floating label fields (touch friendly) */
.floatinglabel .form-control {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    padding-left: 1rem;
}

    .floatinglabel .form-control:focus {
        border-color: var(--first-color);
        box-shadow: 0 0 0 3px rgba(7,108,175,0.1);
    }

.floatinglabel i.svg-inline--fa {
    right: 15px;
    color: #94a3b8;
}

/* Button */
.btn-login {
    background: var(--first-light-background);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: 10px;
    transition: 0.3s;
    font-size: 1rem;
}

    .btn-login:hover {
        background: linear-gradient(45deg, #0b81cf, #2a4ab0);
        box-shadow: 0 8px 20px rgba(30,58,138,0.2);
        color: #fff;
    }

/* Forgot password link */
.forgot-link {
    font-weight: 500;
    color: var(--first-color);
    text-decoration: none;
    font-size: 0.9rem;
}

    .forgot-link:hover {
        text-decoration: underline;
    }

/* ========== Responsive Breakpoints ========== */

/* Tablet: stack panels vertically */
@media (max-width: 768px) {
    .login-split {
        flex-direction: column;
    }

    .split-left,
    .split-right {
        width: 100%;
    }

    .split-left {
        padding: 2.5rem 1.5rem;
        min-height: auto; /* auto height based on content */
    }

    .split-right {
        padding: 2rem 1.5rem;
        min-height: auto;
    }

    .branding-img {
        width: 60%;
        max-width: 220px;
        margin-bottom: 1.5rem;
    }

    .branding-content h1 {
        font-size: 2.2rem;
    }
}

/* Small Mobile (phones) */
@media (max-width: 480px) {
    .split-left {
        padding: 2rem 1rem;
    }

    .split-right {
        padding: 1.5rem 1rem;
    }

    .branding-img {
        width: 50%;
        max-width: 160px;
        margin-bottom: 1rem;
    }

    .branding-content h1 {
        font-size: 1.8rem;
    }

    .branding-content p {
        font-size: 0.95rem;
    }

    .form-wrapper {
        padding: 1.5rem 1.2rem;
        border-radius: 16px;
    }

    .form-logo {
        width: 55px;
        height: 55px;
    }

    .form-title {
        font-size: 1.5rem;
    }

    .form-subtitle {
        font-size: 0.85rem;
        margin-bottom: 1.5rem;
    }

    .btn-login {
        padding: 0.65rem;
        font-size: 0.95rem;
    }
}

/* Very tiny screens (optional) */
@media (max-width: 360px) {
    .branding-content h1 {
        font-size: 1.5rem;
    }

    .form-wrapper {
        padding: 1.2rem 1rem;
    }
}

/* Modal refinements */
.modal-content {
    border-radius: 15px;
    border: none;
}

/* Ensure modal form also responsive */
@media (max-width: 480px) {
    .modal-dialog {
        margin: 1rem;
    }
}
