/* Our Project Item — Figma baseline 1440px, vw skaliranje */

/* ===== SEKCIJA ===== */
/* Hero ends at 469px. Title top: 586px → padding-top = 117px */
.project-items-section {
    width: 100%;
    background: #fff;
    padding-top: 8.125vw;    /* 117px @ 1440px */
    padding-bottom: 5.556vw; /* 80px @ 1440px */
}

/* ===== PROJECT ITEM ===== */
.project-item {
    /* elementi imaju vlastiti margin-left */
}

/* ===== NASLOV ===== */
/* Figma: left 22px, width 605px, Inter 400, 46px, line-height 100%, letter-spacing 0 */
.project-item__title {
    margin: 0 0 0 1.528vw;   /* left 22px @ 1440px */
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 3.194vw;      /* 46px @ 1440px */
    line-height: 1;
    letter-spacing: 0;
    color: #000;
}

/* ===== OPIS ===== */
/* Figma: left 22px, width 893px, Open Sans 400, 16px, line-height 24px */
/* Gap od naslova: 667-(586+59) = 22px */
.project-item__desc {
    margin: 1.528vw 0 0 1.528vw; /* top 22px, left 22px @ 1440px */
    max-width: 62.014vw;         /* 893px @ 1440px */
    font-family: 'Open Sans', sans-serif;
    font-weight: 400;
    font-size: 1.111vw;          /* 16px @ 1440px */
    line-height: 1.667vw;        /* 24px @ 1440px */
    letter-spacing: 0;
    color: #000;
}

.project-item__desc p {
    margin: 0;
}

/* ===== GALERIJA ===== */
/* Gap od opisa do slike: 781-(667+52) = 62px */
.project-item__gallery {
    margin-top: 4.306vw;  /* 62px @ 1440px */
    margin-left: 1.528vw; /* 22px @ 1440px */
    width: 96.944vw;      /* 1396px @ 1440px */
}

/* ===== GLAVNA SLIKA ===== */
/* Figma: width 1396px, height 609px, border-radius 4px */
.project-item__main-image {
    width: 100%;
    height: 42.292vw;     /* 609px @ 1440px */
    border-radius: 4px;
    overflow: hidden;
}

.project-main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.15s ease;
}

/* ===== THUMBNAILS ===== */
/* Figma: width 105px, height 57px, gap od glavne slike: 15px */
.project-item__thumbs {
    margin-top: 1.042vw;  /* 15px @ 1440px */
    display: flex;
    flex-wrap: wrap;
    gap: 0.833vw;         /* 12px @ 1440px */
}

.project-thumb {
    width: 7.292vw;       /* 105px @ 1440px */
    height: 3.958vw;      /* 57px @ 1440px */
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.65;
    transition: opacity 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.project-thumb:hover,
.project-thumb.active {
    opacity: 1;
    transform: scale(1.03);
}

.project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===== SEPARATOR ===== */
/* Gap od thumbs do separatora: 1584-(1405+57) = 122px */
/* Gap od separatora do idućeg naslova: 1706-1584 = 122px */
.project-item__sep {
    display: block;
    width: 96.944vw;      /* 1396px @ 1440px */
    margin: 8.472vw 0 8.472vw 1.528vw; /* top 122px, bottom 122px, left 22px */
    border: none;
    border-top: 1px solid #EEEEEE;
}

/* ===== TABLET ( < 1300px ) ===== */
@media (max-width: 1300px) {
    .project-items-section {
        padding-top: 60px;
    }

    .project-item__title {
        font-size: clamp(28px, 3.194vw, 46px);
        margin-left: 5vw;
    }

    .project-item__desc {
        margin-left: 5vw;
        margin-top: 16px;
        max-width: 90%;
        font-size: 16px;
        line-height: 24px;
    }

    .project-item__gallery {
        margin-left: 5vw;
        margin-top: 40px;
        width: 90vw;
    }

    .project-item__main-image {
        height: 50vw;
    }

    .project-thumb {
        width: calc(16.66% - 12px);
        height: auto;
        aspect-ratio: 105 / 57;
    }

    .project-item__sep {
        width: 90vw;
        margin-left: 5vw;
        margin-top: 60px;
        margin-bottom: 60px;
    }
}

/* ===== MOBITEL ( < 768px ) ===== */
@media (max-width: 767px) {
    .project-items-section {
        padding-top: 40px;
        padding-bottom: 40px;
    }

    .project-item__title {
        font-size: 28px;
        margin-left: 20px;
    }

    .project-item__desc {
        margin-left: 20px;
        margin-top: 12px;
        max-width: calc(100% - 40px);
        font-size: 15px;
        line-height: 22px;
    }

    .project-item__gallery {
        margin-left: 20px;
        margin-top: 24px;
        width: calc(100% - 40px);
    }

    .project-item__main-image {
        height: 56vw;
    }

    .project-thumb {
        width: calc(33.33% - 8px);
        height: auto;
        aspect-ratio: 105 / 57;
    }

    .project-item__sep {
        width: calc(100% - 40px);
        margin-left: 20px;
        margin-top: 40px;
        margin-bottom: 40px;
    }
}
