:root {
    --bg: #0f1216;
    --panel: #171b21;
    --border: #2a2f37;
    --text: #e6e9ef;
    --muted: #8b93a1;
    --accent: #4f8cff;
    --danger: #e0554f;
    --success: #3fb27f;
    --warning: #d6a44b;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
}

.topnav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--panel);
    border-bottom: 1px solid var(--border);
}

.topnav a { color: var(--text); text-decoration: none; }
.topnav .brand { font-weight: 700; margin-right: auto; }
.topnav .logout { color: var(--muted); }

.container { max-width: 1000px; margin: 0 auto; padding: 1.5rem; }

.login-container { max-width: 360px; margin-top: 4rem; text-align: center; }

.page-header { display: flex; justify-content: space-between; align-items: center; }

.card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.25rem;
    margin: 1rem 0;
}

.form-grid { display: grid; grid-template-columns: 1fr; gap: 0.35rem 0.75rem; }
.form-grid label { margin-top: 0.5rem; font-size: 0.85rem; color: var(--muted); }
.form-grid input, .form-grid textarea, .form-grid select {
    background: #0d1015; color: var(--text); border: 1px solid var(--border);
    border-radius: 6px; padding: 0.5rem; font-size: 0.95rem;
}
.form-grid button { margin-top: 0.75rem; }

.inline-form { display: inline-flex; gap: 0.5rem; align-items: center; margin: 0.35rem 0; }
.eligibility-form { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: end; margin: 0.5rem 0; }
.eligibility-form label { display: flex; flex-direction: column; font-size: 0.8rem; color: var(--muted); gap: 0.2rem; }

button, .button {
    background: var(--accent); color: white; border: none; border-radius: 6px;
    padding: 0.5rem 0.9rem; cursor: pointer; font-size: 0.9rem; text-decoration: none; display: inline-block;
}
button.danger { background: var(--danger); }

.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: left; padding: 0.5rem; border-bottom: 1px solid var(--border); }

.flash { padding: 0.75rem 1rem; border-radius: 8px; margin-bottom: 1rem; }
.flash-success { background: rgba(63, 178, 127, 0.15); border: 1px solid var(--success); }
.flash-error { background: rgba(224, 85, 79, 0.15); border: 1px solid var(--danger); }

.muted { color: var(--muted); }
.small { font-size: 0.8rem; }
.empty-state { color: var(--muted); font-style: italic; }

.badge {
    display: inline-block; padding: 0.15rem 0.5rem; border-radius: 999px;
    background: #2a2f37; font-size: 0.75rem; text-transform: uppercase;
}
.badge-warning { background: rgba(214, 164, 75, 0.25); color: var(--warning); }
.badge-success { background: rgba(63, 178, 127, 0.25); color: var(--success); }
.badge-unwanted, .badge-negative { background: rgba(224, 85, 79, 0.25); color: var(--danger); }
.badge-resolved, .badge-positive { background: rgba(63, 178, 127, 0.25); color: var(--success); }

.action-bar { display: flex; gap: 0.75rem; margin: 1rem 0; }

.mention { border-top: 1px solid var(--border); padding: 0.75rem 0; }
.mention-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.snippet { color: var(--muted); font-size: 0.9rem; }
.classification { background: #0d1015; border-radius: 8px; padding: 0.6rem; margin-top: 0.5rem; }
.action-row { background: #0d1015; border-radius: 8px; padding: 0.6rem; margin-top: 0.5rem; }

.code-block {
    background: #0d1015; border: 1px solid var(--border); border-radius: 6px;
    padding: 0.75rem; white-space: pre-wrap; word-break: break-word; font-size: 0.85rem;
}

.subnav { display: flex; gap: 1rem; margin-bottom: 1rem; }
.subnav a { color: var(--accent); text-decoration: none; }

.row-actions { display: flex; gap: 0.5rem; }
.quota-card { font-size: 0.9rem; }

.checklist-card { border-color: var(--accent); }
.checklist { list-style: none; padding: 0; margin: 0.5rem 0 0; display: flex; flex-direction: column; gap: 0.5rem; }
.checklist li { display: flex; align-items: flex-start; gap: 0.5rem; }

.priority-row {
    display: flex; align-items: center; gap: 0.75rem; padding: 0.5rem 0;
    border-bottom: 1px solid var(--border); list-style: none;
}
.priority-row .row-actions { margin-left: auto; }

.walkthrough { padding-left: 1.25rem; display: flex; flex-direction: column; gap: 0.4rem; }
.walkthrough li { padding-left: 0.25rem; }

.provider-status { margin: 0.5rem 0; }

.provider-box {
    border: 1px solid var(--border); border-radius: 8px; padding: 0.9rem;
    margin: 0.75rem 0; background: #0d1015;
}
.provider-box-head { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.provider-box-head h3 { margin: 0; display: flex; align-items: center; gap: 0.5rem; font-size: 1rem; }
.provider-box-disabled { opacity: 0.6; }
