.breadcrumb-nav {
    margin-bottom: 1rem;
}

.breadcrumbs-trail {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 1.2rem;
    line-height: 1.5;
    color: #64748b;
    white-space: nowrap;
    overflow-x: auto;
}

.breadcrumbs-trail .breadcrumb-item {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.breadcrumbs-trail .breadcrumb-item + .breadcrumb-item::before {
    content: "";
    flex-shrink: 0;
    width: 1.15rem;
    height: 1.15rem;
    margin: 0 0.5rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none'%3E%3Cpath d='M7.5 5L12.5 10L7.5 15' stroke='%2394a3b8' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

.breadcrumbs-trail .breadcrumb-item a {
    color: #475569;
    text-decoration: none;
    border-radius: 0.25rem;
    transition: color 0.15s ease;
}

.breadcrumbs-trail .breadcrumb-item a:hover,
.breadcrumbs-trail .breadcrumb-item a:focus-visible {
    color: #0f172a;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.breadcrumbs-trail .breadcrumb-item.is-current span {
    color: #0f172a;
    font-weight: 600;
}

.order-trains-editor tr.train-row-cancelled td {
    text-decoration: line-through;
    color: #94a3b8;
}

.order-trains-editor tr.train-row-cancelled td.select-checkbox,
.order-trains-editor tr.train-row-cancelled td.control {
    text-decoration: none;
}

.order-trains-editor #order-trains-table th.select-checkbox,
.order-trains-editor #order-trains-table td.select-checkbox {
    text-align: center;
    vertical-align: middle;
    width: 2.5rem;
    min-width: 2.5rem;
    max-width: 2.5rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
    box-sizing: border-box;
}

.order-trains-editor #order-trains-table td.select-checkbox {
    position: relative;
}

.order-trains-editor #order-trains-table td.select-checkbox:before,
.order-trains-editor #order-trains-table td.select-checkbox:after,
.order-trains-editor #order-trains-table th.select-checkbox:before,
.order-trains-editor #order-trains-table th.select-checkbox:after {
    left: 50%;
    top: 50%;
    margin-left: -9px;
    margin-top: -9px;
}

.order-trains-editor #order-trains-table td.train-actions {
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
}

.order-trains-editor #order-trains-table td.train-actions a.fa {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.train-cancellation-view .order-view-value:empty::before {
    content: '—';
    color: #94a3b8;
}

@media only screen and (max-width: 1300px) {
    /**
     * General
     */
    .mobile-hide {
        display: none;
    }

    /**
     * Navigation — see nav.css
     */
    /**
     * Reports
     */
    .related {
        margin-bottom: 10px;
    }
    .invoices .error {
        background-color: #ff0000;
        color: #fff;
    }
}
/**
 * Desktop
 */
@media only screen and (min-width: 1299px) {
    .invoices .error {
        background-color: #ff0000;
        color: #fff;
    }
    .row {
        flex-direction: column;
        display: block;
        width: 100%;
    }

    .breadcrumbs {
        margin-bottom: 20px;
    }

    .content {
        margin-bottom: 10px;
    }

    /* General */
    form select.high {
        min-height: 80px;
    }

    form select.very_high {
        min-height: 180px;
    }

    form textarea.high {
        min-height: 120px;
    }

    .ui-datepicker,
    #ui-datepicker-div {
        width: 20em;
    }

    .clearfix {
        clear: both;
    }

    /* Navigation — see nav.css */

    /**
     * Login
     */
    div.login {
        margin: 40px;
    }

    .login-page {
        max-width: 28rem;
        margin: 2rem auto;
        padding: 1.5rem;
        background: #fff;
        border: 1px solid #e2e8f0;
        border-radius: 0.55rem;
        box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    }

    .login-page h2 {
        margin-top: 0;
        margin-bottom: 0.5rem;
    }

    .login-page p {
        margin-top: 0;
        margin-bottom: 1.25rem;
        color: #64748b;
    }

    .social-login-options {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
    }

    .social-login-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.65rem;
        min-height: 2.75rem;
        padding: 0.55rem 0.9rem;
        border: 1px solid #cbd5e1;
        border-radius: 0.4rem;
        background: #fff;
        color: #334155;
        text-decoration: none;
        box-sizing: border-box;
        transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    }

    .social-login-button:hover,
    .social-login-button:focus {
        background: #f8fafc;
        border-color: #94a3b8;
        box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
    }

    .social-login-google img {
        display: block;
        max-width: 100%;
        height: auto;
    }

    .social-login-microsoft {
        font-size: 0.95rem;
        font-weight: 600;
    }

    .social-login-icon img {
        display: block;
        width: 1.1rem;
        height: 1.1rem;
    }

    .oauth-debug-hint {
        margin: 1rem 0 0;
        padding: 0.65rem 0.75rem;
        border: 1px dashed #cbd5e1;
        border-radius: 0.35rem;
        background: #fff;
        color: #64748b;
        font-size: 0.8rem;
        line-height: 1.4;
        word-break: break-all;
    }

    .oauth-debug-hint code {
        color: #334155;
    }

    /**
     * Modules
     */
    .modules-index-toolbar {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
        gap: 1rem;
        margin-bottom: 0.75rem;
    }

    .modules-index-toolbar__search {
        grid-column: 1;
        justify-self: start;
    }

    .modules-index-toolbar__center {
        grid-column: 2;
        justify-self: center;
    }

    .modules-name-search {
        width: 100%;
        min-width: 16rem;
        max-width: 24rem;
        padding: 0.5rem 0.75rem;
        border: 1px solid #ced4da;
        border-radius: 0.25rem;
    }

    @media (max-width: 640px) {
        .modules-index-toolbar {
            grid-template-columns: 1fr;
        }

        .modules-index-toolbar__center,
        .modules-index-toolbar__search {
            grid-column: 1;
            justify-self: stretch;
        }

        .modules-name-search {
            max-width: none;
        }
    }

    .modules .search input,
    .modules .search label {
        width: 250px;
        display: inline;
    }

    .modules .search input {
        margin-left: 30px;
    }

    .modules .search .input {
        display: inline;
    }

    .modules .search button {
        margin: 0 20px;
    }

    /* Plan */
    .plan label,
    .plan input {
        display: inline;
    }

    .plan .toggle {
        display: none;
    }

    .plan td span,
    .personalPlan td span, {
        font-weight: bold;
    }


    .plan-modules td {
        vertical-align: top;
    }

    /**
     * Personify
     */
    #personify fieldset {
        border: 1px solid black;
        padding: 5px;
    }

    /**
     * Personal Plan
     */
    .related table.table-modules {
        display: none;
    }

    /**
     * News
     */
    #news {
        padding: 15px;
    }

    #news #title {
        float: left;
    }

    #news #author {
        float: right;
    }

    #news .article {
        background-color: #ccc;
        padding: 10px;
        margin-bottom: 30px;
    }

    div.error-message {
        background-color: #ff4d4d;
        color: #fff;
        padding: 5px;
    }

    .reports tr.red td {
        color: #ff0000;
    }

    .reports .yellow .fa,
    .reports .green .fa,
    .reports .red .fa {
        background: none;
    }
    /*.reports .fa,
    .breadcrumbs .fa {
        color: #000;
        background:none;
    }*/

    .personalPlan td.dt-center {
        padding-left: 4px;
        padding-right: 0;
    }

    .personalPlan td .fa {
        margin-left: 0;
    }

    .personalPlan .table {
        width: 97%;
    }

    .reports .actions .right {
        margin-left: 10px;
    }

    #activitys .float .inline,
    .reportsActivities .inline div.input {
        float: left;
        margin-left: 10px;
        width: 200px;
    }

    .view.content .select {
        margin-top: 1.2rem;
    }

    .float-right span {
        margin-left: 3px;
    }

    .plan .button {
        margin-left: 10px;
    }

    /**
     * Sorter
     */
    #sorter .input {
        width: auto;
        float: left;
        margin-left: 15px;
    }

    #sorter select {
        width: 200px;
    }

    #sorter button {
        margin-top: 50px;
        margin-left: 15px;
    }

    #sorter .date {
        margin-left: 15px;
    }

    #sorter a {
        margin-top: 50px;
        margin-left: 15px;
    }

    /**
     * Header
     */
    body .top-nav {
        #max-width: 60%;
    }

    div.dt-buttons {
        float: none !important;
    }

    .dt-buttons .break {
        float: right;
    }

}

.dt-buttons button.dt-button {
    min-height: 2.5rem;
    padding: 0.65rem 1rem;
    font-size: 1.05rem;
    line-height: 1.2;
}
/**
 * FileUpload
 */
@media only screen and (min-width: 760px) {
    #dragandrophandler {
        width: min(700px, 100%);
    }
}

#dragandrophandler {
    border: 2px solid #0B85A1;
    height: 60px;
    color: #92AAB0;
    text-align: left;
    vertical-align: middle;
    padding: 0 10px 10px;
    margin: 30px 0;
    font-size: 200%;
    max-width: 100%;
    box-sizing: border-box;
}

.progressBar {
    width: 200px;
    height: 22px;
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    display: inline-block;
    margin: 0px 10px 5px 5px;
    vertical-align: top;
}

.progressBar div {
    height: 100%;
    color: #fff;
    text-align: right;
    line-height: 22px; /* same as #progressBar height if we want text middle aligned */
    width: 0;
    background-color: #0ba1b5;
    border-radius: 3px;
}

.statusbar {
    border-top: 1px solid #A9CCD1;
    min-height: 25px;
    width: min(700px, 100%);
    max-width: 100%;
    padding: 10px 10px 0px 10px;
    vertical-align: top;
    box-sizing: border-box;
}

.statusbar:nth-child(odd) {
    background: #EBEFF0;
}

.filename {
    display: inline-block;
    vertical-align: top;
    width: min(350px, 50%);
    max-width: 100%;
}

.filesize {
    display: inline-block;
    vertical-align: top;
    color: #30693D;
    width: 100px;
    margin-left: 10px;
    margin-right: 5px;
}

.abort {
    background-color: #A8352F;
    -moz-border-radius: 4px;
    -webkit-border-radius: 4px;
    border-radius: 4px;
    display: inline-block;
    color: #fff;
    font-family: arial;
    font-size: 13px;
    font-weight: normal;
    padding: 4px 15px;
    cursor: pointer;
    vertical-align: top
}

#file_uploads {
    padding: 5px;
}

#status {
    margin-bottom: 40px;
}

/**
 * General
 */

td.green span {
    color: green !important;
}

td.yellow span {
    color: orange !important;
}

td.red span {
    color: red !important;
}
.reports .status .fa {
    background: none;
}
.actions a,
.fa,
.reports .actions a {
    color: #fff;
    background-color: #04AA6D;
    padding: 5px;
    border-radius: .9rem;
    margin-left: 5px;
}
    /**
       * News
       */
    #news {
        padding: 15px;
    }

    #news #title {
        float: left;
    }

    #news #author {
        float: right;
    }

    #news .article {
        background-color: #ccc;
        padding: 10px;
        margin-bottom: 30px;
    }
}
.status-red{color:#c0392b;font-weight:bold;}
.status-green{color:#27ae60;font-weight:bold;}
.status-yellow{color:#f1c40f;font-weight:bold;}
.status-orange{color:#d35400;font-weight:bold;}

.main a.fa span {
    font-family: Helvetica Neue, Helvetica, Arial, sans-serif;
}


.filters-panel {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.85rem 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem 1.15rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.55rem;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.filters-title {
    flex: 0 0 100%;
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
}

.filters-fields {
    display: flex;
    flex: 1 1 auto;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.85rem 1rem;
    min-width: 0;
}

.filters-panel .filters-fields .input {
    float: none;
    flex: 1 1 12rem;
    min-width: 12rem;
    max-width: 18rem;
    width: auto;
    margin: 0;
}

.filters-panel .filters-fields .input.checkbox {
    flex: 0 0 auto;
    min-width: auto;
    max-width: none;
    align-self: flex-end;
}

.filters-panel .filters-fields label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: #475569;
}

.filters-panel .filters-fields .input.checkbox label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    height: var(--form-control-height);
    margin: 0;
    padding: 0 0.15rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    white-space: nowrap;
}

.filters-panel .filters-fields .input.checkbox input[type="checkbox"] {
    width: 1rem;
    height: 1rem;
    margin: 0;
    accent-color: #1e293b;
    cursor: pointer;
}

.filter-actions {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    gap: 0.5rem;
    align-items: stretch;
    align-self: flex-end;
    margin: 0;
    padding: 0;
    border-top: none;
}

form.list-filters button[type="submit"]:not(.dt-button):not(.ui-button) {
    margin: 0;
}

.filter-actions > .button,
.filter-actions > button,
.filter-actions > a.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    height: 3rem;
    min-height: 3rem;
    max-height: 3rem;
    margin: 0;
    padding: 0 1.15rem;
    border-width: 1px;
    line-height: 1;
    font-size: 1.05rem;
    box-sizing: border-box;
    vertical-align: middle;
}

.filters-empty-hint {
    margin: 0 0 1.5rem;
    padding: 0.85rem 1rem;
    border: 1px dashed #cbd5e1;
    border-radius: 0.5rem;
    background: #fff;
    color: #64748b;
    font-size: 0.9rem;
}

.filters-empty-hint p {
    margin: 0;
}

.content .page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.content .page-header h3 {
    margin: 0;
}

.content .page-header .button {
    flex-shrink: 0;
}

@media (max-width: 640px) {
    .content .page-header {
        flex-direction: column;
        align-items: stretch;
    }

    .content .page-header .button {
        width: 100%;
        justify-content: center;
    }
}


.DTE_Form_Content .station-autocomplete__suggestions,
.station-autocomplete__suggestions {
    position: fixed;
    margin: 0;
    padding: 0;
    list-style: none;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
    max-height: 240px;
    overflow-y: auto;
    z-index: 10050;
}

.station-autocomplete__suggestions--hidden {
    display: none;
}

.station-autocomplete__suggestions li {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    line-height: 1.35;
}

.station-autocomplete__suggestions li:hover {
    background: #f0f4f8;
}

.station-autocomplete,
.DTE_Field_InputControl.station-autocomplete-host {
    position: relative;
}

.DTE_Inline .station-autocomplete__suggestions,
.DTE_Form_Content .station-autocomplete__suggestions {
    z-index: 10050;
}

.DTE_Form_Content .suggestions {
    position: fixed;
    background: #fff;
    border: 1px solid #ccc;
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 240px;
    overflow-y: auto;
    z-index: 10050;
    border-radius: 4px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}
.DTE_Form_Content .suggestions li {
    padding: 5px;
    cursor: pointer;
}
.DTE_Form_Content .suggestions li:hover {
    background: #f0f0f0;
}
th.delete {
    display: none;
}

/* =====================================================================
   Train route timeline + carded train form/view styling
   (moved here from cake.css; loaded after cake.css so overrides apply)
   ===================================================================== */

/* ---- Route timeline (start / intermediate stops / end) ---- */
.order-train-route-heading {
    margin: 0 0 0.85rem;
}

.order-train-route {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding-left: 1.85rem;
}

/* Vertical connector line running down the marker column. */
.order-train-route::before {
    content: "";
    position: absolute;
    left: 0.6rem;
    top: 0.45rem;
    bottom: 0.45rem;
    width: 2px;
    background: linear-gradient(#22c55e, #cbd5e1 18%, #cbd5e1 82%, #ef4444);
    border-radius: 2px;
}

.order-train-route-point {
    position: relative;
}

.order-train-route-marker {
    position: absolute;
    left: -1.85rem;
    top: 1.95rem;
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: #fff;
    background: #94a3b8;
    box-shadow: 0 0 0 3px #fff;
    z-index: 1;
}

.order-train-route-marker--start {
    background: #22c55e;
}

.order-train-route-marker--end {
    background: #ef4444;
}

.order-train-route-marker--stop {
    top: 1.95rem;
    width: 0.85rem;
    height: 0.85rem;
    left: -1.62rem;
    background: #fff;
    border: 3px solid #94a3b8;
    box-shadow: 0 0 0 2px #fff;
}

.order-train-route-point.is-split > .order-train-route-marker--stop {
    border-color: #f59e0b;
    background: #f59e0b;
}

.order-train-route-fields {
    display: grid;
    gap: 0.6rem 0.9rem;
    align-items: end;
    padding: 0.55rem 0.7rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
}

.order-train-route-fields--terminal {
    /* Keep in sync with route-timeline.css — station column ~34% */
    grid-template-columns: minmax(0, 34%) minmax(0, 1fr) minmax(0, 1fr);
}

.order-train-route-point--start > .order-train-route-fields {
    border-left: 3px solid #22c55e;
}

.order-train-route-point--end > .order-train-route-fields {
    border-left: 3px solid #ef4444;
}

.order-train-route-fields--stop {
    position: relative;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 0.75fr) minmax(0, 1fr) minmax(0, 1.05fr) minmax(0, 1.05fr) minmax(0, 0.6fr) minmax(0, 0.8fr) minmax(0, 1fr) auto;
    background: #f8fafc;
    border-left: 3px solid #cbd5e1;
}

.order-train-stop-personnel-field {
    min-width: 0;
}

.order-train-stop-personnel-control {
    display: flex;
    align-items: center;
    min-height: 2.4rem;
}

.order-train-stop-personnel-control input[type="checkbox"] {
    width: 1.1rem;
    height: 1.1rem;
    margin: 0;
    accent-color: var(--color-primary, #1d4ed8);
    cursor: pointer;
    flex-shrink: 0;
}

.order-train-route-point--stop.is-split > .order-train-route-fields--stop {
    border-left-color: #f59e0b;
    background: #fffbeb;
}

/* Stops wrapper sits between the start and end route points. */
.order-train-route-stops-wrap[hidden] {
    display: none !important;
}

.order-train-route-stops {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.order-train-route-stops__rows {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.order-train-route-stops__rows:empty {
    display: none;
}

.order-train-route-stops__actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.9rem;
}

.order-train-route-stops__hint {
    font-size: 0.8rem;
    color: #64748b;
}

.order-train-add-stop {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.4rem 0.85rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: #1d4ed8;
    background: #eff6ff;
    border: 1px dashed #93c5fd;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.order-train-add-stop:hover {
    background: #dbeafe;
    border-color: #60a5fa;
}

.order-train-add-stop__icon {
    font-size: 1.05rem;
    line-height: 1;
    font-weight: 700;
}

.order-train-stop-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: end;
    justify-self: center;
    position: relative;
    z-index: 5;
    box-sizing: border-box;
    width: 2.75rem;
    height: 2.75rem;
    margin-bottom: 0.05rem;
    padding: 0;
    border: 1px solid #fca5a5;
    border-radius: 10px;
    background: #fff;
    color: #dc2626;
    font-size: 1.85rem;
    font-weight: 400;
    line-height: 1;
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.order-train-stop-remove:hover {
    background: #fee2e2;
    border-color: #ef4444;
    color: #b91c1c;
}

/* ---- Read-only route timeline (train / order view) ---- */
.order-train-route--view {
    padding-top: 0.35rem;
}

.order-train-route-meta {
    margin: 0 0 0.65rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
}

.order-train-route-leg-driver {
    display: flex;
    align-items: center;
    margin: 0.15rem 0 0.15rem 1.85rem;
    padding: 0.35rem 0.65rem;
    border-left: 0.2rem solid #0f766e;
    background: #f0fdfa;
    color: #115e59;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    border-radius: 0 0.25rem 0.25rem 0;
}

.order-train-route-leg-driver__name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-train-route-leg-number {
    display: flex;
    align-items: center;
    margin: 0.15rem 0 0.15rem 1.85rem;
    padding: 0.3rem 0.65rem;
    border-left: 0.2rem solid #1d4ed8;
    background: #eff6ff;
    color: #1e3a8a;
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.3;
    border-radius: 0 0.25rem 0.25rem 0;
}

.order-train-route-leg-number__label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-train-route-fields--view {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 1.6rem;
    align-items: baseline;
    background: #fff;
}

.order-train-route-view-field {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.order-train-route-view-field--station {
    min-width: 12rem;
    flex: 0 1 auto;
}

.order-train-route-view-field--track {
    flex: 0 0 auto;
    min-width: 4.5rem;
}

.order-train-route-view-field--time {
    text-align: right;
}

/* Push the time group to the right; keep station + track on the left. */
.order-train-route-view-field:not(.order-train-route-view-field--time) + .order-train-route-view-field--time {
    margin-left: auto;
}

.order-train-route-view-label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.order-train-route-view-value {
    font-size: 0.95rem;
    color: #1f2937;
}

.order-train-route-view-value--station {
    font-weight: 600;
}

.order-train-route-view-empty {
    color: #94a3b8;
    font-weight: 400;
    font-style: italic;
}

.order-train-route-stop-badge {
    font-size: 0.62rem;
    text-transform: none;
    letter-spacing: 0;
}

/* ---- Larger emphasis for start/end stations and their times ---- */
.order-train-route-point--start .order-train-route-view-value--station,
.order-train-route-point--end .order-train-route-view-value--station {
    font-size: 1.3rem;
    font-weight: 700;
}

.order-train-route-point--start .order-train-route-view-value,
.order-train-route-point--end .order-train-route-view-value {
    font-size: 1.1rem;
}

/* ---- Carded field groups (match the route boxes across view + edit) ---- */
.order-train-section {
    border-bottom: 0;
    padding: 0.6rem 0;
}

.order-train-inline-form .order-train-section-grid,
.order-train-sections .order-train-section-grid,
.order-train-inline-form .order-train-form-field--information {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
    padding: 0.75rem 0.9rem;
}

/* Read-only values sit as clean text inside the carded groups. */
.order-train-sections .order-view-value {
    min-height: 0;
    font-size: 1rem;
    color: #1f2937;
}

.order-train-sections .order-view-label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #94a3b8;
}

/* Train number: scannable; information: dominant readable signal */
.order-train-sections [data-train-number-display] {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.35;
    color: #0f172a;
}

.order-train-sections .order-view-field--information .order-view-value {
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.4;
    color: #0f172a;
}

.order-train-sections .order-view-field--information .order-view-value p {
    margin: 0 0 0.35em;
    font-size: inherit;
    font-weight: inherit;
}

.order-train-sections .order-view-field--information .order-view-value p:last-child {
    margin-bottom: 0;
}

@media (max-width: 900px) {
    .order-train-route-fields--terminal {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .order-train-route-fields--terminal .order-train-route-station {
        grid-column: 1 / -1;
    }

    .order-train-route-fields--stop {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .order-train-route-fields--stop .order-train-stop-note-field {
        grid-column: 1 / -1;
    }

    .order-train-stop-remove {
        position: absolute;
        top: 0.35rem;
        right: 0.35rem;
        width: 2.4rem;
        height: 2.4rem;
        font-size: 1.65rem;
        margin: 0;
    }
}
