* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Arial, sans-serif;
    background: #f5f7fb;
    color: #111827;
}

main {
    margin: 0 auto;
    padding: 24px;
}

.language-flag {
    height: 13px;
    object-fit: contain;
    display: inline-block;
}

.language-selector,
.context-switcher {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.is-login-page {
    background:
        radial-gradient(circle at top left, rgba(84, 118, 255, 0.35), transparent 32rem),
        linear-gradient(135deg, #eef2ff 0%, #dce5ff 45%, #eef5ff 100%);
}

.login-page {
    min-height: 80vh;
    display: grid;
    place-items: center;
    padding: 32px;
}

.login-shell {
    position: relative;
    width: min(1400px, 100%);
    min-height: 680px;
    display: grid;
    grid-template-columns: 1.8fr 1.2fr;
    border-radius: 6px;
    overflow: hidden;
    background: #081b4d;
    box-shadow: 0 30px 90px rgba(8, 27, 77, 0.28);
}

.login-topbar {
    position: absolute;
    top: 28px;
    right: 32px;
    z-index: 5;
}

.login-language-selector {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(14px);
    box-shadow: 0 10px 30px rgba(2, 6, 23, 0.18);
}

.login-language-selector select {
    border: 0;
    outline: none;
    background: transparent;
    color: #ffffff;
    font-weight: 600;
    cursor: pointer;
}

.login-language-selector select option {
    color: #111827;
}

.login-brand-panel {
    position: relative;
    padding: 64px;
    color: #ffffff;
    overflow: hidden;
    background:

        radial-gradient(ellipse at 90% 100%, rgba(37, 99, 235, 0.28) 0%, transparent 42%),
        linear-gradient(135deg, #061842 0%, #071b4d 48%, #091f5b 100%);
}

.login-brand-panel::before,
.login-brand-panel::after {
    content: "";
    position: absolute;
    border-radius: 6px;
    pointer-events: none;
}

.login-brand-panel::before {
    width: 900px;
    height: 220px;
    left: -170px;
    top: 240px;
    background: linear-gradient(90deg, rgba(91, 104, 255, 0.38), rgba(91, 104, 255, 0.06));
}


.login-brand,
.login-brand-extra-text,
.login-footer {
    position: relative;
    z-index: 1;
}

.login-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.login-brand-mark {
    width: 28px;
    height: 28px;
    display: inline-block;
    border: 6px solid #2563eb;
    border-radius: 6px;
    box-shadow: 0 0 0 5px rgba(37, 99, 235, 0.18);
    display: none;
}

.login-brand-extra-text {
    max-width: 620px;
    margin-top: 140px;
}

.login-dashboard-title {
    display: inline-flex;
    margin-bottom: 22px;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.login-brand-extra-text h1 {
    margin: 0;
    font-size: clamp(40px, 5vw, 68px);
    line-height: 0.98;
    letter-spacing: -0.06em;
}

.login-brand-extra-text p {
    margin: 22px 0 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 18px;
}

.login-footer {
    position: absolute;
    left: 64px;
    bottom: 42px;
    color: rgba(255, 255, 255, 0.62);
    font-size: 13px;
}

.login-form-panel {
    display: grid;
    place-items: center;
    padding: 48px;
    background: rgba(8, 27, 77, 0.35);
}

.login-card {
    width: min(420px, 100%);
    padding: 42px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 80px rgba(2, 6, 23, 0.22);
}

.login-card-header {
    margin-bottom: 28px;
}

.login-card-header h2 {
    margin: 0;
    font-size: 28px;
    letter-spacing: -0.04em;
}

.login-card-header p {
    margin: 8px 0 0;
    color: #6b7280;
}

.login-error {
    margin-bottom: 18px;
    padding: 12px 14px;
    border-radius: 6px;
    background: #fee2e2;
    color: #991b1b;
    font-size: 14px;
}

.form-field {
    display: grid;
    gap: 8px;
    margin-bottom: 20px;
}

.form-field span {
    font-size: 13px;
    color: #374151;
}

.form-field input {
    height: 48px;
    padding: 0 16px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    outline: none;
    font-size: 15px;
    background: #ffffff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-field input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.14);
}

.login-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 28px;
}

.reset-link {
    color: #4b5563;
    font-size: 14px;
    text-decoration: none;
}

.reset-link:hover {
    color: #2563eb;
    text-decoration: underline;
}

.login-button {
    min-width: 150px;
    height: 48px;
    border: 0;
    border-radius: 6px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}

.login-button:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
}

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

    .login-shell {
        min-height: auto;
        grid-template-columns: 1fr;
        border-radius: 6px;
    }

    .login-topbar {
        top: 18px;
        right: 18px;
    }

    .login-language-selector {
        padding: 6px 9px;
    }

    .login-language-selector select {
        max-width: 110px;
    }

    .login-brand-panel {
        min-height: 320px;
        padding: 34px;
    }

    .login-brand-extra-text {
        margin-top: 66px;
    }

    .login-brand-extra-text h1 {
        font-size: 38px;
    }

    .login-footer {
        display: none;
    }

    .login-form-panel {
        padding: 0 24px 28px;
        background: #081b4d;
    }

    .login-card {
        padding: 28px;
        margin-top: -42px;
    }

    .login-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .login-button {
        width: 100%;
    }
}

.adfs-login-button {
    width: 100%;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 14px;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #111827;
    font-weight: 700;
    text-decoration: none;
}

.adfs-login-button:hover {
    background: #f9fafb;
    border-color: #2563eb;
}

.adfs-login-button-primary {
    margin-top: 0;
    border: 0;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #ffffff;
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}

.adfs-login-button-primary:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
}

.login-button-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.password-reset-card .password-policy-card {
    margin-top: 4px;
    border-color: #d1d5db;
    border-radius: 6px;
    background: #f9fafb;
    color: #374151;
    font-size: 13px;
}

.password-reset-card .password-reset-preview {
    border-color: #d1d5db;
    border-radius: 6px;
    background: #f9fafb;
    color: #374151;
    font-size: 13px;
}

.password-reset-card .form-success {
    border-radius: 6px;
}

.password-reset-card .form-help {
    color: #6b7280;
    font-size: 13px;
}

.password-reset-card .password-errors {
    display: grid;
    gap: 4px;
    padding-left: 32px;
}

.password-reset-actions {
    margin-top: 22px;
}

.password-reset-card .reset-url {
    color: #1d4ed8;
}

.password-reset-card .reset-url:hover {
    color: #1e40af;
}
