.gwarek-alert-bar-wrap {
    position: sticky;
    top: 0;
    z-index: 999999;
    display: grid;
    grid-template-rows: 1fr;
    transition: grid-template-rows 0.35s ease-in-out;
}

/* Stan "schowany przy scrollu w dół" - animacja grid-template-rows
   plynnie zwija wysokosc kontenera do zera. Technika CSS-Grid zamiast
   max-height/transform - bez recznego liczenia wysokosci w JS, bez
   szarpania przy wolnym scrollu czy zatrzymaniu w polowie. */
.gwarek-alert-bar-wrap.gwarek-ab--hidden-scroll {
    grid-template-rows: 0fr;
}

.gwarek-alert-bar-collapse {
    overflow: hidden;
    min-height: 0;
}

.gwarek-alert-bar {
    --gwarek-ab-bg: #1e1e1e;
    --gwarek-ab-color: #ffffff;

    background: var(--gwarek-ab-bg);
    color: var(--gwarek-ab-color);
    box-sizing: border-box;
    width: 100%;
}

.gwarek-alert-bar__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 12px 44px 12px 16px;
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    line-height: 1.5;
}

.gwarek-alert-bar__inner.gwarek-ab--split {
    justify-content: space-between;
}

.gwarek-alert-bar__inner.gwarek-ab--centered {
    justify-content: center;
    text-align: center;
}

.gwarek-alert-bar__content {
    position: relative;
    z-index: 2;
}

.gwarek-ab--split .gwarek-alert-bar__content {
    flex: 1;
}

.gwarek-alert-bar__content p {
    margin: 0;
}

/* Domyslny odstep dolny akapitow z edytora nie jest potrzebny na ostatnim
   akapicie wewnatrz paska. */
.gwarek-alert-bar__content p:last-child {
    padding-bottom: 0 !important;
}

.gwarek-alert-bar__content a {
    color: inherit;
    text-decoration: underline;
}

/* Caly pasek jako link (gdy CTA jest wylaczone, a link ustawiony) -
   przezroczysta nakladka na cale __inner. Tylko kursor pointer,
   bez zmiany opacity dla calego paska. */
.gwarek-alert-bar__linkoverlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    cursor: pointer;
}

.gwarek-alert-bar__cta {
    position: relative;
    z-index: 2;
    display: inline-block;
    flex-shrink: 0;
    padding: 8px 20px;
    border-radius: 4px;
    background: var(--gwarek-ab-cta-bg, #ffffff);
    color: var(--gwarek-ab-cta-color, #1e1e1e);
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
    transition: opacity 0.2s ease;
}

.gwarek-alert-bar__cta:hover,
.gwarek-alert-bar__cta:focus {
    opacity: 0.8;
    color: var(--gwarek-ab-cta-color, #1e1e1e);
}

.gwarek-alert-bar__close {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: transparent;
    border: 0;
    color: var(--gwarek-ab-color);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 10px;
    opacity: 0.85;
}

.gwarek-alert-bar__close:hover {
    opacity: 1;
}
