@use './src/styles/layouts' as *;
@use './src/styles/variables' as *;
@use './src/styles/colors' as *;
@use './src/styles/fonts' as *;
@use './src/styles/screen' as *;

:host {
    display: block;
    padding: $space-l $space-xl;
    font-size: $font-size-xl;
    font-weight: $font-regular;
    @include v-spacing($space-l);

    .k-leg {
        @include mobile() {
            &-status {
                text-align: right;
            }

            gap: $space-l 0;
            grid-template: auto auto auto / 1fr 1fr 1fr 1fr 1fr 1fr;
            grid-template-areas:
                'number logo logo logo status status'
                'depart-at depart-at depart-at arrive-at arrive-at arrive-at'
                'depart-from depart-from depart-from arrive-to arrive-to arrive-to';

            section-number {
                grid-area: number;
                align-self: center;
            }

            operator-logo-and-model {
                grid-area: logo;
            }

            &-status {
                grid-area: status;
            }

            time-group-legacy {
                &:first-of-type {
                    grid-area: depart-at;
                }
                &:last-of-type {
                    grid-area: arrive-at;
                    justify-self: end;
                    text-align: right;
                }
            }

            station {
                &:first-of-type {
                    grid-area: depart-from;
                }
                &:last-of-type {
                    grid-area: arrive-to;
                }
            }
        }
    }
}
