/* Isolated styles for the national per-section timeline. */
.results .timeline-guide{margin:0;padding:0 16px 12px;color:var(--muted);font-size:12px;line-height:1.5}
.timeline-legend-title{display:flex;align-items:baseline;gap:12px;flex-wrap:wrap;margin-bottom:8px}
.timeline-legend-title h3{margin:0;color:var(--ink);font-size:12px}
.timeline-legend-row{display:flex;align-items:baseline;gap:12px;margin:6px 0}
.timeline-legend-row>strong{flex:0 0 110px;color:var(--ink);font-size:11px}
.timeline-legend-items{display:flex;flex-wrap:wrap;gap:6px 18px;list-style:none;margin:0;padding:0;min-width:0}
.timeline-legend-items li{display:flex;align-items:baseline;gap:6px;max-width:100%}
.timeline-legend-items b{font-weight:600}
.legend-vote{display:inline-block;align-self:center;width:5px;height:15px;border-radius:1px;flex:none}
.legend-bio{background:#00866A}.legend-manual{background:#B07A00}.legend-attempt{background:#6F2C13}.legend-unknown{background:#7A8792}
.legend-symbol{display:inline-block;color:#6545aa;font-size:15px;line-height:1;width:15px;text-align:center;flex:none}
.legend-cutoff{display:inline-block;align-self:center;height:14px;width:15px;border-left:2px dotted #472275;margin-left:5px;flex:none}
.timeline-legend-foot{margin-top:8px!important;font-size:11px}
.timeline-legend-foot>span{display:inline-block;margin-right:8px}
.legend-duration{display:inline-block;width:17px;border-top:2px solid #8C5B43;vertical-align:middle;margin-right:6px}
.timeline-legend-note{margin-top:4px!important;font-size:11px}
@media(max-width:760px){.timeline-legend-row{display:block}.timeline-legend-row>strong{display:block;margin-bottom:5px}.timeline-legend-items{gap:6px 14px}.timeline-legend-title{gap:4px}.timeline-legend-foot{font-size:12px}}
.results .table-tools{flex-wrap:wrap}
.results .timeline-toggle{white-space:nowrap;gap:6px}
.brasil-timeline-cell{box-sizing:border-box;min-width:0;padding:5px 8px!important;text-align:left;vertical-align:middle}
.brasil-timeline-preview{position:relative;width:100%;min-width:0;min-height:118px;background:#fff;border:1px solid #d9e3ec;border-radius:7px;overflow:hidden}
.brasil-timeline-preview:hover{background:#f5f9fb;border-color:#91b3c6}
.brasil-timeline-cell canvas[data-brasil-overview]{display:block;width:100%;max-width:100%;height:118px;cursor:pointer;border-radius:6px}
.brasil-timeline-cell canvas[data-brasil-overview]:focus-visible{outline:2px solid #226f8b;outline-offset:-3px}
.brasil-timeline-status{position:absolute;inset:0;display:grid;place-items:center;padding:12px;color:#5c7080;font-size:12px;line-height:1.4;text-align:center;pointer-events:none}
.brasil-timeline-status[hidden]{display:none}
#brasil-timeline-detail{--line:#d7e1ea;--soft:#f4f7fa;--blue:#226f8b;box-sizing:border-box;width:90vw;max-width:1600px;max-height:92vh;margin:auto;padding:18px 22px 22px;border:1px solid #bccdda;border-radius:12px;background:#fff;color:#243746;box-shadow:0 20px 70px #102c4140;overflow:auto;font-family:system-ui,sans-serif;font-size:12px;line-height:1.45}
#brasil-timeline-detail::backdrop{background:#10253680}
#brasil-timeline-detail .timeline-dialog-header{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:12px;padding-bottom:12px;border-bottom:1px solid var(--line)}
#brasil-timeline-detail .timeline-dialog-header h2{margin:0;font-size:18px;line-height:1.3}
#brasil-timeline-detail [data-brasil-timeline-host]{min-width:0}
#brasil-timeline-detail .timeline-panel{position:static;width:100%;max-width:none;min-width:0;box-sizing:border-box}
#brasil-timeline-detail .timeline-panel h3{margin:14px 0 8px;font-size:16px;line-height:1.3}
#brasil-timeline-detail .hint{margin:8px 0;color:#536c7d;font-size:12px;line-height:1.5;overflow-wrap:anywhere}
#brasil-timeline-detail .timeline-panel canvas{display:block;width:100%;max-width:none;margin:12px 0;background:#fff;border:1px solid var(--line);border-radius:6px;touch-action:none}
#brasil-timeline-detail .filters{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px;margin:14px 0}
#brasil-timeline-detail .filters label{display:grid;gap:4px;min-width:0;font-size:12px;color:#415b6e}
#brasil-timeline-detail input,#brasil-timeline-detail select,#brasil-timeline-detail button{box-sizing:border-box;min-height:32px;max-width:100%;border:1px solid #bdcdd9;border-radius:5px;padding:6px 9px;background:#fff;color:#243746;font:inherit;line-height:1.4}
#brasil-timeline-detail .timeline-panel select{width:min(420px,100%);min-width:160px}
#brasil-timeline-detail input[data-timeline-to]{width:124px}
#brasil-timeline-detail button{cursor:pointer}
#brasil-timeline-detail button:hover{border-color:#226f8b;background:#f2f8fb}
#brasil-timeline-detail :is(button,input,select):focus-visible{outline:2px solid #226f8b;outline-offset:2px}
#brasil-timeline-detail .event-view-controls{display:flex;flex-wrap:wrap;align-items:center;gap:7px;margin:10px 0}
#brasil-timeline-detail .event-view-controls strong{margin-right:3px}
#brasil-timeline-detail .event-view-controls button[aria-pressed="true"]{background:#e5f1f7;border-color:#226f8b;color:#174d68;font-weight:700}
#brasil-timeline-detail .note{padding:12px;background:var(--soft);border:1px solid var(--line);border-radius:7px}
#brasil-timeline-detail [data-timeline-hover]{display:none;position:fixed;z-index:20;width:min(440px,calc(100vw - 24px));max-width:440px;box-sizing:border-box;margin:0;background:#203341;color:#fff;padding:12px;border:1px solid #486071;border-radius:9px;box-shadow:0 8px 24px #0004;pointer-events:none;font-size:12px;line-height:1.4}
#brasil-timeline-detail .cycle-info{display:grid;gap:10px;min-width:0}
#brasil-timeline-detail .cycle-info-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;padding-bottom:8px;border-bottom:1px solid var(--line)}
#brasil-timeline-detail .cycle-info-title{display:block;font-size:14px;line-height:1.25}
#brasil-timeline-detail .cycle-info-source{display:block;margin-top:2px;font-size:12px;overflow-wrap:anywhere}
#brasil-timeline-detail .cycle-info-route{display:flex;align-items:center;gap:5px;flex:none;max-width:54%;padding:4px 7px;border:1px solid var(--line);border-radius:5px;font-size:12px;line-height:1.25;text-align:right}
#brasil-timeline-detail .cycle-info-route:before{content:"";width:7px;height:7px;flex:none;border-radius:50%;background:var(--route-color)}
#brasil-timeline-detail .cycle-info-section{display:grid;gap:5px}
#brasil-timeline-detail .cycle-info-label{font-size:11px;font-weight:700;letter-spacing:.03em;text-transform:uppercase}
#brasil-timeline-detail .cycle-info-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}
#brasil-timeline-detail .cycle-info-item{min-width:0;padding:6px 8px;border:1px solid var(--line);border-radius:5px;background:#fff}
#brasil-timeline-detail .cycle-info-item>span{display:block;font-size:12px;line-height:1.3}
#brasil-timeline-detail .cycle-info-item>strong{display:block;margin-top:3px;font-size:12px;line-height:1.3;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
#brasil-timeline-detail .cycle-info-auth{font-size:12px}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-head{border-color:#ffffff35}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-source,#brasil-timeline-detail [data-timeline-hover] .cycle-info-label,#brasil-timeline-detail [data-timeline-hover] .cycle-info-item>span{color:#c4d2dc}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-item{background:#ffffff0d;border-color:#ffffff26}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-item>strong{color:#fff}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-route{background:#ffffff0d}
#brasil-timeline-detail [data-timeline-hover] .cycle-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
@media(max-width:700px){
  #brasil-timeline-detail{width:calc(100vw - 16px);max-height:96vh;padding:12px}
  #brasil-timeline-detail .cycle-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  #brasil-timeline-detail .filters{gap:8px}
  #brasil-timeline-detail .cycle-info-head{flex-wrap:wrap}
  #brasil-timeline-detail .cycle-info-route{max-width:100%}
  #brasil-timeline-detail [data-timeline-hover]{width:min(400px,calc(100vw - 24px))}
}
