/* ================================================================
   WORKFLOW CONTEXT BANNER
   Compact in-page banner showing workflow step position with
   prev/next navigation. Injected automatically by SPA router.
   Lives in #wf-context-slot (sibling above viewContainer) so
   async view re-renders can't destroy it.
   ================================================================ */

#wf-context-slot {
    flex-shrink: 0;
    padding: 16px 24px 0;
}

.wf-context-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    margin-bottom: 16px;
    border-radius: 8px;
    background: var(--wf-bg, rgba(20, 184, 166, 0.05));
    border: 1px solid color-mix(in srgb, var(--wf-color, #14b8a6) 20%, transparent);
    font-size: 0.8125rem;
    flex-wrap: wrap;
}

.wf-context-name {
    font-weight: 600;
    white-space: nowrap;
}

/* Step dots */
.wf-context-dots {
    display: flex;
    align-items: center;
    gap: 4px;
}

.wf-context-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border-color, #d1d5db);
    transition: background 0.2s, transform 0.2s;
}

.wf-context-dot--current {
    transform: scale(1.4);
}

.wf-context-dot--complete {
    opacity: 0.6;
}

/* Step label */
.wf-context-step-label {
    color: var(--text-secondary);
    white-space: nowrap;
}

/* Prev/Next navigation */
.wf-context-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
}

.wf-context-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    background: none;
    border: 1px solid var(--border-color, #d1d5db);
    color: var(--text-secondary);
    cursor: pointer;
    text-decoration: none;
    font-size: 0.875rem;
    transition: background 0.15s, color 0.15s;
}

.wf-context-nav-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

/* Dismiss button */
.wf-context-dismiss {
    width: 22px;
    height: 22px;
    border-radius: 4px;
    border: none;
    background: none;
    color: var(--text-tertiary);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: color 0.15s, background 0.15s;
}

.wf-context-dismiss:hover {
    color: var(--text-primary);
    background: var(--bg-tertiary);
}

/* Show link (visible when banner is dismissed) */
.wf-context-show-link {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    text-decoration: none;
    margin-bottom: 8px;
    display: inline-block;
}

.wf-context-show-link:hover {
    color: var(--text-secondary);
    text-decoration: underline;
}

/* ================================================================
   SIDEBAR NAV WORKFLOW DOTS
   Small colored dots on nav items that belong to workflows
   ================================================================ */

.wf-nav-dot {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    opacity: 0.7;
    transition: opacity 0.15s;
    pointer-events: none;
}

/* Shift dot left when parent item has a toggle chevron */
li:has(.item-toggle) .wf-nav-dot {
    right: 34px;
}

/* Hide dots when sidebar is collapsed — no room */
.sidebar:not(.expanded) .wf-nav-dot {
    display: none;
}

.sidebar-link:hover .wf-nav-dot {
    opacity: 1;
}

/* Responsive */
@media (max-width: 640px) {
    .wf-context-banner {
        padding: 6px 10px;
        gap: 6px;
        font-size: 0.75rem;
    }

    .wf-context-step-label {
        display: none;
    }

    .wf-context-nav {
        margin-left: 0;
    }
}
