.bb-promo-bar[hidden],
.bb-promo-bar__coupon[hidden] {
    display: none !important;
}

.bb.bb-promo-visible {
    --bb-promo-top-offset: calc(var(--bb-promo-admin-offset, 0px) + var(--bb-promo-height, 0px));
    padding-top: var(--bb-promo-height, 0px);
}

.bb .header-1-wrapper .header-1 {
    transition-property: background-color, padding, box-shadow;
}

.bb-promo-visible .header-1-wrapper .header-1 {
    top: var(--bb-promo-top-offset);
    margin-top: 0;
}

.bb .header-1-wrapper .search-bar,
.bb .header-1-wrapper .contacts-bar {
    transition-property: transform, opacity;
}

.bb .sidebar-bg-all {
    transition-property: opacity;
}

.bb-promo-visible .header-1-wrapper .search-bar,
.bb-promo-visible .header-1-wrapper .contacts-bar,
.bb-promo-visible .sidebar-bg-all {
    top: var(--bb-promo-top-offset);
}

.bb-promo-visible .header-1-wrapper .contacts-bar,
.bb-promo-visible .sidebar-bg-all {
    height: calc(100vh - var(--bb-promo-top-offset));
    height: calc(100dvh - var(--bb-promo-top-offset));
}

.bb-promo-visible .header-1-wrapper .search-bar {
    visibility: hidden;
    pointer-events: none;
}

.bb-promo-visible .header-1-wrapper .search-bar.active {
    visibility: visible;
    pointer-events: auto;
}

.bb-promo-bar {
    --promo-background: #232323;
    --promo-accent: #d9b287;
    position: fixed;
    top: var(--bb-promo-admin-offset, 0px);
    left: 0;
    width: 100%;
    z-index: 1011;
    background: var(--promo-background);
    color: #fff;
    font-size: 14px;
    line-height: 1.4;
}

.bb-promo-bar__inner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px 20px;
    min-height: 44px;
    padding-top: 0;
    padding-bottom: 0;
}

.bb-promo-bar .bb-promo-bar__message {
    margin: 0;
    font-size: inherit;
    line-height: inherit;
    font-weight: 500;
    overflow-wrap: anywhere;
}

.bb-promo-bar__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 0;
    cursor: pointer;
    font: inherit;
    touch-action: manipulation;
    transition: background-color .15s, color .15s;
}

.bb-promo-bar__coupon {
    display: inline-flex;
    align-items: baseline;
    flex: 0 1 auto;
    flex-wrap: wrap;
    gap: 2px 6px;
    min-width: 0;
    max-width: 100%;
    padding: 3px 8px;
    border-radius: 3px;
    background: var(--promo-accent);
    color: #232323;
    line-height: 1.2;
    user-select: text;
}

.bb-promo-bar__code-label {
    font-size: 12px;
}

.bb-promo-bar__code {
    font-size: 13px;
    font-weight: 700;
    overflow-wrap: anywhere;
    min-width: 0;
}

.bb-promo-bar__timer {
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.bb-promo-bar__clock {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.bb-promo-bar__days {
    margin-right: 4px;
    font-size: 12px;
}

.bb-promo-bar__time-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 2px 4px;
    border: 1px solid #ffffff1a;
    border-radius: 2px;
    background: #3a3a3a;
    font-size: 12px;
    font-weight: 600;
}

.bb-promo-bar__separator {
    font-size: 12px;
}

.bb-promo-bar__close {
    flex: 0 0 44px;
    width: 44px;
    padding: 0;
    border-radius: 4px;
    background: transparent;
    color: #fff;
}

.bb-promo-bar__close:hover {
    background: #414141;
}

.bb-promo-bar button:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

@media (max-width: 767px) {
    .bb-promo-bar__inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto 44px;
        gap: 4px 8px;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .bb-promo-bar__message {
        grid-column: 1 / 3;
    }

    .bb-promo-bar__coupon {
        grid-column: 1;
        grid-row: 2;
        justify-self: start;
    }

    .bb-promo-bar__timer {
        grid-column: 2;
        grid-row: 2;
        font-size: 13px;
    }

    .bb-promo-bar__coupon[hidden] + .bb-promo-bar__timer {
        grid-column: 1 / 3;
        justify-self: start;
    }

    .bb-promo-bar__close {
        grid-column: 3;
        grid-row: 1 / 3;
        align-self: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bb-promo-bar button {
        transition: none;
    }
}
