/* AGENTFORGE STYLES */
:root {
    --bg-primary: #0a0a1a;
    --bg-secondary: #12122a;
    --bg-tertiary: #1a1a3a;
    --aurora-1: #7c3aed;
    --aurora-2: #a855f7;
    --aurora-3: #c084fc;
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --text-muted: #64748b;
    --success: #22c55e;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    font-family: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-primary);
}

.demo-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background: rgba(18, 18, 42, 0.9);
    border-bottom: 1px solid rgba(168, 85, 247, 0.2);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo {
    font-size: 1.5rem;
    color: var(--aurora-2);
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 600;
}

.product-name {
    color: var(--text-muted);
    padding-left: 0.75rem;
    border-left: 1px solid rgba(168, 85, 247, 0.3);
}

.header-actions {
    display: flex;
    gap: 1rem;
}

.btn-primary,
.btn-secondary {
    padding: 0.6rem 1.25rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--aurora-1), var(--aurora-2));
    color: white;
}

.btn-secondary {
    background: transparent;
    border: 1px solid rgba(168, 85, 247, 0.4);
    color: var(--aurora-2);
}

.builder-container {
    display: grid;
    grid-template-columns: 250px 1fr 250px;
    gap: 1rem;
    padding: 1rem;
    height: calc(100vh - 110px);
}

.config-panel,
.library-panel {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid rgba(168, 85, 247, 0.1);
    overflow-y: auto;
}

.panel-section {
    margin-bottom: 1.5rem;
}

.panel-section h3 {
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
    color: var(--text-secondary);
}

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

.form-group label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.6rem;
    background: var(--bg-tertiary);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 6px;
    color: var(--text-primary);
    font-size: 0.85rem;
}

.integrations-list,
.schedule-options {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.integration,
.schedule-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: pointer;
}

.integration .status {
    margin-left: auto;
    color: var(--text-muted);
}

.integration.active .status {
    color: var(--success);
}

.schedule-option.active,
.schedule-option:has(input:checked) {
    border: 1px solid var(--aurora-2);
}

/* Canvas */
.canvas-panel {
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid rgba(168, 85, 247, 0.1);
    display: flex;
    flex-direction: column;
}

.canvas-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(168, 85, 247, 0.1);
}

.canvas-header h3 {
    font-size: 0.9rem;
}

.canvas-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.zoom-btn {
    width: 28px;
    height: 28px;
    background: var(--bg-tertiary);
    border: none;
    border-radius: 6px;
    color: var(--text-primary);
    cursor: pointer;
}

.workflow-canvas {
    flex: 1;
    position: relative;
    background: radial-gradient(circle at 1px 1px, rgba(168, 85, 247, 0.1) 1px, transparent 0);
    background-size: 30px 30px;
    overflow: hidden;
}

.workflow-connections {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.workflow-node {
    position: absolute;
    background: var(--bg-tertiary);
    border: 2px solid;
    border-radius: 10px;
    padding: 0.75rem;
    min-width: 160px;
    cursor: move;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.workflow-node.trigger {
    border-color: #22c55e;
}

.workflow-node.action {
    border-color: var(--aurora-2);
}

.workflow-node.condition {
    border-color: #f59e0b;
}

.workflow-node.human {
    border-color: #06b6d4;
}

.node-icon {
    font-size: 1.25rem;
}

.node-type {
    font-size: 0.65rem;
    color: var(--text-muted);
    display: block;
}

.node-name {
    font-size: 0.8rem;
    font-weight: 500;
}

.add-node-btn {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--aurora-1), var(--aurora-2));
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-weight: 500;
}

/* Library */
.node-library {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.library-node {
    padding: 0.6rem 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: grab;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 1px dashed rgba(168, 85, 247, 0.3);
}

.library-node:hover {
    border-color: var(--aurora-2);
    background: rgba(168, 85, 247, 0.1);
}

.stats-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(168, 85, 247, 0.1);
}

.stat-value {
    color: var(--aurora-3);
    font-weight: 600;
}

.demo-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.75rem;
    background: linear-gradient(135deg, var(--aurora-1), var(--aurora-2));
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.demo-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
}