/* Custom ReBak WindowsApp styles that extend the generated Tailwind CSS file. */

/* Ensure the Blazor app root fills the WebView viewport. */
html,
body,
#app {
    height: 100%;
}

/* Utilities missing from the generated Tailwind bundle. */
.h-screen {
    height: 100vh;
}

.px-3 {
    padding-inline: 0.75rem;
}

html,
body {
    overflow: hidden;
}

.sidebar-wide {
    width: 14rem;
}

.sidebar-item {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

.sidebar-header {
    padding-inline: 1.25rem;
}

.welcome-card {
    margin-left: auto;
    margin-right: auto;
}

.inline-flex {
    display: inline-flex;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.text-primary-foreground {
    color: var(--primary-foreground);
}

.bg-primary-foreground {
    background-color: var(--primary-foreground);
}

.animate-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Empty-state welcome card -------------------------------------------------- */
.welcome-gradient {
    background: linear-gradient(135deg, color-mix(in oklab, var(--primary) 8%, transparent) 0%, var(--background) 100%);
}

.welcome-card {
    width: 100%;
    max-width: 28rem;
    padding: 2.5rem;
    background-color: var(--card, var(--background));
    border: 1px solid var(--border, #e5e5e5);
    border-radius: var(--radius-lg, 0.5rem);
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    text-align: center;
}

/* Status badge pills -------------------------------------------------------- */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1;
}

.status-badge-connecting {
    background-color: var(--muted);
    color: var(--muted-foreground);
}

.status-badge-connected {
    background-color: color-mix(in oklab, var(--color-green-500) 12%, transparent);
    color: color-mix(in oklab, var(--color-green-500) 65%, black);
}

.status-badge-running {
    background-color: color-mix(in oklab, var(--primary) 12%, transparent);
    color: var(--primary);
}

.status-badge-error {
    background-color: color-mix(in oklab, var(--destructive) 12%, transparent);
    color: var(--destructive);
}

.status-badge-dot {
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 9999px;
    background-color: currentColor;
}

.status-badge-ping {
    position: absolute;
    display: inline-flex;
    width: 100%;
    height: 100%;
    border-radius: 9999px;
    background-color: currentColor;
    opacity: 0.75;
    animation: ping 1.5s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes ping {
    75%, 100% {
        transform: scale(2);
        opacity: 0;
    }
}
