/**
 * PORTFOLIO FIX
 * Correção para garantir exibição das imagens dos cards de obras
 */

/* ========================================
   PORTFOLIO ITEM
   ======================================== */

.portfolio-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    background: #f5f5f5;
    min-height: 400px;
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* ========================================
   PORTFOLIO IMAGE - FORÇAR EXIBIÇÃO
   ======================================== */

.portfolio-image {
    position: relative !important;
    width: 100% !important;
    height: 400px !important;
    overflow: hidden !important;
    display: block !important;
    background: #e0e0e0 !important;
}

.portfolio-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    transition: transform 0.3s ease !important;
    background: #f5f5f5;
}

.portfolio-item:hover .portfolio-image img {
    transform: scale(1.1);
}

/* ========================================
   OVERLAY
   ======================================== */

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg, 
        rgba(30, 136, 229, 0.9) 0%, 
        rgba(255, 152, 0, 0.9) 100%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    pointer-events: none;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
    pointer-events: auto;
}

/* ========================================
   CONTENT
   ======================================== */

.portfolio-content {
    text-align: center;
    color: white;
    padding: 30px;
    transform: translateY(30px);
    transition: transform 0.3s ease;
}

.portfolio-item:hover .portfolio-content {
    transform: translateY(0);
}

.portfolio-content h4 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: white;
}

.portfolio-content h5 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: white;
}

.portfolio-content p {
    font-size: 1rem;
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.9);
}

/* ========================================
   TAGS
   ======================================== */

.portfolio-tags {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.portfolio-tags .tag {
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(5px);
}

/* ========================================
   CTA BUTTON
   ======================================== */

.portfolio-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.2);
    padding: 12px 30px;
    border-radius: 50px;
    color: white;
    font-weight: 600;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.portfolio-item:hover .portfolio-cta {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* ========================================
   SWIPER NAVIGATION
   ======================================== */

.swiper-button-next,
.swiper-button-prev {
    color: #1E88E5 !important;
    background: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 20px !important;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: #1E88E5;
    color: white !important;
}

.swiper-pagination-bullet {
    background: #1E88E5 !important;
    opacity: 0.3;
}

.swiper-pagination-bullet-active {
    opacity: 1 !important;
}

/* ========================================
   RESPONSIVIDADE
   ======================================== */

@media (max-width: 768px) {
    .portfolio-image {
        height: 300px !important;
    }
    
    .portfolio-content h4 {
        font-size: 1.2rem;
    }
    
    .portfolio-content h5 {
        font-size: 1.1rem;
    }
    
    .portfolio-content p {
        font-size: 0.9rem;
    }
    
    .swiper-button-next,
    .swiper-button-prev {
        width: 40px;
        height: 40px;
    }
    
    .swiper-button-next:after,
    .swiper-button-prev:after {
        font-size: 16px !important;
    }
}

@media (max-width: 576px) {
    .portfolio-image {
        height: 250px !important;
    }
    
    .portfolio-content {
        padding: 20px;
    }
    
    .portfolio-content h4 {
        font-size: 1.1rem;
    }
    
    .portfolio-content h5 {
        font-size: 1rem;
    }
    
    .portfolio-tags .tag {
        font-size: 0.75rem;
        padding: 4px 12px;
    }
}

/* ========================================
   LOADING STATE
   ======================================== */

.portfolio-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        #f0f0f0 25%,
        #e0e0e0 50%,
        #f0f0f0 75%
    );
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    z-index: 1;
}

.portfolio-image img[src] ~ ::before {
    display: none;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* ========================================
   IMAGE LOADED STATE
   ======================================== */

.portfolio-image.loaded::before {
    display: none;
}

.portfolio-image img.loaded {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

