:root {
    --bg-main: #1e1e1e;
    --bg-panel: #252526;
    --bg-input: #3c3c3c;
    --border-color: #454545;
    --text-main: #cccccc;
    --text-muted: #858585;
    --accent: #007acc;
    --accent-hover: #0098ff;
    --success: #0e639c;
    --danger: #f14c4c;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 14px;
    padding: 1.5rem;
}

.container { max-width: 1350px; margin: 0 auto; }

header {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

header h1 {
    font-size: 1.4rem;
    color: #ffffff;
    font-weight: 600;
}

header p { color: var(--text-muted); font-size: 0.85rem; margin-top: 0.2rem; }

main {
    display: grid;
    grid-template-columns: 5.5fr 4.5fr; 
    gap: 1.5rem;
}

.panel {
    background: var(--bg-panel);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
}

.section-header h2 {
    font-size: 1.05rem;
    color: #ffffff;
    margin-bottom: 1rem;
    font-weight: 500;
}

.controls {
    display: flex;
    gap: 0.6rem;
    margin-bottom: 1rem;
    align-items: flex-end;
}

.add-process-box {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.6rem;
    margin-bottom: 1rem;
    align-items: flex-end;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    flex: 1;
}

label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

input, select {
    background: var(--bg-input);
    color: var(--text-main);
    border: 1px solid transparent;
    padding: 0.45rem 0.6rem;
    border-radius: 3px;
    font-family: 'Fira Code', monospace;
    font-size: 0.85rem;
    outline: none;
    transition: border 0.2s;
}

input:focus, select:focus { border: 1px solid var(--accent); }

.btn {
    padding: 0.45rem 0.8rem;
    border-radius: 3px;
    font-weight: 500;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.15s ease;
    font-family: 'Inter', sans-serif;
}

.btn-outline {
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    white-space: nowrap;
}

.add-process-box .btn-outline {
    width: 100%;
    height: 32px;
    padding: 0;
}

.btn-outline:hover {
    background: var(--accent);
    color: #ffffff;
}

.btn-primary {
    background: var(--success);
    color: white;
    border: none;
    width: 100%;
    margin-top: auto;
    padding: 0.65rem;
    font-size: 0.95rem;
}

.btn-primary:hover { background: #1177bb; }

.action-buttons {
    display: flex;
    gap: 0.8rem;
    margin-top: auto;
}

.action-buttons .btn-primary {
    flex: 3; 
    margin-top: 0;
}

.btn-danger {
    flex: 1;
    background: transparent;
    color: var(--danger);
    border: 1px solid var(--danger);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-danger:hover {
    background: var(--danger);
    color: #ffffff;
}

.table-container {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    min-height: 120px;
    max-height: 200px;
    overflow-y: auto;
    margin-bottom: 1rem;
}

table { width: 100%; border-collapse: collapse; text-align: left; }

th {
    background: var(--bg-panel);
    color: var(--text-muted);
    font-size: 0.75rem;
    padding: 0.5rem 0.6rem;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
}

td {
    padding: 0.45rem 0.6rem;
    border-bottom: 1px solid var(--border-color);
    font-family: 'Fira Code', monospace;
    font-size: 0.85rem;
}

tr:last-child td { border-bottom: none; }

.empty-message {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 1.5rem !important;
}

.gantt-wrapper { margin-bottom: 1rem; }

.gantt-container {
    background: transparent;
    min-height: 70px;
    display: block; 
    padding: 0.5rem 0;
}

.placeholder-text { color: var(--text-muted); font-size: 0.8rem; }

.subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.metrics-container { display: flex; gap: 0.6rem; }

.metric-card {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    padding: 0.8rem;
    border-radius: 3px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.metric-label { font-size: 0.7rem; color: var(--text-muted); text-transform: uppercase; }
.metric-value { font-size: 1.3rem; color: #ffffff; font-family: 'Fira Code', monospace; }
.metric-value small { font-size: 0.75rem; color: var(--text-muted); }

.hidden { display: none !important; }

.delete-btn {
    background: transparent;
    color: var(--danger);
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
}

.delete-btn:hover { color: #ff7b7b; }