/* Viewer interactif — index.html (web). Flèches groupées en bas. */
body.viewer { height: 100%; overflow: hidden; }
#app { display: flex; height: 100vh; width: 100vw; }
#rail { width: 214px; flex: 0 0 214px; background: var(--ink-900); height: 100vh; overflow-y: auto; padding: 16px 14px 24px; display: flex; flex-direction: column; gap: 12px; }
#rail::-webkit-scrollbar { width: 8px; } #rail::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 4px; }
.rail-head { display: flex; flex-direction: column; gap: 8px; padding: 2px 4px 12px; border-bottom: 1px solid rgba(255,255,255,.12); }
.rail-head img { height: 20px; align-self: flex-start; }
.rail-head span { font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.45); font-weight: 600; }
.thumbs { display: flex; flex-direction: column; gap: 10px; }
.thumb { position: relative; width: 186px; height: 104.6px; border: 0; padding: 0; border-radius: 5px; overflow: hidden; cursor: pointer; background: var(--ink-50); box-shadow: 0 0 0 1px rgba(255,255,255,.10); transition: box-shadow .15s; flex: 0 0 auto; }
.thumb:hover { box-shadow: 0 0 0 1px rgba(255,255,255,.32); }
.thumb.active { box-shadow: 0 0 0 2px var(--perf-lime); }
.thumb .slide { position: absolute; top: 0; left: 0; transform: scale(0.14531); transform-origin: top left; box-shadow: none !important; opacity: 1 !important; visibility: visible !important; pointer-events: none; }
.thumb .thumb-n { position: absolute; bottom: 4px; right: 6px; font-family: var(--font-mono); font-size: 9px; color: rgba(255,255,255,.75); background: rgba(10,10,11,.6); border-radius: 3px; padding: 1px 5px; }
#stage { position: relative; flex: 1; height: 100vh; background: #1a1a1a; overflow: hidden; }
#stage .slide { position: absolute; top: 46%; left: 50%; margin: 0; transform: translate(-50%, -50%) scale(var(--s, 0.85)); opacity: 0; visibility: hidden; box-shadow: 0 30px 90px rgba(0,0,0,.55); transition: opacity .18s ease; }
#stage .slide.is-active { opacity: 1; visibility: visible; }
#controls { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 14px; z-index: 10; }
.nav-arrow { width: 42px; height: 42px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: rgba(20,20,22,.6); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: background .15s, border-color .15s, opacity .15s; }
.nav-arrow:hover { background: var(--perf-lime); color: var(--ink-1000); border-color: var(--perf-lime); }
.nav-arrow:disabled { opacity: .25; cursor: default; }
.nav-arrow:disabled:hover { background: rgba(20,20,22,.6); color: #fff; border-color: rgba(255,255,255,.18); }
#counter { font-family: var(--font-mono); font-size: 12px; letter-spacing: .1em; color: rgba(255,255,255,.7); background: rgba(20,20,22,.6); padding: 8px 14px; border-radius: 999px; min-width: 78px; text-align: center; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
@media (max-width: 820px) { #rail { display: none; } }
@media print {
  body.viewer { overflow: visible; height: auto; }
  #rail, #controls { display: none !important; }
  #app { display: block; }
  #stage { position: static; height: auto; background: #fff; overflow: visible; }
  #stage .slide { position: static; transform: none; opacity: 1; visibility: visible; margin: 0 auto; box-shadow: none; page-break-after: always; }
}
