/* ============================================================
   loginpage.css  —  1POS Login Page
   Target: Matches the reference design image exactly.
   Loaded ONLY for the Login page (conditional in _Layout.cshtml).
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700;800&display=swap');

/* ============================================================
   PAGE BACKGROUND
   ============================================================ */
body {
    margin: 0 !important;
    padding: 32px 24px;
    min-height: 100vh;
    background: #EAF1F0 !important;
    /* Pale sea green — ui_guideline.md: Overall Background */
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Poppins', 'Segoe UI', system-ui, sans-serif;
    overflow-x: hidden;
    box-sizing: border-box;
    /* Hard-reset any inherited dark gradient from old stylesheets */
    background-image: none !important;
}

body *,
body *::before,
body *::after {
    box-sizing: border-box;
}

/* ============================================================
   OUTER CARD
   ============================================================ */
.login-mobile-wrapper {
    max-width: 1020px;
    width: 100%;
    margin: auto;
    background: #FFFFFF !important;
    /* Pure white card */
    border-radius: 24px;
    /* Popped-out card shadow: ambient layer + key lift layer */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.10), 0 20px 48px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    padding: 0 !important;
    text-align: left;
}

/* Row: columns stretch to equal height, no gutter */
.login-mobile-wrapper .row {
    display: flex;
    width: 100%;
    align-items: stretch !important;
    margin: 0 !important;
    flex-wrap: nowrap;
}

.login-mobile-wrapper .row>[class*="col-"] {
    padding: 0;
    min-width: 0;
}

.login-mobile-wrapper .row>.col-sm-7 {
    flex: 0 0 55%;
    max-width: 55%;
}

.login-mobile-wrapper .row>.col-sm-5 {
    display: flex;
    flex: 0 0 45%;
    max-width: 45%;
    align-items: center;
}

.login-mobile-wrapper .row>.col-sm-5>form {
    width: 100%;
    margin: 0;
}

/* ============================================================
   LEFT PANEL — Banner Image
   ============================================================ */
.login-image-container {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 560px;
    overflow: hidden;
    border-radius: 24px 0 0 24px;
}

.login-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
    display: block;
    min-height: 560px;
}

/* Gradient overlay removed — image displays at full clarity */
.login-image-container::after {
    display: none;
}

/* ============================================================
   OVERLAY TEXT (sits on top of the image)
   ============================================================ */
.overlay-text {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    /* push content to bottom */
    padding: 40px 38px;
}

/* "1pos" — "1" is teal, "pos" is white */
.overlay-logo {
    position: absolute;
    top: 36px;
    left: 38px;
    font-size: 2.4rem;
    font-weight: 800;
    color: #fff;
    /* "pos" default white */
    letter-spacing: -2px;
    line-height: 1;
    font-family: 'Poppins', sans-serif;
}

.overlay-logo .logo-one {
    color: #18BDB3;
    /* "1" is teal */
}

/* "Smart Billing. / Seamless Growth." */
.overlay-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 14px;
}

.overlay-title-teal {
    color: #18BDB3;
    /* "Smart", "Seamless" */
}

.overlay-title-white {
    color: #ffffff;
    /* "Billing.", "Growth." */
    font-weight: 700;
}

/* Supporting paragraph below headline */
.overlay-subtext {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
    max-width: 275px;
    margin-bottom: 22px;
}

/* Carousel dots */
.overlay-dots {
    display: flex;
    gap: 8px;
    align-items: center;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.28);
    border: 2px solid rgba(255, 255, 255, 0.50);
    display: inline-block;
    transition: background 0.25s, border-color 0.25s;
    cursor: pointer;
}

.dot.active {
    background: #0F9E95;
    border-color: #0F9E95;
}

/* ============================================================
   RIGHT PANEL — Login Form
   ============================================================ */
.form-signin {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 56px clamp(28px, 4vw, 44px) 48px;
    text-align: left;
}

/* "Welcome Back" heading */
.login-welcome-title {
    font-size: 28px;
    font-weight: 700;
    color: #2F2F33;
    margin: 0 0 8px 0;
    line-height: 1.2;
    text-align: center;
}

/* "Sign in to continue to your account" */
.login-welcome-sub {
    font-size: 14px;
    color: #666A70;
    margin: 0 0 34px 0;
    font-weight: 400;
    line-height: 1.5;
    text-align: center;
}

/* ============================================================
   INPUT GROUPS
   ============================================================ */
.modern-input-wrapper {
    position: relative;
}

.modern-input-group {
    display: flex;
    align-items: center;
    border: 1.5px solid #E2E8F0;
    border-radius: 10px;
    background: #F8F8F8;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    overflow: hidden;
    height: 52px;
}

.modern-input-group:focus-within {
    border-color: #0F9E95;
    box-shadow: 0 0 0 3px rgba(15, 158, 149, 0.12);
    background: #fff;
}

/* Left icon box */
.input-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 100%;
    flex-shrink: 0;
}

/* Override inline red colour → teal */
.input-icon-box i {
    color: #0F9E95 !important;
    font-size: 17px !important;
}

/* Text input */
.modern-input-field {
    flex: 1;
    border: none !important;
    background: transparent !important;
    padding: 0 8px;
    height: 100%;
    font-size: 15px;
    color: #2F2F33;
    outline: none !important;
    box-shadow: none !important;
    font-family: inherit;
}

.modern-input-field::placeholder {
    color: #8D8F95;
    font-size: 15px;
    font-weight: 400;
}

/* Right icon box (password eye toggle) */
.input-right-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 100%;
    flex-shrink: 0;
    color: #94a3b8;
    cursor: pointer;
    transition: color 0.2s;
}

.input-right-icon:hover {
    color: #475569;
}

/* Hide the decorative right icon on username (not the password toggle) */
.modern-input-group .input-right-icon:not(#togglePasswordBtn) {
    display: none;
}

/* Hide helper hint text */
.input-helper {
    display: none;
}

/* Lower font size of warning validation texts */
.field-validation-error {
    font-size: 12px !important;
}

/* ============================================================
   FORGOT PASSWORD
   ============================================================ */
.forgot-password-link {
    color: #0F9E95 !important;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.15s;
}

.forgot-password-link:hover {
    color: #0D6E69 !important;
    text-decoration: underline;
}

/* ============================================================
   BUTTONS
   ============================================================ */

/* Login — solid teal gradient, full-width */
.btn-brand-solid {
    width: 100%;
    height: 52px;
    background: linear-gradient(90deg, #0F9E95 0%, #0D948C 50%, #0A8D85 100%);
    color: #ffffff !important;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: 0.3px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s, transform 0.12s;
    font-family: inherit;
}

.btn-brand-solid:hover {
    opacity: 0.88;
    transform: translateY(-1px);
    color: #ffffff !important;
}

.btn-brand-solid:active {
    transform: translateY(0);
    opacity: 1;
}

/* Read Card — white outlined */
.btn-brand-outline {
    width: 100%;
    height: 52px;
    background: #ffffff;
    color: #2F2F33 !important;
    border: 1.5px solid #CBD5E1;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
    font-family: inherit;
}

.btn-brand-outline:hover {
    border-color: #0F9E95;
    color: #0F9E95 !important;
    background: #f0fdfa;
}

.btn-brand-outline:active {
    transform: translateY(0);
}

/* ============================================================
   FOOTER TEXT
   ============================================================ */
.login-footer-text {
    font-size: 14px;
    color: #7D7D84 !important;
    text-align: center !important;
    margin-top: 28px !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
}

.login-footer-text a {
    color: #7D7D84 !important;
    text-decoration: none;
    white-space: normal !important;
}

.login-footer-text a:hover {
    color: #2F2F33 !important;
}

/* ============================================================
   MOBILE LOGO (hidden on desktop, shown on mobile)
   ============================================================ */
.mobile-logo {
    display: none;
}

.mobile-logo img {
    height: 44px;
    width: auto;
}

/* ============================================================
   RESPONSIVE — Mobile
   ============================================================ */
@media (max-width: 900px) {
    body {
        align-items: flex-start;
        padding: 24px;
    }

    .login-mobile-wrapper {
        border-radius: 16px;
        width: 100%;
        max-width: 560px;
    }

    .login-mobile-wrapper .row {
        display: block;
    }

    .login-mobile-wrapper .row>.col-sm-7 {
        display: none;
    }

    .login-mobile-wrapper .row>.col-sm-5 {
        display: block;
        max-width: 100%;
        width: 100%;
        flex: none;
    }

    /* On mobile, hide the image panel */
    .login-image-container {
        display: none;
    }

    /* Show the mobile logo at the top */
    .mobile-logo {
        display: block;
        text-align: center;
        padding-top: 28px;
        margin-bottom: 0;
    }

    .form-signin {
        padding: 28px clamp(24px, 7vw, 44px) 32px;
    }

    .login-welcome-title {
        font-size: 22px;
    }

    .login-welcome-sub {
        font-size: 13px;
        margin-bottom: 24px;
    }

    .modern-input-group {
        height: 46px;
    }

    .btn-brand-solid,
    .btn-brand-outline {
        height: 46px;
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 16px;
    }

    .form-signin {
        padding-right: 20px;
        padding-left: 20px;
    }
}
