:root {
    /* Light theme */
    --primary: #3498db;
    --secondary: #2e7d32;
    --accent: #ffc107;
    --bg: #f8f9fa;
    --surface: #ffffff;
    --text: #212529;
    --text2: #6c757d;
    --border: #ced4da;
    --success: #28a745;
    --warning: #ffc107;
    --error: #dc3545;

    --font: "Segoe UI", system-ui, sans-serif;
    --font-mono: "Consolas", "Fira Code", monospace;
}

body.dark {
    --primary: #64b5f6;
    --secondary: #66bb6a;
    --accent: #ffd54f;
    --bg: #121212;
    --surface: #252525;
    --text: #ffffff;
    --text2: #bdbdbd;
    --border: #444;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

header {
    padding: 1.2rem 2rem;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

h1 { margin: 0; color: var(--primary); font-size: 1.6rem; }
.subtitle { margin: .2rem 0 0; color: var(--text2); }

main {
    flex: 1;
    padding: 1.5rem 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
    gap: 1.5rem;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 1rem 1.2rem;
    display: flex;
    flex-direction: column;
    gap: .8rem;
}

.card.wide { grid-column: 1 / -1; }

label {
    display: flex;
    flex-direction: column;
    font-size: .9rem;
    gap: .3rem;
}

input[type=text], select, textarea {
    padding: .4rem .6rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: var(--surface);
    color: var(--text);
    font-family: var(--font);
}

textarea {
    font-family: var(--font-mono);
    min-height: 250px;
    resize: vertical;
}

.checks {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.btn {
    padding: .45rem .9rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: .9rem;
    transition: background .2s;
}

.btn.primary   { background: var(--primary); color: #fff; }
.btn.success   { background: var(--success); color: #fff; }
.btn.warning   { background: var(--warning); color: var(--text); }
.btn.browse    { background: var(--warning); color: var(--text); }
.btn.small     { padding: .3rem .6rem; }

.actions {
    display: flex;
    gap: .6rem;
    flex-wrap: wrap;
    margin-top: .5rem;
}

ul {
    margin: 0;
    padding-left: 1.2rem;
    font-size: .85rem;
    color: var(--text2);
}

footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: .5rem 2rem;
    font-size: .8rem;
    color: var(--text2);
}