/* Responsive Transport Diary sign-in shell. */
.auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    background: var(--kodewaves-paper);
    color: var(--kodewaves-ink);
}

.auth-shell-main {
    min-width: 0;
    display: grid;
    place-items: center;
    padding: clamp(20px, 4vw, 56px);
}

.auth-workspace {
    width: min(1120px, 100%);
    min-height: min(680px, calc(100vh - 118px));
    display: grid;
    grid-template-columns: minmax(0, 1.04fr) minmax(360px, 0.96fr);
    overflow: hidden;
    border: 1px solid var(--kodewaves-line);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 24px 70px rgb(28 48 37 / 10%);
}

.auth-workspace-story {
    min-width: 0;
    display: flex;
    flex-direction: column;
    padding: clamp(30px, 4vw, 54px);
    background: linear-gradient(150deg, #f8fafc 0%, #e8efe8 100%);
}

.auth-workspace-brand {
    display: inline-flex;
    width: fit-content;
    max-width: 100%;
    align-items: center;
}

.auth-workspace-brand img {
    display: block;
    width: min(252px, 100%);
    height: auto;
    object-fit: contain;
    content: url('/images/transport-diary-logo.svg?v=20261127-diary');
}

.auth-workspace-message {
    max-width: 480px;
    margin-top: clamp(46px, 8vh, 92px);
}

.auth-workspace-message h1 {
    margin: 0 0 16px;
    color: var(--kodewaves-ink);
    font-size: clamp(2rem, 3.4vw, 3.15rem);
    font-weight: 720;
    line-height: 1.08;
    letter-spacing: -0.045em;
}

.auth-workspace-message p {
    max-width: 42ch;
    margin: 0;
    color: var(--kodewaves-muted);
    font-size: 1rem;
    line-height: 1.7;
}

.auth-route-diagram {
    width: min(100%, 480px);
    margin: auto auto 14px;
    color: var(--kodewaves-ink);
}

.auth-route-diagram svg {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.auth-route-diagram text {
    font-family: Inter, ui-sans-serif, system-ui, sans-serif;
    font-size: 17px;
    font-weight: 600;
}

.auth-workspace-link {
    width: fit-content;
    color: var(--kodewaves-primary-deep);
    font-size: 0.9rem;
    font-weight: 650;
    text-decoration: none;
}

.auth-workspace-link:hover {
    color: var(--kodewaves-primary);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.auth-workspace-form {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: clamp(28px, 4vw, 56px);
}

.auth-workspace-form > * {
    width: min(100%, 410px);
}

.auth-login-heading {
    margin-bottom: 28px;
}

.auth-login-heading h2 {
    margin: 0 0 8px;
    color: var(--kodewaves-ink);
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.035em;
}

.auth-login-heading p {
    margin: 0;
    color: var(--kodewaves-muted);
    font-size: 0.93rem;
}

.auth-login-form {
    width: 100%;
}

.auth-login-fields {
    display: grid;
    gap: 18px;
}

.auth-login-field label {
    display: block;
    margin-bottom: 7px;
    color: var(--kodewaves-ink);
    font-size: 0.86rem;
    font-weight: 600;
}

.auth-login-field input {
    width: 100%;
    height: 48px;
    border: 1px solid var(--kodewaves-line);
    border-radius: 9px;
    background: #fff;
    color: var(--kodewaves-ink);
    box-shadow: none;
}

.auth-login-field input:focus {
    border-color: var(--kodewaves-primary);
    box-shadow: 0 0 0 3px rgb(66 107 87 / 14%);
    outline: none;
}

.auth-login-form .btn-block {
    width: 100%;
}

.auth-login-form button[type='submit'],
.auth-login-form button.btn-primary {
    min-height: 46px;
    border-color: var(--kodewaves-primary);
    border-radius: 9px;
    background: var(--kodewaves-primary);
    color: #fff;
    font-weight: 650;
}

.auth-shell-footer {
    padding: 0 20px 20px;
    color: var(--kodewaves-muted);
    text-align: center;
    font-size: 0.76rem;
}

.auth-shell-footer-inner {
    display: flex;
    justify-content: center;
}

@media (width <= 780px) {
    .auth-shell-main {
        padding: 14px;
    }

    .auth-workspace {
        width: min(560px, 100%);
        min-height: auto;
        grid-template-columns: 1fr;
        border-radius: 18px;
    }

    .auth-workspace-story {
        padding: 24px 26px 20px;
    }

    .auth-workspace-brand img {
        width: min(220px, 100%);
    }

    .auth-workspace-message {
        margin-top: 28px;
    }

    .auth-workspace-message h1 {
        font-size: clamp(1.65rem, 6vw, 2.3rem);
    }

    .auth-workspace-message p {
        font-size: 0.9rem;
    }

    .auth-route-diagram {
        width: min(100%, 360px);
        margin: 20px auto 8px;
    }

    .auth-workspace-link {
        font-size: 0.83rem;
    }

    .auth-workspace-form {
        padding: 30px 26px 34px;
    }

    .auth-shell-footer {
        padding-bottom: 12px;
    }
}

@media (width <= 420px) {
    .auth-workspace-story {
        padding: 20px 18px 16px;
    }

    .auth-workspace-form {
        padding: 24px 18px 28px;
    }

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

    .auth-login-fields {
        gap: 14px;
    }
}

/* Cache-busted Transport Diary mark for existing compiled header references. */
img.kodewaves-console-mark {
    content: url('/images/transport-diary-icon.svg?v=20261127-diary');
}

.auth-developer-attribution {
    color: #64748b;
    font-size: 0.8125rem;
}

.auth-license-link {
    display: inline-flex;
    min-height: 2.75rem;
    align-items: center;
    justify-content: center;
    margin-left: 0.75rem;
    color: #315641;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.auth-license-link:focus-visible {
    border-radius: 0.25rem;
    outline: 2px solid #426b57;
    outline-offset: 3px;
}

@media (max-width: 560px) {
    .auth-shell-footer-inner { flex-wrap: wrap; gap: 0.25rem 0.75rem; }
    .auth-license-link { margin-left: 0; }
}