@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --font-primary: 'Plus Jakarta Sans', sans-serif;
    --bg-light: #f8fafc;
    --card-bg: #ffffff;
    --border-light: #e2e8f0;
    --text-dark: #0f172a;
    --text-muted: #475569;
    --primary: #4f46e5;
    --primary-hover: #4338ca;
}

body {
    font-family: var(--font-primary);
    background-color: #f8fafc;
    color: var(--text-dark);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Background Clean Gradient */
.bg-mesh {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    background: linear-gradient(135deg, #eef2ff 0%, #f8fafc 50%, #e0e7ff 100%);
}

/* Crisp Sharp Cards (NO BLUR, NO WASHED OUT EFFECTS) */
.glass-panel {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 1.25rem;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.glass-input {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    color: #0f172a;
    font-weight: 500;
    transition: all 0.15s ease-in-out;
}

.glass-input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
    outline: none;
}

/* Buttons & Clickable Elements Hover Fixes */
button, a {
    cursor: pointer;
    user-select: none;
    transition: all 0.15s ease-in-out;
}

button:hover, a:hover {
    transform: translateY(-1px);
}

button:active, a:active {
    transform: translateY(0);
}

/* High Contrast Solid Badges */
.badge-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
    font-weight: 700;
}

.badge-failed {
    background: #ffe4e6;
    color: #9f1239;
    border: 1px solid #fca5a5;
    font-weight: 700;
}

.badge-running {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
    font-weight: 700;
    animation: pulse 1.5s infinite;
}

.badge-idle {
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
    font-weight: 700;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.65; }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Live dot indicator */
.dot-live {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background-color: #10b981;
    box-shadow: 0 0 6px #10b981;
}

/* Table Row Hover */
tr.hover-row:hover {
    background-color: #f1f5f9;
}

/* DOM TOAST CONTAINER & ANIMATIONS */
#toast-container {
    position: fixed;
    top: 1.25rem;
    right: 1.25rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-width: 24rem;
    width: calc(100vw - 2.5rem);
    pointer-events: none;
}

.dom-toast {
    pointer-events: auto;
    display: flex;
    items-center: center;
    gap: 0.75rem;
    padding: 0.875rem 1.125rem;
    border-radius: 1rem;
    background: #ffffff;
    box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.15);
    border: 1px solid #e2e8f0;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #0f172a;
    animation: toastIn 0.3s ease forwards;
    transition: all 0.2s ease;
}

.dom-toast.success {
    border-left: 4px solid #10b981;
}

.dom-toast.error {
    border-left: 4px solid #f43f5e;
}

.dom-toast.warning {
    border-left: 4px solid #f59e0b;
}

.dom-toast.info {
    border-left: 4px solid #4f46e5;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Mobile responsive fixes */
@media (max-width: 640px) {
    .glass-panel {
        border-radius: 1rem;
        padding: 0.875rem !important;
    }
}
