.lf-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 12px 20px;
}

.lf-brand-mark {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 13px;
    color: #fff;
    font-size: 24px;
    font-weight: 700;
    font-style: italic;
    background: linear-gradient(145deg, #2563eb, #7c3aed 55%, #a855f7);
    box-shadow: var(--lf-shadow-purple);
}

.lf-brand-mark-large {
    width: 56px;
    height: 56px;
    border-radius: 18px;
    font-size: 34px;
}

.lf-brand-copy {
    display: flex;
    flex-direction: column;
}

.lf-brand-copy strong {
    font-size: 14px;
    font-weight: 600;
}

.lf-brand-copy span {
    color: var(--lf-text-muted);
    font-size: 11px;
    letter-spacing: 0.16em;
}

.lf-navigation {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 3px;
}

.lf-nav-item {
    display: flex;
    min-height: 42px;
    align-items: center;
    gap: 12px;
    padding: 0 12px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: var(--lf-text-soft);
    transition: var(--lf-transition);
}

.lf-nav-item:hover:not([aria-disabled="true"]),
.lf-nav-item.is-active {
    color: #fff;
    background: linear-gradient(90deg, rgba(124, 58, 237, 0.58), rgba(124, 58, 237, 0.22));
    border-color: rgba(139, 92, 246, 0.34);
}

.lf-nav-item[aria-disabled="true"] {
    opacity: 0.62;
    cursor: not-allowed;
}

.lf-nav-icon {
    display: grid;
    width: 22px;
    place-items: center;
    font-size: 16px;
}

.lf-sidebar-user {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 12px;
    border: 1px solid var(--lf-border);
    border-radius: 14px;
    background: rgba(12, 27, 54, 0.74);
}

.lf-avatar {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, #6d28d9, #8b5cf6);
    color: #fff;
    font-weight: 600;
}

.lf-sidebar-user strong,
.lf-sidebar-user span {
    display: block;
}

.lf-sidebar-user strong {
    font-size: 12px;
    font-weight: 600;
}

.lf-sidebar-user span {
    color: var(--lf-text-muted);
    font-size: 10px;
}

.lf-sidebar-user-arrow {
    font-size: 14px !important;
}

.lf-topbar-title {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 14px;
}

.lf-topbar-title h1 {
    margin-bottom: 4px;
    font-size: clamp(22px, 2vw, 30px);
    font-weight: 450;
    letter-spacing: -0.035em;
}

.lf-topbar-title p {
    margin: 0;
    color: var(--lf-text-muted);
    font-size: 12px;
}

.lf-topbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.lf-global-search {
    display: flex;
    width: min(320px, 30vw);
    height: 42px;
    align-items: center;
    gap: 10px;
    padding: 0 13px;
    border: 1px solid var(--lf-border);
    border-radius: 11px;
    background: rgba(13, 27, 54, 0.88);
}

.lf-global-search input {
    width: 100%;
    color: var(--lf-text-soft);
    background: transparent;
    border: 0;
    outline: 0;
}

.lf-live-clock {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--lf-text-muted);
    font-size: 11px;
    white-space: nowrap;
}

.lf-live-clock > span:nth-child(2) {
    color: var(--lf-green);
}

.lf-live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--lf-green);
    box-shadow: 0 0 14px rgba(34, 197, 94, 0.86);
}

.lf-theme-toggle,
.lf-icon-button {
    display: inline-flex;
    min-width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid var(--lf-border);
    border-radius: 11px;
    color: var(--lf-text-soft);
    background: var(--lf-surface);
    cursor: pointer;
}

.lf-theme-toggle-track {
    position: relative;
    width: 31px;
    height: 18px;
    border-radius: 999px;
    background: rgba(124, 58, 237, 0.45);
}

.lf-theme-toggle-thumb {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    transition: var(--lf-transition);
}

html[data-theme="light"] .lf-theme-toggle-thumb {
    transform: translateX(13px);
}

.lf-mobile-menu {
    display: none;
}

.lf-kpi-grid {
    display: grid;
    grid-template-columns: repeat(8, minmax(135px, 1fr));
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.lf-kpi-card,
.lf-card {
    border: 1px solid var(--lf-border);
    background: linear-gradient(145deg, rgba(14, 30, 58, 0.96), rgba(8, 19, 40, 0.96));
    box-shadow: var(--lf-shadow-card);
}

.lf-kpi-card {
    min-width: 140px;
    padding: 15px;
    border-radius: 14px;
}

.lf-kpi-card > span,
.lf-kpi-card > strong,
.lf-kpi-card > small {
    display: block;
}

.lf-kpi-card > span {
    color: var(--lf-text-soft);
    font-size: 11px;
}

.lf-kpi-card > strong {
    margin: 8px 0 4px;
    font-size: 24px;
    font-weight: 450;
}

.lf-kpi-card > small {
    color: var(--lf-text-muted);
    font-size: 9px;
}

.lf-kpi-icon {
    display: grid;
    width: 34px;
    height: 34px;
    margin-bottom: 12px;
    place-items: center;
    border-radius: 10px;
    background: rgba(124, 58, 237, 0.18);
    color: var(--lf-purple-bright);
}

.lf-kpi-card[data-tone="green"] .lf-kpi-icon { color: var(--lf-green); background: rgba(34, 197, 94, 0.14); }
.lf-kpi-card[data-tone="blue"] .lf-kpi-icon { color: var(--lf-blue); background: rgba(59, 130, 246, 0.14); }
.lf-kpi-card[data-tone="cyan"] .lf-kpi-icon { color: var(--lf-cyan); background: rgba(34, 211, 238, 0.14); }
.lf-kpi-card[data-tone="amber"] .lf-kpi-icon { color: var(--lf-amber); background: rgba(245, 158, 11, 0.14); }
.lf-kpi-card[data-tone="orange"] .lf-kpi-icon { color: var(--lf-orange); background: rgba(249, 115, 22, 0.14); }

.lf-card {
    padding: 20px;
    border-radius: 16px;
}

.lf-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--lf-border);
}

.lf-card-header h2 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
}

.lf-eyebrow {
    display: block;
    margin-bottom: 5px;
    color: var(--lf-purple-bright);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.12em;
}

.lf-status-pill,
.lf-stage-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 10px;
}

.lf-status-success {
    color: #7ef29f;
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.28);
}

.lf-stage-pill {
    color: #d8c8ff;
    background: rgba(124, 58, 237, 0.16);
    border: 1px solid rgba(139, 92, 246, 0.36);
}

.lf-empty-state {
    display: flex;
    min-height: 330px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px;
    text-align: center;
}

.lf-empty-icon {
    display: grid;
    width: 64px;
    height: 64px;
    margin-bottom: 18px;
    place-items: center;
    border-radius: 20px;
    color: var(--lf-green);
    font-size: 28px;
    background: rgba(34, 197, 94, 0.12);
    box-shadow: 0 0 34px rgba(34, 197, 94, 0.14);
}

.lf-empty-state h3 {
    margin-bottom: 8px;
    font-size: 18px;
    font-weight: 500;
}

.lf-empty-state p {
    max-width: 620px;
    margin: 0;
    color: var(--lf-text-muted);
}

.lf-status-list {
    display: grid;
    gap: 0;
    padding-top: 8px;
}

.lf-status-list div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--lf-border);
}

.lf-status-list div:last-child {
    border-bottom: 0;
}

.lf-status-list span {
    color: var(--lf-text-muted);
}

.lf-status-list strong {
    color: var(--lf-green);
    font-size: 12px;
    font-weight: 500;
}

.lf-auth-brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.lf-auth-brand span,
.lf-auth-brand strong {
    display: block;
}

.lf-auth-brand span {
    color: var(--lf-text-muted);
    font-size: 13px;
}

.lf-auth-brand strong {
    font-size: 20px;
    font-weight: 500;
}

.lf-auth-message {
    max-width: 760px;
}

.lf-auth-message h1 {
    margin: 20px 0 16px;
    font-size: clamp(38px, 5vw, 66px);
    font-weight: 400;
    line-height: 1.04;
    letter-spacing: -0.055em;
}

.lf-auth-message p {
    max-width: 640px;
    margin: 0;
    color: var(--lf-text-soft);
    font-size: 16px;
}

.lf-auth-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.lf-auth-metrics article {
    padding: 18px;
    border: 1px solid var(--lf-border);
    border-radius: 14px;
    background: rgba(11, 23, 48, 0.72);
}

.lf-auth-metrics span,
.lf-auth-metrics strong {
    display: block;
}

.lf-auth-metrics span {
    color: var(--lf-text-muted);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.lf-auth-metrics strong {
    margin-top: 8px;
    font-size: 18px;
    font-weight: 500;
}

.lf-auth-card {
    width: min(100%, 470px);
    padding: 34px;
    border: 1px solid var(--lf-border-strong);
    border-radius: 24px;
    background: linear-gradient(145deg, rgba(15, 31, 61, 0.96), rgba(7, 17, 37, 0.98));
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.38), 0 0 80px rgba(124, 58, 237, 0.08);
}

.lf-auth-card-heading h2 {
    margin-bottom: 6px;
    font-size: 30px;
    font-weight: 450;
    letter-spacing: -0.04em;
}

.lf-auth-card-heading p {
    color: var(--lf-text-muted);
}

.lf-form-stack {
    display: grid;
    gap: 18px;
    margin-top: 28px;
}

.lf-field {
    display: grid;
    gap: 8px;
}

.lf-field > span {
    color: var(--lf-text-soft);
    font-size: 12px;
}

.lf-field input {
    width: 100%;
    height: 48px;
    padding: 0 14px;
    color: var(--lf-text);
    border: 1px solid var(--lf-border);
    border-radius: 12px;
    outline: 0;
    background: rgba(5, 14, 31, 0.78);
    transition: var(--lf-transition);
}

.lf-field input:focus {
    border-color: var(--lf-purple-bright);
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.12);
}

.lf-form-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.lf-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--lf-text-soft);
    font-size: 12px;
}

.lf-checkbox input {
    width: 16px;
    height: 16px;
    accent-color: var(--lf-purple);
}

.lf-muted-link {
    color: var(--lf-text-muted);
    font-size: 12px;
}

.lf-button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    border-radius: 11px;
    cursor: pointer;
    transition: var(--lf-transition);
}

.lf-button-primary {
    color: #fff;
    background: linear-gradient(135deg, #6d28d9, #8b5cf6);
    box-shadow: var(--lf-shadow-purple);
}

.lf-button-primary:hover {
    transform: translateY(-1px);
    filter: brightness(1.08);
}

.lf-button-block {
    width: 100%;
}

.lf-foundation-note {
    display: flex;
    gap: 11px;
    margin-top: 20px;
    padding: 13px;
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 12px;
    background: rgba(245, 158, 11, 0.08);
}

.lf-foundation-note p {
    margin: 0;
    color: #e9cf9c;
    font-size: 11px;
}

.lf-foundation-note-icon {
    display: grid;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    place-items: center;
    border-radius: 50%;
    color: #0b1326;
    background: var(--lf-amber);
    font-weight: 700;
}

.lf-auth-footer {
    position: absolute;
    bottom: 22px;
    margin: 0;
    color: var(--lf-text-muted);
    font-size: 10px;
    text-align: center;
}

.lf-error-page {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 24px;
}

.lf-error-card {
    width: min(100%, 520px);
    padding: 42px;
    text-align: center;
    border: 1px solid var(--lf-border);
    border-radius: 24px;
    background: var(--lf-surface);
}

.lf-error-card > span {
    display: block;
    color: var(--lf-purple-bright);
    font-size: 58px;
    font-weight: 300;
}

.lf-error-card h1 {
    margin-bottom: 8px;
    font-weight: 450;
}

.lf-error-card p {
    margin-bottom: 24px;
    color: var(--lf-text-muted);
}

.lf-toast-region {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 9999;
    display: grid;
    width: min(390px, calc(100vw - 36px));
    gap: 10px;
}

.lf-toast {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 11px;
    align-items: start;
    padding: 14px;
    border: 1px solid var(--lf-border);
    border-radius: 14px;
    background: rgba(9, 22, 45, 0.96);
    box-shadow: var(--lf-shadow-card);
    backdrop-filter: blur(16px);
    animation: lf-toast-in 180ms ease-out;
}

.lf-toast-icon {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border-radius: 11px;
    background: rgba(124, 58, 237, 0.18);
    color: var(--lf-purple-bright);
}

.lf-toast[data-type="success"] .lf-toast-icon { background: rgba(34, 197, 94, 0.15); color: var(--lf-green); }
.lf-toast[data-type="warning"] .lf-toast-icon { background: rgba(245, 158, 11, 0.15); color: var(--lf-amber); }
.lf-toast[data-type="error"] .lf-toast-icon { background: rgba(239, 68, 68, 0.15); color: var(--lf-red); }

.lf-toast strong,
.lf-toast span {
    display: block;
}

.lf-toast strong {
    font-size: 12px;
    font-weight: 550;
}

.lf-toast span {
    margin-top: 3px;
    color: var(--lf-text-muted);
    font-size: 11px;
}

.lf-toast button {
    color: var(--lf-text-muted);
    background: transparent;
    cursor: pointer;
}

@keyframes lf-toast-in {
    from { opacity: 0; transform: translateY(-8px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
