/* ========================================================================= */
/* 1. WRAPPER & GRID LAYOUT
/* ========================================================================= */

.efg-wrapper {
    width: 100%;
}

.efg-wrapper::after {
    content: '';
    display: block;
    clear: both;
}

.efg-grid {
    margin: 0 -10px;
}

.efg-grid-item {
    float: left;
    padding: 10px;
    box-sizing: border-box;
}

.elementor-grid-1 .efg-grid-item { width: 100%; }
.elementor-grid-2 .efg-grid-item { width: 50%; }
.elementor-grid-3 .efg-grid-item { width: 33.333%; }
.elementor-grid-4 .efg-grid-item { width: 25%; }
.elementor-grid-5 .efg-grid-item { width: 20%; }
.elementor-grid-6 .efg-grid-item { width: 16.666%; }

@media (max-width: 1024px) {
    .elementor-grid-tablet-1 .efg-grid-item { width: 100%; }
    .elementor-grid-tablet-2 .efg-grid-item { width: 50%; }
    .elementor-grid-tablet-3 .efg-grid-item { width: 33.333%; }
    .elementor-grid-tablet-4 .efg-grid-item { width: 25%; }
}

@media (max-width: 767px) {
    .elementor-grid-mobile-1 .efg-grid-item { width: 100%; }
    .elementor-grid-mobile-2 .efg-grid-item { width: 50%; }
    .elementor-grid-mobile-3 .efg-grid-item { width: 33.333%; }
}

.efg-grid:after {
    content: '';
    display: block;
    clear: both;
}

/* ========================================================================= */
/* 2. FILTER BAR
/* ========================================================================= */

.efg-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.efg-filter-btn {
    padding: 8px 20px;
    border: 1px solid #ddd;
    background-color: #f9f9f9;
    color: #555;
    cursor: pointer;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.efg-filter-btn:hover {
    background-color: #eee;
    color: #111;
}

.efg-filter-btn.is-active {
    background-color: var(--eyelit-color-primary);
    color: #fff;
    border-color: var(--eyelit-color-primary);
}

/* ========================================================================= */
/* 3. ITEM STYLES & OVERLAY
/* ========================================================================= */

.efg-grid-item.isotope-hidden {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.efg-item-inner {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    height: 100%;
}

.efg-item-inner img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Mode "Cover"  */
.efg-image-fit-cover .efg-item-inner {
    aspect-ratio: 1/1; 
}
.efg-image-fit-cover .efg-item-inner img {
    height: 100%;
    object-fit: cover;
}

.efg-item-inner:hover img {
    transform: scale(1.1);
}

.efg-item-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: flex-end;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.efg-item-inner:hover .efg-item-overlay {
    opacity: 1;
}

.efg-item-content {
    transform: translateY(20px);
    transition: transform 0.4s ease;
    color: #fff;
}

.efg-item-inner:hover .efg-item-content {
    transform: translateY(0);
}

.efg-item-title {
    margin: 0 0 5px;
    font-size: 1.2rem;
    font-weight: normal;
    color: #fff;
}

.efg-item-subtitle {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.8;
    color: #fff;
}

/* ========================================================================= */
/* 4. LOAD MORE & UTILITY
/* ========================================================================= */

.efg-load-more-wrapper {
    text-align: center;
    margin-top: 40px;
}

.efg-grid-item.is-hidden {
    display: none;
}