/* Container Principal */
.portfolio-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Mobile: 1 por linha */
    gap: 2rem;
    width: 100%;
}

/* Tablet: 2 colunas */
@media (min-width: 768px) {
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop: 3 colunas */
@media (min-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.portfolio-item {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.portfolio-item:hover {
    transform: translateY(-8px);
    border-color: rgba(0, 242, 255, 0.3);
    box-shadow: 0 20px 40px -15px rgba(0, 242, 255, 0.1);
}

/* Área de Expansão */
#portfolio-details {
    display: none;
    margin-bottom: 5rem;
    width: 100%;
    position: relative;
    z-index: 50;
}

/* Card mais estreito no slide */
.expanded-project-container {
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
}

.nav-arrow-side {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(5, 10, 24, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 242, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    color: #00F2FF;
    pointer-events: auto;
}

.nav-arrow-left {
    left: -40px;
}

.nav-arrow-right {
    right: -40px;
}

/* Responsividade: Dentro do card em telas menores */
@media (max-width: 1300px) {
    .nav-arrow-left {
        left: 20px;
    }

    .nav-arrow-right {
        right: 20px;
    }

    .nav-arrow-side {
        width: 60px;
        height: 60px;
    }
}

.nav-arrow-side:hover {
    background: #00F2FF;
    color: #050A18;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 0 50px rgba(0, 242, 255, 0.6);
}

.nav-arrow-side i {
    font-size: 2.5rem;
}