/* =========================================================
   PORTFOLIO STABILITY — końcowe poprawki bez wymuszania stylów
   Aktualizacja: 09.05.2026
   Cel: stabilna galeria, mobile scroll, stopka wersji, O mnie
   ========================================================= */

:root{
    --section-spacing-desktop: 120px;
    --section-spacing-mobile: 72px;
    --container-padding: 20px;
    --gallery-main-height: 440px;
    --gallery-main-height-mobile: 320px;
    --premium-radius: 8px;
    --premium-accent: #FFF;
}

html{
    scroll-behavior: smooth;
    scroll-padding-top: 82px;
}

section{
    scroll-margin-top: 82px;
}

img{
    max-width: 100%;
}

/* O mnie — szerokość i równe marginesy jak segment galerii */
#about .container{
    width:100%;
    max-width:none;
    padding-left:0;
    padding-right:0;
}

#about .col-lg-10.col-lg-offset-1{
    float:none;
    width:100%;
    max-width:1280px;
    margin-left:auto;
    margin-right:auto;
    padding-left:0;
    padding-right:0;
}

#about .about-layout{
    display:flex;
    align-items:center;
    width:100%;
    max-width:1280px;
    margin-left:auto;
    margin-right:auto;
    box-sizing:border-box;
    padding:25px;
    gap:25px;
}

#about .about-text-wrap{
    flex:1 1 auto;
    min-width:0;
    box-sizing:border-box;
    padding:0 10px;
    margin:0;
}

#about .about-photo-wrap{
    flex:0 0 360px;
    width:360px;
    max-width:360px;
    box-sizing:border-box;
    padding:0 10px;
    margin:0;
    display:flex;
    justify-content:center;
    align-items:center;
}

#about .text-faded{
    max-width:none;
    width:100%;
    margin:0;
    padding:0;
}

#about .about-photo{
    width:100%;
    max-width:none;
    margin:0;
    display:block;
    border-radius: 8px;
}

/* Galeria — stała wysokość bez skakania layoutu */
.portfolio-gallery,
.portfolio-gallery-section{
    box-sizing: border-box;
}

.portfolio-gallery .gallery-main-row{
    min-height: var(--gallery-main-height);
    display: flex;
    align-items: stretch;
    overflow: hidden;
}

.portfolio-gallery .gallery-image-col,
.portfolio-gallery .gallery-desc-col{
    min-height: var(--gallery-main-height);
    height: var(--gallery-main-height);
    box-sizing: border-box;
}

.portfolio-gallery .gallery-image-col{
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    overflow: hidden;
}

.portfolio-gallery .gallery-main-img{
    width: 100%;
    height: 100%;
    max-height: none;
    object-fit: contain;
    display: block;
    margin: 0 auto;
    border: 0;
    background: transparent;
}

.portfolio-gallery .gallery-desc-col{
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow: hidden;
}

.portfolio-gallery .gallery-title{
    text-align: center;
}

.portfolio-gallery .gallery-desc,
.portfolio-gallery .gallery-extra,
.portfolio-gallery .gallery-desc-col p{
    text-align: justify;
    hyphens: auto;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    overflow-wrap: break-word;
    word-break: normal;
    font-weight: 400;
}

/* Miniatury i strzałki — bez efektów zmieniających układ */
.portfolio-gallery .gallery-thumb,
.portfolio-gallery .gallery-thumb:hover,
.portfolio-gallery .gallery-thumb.active{
    opacity: 1;
    transform: none;
    box-shadow: none;
}

.portfolio-gallery .gallery-thumb{
    border-radius: 8px;
    background: transparent;
}

.portfolio-gallery .gallery-thumb.active{
    border-color: var(--premium-accent);
    border-radius: 8px;
}

.portfolio-gallery .gallery-thumb img{
    border-radius: 8px;
}

.portfolio-gallery .gallery-thumb-arrow{
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: #888888;
    box-shadow: none;
    font-size: 24px;
    line-height: 22px;
    font-weight: 400;
    text-align: center;
    transform: none;
}

.portfolio-gallery .gallery-thumb-arrow:hover,
.portfolio-gallery .gallery-thumb-arrow:focus,
.portfolio-gallery .gallery-thumb-arrow:active{
    background: transparent;
    color: #555555;
    box-shadow: none;
    outline: none;
    transform: none;
}

.portfolio-gallery .gallery-thumb-arrow:disabled{
    opacity: .35;
    background: transparent;
}

/* Stopka — wersja strony */
.site-footer .site-version{
    margin-top: 10px;
    text-align: center;
    font-size: 12px;
    line-height: 1.5;
    letter-spacing: .8px;
    color: rgba(255,255,255,.58);
}

.site-footer .site-version::before{
    content: '';
    display: block;
    width: 44px;
    height: 1px;
    margin: 0 auto 10px auto;
    background: rgba(255,255,255,.16);
}

@media (min-width:1400px){
    #about .col-lg-10.col-lg-offset-1,
    #about .about-layout{
        max-width:1280px;
    }
}

@media (max-width:1320px){
    #about .col-lg-10.col-lg-offset-1,
    #about .about-layout{
        max-width:calc(100% - 40px);
    }
}

@media (max-width: 768px){
    html{
        scroll-padding-top: 68px;
    }

    section{
        scroll-margin-top: 68px;
    }

    #about .about-layout{
        flex-direction:column;
        width:100%;
        max-width:calc(100% - 20px);
        padding:10px;
        gap:10px;
    }

    #about .about-text-wrap,
    #about .about-photo-wrap{
        width:100%;
        max-width:none;
        flex:none;
        padding:0;
        margin:0;
    }

    #about .text-faded{
        padding:0 10px;
        box-sizing:border-box;
    }

    #about .about-photo{
        width:calc(100% - 20px);
        max-width:none;
        margin-left:10px;
        margin-right:10px;
		margin-top:10px;
    }

    .portfolio-gallery .gallery-main-row{
        display: block;
        min-height: auto;
        overflow: visible;
    }

    .portfolio-gallery .gallery-image-col{
        height: var(--gallery-main-height-mobile);
        min-height: var(--gallery-main-height-mobile);
    }

    .portfolio-gallery .gallery-main-img{
        height: var(--gallery-main-height-mobile);
    }

    .portfolio-gallery .gallery-desc-col{
        height: auto;
        min-height: auto;
        overflow: visible;
    }

    .portfolio-gallery,
    .portfolio-gallery-section,
    .gallery-main-row,
    .gallery-image-col,
    .gallery-desc-col{
        border:none;
        outline:none;
        box-shadow:none;
    }

    .gallery-main-row::before,
    .gallery-main-row::after,
    .portfolio-gallery::before,
    .portfolio-gallery::after{
        display:none;
        content:none;
    }

    .site-footer .site-version{
        font-size: 11px;
        letter-spacing: .5px;
    }
}
.portfolio-lightbox[aria-hidden="true"] {
  display: none !important;
}

.portfolio-lightbox[aria-hidden="false"] {
  display: flex !important;
}

/* FORCE PORTFOLIO CARDS RADIUS 8PX */
.portfolio-box,
.portfolio-item,
.portfolio-card,
.portfolio-box img,
.portfolio-item img,
.portfolio-card img,
#portfolio img,
#portfolio .portfolio-box,
#portfolio .portfolio-item,
#portfolio .portfolio-card,
.clients-portfolio img,
.clients-portfolio .portfolio-box,
.clients-portfolio .portfolio-item,
.clients-portfolio .portfolio-card {
    border-radius: 8px !important;
}


/* FORCE THUMBNAILS RADIUS 2PX */
.thumbnail,
.thumbnails img,
.gallery-thumb,
.gallery-thumbnails img,
.thumb,
.thumb img,
.portfolio-thumbnails img,
.portfolio-thumb img,
.swiper-slide img,
.gallery-nav img {
    border-radius: 2px !important;
}


/* FINAL GALLERY THUMB FIX */
.gallery-thumb,
.gallery-thumb img,
.gallery-thumbnails img,
.thumb,
.thumb img,
.swiper-slide,
.swiper-slide img,
.slick-slide img,
.portfolio-gallery-thumb,
.portfolio-gallery-thumb img {
    border-radius: 2px !important;
    overflow: hidden !important;
}

/* thin gray border same as gallery */
.gallery-thumb,
.thumb,
.swiper-slide,
.slick-slide,
.portfolio-gallery-thumb {
    border: 1px solid rgba(120,120,120,0.55) !important;
    box-shadow: none !important;
}

/* remove orange/red border */
.gallery-thumb.active,
.thumb.active,
.swiper-slide-active,
.slick-current,
.slick-active {
    border: 1px solid rgba(120,120,120,0.55) !important;
    box-shadow: none !important;
}


/* portfolio-btn-spacing-fix */
.hero-buttons,
.cta-buttons,
.about-buttons{
display:flex;
gap:24px;
flex-wrap:wrap;
}

@media(max-width:768px){
.hero-buttons,
.cta-buttons,
.about-buttons{
gap:14px;
}
}
