:root {
    --bg-dark: #0f172a;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --primary: #3b82f6;
    --primary-glow: rgba(59, 130, 246, 0.5);
    --success: #10b981;
    --danger: #ef4444;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Background Blobs for Glassmorphism */
.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.6;
    animation: float 10s infinite alternate ease-in-out;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
}

.blob-2 {
    bottom: -10%;
    right: -10%;
    width: 40vw;
    height: 40vw;
    background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
    animation-delay: -5s;
}

@keyframes float {
    0% { transform: translate(0, 0); }
    100% { transform: translate(5%, 5%); }
}

/* Glassmorphism Classes */
.glass-header {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Header */
.logo-area {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.brand-icon {
    font-size: 2rem;
    color: var(--primary);
    text-shadow: 0 0 10px var(--primary-glow);
}

h1 {
    font-weight: 800;
    font-size: 1.5rem;
}

h1 span {
    color: var(--primary);
}

.badge {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    padding: 0.5rem 1rem;
    border-radius: 99px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

/* Main Layout */
.container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
}

/* Typography & Forms */
h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

h2 i {
    color: var(--primary);
}

.subtitle {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
}

input, textarea {
    width: 100%;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text-main);
    padding: 0.75rem 1rem;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-glow);
}

.quick-fills {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.pill-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    padding: 0.4rem 0.8rem;
    border-radius: 99px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pill-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
}

.primary-btn {
    width: 100%;
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px 0 var(--primary-glow);
}

.primary-btn:hover {
    background: #2563eb;
    transform: translateY(-2px);
}

/* Workflow Visualizer */
.workflow-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 2rem;
}

.step {
    display: flex;
    gap: 1.5rem;
    opacity: 0.5;
    transition: all 0.5s ease;
}

.step.active {
    opacity: 1;
}

.step-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--text-muted);
    transition: all 0.5s ease;
    z-index: 2;
}

.step.active .step-icon {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: 0 0 20px var(--primary-glow);
}

.step-content {
    flex: 1;
    padding-bottom: 1rem;
}

.step-content h3 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.status-text {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.status-text.processing {
    color: #f59e0b;
    animation: pulse 1.5s infinite;
}

.status-text.success { color: var(--success); }
.status-text.error { color: var(--danger); }

.connector {
    width: 2px;
    height: 30px;
    background: var(--glass-border);
    margin-left: 23px; /* Align with center of 48px icon */
    margin-top: -10px;
    margin-bottom: -10px;
    transition: all 0.5s ease;
    z-index: 1;
}

.connector.active {
    background: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

/* dynamic outputs */
.json-output {
    margin-top: 1rem;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    padding: 1rem;
    font-family: monospace;
    font-size: 0.85rem;
    color: #10b981;
    border: 1px solid var(--glass-border);
}

.action-card {
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 1rem;
}

.hidden {
    display: none;
}

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