/* Locomotive roster search: scoped homepage-style presentation. */
body.crf-roster { margin: 0; background: #090909; color: #f0f0f0; font: 16px/1.6 Arial,Helvetica,sans-serif; }
.roster-shell, .roster-shell * { box-sizing: border-box; }
.roster-shell { max-width: 1440px; margin: auto; padding: 28px 24px; }
.roster-shell a { color: #ffb44d; }
.roster-shell a:focus-visible, .roster-shell summary:focus-visible, .roster-shell input:focus-visible, .roster-shell select:focus-visible, .roster-shell button:focus-visible { outline: 3px solid #61a7ff; outline-offset: 3px; }
.roster-page-heading { margin-bottom: 24px; }
.roster-eyebrow { color: #ffb44d; text-transform: uppercase; letter-spacing: .07em; font-weight: 700; font-size: .75rem; margin: 0 0 6px; }
.roster-page-heading h1 { margin: 0; font-size: clamp(1.8rem,4vw,2.6rem); line-height: 1.2; }
.roster-page-heading > p:last-child { color: #bcbcbc; margin: 10px 0 0; }
.roster-search-panel { background: #181818; border: 1px solid #363636; border-radius: 7px; padding: 20px; margin-bottom: 28px; }
.roster-search-panel h2 { margin: 0 0 14px; font-size: 1.15rem; }
.roster-search-form { display: grid; grid-template-columns: minmax(0,1.3fr) minmax(0,1fr) minmax(0,.7fr) auto; gap: 14px; align-items: end; }
.roster-search-form > div { min-width: 0; }
.roster-search-form label { display: block; font-size: .85rem; font-weight: 700; margin-bottom: 6px; }
.roster-search-form select, .roster-search-form input { width: 100%; min-width: 0; max-width: 100%; min-height: 44px; border: 1px solid #aaa; border-radius: 4px; padding: 9px 10px; color: #111; background: #f4f4f4; font: 16px/1.4 Arial,Helvetica,sans-serif; }
.roster-form-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.roster-form-actions button, .roster-form-actions .roster-clear { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; padding: 10px 14px; border: 1px solid #ffa323; border-radius: 5px; background: #ffa323; color: #111; font: 700 .85rem/1.4 Arial,Helvetica,sans-serif; cursor: pointer; text-decoration: none; }
.roster-form-actions .roster-clear { background: transparent; color: #ffb44d; border-color: #725525; }
.roster-form-actions button:hover { background: #ffc16a; }
.roster-overview { margin-bottom: 28px; }
.roster-overview h2 { font-size: 1.45rem; margin: 0 0 12px; overflow-wrap: anywhere; }
.roster-active-filters { display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 14px; }
.roster-active-filters span { color: #d7c7aa; border: 1px solid #55442a; background: #211d17; border-radius: 5px; padding: 4px 9px; font-size: .78rem; overflow-wrap: anywhere; }
.roster-summary { display: grid; grid-template-columns: 150px 150px minmax(0,1fr); gap: 12px; margin-bottom: 16px; }
.roster-summary > div { padding: 12px 16px; background: #181818; border: 1px solid #363636; border-radius: 6px; min-width: 0; }
.roster-summary strong { display: block; color: #ffb44d; font-size: 1.35rem; line-height: 1.3; }
.roster-summary span { color: #bcbcbc; font-size: .8rem; }
.roster-summary-dates { display: flex; align-items: center; }
.roster-quick-links { padding: 10px 16px; border: 1px solid #363636; background: #151515; border-radius: 6px; }
.roster-quick-links summary { min-height: 44px; padding: 9px 0; font-size: .9rem; font-weight: 700; cursor: pointer; }
.roster-quick-links nav { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 0 12px; }
.roster-quick-links nav a { max-width: 100%; overflow-wrap: anywhere; display: inline-flex; align-items: center; gap: 9px; min-height: 44px; padding: 8px 12px; border: 1px solid #725525; border-radius: 5px; text-decoration: none; font-size: .85rem; }
.roster-quick-links nav a:hover { background: #2b2318; }
.roster-quick-links nav a span { color: #aaa; font-size: .75rem; }
.roster-group { margin: 0 0 30px; scroll-margin-top: 16px; }
.roster-group-heading { padding: 0 0 13px; margin-bottom: 16px; border-bottom: 2px solid #80591e; }
.roster-group-heading h2 { margin: 0 0 6px; font-size: 1.4rem; line-height: 1.3; overflow-wrap: anywhere; }
.roster-group-stats { display: flex; flex-wrap: wrap; gap: 5px 16px; color: #ffbd61; font-size: .8rem; }
.roster-group-heading p { margin: 5px 0 0; color: #aaa; font-size: .8rem; }
.roster-unit-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,380px),1fr)); gap: 18px; align-items: start; }
.roster-unit { min-width: 0; padding: 17px; background: #181818; border: 1px solid #363636; border-radius: 7px; }
.roster-unit-heading h3 { font-size: 1.08rem; line-height: 1.3; margin: 0 0 6px; color: #f5f5f5; }
.roster-unit-heading > p { font-size: .78rem; line-height: 1.5; margin: 8px 0 14px; color: #bcbcbc; }
.roster-history { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .75rem; color: #bbb; overflow-wrap: anywhere; }
.roster-history:empty { display: none; }
.roster-thumbnails { display: flex; flex-wrap: wrap; gap: 12px; align-items: stretch; }
.roster-thumbnail { display: flex; flex: 0 1 160px; flex-direction: column; min-width: 0; max-width: 100%; border: 1px solid #414141; background: #0d0d0d; border-radius: 5px; overflow: hidden; text-decoration: none; }
.roster-thumbnail:hover { border-color: #ffb44d; }
.roster-thumbnail-image { display: flex; align-items: center; justify-content: center; height: 118px; padding: 8px; }
.roster-thumbnail img { display: block; max-width: 100%; max-height: 102px; width: auto; height: auto; }
.roster-photo-date { display: block; padding: 5px 7px 7px; font-size: .65rem; color: #c6b89f; text-align: center; }
.roster-empty, .roster-notice { background: #181818; border: 1px solid #66502c; border-radius: 7px; padding: 22px; margin: 20px 0; }
.roster-empty h2 { font-size: 1.15rem; margin: 0 0 8px; }
.roster-empty p { color: #bcbcbc; margin: 0 0 10px; }
.roster-visits { color: #aaa; font-size: .75rem; margin-top: 28px; }
@media (max-width: 1099px) {
 .roster-search-form { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
 .roster-form-actions { align-self: end; }
}
@media (max-width: 699.98px) {
 .roster-shell { padding: 20px 12px; }
 .roster-search-panel { padding: 16px; }
 .roster-search-form { grid-template-columns: minmax(0,1fr); gap: 12px; }
 .roster-form-actions > * { flex: 1 1 auto; }
 .roster-summary { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
 .roster-summary-dates { grid-column: 1 / -1; }
 .roster-unit-grid { grid-template-columns: minmax(0,1fr); }
 .roster-unit { padding: 14px; }
 .roster-thumbnail { flex-basis: calc(50% - 6px); }
 .roster-thumbnail-image { height: 110px; }
 .roster-thumbnail img { max-height: 94px; }
}

/* Keep each locomotive unit on its own full-width row. */
.roster-unit-grid {
    grid-template-columns: minmax(0, 1fr);
}