@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');
@import url('https://fonts.googleapis.com/icon?family=Material+Icons+Round');

:root {
    --FontFamily: 'Roboto', 'QlikView Sans', sans-serif;
    --FontFamilyOpenSans: 'Open Sans', 'QlikView Sans', sans-serif;
}

body,
html {
    height: 100%;
    width: 100%;
    scrollbar-width: thin;
    overflow-x: hidden !important;
    overflow-y: auto;
}

body {
    background: #FFFFFF url('../img/bg-light.jpg') no-repeat center !important;
    background-size: cover !important;
    font-family: var(--FontFamily) !important;
    font-size: 16px;
    line-height: 18px;
    overflow: auto;
    color: #333 !important;
	transition: 0.3s all;
}

body.theme-dark {
    background: #111 url('../img/bg-dark.jpg') no-repeat center !important;
    background-size: cover !important;
    color: #E5E2E8 !important;
	transition: 0.3s all;
}

.moca-logo {
    position: fixed;
    display: block;
    top: 20px;
    right: 20px;
    height: 10%;
    width: 20%;
    text-align: right;
}

.moca-logo .logo {
    height: 100%;
    width: 100%;
    background-image: url('../img/Moca-Logo-light.svg');
    background-repeat: no-repeat;
    background-position: right center;
    background-size: auto 70%;
}

body.theme-dark .moca-logo .logo {
    background-image: url('../img/Moca-Logo-dark.svg');
}

/* Top-left FCSC logo */
.fcsc-logo {
    position: fixed;
    top: 24px;
    left: 24px;
    height: 56px;
    width: 360px;
}

.fcsc-logo .logo {
    height: 100%;
    width: 100%;
    background-image: url('../img/FCSC-Logo-light.svg');
    background-repeat: no-repeat;
    background-position: left center;
    background-size: contain;
}

body.theme-dark .fcsc-logo .logo {
    background-image: url('../img/FCSC-Logo-dark.svg');
}

/* Login layout variants */
.login-section {
    min-height: 100dvh;
    height: 100dvh;
    width: calc(90% + 5%);
    display: grid;
    align-items: center;
    padding: 0 0 0 5%;
	transition: 0.3s all;
}

.login-section.center {
    place-items: center;
}

.login-section.center {
    place-items: center;
}

.login-section.left {
    display: grid;
    grid-template-columns: 35% 1fr;
    width: 80%;
}

.login-section.left .left-pane {
    grid-column: 1;
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(3px);
    height: 100%;
    position: relative;
    padding: 0;
}

body.theme-dark .login-section.left .left-pane {
    background: rgba(12, 12, 16, 0.68);
    backdrop-filter: blur(6px);
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
	transition: 0.3s all;
}

.login-section.left .left-pane-inner {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-rows: auto 1fr auto;
    padding: 40px 0;
	box-shadow:0 8px 24px rgba(0, 0, 0, 0.12);
	transition: 0.3s all;
}



.login-section.left .left-pane .fcsc-logo {
    position: static;
    height: 64px;
    width: 380px;
    margin: 0 auto;
}

.login-section.left .left-pane .fcsc-logo .logo {
    background-image: url('../img/FCSC-Logo-light.svg');
    background-position: center;
}

body.theme-dark .login-section.left .left-pane .fcsc-logo .logo {
    background-image: url('../img/FCSC-Logo-dark.svg');
}

.login-section.left .left-pane .login-card {
    align-self: center;
    justify-self: center;
    width: min(460px, 90%);
    margin: 0;
    background: transparent !important;
    box-shadow: none !important;
    padding: 60px 30px;
    border: none;
    backdrop-filter: none !important;
}

.login-section.left .left-pane .left-footer {
    height: 15px;
    width: 100%;
    background: url('../img/Footer-light.png') no-repeat center bottom / contain;
    opacity: 0.95;
}

body.theme-dark .login-section.left .left-pane .left-footer {
    background-image: url('../img/Footer-dark.png');
}

/* Hide the global fcsc logo in left layout */
.login-section.left~.global.fcsc-logo {
    display: none;
}

.login-section.left~.page-footer {
    display: none;
}

/* Card */
.login-card {
    width: 460px;
    padding: 60px 60px;
    background: rgba(255, 255, 255, 0.68);
    backdrop-filter: blur(3px);
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

body.theme-dark .login-card {
    background: rgba(22, 22, 26, 0.72);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.login-title {
    font-weight: 400;
    text-align: center;
    color: #5b5f63;
    margin: 6px 0 18px;
    line-height: 24px;
}

body.theme-dark .login-title {
    color: #ECEDEF;
}

.login-form {
    display: grid;
    gap: 14px;
}

.field {
    position: relative;
}

.with-icon .icon {
    position: absolute;
    inset: 0 auto 0 10px;
    display: grid;
    place-items: center;
    color: #8b9197;
    font-size: 20px;
    pointer-events: none;
}

body.theme-dark .with-icon .icon {
    color: #898C81;
}

.with-icon input {
    width: 100%;
    height: 44px;
    border: 1px solid #b9c0c7;
    border-radius: 6px;
    padding: 0 12px 0 38px;
    background: rgba(255, 255, 255, 0.9);
}

body.theme-dark .with-icon input {
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.92);
}

.with-icon input:focus {
    outline: none;
    border-color: #7a8a99;
    box-shadow: 0 0 0 3px rgba(18, 112, 220, 0.1);
}

body.theme-dark .with-icon input:focus {
    border-color: #B7BBC2;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08);
}

.icon-action {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border: 0;
    background: transparent;
    cursor: pointer;
    display: grid;
    place-items: center;
    color: #6b7280;
}

body.theme-dark .icon-action {
    color: #898C81;
}

.icon-action .material-icons-round {
    font-size: 22px;
}

.icon-action.is-showing .material-icons-round {
    content: 'visibility_off';
}

.login-btn {
    height: 44px;
    border-radius: 6px;
    background: #4b6380;
    color: #fff;
    border: 1px solid #3f566f;
    display: grid;
    grid-template-columns: 1fr 24px;
    align-items: center;
    padding: 0 12px 0 12px;
}

body.theme-dark .login-btn {
    background: #6E5A66;
    border: 1px solid #5D4B56;
}

.login-btn .arrow {
    font-size: 20px;
    justify-self: end;
}

.login-btn:hover {
    filter: brightness(1.05);
}

.help-text {
    margin-top: 10px;
    text-align: center;
    color: #6a7177;
    font-size: 14px;
}

body.theme-dark .help-text{
	color: #aaa;
}

.help-text a {
    color: #2f5ea9;
    text-decoration: none;
}

body.theme-dark .help-text a {
    color: #E5E2E8;
}

.help-text a:hover {
    text-decoration: underline;
}

.page-footer {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    align-items: center;
}

.page-footer {
    height: 15px;
    width: 100%;
    background: url('../img/Footer-light.png') no-repeat center bottom / contain;
    opacity: 0.95;
}

body.theme-dark .page-footer {
    background-image: url('../img/Footer-dark.png');
}


/* Bottom-right UI toggles */
.ui-toggles {
    position: fixed;
    right: 16px;
    bottom: 16px;
    display: flex;
    gap: 10px;
    z-index: 10;
}

.toggle-btn {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #4b5563;
    cursor: pointer;
}

.toggle-btn:hover {
    filter: brightness(1.05);
}

/* Responsive breakpoints */
@media (min-width: 1600px) {
    .login-section.left {
        grid-template-columns: 30% 1fr;
    }

    .login-card {
        width: 520px;
        padding: 72px 64px;
    }

    .login-title {
        font-size: 18px;
    }

    .fcsc-logo {
        height: 72px;
        width: 420px;
    }

    .moca-logo {
        height: 12%;
        width: 22%;
    }

    .login-section.left .left-pane .left-footer {
        height: 16px;
    }

    .page-footer {
        height: 20px;
    }
}

@media (max-width: 1366px) {
    .login-section.left {
        grid-template-columns: 38% 1fr;
        width: 86%;
    }

    .login-card {
        width: 440px;
        padding: 48px 40px;
    }

    .fcsc-logo {
        height: 56px;
        width: 320px;
    }
}

@media (max-width: 1024px) {
    .login-section {
        width: 100%;
        padding-left: 0;
    }

    .login-section.left {
        grid-template-columns: 48% 1fr;
        width: 100%;
    }

    .login-card {
        width: 420px;
        padding: 40px 28px;
    }

    .fcsc-logo {
        height: 52px;
        width: 280px;
    }
}

@media (max-width: 820px) {
    .moca-logo {
        right: 12px;
        top: 14px;
        width: 36%;
        height: 10%;
    }

    .login-section {
        padding: 16px;
    }

    .login-section.left {
        grid-template-columns: 100%;
    }

    .login-section.left .left-pane {
        grid-column: 1 / -1;
    }

    .login-card {
        width: min(520px, 92vw);
        padding: 36px 20px;
    }

    .login-title {
        font-size: 16px;
    }

    .page-footer {
        bottom: 10px;
    }
}