/* The trail: a deck of clues from the robbery to the last trace of the fourth man.
   Without JavaScript every clue is listed in order; with it, one clue shows at a time. */
.deck { border: 1px solid var(--accent); display: flex; flex-direction: column; }
.deck [data-enhanced] { display: none; }
.deck.is-enhanced [data-enhanced] { display: flex; }

.rail { flex-direction: column; gap: 8px; padding: 16px 18px 12px; background: var(--tint); border-bottom: 1px solid var(--frame); }
.rail-track { position: relative; height: 2px; margin: 0 4px; background: var(--frame); }
.rail-fill { position: absolute; top: 0; bottom: 0; left: 0; width: 0; background: var(--accent); transition: width .45s cubic-bezier(.3, .7, .3, 1); }
.rail-fill::after { content: ""; position: absolute; right: -5px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px var(--tint); }
.rail-ends { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; line-height: 1.4; color: var(--muted); }
.rail-ends > span { display: flex; flex-direction: column; }
.rail-ends > span:last-child { text-align: right; }
.rail-ends strong { font-weight: 500; color: var(--ink); }
.rail-ends .is-found strong { color: var(--accent); }

.clues { list-style: none; margin: 0; padding: 0; }
.clue { padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.clue + .clue { border-top: 1px solid var(--frame); }
.deck.is-enhanced .clue { display: none; border-top: 0; }
.deck.is-enhanced .clue.is-active { display: flex; animation: clue-in .4s ease both; }
.clue-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; font-size: 11px; color: var(--muted); }
.clue-type { font-size: 10px; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); font-weight: 500; }
.clue h3 { margin: 0; font-size: 17px; font-weight: 500; line-height: 1.3; }
.finding { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: baseline; padding-top: 12px; border-top: 1px dashed var(--frame); font-weight: 500; }
.finding .label { font-weight: 400; }

.signalement { display: grid; grid-template-columns: 112px 1fr; margin: 0; border: 1px solid var(--frame); }
.signalement dt, .signalement dd { margin: 0; padding: 6px 10px; }
.signalement dt { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; background: var(--tint); }
.signalement dt:not(:first-of-type), .signalement dd:not(:first-of-type) { border-top: 1px solid var(--frame); }

.evidence { gap: 6px; }
.evidence a { display: block; cursor: zoom-in; }
.evidence a:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }

.stamp { align-self: flex-start; margin: 4px 0 2px 6px; padding: 4px 12px; border: 2px solid #a3392b; color: #a3392b; font-size: 14px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; transform: rotate(-6deg); opacity: .9; }
.deck.is-enhanced .clue.is-active .stamp { animation: stamp-in .5s .25s cubic-bezier(.2, .9, .3, 1.2) both; }

.verdict { background: var(--accent); color: var(--bg); padding: 16px; display: flex; flex-direction: column; gap: 2px; }
.verdict .label { color: #a9b6c2; }
.verdict strong { font-size: 20px; font-weight: 500; line-height: 1.3; }
.verdict span:last-child { color: #d5dce3; }
.caveat { font-size: 12px; color: var(--soft); }

.deck-controls { align-items: center; justify-content: space-between; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--frame); }
.deck-count { font-size: 11px; color: var(--muted); white-space: nowrap; }
.deck-btn { font: inherit; font-size: 12px; line-height: 1.4; padding: 8px 14px; border: 1px solid var(--accent); background: var(--bg); color: var(--accent); cursor: pointer; white-space: nowrap; }
.deck-btn:hover { background: var(--tint); }
.deck-btn:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.deck-btn.primary { background: var(--accent); color: var(--bg); }
.deck-btn.primary:hover { background: #24313d; }
.deck-btn:disabled { opacity: .3; cursor: default; background: var(--bg); }

.story-break { padding-top: 24px; border-top: 1px solid var(--ink); }

@keyframes clue-in { from { opacity: 0; transform: translateX(10px); } to { opacity: 1; transform: none; } }
@keyframes stamp-in { from { opacity: 0; transform: rotate(-16deg) scale(1.9); } to { opacity: .9; transform: rotate(-6deg) scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .rail-fill { transition: none; }
  .deck.is-enhanced .clue.is-active, .deck.is-enhanced .clue.is-active .stamp { animation: none; }
}
@media (max-width: 520px) {
  .rail, .clue, .deck-controls { padding-left: 14px; padding-right: 14px; }
  .finding { grid-template-columns: 1fr; gap: 2px; }
  .signalement { grid-template-columns: 96px 1fr; }
  .deck-btn { padding: 8px 10px; }
}
