/* Extra app styles beyond pico.css */
.htmx-indicator {
    opacity: 0;
    transition: opacity 200ms ease-in;
}
.htmx-request .htmx-indicator, .htmx-request.htmx-indicator {
    opacity: 1;
}

/* Inline styles moved from layout <style> */
:root { --pico-font-size: 15px; }
nav { margin-bottom: 1rem; }
.position-pour { color: var(--pico-color-green-500, #22c55e); font-weight: bold; }
.position-contre { color: var(--pico-color-red-500, #ef4444); font-weight: bold; }
.position-abstention { color: var(--pico-color-yellow-500, #eab308); font-weight: bold; }
.position-nonVotant { color: var(--pico-muted-color); }
.discipline-high { color: var(--pico-color-green-500, #22c55e); font-weight: bold; }
.discipline-medium { color: var(--pico-color-yellow-500, #eab308); font-weight: bold; }
.discipline-low { color: var(--pico-color-red-500, #ef4444); font-weight: bold; }
.dissent { color: var(--pico-color-red-500, #ef4444); }
tr.dissident { background: rgba(239, 68, 68, 0.1); }
.sort-adopté { color: var(--pico-color-green-500, #22c55e); }
.sort-rejeté { color: var(--pico-color-red-500, #ef4444); }
.stats { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.stats > div { padding: 0.5rem 1rem; border-radius: 0.25rem; background: var(--pico-card-background-color); }
.stats strong { font-size: 1.2em; }
.tab-group { display: flex; gap: 0.5rem; margin-bottom: 1rem; }
.tab-group button { cursor: pointer; }
.tab-group button[aria-selected="true"] { font-weight: bold; }
table { font-size: 0.9em; }
small { color: var(--pico-muted-color); }

/* Chart containers — match table width */
.chart-container { position: relative; width: 100%; margin-bottom: 1rem; }
.chart-container-sm { max-width: 300px; }
.charts-row { display: flex; gap: 2rem; flex-wrap: wrap; align-items: flex-start; margin-bottom: 1rem; }
.charts-row .chart-container-sm { max-width: none; }
.charts-row .chart-container-sm:first-child { flex: 0 0 280px; }
.charts-row .chart-container-sm:last-child { flex: 1; min-width: 300px; }
.chart-subtitle { font-size: 0.85em; color: var(--pico-muted-color); margin: 0 0 0.5rem 0; }

/* Low discipline row highlighting */
tr.low-discipline-row { background: rgba(239, 68, 68, 0.08); }
tr.low-discipline-row:hover { background: rgba(239, 68, 68, 0.15); }

/* Filter button */
.filter-low-discipline { font-size: 0.8em; padding: 0.3em 0.8em; margin-left: 0.5rem; vertical-align: middle; }
.filter-low-discipline.active { background: var(--pico-color-red-500, #ef4444); border-color: var(--pico-color-red-500, #ef4444); color: #fff; }

/* Legislature toggle */
.leg-toggle { font-weight: bold; opacity: 0.5; }
.leg-toggle.active { opacity: 1; }

/* Sortable table headers */
th.sort { cursor: pointer; user-select: none; }
th.sort:hover { text-decoration: underline; }
th.sort.asc::after { content: ' ▲'; font-size: 0.7em; }
th.sort.desc::after { content: ' ▼'; font-size: 0.7em; }

/* List.js search controls */
.list-controls { margin-bottom: 0.5rem; }
.list-controls input.search { max-width: 300px; }

/* Overridden position (consigne contredite) */
tr.overridden-row { background: rgba(249, 115, 22, 0.12); }
tr.overridden-row:hover { background: rgba(249, 115, 22, 0.2); }
.badge-overridden {
    display: inline-block; background: #f97316; color: #fff;
    font-size: 0.7em; font-weight: bold; padding: 0.1em 0.4em;
    border-radius: 0.25em; vertical-align: middle; margin-left: 0.3em;
}
