.page {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    position: relative;
}

body {
    gap: 0;
}

.content {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    width: clamp(30rem, 100%, 1500px);
    flex-direction: column;
    font-family: Montserrat;
    color: var(--cloudy-white);
    background-color: var(--translucid-dark);
    padding: 32px;
    padding-bottom: 128px;
    min-height: calc(100svh - 128px);
}

#knowledge-base-header{
    font-weight: 600;
    display: flex;
    justify-content: center;
    align-items: center;
    gap:10px;
    border-bottom: 2px solid var(--slate-steel);
    padding-bottom: 52px;
    width: 100%;
    color:var(--main-green);
}

#knowledge-base-header svg{
    height: 32px;
    width: 32px;
}

#kb-text{
    font-size:18px;
    margin:40px 20px;
}

#kb-text b{
    color:var(--main-green);
    font-weight: 650;
}

.manuals-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

#manuals-container{
    width: 100%;
    display: flex;
    flex-direction: column;
    gap:20px;
}

.content hr{
    width: 100%;
    height: 2px;
    background-color: var(--slate-steel);
    border:none;
}

.manual-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 20px;
    padding:6px 12px 16px 0px;
    background: none;
    text-align: start;
    color: var(--cloudy-white);
    font-family: Montserrat;
    border: none;
    font-size: 20px;
    cursor: var(--custom-pointer);
    border-bottom: 2px dotted var(--slate-steel);
    transition: all 150ms ease-in-out;
}

.opened{
    font-weight: 600;
    font-size:24px;
    border-color:rgb(153, 153, 153);
}

.chevron-icon {
    transition: transform 150ms ease-in-out;
}

.manual-content {
    display: none;
    padding:16px;
}

.manual-content img {
    pointer-events: all !important;
    cursor: var(--custom-pointer);
    transition: outline 150ms ease-in-out;
}

.manual-content p {
    text-align: center;
    padding: 16px 16px 32px 16px;
    margin:0;
    font-size: 16px;
    font-style: italic;
}

.image-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 20vw;
    position: relative;
}

.image-wrapper img {
    width: 80%;
    border-radius: 12px;
}

.lds-ring {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    width: 80%;
    height: 100%;
    border-radius: 12px;
    background-color: var(--deep-steel);
}

.lds-ring div {
    box-sizing: border-box;
    display: block;
    position: absolute;
    width: 32px;
    height: 32px;
    margin: 0px;

    border: 4px solid #dfdfdf;
    border-radius: 50%;

    animation: lds-ring 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    border-color: var(--cloudy-white) transparent transparent transparent;
}

.lds-ring div:nth-child(1) {
    animation-delay: -0.45s;
}

.lds-ring div:nth-child(2) {
    animation-delay: -0.3s;
}

.lds-ring div:nth-child(3) {
    animation-delay: -0.15s;
}

@keyframes lds-ring {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}


.gallery-wrapper {
    display: flex;
    position: relative;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
    width: 100%;
}

.gallery {
    display: flex;
    overflow: hidden;
    width: 100%;
    /* Dostosuj szerokość galerii */
    justify-content: center;
    align-items: center;
    min-height: 30vw;
}

.gallery img {
    display: none;
    width: 80%;
    border-radius: 12px;
}

.gallery-nav,
.gallery-nav-mobile {
    cursor: var(--custom-pointer);
    background: none;
    font-size: 2em;
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 10px;
    border: 1px solid var(--slate-steel);
    background-color: var(--deep-steel);
    border-radius: 6px;
    transition: filter 150ms ease-in-out;
}

.mobile-gallery-nav-wrapper{
    display: flex;
}

.gallery-nav-mobile{
    display: none;
}

.gallery-nav img,
.gallery-nav-mobile img {
    pointer-events: none !important;
}

.gallery-nav:hover {
    filter: brightness(1.2);
}

.gallery-indicator {
    text-align: center;
    margin-top: 10px;
}

.gallery-indicator .dot {
    height: 10px;
    width: 10px;
    margin: 0 5px;
    background: none;
    border: 1px solid var(--slate-steel);
    border-radius: 50%;
    display: inline-block;
    transition: background-color 0.3s ease-in-out;
}

.gallery-indicator .dot.active {
    background-color: var(--main-green);
}






/* The Modal (background) */
.kb-modal {
    margin-top: 64px;
    display: none;
    /* Hidden by default */
    justify-content: center;
    align-items: center;
    position: fixed;
    /* Stay in place */
    flex-direction: column;
    z-index: 1;
    /* Sit on top */
    left: 0;
    top: 0;
    width: 100%;
    /* Full width */
    height: 100%;
    /* Full height */
    overflow: auto;
    /* Enable scroll if needed */
    background-color: rgb(0, 0, 0);
    /* Fallback color */
    background-color: rgba(0, 0, 0, 0.8);
    /* Black w/ opacity */
}

/* Modal Content (Image) */
.kb-modal-content {
    display: block;
    width: 80%;
    border-radius: 12px;
}

/* Caption of Modal Image */
#kbCaption {
    display: block;
    width: 80%;
    text-align: center;
    color: var(--cloudy-white);
    padding: 10px 0;
    font-family: Montserrat;
}

/* The Close Button */
.kb-modal-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
}

.kb-modal-close:hover,
.kb-modal-close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: var(--custom-pointer);
}


@media (max-width: 520px) {
    .content{
        padding:12px 12px 64px 12px;
    }
    #knowledge-base-header{
        font-size: calc(24px + 0.390625vw);
        padding-bottom: 32px;
    }
    #kb-text{
        font-size: calc(12px + 0.390625vw);
    }
    .manuals-wrapper h1{
        font-size: calc(24px + 0.390625vw);
    }
    .manual-content{
        padding:0;
    }
    .image-wrapper img,
    .gallery img{
        width: 100%;
    }
    .lds-ring{
        width: 100%;
    }
    .manual-title{
        font-size: calc(16px + 0.390625vw);
    }
    .manual-content p{
          font-size: calc(10px + 0.390625vw);
          padding:16px 8px;
    }
    .gallery-nav{
        display: none;
    }
    .gallery-wrapper{
        margin:0;
    }
    .gallery-nav-mobile{
        display: flex;
    }
    .kb-modal-content{
        width: 96%;
    }
}