diff --git a/public/index.html b/public/index.html
index 9ec2d41..280711e 100644
--- a/public/index.html
+++ b/public/index.html
@@ -381,7 +381,7 @@ window.dispatchEvent(new Event('tiptap-loaded'));
.editor-saving { position: fixed; bottom: 20px; right: 20px; background: var(--accent); color: var(--bg); padding: 8px 18px; border-radius: 8px; font-size: 13px; font-family: 'Lora', serif; opacity: 0; transition: opacity 0.3s; z-index: 200; pointer-events: none; }
.editor-saving.show { opacity: 1; }
.word-count { font-size: 12px; color: var(--text-hint); padding: 8px 32px; border-top: 1px solid var(--border-light); background: var(--bg); }
- .binder-legend { padding: 12px 20px; border-top: 1px solid var(--border); margin-top: auto; }
+ .binder-legend { padding: 12px 20px; border-bottom: 1px solid var(--border); }
.binder-legend-title { font-size: 11px; color: var(--text-hint); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px; }
.binder-legend-item { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-muted); margin-bottom: 3px; }
.binder-legend-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
@@ -1622,6 +1622,28 @@ function buildBinder() {
});
binder.innerHTML = '';
+
+ // Legend at top
+ const legend = document.createElement('div');
+ legend.className = 'binder-legend';
+ const legendTitle = document.createElement('div');
+ legendTitle.className = 'binder-legend-title';
+ legendTitle.textContent = 'Statuts';
+ legend.appendChild(legendTitle);
+ [['#c4a030', 'À étudier'], ['#5a7a3a', 'Validée'], ['#a08a76', 'Abandonnée'], ['#8b3030', 'En conflit']].forEach(([color, label]) => {
+ const item = document.createElement('div');
+ item.className = 'binder-legend-item';
+ const dot = document.createElement('span');
+ dot.className = 'binder-legend-dot';
+ dot.style.background = color;
+ const txt = document.createElement('span');
+ txt.textContent = label;
+ item.appendChild(dot);
+ item.appendChild(txt);
+ legend.appendChild(item);
+ });
+ binder.appendChild(legend);
+
let totalWords = 0;
ACTE_ORDER.forEach(acte => {
@@ -1656,27 +1678,6 @@ function buildBinder() {
totalDiv.style.cssText = 'padding: 16px 20px; margin-top: 12px; border-top: 1px solid var(--border); font-size: 12px; color: var(--text-hint);';
totalDiv.textContent = totalWords > 0 ? `Total : ${totalWords.toLocaleString('fr-FR')} mots` : '';
binder.appendChild(totalDiv);
-
- // Legend — static content, no user input
- const legend = document.createElement('div');
- legend.className = 'binder-legend';
- const legendTitle = document.createElement('div');
- legendTitle.className = 'binder-legend-title';
- legendTitle.textContent = 'Statuts';
- legend.appendChild(legendTitle);
- [['#c4a030', 'À étudier'], ['#5a7a3a', 'Validée'], ['#a08a76', 'Abandonnée'], ['#8b3030', 'En conflit']].forEach(([color, label]) => {
- const item = document.createElement('div');
- item.className = 'binder-legend-item';
- const dot = document.createElement('span');
- dot.className = 'binder-legend-dot';
- dot.style.background = color;
- const txt = document.createElement('span');
- txt.textContent = label;
- item.appendChild(dot);
- item.appendChild(txt);
- legend.appendChild(item);
- });
- binder.appendChild(legend);
}
async function openScene(scene) {