﻿/* Linear Design System - CSS Foundation */
/* wwwroot/css/linear-design-system.css */

:root, html {
    color-scheme: dark;
    /* === LINEAR COLOR PALETTE === */
    /* Backgrounds */
    --linear-bg: #0d1117;
    --linear-bg-subtle: #161b22;
    --linear-bg-muted: #21262d;
    --linear-bg-emphasis: #30363d;
    /* Borders */
    --linear-border: #30363d;
    --linear-border-muted: #21262d;
    --linear-border-subtle: #484f58;
    /* Text Colors */
    --linear-text: #f0f6fc;
    --linear-text-muted: #8b949e;
    --linear-text-subtle: #6e7681;
    --linear-text-placeholder: #6e7681;
    /* Accent Colors - Techy Lime Green Theme */
    --linear-accent: #daef51;
    --linear-accent-emphasis: #e8f472;
    --linear-accent-muted: rgba(218, 239, 81, 0.15);
    --linear-accent-subtle: rgba(218, 239, 81, 0.05);
    /* Status Colors - Using lime green for success */
    --linear-success: #daef51;
    --linear-success-emphasis: #e8f472;
    --linear-success-muted: rgba(218, 239, 81, 0.15);
    --linear-danger: #da3633;
    --linear-danger-emphasis: #f85149;
    --linear-danger-muted: rgba(218, 54, 51, 0.15);
    --linear-warning: #d29922;
    --linear-warning-emphasis: #f0c53f;
    --linear-warning-muted: rgba(210, 153, 34, 0.15);
    --linear-info: #58a6ff;
    --linear-info-emphasis: #79c0ff;
    --linear-info-muted: rgba(88, 166, 255, 0.15);
    /* === LINEAR TYPOGRAPHY SCALE === */
    --linear-text-xs: 12px;
    --linear-text-sm: 14px;
    --linear-text-base: 16px;
    --linear-text-lg: 18px;
    --linear-text-xl: 20px;
    --linear-text-2xl: 24px;
    --linear-text-3xl: 32px;
    /* Font Weights */
    --linear-font-light: 300;
    --linear-font-normal: 400;
    --linear-font-medium: 500;
    --linear-font-semibold: 600;
    --linear-font-bold: 700;
    /* Line Heights */
    --linear-leading-tight: 1.25;
    --linear-leading-snug: 1.33;
    --linear-leading-normal: 1.5;
    --linear-leading-relaxed: 1.625;
    /* === LINEAR SPACING SCALE (8px base unit) === */
    --linear-space-0: 0;
    --linear-space-px: 1px;
    --linear-space-0-5: 2px;
    --linear-space-1: 4px;
    --linear-space-1-5: 6px;
    --linear-space-2: 8px;
    --linear-space-2-5: 10px;
    --linear-space-3: 12px;
    --linear-space-3-5: 14px;
    --linear-space-4: 16px;
    --linear-space-5: 20px;
    --linear-space-6: 24px;
    --linear-space-7: 28px;
    --linear-space-8: 32px;
    --linear-space-9: 36px;
    --linear-space-10: 40px;
    --linear-space-11: 44px;
    --linear-space-12: 48px;
    --linear-space-14: 56px;
    --linear-space-16: 64px;
    --linear-space-20: 80px;
    --linear-space-24: 96px;
    /* === LINEAR BORDER RADIUS === */
    --linear-radius-none: 0;
    --linear-radius-sm: 4px;
    --linear-radius: 6px;
    --linear-radius-md: 8px;
    --linear-radius-lg: 12px;
    --linear-radius-xl: 16px;
    --linear-radius-2xl: 20px;
    --linear-radius-full: 9999px;
    /* === LINEAR SHADOWS === */
    --linear-shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.5);
    --linear-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.5);
    --linear-shadow: 0 1px 3px rgba(0, 0, 0, 0.5), 0 1px 2px rgba(0, 0, 0, 0.5);
    --linear-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.5), 0 2px 4px rgba(0, 0, 0, 0.5);
    --linear-shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5), 0 4px 6px rgba(0, 0, 0, 0.5);
    --linear-shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.5), 0 10px 10px rgba(0, 0, 0, 0.5);
    --linear-shadow-2xl: 0 25px 50px rgba(0, 0, 0, 0.5);
    /* Focus Ring */
    --linear-focus-ring: 0 0 0 3px var(--linear-accent-muted);
    --linear-focus-ring-danger: 0 0 0 3px var(--linear-danger-muted);
    /* === LINEAR ANIMATIONS === */
    --linear-transition-fast: all 0.1s cubic-bezier(0.4, 0, 0.2, 1);
    --linear-transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --linear-transition-slow: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    /* Easing curves */
    --linear-ease-in: cubic-bezier(0.4, 0, 1, 1);
    --linear-ease-out: cubic-bezier(0, 0, 0.2, 1);
    --linear-ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
    /* Missing select styling variables */
    --linear-bg-secondary: #161b22;
    --linear-text-secondary: #8b949e;
    --linear-select-bg: #21262d;
    --linear-select-text: #f0f6fc;
    --linear-select-border: #30363d;
    --linear-select-hover: #30363d;
    /* Missing background variations for alerts/success/danger */
    --linear-success-bg: rgba(218, 239, 81, 0.1);
    --linear-danger-bg: rgba(218, 54, 51, 0.1);
    --linear-warning-bg: rgba(210, 153, 34, 0.1);
    --linear-accent-bg: rgba(218, 239, 81, 0.1);

}

/* Enhanced Linear Select Styling - macOS style dark dropdown */
.linear-app .linear-select {
    width: 100%;
    padding: var(--linear-space-3);
    background: #1a1a1a !important;
    color: #ffffff !important;
    border: 1px solid #404040 !important;
    border-radius: var(--linear-radius);
    font-size: 0.875rem;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .linear-app .linear-select:hover {
        background: #2a2a2a !important;
        border-color: #505050 !important;
    }

    .linear-app .linear-select:focus {
        outline: none !important;
        background: #2a2a2a !important;
        border-color: var(--linear-accent) !important;
        box-shadow: 0 0 0 2px rgba(218, 239, 81, 0.2) !important;
    }

    /* Force dropdown options styling */
    .linear-app .linear-select option {
        background-color: #1a1a1a !important;
        color: #ffffff !important;
        padding: 8px 12px !important;
    }

        .linear-app .linear-select option:hover,
        .linear-app .linear-select option:focus,
        .linear-app .linear-select option:checked {
            background-color: #404040 !important;
            color: #ffffff !important;
        }

    /* Additional browser-specific attempts */
    .linear-app .linear-select optgroup {
        background-color: #1a1a1a !important;
        color: #ffffff !important;
    }

    /* Webkit specific */
    .linear-app .linear-select::-webkit-scrollbar {
        width: 8px;
        background: #1a1a1a;
    }

    .linear-app .linear-select::-webkit-scrollbar-thumb {
        background: #404040;
        border-radius: 4px;
    }


/* === LINEAR BASE STYLES === */
.linear-app {
    background: var(--linear-bg);
    color-scheme: dark;
    color: var(--linear-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    font-size: var(--linear-text-sm);
    line-height: var(--linear-leading-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

    /* Closed control */
    .linear-app .linear-select {
        width: 100%;
        padding: var(--linear-space-3) var(--linear-space-8) var(--linear-space-3) var(--linear-space-4);
        background: var(--linear-select-bg);
        color: var(--linear-select-text);
        border: 1px solid var(--linear-select-border);
        border-radius: var(--linear-radius);
        font-size: var(--linear-text-sm);
        appearance: none;
        -webkit-appearance: none;
        -moz-appearance: none;
        transition: var(--linear-transition); /* was invalid before */
        line-height: 1.2;
        cursor: pointer;
    }

        .linear-app .linear-select:hover {
            background: var(--linear-select-hover);
        }

        .linear-app .linear-select:focus {
            outline: none;
            box-shadow: var(--linear-focus-ring);
            border-color: var(--linear-accent);
        }

        /* Try to style options where allowed */
        .linear-app .linear-select option {
            background: var(--linear-bg-secondary);
            color: var(--linear-text);
        }

/* Button (closed state) */
.ls-root {
    position: relative;
    display: block;
    width: 100%;
}

.ls-btn {
    width: 100%;
    padding: var(--linear-space-3) var(--linear-space-4);
    background: var(--linear-select-bg);
    color: var(--linear-select-text);
    border: 1px solid var(--linear-select-border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    transition: var(--linear-transition);
}

    .ls-btn:hover {
        background: var(--linear-select-hover);
    }

    .ls-btn:focus-visible {
        outline: none;
        box-shadow: var(--linear-focus-ring);
        border-color: var(--linear-accent);
    }

.ls-btn-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ls-btn-caret {
    opacity: .7;
}

/* Popover menu (open state) — matches screenshot */
.ls-popover {
    position: absolute;
    z-index: 1000;
    top: calc(100% + 8px);
    left: 0;
    min-width: 100%;
    background: var(--linear-bg-subtle);
    border: 1px solid var(--linear-border);
    border-radius: 14px;
    box-shadow: var(--linear-shadow-xl);
    padding: 6px;
}

.ls-item {
    list-style: none;
    border-radius: 10px;
}

.ls-option {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--linear-text);
    text-align: left;
    cursor: pointer;
}

    .ls-item.is-active .ls-option,
    .ls-option:hover {
        background: var(--linear-bg-emphasis);
    }

.ls-option-icon {
    opacity: .9;
    width: 16px;
    text-align: center;
}

.ls-kbd {
    opacity: .6;
    font: 12px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}


/* Typography Classes */
.text-linear-xs {
    font-size: var(--linear-text-xs);
}

.text-linear-sm {
    font-size: var(--linear-text-sm);
}

.text-linear-base {
    font-size: var(--linear-text-base);
}

.text-linear-lg {
    font-size: var(--linear-text-lg);
}

.text-linear-xl {
    font-size: var(--linear-text-xl);
}

.text-linear-2xl {
    font-size: var(--linear-text-2xl);
}

.text-linear-3xl {
    font-size: var(--linear-text-3xl);
}

/* Font Weight Classes */
.font-linear-light {
    font-weight: var(--linear-font-light);
}

.font-linear-normal {
    font-weight: var(--linear-font-normal);
}

.font-linear-medium {
    font-weight: var(--linear-font-medium);
}

.font-linear-semibold {
    font-weight: var(--linear-font-semibold);
}

.font-linear-bold {
    font-weight: var(--linear-font-bold);
}

/* Text Color Classes */
.text-linear {
    color: var(--linear-text);
}

.text-linear-muted {
    color: var(--linear-text-muted);
}

.text-linear-subtle {
    color: var(--linear-text-subtle);
}

.text-linear-accent {
    color: var(--linear-accent);
}

.text-linear-success {
    color: var(--linear-success);
}

.text-linear-danger {
    color: var(--linear-danger);
}

.text-linear-warning {
    color: var(--linear-warning);
}

/* Background Color Classes */
.bg-linear {
    background-color: var(--linear-bg);
}

.bg-linear-subtle {
    background-color: var(--linear-bg-subtle);
}

.bg-linear-muted {
    background-color: var(--linear-bg-muted);
}

.bg-linear-accent {
    background-color: var(--linear-accent);
}

/* Border Classes */
.border-linear {
    border-color: var(--linear-border);
}

.border-linear-muted {
    border-color: var(--linear-border-muted);
}

.border-linear-subtle {
    border-color: var(--linear-border-subtle);
}

/* === LINEAR LAYOUT SYSTEM === */
.linear-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--linear-space-6);
}

.linear-grid {
    display: grid;
    gap: var(--linear-space-4);
}

.linear-flex {
    display: flex;
    gap: var(--linear-space-4);
}

.linear-stack {
    display: flex;
    flex-direction: column;
    gap: var(--linear-space-4);
}

/* === LINEAR MAIN LAYOUT === */
.linear-layout {
    display: grid;
    grid-template-areas:
        "sidebar header"
        "sidebar main";
    grid-template-columns: 240px 1fr;
    grid-template-rows: 56px 1fr;
    height: 100vh;
    background: var(--linear-bg);
}

.linear-sidebar {
    grid-area: sidebar;
    background: var(--linear-bg-subtle);
    border-right: 1px solid var(--linear-border);
    display: flex;
    flex-direction: column;
}

.linear-header {
    grid-area: header;
    background: var(--linear-bg);
    border-bottom: 1px solid var(--linear-border);
    display: flex;
    align-items: center;
    padding: 0 var(--linear-space-6);
    z-index: 10;
}

.linear-main {
    grid-area: main;
    background: var(--linear-bg);
    overflow-y: auto;
    padding: var(--linear-space-6);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .linear-layout {
        grid-template-areas:
            "header"
            "main";
        grid-template-columns: 1fr;
        grid-template-rows: 56px 1fr;
    }

    .linear-sidebar {
        display: none; /* Will implement mobile nav later */
    }

    .linear-main {
        padding: var(--linear-space-4);
    }
}

/* === LINEAR UTILITY CLASSES === */
.linear-transition {
    transition: var(--linear-transition);
}

.linear-transition-fast {
    transition: var(--linear-transition-fast);
}

.linear-transition-slow {
    transition: var(--linear-transition-slow);
}

/* Hover effects */
.linear-hover-lift:hover {
    transform: translateY(-1px);
    box-shadow: var(--linear-shadow-md);
}

.linear-hover-bg:hover {
    background: var(--linear-bg-muted);
}

/* Focus styles */
.linear-focus:focus {
    outline: none;
    box-shadow: var(--linear-focus-ring);
}

.linear-focus-danger:focus {
    outline: none;
    box-shadow: var(--linear-focus-ring-danger);
}

/* === LINEAR SCROLLBARS === */
.linear-scrollbar::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.linear-scrollbar::-webkit-scrollbar-track {
    background: var(--linear-bg-subtle);
}

.linear-scrollbar::-webkit-scrollbar-thumb {
    background: var(--linear-border);
    border-radius: var(--linear-radius);
}

    .linear-scrollbar::-webkit-scrollbar-thumb:hover {
        background: var(--linear-border-subtle);
    }

/* Apply to main content area */
.linear-main {
    scrollbar-width: thin;
    scrollbar-color: var(--linear-border) var(--linear-bg-subtle);
}

/* === LOADING ANIMATIONS === */
@keyframes linear-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes linear-pulse {
    0%, 100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

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

.linear-pulse {
    animation: linear-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* === LINEAR SELECTION STYLES === */
::selection {
    background: var(--linear-accent-muted);
    color: var(--linear-text);
}

::-moz-selection {
    background: var(--linear-accent-muted);
    color: var(--linear-text);
}

/* === LINEAR FORM FOCUS STYLES === */
.linear-form-element:focus-within {
    border-color: var(--linear-accent);
    box-shadow: var(--linear-focus-ring);
}

/* === LINEAR BUTTON COMPONENT STYLES === */
.linear-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: inherit;
    font-weight: var(--linear-font-medium);
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--linear-transition);
    white-space: nowrap;
    user-select: none;
    outline: none;
    /* Remove default button styles */
    background: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

    .linear-button:disabled {
        opacity: 0.5;
        cursor: not-allowed;
        transform: none !important;
    }

    .linear-button:not(:disabled):hover {
        transform: translateY(-1px);
    }

    .linear-button:not(:disabled):active {
        transform: translateY(0);
        transition-duration: 0.05s;
    }

    .linear-button:focus-visible {
        box-shadow: var(--linear-focus-ring);
    }

/* Button Content */
.linear-button-content {
    display: inline-block;
}

/* Icons */
.linear-button-icon-left {
    margin-right: var(--linear-space-2);
}

.linear-button-icon-right {
    margin-left: var(--linear-space-2);
}

/* Loading Spinner */
.linear-button-spinner {
    animation: linear-spin 1s linear infinite;
    margin-right: var(--linear-space-2);
    flex-shrink: 0;
}

/* Badge */
.linear-button-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--linear-danger);
    color: white;
    font-size: 10px;
    font-weight: var(--linear-font-semibold);
    padding: 2px 6px;
    border-radius: var(--linear-radius-full);
    min-width: 18px;
    text-align: center;
    line-height: 1.2;
}

/* === BUTTON SIZE VARIANTS === */
.linear-button.size-xs {
    padding: var(--linear-space-1) var(--linear-space-2);
    font-size: var(--linear-text-xs);
    line-height: var(--linear-leading-tight);
    border-radius: var(--linear-radius-sm);
    min-height: 24px;
}

.linear-button.size-sm {
    padding: var(--linear-space-1-5) var(--linear-space-3);
    font-size: var(--linear-text-sm);
    line-height: var(--linear-leading-tight);
    border-radius: var(--linear-radius);
    min-height: 32px;
}

.linear-button.size-md {
    padding: var(--linear-space-2) var(--linear-space-4);
    font-size: var(--linear-text-sm);
    line-height: var(--linear-leading-tight);
    border-radius: var(--linear-radius);
    min-height: 36px;
}

.linear-button.size-lg {
    padding: var(--linear-space-3) var(--linear-space-6);
    font-size: var(--linear-text-base);
    line-height: var(--linear-leading-tight);
    border-radius: var(--linear-radius-md);
    min-height: 44px;
}

.linear-button.size-xl {
    padding: var(--linear-space-4) var(--linear-space-8);
    font-size: var(--linear-text-lg);
    line-height: var(--linear-leading-tight);
    border-radius: var(--linear-radius-md);
    min-height: 52px;
}

/* === BUTTON VARIANT STYLES === */
.linear-button.variant-primary {
    background: var(--linear-accent);
    color: black;
    border-color: var(--linear-accent);
}

    .linear-button.variant-primary:not(:disabled):hover {
        background: var(--linear-accent-emphasis);
        border-color: var(--linear-accent-emphasis);
        box-shadow: var(--linear-shadow-md);
    }

.linear-button.variant-secondary {
    background: var(--linear-bg-muted);
    color: var(--linear-text);
    border-color: var(--linear-border);
}

    .linear-button.variant-secondary:not(:disabled):hover {
        background: var(--linear-bg-emphasis);
        border-color: var(--linear-border-subtle);
        box-shadow: var(--linear-shadow-sm);
    }

.linear-button.variant-ghost {
    background: transparent;
    color: var(--linear-text-muted);
    border-color: transparent;
}

    .linear-button.variant-ghost:not(:disabled):hover {
        background: var(--linear-bg-muted);
        color: var(--linear-text);
    }

.linear-button.variant-outline {
    background: transparent;
    color: var(--linear-text);
    border-color: var(--linear-border);
}

    .linear-button.variant-outline:not(:disabled):hover {
        background: var(--linear-bg-muted);
        border-color: var(--linear-border-subtle);
    }

.linear-button.variant-danger {
    background: var(--linear-danger);
    color: white;
    border-color: var(--linear-danger);
}

    .linear-button.variant-danger:not(:disabled):hover {
        background: var(--linear-danger-emphasis);
        border-color: var(--linear-danger-emphasis);
        box-shadow: var(--linear-shadow-md);
    }

.linear-button.variant-success {
    background: var(--linear-success);
    color: black;
    border-color: var(--linear-success);
}

    .linear-button.variant-success:not(:disabled):hover {
        background: var(--linear-success-emphasis);
        border-color: var(--linear-success-emphasis);
        box-shadow: var(--linear-shadow-md);
    }

.linear-button.variant-warning {
    background: var(--linear-warning);
    color: var(--linear-bg);
    border-color: var(--linear-warning);
}

    .linear-button.variant-warning:not(:disabled):hover {
        background: var(--linear-warning-emphasis);
        border-color: var(--linear-warning-emphasis);
        box-shadow: var(--linear-shadow-md);
    }

.linear-button.variant-link {
    background: transparent;
    color: var(--linear-accent);
    border-color: transparent;
    text-decoration: underline;
    text-underline-offset: 2px;
}

    .linear-button.variant-link:not(:disabled):hover {
        color: var(--linear-accent-emphasis);
        text-decoration: none;
        transform: none;
    }

/* Button Special States */
.linear-button.full-width {
    width: 100%;
}

.linear-button.icon-only {
    padding: var(--linear-space-2);
    aspect-ratio: 1;
}

    .linear-button.icon-only.size-xs {
        padding: var(--linear-space-1);
        min-height: 24px;
        width: 24px;
    }

    .linear-button.icon-only.size-sm {
        padding: var(--linear-space-1-5);
        min-height: 32px;
        width: 32px;
    }

    .linear-button.icon-only.size-md {
        padding: var(--linear-space-2);
        min-height: 36px;
        width: 36px;
    }

    .linear-button.icon-only.size-lg {
        padding: var(--linear-space-3);
        min-height: 44px;
        width: 44px;
    }

    .linear-button.icon-only.size-xl {
        padding: var(--linear-space-4);
        min-height: 52px;
        width: 52px;
    }

/* === LINEAR CARD COMPONENT STYLES === */
.linear-card {
    background: var(--linear-bg-subtle);
    border: 1px solid var(--linear-border);
    border-radius: var(--linear-radius-md);
    transition: var(--linear-transition);
    overflow: hidden;
    position: relative;
}

    .linear-card.interactive {
        cursor: pointer;
    }

        .linear-card.interactive:hover {
            border-color: var(--linear-border-subtle);
            box-shadow: var(--linear-shadow-md);
            transform: translateY(-1px);
        }

        .linear-card.interactive:active {
            transform: translateY(0);
            transition-duration: 0.05s;
        }

        .linear-card.interactive:focus-visible {
            outline: none;
            box-shadow: var(--linear-focus-ring);
        }

/* Card Header */
.linear-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--linear-space-4);
    padding: var(--linear-space-6);
    border-bottom: 1px solid var(--linear-border);
    background: var(--linear-bg-subtle);
}

.linear-card-header-content {
    flex: 1;
    min-width: 0;
}

.linear-card-title {
    font-size: var(--linear-text-lg);
    font-weight: var(--linear-font-semibold);
    color: var(--linear-text);
    margin: 0;
    line-height: var(--linear-leading-tight);
}

.linear-card-description {
    font-size: var(--linear-text-sm);
    color: var(--linear-text-muted);
    margin: var(--linear-space-1) 0 0 0;
    line-height: var(--linear-leading-normal);
}

.linear-card-header-custom {
    margin-top: var(--linear-space-2);
}

.linear-card-header-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: var(--linear-space-2);
}

/* Card Content */
.linear-card-content {
    padding: var(--linear-space-6);
}

/* Card Footer */
.linear-card-footer {
    padding: var(--linear-space-4) var(--linear-space-6);
    border-top: 1px solid var(--linear-border);
    background: var(--linear-bg-muted);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--linear-space-4);
}

/* Card Size Variants */
.linear-card.size-compact .linear-card-header {
    padding: var(--linear-space-4);
}

.linear-card.size-compact .linear-card-content {
    padding: var(--linear-space-4);
}

.linear-card.size-compact .linear-card-footer {
    padding: var(--linear-space-3) var(--linear-space-4);
}

.linear-card.size-compact .linear-card-title {
    font-size: var(--linear-text-base);
}

.linear-card.size-large .linear-card-header {
    padding: var(--linear-space-8);
}

.linear-card.size-large .linear-card-content {
    padding: var(--linear-space-8);
}

.linear-card.size-large .linear-card-footer {
    padding: var(--linear-space-6) var(--linear-space-8);
}

.linear-card.size-large .linear-card-title {
    font-size: var(--linear-text-xl);
}

/* Card Visual Variants */
.linear-card.variant-elevated {
    box-shadow: var(--linear-shadow);
    border-color: transparent;
}

    .linear-card.variant-elevated.interactive:hover {
        box-shadow: var(--linear-shadow-lg);
    }

.linear-card.variant-outlined {
    background: transparent;
    border-color: var(--linear-border-subtle);
}

    .linear-card.variant-outlined .linear-card-header {
        background: transparent;
    }

    .linear-card.variant-outlined .linear-card-footer {
        background: var(--linear-bg-subtle);
    }

.linear-card.variant-ghost {
    background: transparent;
    border: none;
    box-shadow: none;
}

    .linear-card.variant-ghost .linear-card-header {
        background: transparent;
        border-bottom: 1px solid var(--linear-border);
    }

    .linear-card.variant-ghost .linear-card-footer {
        background: transparent;
        border-top: 1px solid var(--linear-border);
    }

    .linear-card.variant-ghost.interactive:hover {
        background: var(--linear-bg-subtle);
        transform: none;
        box-shadow: none;
    }

/* Card Status Variants */
.linear-card.status-success {
    border-left: 4px solid var(--linear-success);
}

.linear-card.status-danger {
    border-left: 4px solid var(--linear-danger);
}

.linear-card.status-warning {
    border-left: 4px solid var(--linear-warning);
}

.linear-card.status-info {
    border-left: 4px solid var(--linear-info);
}

/* Card Special Layouts */
.linear-card.layout-horizontal {
    display: flex;
    align-items: stretch;
}

    .linear-card.layout-horizontal .linear-card-header {
        border-bottom: none;
        border-right: 1px solid var(--linear-border);
        flex-shrink: 0;
        width: 300px;
    }

    .linear-card.layout-horizontal .linear-card-content {
        flex: 1;
    }

.linear-card.no-padding .linear-card-content {
    padding: 0;
}

.linear-card.flush .linear-card-header {
    padding-bottom: 0;
    border-bottom: none;
}

.linear-card.flush .linear-card-content {
    padding-top: 0;
}

.linear-card.loading {
    pointer-events: none;
    opacity: 0.6;
}

    .linear-card.loading::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--linear-bg-subtle);
        opacity: 0.8;
        display: flex;
        align-items: center;
        justify-content: center;
    }

/* === RESPONSIVE CARD STYLES === */
@media (max-width: 768px) {
    .linear-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--linear-space-3);
    }

    .linear-card-header-actions {
        align-self: stretch;
        justify-content: flex-end;
    }

    .linear-card.layout-horizontal {
        flex-direction: column;
    }

        .linear-card.layout-horizontal .linear-card-header {
            border-right: none;
            border-bottom: 1px solid var(--linear-border);
            width: auto;
        }
}

/* === TECHY NOTIFICATION ANIMATIONS === */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Enhanced techy notification styles */
button:hover {
    opacity: 1 !important;
}

/* ULTRA HIGH SPECIFICITY OVERRIDES FOR BUTTON CONTRAST */
/* Force yellow-green background AND black text for consistent styling */
html body .linear-button.variant-primary,
html body .linear-button.variant-success,
html body .btn-primary,
html body button[style*="#daef51"],
html body .btn[style*="#daef51"],
html body *[style*="background:#daef51"],
html body *[style*="background: #daef51"],
html body *[style*="background-color:#daef51"],
html body *[style*="background-color: #daef51"],
html body [class*="linear-button"][class*="variant-primary"],
html body [class*="linear-button"][class*="variant-success"] {
    background: var(--linear-accent) !important;
    background-color: var(--linear-accent) !important;
    color: #000000 !important;
    text-shadow: none !important;
    border-color: var(--linear-accent) !important;
}

/* Hover, focus, active states */
html body .linear-button.variant-primary:hover,
html body .linear-button.variant-primary:focus,
html body .linear-button.variant-primary:active,
html body .linear-button.variant-success:hover,
html body .linear-button.variant-success:focus,
html body .linear-button.variant-success:active,
html body .btn-primary:hover,
html body .btn-primary:focus,
html body .btn-primary:active {
    background: var(--linear-accent-emphasis) !important;
    background-color: var(--linear-accent-emphasis) !important;
    border-color: var(--linear-accent-emphasis) !important;
    color: #000000 !important;
    text-shadow: none !important;
}

/* Target elements with specific yellow-green background */
html body *[style*="background:#daef51"],
html body *[style*="background: #daef51"],
html body *[style*="background-color:#daef51"],
html body *[style*="background-color: #daef51"] {
    color: #000000 !important;
}

/* Specific override for problematic Linear button variants only */
.linear-button.variant-primary,
.linear-button.variant-success {
    background: var(--linear-accent) !important;
    background-color: var(--linear-accent) !important;
    border-color: var(--linear-accent) !important;
    color: #000000 !important;
    text-shadow: none !important;
}

/* NUCLEAR OPTION - ABSOLUTE MAXIMUM SPECIFICITY */
html body div.linear-app div * .linear-button.variant-primary,
html body div.linear-app div * .linear-button.variant-success,
html body .linear-app .linear-button.variant-primary,
html body .linear-app .linear-button.variant-success,
body .linear-button.variant-primary,
body .linear-button.variant-success,
.linear-button.variant-primary,
.linear-button.variant-success {
    background: var(--linear-accent) !important;
    background-color: var(--linear-accent) !important;
    border-color: var(--linear-accent) !important;
    color: #000000 !important;
    text-shadow: none !important;
}

/* Target by background color specifically */
[style*="background:#daef51"] *,
[style*="background: #daef51"] *,
[style*="background-color:#daef51"] *,
[style*="background-color: #daef51"] * {
    color: #000000 !important;
}

/* Extreme measures - target common button patterns */
button[class*="linear"],
.btn[class*="primary"],
[class*="button"][class*="primary"],
[class*="button"][class*="success"] {
    color: #000000 !important;
}
