/* ============================================================
   Conseil Citoyen — Besançon · composants de production
   Tout via var(--token) (voir tokens.css). Mobile-first, flex-wrap.
   Direction « Outil de vérification » : sombre par défaut, clair en option.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: .1px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}

::selection { background: var(--accent-weak); color: var(--ink); }

a { color: inherit; }

button { font-family: inherit; color: inherit; }

@keyframes dcfade { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }

.boot, .loading-msg {
  max-width: 1320px; margin: 0 auto; padding: 60px 22px; text-align: center;
  color: var(--ink-3); font-family: var(--mono); font-size: 12px;
}

.wrap { max-width: 1320px; margin: 0 auto; }

/* -------------------- Header -------------------- */
.app-header {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-bar { max-width: 1320px; margin: 0 auto; padding: 13px 22px; display: flex; align-items: center; gap: 18px; }
.brand { cursor: pointer; background: none; border: none; display: flex; align-items: center; gap: 11px; flex: 0 0 auto; color: var(--ink); text-align: left; text-decoration: none; }
.brand .logo { width: 26px; height: 26px; border: 1.5px solid var(--accent); border-radius: var(--r1); display: flex; align-items: center; justify-content: center; color: var(--accent); }
.brand .name { font-weight: 700; font-size: 13px; letter-spacing: .2px; line-height: 1.15; }
.brand .tag { font-family: var(--mono); font-size: 10px; color: var(--ink-3); letter-spacing: .4px; text-transform: uppercase; line-height: 1.15; }
.spacer { flex: 1 1 auto; }
.theme-btn {
  cursor: pointer; display: flex; align-items: center; gap: 7px;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2);
  border-radius: var(--r2); padding: 7px 11px; font-family: var(--mono); font-size: 11px; height: 34px;
  transition: border-color var(--dur), color var(--dur);
}
.theme-btn:hover { border-color: var(--line-2); color: var(--ink); }

.header-session { max-width: 1320px; margin: 0 auto; padding: 0 22px 14px; display: flex; align-items: flex-end; gap: 22px; flex-wrap: wrap; }
.session-title-wrap { min-width: 240px; flex: 1 1 auto; }
.kicker { font-family: var(--mono); font-size: 11px; letter-spacing: .5px; text-transform: uppercase; color: var(--ink-3); margin-bottom: 5px; }
h1.session-title { margin: 0; font-size: 25px; font-weight: 700; letter-spacing: -.4px; line-height: 1.1; }
.session-meta { margin-top: 7px; display: flex; align-items: center; gap: 14px; font-family: var(--mono); font-size: 11.5px; color: var(--ink-2); flex-wrap: wrap; }
.session-meta .dot { color: var(--ink-3); }
.session-meta .fc { color: var(--accent-ink); }

.year-picker { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; max-width: 100%; }
.year-row { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.year-label, .archive-label { font-family: var(--mono); font-size: 10px; letter-spacing: .5px; text-transform: uppercase; color: var(--ink-3); }
.archive-label { font-size: 10.5px; text-transform: none; }
.year-seg { display: flex; gap: 3px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r2); padding: 3px; }
.year-seg button { cursor: pointer; border: none; background: transparent; color: var(--ink-2); font-family: var(--mono); font-size: 12px; font-weight: 600; padding: 6px 11px; border-radius: var(--r1); transition: background var(--dur), color var(--dur); }
.year-seg button[aria-selected="true"] { background: var(--accent-weak); color: var(--accent-ink); }
.date-row { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 2px; max-width: 100%; }
.date-pill { cursor: pointer; flex: 0 0 auto; min-width: 48px; padding: 7px 11px; border-radius: var(--r2); text-align: center; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); transition: border-color var(--dur), color var(--dur), background var(--dur); }
.date-pill[aria-selected="true"] { border-color: var(--accent-line); background: var(--accent-weak); color: var(--accent-ink); }
.date-pill .d { font-family: var(--mono); font-size: 12px; font-weight: 600; line-height: 1.1; }
.date-pill .m { font-family: var(--mono); font-size: 9.5px; letter-spacing: .4px; text-transform: uppercase; opacity: .7; line-height: 1.3; }
.date-pill[disabled] { opacity: .4; cursor: default; }

/* -------------------- Banner -------------------- */
.banner-wrap { max-width: 1320px; margin: 0 auto; padding: 16px 22px 0; }
.banner { display: flex; align-items: flex-start; gap: 12px; background: var(--accent-weak); border: 1px solid var(--accent-line); border-radius: var(--r2); padding: 13px 15px; }
.banner svg { flex: 0 0 auto; margin-top: 1px; }
.banner .b-title { font-weight: 600; font-size: 13.5px; color: var(--ink); }
.banner .b-text { font-size: 12.5px; color: var(--ink-2); margin-top: 3px; text-wrap: pretty; }

/* -------------------- Layout 2 colonnes -------------------- */
main.layout { max-width: 1320px; margin: 0 auto; padding: 22px; display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; }
.aside { flex: 1 1 380px; max-width: 430px; position: sticky; top: 128px; display: flex; flex-direction: column; gap: 14px; }
.aside.point-aside { top: 88px; }
.section-col { flex: 999 1 520px; min-width: 0; }
.section-col.point-col { display: flex; flex-direction: column; gap: 16px; }

/* -------------------- Cards -------------------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); box-shadow: var(--sh); }
.card.pad { padding: 14px; }
.card.clip { overflow: hidden; }
.card-soft { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r3); padding: 18px; }

/* -------------------- Player -------------------- */
.player-frame { position: relative; aspect-ratio: 16/9; overflow: hidden; border-radius: var(--r3) var(--r3) 0 0; background: #000; }
.player-persistent { position: absolute; inset: 0; z-index: 1; }
.player-persistent iframe, .player-frame iframe { position: absolute; inset: 0; width: 100% !important; height: 100% !important; border: 0; }
.player-persistent:empty { display: none; }
.player-placeholder { position: absolute; inset: 0; background: repeating-linear-gradient(135deg, var(--surface-2), var(--surface-2) 11px, var(--surface-3) 11px, var(--surface-3) 22px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 11px; }
.player-placeholder .pp-label { font-family: var(--mono); font-size: 10px; letter-spacing: .5px; color: var(--ink-3); text-transform: uppercase; text-align: center; padding: 0 12px; }
.player-placeholder.coming-soon { text-align: center; gap: 8px; }
.cc-badge { position: absolute; left: 11px; top: 11px; font-family: var(--mono); font-size: 10px; background: color-mix(in srgb, var(--bg) 70%, transparent); border: 1px solid var(--line); color: var(--ink-2); padding: 3px 7px; border-radius: var(--r1); z-index: 2; }
.play-circle { cursor: pointer; flex: 0 0 auto; border-radius: 50%; background: var(--accent); border: none; color: #fff; display: flex; align-items: center; justify-content: center; }
.play-circle.sm { width: 36px; height: 36px; box-shadow: 0 4px 12px -4px var(--accent); }
.play-circle.lg { width: 54px; height: 54px; box-shadow: 0 6px 18px -6px var(--accent); }

.player-controls { padding: 13px 14px 14px; }
.player-controls .row { display: flex; align-items: center; gap: 11px; }
.btn-fs { cursor: pointer; flex: 0 0 auto; width: 34px; height: 34px; border-radius: var(--r2); background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2); display: flex; align-items: center; justify-content: center; transition: border-color .15s, color .15s; }
.btn-fs:hover { border-color: var(--accent-line); color: var(--accent-ink); }
.progress { height: 6px; border-radius: 3px; background: var(--surface-3); position: relative; overflow: hidden; }
.progress .fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); border-radius: 3px; }
.progress-times { display: flex; justify-content: space-between; margin-top: 7px; font-family: var(--mono); font-size: 11px; color: var(--ink-2); }
.progress-times .cur { color: var(--accent-ink); }
.col-grow { flex: 1 1 auto; }

.clip-window { padding: 13px 14px 14px; }
.clip-rail { height: 6px; border-radius: 3px; background: var(--surface-3); position: relative; overflow: hidden; }
.clip-rail .clip { position: absolute; top: 0; bottom: 0; background: var(--accent-weak); border-left: 2px solid var(--accent); border-right: 2px solid var(--accent); }
.clip-rail .playhead { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--accent-ink); }
.clip-times { display: flex; justify-content: space-between; margin-top: 7px; font-family: var(--mono); font-size: 11px; color: var(--ink-2); }
.clip-times .cur { color: var(--accent-ink); }
.btn-clip { cursor: pointer; margin-top: 11px; width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 7px; font-family: var(--mono); font-size: 11.5px; color: var(--accent-ink); background: var(--accent-weak); border: 1px solid var(--accent-line); border-radius: var(--r2); padding: 9px; }

/* -------------------- Open data card -------------------- */
.label-mono { font-family: var(--mono); font-size: 10px; letter-spacing: .5px; text-transform: uppercase; color: var(--ink-3); }
.opendata p { margin: 0 0 12px; font-size: 12px; line-height: 1.55; color: var(--ink-2); text-wrap: pretty; }
.dl-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.dl-chip { cursor: pointer; font-family: var(--mono); font-size: 11px; color: var(--ink-2); background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r1); padding: 6px 9px; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; transition: border-color var(--dur), color var(--dur); }
.dl-chip.sm { font-size: 10.5px; padding: 5px 8px; }
.dl-chip:hover { border-color: var(--accent-line); color: var(--accent-ink); }
.dl-chip .arrow { opacity: .55; }
.hr { height: 1px; background: var(--line); margin: 13px 0; }
.ext-link { display: flex; align-items: center; justify-content: space-between; text-decoration: none; color: var(--ink); font-size: 13px; font-weight: 500; padding: 3px 0; transition: color var(--dur); }
.ext-link:hover { color: var(--accent-ink); }
.ext-link .ext { color: var(--ink-3); }

/* -------------------- Tabs -------------------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.tab { cursor: pointer; background: none; border: none; border-bottom: 2px solid transparent; color: var(--ink-3); font-family: var(--sans); font-size: 13.5px; font-weight: 500; padding: 11px 14px; margin-bottom: -1px; display: flex; align-items: center; transition: color var(--dur), border-color var(--dur); }
.tab[aria-selected="true"] { border-bottom-color: var(--accent); color: var(--ink); font-weight: 600; }
.tab-count { margin-left: 7px; font-family: var(--mono); font-size: 10px; background: var(--surface-3); color: var(--ink-2); padding: 1px 6px; border-radius: 20px; }

/* -------------------- Filters -------------------- */
.filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; padding-top: 14px; }
.filters .label-mono { margin-right: 2px; }
.filter-pill { cursor: pointer; font-family: var(--mono); font-size: 11px; border-radius: 20px; padding: 5px 11px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); transition: border-color var(--dur), color var(--dur), background var(--dur); }
.filter-pill[aria-pressed="true"] { border-color: var(--accent-line); background: var(--accent-weak); color: var(--accent-ink); }
.filter-pill .c { opacity: .6; margin-left: 5px; }

/* -------------------- ODJ points list -------------------- */
.points-list { display: flex; flex-direction: column; gap: 6px; }
.point-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); overflow: hidden; transition: border-color var(--dur); }
.point-card:hover { border-color: var(--line-2); }
.point-row { cursor: pointer; width: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 9px 12px; background: none; border: none; padding: 11px 14px 8px; color: var(--ink); text-align: left; min-height: 44px; }
.point-row.static { cursor: default; }
.point-n { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--ink-3); flex: 0 0 auto; width: 30px; text-align: right; }
.point-title { flex: 1 1 auto; min-width: 170px; font-size: 14px; font-weight: 500; color: var(--ink); text-wrap: pretty; }
.point-meta { flex: 0 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px 3px 7px; border: 1px solid var(--line); border-radius: 20px; color: var(--ink-2); background: var(--surface-2); }
.chip.checks { border-color: var(--line-2); }
.chip .mono { font-family: var(--mono); font-size: 10.5px; }
.delib-micro { display: inline-flex; align-items: center; gap: 5px; font-family: var(--mono); font-size: 10px; color: var(--ink-3); }
.delib-micro .pip { width: 7px; height: 7px; border-radius: 50%; }
.dur { display: inline-flex; align-items: center; gap: 4px; justify-content: flex-end; font-family: var(--mono); font-size: 11px; color: var(--ink-3); min-width: 62px; }
.dur svg { opacity: .7; }
.chevron { color: var(--ink-3); }
.vote-mark { font-family: var(--mono); font-size: 11px; color: var(--ink-3); margin-right: 6px; }
.point-tags { display: flex; flex-wrap: wrap; gap: 5px; padding: 0 14px 11px 56px; }
.tag-pill { cursor: pointer; font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .3px; border-radius: 20px; padding: 3px 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink-2); transition: border-color var(--dur), color var(--dur), background var(--dur); }
.tag-pill[aria-pressed="true"] { border-color: var(--accent-line); background: var(--accent-weak); color: var(--accent-ink); }
.empty-note { padding: 30px; text-align: center; color: var(--ink-3); font-size: 13px; }

/* -------------------- Moments clés -------------------- */
.moments { padding-top: 16px; display: flex; flex-direction: column; gap: 7px; }
.moments-intro { font-size: 12.5px; color: var(--ink-3); margin-bottom: 5px; text-wrap: pretty; }
.moment { cursor: pointer; text-align: left; display: flex; align-items: flex-start; gap: 13px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r2); padding: 13px 14px; color: var(--ink); transition: border-color var(--dur); }
.moment:hover { border-color: var(--line-2); }
.moment .tc { font-family: var(--mono); font-size: 11.5px; color: var(--accent-ink); flex: 0 0 auto; width: 58px; padding-top: 1px; }
.verdict-pill { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px 3px 8px; border: 1px solid var(--line-2); border-radius: 20px; background: var(--surface-2); }
.verdict-pill .lbl { font-family: var(--mono); font-size: 10.5px; }
.moment .body { flex: 1 1 auto; min-width: 0; }
.moment .quote { font-size: 13.5px; line-height: 1.5; color: var(--ink); text-wrap: pretty; }
.moment .sub { display: block; margin-top: 4px; font-family: var(--mono); font-size: 10px; color: var(--ink-3); }

/* -------------------- Transcription -------------------- */
.transcript { padding-top: 16px; }
.search { position: relative; margin-bottom: 12px; }
.search > svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); }
.search input { width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r2); padding: 11px 13px 11px 36px; color: var(--ink); font-family: var(--sans); font-size: 14px; outline: none; transition: border-color var(--dur), box-shadow var(--dur); }
.search input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-weak); }
.search .count { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-family: var(--mono); font-size: 11px; color: var(--ink-2); }
.seg-list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); overflow: hidden; position: relative; }
.seg-viewport { overflow-y: auto; max-height: 70vh; position: relative; }
.seg-spacer { position: relative; width: 100%; }
.seg-row { cursor: pointer; width: 100%; display: flex; gap: 13px; align-items: flex-start; padding: 11px 14px; border: none; border-left: 2px solid transparent; border-bottom: 1px solid var(--line); background: transparent; text-align: left; position: absolute; left: 0; right: 0; transition: background var(--dur); }
.seg-row:hover { background: var(--surface-2); }
.seg-row.active { border-left-color: var(--accent); background: var(--accent-weak); }
.seg-row .tc { font-family: var(--mono); font-size: 11px; color: var(--accent-ink); flex: 0 0 auto; width: 62px; text-align: left; }
.seg-row .txt { flex: 1 1 auto; font-size: 13.5px; line-height: 1.55; color: var(--ink-2); text-align: left; }
.seg-row mark { background: var(--accent-weak); color: var(--ink); border-radius: 2px; padding: 0 1px; }
.transcript-foot { margin-top: 10px; font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); text-align: center; }
.transcript-empty, .transcript-noseg { padding: 34px 16px; text-align: center; color: var(--ink-3); font-size: 13px; }

/* -------------------- Point detail -------------------- */
.point-detail { max-width: 1320px; margin: 0 auto; padding: 18px 22px 0; }
.actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.btn { cursor: pointer; display: inline-flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); border-radius: var(--r2); padding: 8px 13px; font-size: 12.5px; font-weight: 500; transition: border-color var(--dur), color var(--dur); }
.btn:hover { border-color: var(--line-2); }
.btn.nav { color: var(--ink-2); font-family: var(--mono); font-size: 11px; padding: 8px 12px; }
.btn.nav:hover { color: var(--ink); }
.btn .mono { font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.share-wrap { position: relative; }
.nav-group { display: flex; gap: 7px; }

.popover { position: absolute; top: 44px; right: 0; z-index: 50; width: 300px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r3); box-shadow: var(--sh); padding: 14px; animation: dcfade .16s ease both; }
.popover .copy-row { display: flex; gap: 6px; margin-bottom: 11px; }
.popover .copy-row input { flex: 1 1 auto; min-width: 0; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r1); padding: 7px 9px; color: var(--ink-2); font-family: var(--mono); font-size: 11px; outline: none; }
.popover .copy-btn { cursor: pointer; flex: 0 0 auto; background: var(--accent-weak); border: 1px solid var(--accent-line); color: var(--accent-ink); border-radius: var(--r1); padding: 7px 10px; font-size: 11.5px; font-weight: 600; }
.net-grid { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 13px; }
.net-btn { cursor: pointer; flex: 1 1 calc(50% - 3px); display: inline-flex; align-items: center; justify-content: center; gap: 7px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); border-radius: var(--r2); padding: 9px; font-size: 12px; font-weight: 500; transition: border-color var(--dur); }
.net-btn:hover { border-color: var(--line-2); }
.share-dist { display: flex; flex-direction: column; gap: 8px; }
.share-dist .d-row { display: flex; align-items: center; gap: 9px; }
.share-dist .d-lbl { font-size: 11.5px; color: var(--ink-2); flex: 0 0 64px; }
.share-dist .d-bar { flex: 1 1 auto; height: 5px; border-radius: 3px; background: var(--surface-3); overflow: hidden; position: relative; }
.share-dist .d-bar .v { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); border-radius: 3px; }
.share-dist .d-c { font-family: var(--mono); font-size: 11px; color: var(--ink-2); flex: 0 0 auto; width: 26px; text-align: right; }
.share-note { margin-top: 11px; font-size: 10.5px; line-height: 1.5; color: var(--ink-3); text-wrap: pretty; }

.point-head { margin-top: 16px; }
.point-head .meta { display: flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 11px; letter-spacing: .4px; text-transform: uppercase; color: var(--ink-3); margin-bottom: 9px; flex-wrap: wrap; }
.point-head .meta .accent { color: var(--accent-ink); }
.point-head .meta .ico { display: inline-flex; align-items: center; gap: 4px; }
h1.point-title { margin: 0; font-size: 27px; font-weight: 700; letter-spacing: -.5px; line-height: 1.12; max-width: 760px; text-wrap: pretty; }
.point-head .tags { margin-top: 11px; display: flex; flex-wrap: wrap; gap: 6px; }
.point-head .status { margin-top: 13px; display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.vote-chip { display: inline-flex; align-items: center; padding: 6px 12px; border: 1px solid var(--line); border-radius: var(--r2); background: var(--surface-2); font-weight: 600; font-size: 13px; }
.delib-pill { display: inline-flex; align-items: center; gap: 8px; border-radius: 20px; padding: 5px 12px 5px 9px; font-size: 12px; }
.delib-pill .pip { width: 8px; height: 8px; border-radius: 50%; }
.delib-pill.ready { background: var(--ok-weak); border: 1px solid var(--ok-line); color: var(--ok-ink); }
.delib-pill.ready .pip { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-weak); }
.delib-pill.pending { background: var(--surface-3); border: 1px solid var(--line); color: var(--ink-2); }
.delib-pill.pending .pip { background: var(--ink-3); }

.point-body { margin-top: 18px; display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; padding-bottom: 8px; }

.enbref { display: flex; flex-direction: column; gap: 11px; }
.enbref .label { font-size: 12.5px; color: var(--ink-3); margin-bottom: 7px; }
.enbref .tags { display: flex; flex-wrap: wrap; gap: 5px; }
.enbref .tag-static { font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .3px; color: var(--ink-2); background: var(--surface-2); border: 1px solid var(--line); border-radius: 20px; padding: 3px 8px; }
.enbref .kv { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.enbref .kv .k { font-size: 12.5px; color: var(--ink-3); }
.enbref .kv .v { font-size: 13px; font-weight: 600; text-align: right; }
.enbref .vote-detail { font-family: var(--mono); font-size: 11.5px; color: var(--ink-2); text-align: right; margin-top: -5px; }
.enbref .delib-col { display: flex; flex-direction: column; gap: 9px; align-items: flex-start; }
.enbref a.pdf { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--accent-ink); text-decoration: none; font-weight: 500; }
.enbref a.pdf:hover { text-decoration: underline; }

.section-head { display: flex; align-items: center; gap: 9px; }
.section-head .line { height: 1px; background: var(--line); flex: 1 1 auto; }
.section-head .n { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }
.claims { display: flex; flex-direction: column; gap: 12px; }
.claim { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 16px; box-shadow: var(--sh); }
.claim .top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 11px; flex-wrap: wrap; }
.verdict-lg { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 9px; border: 1px solid var(--line-2); border-radius: var(--r2); background: var(--surface-2); font-weight: 600; font-size: 13px; }
.tc-btn { cursor: pointer; font-family: var(--mono); font-size: 11px; color: var(--accent-ink); background: var(--accent-weak); border: 1px solid var(--accent-line); border-radius: var(--r1); padding: 4px 9px; display: inline-flex; align-items: center; gap: 5px; }
.claim .q { margin: 0 0 10px; font-size: 15px; line-height: 1.6; color: var(--ink); border-left: 2px solid var(--line-2); padding-left: 13px; text-wrap: pretty; }
.claim .r { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }
.no-claims { background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--r3); padding: 16px 18px; display: flex; align-items: center; gap: 12px; color: var(--ink-3); font-size: 13px; }
.no-claims a { color: var(--accent-ink); text-decoration: none; }

.excerpt-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 18px; box-shadow: var(--sh); }
.excerpt-card .top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 11px; }
.excerpt-card .q { margin: 0; font-size: 15px; line-height: 1.7; color: var(--ink); border-left: 2px solid var(--accent-line); padding-left: 14px; text-wrap: pretty; }

.args { display: flex; gap: 14px; flex-wrap: wrap; }
.args .col { flex: 1 1 220px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 16px; }
.args ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 9px; }
.args li { display: flex; gap: 9px; font-size: 13px; line-height: 1.55; color: var(--ink-2); }
.args li .dash { color: var(--ink-3); flex: 0 0 auto; }
.args li span.t { text-wrap: pretty; }

.context-card .ctx { margin: 0; font-size: 14px; line-height: 1.65; color: var(--ink-2); text-wrap: pretty; }

.sources-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 18px; box-shadow: var(--sh); }
.source { display: flex; align-items: flex-start; gap: 10px; text-decoration: none; color: var(--ink); padding: 10px 0; transition: color var(--dur); }
.source + .source { border-top: 1px solid var(--line); }
.source:hover { color: var(--accent-ink); }
.source .kind { font-family: var(--mono); font-size: 9.5px; color: var(--ink-3); border: 1px solid var(--line); border-radius: var(--r1); padding: 3px 6px; flex: 0 0 auto; margin-top: 1px; text-transform: uppercase; letter-spacing: .3px; }
.source .t { font-size: 13.5px; line-height: 1.45; text-wrap: pretty; }
.source .ext { color: var(--ink-3); }
.no-sources { font-size: 13px; color: var(--ink-3); }
.no-sources a { color: var(--accent-ink); text-decoration: none; }

/* -------------------- Fact-check & Propositions citoyennes -------------------- */
.factcheck-card, .props-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 16px; box-shadow: var(--sh); }
.fc-note { color: var(--ink-2); margin: 8px 0 10px; font-size: 13.5px; line-height: 1.6; text-wrap: pretty; }
.fc-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.props .prop { padding: 10px 0; border-top: 1px solid var(--line); }
.props .prop:first-child { border-top: 0; }
.prop-title { font-weight: 650; margin-bottom: 4px; font-size: 13.5px; }
.prop-text { color: var(--ink-2); margin: 0 0 6px; font-size: 13px; line-height: 1.6; text-wrap: pretty; }
.prop-links { display: flex; flex-wrap: wrap; gap: 10px; }

.prevnext { display: flex; gap: 12px; flex-wrap: wrap; }
.pn-card { cursor: pointer; flex: 1 1 220px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 14px 16px; color: var(--ink); transition: border-color var(--dur); }
.pn-card:hover { border-color: var(--line-2); }
.pn-card.prev { text-align: left; }
.pn-card.next { text-align: right; }
.pn-card .k { font-family: var(--mono); font-size: 10px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .4px; }
.pn-card .t { font-size: 13.5px; font-weight: 500; margin-top: 5px; text-wrap: pretty; }

/* -------------------- Footer -------------------- */
.site-footer { max-width: 1320px; margin: 14px auto 0; padding: 18px 22px 40px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between; }
.site-footer .note { font-size: 12px; color: var(--ink-3); max-width: 560px; text-wrap: pretty; }
.site-footer .prov { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }

/* -------------------- Status badge -------------------- */
.status-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .02em;
  padding: 2px 9px;
  border-radius: 999px;
  margin-bottom: 6px;
  border: 1px solid var(--ink-3);
  color: var(--ink-1);
}
.status-badge.st-odj    { border-color: var(--ink-3); color: var(--ink-2); }
.status-badge.st-prelim { border-color: var(--accent, #c9a227); color: var(--accent, #c9a227); }
.status-badge.st-final  { border-color: var(--ok, #3a8); color: var(--ok, #3a8); }

/* -------------------- Skeletons -------------------- */
@keyframes shimmer { 0% { opacity: .5; } 50% { opacity: 1; } 100% { opacity: .5; } }
.sk { background: var(--surface-2); border-radius: var(--r2); animation: shimmer 1.4s var(--ease) infinite; }
.sk.card-sk { height: 64px; border-radius: var(--r3); margin-bottom: 6px; }
.sk.line { height: 12px; margin: 8px 0; }
@media (prefers-reduced-motion: reduce) { .sk { animation: none; } }

/* -------------------- Offline -------------------- */
.offline-flag { display: none; align-items: center; gap: 6px; font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r1); padding: 4px 8px; }
body.is-offline .offline-flag { display: inline-flex; }
.offline-flag .pip { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); }

/* -------------------- Update banner -------------------- */
.update-banner {
  position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%);
  z-index: 100;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  max-width: 780px; width: calc(100% - 32px);
  background: var(--surface); border: 1px solid var(--accent-line);
  border-radius: var(--r3); padding: 12px 16px;
  box-shadow: var(--sh), 0 0 0 1px var(--accent-line);
  animation: dcfade .2s var(--ease) both;
  font-size: 13.5px; color: var(--ink);
}
.update-banner-text { flex: 1 1 200px; line-height: 1.5; }
.update-banner-reload {
  flex: 0 0 auto;
  background: var(--accent); color: #fff;
  border: none; border-radius: var(--r2);
  padding: 6px 14px; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: opacity var(--dur);
}
.update-banner-reload:hover { opacity: .85; }
.update-banner-close {
  flex: 0 0 auto;
  background: none; border: none;
  color: var(--ink-3); font-size: 18px; line-height: 1;
  cursor: pointer; padding: 0 4px;
  transition: color var(--dur);
}
.update-banner-close:hover { color: var(--ink); }

/* ----------------------------------------------------------- responsive mobile */
/* Sur petit écran le header (titre de séance + sélecteurs année/dates) est trop haut
   pour rester collé : en sticky il masquait ~40% de l'écran au scroll. On le laisse
   défiler normalement, et on désactive le sticky des colonnes vidéo/aside (layout en
   colonne unique). */
@media (max-width: 768px) {

  /* ---- Header ---- */
  .app-header { position: static; }
  .header-bar { padding: 10px 14px; }
  .header-session { padding: 0 14px 12px; gap: 14px; }
  .session-title-wrap { min-width: 0; }
  h1.session-title { font-size: 20px; }

  /* ---- Year / date pickers ---- */
  /* Year-seg buttons: augmenter la cible tactile à ≥ 40px */
  .year-seg button { padding: 12px 11px; min-height: 40px; }
  /* Pastilles de séances : wrap au lieu de scroll horizontal */
  .date-row { flex-wrap: wrap; overflow-x: visible; }

  /* ---- Layout colonne unique ---- */
  main.layout {
    flex-direction: column;
    padding: 14px;
    gap: 14px;
  }
  /* Aside et point-aside : pleine largeur, pas de sticky */
  .aside,
  .point-aside {
    position: static;
    top: auto;
    max-width: none;
    flex-basis: 100%;
    width: 100%;
  }
  /* Section col : pleine largeur, pas de min-width bloquante */
  .section-col { min-width: 0; flex-basis: 100%; width: 100%; }

  /* ---- Point detail header ---- */
  .point-detail { padding: 14px 14px 0; }
  h1.point-title { font-size: 20px; max-width: none; }

  /* ---- Action bar (Retour / Partager / nav) ---- */
  .btn { padding: 10px 13px; min-height: 40px; }
  .btn.nav { padding: 10px 12px; min-height: 40px; }

  /* ---- Tabs : cible tactile correcte ---- */
  .tab { padding: 13px 12px; min-height: 40px; font-size: 13px; }

  /* ---- Filtres thématiques ---- */
  /* Les pills passent à la ligne — augmenter la cible tactile */
  .filter-pill { padding: 9px 11px; min-height: 40px; }

  /* ---- Cards : padding réduit pleine largeur ---- */
  .card.pad { padding: 14px; }
  .card-soft { padding: 14px; }
  .claim { padding: 14px; }
  .excerpt-card { padding: 14px; }
  .sources-card { padding: 14px; }
  .factcheck-card,
  .props-card { padding: 14px; }

  /* ---- Point body ---- */
  .point-body { gap: 14px; }
  .args { gap: 10px; }

  /* ---- Popover de partage : ne pas déborder sur les petits écrans ---- */
  .popover {
    width: calc(100vw - 28px);
    max-width: 300px;
    right: 0;
    left: auto;
  }

  /* ---- Update banner ---- */
  .update-banner {
    bottom: max(14px, env(safe-area-inset-bottom));
    width: calc(100% - 22px);
    padding: 11px 14px;
    font-size: 13px;
  }

  /* ---- Prev/next cards : empilées verticalement ---- */
  .prevnext { flex-direction: column; }
  .pn-card { flex-basis: auto; }
  .pn-card.next { text-align: left; }

  /* ---- Point title (liste ODJ) : pas de min-width bloquant ---- */
  .point-title { min-width: 0; }

  /* ---- Download chips ---- */
  .dl-chips { gap: 8px; }
  .dl-chip { padding: 9px 10px; min-height: 40px; }
  .dl-chip.sm { padding: 8px 9px; min-height: 40px; }
}

/* ---- Affinage pour très petits écrans (≤ 430px) ---- */
@media (max-width: 430px) {
  /* Tabs : réduire le texte pour qu'ils tiennent sur une ligne */
  .tab { font-size: 12px; padding: 12px 10px; }
  .tab-count { display: none; }

  /* Header brand name compact */
  .brand .name { font-size: 12px; }

  /* Point row : titre sans min-width */
  .point-title { font-size: 13.5px; }

  /* Popover : pleine largeur avec marges */
  .popover { width: calc(100vw - 28px); }
}
