/* Gallery Specific Styles */
.gallery-filter {
    margin-bottom: 40px;
}

.filter-btn {
    padding: 10px 25px;
    border-radius: 50px;
    border: 2px solid var(--primary-color);
    background: transparent;
    color: var(--primary-color);
    font-weight: 600;
    transition: all 0.3s ease;
    margin: 5px;
}

.filter-btn.active, .filter-btn:hover {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 4px 15px rgba(var(--primary-color-rgb), 0.3);
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    cursor: pointer;
    height: 250px;
    /* Fix untuk clipping sudut di beberapa browser */
    -webkit-mask-image: -webkit-radial-gradient(white, black);
    mask-image: radial-gradient(white, black);
}

.gallery-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    transition: transform 0.6s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 20px;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-info h5 {
    color: white;
    margin-bottom: 5px;
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
}

.gallery-info p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    margin-bottom: 0;
}

.gallery-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 1.5rem;
    opacity: 0;
    transition: all 0.3s ease 0.1s;
}

.gallery-item:hover .gallery-icon {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(var(--danger-color-rgb), 0.9);
    color: white;
    padding: 5px 14px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    z-index: 2;
}

.gallery-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 5px 14px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 500;
    z-index: 5;
    transition: all 0.3s ease;
}

.gallery-badge a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.2s;
}

.gallery-badge a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.gallery-badge i {
    font-size: 0.8rem;
}

.gallery-item:hover .gallery-badge {
    background: rgba(0, 0, 0, 0.5);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Animation for filtering */
.gallery-item.hide {
    display: none;
}

.gallery-item.show {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}