.sf-auth-shell {
    min-height: 100vh;
    padding: calc(var(--sf-navbar-height, 4rem) + 48px) 16px 64px;
    background: var(--phoenix-card-bg, #f8fafc);
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.sf-auth-card {
    width: 100%;
    max-width: 520px;
    background: var(--phoenix-card-bg, #fff);
    border: 1px solid var(--phoenix-border-color, rgba(15, 23, 42, .10));
    border-radius: 14px;
    padding: 32px;
    box-shadow: 0 12px 36px rgba(15, 23, 42, .06);
}
[data-bs-theme="dark"] .sf-auth-card {
    box-shadow: 0 12px 36px rgba(0, 0, 0, .40);
}
.sf-auth-card-narrow {
    max-width: 440px;
    text-align: center;
}

.sf-auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 20px;
    text-decoration: none;
}
.sf-auth-brand img {
    max-height: 44px;
    width: auto;
    display: block;
}

.sf-auth-h1 {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -.01em;
    margin: 0 0 6px;
    text-align: center;
    color: rgba(var(--phoenix-body-color-rgb), .96);
}
.sf-auth-sub {
    color: rgba(var(--phoenix-body-color-rgb), .62);
    font-size: .9rem;
    margin: 0 0 24px;
    text-align: center;
    line-height: 1.5;
}
.sf-auth-sub a { font-weight: 700; }

.sf-auth-alert {
    margin: 0 0 20px;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid transparent;
    font-size: .9rem;
    line-height: 1.5;
}
.sf-auth-alert.is-success { background: rgba(22, 163, 74, .10); border-color: rgba(22, 163, 74, .30); color: #15803d; }
.sf-auth-alert.is-danger  { background: rgba(220, 38, 38, .10);  border-color: rgba(220, 38, 38, .30);  color: #b91c1c; }
.sf-auth-alert.is-warning { background: rgba(245, 158, 11, .12); border-color: rgba(245, 158, 11, .35); color: #b45309; }
.sf-auth-alert.is-info    { background: rgba(37, 99, 235, .10);  border-color: rgba(37, 99, 235, .30);  color: #1d4ed8; }
[data-bs-theme="dark"] .sf-auth-alert.is-success { color: #86efac; }
[data-bs-theme="dark"] .sf-auth-alert.is-danger  { color: #fca5a5; }
[data-bs-theme="dark"] .sf-auth-alert.is-warning { color: #fcd34d; }
[data-bs-theme="dark"] .sf-auth-alert.is-info    { color: #93c5fd; }

.sf-auth-form .form-label {
    font-weight: 700;
    font-size: .82rem;
    margin-bottom: 6px;
    color: rgba(var(--phoenix-body-color-rgb), .88);
}
.sf-auth-form .form-control,
.sf-auth-form .form-select {
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid var(--phoenix-border-color, rgba(15, 23, 42, .14));
    background: var(--phoenix-card-bg);
    color: rgba(var(--phoenix-body-color-rgb), .92);
    font-size: .92rem;
}
.sf-auth-form .form-control:focus,
.sf-auth-form .form-select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .14);
}
[data-bs-theme="dark"] .sf-auth-form .form-control:focus,
[data-bs-theme="dark"] .sf-auth-form .form-select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96, 165, 250, .18);
}
.sf-auth-form .form-control.is-invalid,
.sf-auth-form .form-select.is-invalid {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}

.sf-auth-form-row { margin-bottom: 14px; }
.sf-auth-form-row:last-of-type { margin-bottom: 0; }

.sf-auth-row-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 4px 0 16px;
    font-size: .85rem;
}
.sf-auth-row-actions a { font-weight: 700; }

.sf-auth-inline-form {
    display: flex;
    align-items: stretch;
    gap: 8px;
    margin: 0 0 16px;
}
.sf-auth-inline-form .form-control { flex: 1 1 auto; }

.sf-auth-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 20px;
    border-radius: 10px;
    background: #2563eb;
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    border: 0;
    cursor: pointer;
    transition: background-color .12s ease;
    text-decoration: none;
    margin: 8px 0 0;
}
.sf-auth-submit:hover { background: #1d4ed8; color: #fff; }
.sf-auth-submit:disabled { opacity: .55; cursor: not-allowed; }
[data-bs-theme="dark"] .sf-auth-submit { background: #3b82f6; }
[data-bs-theme="dark"] .sf-auth-submit:hover { background: #2563eb; }

.sf-auth-submit-compact {
    padding: 10px 18px;
    width: auto;
    flex: 0 0 auto;
    font-size: .92rem;
    margin: 0;
}

.sf-auth-links {
    margin: 18px 0 0;
    text-align: center;
    font-size: .85rem;
    color: rgba(var(--phoenix-body-color-rgb), .65);
}
.sf-auth-links a { font-weight: 700; }
.sf-auth-links .sf-auth-link-row { display: block; margin-top: 6px; }

.sf-auth-footnote {
    margin: 18px 0 0;
    text-align: center;
    color: rgba(var(--phoenix-body-color-rgb), .60);
    font-size: .82rem;
}
.sf-auth-footnote a { font-weight: 700; }

.sf-auth-terms {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 4px 0 16px;
    font-size: .85rem;
    color: rgba(var(--phoenix-body-color-rgb), .80);
    line-height: 1.45;
}
.sf-auth-terms input { margin-top: 3px; }
.sf-auth-terms a { font-weight: 700; }

.sf-auth-recaptcha {
    display: flex;
    justify-content: center;
    margin: 0 0 16px;
}

.sf-auth-paused-ico {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    border-radius: 14px;
    background: rgba(245, 158, 11, .14);
    color: #b45309;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}
[data-bs-theme="dark"] .sf-auth-paused-ico {
    background: rgba(245, 158, 11, .22);
    color: #fcd34d;
}

.sf-auth-doc-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
    border: 1px solid var(--phoenix-border-color, rgba(15, 23, 42, .10));
    border-radius: 10px;
    overflow: hidden;
}
.sf-auth-doc-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    border-top: 1px solid var(--phoenix-border-color, rgba(15, 23, 42, .06));
}
.sf-auth-doc-row:first-child { border-top: 0; }
.sf-auth-doc-main { min-width: 0; flex: 1 1 auto; }
.sf-auth-doc-title {
    font-weight: 700;
    color: rgba(var(--phoenix-body-color-rgb), .94);
    font-size: .95rem;
}
.sf-auth-doc-version {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 700;
    background: rgba(37, 99, 235, .12);
    color: #1d4ed8;
    vertical-align: middle;
}
[data-bs-theme="dark"] .sf-auth-doc-version {
    background: rgba(96, 165, 250, .18);
    color: #93c5fd;
}
.sf-auth-doc-summary {
    color: rgba(var(--phoenix-body-color-rgb), .62);
    font-size: .85rem;
    margin-top: 4px;
}
.sf-auth-doc-link {
    font-size: .9rem;
    font-weight: 700;
    color: #1d4ed8;
    text-decoration: none;
    flex: 0 0 auto;
}
.sf-auth-doc-link:hover { text-decoration: underline; }
