/* =============================================================================
   NK Carousel – Public CSS
   WCAG 2.2 AA compliant
   ============================================================================= */

/* Wrapper – dodaje padding boczny na przyciski nawigacji */
.nk-carousel-wrapper {
    position: relative;
    width: 100%;
    padding: 0 48px;
    box-sizing: border-box;
}

/* Viewport – przycina slajdy */
.nk-carousel__viewport {
    overflow: hidden;
    width: 100%;
}

/* Track – rząd slajdów */
.nk-carousel__track {
    display: flex;
    flex-wrap: nowrap;
    list-style: none;
    margin: 0;
    padding: 0;
    transition: transform 0.45s ease;
    will-change: transform;
}

/* Wyłącz animację przy resize (dodawana/usuwana przez JS) */
.nk-carousel__track--no-transition {
    transition: none !important;
}

/* Pojedynczy slajd */
.nk-carousel__slide {
    flex: 0 0 auto;
    padding: 0 12px;
    box-sizing: border-box;
    text-align: center;
}

/* Link wewnątrz slajdu */
.nk-carousel__link {
    display: block;
    text-decoration: none;
    color: inherit;
    outline-offset: 3px;
}

.nk-carousel__link:focus-visible {
    outline: 3px solid #005fcc;
    border-radius: 4px;
}

/* Obrazek / logo */
.nk-carousel__img {
    max-height: 120px;
    width: auto;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
    transition: opacity 0.2s ease;
}

.nk-carousel__link:hover .nk-carousel__img,
.nk-carousel__link:focus .nk-carousel__img {
    opacity: 0.8;
}

/* Tytuł pod obrazkiem */
.nk-carousel__title {
    font-size: 13px;
    color: #444444;
    margin: 8px 0 0;
    text-align: center;
    line-height: 1.4;
    word-break: break-word;
}

/* -----------------------------------------------------------------------
   Przyciski nawigacji
   ----------------------------------------------------------------------- */
.nk-carousel__btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: #333333;
    color: #ffffff;
    border: 2px solid transparent;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    line-height: 1;
    z-index: 10;
    padding: 0;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    /* WCAG: min. rozmiar 44×44px dotykowy obszar */
}

.nk-carousel__btn:hover {
    background: #555555;
}

/* WCAG 2.2 focus-visible */
.nk-carousel__btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px #ffffff, 0 0 0 5px #333333;
}

.nk-carousel__btn--prev {
    left: 0;
}

.nk-carousel__btn--next {
    right: 0;
}

/* Ukryj przyciski gdy nie jest potrzebna nawigacja */
.nk-carousel__btn[disabled] {
    opacity: 0.35;
    cursor: default;
    pointer-events: none;
}

/* -----------------------------------------------------------------------
   Przycisk pauzy (WCAG 2.2 SC 2.2.2)
   ----------------------------------------------------------------------- */
.nk-carousel__pause {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 28px auto 0;
    width: 36px;
    height: 36px;
    padding: 0;
    background: transparent;
    border: 1px solid #aaaaaa;
    border-radius: 0;
    cursor: pointer;
    font-size: 14px;
    color: #555555;
    transition: background 0.2s ease, color 0.2s ease;
    line-height: 1;
}

.nk-carousel__pause:hover {
    background: #f0f0f0;
    color: #222222;
}

.nk-carousel__pause:focus-visible {
    outline: 3px solid #005fcc;
    outline-offset: 2px;
}

/* -----------------------------------------------------------------------
   Responsywność – liczba widocznych slajdów jest sterowana przez JS,
   ale marginesy/padding dostosowujemy tutaj
   ----------------------------------------------------------------------- */
@media (max-width: 575px) {
    .nk-carousel-wrapper {
        padding: 0 40px;
    }

    .nk-carousel__btn {
        width: 34px;
        height: 34px;
        font-size: 16px;
    }

    .nk-carousel__title {
        font-size: 11px;
    }
}

