*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Arial,Helvetica,sans-serif;color:#182230;background:#f2f4f7}a{color:#175cd3;text-decoration:none}a:hover{text-decoration:underline}.entity-page{width:min(1180px,calc(100% - 24px));margin:0 auto;padding:18px 0 40px}.entity-topbar{display:flex;justify-content:space-between;align-items:center;gap:18px;margin-bottom:16px}.entity-nav{display:flex;flex-wrap:wrap;gap:8px}.entity-nav a{padding:7px 10px;border:1px solid #d0d5dd;border-radius:8px;background:#fff;color:#344054;font-size:13px}.entity-hero{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:16px;margin-bottom:16px}.entity-card{border:1px solid #d0d5dd;border-radius:12px;background:#fff;overflow:hidden}.entity-card__body{padding:18px}.entity-title{margin:0 0 7px;font-size:30px;line-height:1.1}.entity-kicker{margin:0 0 5px;color:#667085;font-size:12px;text-transform:uppercase;letter-spacing:.04em}.entity-lead{margin:10px 0 0;color:#475467;line-height:1.55}.entity-meta{display:flex;flex-wrap:wrap;gap:6px 16px;margin-top:14px;color:#667085;font-size:12px}.entity-photo-cover{min-height:240px;height:100%;background:#e4e7ec}.entity-photo-cover img{display:block;width:100%;height:100%;min-height:240px;object-fit:cover}.entity-photo-placeholder{display:grid;place-items:center;min-height:240px;height:100%;color:#98a2b3;font-size:13px;text-align:center;padding:20px}.entity-grid{display:grid;grid-template-columns:1.4fr .8fr;gap:16px}.entity-section{margin-bottom:16px}.entity-section h2{margin:0 0 12px;font-size:20px}.entity-section h3{margin:15px 0 7px;font-size:15px}.route-list,.arrival-list,.transfer-list,.vehicle-list{display:grid;gap:8px}.route-row,.arrival-row,.transfer-row,.vehicle-row{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:10px;padding:10px;border:1px solid #e4e7ec;border-radius:9px}.route-badge{display:inline-grid;place-items:center;min-width:39px;height:30px;padding:0 8px;border-radius:7px;background:#2563eb;color:#fff;font-size:15px;font-weight:800}.route-direction{min-width:0;font-size:13px;line-height:1.35}.arrival-wait{text-align:right;white-space:nowrap}.arrival-wait strong{display:block;font-size:15px}.arrival-wait span{color:#667085;font-size:11px}.stop-points{width:100%;border-collapse:collapse;font-size:12px}.stop-points th,.stop-points td{padding:7px 8px;border-bottom:1px solid #eaecf0;text-align:left;vertical-align:top}.stop-points th{color:#667085;font-weight:600}.entity-gallery{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.entity-gallery figure{margin:0}.entity-gallery img{display:block;width:100%;aspect-ratio:4/3;object-fit:cover;border-radius:8px}.entity-gallery figcaption{padding-top:4px;color:#667085;font-size:11px}.entity-empty{padding:12px;border:1px dashed #d0d5dd;border-radius:8px;color:#667085;font-size:12px;line-height:1.45}.transfer-type{color:#667085;font-size:11px}.entity-search{width:100%;padding:10px 11px;border:1px solid #d0d5dd;border-radius:8px;font:inherit}.entity-directory{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:10px;margin-top:14px}.entity-directory a{display:block;padding:12px;border:1px solid #d0d5dd;border-radius:9px;background:#fff;color:#182230}.entity-directory strong{display:block}.entity-directory span{display:block;margin-top:3px;color:#667085;font-size:11px}@media(max-width:850px){.entity-hero,.entity-grid{grid-template-columns:1fr}.entity-photo-cover,.entity-photo-cover img,.entity-photo-placeholder{min-height:190px}.entity-gallery{grid-template-columns:repeat(2,minmax(0,1fr))}}


/* Stop page local map, v20260723-2 */
.entity-stop-map-section {
    width: 100%;
}

.entity-stop-map {
    width: 100%;
    height: 430px;
    min-height: 360px;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    overflow: hidden;
    background: #e4e7ec;
}

.entity-stop-map-note {
    margin-top: 7px;
    color: #667085;
    font-size: 11px;
}

@media (max-width: 700px) {
    .entity-stop-map {
        height: 340px;
        min-height: 300px;
    }
}


/* Fixed local map v20260723-3 */
.entity-stop-map .ymaps-2-1-79-controls__control,
.entity-stop-map .ymaps-2-1-79-controls__toolbar {
    display: none !important;
}

.entity-stop-map {
    cursor: grab;
}

.entity-stop-map:active {
    cursor: grabbing;
}


/* Stop map v20260723-4:
   viewport ~300 m, rendering cache ~1 km. */


/* Stop map v20260723-5: карта полностью зафиксирована. */
.entity-stop-map,
.entity-stop-map:active {
    cursor: default !important;
}

/* Скрываем любые элементы управления, если API добавит их автоматически. */
.entity-stop-map
.ymaps-2-1-79-controls__control,
.entity-stop-map
.ymaps-2-1-79-controls__toolbar,
.entity-stop-map
.ymaps-2-1-79-controls-pane {
    display: none !important;
}


/* ================================================================
   Полное расписание на странице STOP_AREA, v20260724-1
   Повторяет визуальную структуру расписания в balloon карты.
   ================================================================ */

.stop-page-schedule-section {
    overflow: hidden;
}

.stop-page-schedule-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 12px;
}

.stop-page-schedule-heading h2 {
    margin-bottom: 3px;
}

.stop-page-schedule-summary {
    color: #667085;
    font-size: 11px;
    line-height: 1.4;
}

.stop-page-schedule-legend {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 5px 8px;
    color: #667085;
    font-size: 10px;
    line-height: 1.35;
    text-align: right;
}

.stop-page-nearest-sample {
    display: inline-block;
    padding: 2px 5px;
    border: 1px solid #32d583;
    border-radius: 4px;
    background: #ecfdf3;
    color: #067647;
    font-weight: 700;
}

.stop-page-schedule-routes {
    display: grid;
    gap: 10px;
}

.stop-page-route-block {
    overflow: hidden;
    border: 1px solid #d0d5dd;
    border-radius: 8px;
    background: #fff;
}

.stop-page-route-header {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    align-items: stretch;
    min-height: 48px;
}

.stop-page-route-number-cell {
    display: grid;
    place-items: center;
    padding: 7px;
}

.stop-page-route-number {
    display: inline-grid;
    place-items: center;
    min-width: 38px;
    height: 30px;
    padding: 0 7px;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    font-size: 15px;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
}

.stop-page-route-number:hover {
    background: #175cd3;
    text-decoration: none;
}

.stop-page-route-following {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 6px 9px 6px 0;
}

.stop-page-route-caption {
    margin-bottom: 2px;
    color: #98a2b3;
    font-size: 8px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.stop-page-route-following strong {
    overflow: hidden;
    color: #182230;
    font-size: 12px;
    line-height: 1.25;
    text-overflow: ellipsis;
}

.stop-page-route-divider {
    height: 1px;
    margin: 0 8px;
    background: #eaecf0;
}

.stop-page-time-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    margin: 0;
}

.stop-page-time-table td {
    padding: 6px 4px;
    border: 0;
    border-right: 1px solid #eaecf0;
    border-bottom: 1px solid #eaecf0;
    color: #344054;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
}

.stop-page-time-table tr:last-child td {
    border-bottom: 0;
}

.stop-page-time-table td:last-child {
    border-right: 0;
}

.stop-page-time-cell.is-nearest {
    outline: 1px solid #32d583;
    outline-offset: -1px;
    background: #ecfdf3;
    color: #067647;
}

.stop-page-time-cell.is-next-day {
    background: #eff8ff;
    color: #175cd3;
}

.stop-page-time-cell.is-nearest.is-next-day {
    background: #ecfdf3;
    color: #067647;
}

.stop-page-time-cell.is-empty {
    color: transparent;
    background: #fff;
}

@media (max-width: 720px) {
    .stop-page-schedule-heading {
        flex-direction: column;
    }

    .stop-page-schedule-legend {
        justify-content: flex-start;
        text-align: left;
    }

    .stop-page-route-header {
        grid-template-columns: 50px minmax(0, 1fr);
    }

    .stop-page-time-table td {
        padding: 6px 2px;
        font-size: 10px;
    }
}


/* ================================================================
   Расписание по физическим STOP_POINT / путям, v20260724-2
   ================================================================ */

.stop-page-path-list {
    display: grid;
    gap: 16px;
}

.stop-page-path-block {
    overflow: hidden;
    border: 2px solid #d0d5dd;
    border-radius: 10px;
    background: #f9fafb;
}

.stop-page-path-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
    padding: 12px 14px;
    border-bottom: 1px solid #d0d5dd;
    background: #f2f4f7;
}

.stop-page-path-kicker {
    margin-bottom: 2px;
    color: #667085;
    font-size: 9px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.stop-page-path-header h3 {
    margin: 0;
    color: #101828;
    font-size: 19px;
    line-height: 1.15;
}

.stop-page-path-direction {
    margin-top: 4px;
    color: #344054;
    font-size: 12px;
    line-height: 1.35;
}

.stop-page-path-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 5px;
    max-width: 320px;
}

.stop-page-path-meta span {
    padding: 3px 6px;
    border: 1px solid #d0d5dd;
    border-radius: 999px;
    background: #fff;
    color: #667085;
    font-size: 9px;
    white-space: nowrap;
}

.stop-page-path-block
.stop-page-schedule-routes {
    gap: 8px;
    padding: 10px;
}

.stop-page-path-block
.stop-page-route-block {
    background: #fff;
}

.stop-page-path-no-schedule {
    display: grid;
    gap: 3px;
    margin: 10px;
    padding: 12px;
    border: 1px dashed #d0d5dd;
    border-radius: 8px;
    background: #fff;
    color: #667085;
    font-size: 11px;
    line-height: 1.45;
}

.stop-page-path-no-schedule strong {
    color: #475467;
    font-size: 12px;
}

@media (max-width: 720px) {
    .stop-page-path-header {
        flex-direction: column;
    }

    .stop-page-path-meta {
        justify-content: flex-start;
        max-width: none;
    }
}


/* Маркер движущегося трамвая задаётся единообразно в assets/vehicle-marker.css. */

.vehicle-balloon-note {
    color: #667085;
    font-size: 10px;
    line-height: 1.35;
}




/* ================================================================
   Ближайшие рейсы по каждому STOP_POINT в правой колонке,
   build 20260724-4
   ================================================================ */

.stop-nearest-sidebar-card {
    overflow: hidden;
}

.stop-nearest-point-list {
    display: grid;
    gap: 10px;
}

.stop-nearest-point {
    overflow: hidden;
    border: 1px solid #d0d5dd;
    border-radius: 8px;
    background: #fff;
}

.stop-nearest-point-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 9px;
    border-bottom: 1px solid #eaecf0;
    background: #f9fafb;
}

.stop-nearest-point-head > div {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.stop-nearest-point-head strong {
    color: #101828;
    font-size: 12px;
    line-height: 1.2;
}

.stop-nearest-point-head span {
    color: #667085;
    font-size: 10px;
    line-height: 1.3;
}

.stop-nearest-point-head small {
    flex: 0 0 auto;
    color: #98a2b3;
    font-size: 8px;
    white-space: nowrap;
}

.stop-nearest-route-list {
    display: grid;
}

.stop-nearest-route-row {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        auto;
    align-items: center;
    gap: 8px;
    padding: 7px 8px;
    border-bottom: 1px solid #eaecf0;
}

.stop-nearest-route-row:last-child {
    border-bottom: 0;
}

.stop-nearest-route-main {
    display: grid;
    grid-template-columns:
        auto
        minmax(0, 1fr);
    align-items: center;
    gap: 7px;
    min-width: 0;
}

.stop-nearest-route-badge {
    min-width: 35px;
    padding-left: 6px;
    padding-right: 6px;
}

.stop-nearest-route-direction {
    min-width: 0;
    overflow: hidden;
    color: #344054;
    font-size: 10px;
    line-height: 1.25;
    text-overflow: ellipsis;
}

.stop-nearest-route-time {
    display: grid;
    justify-items: end;
    gap: 1px;
    min-width: 66px;
    color: #475467;
    text-align: right;
}

.stop-nearest-route-time strong {
    color: #101828;
    font-size: 11px;
    line-height: 1.15;
    white-space: nowrap;
}

.stop-nearest-route-time > span {
    font-size: 9px;
    line-height: 1.15;
}

.stop-nearest-no-trip {
    max-width: 74px;
    color: #98a2b3 !important;
    font-size: 9px !important;
    line-height: 1.2 !important;
    white-space: normal !important;
}

.stop-nearest-empty {
    padding: 9px;
    color: #667085;
    font-size: 10px;
    line-height: 1.4;
}

@media (max-width: 920px) {
    .stop-nearest-route-row {
        grid-template-columns:
            minmax(0, 1fr)
            auto;
    }
}


/* ================================================================
   Динамическое ближайшее время по часам устройства,
   build 20260724-5
   ================================================================ */

#stopPageClientClock {
    font-weight: 700;
    color: #344054;
    font-variant-numeric: tabular-nums;
}

.stop-page-device-time-label {
    color: #98a2b3;
    font-size: 9px;
}

.stop-nearest-live-wait,
.stop-nearest-live-time {
    font-variant-numeric: tabular-nums;
}

/*
 * При смене ближайшего рейса JS переносит этот класс с одной
 * ячейки на другую без перезагрузки страницы.
 */
.stop-page-time-cell.is-nearest {
    position: relative;
    z-index: 1;
}


/* Тип использования путей маршрутами на карте остановки. */
.entity-track-usage-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 7px 14px;
    margin-top: 7px;
}

.entity-track-usage-legend > span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.entity-track-usage-rail {
    position: relative;
    display: inline-block;
    width: 26px;
    height: 8px;
    flex: 0 0 26px;
    border-radius: 4px;
    background: #1f2937;
}

.entity-track-usage-rail::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 2px;
    height: 4px;
    border-radius: 2px;
}

.entity-track-usage-rail--used {
    opacity: .90;
}

.entity-track-usage-rail--used::after {
    background: #fff;
}

.entity-track-usage-rail--unused {
    background: #514733;
    opacity: .96;
}

.entity-track-usage-rail--unused::after {
    background: #a98b4f;
}


.entity-segment-type-legend{display:flex;flex-wrap:wrap;gap:6px 12px;margin-top:8px}.entity-segment-type-legend>span{display:inline-flex;align-items:center;gap:5px}.entity-segment-swatch{display:inline-block;width:24px;height:7px;border-radius:4px}.entity-segment-swatch--tram-overhead {
    position: relative;
    background: #fff;
    border: 3px solid #1f2937;
    height: 9px;
}.entity-segment-swatch--tram-battery {
    background: #fff;
    border: 3px solid #1f2937;
    height: 9px;
}.entity-segment-swatch--third-center{background:#facc15;border:2px solid #3f3f46}.entity-segment-swatch--road{background:#cbd5e1;border:3px solid #475569}.entity-segment-swatch--water{background:#93c5fd;border:2px solid #1d4ed8}.entity-segment-swatch--trolley{background:#99f6e4;border:2px dashed #0f766e}

.entity-segment-swatch--tram-overhead::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 1px;
    background: #374151;
    transform: translateY(-50%);
}
