:root {
    --bf-page: #eeeeee;
    --bf-card: #ffffff;
    --bf-ink: #132647;
    --bf-muted: #626978;
    --bf-border: #d7d9de;
    --bf-blue: #165bd6;

    /* Darker orange mixture */
    --bf-orange: #d95808;
    --bf-orange-gradient: linear-gradient(
        115deg,
        #ed790e 0%,
        #d65a06 55%,
        #b83d05 100%
    );

    --bf-radius: 16px;
    --bf-shadow:
        0 5px 8px rgba(0, 0, 0, .10),
        0 1px 3px rgba(0, 0, 0, .05);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bf-page);
    color: var(--bf-ink);
    font-family: 'DM Sans', 'Avenir Next', Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
}

a {
    color: var(--bf-blue);
    text-decoration: none;
}

button,
input,
select {
    font: inherit;
}

button,
a,
input,
select {
    -webkit-tap-highlight-color: transparent;
}

:focus-visible {
    outline: 3px solid #2469dc;
    outline-offset: 3px;
}

[hidden] {
    display: none !important;
}

.bf-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 18px max(24px, calc((100% - 1260px) / 2));
    background: #fff;
}

.bf-brand {
    display: grid;
    color: var(--bf-ink);
    flex-shrink: 0;
}

.bf-brand strong {
    font-size: 42px;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -.04em;
}

.bf-brand span {
    margin-top: 6px;
    font-size: 12px;
}

.bf-header nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.bf-header nav > a {
    white-space: nowrap;
}

.bf-tabs {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 78px;
    padding: 10px 20px;
    background: #101c35;
}

.bf-tabs a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    min-width: 175px;
    padding: 17px 25px;
    color: #fff;
    font-weight: 700;
    border-radius: 5px;
}

.bf-tabs a.active {
    background: var(--bf-orange-gradient);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25);
}

.bf-tabs svg {
    width: 23px;
    height: 23px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
}

.bf-container {
    width: min(1260px, calc(100% - 48px));
    margin: 24px auto 50px;
    min-height: 65vh;
}

.bf-card {
    border: 1px solid #e5e5e5;
    border-radius: var(--bf-radius);
    background: var(--bf-card);
    box-shadow: var(--bf-shadow);
}

.bf-button,
.bf-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    cursor: pointer;
    transition: transform 180ms ease, opacity 180ms ease;
}

.bf-button {
    border: 1px solid #bd4d08;
    background: var(--bf-orange-gradient);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22);
}

.bf-outline {
    border: 1px solid var(--bf-blue);
    background: #fff;
    color: var(--bf-blue);
}

.bf-button:active,
.bf-outline:active {
    transform: scale(.98);
}

.bf-button:disabled {
    opacity: .5;
    cursor: not-allowed;
}

@media (hover: hover) {
    .bf-button:not(:disabled):hover,
    .bf-outline:hover {
        transform: translateY(-2px);
    }
}

.bf-search {
    padding: 16px;
    margin-bottom: 22px;
}

.bf-search-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.bf-chip {
    display: inline-block;
    padding: 7px 12px;
    border-radius: 12px;
    background: #ffeadb;
    color: #96400a;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.bf-pax {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
}

.bf-pax select {
    max-width: 165px;
    padding: 8px;
    border: 1px solid var(--bf-border);
    border-radius: 6px;
    background: #fff;
    color: var(--bf-ink);
}

.bf-search-fields {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) auto minmax(180px, 1fr) 180px;
    gap: 12px;
    align-items: center;
}

.bf-control {
    display: grid;
    min-width: 0;
    gap: 3px;
    min-height: 62px;
    padding: 8px 16px;
    border: 1px solid #bfc2c9;
    border-radius: 15px;
}

.bf-control > span {
    color: var(--bf-muted);
    font-size: 12px;
}

.bf-control select,
.bf-control input {
    width: 100%;
    min-width: 0;
    padding: 0;
    border: 0;
    background: #fff;
    color: var(--bf-ink);
    font-weight: 650;
}

.bf-swap {
    width: 42px;
    height: 42px;
    border: 1px solid var(--bf-border);
    border-radius: 50%;
    background: #fff;
    color: #b74606;
    font-size: 25px;
    cursor: pointer;
}

.bf-search-fields > .bf-button {
    min-height: 62px;
}

.bf-layout {
    display: grid;
    grid-template-columns: minmax(260px, .88fr) minmax(0, 2.12fr);
    align-items: start;
    gap: 22px;
}

.bf-summary {
    padding: 26px 18px;
    min-height: 440px;
}

.bf-summary h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 650;
}

.bf-summary h3 {
    margin: 0 0 14px;
    font-size: 14px;
}

.bf-summary-route {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 72px minmax(0, 1fr);
    align-items: center;
    text-align: center;
    gap: 4px;
    margin: 48px 0;
}

.bf-summary-route small {
    display: block;
    color: #757575;
    font-size: 10px;
    text-transform: uppercase;
    overflow-wrap: anywhere;
}

.bf-summary-route strong {
    display: block;
    font-size: 26px;
    color: #111;
}

.bf-route-line {
    display: grid;
    justify-items: center;
}

.bf-route-line svg {
    width: 43px;
    height: 25px;
    fill: #fff;
    stroke: #1b1b1b;
    stroke-width: 1.4;
}

.bf-route-line > span {
    color: #333;
    line-height: .8;
}

.bf-facts {
    margin: 0;
    color: #353535;
    font-size: 12px;
}

.bf-facts > div,
.bf-price-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    margin: 8px 0;
}

.bf-facts dd {
    margin: 0;
    text-align: right;
}

.bf-summary-divider {
    height: 1px;
    margin: 24px 0;
    background: #e8b59c;
}

.bf-summary-hint {
    color: #595959;
    font-size: 11px;
    font-style: italic;
    text-align: center;
}

.bf-price-row {
    font-size: 12px;
}

.bf-total {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid #e8b59c;
    font-size: 17px;
}

.bf-main {
    min-width: 0;
}

.bf-main h1 {
    margin: 20px 8px;
    font-size: 19px;
    line-height: 1.4;
}

.bf-steps {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
}

.bf-back {
    display: inline-block;
    flex-shrink: 0;
    color: var(--bf-blue);
    font-weight: 650;
}

.bf-steps ol {
    display: flex;
    justify-content: space-between;
    flex: 1;
    gap: 12px;
    padding: 0;
    margin: 0;
    list-style: none;
}

.bf-steps li {
    display: flex;
    align-items: center;
    gap: 7px;
    color: #666;
    font-size: 11px;
}

.bf-steps li > span {
    display: grid;
    place-items: center;
    flex: 0 0 29px;
    width: 29px;
    height: 29px;
    border-radius: 50%;
    background: #e2e2e2;
    color: #333;
}

.bf-steps li.current {
    color: #151515;
}

.bf-steps li.current > span {
    background: var(--bf-orange-gradient);
    color: #fff;
}

.bf-steps li.complete > span {
    background: var(--bf-ink);
    color: #fff;
}

.bf-trip {
    display: grid;
    grid-template-columns: minmax(150px, .8fr) minmax(0, 1.7fr);
    gap: 20px;
    padding: 15px;
    margin-bottom: 18px;
}

.bf-trip-brand {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px 12px;
    background: #ededed;
    border-radius: 11px;
    text-align: center;
}

.bf-trip-brand strong {
    font-size: clamp(36px, 4vw, 64px);
    font-weight: 900;
    letter-spacing: -.05em;
    line-height: 1.1;
}

.bf-trip-brand span {
    font-size: 11px;
    font-weight: 600;
}

.bf-trip-content {
    min-width: 0;
}

.bf-trip-heading,
.bf-trip-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.bf-trip-heading h2 {
    margin: 0;
    color: #111;
    font-size: 28px;
}

.bf-muted {
    color: var(--bf-muted);
    font-size: 12px;
}

.bf-trip-route {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px;
    margin: 16px 0;
    background: #ededed;
    border-top: 1px dashed #bbb;
    border-bottom: 1px dashed #bbb;
    font-size: 11px;
    text-transform: uppercase;
}

.bf-trip-bottom > span {
    font-size: 12px;
}

.bf-fare {
    display: grid;
    text-align: right;
}

.bf-fare strong {
    font-size: 23px;
    color: #101010;
}

.bf-fare small {
    font-size: 10px;
    color: var(--bf-muted);
}

.bf-trip-bottom .bf-button {
    padding: 10px 15px;
    font-size: 12px;
}

.bf-unavailable {
    padding: 10px;
    border-radius: 8px;
    background: #eee;
    color: #555;
}

.bf-empty {
    padding: 70px 24px;
    text-align: center;
}

.bf-empty h2 {
    font-size: 21px;
}

.bf-empty p {
    color: var(--bf-muted);
    margin-bottom: 24px;
}

.bf-form {
    padding: 24px;
}

.bf-form > h1,
.bf-payment-heading h1 {
    margin: 0;
    font-size: 26px;
}

.bf-passenger {
    min-width: 0;
    margin: 22px 0;
    padding: 18px;
    border: 1px solid var(--bf-border);
    border-radius: 10px;
}

.bf-passenger legend {
    padding: 0 8px;
    font-size: 17px;
    font-weight: 700;
}

.bf-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.bf-fields label,
.bf-field {
    display: grid;
    gap: 7px;
    font-size: 13px;
}

.bf-fields input,
.bf-fields select,
.bf-field input {
    width: 100%;
    min-width: 0;
    min-height: 45px;
    padding: 10px 12px;
    border: 1px solid #bfc2c9;
    border-radius: 7px;
    background: #fff;
    color: var(--bf-ink);
}

.bf-fields input:disabled {
    background: #f2f2f2;
}

.bf-field {
    margin: 18px 0;
}

.bf-check {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: 13px;
}

.bf-check input {
    margin-top: 4px;
    accent-color: var(--bf-blue);
}

.bf-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 24px;
}

.bf-notice,
.bf-error {
    padding: 16px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.bf-notice {
    background: #edf7ed;
    color: #24532a;
    border: 1px solid #b7d6b8;
}

.bf-error {
    background: #fff0ec;
    color: #8f2c18;
    border: 1px solid #e9b7a9;
}

.bf-error ul {
    margin-bottom: 0;
}

.bf-seat-form {
    padding: 24px;
}

.bf-seat-intro > p {
    margin-top: 0;
}

.bf-seat-legend {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.bf-seat-legend > span {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
}

.bf-seat-legend i {
    display: inline-block;
    width: 21px;
    height: 25px;
    border: 1px solid var(--bf-ink);
    border-radius: 5px;
    background: #fff;
}

.bf-seat-legend .selected {
    background: var(--bf-orange);
    border-color: var(--bf-orange);
}

.bf-seat-legend .booked {
    background: #aaaeb7;
    border-color: #aaaeb7;
}

.bf-seat-layout {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    align-items: start;
    gap: 30px;
    margin-top: 28px;
}

.bf-bus {
    width: 260px;
    padding: 14px;
    border: 2px solid #858c98;
    border-radius: 45px 45px 28px 28px;
    background: #fafafa;
}

.bf-front-label {
    margin: 5px 0 12px;
    color: #626978;
    text-align: center;
    font-size: 10px;
}

.bf-seat-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr) 15px repeat(2, 1fr);
    gap: 6px;
    margin-bottom: 10px;
}

.bf-seat-row > :nth-child(3) {
    grid-column: 4;
}

.bf-seat-row > :nth-child(4) {
    grid-column: 5;
}

.bf-seat-row.bf-bench {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
}

.bf-seat-row.bf-bench > * {
    grid-column: auto;
}

.bf-seat {
    position: relative;
    display: block;
    min-width: 0;
    cursor: pointer;
}

.bf-seat input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.bf-seat span {
    display: grid;
    place-items: center;
    height: 44px;
    border: 2px solid #233756;
    border-bottom-width: 5px;
    border-radius: 7px;
    background: #fff;
    color: #172a4c;
    font-size: 13px;
    font-weight: 700;
}

.bf-seat input:checked + span {
    background: var(--bf-orange);
    border-color: #ac3e06;
    color: #fff;
}

.bf-seat input:disabled + span {
    border-color: #8f959e;
    background: #b6bac1;
    color: #414650;
    cursor: not-allowed;
}

.bf-seat input:focus-visible + span {
    outline: 3px solid #276bea;
    outline-offset: 3px;
}

.bf-driver,
.bf-entry {
    display: grid;
    place-items: center;
    min-height: 44px;
    color: #687181;
    font-size: 20px;
}

.bf-driver small {
    font-size: 7px;
}

.bf-entry {
    font-size: 8px;
}

.bf-seat-assignment {
    padding: 20px;
    border: 1px solid var(--bf-border);
    border-radius: 12px;
}

.bf-seat-assignment h2 {
    margin-top: 0;
    font-size: 18px;
}

.bf-seat-assignment ol {
    padding-left: 20px;
    font-size: 13px;
}

.bf-seat-assignment li {
    margin: 12px 0;
    overflow-wrap: anywhere;
}

.bf-seat-assignment .bf-button {
    width: 100%;
}

.bf-seat-assignment .bf-back {
    margin-top: 20px;
    font-size: 12px;
}

.bf-payment-heading {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 15px;
    flex-wrap: wrap;
}

.bf-payment-amount {
    display: grid;
    margin: 20px 0;
}

.bf-payment-amount strong {
    font-size: 38px;
    line-height: 1.3;
}

.bf-hold {
    padding: 10px 12px;
    border: 1px solid #e7cf9e;
    border-radius: 8px;
    background: #fff7e8;
    color: #795212;
    font-size: 13px;
}

.bf-wallets {
    display: flex;
    gap: 12px;
    border: 0;
    margin: 20px 0;
    padding: 0;
}

.bf-wallets legend {
    margin-bottom: 8px;
    font-size: 13px;
}

.bf-wallets label {
    position: relative;
    flex: 1;
    cursor: pointer;
}

.bf-wallets input {
    position: absolute;
    opacity: 0;
}

.bf-wallets span {
    display: block;
    padding: 16px;
    border: 1px solid var(--bf-border);
    border-radius: 8px;
    text-align: center;
    font-weight: 750;
}

.bf-wallets input:checked + span {
    border: 2px solid var(--bf-blue);
    padding: 15px;
    color: var(--bf-blue);
}

.bf-wallets input:focus-visible + span {
    outline: 3px solid var(--bf-blue);
    outline-offset: 3px;
}

.bf-qr-layout {
    display: grid;
    grid-template-columns: minmax(180px, 280px) minmax(0, 1fr);
    align-items: center;
    gap: 25px;
    margin: 25px 0;
}

.bf-qr {
    padding: 12px;
    border: 1px solid var(--bf-border);
    border-radius: 10px;
    background: #fff;
    text-align: center;
}

.bf-qr img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.bf-qr-layout h2 {
    font-size: 20px;
}

.bf-detail-link {
    display: inline-block;
    margin-top: 24px;
    text-decoration: underline;
}

.bf-table-wrap {
    overflow-x: auto;
    padding: 15px;
}

.bf-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 12px;
}

.bf-table th,
.bf-table td {
    padding: 14px 10px;
    border-bottom: 1px solid #e2e2e2;
    vertical-align: top;
}

.bf-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 20px max(24px, calc((100% - 1260px) / 2));
    color: #666;
    font-size: 11px;
}

@media (max-width: 1050px) {
    .bf-layout {
        grid-template-columns: 260px minmax(0, 1fr);
        gap: 16px;
    }

    .bf-steps {
        display: block;
    }

    .bf-steps ol {
        margin-top: 14px;
    }

    .bf-steps li {
        flex-direction: column;
        text-align: center;
        font-size: 10px;
    }

    .bf-trip {
        grid-template-columns: 135px minmax(0, 1fr);
        gap: 14px;
    }

    .bf-trip-brand strong {
        font-size: 36px;
    }

    .bf-seat-layout {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .bf-seat-assignment {
        width: 100%;
    }
}

@media (max-width: 760px) {
    .bf-header {
        padding: 18px;
        flex-wrap: wrap;
    }

    .bf-brand strong {
        font-size: 34px;
    }

    .bf-header nav {
        gap: 12px;
        flex-wrap: wrap;
        font-size: 12px;
    }

    .bf-header .bf-button,
    .bf-header .bf-outline {
        min-height: 38px;
        padding: 8px 12px;
        font-size: 12px;
    }

    .bf-tabs {
        gap: 6px;
        padding: 8px;
        min-height: 65px;
    }

    .bf-tabs a {
        min-width: 0;
        padding: 14px 18px;
        font-size: 13px;
    }

    .bf-container {
        width: calc(100% - 28px);
        margin-top: 16px;
    }

    .bf-layout {
        grid-template-columns: 1fr;
    }

    .bf-summary {
        min-height: 0;
        padding: 20px;
    }

    .bf-summary-route {
        margin: 24px 0;
    }

    .bf-search-fields {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .bf-search-fields > .bf-button {
        min-height: 55px;
    }

    .bf-search-top {
        gap: 8px;
    }

    .bf-pax {
        font-size: 10px;
    }

    .bf-form,
    .bf-seat-form {
        padding: 18px;
    }

    .bf-fields,
    .bf-qr-layout {
        grid-template-columns: 1fr;
    }

    .bf-trip {
        grid-template-columns: 1fr;
    }

    .bf-trip-brand {
        flex-direction: row;
        gap: 16px;
        padding: 12px;
    }

    .bf-trip-brand span {
        max-width: 170px;
        text-align: left;
    }

    .bf-trip-route {
        font-size: 10px;
    }

    .bf-steps {
        padding: 16px 12px;
    }

    .bf-steps ol {
        gap: 5px;
    }

    .bf-actions {
        flex-wrap: wrap;
    }

    .bf-actions > * {
        flex: 1;
    }

    .bf-qr {
        width: min(280px, 100%);
        margin: auto;
    }

    .bf-footer {
        padding: 20px;
        flex-direction: column;
        gap: 5px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition: none !important;
        scroll-behavior: auto !important;
    }
}
/* Route connectors — aligned like the reference */

.bf-summary-route {
    grid-template-columns:
        minmax(0, 1fr)
        minmax(80px, 112px)
        minmax(0, 1fr);
    align-items: center;
    gap: 3px;
}

.bf-route-line {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-width: 0;
    color: #252525;
}

.bf-route-line .bf-route-art {
    display: block;
    width: 100%;
    max-width: 120px;
    height: auto;
    overflow: visible;
    fill: none;
    stroke: none;
}

/* Keep the origin, route line and destination aligned */
.bf-trip-route {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        minmax(65px, 115px)
        minmax(0, 1.4fr);
    align-items: center;
    gap: 12px;
}

.bf-trip-route > strong:first-child {
    text-align: center;
}

.bf-trip-route > strong:last-child {
    text-align: center;
}

.bf-trip-connector {
    display: block;
    width: 100%;
    height: 16px;
    color: #252525;
}

@media (max-width: 480px) {
    .bf-summary-route {
        grid-template-columns:
            minmax(0, 1fr)
            92px
            minmax(0, 1fr);
    }

    .bf-trip-route {
        grid-template-columns:
            minmax(0, 1fr)
            65px
            minmax(0, 1.4fr);
        gap: 7px;
    }
}
/* ==========================================
   SMTC — bird's-eye bus interior
   Uses the existing 25-seat arrangement.
   ========================================== */

.bf-seat-form {
    --bus-outline: #727c89;
    --bus-inner-outline: #bac1ca;
    --seat-outline: #203653;
    --seat-selected: #e35e08;
    --seat-selected-dark: #b94404;
    --seat-booked: #b4bac3;
}

/* Bus and assignment panel */
.bf-seat-form .bf-seat-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    align-items: start;
    gap: 32px;
    padding: 24px 8px 12px;
}

/* Vehicle body */
.bf-seat-form .bf-bus {
    position: relative;
    isolation: isolate;
    box-sizing: border-box;
    width: 280px;
    max-width: 100%;
    margin: 0 auto;
    padding: 79px 17px 43px;

    overflow: visible;

    border: 2px solid var(--bus-outline);
    border-radius: 48% 48% 15% 15% / 9% 9% 6% 6%;

    background:
        linear-gradient(
            90deg,
            #e3e6ea 0,
            #ffffff 5%,
            #f8f9fb 11%,
            #ffffff 49%,
            #f8f9fb 89%,
            #ffffff 95%,
            #e3e6ea 100%
        );

    box-shadow:
        inset 0 0 0 5px #f7f8fa,
        inset 0 0 0 6px var(--bus-inner-outline),
        inset 0 0 0 11px #ffffff,
        inset 0 0 0 12px #d2d7de,
        0 8px 18px rgb(20 33 61 / 7%);
}

/* Front windshield */
.bf-seat-form .bf-bus::before {
    content: "";
    position: absolute;
    z-index: -1;

    top: 15px;
    left: 18px;
    right: 18px;
    height: 49px;

    border: 1px solid #98a4b2;
    border-bottom: 5px solid #d3d9e0;
    border-radius: 48% 48% 12% 12% / 70% 70% 20% 20%;

    background:
        linear-gradient(
            165deg,
            #d3dce4 0%,
            #f5f8fb 35%,
            #e6edf3 70%,
            #c4cfd9 100%
        );

    box-shadow:
        inset 0 3px 0 rgb(255 255 255 / 85%),
        0 6px 0 #f1f3f6;
}

/* Exterior side mirrors */
.bf-seat-form .bf-bus::after {
    content: "";
    position: absolute;
    z-index: -2;

    top: 89px;
    left: -14px;

    width: 12px;
    height: 41px;

    border: 1px solid #697584;
    border-radius: 6px 2px 2px 6px;

    background: linear-gradient(90deg, #77818e, #a2abb6);

    box-shadow: 292px 0 0 -1px #8a95a2;

    pointer-events: none;
}

/* FRONT / REAR labels */
.bf-seat-form .bf-bus > .bf-front-label {
    position: absolute;
    left: 0;
    right: 0;

    margin: 0;
    padding: 0;

    color: #465268;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: .06em;
    text-align: center;
}

.bf-seat-form .bf-bus > .bf-front-label:first-child {
    top: -23px;
}

.bf-seat-form .bf-bus > .bf-front-label:last-child {
    bottom: -23px;
}

/* Two seats, aisle, two seats */
.bf-seat-form .bf-seat-row {
    position: relative;
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1fr)
        20px
        minmax(0, 1fr)
        minmax(0, 1fr);

    align-items: stretch;
    gap: 6px;

    margin: 0 0 13px;
}

.bf-seat-form .bf-seat-row > :nth-child(1) {
    grid-column: 1;
}

.bf-seat-form .bf-seat-row > :nth-child(2) {
    grid-column: 2;
}

.bf-seat-form .bf-seat-row > :nth-child(3) {
    grid-column: 4;
}

.bf-seat-form .bf-seat-row > :nth-child(4) {
    grid-column: 5;
}

/* Driver dashboard area */
.bf-seat-form .bf-seat-row > .bf-driver {
    grid-column: 1 / 3;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;

    min-height: 61px;
    padding: 7px;

    border: 1px solid #d6dae0;
    border-radius: 13px 8px 8px 8px;

    background: linear-gradient(135deg, #d9dde3, #f1f3f6);

    color: #344357;
}

.bf-seat-form .bf-steering-wheel {
    display: block;
    width: 35px;
    height: 35px;

    fill: none;
    stroke: currentColor;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.bf-seat-form .bf-driver small {
    margin: 0;
    font-size: 7px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: .07em;
}

/* First row: hide the empty placeholder beside driver */
.bf-seat-form .bf-seat-row:first-of-type > div[aria-hidden="true"] {
    display: none;
}

/* Entry area occupies the right pair of seat columns */
.bf-seat-form .bf-seat-row > .bf-entry {
    grid-column: 4 / 6;

    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 55px;
    padding: 0;

    border: 1px solid #d6dce3;
    border-radius: 8px;

    background:
        repeating-linear-gradient(
            0deg,
            transparent 0,
            transparent 11px,
            rgb(132 146 162 / 15%) 11px,
            rgb(132 146 162 / 15%) 12px
        ),
        linear-gradient(135deg, #e3e7ec, #f5f6f8);

    color: #5e6b7e;
    font-size: 9px;
    font-weight: 600;
}

/* Hide the unused cell after ENTRY */
.bf-seat-form .bf-entry + div[aria-hidden="true"] {
    display: none;
}

/* Seat hit area */
.bf-seat-form .bf-seat {
    position: relative;
    display: block;
    min-width: 0;
    margin: 0;
    cursor: pointer;
}

/* Keep native checkbox accessible */
.bf-seat-form .bf-seat > input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    padding: 0;

    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    opacity: 0;
}

/* Seat cushion */
.bf-seat-form .bf-seat > span {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;

    box-sizing: border-box;
    width: 100%;
    height: 55px;
    min-height: 55px;
    margin: 0;
    padding: 0 0 5px;

    border: 1.5px solid var(--seat-outline);
    border-bottom: 5px solid var(--seat-outline);
    border-radius: 8px 8px 6px 6px;

    background: linear-gradient(145deg, #ffffff, #f3f5f8);

    color: #142b4c;
    font-size: 13px;
    font-weight: 750;
    line-height: 1;

    box-shadow:
        inset 3px 0 0 rgb(220 225 232 / 45%),
        inset -3px 0 0 rgb(220 225 232 / 45%),
        0 2px 3px rgb(20 33 61 / 8%);

    transition:
        transform 180ms ease,
        background 180ms ease,
        box-shadow 180ms ease;
}

/* Seat backrest detail */
.bf-seat-form .bf-seat > span::before {
    content: "";
    position: absolute;

    left: 4px;
    right: 4px;
    bottom: 3px;
    height: 5px;

    border-top: 1px solid rgb(32 54 83 / 25%);
    border-radius: 3px;

    background: rgb(32 54 83 / 6%);
    pointer-events: none;
}

/* Selected seats */
.bf-seat-form .bf-seat > input:checked + span {
    border-color: var(--seat-selected-dark);
    border-bottom-color: var(--seat-selected-dark);

    background: linear-gradient(145deg, #ff8b30, var(--seat-selected));

    color: #ffffff;

    box-shadow:
        inset 0 1px 0 rgb(255 255 255 / 35%),
        0 3px 7px rgb(213 84 7 / 20%);
}

.bf-seat-form .bf-seat > input:checked + span::before {
    border-top-color: rgb(255 255 255 / 40%);
    background: rgb(130 43 0 / 12%);
}

/* Booked / unavailable seats */
.bf-seat-form .bf-seat > input:disabled + span {
    border-color: #89929f;
    border-bottom-color: #7b8593;

    background: linear-gradient(145deg, #c5cad1, var(--seat-booked));

    color: #344255;
    cursor: not-allowed;

    box-shadow: inset 0 1px 0 rgb(255 255 255 / 35%);
}

/* Keyboard focus */
.bf-seat-form .bf-seat > input:focus-visible + span {
    outline: 3px solid #176ae6;
    outline-offset: 3px;
}

/* Rear bench: five adjacent seats */
.bf-seat-form .bf-seat-row.bf-bench {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 3px;

    margin: 19px 0 0;
    padding: 7px 3px 3px;

    border: 1px solid #cbd2db;
    border-radius: 9px;
    background: #e9edf2;
}

.bf-seat-form .bf-seat-row.bf-bench > * {
    grid-column: auto;
}

.bf-seat-form .bf-bench .bf-seat > span {
    height: 53px;
    min-height: 53px;
    border-radius: 5px;
    font-size: 12px;
}

/* Assignment card */
.bf-seat-form .bf-seat-assignment {
    align-self: start;
    min-width: 0;
    margin-top: 45px;
}

/* Hover only on devices with a pointer */
@media (hover: hover) {
    .bf-seat-form .bf-seat > input:not(:disabled):not(:checked) + span:hover {
        transform: translateY(-2px);
        background: #edf3fc;

        box-shadow:
            inset 3px 0 0 rgb(220 225 232 / 45%),
            inset -3px 0 0 rgb(220 225 232 / 45%),
            0 4px 8px rgb(20 33 61 / 12%);
    }
}

/* Stack without shrinking the seat targets */
@media (max-width: 1100px) {
    .bf-seat-form .bf-seat-layout {
        grid-template-columns: minmax(0, 1fr);
        justify-items: center;
        gap: 42px;
    }

    .bf-seat-form .bf-seat-assignment {
        width: 100%;
        margin-top: 0;
    }
}

@media (max-width: 480px) {
    .bf-seat-form .bf-seat-layout {
        padding-right: 0;
        padding-left: 0;
    }

    .bf-seat-form .bf-bus {
        width: 260px;
        padding-right: 13px;
        padding-left: 13px;
    }

    .bf-seat-form .bf-bus::after {
        box-shadow: 272px 0 0 -1px #8a95a2;
    }

    .bf-seat-form .bf-seat-row {
        column-gap: 4px;
        grid-template-columns:
            minmax(0, 1fr)
            minmax(0, 1fr)
            16px
            minmax(0, 1fr)
            minmax(0, 1fr);
    }

    .bf-seat-form .bf-seat-row.bf-bench {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 3px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bf-seat-form .bf-seat > span {
        transition: none;
    }
}
/* =========================================
   Bus reference corrections
   ========================================= */

/* Compact bus proportions */
.bf-seat-form .bf-bus {
    width: 250px;
    padding: 48px 13px 30px;

    border: 2px solid #626c79;
    border-radius: 42px 42px 31px 31px / 38px 38px 29px 29px;

    background: linear-gradient(
        90deg,
        #edf0f3 0%,
        #fff 7%,
        #fafbfc 50%,
        #fff 93%,
        #edf0f3 100%
    );

    box-shadow:
        inset 0 0 0 5px #fff,
        inset 0 0 0 6px #b9c0c9,
        inset 0 0 0 10px #fafbfc,
        0 3px 8px rgb(20 33 61 / 5%);
}

/* Slim curved windshield */
.bf-seat-form .bf-bus::before {
    top: 12px;
    left: 15px;
    right: 15px;
    height: 25px;

    border: 1px solid #919ba8;
    border-bottom: 2px solid #a9b2bd;
    border-radius: 50% 50% 8px 8px / 70% 70% 8px 8px;

    background: linear-gradient(
        180deg,
        #e5eaf0,
        #fff 70%
    );

    box-shadow: 0 5px 0 #f0f2f5;
}

/* Mirrors aligned with driver */
.bf-seat-form .bf-bus::after {
    top: 67px;
    left: -13px;
    width: 11px;
    height: 38px;

    border-radius: 5px;
    background: #929ca9;
    box-shadow: 261px 0 0 -1px #929ca9;
}

/* Keep all row items on the same grid row.
   This fixes seats 1 and 2 dropping below the driver. */
.bf-seat-form .bf-bus > .bf-seat-row > * {
    grid-row: 1;
}

/* The FRONT label precedes the first seat row.
   Use the adjacent sibling selector instead of first-of-type. */
.bf-seat-form .bf-bus
> .bf-front-label:first-child
+ .bf-seat-row
> div[aria-hidden="true"] {
    display: none;
}

/* Seat rows and center aisle */
.bf-seat-form .bf-seat-row {
    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1fr)
        14px
        minmax(0, 1fr)
        minmax(0, 1fr);

    column-gap: 5px;
    margin-bottom: 12px;
}

/* Driver area matches the front passenger row */
.bf-seat-form .bf-seat-row > .bf-driver {
    grid-column: 1 / 3;
    grid-row: 1;

    min-height: 53px;
    padding: 5px;
    gap: 2px;

    border: 1px solid #dde1e6;
    border-radius: 8px;

    background: linear-gradient(135deg, #dce0e5, #f0f2f4);
}

.bf-seat-form .bf-steering-wheel {
    width: 32px;
    height: 32px;
}

.bf-seat-form .bf-driver small {
    font-size: 6px;
}

/* Flatter outlined seats like the reference */
.bf-seat-form .bf-seat > span {
    height: 53px;
    min-height: 53px;
    padding: 0;

    border: 1.5px solid #172b4c;
    border-bottom-width: 2px;
    border-radius: 7px;

    background: linear-gradient(135deg, #fff 55%, #f0f2f6);
    color: #14294a;

    font-size: 14px;
    font-weight: 700;

    box-shadow: inset 0 0 0 3px rgb(234 238 244 / 45%);
}

/* Remove the thick cushion strip from the previous design */
.bf-seat-form .bf-seat > span::before {
    content: none;
}

/* Selected */
.bf-seat-form .bf-seat > input:checked + span {
    border: 1.5px solid #bd4a08;
    border-bottom-width: 2px;
    background: linear-gradient(135deg, #ff8528, #e15b08);
    color: #fff;
    box-shadow: inset 0 1px 2px rgb(255 255 255 / 25%);
}

/* Booked */
.bf-seat-form .bf-seat > input:disabled + span {
    border: 1.5px solid #7d8795;
    border-bottom-width: 2px;
    background: linear-gradient(135deg, #c4c9d0, #aeb5bf);
    color: #24344e;
    box-shadow: none;
}

/* Entry */
.bf-seat-form .bf-seat-row > .bf-entry {
    grid-column: 4 / 6;
    grid-row: 1;
    min-height: 53px;

    background: linear-gradient(135deg, #e6e9ee, #f3f4f6);
    border: 1px solid #d7dce3;
    border-radius: 7px;
    font-size: 9px;
}

/* Five connected rear seats */
.bf-seat-form .bf-seat-row.bf-bench {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;

    margin: 17px 0 0;
    padding: 0;

    border: 0;
    border-radius: 0;
    background: transparent;
}

.bf-seat-form .bf-seat-row.bf-bench > * {
    grid-column: auto;
    grid-row: 1;
}

.bf-seat-form .bf-bench .bf-seat > span {
    height: 53px;
    min-height: 53px;
    border-radius: 4px;
    font-size: 13px;
}

/* Center the narrower bus within its existing column */
.bf-seat-form .bf-seat-layout {
    grid-template-columns: 270px minmax(0, 1fr);
    gap: 28px;
}

.bf-seat-form .bf-seat-assignment {
    margin-top: 58px;
}

@media (max-width: 1100px) {
    .bf-seat-form .bf-seat-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 42px;
    }

    .bf-seat-form .bf-seat-assignment {
        margin-top: 0;
    }
}
.bf-card.bf-trip.bf-trip-clickable {
    cursor: pointer;
}