.schedule-pdf {
    display: none;
    --sheet-width: 279mm;
    --poster-red: #ed4546;
    --poster-burgundy: #681e28;
    --poster-light: #f6eeee;
    --poster-row: #eee4e4;
    --poster-row-alt: #f7eeee;
    --poster-rule: #fff;
    --poster-text: #351820;
    width: var(--sheet-width);
    max-width: 100%;
    margin: 0 auto;
    color: var(--poster-text);
    background: #fff;
    font: 400 10pt/1.28 "Golos Text", Arial, sans-serif;
    font-variant-numeric: tabular-nums;
    color-scheme: light;
    text-size-adjust: none;
    -webkit-text-size-adjust: none;
}

html.schedule-pdf-active body > .schedule-pdf--measuring {
    display: block !important;
    position: fixed;
    inset: 0 auto auto -300vw;
    visibility: hidden;
    width: var(--sheet-width) !important;
    max-width: none;
    margin: 0;
    zoom: 1 !important;
}

@page {
    size: A4 landscape;
    margin: 8mm 9mm;
}

@media print {
    html.schedule-pdf-active,
    html.schedule-pdf-active body {
        width: auto;
        height: auto;
        min-height: 0;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        background: #fff !important;
    }

    html.schedule-pdf-active body {
        display: block;
    }

    html.schedule-pdf-active body > :not(.schedule-pdf) {
        display: none !important;
    }

    html.schedule-pdf-active body > .schedule-pdf {
        display: block !important;
        width: calc(var(--sheet-width) / var(--sheet-scale, 1));
        zoom: var(--sheet-scale, 1);
        break-inside: avoid;
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }
}

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

.schedule-pdf :is(h1, h2, h3, p, ul, figure) {
    margin: 0;
}

.schedule-pdf__header {
    --badge-width: 32mm;
    --badge-padding: 2mm;
    display: grid;
    grid-template-columns: var(--badge-width) minmax(0, 1fr);
    gap: 1.2mm;
    margin-bottom: 2mm;
    break-inside: avoid;
    page-break-inside: avoid;
}

.schedule-pdf__badge {
    display: grid;
    place-items: center;
    min-width: 0;
    min-height: 29mm;
    padding: 1.2mm var(--badge-padding);
    border-radius: 2mm;
    background: var(--poster-red);
    color: #fff;
    text-align: center;
    font-size: 49pt;
    font-weight: 800;
    line-height: .95;
}

.schedule-pdf__badge-number {
    font-size: min(49pt, calc((var(--badge-width) - 2 * var(--badge-padding) - 1mm) / var(--number-width)));
    font-variant-numeric: normal;
    white-space: nowrap;
}

.schedule-pdf__identity {
    display: grid;
    grid-template-rows: auto 1fr;
    gap: 1.2mm;
    min-width: 0;
}

.schedule-pdf__title {
    padding: 1.8mm 2.6mm;
    border-radius: 2mm 2mm 0 0;
    color: #fff;
    background: var(--poster-red);
    font-size: 13.5pt;
    font-weight: 800;
    line-height: 1.14;
    letter-spacing: .012em;
    text-align: center;
    text-transform: uppercase;
    overflow-wrap: anywhere;
}

.schedule-pdf__summary {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 4fr);
    gap: 1.2mm;
}

.schedule-pdf__stops,
.schedule-pdf__route {
    display: grid;
    align-content: center;
    gap: .6mm;
    min-width: 0;
    padding: 1.5mm 2.6mm;
    background: var(--poster-light);
    color: var(--poster-burgundy);
    overflow-wrap: anywhere;
}

.schedule-pdf__stops {
    list-style: none;
    font-size: 13pt;
    line-height: 1.1;
    font-weight: 800;
}

.schedule-pdf__stops li {
    display: grid;
    grid-template-columns: 4.5mm minmax(0, 1fr);
    align-items: baseline;
    gap: 2.2mm;
}

.schedule-pdf__stops li + li {
    padding-top: 1mm;
    border-top: .45mm solid var(--poster-rule);
}

.schedule-pdf__stops li > [aria-hidden="true"] {
    width: 4.5mm;
    color: var(--poster-red);
    font-size: 11pt;
}

.schedule-pdf__stops ul {
    display: grid;
    gap: .5mm;
    padding: 0;
    list-style: none;
}

.schedule-pdf__route h3 {
    font-size: 9pt;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: .025em;
    text-transform: uppercase;
}

.schedule-pdf__route p {
    font-size: 10pt;
    font-weight: 650;
    line-height: 1.24;
    white-space: pre-wrap;
}

.schedule-pdf__table {
    width: 100%;
    margin: 0;
    border-collapse: collapse;
    table-layout: auto;
}

.schedule-pdf__table + .schedule-pdf__table {
    margin-top: 2mm;
}

.schedule-pdf__table thead {
    display: table-header-group;
}

.schedule-pdf__table tbody {
    display: table-row-group;
}

.schedule-pdf__table tr {
    break-inside: avoid;
    page-break-inside: avoid;
}

.schedule-pdf__table :is(th, td) {
    border: .5mm solid var(--poster-rule);
    vertical-align: middle;
}

.schedule-pdf__table thead th {
    padding: 1.15mm 1.6mm;
    background: #efdcdf;
    color: var(--poster-burgundy);
    text-align: center;
    font-size: 12pt;
    font-weight: 800;
    line-height: 1.12;
    text-transform: uppercase;
    overflow-wrap: anywhere;
}

.schedule-pdf__table thead th small {
    font-size: 8.8pt;
    font-weight: 650;
    text-transform: none;
}

.schedule-pdf__table tbody :is(td, th) {
    padding: .33mm 1.5mm;
    background: var(--poster-row);
    color: var(--poster-burgundy);
    font-size: 10pt;
    line-height: 1.12;
}

.schedule-pdf__table tbody tr:nth-child(even) :is(td, th) {
    background: var(--poster-row-alt);
}

.schedule-pdf__table tbody .schedule-pdf__hour {
    width: 11%;
    padding-inline: .9mm;
    background: #e9d9db;
    text-align: center;
    font-size: 11pt;
    font-weight: 800;
    line-height: 1.04;
    white-space: nowrap;
}

.schedule-pdf__table tbody tr:nth-child(even) .schedule-pdf__hour {
    background: #f0e0e2;
}

.schedule-pdf__table[data-columns="2"] thead th {
    width: 50%;
}

.schedule-pdf__table[data-columns="2"] :is(.schedule-pdf__hour, .schedule-pdf__hour-column) {
    width: 6.5%;
}

.schedule-pdf__table[data-columns="2"] .schedule-pdf__minutes {
    width: 43.5%;
}

.schedule-pdf__minutes {
    font-weight: 650;
    overflow-wrap: anywhere;
}

.schedule-pdf__minutes span {
    display: inline-block;
    margin-inline-end: 1mm;
    font: 400 11.5pt/1 "Bebas Neue", "Golos Text", Arial, sans-serif;
    white-space: nowrap;
}

.schedule-pdf__table[data-density="compact"] tbody :is(td, th) {
    padding-block: .30mm;
    font-size: 8.7pt;
    line-height: 1.12;
}

.schedule-pdf__table[data-density="compact"] tbody .schedule-pdf__hour {
    font-size: 9.7pt;
}

.schedule-pdf__table[data-density="compact"] .schedule-pdf__minutes span {
    margin-inline-end: .72mm;
    font-size: 10.2pt;
}

.schedule-pdf__footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(71mm, .55fr);
    align-items: start;
    gap: 1.5mm;
    margin-top: 2mm;
}

.schedule-pdf__cards {
    min-width: 0;
}

.schedule-pdf__notes {
    display: contents;
}

.schedule-pdf__notes h2 {
    grid-column: 1 / -1;
    padding: 1mm 2mm;
    border-radius: 1.5mm 1.5mm 0 0;
    background: var(--poster-red);
    color: #fff;
    font-size: 11pt;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: .025em;
    text-transform: uppercase;
    break-after: avoid;
    page-break-after: avoid;
}

.schedule-pdf__notes p {
    min-width: 0;
    padding: 1.25mm 2mm;
    background: var(--poster-light);
    color: var(--poster-text);
    font-size: 8.7pt;
    line-height: 1.29;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    orphans: 2;
    widows: 2;
}

.schedule-pdf__cards {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
    gap: 1.2mm;
}

.schedule-pdf__validity,
.schedule-pdf__community {
    flex: 1 1 34mm;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .7mm;
    min-width: 0;
    min-height: 26mm;
    padding: 1.4mm;
    border: .4mm solid #ecdbde;
    background: var(--poster-light);
    color: var(--poster-burgundy);
    text-decoration: none;
    font-size: 8.5pt;
    font-weight: 650;
    line-height: 1.2;
    text-align: center;
    overflow-wrap: anywhere;
    break-inside: avoid;
    page-break-inside: avoid;
}

.schedule-pdf__validity > [aria-hidden="true"] {
    color: var(--poster-red);
    font-size: 21pt;
    line-height: 1;
}

.schedule-pdf__validity strong {
    font-size: 10pt;
    font-weight: 800;
    white-space: nowrap;
    overflow-wrap: normal;
}

.schedule-pdf__community img {
    display: block;
    flex: 0 0 auto;
    width: 22mm;
    height: 22mm;
    max-width: none;
    padding: .6mm;
    background: #fff;
    object-fit: contain;
    image-rendering: pixelated;
}
