/* Shared public pages. No app bundle, third-party code, marketing panels or decorative effects. */
* { box-sizing: border-box; min-width: 0; }
html { scrollbar-gutter: stable; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.5 var(--font-sans); -webkit-font-smoothing: antialiased; }
button, input { font: inherit; }
a { color: inherit; text-decoration: none; }
button { color: inherit; cursor: pointer; touch-action: manipulation; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
h1, h2, p { margin: 0; }
h1 { font-size: 28px; line-height: 1.2; letter-spacing: -.65px; font-weight: 600; }
h2 { font-size: 17px; font-weight: 600; }
[hidden] { display: none !important; }
.public-page { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.public-header, .public-footer { width: calc(100% - 96px); max-width: 1280px; margin-inline: auto; }
.public-header { min-height: 88px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.public-brand-group { display: flex; gap: 19px; align-items: center; }
.brand { display: block; line-height: 0; flex-shrink: 0; }
.brand img { display: block; width: 80px; height: auto; }
.brand .logo-dark { display: none; }
html[data-theme="dark"] .brand .logo-light { display: none; }
html[data-theme="dark"] .brand .logo-dark { display: block; }
.brand-separator { font-size: 30px; font-weight: 300; color: var(--line-strong); line-height: 1; user-select: none; }
.product-label { font-size: 13px; font-weight: 550; }
.icon { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }
.icon-button { border: 0; background: transparent; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 6px; transition: transform 100ms var(--ease-out); }
.public-main { width: calc(100% - 40px); flex: 1; margin-inline: auto; padding: 80px 0; display: flex; align-items: flex-start; justify-content: center; outline: none; }
.auth-content { width: 384px; margin-top: max(0px, calc(12vh - 80px)); }
.auth-heading { margin-bottom: 28px; }
.auth-heading p { margin-top: 12px; color: var(--secondary); font-size: 14px; line-height: 1.6; }
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 12px; font-weight: 550; margin-bottom: 8px; }
.field input { width: 100%; height: 44px; border: 1px solid var(--line-strong); border-radius: 6px; padding: 0 12px; background: var(--field-bg); color: var(--ink); font-size: 14px; }
.field input[aria-invalid="true"] { border-color: var(--negative); }
.field small { display: block; color: var(--muted); font-size: 12px; margin-top: 8px; }
.field-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.field-heading a { color: var(--secondary); font-size: 12px; text-underline-offset: 3px; }
.password-field { position: relative; }
.password-field input { padding-right: 88px; }
.password-toggle { position: absolute; top: 1px; right: 2px; padding: 0 10px; height: 42px; color: var(--secondary); background: transparent; border: 0; border-radius: 4px; font-size: 12px; }
.field .caps-warning { color: var(--warning); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 40px; border-radius: 7px; padding: 9px 14px; background: var(--subtle); border: 1px solid var(--line-strong); color: var(--ink); font-size: 12px; font-weight: 550; transition: transform 100ms var(--ease-out); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn:active:not(:disabled), .icon-button:active { transform: scale(.98); }
.btn:disabled { color: var(--muted); background: var(--subtle); border-color: var(--line); transform: none; cursor: wait; }
.submit-button { width: 100%; min-height: 44px; margin-top: 6px; justify-content: space-between; }
.auth-error { padding: 12px 14px; margin-bottom: 20px; border: 1px solid var(--line); border-left: 2px solid var(--negative); border-radius: 4px; color: var(--negative); background: var(--subtle); font-size: 12px; line-height: 1.6; }
.auth-demo, .auth-footnote { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.65; }
.auth-demo summary { display: inline-block; cursor: pointer; color: var(--secondary); padding: 8px 0; min-height: 32px; text-decoration: underline; text-underline-offset: 3px; }
.auth-demo dl { padding: 10px 0 0; margin: 0; }
.auth-demo dl div { display: flex; justify-content: space-between; gap: 16px; padding: 4px 0; }
.auth-demo dt, .auth-demo dd { margin: 0; }
.auth-demo dd, .mono { font-family: var(--font-mono); font-size: 12px; }
.public-footer { min-height: 66px; display: flex; align-items: center; gap: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.public-footer span:nth-child(2) { margin-left: auto; }
.back-link { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--secondary); margin-bottom: 26px; min-height: 32px; }
.back-link .icon { width: 14px; height: 14px; }
.code-input { font-family: var(--font-mono); font-size: 20px !important; letter-spacing: .25em; font-variant-numeric: tabular-nums; }
.auth-result { color: var(--secondary); font-size: 13px; }
.auth-result h2 { color: var(--ink); margin-bottom: 10px; }
.auth-result .btn { margin-top: 24px; }
.error-content { width: 480px; margin-top: max(0px, calc(15vh - 80px)); }
.error-code { font: 500 52px/1 var(--font-sans); color: var(--muted); letter-spacing: -2px; margin-bottom: 24px; }
.error-description { max-width: 440px; margin: 14px 0 26px; line-height: 1.75; color: var(--secondary); }
.error-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.error-meta { margin: 32px 0 0; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.error-meta div { display: flex; gap: 24px; }
.error-meta dd { margin: 0; font-family: var(--font-mono); }
.error-reference { display: flex; align-items: center; gap: 24px; color: var(--muted); margin-top: 10px; font-size: 12px; overflow-wrap: anywhere; }
.error-content .auth-footnote { border: 0; padding: 0; margin-top: 22px; font-size: 11px; }
.skip-link { position: fixed; top: 8px; left: 8px; padding: 8px 16px; background: var(--ink); color: var(--bg); transform: translateY(-150%); z-index: 100; }
.skip-link:focus { transform: none; }
@media (hover: hover) and (pointer: fine) {
    .btn:not(:disabled):hover, .icon-button:hover { background: var(--hover); }
    .btn.primary:not(:disabled):hover { background: var(--accent-hover); border-color: var(--accent-hover); }
    .field-heading a:hover, .public-footer a:hover, .back-link:hover, .password-toggle:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
}
@media (max-width: 700px) {
    .public-header, .public-footer { width: calc(100% - 40px); }
    .public-header { min-height: 74px; }
    .public-main { padding: 48px 0; }
    .auth-content, .error-content { margin-top: 0; }
    .brand img { width: 68px; }
    .brand-separator { font-size: 25px; }
    .public-brand-group { gap: 14px; }
    .field input { font-size: 16px; }
    .public-footer { gap: 16px; font-size: 10px; }
    h1 { font-size: 26px; }
    .btn, .icon-button { min-height: 44px; }
    .error-code { font-size: 44px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
    .btn:active, .icon-button:active { transform: none !important; }
}
@media (forced-colors: active) {
    .btn, .icon-button, .field input { border: 1px solid ButtonText; }
    .brand-separator { color: CanvasText; }
    .auth-error { border-color: CanvasText; }
}
