﻿/* Import the Poppins font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

:root {
    --navitap-primary: #4A90E2;
    --navitap-bg: #F4F7FA;
    --navitap-card: #FFFFFF;
    --navitap-text-primary: #1A1A1A;
    --navitap-text-secondary: #6B7280;
    --navitap-border-light: #E5E7EB;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* 1. Page Layout for Two Columns */
body {
    /* Updated font-family to Poppins */
    font-family: 'Poppins', sans-serif;
    display: flex; /* Use flexbox for the main layout */
    min-height: 100vh;
    overflow: hidden; /* Hide any overflow, especially from background image */
}

/* Left side with background image */
.login-background-left {
    flex: 1; /* Takes up 50% of the width */
    /* * !!! THIS PATH IS UPDATED !!!
     * It points to /wwwroot/images/navitap_back.jpg
     */
    background-image: url('/images/navitap_back.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative; /* For potential overlays */
}

/* Right side for the login card */
.login-container-right {
    flex: 1; /* Takes up the other 50% of the width */
    background-color: var(--navitap-bg); /* White background for the right side */
    display: flex;
    flex-direction: column; /* Stack login card and footer vertically */
    justify-content: center; /* Center login card vertically */
    align-items: center; /* Center login card horizontally */
    padding: 2rem; /* Add some padding for smaller screens */
    position: relative; /* For copyright absolute positioning */
}

/* 2. Login Card Styling */
.login-card {
    background-color: var(--navitap-card);
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0px 8px 24px rgba(0, 0, 0, 0.07);
    border: 1px solid var(--navitap-border-light);
    width: 100%; /* Make card take full width of its container on smaller screens */
    max-width: 380px; /* Max width as seen in the image */
}

/* 3. Header & Logo */
.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

    .login-header .logo {
        width: 120px; /* Adjust size as needed */
        height: auto;
        margin-bottom: 1.5rem; /* More space below logo */
    }

    .login-header h2 {
        font-size: 1.75rem;
        font-weight: 700;
        color: var(--navitap-text-primary);
        margin-bottom: 0.5rem;
    }

    .login-header p {
        font-size: 0.95rem; /* Slightly smaller for subtitle */
        color: var(--navitap-text-secondary);
    }

/* 4. Form Styling (Overrides Bootstrap) */
.form-control {
    padding: 1rem;
    font-size: 1rem;
    border-radius: 8px;
    border-color: var(--navitap-border-light);
    background-color: #F8F9FA; /* Slightly off-white input fields as in image */
    font-family: 'Poppins', sans-serif; /* Ensure inputs also use Poppins */
}

    .form-control:focus {
        border-color: var(--navitap-primary);
        box-shadow: 0 0 0 0.25rem rgba(74, 144, 226, 0.25); /* Primary color glow */
        background-color: var(--navitap-card); /* White background on focus */
    }

.form-floating > .form-control {
    height: calc(3.5rem + 2px);
    padding: 1rem 1rem 0 1rem; /* Adjust padding for floating label */
}

.form-floating > label {
    padding: 1rem 1rem 0 1rem;
    color: var(--navitap-text-secondary);
}

/* 5. Button Styling (Overrides Bootstrap) */
.btn-primary {
    background-color: var(--navitap-primary);
    border-color: var(--navitap-primary);
    border-radius: 8px;
    padding: 0.85rem; /* Slightly more vertical padding */
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.2s ease;
    font-family: 'Poppins', sans-serif; /* Ensure button uses Poppins */
}

    .btn-primary:hover {
        background-color: #357ABD; /* Slightly darker blue */
        border-color: #357ABD;
    }

    .btn-primary:focus {
        box-shadow: 0 0 0 0.25rem rgba(74, 144, 226, 0.5);
    }

/* 6. Utility Links */
.link-secondary {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--navitap-primary); /* Keep blue for contrast */
    text-decoration: none;
}

    .link-secondary:hover {
        text-decoration: underline;
        color: #357ABD;
    }

/* 7. Copyright Footer */
.copyright-footer {
    position: relative;
    bottom: -8rem;
    right: 0rem;
    font-size: 0.85rem;
    color: var(--navitap-text-secondary);
}

/* 8. Responsive Adjustments */
@media (max-width: 768px) {
    .login-background-left {
        display: none; /* Hide background image on smaller screens */
    }

    .login-container-right {
        width: 100%;
        padding: 1.5rem;
        justify-content: flex-start; /* Align card to top on small screens */
    }

    .login-card {
        margin-top: 2rem; /* Give some space from top on small screens */
        max-width: 400px; /* Adjust max-width for better fit */
    }

    .copyright-footer {
        position: static; /* Make it flow with content */
        margin-top: 2rem; /* Space below card */
        text-align: center;
        right: auto;
        bottom: auto;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 1.5rem; /* Smaller padding on very small screens */
    }

    .login-header h2 {
        font-size: 1.5rem;
    }
}
