/* Responsive, scrollable and zoomable wrapper for every .seats element. */
.seat-map {
    --seat-map-max-width: 1190px;
    --seat-map-border: #d9dee7;
    --seat-map-background: #f7f8fa;

    box-sizing: border-box;
    width: 100%;
    max-width: var(--seat-map-max-width);
    margin: 20px auto;
    direction: ltr;
}

.seat-map,
.seat-map__toolbar,
.seat-map__button,
.seat-map__viewport,
.seat-map__stage {
    box-sizing: border-box;
}

.seat-map__toolbar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 46px;
    padding: 6px 8px;
    direction: rtl;
    background: #fff;
    border: 1px solid var(--seat-map-border);
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
}

.seat-map__button {
    min-width: 38px;
    height: 34px;
    padding: 0 10px;
    border: 1px solid #c8ced8;
    border-radius: 6px;
    background: #fff;
    color: #273142;
    font: 700 18px/32px Tahoma, Arial, sans-serif;
    text-align: center;
    cursor: pointer;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
}

.seat-map__button:hover {
    background: #f0f3f7;
}

.seat-map__button:focus-visible,
.seat-map__viewport:focus-visible {
    outline: 3px solid rgba(20, 115, 230, 0.35);
    outline-offset: 2px;
}

.seat-map__button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.seat-map__button--fit {
    width: auto;
    font-size: 12px;
    font-weight: 400;
}

.seat-map__value {
    min-width: 54px;
    color: #4b5565;
    font: 12px/1.2 Tahoma, Arial, sans-serif;
    text-align: center;
    direction: ltr;
}

.seat-map__viewport {
    position: relative;
    width: 100%;
    min-height: 1px;
    overflow: auto;
    direction: ltr;
    background: var(--seat-map-background);
    border: 1px solid var(--seat-map-border);
    border-radius: 0 0 8px 8px;
    cursor: grab;
    touch-action: none;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-gutter: stable both-edges;
}

.seat-map__viewport[data-dragging="true"] {
    cursor: grabbing;
    user-select: none;
    -webkit-user-select: none;
}

.seat-map__stage {
    position: relative;
    min-width: 1px;
    min-height: 1px;
    margin-right: auto;
    margin-left: auto;
}

/* The existing hall remains unchanged; only its outer geometry is controlled. */
.seat-map__hall.seats {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-block !important;
    width: max-content !important;
    max-width: none !important;
    margin: 0 !important;
    transform: scale(var(--seat-map-scale, 1));
    transform-origin: top left;
    will-change: transform;
}

@media (max-width: 600px) {
    .seat-map {
        margin: 12px auto;
    }

    .seat-map__toolbar {
        position: sticky;
        top: 0;
        z-index: 10;
    }

    .seat-map__button {
        min-width: 42px;
        height: 38px;
        line-height: 36px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .seat-map__button {
        transition: none;
    }
}

