:root {
    --bg: #1e1e2e;
    --surface: #313244;
    --border: #45475a;
    --text: #cdd6f4;
    --text-dim: #a6adc8;
    --accent: #89b4fa;
    --green: #a6e3a1;
    --red: #f38ba8;
    --yellow: #f9e2af;
    --purple: #cba6f7;
    --mono: 'JetBrains Mono', 'Fira Code', monospace;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    gap: 2rem;
}

header h1 {
    font-size: 1.5rem;
    color: var(--accent);
}

#repo-select {
    background: var(--bg);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    min-width: 200px;
}

main {
    flex: 1;
    padding: 2rem;
    display: grid;
    grid-template-columns: 250px 1fr 1fr;
    gap: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1rem;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
}

.panel h2 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-dim);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

#branch-list {
    list-style: none;
}

#branch-list li {
    padding: 0.4rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    font-family: var(--mono);
    font-size: 0.85rem;
    color: var(--accent);
    transition: background 0.15s;
}

#branch-list li:hover {
    background: rgba(137, 180, 250, 0.1);
}

#branch-list li.active {
    background: rgba(137, 180, 250, 0.2);
}

.commit-entry {
    padding: 0.6rem;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s;
}

.commit-entry:hover {
    background: rgba(137, 180, 250, 0.1);
}

.commit-entry .hash {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--yellow);
}

.commit-entry .message {
    font-size: 0.9rem;
    margin-top: 0.2rem;
}

.commit-entry .meta {
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 0.2rem;
}

#commit-detail .field {
    margin-bottom: 0.8rem;
}

#commit-detail .field-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-dim);
    letter-spacing: 0.05em;
}

#commit-detail .field-value {
    font-family: var(--mono);
    font-size: 0.85rem;
    color: var(--green);
}

footer {
    text-align: center;
    padding: 1rem;
    color: var(--text-dim);
    font-size: 0.8rem;
    border-top: 1px solid var(--border);
}

.hidden { display: none !important; }

#empty-state {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--text-dim);
    padding: 4rem;
}

#empty-state p {
    font-size: 1.2rem;
}

@media (max-width: 900px) {
    main {
        grid-template-columns: 1fr;
    }
}
