/* ============================================
   .cta-button — shared "icon chip + label" CTA
   ============================================
   The primary CTA pattern threaded through the UI design pass: slate-900
   pill with a white icon slot on the left. Used for Create / New /
   Submit actions across the product so the visual contract is the same
   everywhere — kanban, hero, settings, modals, sidebars, legacy pages
   that have not yet been refactored to their own surface stylesheet.

   Variants:
     .cta-button                  → primary (slate-900)
     .cta-button--workspace       → tints to var(--workspace-accent) when
                                    the surface carries a workspace identity
     .cta-button--ghost           → outline-only on white (secondary action)
     .cta-button--warn            → amber outline (upgrade / non-destructive
                                    attention CTAs)
     .cta-button--block           → full-width (sticks to its column)
*/

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.95rem 0.5rem 0.5rem;
    background: var(--gray-900);
    color: var(--bs-white);
    border: 1px solid var(--gray-900);
    border-radius: 0.55rem;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
    transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease, border-color 140ms ease, color 140ms ease;
    box-shadow:
        inset 0 -2px 0 rgba(255, 255, 255, 0.06),
        0 2px 4px rgba(15, 23, 42, 0.15);
    white-space: nowrap;
}

.cta-button:hover {
    transform: translateY(-1px);
    background: #000;
    color: var(--bs-white);
    text-decoration: none;
    box-shadow:
        inset 0 -2px 0 rgba(255, 255, 255, 0.08),
        0 4px 14px rgba(15, 23, 42, 0.25);
}

.cta-button:focus-visible {
    outline: 0;
    box-shadow:
        inset 0 -2px 0 rgba(255, 255, 255, 0.08),
        0 0 0 3px rgba(15, 23, 42, 0.18);
}

.cta-button:disabled,
.cta-button.is-loading {
    cursor: progress;
    opacity: 0.85;
    transform: none;
}

.cta-button-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0.4rem;
    background: rgba(255, 255, 255, 0.12);
    font-size: 0.75rem;
    flex-shrink: 0;
}

/* Workspace-tinted variant — uses --workspace-accent if present on the surface */
.cta-button--workspace {
    background: var(--workspace-accent, var(--gray-900));
    border-color: var(--workspace-accent, var(--gray-900));
    box-shadow:
        inset 0 -2px 0 rgba(255, 255, 255, 0.08),
        0 2px 6px -2px color-mix(in srgb, var(--workspace-accent, var(--gray-900)) 45%, transparent);
}

.cta-button--workspace:hover {
    background: color-mix(in srgb, var(--workspace-accent, var(--gray-900)) 85%, #000);
    border-color: color-mix(in srgb, var(--workspace-accent, var(--gray-900)) 85%, #000);
    box-shadow:
        inset 0 -2px 0 rgba(255, 255, 255, 0.1),
        0 6px 18px -4px color-mix(in srgb, var(--workspace-accent, var(--gray-900)) 50%, transparent);
}

/* Ghost (secondary) variant */
.cta-button--ghost {
    background: var(--bs-white);
    color: var(--gray-800);
    border-color: var(--gray-200);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.cta-button--ghost:hover {
    background: var(--gray-50);
    color: var(--gray-900);
    border-color: var(--gray-300);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

.cta-button--ghost .cta-button-icon {
    background: var(--gray-100);
    color: var(--gray-700);
}

/* Warn (amber) variant — upgrade / non-destructive attention */
.cta-button--warn {
    background: var(--bs-white);
    color: #b45309;
    border-color: rgba(245, 158, 11, 0.45);
    box-shadow: 0 1px 2px rgba(245, 158, 11, 0.08);
}

.cta-button--warn:hover {
    background: rgba(245, 158, 11, 0.06);
    color: #b45309;
    border-color: rgba(245, 158, 11, 0.7);
    box-shadow: 0 4px 12px -6px rgba(245, 158, 11, 0.45);
}

.cta-button--warn .cta-button-icon {
    background: rgba(245, 158, 11, 0.16);
    color: #b45309;
}

/* Block (full-width) */
.cta-button--block {
    display: flex;
    width: 100%;
    justify-content: center;
}

/* Small variant — for footer / inline contexts */
.cta-button--sm {
    padding: 0.38rem 0.7rem 0.38rem 0.42rem;
    font-size: 0.8rem;
    border-radius: 0.45rem;
}

.cta-button--sm .cta-button-icon {
    width: 1.3rem;
    height: 1.3rem;
    font-size: 0.68rem;
    border-radius: 0.35rem;
}
