/* Same reasoning as landing.css: this page is a dark design, so its own
   names are prefixed. Redefining --text-muted here would be overridden by the
   global palette loaded afterwards, turning the text grey on a dark ground. */
:root {
    --login-light: #f8fafc;
    --login-dark: #020617;
    --login-muted: rgba(255, 255, 255, 0.7);
    --login-card-bg: rgba(255, 255, 255, 0.06);
    --login-input-bg: rgba(255, 255, 255, 0.08);
    --login-border: rgba(255, 255, 255, 0.12);

    /* The brand lifted for this dark shell. The configured accent (#8c6a34)
       measures 3.8:1 here - under the 4.5:1 body-text threshold - so text set
       in it is legible only just. Mixing towards a warm light keeps the hue
       and reaches ~7:1, and color-mix means it still follows whatever accent
       is configured in Developer Settings. Borders and rules can keep the raw
       accent: UI components only need 3:1. */
    --login-accent: color-mix(in srgb, var(--accent, #8c6a34) 55%, #ffd88a);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, var(--primary), var(--login-dark));
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    overflow-x: hidden;
    position: relative;
}

/* Ambient Background Image Cover */
body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* The same photograph the landing page uses, so signing in feels like the
       same site rather than a different one. Served locally rather than from
       Unsplash: the sign-in page is the last place to want a third-party
       request that can hang, disappear, or hand a visitor's IP to someone
       else. */
    background: url('../img/landing_bg.jpg') no-repeat center center;
    background-size: cover;
    opacity: 0.1; 
    z-index: -1;
}

.container {
    width: 100%;
    max-width: 1100px;
    min-height: 650px;
    margin: 2rem;
    display: flex;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--login-border);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

/* Left Panel - Image Area */
.left-panel {
    flex: 1.1;
    position: relative;
    background: var(--login-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* The artwork is portrait and matches the panel's proportions, so "cover"
   fills it edge to edge at roughly native size - no magnification, and only
   the top and bottom are trimmed. */
.left-panel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    opacity: 0.72;
    transition: transform 0.5s ease;
    z-index: 1;
}

.left-panel:hover img {
    transform: scale(1.03);
}

/* Corporate Gradient overlay layer on the image */
.left-panel::after {
    content: "";
    z-index: 2;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(30, 58, 138, 0.4), rgba(15, 23, 42, 0.85));
}

/* Right Panel - Login Form Area */
.right-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 2.5rem;
    background: rgba(2, 6, 23, 0.2);
}

.login-card {
    width: 100%;
    max-width: 420px;
    text-align: center;
}

.login-logo {
    max-height: 60px;
    max-width: 220px;
    object-fit: contain;
    margin-bottom: 1rem;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.2));
}

.login-card p {
    color: var(--login-muted);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    font-weight: 400;
}

/* Error States */
.error-messages {
    background: rgba(228, 30, 38, 0.15);
    border-left: 4px solid #e41e26;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    text-align: left;
}

.error-messages p {
    color: #fca5a5;
    font-size: 0.95rem;
    margin: 0;
}

/* Form Inputs */
.input-group {
    position: relative;
    margin-bottom: 1.25rem;
    text-align: left;
}

.input-group .icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--login-muted);
    font-size: 1.1rem;
}

.input-group input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    background: var(--login-input-bg);
    border: 1px solid var(--login-border);
    border-radius: 12px;
    color: #fff;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

.input-group input:focus {
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
}

.input-group input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

/* MFA Choice Channels */
.verification-choice {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--login-border);
    border-radius: 12px;
    padding: 1.2rem;
    margin-bottom: 1.5rem;
    text-align: left;
}

.choice-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--login-muted);
    letter-spacing: 0.5px;
}

.verification-choice label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-right: 1.5rem;
    cursor: pointer;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.verification-choice label:hover {
    color: #fff;
}

.verification-choice input[type="radio"] {
    accent-color: var(--login-accent);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Actions */
button[type="submit"] {
    width: 100%;
    padding: 1rem;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

button[type="submit"]:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

button[type="submit"]:active {
    transform: translateY(0);
}

.forgot {
    color: var(--login-muted);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s ease;
    display: inline-block;
}

.forgot:hover {
    color: #fff;
    text-decoration: underline;
}

/* Responsive Adaptive Engine */
@media (max-width: 850px) {
    .left-panel {
        display: none; /* Hide illustrative frame on smaller form factors to keep workflow focus */
    }
    .container {
        max-width: 500px;
        min-height: auto;
    }
    .right-panel {
        padding: 3rem 2rem;
    }
}

@media (max-width: 480px) {
    .container {
        margin: 1rem;
        border-radius: 16px;
    }
    .right-panel {
        padding: 2.5rem 1.5rem;
    }
    .verification-choice label {
        display: flex;
        margin-bottom: 0.5rem;
    }
}

/* ========== Enhanced Mobile Responsive ========== */
@media (max-width: 850px) {
    .container {
        flex-direction: column;
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
        max-width: 100%;
    }
    .left-panel {
        display: none;
    }
    .right-panel {
        padding: 2.5rem 1.5rem;
        min-height: 100vh;
        justify-content: center;
    }
    .login-card {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .container {
        margin: 0;
        border-radius: 0;
        border: none;
        box-shadow: none;
    }
    .right-panel {
        padding: 2rem 1.25rem;
    }
    .login-card p {
        font-size: 0.95rem;
    }
    .login-logo {
        max-height: 50px;
        max-width: 180px;
    }
    .input-group input {
        padding: 0.9rem 0.9rem 0.9rem 2.8rem;
        font-size: 0.95rem;
    }
    button[type="submit"] {
        padding: 0.9rem;
        font-size: 1rem;
    }
    .verification-choice {
        padding: 1rem;
    }
    .verification-choice label {
        display: flex;
        margin-right: 0;
        margin-bottom: 0.6rem;
    }
}

@media (max-width: 360px) {
    .right-panel {
        padding: 1.5rem 1rem;
    }
    .login-logo {
        max-height: 42px;
    }
}


/* ==========================================================================
   Public header — shared with the landing page.
   About, Pricing and Feedback load this file rather than landing.css, and they
   previously had no header at all: a logo that was not a link and no way back
   to the front page.
   ========================================================================== */
.header {
    padding: 1.25rem 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}
.logo {
    display: flex;
    align-items: center;
}
.landing-img {
    height: 42px;
    width: auto;
    display: block;
    object-fit: contain;
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.nav-links a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 8px 18px;
    border-radius: 30px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.nav-links a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}
.nav-links a.btn-signup {
    background: transparent;
    border: 1.5px solid var(--accent);
    color: var(--landing-accent);
}
.nav-links a.btn-signup:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}
.nav-links a.btn-login {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}
.nav-links a.btn-login:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.logo-home { display: inline-block; }
.nav-links a.is-here { color: var(--login-accent); }
.nav-links a.is-here::after {
    content: ''; display: block; height: 2px; margin-top: 3px; border-radius: 2px;
    background: var(--login-accent);
}

/* ==========================================================================
   Pages that carry the public header.

   The body here is `display:flex; align-items:center`, which exists to centre
   a single sign-in card. Adding a header made it a second flex child, so the
   nav and the content sat side by side, both vertically centred. With a header
   the page is a column: bar on top, content beneath.
   ========================================================================== */
body.has-public-nav {
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
}
body.has-public-nav .header { flex: 0 0 auto; }
body.has-public-nav .container {
    margin: 2rem auto;
    min-height: 0;          /* the 650px floor is for the sign-in card only */
}
