/*
 * ae-default: the Ae sign-in theme, after www.aeeconomics.com (teal #1d6466, mint #89cbbf).
 * A brand panel on the left and the page on the right. Only Login is themed by a view of its own; every other
 * page is the shared view (Bootstrap row > col > card), which the .ae-content rules below lay out for the panel.
 */
:root {
    --ae-teal: #1d6466;
    --ae-teal-deep: #124f51;
    --ae-teal-ink: #0c3a3c;
    --ae-mint: #89cbbf;
    --ae-mint-wash: #eef6f5;
    --ae-text: #222222;
    --ae-muted: #5f6b6d;
    --ae-border: #d3dadb;
    --ae-danger: #b42318;
    --ae-focus: 0 0 0 0.2rem rgba(137, 203, 191, 0.55);
    --ae-radius: 6px;
}

body.ae-shell {
    margin: 0;
    min-height: 100vh;
    background: #ffffff;
    color: var(--ae-text);
    font-family: "Open Sans", system-ui, sans-serif;
}

a {
    color: var(--ae-teal);
    text-underline-offset: 0.15em;
}

a:hover,
a:focus {
    color: var(--ae-teal-deep);
}

/* Split layout */

.ae-split {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
}

.ae-brand {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2.75rem 3.25rem;
    color: #ffffff;
    background:
        radial-gradient(circle at 85% 15%, rgba(137, 203, 191, 0.22), transparent 45%),
        linear-gradient(160deg, var(--ae-teal) 0%, var(--ae-teal-deep) 55%, var(--ae-teal-ink) 100%);
}

.ae-brand::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 48px 48px;
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000000 60%);
    mask-image: linear-gradient(180deg, transparent 0%, #000000 60%);
    pointer-events: none;
}

.ae-brand > * {
    position: relative;
    z-index: 1;
}

.ae-brand__logo {
    align-self: flex-start;
    display: inline-flex;
}

.ae-brand__logo img {
    height: 44px;
    width: auto;
}

.ae-brand__headline {
    margin: 0 0 1rem;
    font: 800 2.6rem/1.15 "Manrope", sans-serif;
    letter-spacing: -0.01em;
}

.ae-brand__headline em {
    color: var(--ae-mint);
    font-style: italic;
}

.ae-brand__lead {
    max-width: 30rem;
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.02rem;
    line-height: 1.6;
}

.ae-brand__foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    font-size: 0.82rem;
}

.ae-brand__foot a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
}

.ae-brand__foot a:hover,
.ae-brand__foot a:focus {
    color: #ffffff;
    text-decoration: underline;
}

.ae-env {
    padding: 0.25rem 0.6rem;
    background: var(--ae-mint);
    color: var(--ae-teal-ink);
    font: 800 0.72rem/1 "Nunito", sans-serif;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.ae-content {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.ae-content__toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    padding: 1.25rem 2rem 0;
    font-size: 0.88rem;
}

.ae-content__toolbar a {
    font-weight: 600;
    text-decoration: none;
}

.ae-content__user {
    color: var(--ae-muted);
}

.ae-content__main {
    flex: 1;
    display: grid;
    place-items: center;
    padding: 3rem 1.5rem;
}

.ae-content__inner {
    width: min(420px, 100%);
}

.ae-content__foot {
    padding: 0 1.5rem 1.5rem;
    color: var(--ae-muted);
    font-size: 0.8rem;
    text-align: center;
}

/* The shared views' Bootstrap grid and cards, flattened into the panel */

.ae-content .row {
    --bs-gutter-x: 0;
    margin: 0;
}

.ae-content .row > [class*="col"] {
    flex: 0 0 100%;
    width: 100%;
    max-width: 100%;
}

.ae-content .card {
    border: 0;
    background: transparent;
    box-shadow: none !important;
}

.ae-content .card-body {
    padding: 0;
}

.ae-content h1,
.ae-content h2 {
    color: var(--ae-teal);
    font-family: "Manrope", sans-serif;
    font-weight: 800;
}

.ae-content .card h2.h4,
.ae-content .card h1.h4 {
    margin-bottom: 1.25rem !important;
    font-size: 1.75rem;
}

.text-muted {
    color: var(--ae-muted) !important;
}

/* Sign-in page */

.ae-title {
    margin: 0 0 0.35rem;
    font-size: 2rem;
    line-height: 1.15;
}

.ae-context {
    margin-bottom: 2rem;
    color: var(--ae-muted);
}

.ae-context strong {
    color: var(--ae-text);
}

.validation-summary-valid {
    display: none;
}

.ae-alert.validation-summary-errors {
    margin-bottom: 1.25rem;
    padding: 0.75rem 1rem;
    border-left: 4px solid var(--ae-danger);
    background: #fdf1f0;
    color: var(--ae-danger);
    font-size: 0.92rem;
}

.ae-alert ul {
    margin: 0;
    padding-left: 1.1rem;
}

.ae-providers {
    display: grid;
    gap: 0.6rem;
}

.ae-divider {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin: 1.6rem 0;
    color: var(--ae-muted);
    font-size: 0.85rem;
}

.ae-divider::before,
.ae-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--ae-border);
}

.ae-label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
}

.ae-label-row a {
    text-decoration: none;
}

.ae-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 1.5rem;
    margin-bottom: 1.5rem;
}

/* Form controls */

.form-label {
    color: #333333;
    font-size: 0.9rem;
    font-weight: 600;
}

.form-control,
.form-select {
    min-height: 3rem;
    border-color: var(--ae-border);
    border-radius: var(--ae-radius);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--ae-teal);
    box-shadow: var(--ae-focus);
}

.form-check-label {
    font-size: 0.92rem;
}

.form-check-input:checked {
    border-color: var(--ae-teal);
    background-color: var(--ae-teal);
}

.form-check-input:focus {
    border-color: var(--ae-teal);
    box-shadow: var(--ae-focus);
}

/* Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    border-radius: var(--ae-radius);
    font-family: "Nunito", sans-serif;
    font-weight: 800;
}

.btn-sm {
    min-height: 0;
}

.btn:focus-visible {
    box-shadow: var(--ae-focus);
}

.btn-primary {
    border-color: var(--ae-teal);
    background: var(--ae-teal);
    color: #ffffff;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    border-color: var(--ae-teal-deep) !important;
    background: var(--ae-teal-deep) !important;
    color: #ffffff;
}

.btn-outline-secondary,
.btn-outline-dark,
.ae-btn-provider {
    border: 1px solid var(--ae-border);
    background: #ffffff;
    color: var(--ae-text);
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus,
.btn-outline-dark:hover,
.btn-outline-dark:focus,
.ae-btn-provider:hover,
.ae-btn-provider:focus {
    border-color: var(--ae-teal);
    background: var(--ae-mint-wash);
    color: var(--ae-text);
}

.ae-btn-provider {
    gap: 0.75rem;
}

.ae-btn-provider__icon {
    flex: none;
}

/* Narrow screens: the brand panel becomes a band above the page */

@media (max-width: 900px) {
    .ae-split {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }

    .ae-brand {
        position: relative;
        height: auto;
        flex-direction: row;
        align-items: center;
        padding: 1.25rem 1.5rem;
    }

    .ae-brand__logo {
        align-self: center;
    }

    .ae-brand__logo img {
        height: 36px;
    }

    .ae-brand__pitch,
    .ae-brand__foot a {
        display: none;
    }

    .ae-content__toolbar {
        padding: 1rem 1.5rem 0;
    }

    .ae-content__main {
        place-items: start center;
        padding: 2rem 1rem;
    }
}
