.context-tabs {
    position: fixed;
    left: 0;
    top: var(--app-header-height);
    bottom: var(--app-footer-height);
    z-index: 1030;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    pointer-events: none;
    width: max-content;
    padding-top: 12px;
    padding-bottom: 12px;
    padding-right: 0;
    overflow: visible;
}

.context-tabs::after {
    content: "";
    position: absolute;
    top: 10px;
    right: -1px;
    bottom: 10px;
    width: 1px;
    background: linear-gradient(to bottom, rgba(74, 44, 42, 0.12), rgba(74, 44, 42, 0.78), rgba(74, 44, 42, 0.12));
    box-shadow:
        0 0 0 1px rgba(255,255,255,0.18),
        0 0 8px rgba(74, 44, 42, 0.22);
    pointer-events: none;
}

.context-tabs::before {
    content: "";
    position: absolute;
    top: 8px;
    right: -7px;
    bottom: 8px;
    width: 8px;
    background: linear-gradient(to right, rgba(74, 44, 42, 0.08), rgba(74, 44, 42, 0));
    pointer-events: none;
}

.kiosk-body .context-tabs {
    left: 0;
    top: 0;
    bottom: 0;
}

.context-tabs-fixed {
    pointer-events: none;
    width: var(--app-tabs-fixed-width);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.context-tabs-pages {
    pointer-events: none;
    width: var(--app-tabs-fixed-width);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    overflow-y: auto;
    padding-top: 12px;
    padding-left: 0;
    max-height: 100%;
}

.context-tab {
    pointer-events: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 34px;
    min-height: 108px;
    padding: 10px 6px;
    border: 1px solid rgba(255,255,255,0.35);
    border-left: 0;
    border-radius: 0 7px 7px 0;
    background: #4A2C2A;
    color: #fff;
    box-shadow: 2px 3px 8px rgba(0,0,0,0.18);
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-family: "Oswald", Helvetica, sans-serif;
    font-size: .86rem;
    line-height: 1;
    text-decoration: none;
    margin-right: 0;
}

.context-tab i {
    transform: rotate(90deg);
    font-size: .86rem;
}

.context-tab:hover,
.context-tab:focus {
    color: #fff;
    background: #B91C1C;
}

.context-tab.active {
    background: #fff;
    color: #4A2C2A;
    border-color: #4A2C2A;
    border-right-color: #4A2C2A;
    box-shadow: 2px 3px 8px rgba(0,0,0,0.12);
    z-index: 2;
}

.context-tab.active:hover,
.context-tab.active:focus {
    background: #fff;
    color: #4A2C2A;
}

.context-tab-page {
    pointer-events: auto;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    min-height: 108px;
    padding: 12px 6px 18px;
    border: 1px solid rgba(255,255,255,0.35);
    border-left: 0;
    border-radius: 0 7px 7px 0;
    background: #6c3c35;
    color: #fff;
    box-shadow: 2px 3px 8px rgba(0,0,0,0.18);
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    font-family: "Oswald", Helvetica, sans-serif;
    font-size: .82rem;
    line-height: 1;
    text-decoration: none;
    text-align: left;
    overflow: visible;
    margin-right: 0;
}

.context-tab-page__link {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    color: inherit;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    writing-mode: inherit;
    transform: inherit;
}

.context-tab-page:hover,
.context-tab-page:focus {
    color: #fff;
    background: #B91C1C;
}

.context-tab-page.active {
    background: #fff;
    color: #4A2C2A;
    border-color: #4A2C2A;
    border-right-color: #4A2C2A;
    z-index: 2;
}

.context-tab-page.active:hover,
.context-tab-page.active:focus {
    background: #fff;
    color: #4A2C2A;
}

.context-tab-page__label {
    display: inline-block;
    max-height: 84px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
    text-align: center;
    transform: rotate(180deg);
    transform-origin: center center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.context-tab-page__close {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 2;
    border: 0;
    background: transparent;
    color: inherit;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    transform: rotate(180deg);
    writing-mode: horizontal-tb;
}

@media (max-width: 820px), (hover: none) and (pointer: coarse) {
    .context-tabs {
        display: none !important;
    }
}
