* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    background: #f8faff;
    color: #101828;
}

a {
    color: inherit;
}

button,
input {
    font: inherit;
}

.auth-page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(340px, 0.9fr) minmax(0, 1.1fr);
}

.auth-brand-panel {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px;
    background:
        linear-gradient(
            160deg,
            #071b3a 0%,
            #102a56 100%
        );
    color: #ffffff;
}

.auth-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 1.05rem;
    font-weight: 800;
}

.auth-logo {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #4f67f6;
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 800;
    box-shadow: 0 8px 22px rgba(79, 103, 246, 0.28);
}

.brand-content {
    max-width: 520px;
    margin: auto 0;
}

.brand-label {
    display: inline-block;
    margin-bottom: 18px;
    color: #9dadff;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.1em;
}

.brand-content h1 {
    margin: 0 0 24px;
    font-size: clamp(2.4rem, 5vw, 4.4rem);
    line-height: 1.04;
    letter-spacing: -0.045em;
}

.brand-content p {
    margin: 0;
    max-width: 520px;
    color: #c7d0df;
    font-size: 1.05rem;
    line-height: 1.8;
}

.brand-footer {
    color: #8fa1ba;
    font-size: 0.85rem;
}

.auth-main {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    padding: 40px;
    background: #ffffff;
    border: 1px solid #e4e8f2;
    border-radius: 22px;
    box-shadow: 0 22px 60px rgba(16, 24, 40, 0.08);
}

.mobile-brand {
    display: none;
    align-items: center;
    gap: 10px;
    margin-bottom: 32px;
    font-weight: 800;
}

.auth-heading {
    margin-bottom: 30px;
}

.auth-heading h2 {
    margin: 0 0 10px;
    color: #101828;
    font-size: 2rem;
    letter-spacing: -0.035em;
}

.auth-heading p {
    margin: 0;
    color: #667085;
    line-height: 1.7;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 20px;
}

.auth-field label {
    color: #344054;
    font-size: 0.9rem;
    font-weight: 700;
}

.auth-field input {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    background: #ffffff;
    color: #101828;
    outline: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.auth-field input:focus {
    border-color: #4f67f6;
    box-shadow: 0 0 0 4px rgba(79, 103, 246, 0.1);
}

.auth-button {
    width: 100%;
    min-height: 48px;
    margin-top: 4px;
    padding: 12px 20px;
    border: 0;
    border-radius: 10px;
    background: #4f67f6;
    color: #ffffff;
    font-weight: 800;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        opacity 0.2s ease;
}

.auth-button:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(79, 103, 246, 0.22);
}

.auth-button:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.auth-message {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 0.9rem;
    line-height: 1.5;
}

.auth-message.hidden {
    display: none;
}

.auth-message.success {
    background: #ecfdf3;
    border: 1px solid #abefc6;
    color: #067647;
}

.auth-message.error {
    background: #fef3f2;
    border: 1px solid #fecdca;
    color: #b42318;
}

.auth-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 20px;
    color: #667085;
    font-size: 0.88rem;
}

.auth-secondary a {
    color: #4f67f6;
    font-weight: 700;
    text-decoration: none;
}

.auth-secondary a:hover {
    text-decoration: underline;
}

.auth-security {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid #eaecf0;
    color: #98a2b3;
    font-size: 0.8rem;
}

.security-icon {
    color: #12b76a;
    font-weight: 800;
}

@media (max-width: 900px) {
    .auth-page {
        grid-template-columns: 1fr;
    }

    .auth-brand-panel {
        display: none;
    }

    .mobile-brand {
        display: flex;
    }

    .auth-main {
        min-height: 100vh;
    }
}

@media (max-width: 600px) {
    .auth-main {
        padding: 24px 16px;
    }

    .auth-card {
        padding: 30px 22px;
        border-radius: 18px;
    }

    .auth-heading h2 {
        font-size: 1.7rem;
    }

    .auth-secondary {
        flex-wrap: wrap;
        text-align: center;
    }
}