.portfolio-filter-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 45px;
    padding-bottom: 15px;
    gap: 20px;
    flex-wrap: wrap;
    position: relative;
}

/* Main Filters Styling */
#portfolio-filters {
    display: flex;
    gap: 35px;
    margin: 0;
    padding: 0;
    list-style: none;
}

#portfolio-filters li {
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 16px;
    color: #ffffff;
    cursor: pointer;
    position: relative;
}

#portfolio-filters li:hover,
#portfolio-filters li.active {
    color: #a91e22;
    border-bottom: 1px solid #a91e22;
}

/* Custom Dropdown Styling */
.portfolio-sub-wrap {
    min-width: 220px;
    position: absolute;
    right: 0;
}

.custom-dropdown {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 12px 20px;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    user-select: none;
    width: 165px;
}

.custom-dropdown:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.dropdown-selected {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'IBM Plex Sans', sans-serif;
    font-weight: 600;
    font-size: 13px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dropdown-selected i {
    font-size: 10px;
    margin-left: 15px;
    transition: transform 0.3s ease;
}

.custom-dropdown.open i {
    transform: rotate(180deg);
}

.dropdown-list {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 100%;
    background: #1a1a1a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    list-style: none;
    padding: 8px 0;
    margin: 0;
    z-index: 100;
    display: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    max-height: 300px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.dropdown-list li {
    padding: 10px 20px;
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.2s ease;
    text-transform: uppercase;
}

.dropdown-list li:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.dropdown-list li.active {
    color: var(--p-red, #df1f26);
    background: rgba(223, 31, 38, 0.05);
}

/* Responsive Fixes */
@media (max-width: 1024px) {
    .portfolio-filter-container {
        justify-content: flex-start;
    }

    .portfolio-sub-wrap {
        position: relative;
        right: auto;
    }
}

@media (max-width: 768px) {
    .portfolio-filter-container {
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
    }

    #portfolio-filters {
        gap: 20px;
        flex-wrap: wrap;
    }

    .portfolio-sub-wrap {
        width: 100%;
        position: relative;
        right: auto;
    }
}

/* Grid Layout System */
.f-row {
    display: flex;
    margin-left: -15px;
    margin-right: -15px;
    flex-wrap: wrap;
}

.f-col {
    padding: 0 15px;
}

.f-5 .f-col {
    width: 20%;
}

.f-4 .f-col {
    width: 25%;
}

.f-3 .f-col {
    width: 33.33333333%;
}

.f-2 .f-col {
    width: 50%;
}

.f-1 .f-col {
    width: 100%;
}

@media (max-width: 1200px) {
    .f-1200-3 .f-col {
        width: 33.33333333%;
    }
}

@media (max-width: 640px) {
    .f-640-2 .f-col {
        width: 50%;
    }
}

/* Portfolio Work Box / Cards styling */
.work-box {
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 2 / 3 !important;
    position: relative;
    margin-bottom: 20px;
}

.work-box a {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.work-box:hover .work-cont {
    opacity: 1;
    top: 50%;
    visibility: visible;
}

.work-box:hover .work-img::after {
    opacity: 1;
    visibility: visible;
}

.work-cont {
    padding: 20px;
    text-align: center;
    position: absolute;
    top: 70%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    visibility: hidden;
    z-index: 3;
    width: 70%;
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 14px;
    transition: all 0.4s ease-in-out;
    -webkit-transition: all 0.4s ease-in-out;
}

.work-img {
    width: 100%;
    height: 100%;
    position: relative;
}

.work-img img {
    width: 100%;
    height: 100%;
    object-fit: cover !important;
}

.work-img img.botvfx-lazy-img {
    transition: opacity 0.35s ease;
}

.work-img img.botvfx-lazy-img:not(.loaded) {
    opacity: 0;
}

.work-img img.loaded {
    opacity: 1;
}

.work-img::after {
    content: "";
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0;
    background: rgb(0 0 0 / 55%);
    opacity: 0;
    transition: all 0.4s ease-in-out;
    -webkit-transition: all 0.4s ease-in-out;
}

.comm-card-hdn {
    color: #ffffff;
    font-family: "Tanker", sans-serif;
    font-size: 36px;
    line-height: 1.01;
    text-transform: uppercase;
    margin: 0;
}