/* Modern Elite Property Management login page. Separate stylesheet keeps app.css unchanged. */
.login-page {
    --login-ink: #17233d;
    --login-muted: #77839a;
    --login-blue: #3d7bfd;
    --login-border: #e5eaf2;
    min-height: 100vh;
    margin: 0;
    padding: 24px;
    display: grid;
    place-items: center;
    background: #f2f5fa;
    color: var(--login-ink);
    font-family: Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif
}

    .login-page * {
        box-sizing: border-box
    }

.login-shell {
    width: min(1180px,100%);
    min-height: min(760px,calc(100vh - 48px));
    display: grid;
    grid-template-columns: 1.02fr .98fr;
    overflow: hidden;
    background: #fff;
    border: 1px solid rgba(218,226,239,.9);
    border-radius: 28px;
    box-shadow: 0 30px 90px rgba(29,48,82,.13)
}

.login-showcase {
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    padding: 42px 46px 28px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(145deg,#101c38 0%,#142c54 56%,#1c4778 100%)
}

    .login-showcase:before {
        content: "";
        position: absolute;
        z-index: -1;
        inset: 0;
        opacity: .22;
        background-image: linear-gradient(rgba(255,255,255,.07) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.07) 1px,transparent 1px);
        background-size: 42px 42px;
        mask-image: linear-gradient(to bottom,#000,transparent 85%)
    }

.showcase-glow {
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    filter: blur(2px);
    pointer-events: none
}

.showcase-glow-one {
    width: 380px;
    height: 380px;
    right: -170px;
    top: 80px;
    background: rgba(69,135,255,.2)
}

.showcase-glow-two {
    width: 300px;
    height: 300px;
    left: -170px;
    bottom: -80px;
    background: rgba(25,195,190,.12)
}

.login-brand {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    max-width: 230px;
    min-height: 46px
}

    .login-brand img {
        display: block;
        width: auto;
        max-width: 210px;
        max-height: 62px;
        object-fit: contain;
        border-radius: 5px
    }

.showcase-content {
    margin: auto 0;
    padding-top: 35px
}

.eyebrow, .form-kicker {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .16em
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #b7d1ff
}

.eyebrow-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #68e1cb;
    box-shadow: 0 0 0 4px rgba(104,225,203,.13)
}

.showcase-content h2 {
    margin: 20px 0 14px;
    color: #fff;
    font-size: clamp(30px,3.2vw,42px);
    line-height: 1.14;
    font-weight: 750;
    letter-spacing: -.045em
}

    .showcase-content h2 span {
        color: #86b3ff
    }

.showcase-copy {
    max-width: 390px;
    margin: 0;
    color: #c0cce0;
    font-size: 14px;
    line-height: 1.8
}

.property-visual {
    position: relative;
    height: 260px;
    margin: 18px -6px 0
}

.visual-orbit {
    position: absolute;
    border: 1px solid rgba(158,193,255,.22);
    border-radius: 50%;
    transform: rotate(-17deg)
}

.orbit-one {
    width: 390px;
    height: 145px;
    left: 0;
    bottom: 26px
}

.orbit-two {
    width: 320px;
    height: 110px;
    left: 34px;
    bottom: 44px
}

.visual-ground {
    position: absolute;
    bottom: 27px;
    left: 6%;
    width: 88%;
    height: 1px;
    background: linear-gradient(90deg,transparent,rgba(178,205,255,.6),transparent)
}

.building {
    position: absolute;
    bottom: 28px;
    border: 1px solid rgba(207,225,255,.6);
    box-shadow: 0 14px 30px rgba(0,0,0,.15)
}

.building-back {
    width: 104px;
    height: 138px;
    left: 35%;
    bottom: 35px;
    border-radius: 5px 5px 0 0;
    background: linear-gradient(130deg,#4c76a9,#27446d);
    transform: skewY(-4deg)
}

.building-front {
    width: 145px;
    height: 176px;
    left: 46%;
    bottom: 28px;
    border-radius: 5px 5px 0 0;
    background: linear-gradient(130deg,#e6f0ff,#8eaed8);
    transform: skewY(2deg)
}

.building-roof {
    position: absolute;
    top: -9px;
    left: -1px;
    width: calc(100% + 2px);
    height: 10px;
    border-radius: 3px 3px 0 0;
    background: #a7c6f2
}

.building-windows {
    position: absolute;
    inset: 18px 14px 15px;
    background: repeating-linear-gradient(90deg,transparent 0 19px,rgba(21,48,83,.65) 19px 27px,transparent 27px 37px),repeating-linear-gradient(0deg,transparent 0 21px,rgba(21,48,83,.55) 21px 29px,transparent 29px 40px);
    opacity: .8
}

.building-back .building-windows {
    inset: 14px 12px;
    opacity: .5
}

.building-door {
    position: absolute;
    bottom: 0;
    left: 55px;
    width: 31px;
    height: 54px;
    border: 2px solid rgba(25,56,94,.55);
    border-bottom: 0;
    border-radius: 3px 3px 0 0;
    background: rgba(43,76,118,.25)
}

.floating-stat {
    position: absolute;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    color: #fff;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 13px;
    background: rgba(255,255,255,.11);
    box-shadow: 0 12px 26px rgba(0,0,0,.12);
    backdrop-filter: blur(12px)
}

    .floating-stat small, .floating-stat strong {
        display: block
    }

    .floating-stat small {
        color: #c2d3ed;
        font-size: 9px;
        margin-bottom: 3px
    }

    .floating-stat strong {
        font-size: 11px;
        font-weight: 650
    }

.stat-properties {
    top: 32px;
    left: 0
}

.stat-secure {
    right: 0;
    bottom: 49px
}

.stat-icon {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    color: #dce9ff;
    background: rgba(133,174,255,.23);
    font-size: 23px
}

.secure-check {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    color: #8bf0d7;
    background: rgba(85,220,186,.15);
    font-weight: 800
}

.showcase-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #a8bad4;
    font-size: 10px
}

.footer-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #6e8eb8
}

.login-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 54px clamp(34px,5vw,68px) 24px;
    background: #fff
}

.login-form-wrap {
    width: 100%;
    max-width: 390px;
    margin: auto
}

.form-kicker {
    color: #3d7bfd
}

.form-heading h1 {
    margin: 13px 0 9px;
    color: #17233d;
    font-size: clamp(26px,2.4vw,32px);
    line-height: 1.2;
    letter-spacing: -.04em;
    font-weight: 750
}

.form-heading p {
    margin: 0 0 32px;
    color: #7b879b;
    font-size: 13px;
    line-height: 1.7
}

.modern-login-form .field-group {
    margin-bottom: 21px
}

.modern-login-form .form-label {
    display: block;
    margin-bottom: 9px;
    color: #283750;
    font-size: 12px;
    font-weight: 700
}

.input-wrap {
    position: relative;
    display: flex;
    align-items: center
}

    .input-wrap > svg {
        position: absolute;
        left: 15px;
        z-index: 1;
        width: 19px;
        height: 19px;
        fill: none;
        stroke: #96a2b5;
        stroke-width: 1.7;
        stroke-linecap: round;
        stroke-linejoin: round;
        pointer-events: none
    }

    .input-wrap .form-control {
        height: 53px;
        padding: 0 45px;
        border: 1px solid var(--login-border);
        border-radius: 12px;
        background: #f9fbfe;
        color: #1b2942;
        font-size: 13px;
        box-shadow: none;
        transition: border-color .2s,box-shadow .2s,background .2s
    }

        .input-wrap .form-control::placeholder {
            color: #a4afbf
        }

        .input-wrap .form-control:focus {
            border-color: #79a5ff;
            background: #fff;
            box-shadow: 0 0 0 4px rgba(61,123,253,.11)
        }

.password-toggle {
    position: absolute;
    right: 10px;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 8px;
    color: #8d9ab0;
    background: transparent
}

    .password-toggle:hover {
        color: #315fae;
        background: #edf3ff
    }

    .password-toggle svg {
        width: 19px;
        height: 19px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.7;
        stroke-linecap: round;
        stroke-linejoin: round
    }

.field-error, .validation-summary {
    display: block;
    margin-top: 6px;
    color: #c43d4b;
    font-size: 11px
}

    .validation-summary:empty {
        display: none
    }

    .validation-summary ul {
        margin: 0;
        padding-left: 18px
    }

.login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 3px 0 24px
}

.remember-option {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #65738a;
    font-size: 12px;
    cursor: pointer;
    user-select: none
}

    .remember-option input {
        position: absolute;
        width: 1px;
        height: 1px;
        opacity: 0
    }

.custom-check {
    position: relative;
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    border: 1px solid #cdd6e4;
    border-radius: 5px;
    background: #fff;
    transition: .2s
}

.remember-option input:checked + .custom-check {
    border-color: #3d7bfd;
    background: #3d7bfd
}

    .remember-option input:checked + .custom-check:after {
        content: "";
        position: absolute;
        left: 5px;
        top: 2px;
        width: 5px;
        height: 9px;
        border: solid white;
        border-width: 0 2px 2px 0;
        transform: rotate(45deg)
    }

.remember-option input:focus-visible + .custom-check {
    outline: 3px solid rgba(61,123,253,.22);
    outline-offset: 2px
}

.sign-in-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    min-height: 53px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(100deg,#3474f6,#4b8bff);
    box-shadow: 0 9px 20px rgba(61,123,253,.23);
    font-size: 13px;
    font-weight: 700;
    transition: transform .2s,box-shadow .2s
}

    .sign-in-button:hover {
        transform: translateY(-1px);
        box-shadow: 0 12px 24px rgba(61,123,253,.3)
    }

    .sign-in-button:active {
        transform: translateY(0)
    }

    .sign-in-button svg {
        width: 18px;
        height: 18px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.8;
        stroke-linecap: round;
        stroke-linejoin: round
    }

.login-security-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    color: #8b97a9;
    font-size: 10px
}

.security-icon {
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 6px;
    color: #2b9d81;
    background: #eaf8f3
}

    .security-icon svg {
        width: 14px;
        height: 14px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.8;
        stroke-linecap: round;
        stroke-linejoin: round
    }

.login-panel-footer {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 32px;
    color: #a0aabb;
    font-size: 9px
}

.mobile-brand {
    display: none
}

@media(max-width:900px) {
    .login-page {
        padding: 16px
    }

    .login-shell {
        min-height: calc(100vh - 32px);
        grid-template-columns: .9fr 1.1fr
    }

    .login-showcase {
        padding: 32px 28px 24px
    }

    .login-panel {
        padding: 42px 32px 22px
    }

    .property-visual {
        transform: scale(.92);
        transform-origin: center;
        margin-left: -15px;
        margin-right: -15px
    }

    .floating-stat {
        padding: 9px 10px
    }
}

@media(max-width:680px) {
    .login-page {
        display: block;
        padding: 0;
        background: #fff
    }

    .login-shell {
        display: block;
        width: 100%;
        min-height: 100vh;
        border: 0;
        border-radius: 0;
        box-shadow: none
    }

    .login-showcase {
        display: none
    }

    .login-panel {
        min-height: 100vh;
        justify-content: flex-start;
        padding: 25px 24px 18px
    }

    .mobile-brand {
        display: flex;
        align-items: center;
        min-height: 54px;
        margin-bottom: 45px
    }

        .mobile-brand img {
            display: block;
            width: auto;
            max-width: 185px;
            max-height: 54px;
            object-fit: contain
        }

    .login-form-wrap {
        max-width: 430px;
        margin: 0 auto
    }

    .form-heading h1 {
        font-size: 29px
    }

    .form-heading p {
        margin-bottom: 29px
    }

    .login-panel-footer {
        margin-top: auto;
        padding-top: 44px;
        font-size: 9px
    }
}

@media(max-width:360px) {
    .login-panel {
        padding-right: 18px;
        padding-left: 18px
    }

    .login-panel-footer {
        flex-direction: column;
        gap: 5px
    }
}


/* Laptop fit: keep the login card centered and scale its height to the viewport. */
@media (min-width: 681px) {
    .login-page {
        min-height: 100vh;
        min-height: 100dvh;
        padding: clamp(12px, 2.2vh, 24px);
    }

    .login-shell {
        width: min(1080px, 100%);
        min-height: 0;
        height: min(700px, calc(100dvh - 2 * clamp(12px, 2.2vh, 24px)));
        grid-template-columns: 1fr 1fr;
    }

    .login-showcase {
        padding: clamp(22px, 3.5vh, 36px) clamp(24px, 3vw, 40px) 20px;
    }

    .showcase-content {
        padding-top: clamp(12px, 2.2vh, 24px);
    }

        .showcase-content h2 {
            margin: 14px 0 10px;
            font-size: clamp(27px, 2.5vw, 36px);
        }

    .showcase-copy {
        font-size: 13px;
        line-height: 1.6;
    }

    .property-visual {
        height: clamp(150px, 25vh, 220px);
        margin-top: 8px;
        transform: scale(.88);
        transform-origin: center top;
    }

    .login-panel {
        padding: clamp(22px, 3.5vh, 38px) clamp(28px, 3.8vw, 52px) 18px;
    }

    .login-form-wrap {
        max-width: 360px;
    }

    .form-heading h1 {
        font-size: clamp(25px, 2.1vw, 30px);
    }

    .form-heading p {
        margin-bottom: clamp(18px, 2.6vh, 28px);
    }

    .modern-login-form .field-group {
        margin-bottom: clamp(12px, 1.8vh, 18px);
    }

    .input-wrap .form-control {
        height: 47px;
    }

    .login-options {
        margin-bottom: clamp(14px, 2vh, 20px);
    }

    .sign-in-button {
        min-height: 47px;
    }

    .login-security-note {
        margin-top: clamp(14px, 2vh, 20px);
    }

    .login-panel-footer {
        margin-top: 18px;
    }
}

/* Short laptop displays (e.g. 1366x768): compact the showcase and form further. */
@media (min-width: 681px) and (max-height: 800px) {
    .login-shell {
        height: calc(100dvh - 24px);
    }

    .login-showcase {
        padding-top: 20px;
        padding-bottom: 16px;
    }

    .login-brand {
        min-height: 38px;
    }

        .login-brand img {
            max-height: 48px;
            max-width: 185px;
        }

    .showcase-content {
        padding-top: 10px;
    }

        .showcase-content h2 {
            margin: 30px 0 90px;
            font-size: clamp(26px, 2.4vw, 32px);
        }

    .property-visual {
        height: 170px;
        margin-top: 4px;
        transform: scale(.78);
        transform-origin: center top;
    }

    .login-panel {
        padding-top: 18px;
        padding-bottom: 14px;
    }

    .form-heading h1 {
        margin-top: 9px;
        margin-bottom: 7px;
        font-size: 26px;
    }

    .form-heading p {
        margin-bottom: 17px;
        font-size: 12px;
    }

    .modern-login-form .field-group {
        margin-bottom: 12px;
    }

    .modern-login-form .form-label {
        margin-bottom: 6px;
    }

    .input-wrap .form-control {
        height: 44px;
    }

    .login-options {
        margin-bottom: 14px;
    }

    .sign-in-button {
        min-height: 44px;
    }

    .login-security-note {
        margin-top: 12px;
    }

    .login-panel-footer {
        margin-top: 12px;
    }
}


/* Final viewport correction: body padding must be included in its height. */
@media (min-width: 681px) {
    html {
        height: 100%;
        overflow: hidden;
    }

    body.login-page {
        box-sizing: border-box;
        width: 100%;
        height: 100vh;
        height: 100dvh;
        min-height: 0;
        padding: 10px;
        overflow: hidden;
    }

        body.login-page > .login-shell {
            width: min(1080px, 100%);
            height: calc(100dvh - 20px);
            min-height: 0;
            margin: auto;
        }

    .login-showcase {
        min-height: 0;
    }

    .showcase-content {
        flex: 1 1 auto;
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-height: 0;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .property-visual {
        flex: 0 0 auto;
        height: clamp(170px, 27vh, 230px);
        margin-top: 8px;
        transform: scale(.9);
        transform-origin: center top;
    }
}

/* On short laptop displays, compact vertical spacing without leaving a page scroll. */
@media (min-width: 681px) and (max-height: 800px) {
    body.login-page {
        padding: 8px;
    }

        body.login-page > .login-shell {
            height: calc(100dvh - 16px);
        }

    .login-showcase {
        padding-top: 16px;
        padding-bottom: 12px;
    }

    .showcase-content h2 {
        font-size: clamp(25px, 2.3vw, 31px);
    }

    .showcase-copy {
        font-size: 12px;
        line-height: 1.45;
    }

    .property-visual {
        height: clamp(165px, 26vh, 200px);
        margin-top: 6px;
        transform: scale(.82);
        transform-origin: center top;
    }

    .login-panel {
        padding-top: 14px;
        padding-bottom: 12px;
    }

    .login-panel-footer {
        margin-top: 8px;
    }
}

@media (max-width: 680px) {
    html {
        overflow-x: hidden;
    }

    body.login-page {
        box-sizing: border-box;
    }
}
