/* PSB Luqman Al Hakim - Modern Islamic Login Redesign */
@charset "UTF-8";

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.login-page-body {
    min-height: 100vh;
    margin: 0;
    padding: 24px;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f7faf8;
    background-image: url('../assets/login/background-login-psb.png');
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow-x: hidden;
}

/* Fallback Corner Ornaments */
.corner-ornament {
    display: none;
}

/* Main Container */
.login-container {
    position: relative;
    z-index: 2;
    width: 100%;
    margin: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Common Card Styles */
.login-card {
    background: #ffffff;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(16, 50, 48, 0.12), 0 4px 16px rgba(0, 0, 0, 0.04);
}

/* Desktop Layout (Default > 860px) */
@media (min-width: 861px) {
    .login-container {
        max-width: 1102px;
        transform: translateY(6px);
    }

    .login-card {
        width: 1102px;
        height: 804px;
        display: flex;
        flex-direction: row;
    }

    .login-card-left {
        flex: 0 0 480px;
        width: 480px;
        height: 804px;
        position: relative;
        background-color: #155249;
        background-image: url('../assets/login/illustrations/left-panel-clean.png');
        background-size: 480px 804px;
        background-position: left top;
        background-repeat: no-repeat;
        overflow: hidden;
    }

    .login-card-right {
        flex: 1;
        height: 804px;
        padding: 44px 56px 40px 56px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        background: #ffffff;
    }
}

/* Mobile & Tablet Layout (<= 860px) */
@media (max-width: 860px) {
    body.login-page-body {
        padding: 24px 16px;
        background-attachment: scroll;
        align-items: flex-start;
    }

    .login-container {
        max-width: 440px;
        margin: 20px auto;
    }

    .login-card {
        width: 100%;
        max-width: 440px;
        height: auto;
        min-height: auto;
        display: flex;
        flex-direction: column;
        border-radius: 22px;
        box-shadow: 0 16px 40px rgba(16, 50, 48, 0.12);
    }

    .login-card-left {
        display: none;
    }

    .login-card-right {
        width: 100%;
        height: auto;
        padding: 36px 24px 32px 24px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        background: #ffffff;
    }

    .login-logo {
        width: 190px !important;
        margin-bottom: 16px !important;
    }

    .login-title {
        font-size: 26px !important;
    }

    .login-subtitle {
        font-size: 12.5px !important;
        margin-bottom: 24px !important;
    }

    .input-group-modern input.form-input-modern,
    .btn-submit-login {
        height: 50px !important;
    }
}

/* Screen-reader text fallback */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.login-form-wrapper {
    width: 100%;
    max-width: 490px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Logo */
.login-logo {
    width: 250px;
    max-width: 100%;
    height: auto;
    margin-bottom: 18px;
    display: block;
    object-fit: contain;
}

/* Typography */
.login-title {
    font-size: 32px;
    font-weight: 800;
    color: #175249;
    margin: 0 0 6px 0;
    letter-spacing: -0.2px;
    text-align: center;
    text-transform: uppercase;
    line-height: 1.2;
}

.login-subtitle {
    font-size: 13.5px;
    font-weight: 600;
    color: #8c9b98;
    letter-spacing: 2.8px;
    text-transform: uppercase;
    margin: 0 0 34px 0;
    text-align: center;
    line-height: 1.2;
}

/* Flash Messages */
.login-alert-box {
    width: 100%;
    margin-bottom: 18px;
}

.login-alert-box .alert,
.alert.alert-danger,
.message {
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.4;
    text-align: center;
    background-color: #fef2f2;
    border: 1px solid #fee2e2;
    color: #991b1b;
    box-sizing: border-box;
    margin-bottom: 16px;
}

/* Form Styles */
.login-form {
    width: 100%;
}

.input-group-modern {
    position: relative;
    width: 100%;
    margin-bottom: 16px;
}

.input-group-modern .input-icon-left {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: #8c9c9a;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 2;
}

.input-group-modern input.form-input-modern {
    width: 100%;
    height: 54px;
    border: 1.5px solid #d8e3e1;
    border-radius: 12px;
    background: #fbfdfc;
    font-size: 15px;
    color: #2c3e3c;
    font-family: inherit;
    font-weight: 500;
    padding: 0 48px 0 52px;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.input-group-modern input.form-input-modern::placeholder {
    color: #9aa8a6;
    font-weight: 400;
}

.input-group-modern input.form-input-modern:focus {
    outline: none;
    border-color: #176d63;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(23, 109, 99, 0.1);
}

.btn-toggle-password {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 6px;
    cursor: pointer;
    color: #8c9c9a;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s;
    z-index: 2;
}

.btn-toggle-password:hover {
    color: #176d63;
}

.btn-toggle-password:focus {
    outline: none;
}

/* Submit Button */
.btn-submit-login {
    width: 100%;
    height: 54px;
    background: #176d63;
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(23, 109, 99, 0.25);
    transition: all 0.2s ease;
    margin-top: 6px;
}

.btn-submit-login svg {
    flex-shrink: 0;
}

.btn-submit-login:hover {
    background: #11574e;
    box-shadow: 0 6px 18px rgba(23, 109, 99, 0.35);
    transform: translateY(-1px);
}

.btn-submit-login:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(23, 109, 99, 0.2);
}

/* Divider */
.login-divider {
    display: flex;
    align-items: center;
    width: 100%;
    margin: 26px 0 20px 0;
}

.login-divider::before,
.login-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #e6efee;
}

.login-divider span {
    padding: 0 16px;
    color: #9aa8a6;
    font-size: 13px;
    font-weight: 500;
}

/* Home Link */
.link-back-home {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #1b72b8;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.15s;
}

.link-back-home:hover {
    color: #125488;
    text-decoration: underline;
}

.link-back-home svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    flex-shrink: 0;
}
