/* Portfolio Reviews Section - Lightweight & Eye-Catching */
.portfolio-reviews-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 50%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

/* Subtle background pattern - CSS only */
.portfolio-reviews-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(102, 126, 234, 0.02) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(139, 92, 246, 0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.portfolio-reviews-section .container {
    position: relative;
    z-index: 1;
}

/* Header */
.portfolio-header {
    margin-bottom: 50px;
}

.portfolio-title {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 15px 0;
    line-height: 1.2;
}

.portfolio-subtitle {
    color: #64748b;
    font-size: 1.1rem;
    margin: 0;
}

/* Carousel Wrapper - CSS-only horizontal scroll */
.portfolio-carousel-wrapper {
    position: relative;
    margin: 40px 0;
    overflow: hidden;
}

.portfolio-carousel {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 10px 0 30px 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(102, 126, 234, 0.3) transparent;
}

.portfolio-carousel::-webkit-scrollbar {
    height: 8px;
}

.portfolio-carousel::-webkit-scrollbar-track {
    background: transparent;
}

.portfolio-carousel::-webkit-scrollbar-thumb {
    background: rgba(102, 126, 234, 0.3);
    border-radius: 4px;
}

.portfolio-carousel::-webkit-scrollbar-thumb:hover {
    background: rgba(102, 126, 234, 0.5);
}

/* Portfolio Item */
.portfolio-item {
    flex: 0 0 auto;
    width: 100%;
    max-width: 558px;
    scroll-snap-align: start;
    opacity: 0;
    animation: fadeInSlide 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    will-change: transform, opacity;
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.portfolio-link {
    display: block;
    text-decoration: none;
    color: inherit;
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 
        0 4px 6px rgba(15, 23, 42, 0.05),
        0 10px 20px rgba(15, 23, 42, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(226, 232, 240, 0.6);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.portfolio-link:hover {
    transform: translateY(-8px);
    box-shadow: 
        0 8px 12px rgba(15, 23, 42, 0.1),
        0 20px 40px rgba(15, 23, 42, 0.15);
    text-decoration: none;
    color: inherit;
}

/* Image Container */
.portfolio-image-container {
    position: relative;
    width: 100%;
    height: 350px;
    overflow: hidden;
    background: #f1f5f9;
}

.portfolio-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
}

.portfolio-link:hover .portfolio-image-container img {
    transform: scale(1.1);
}

/* Overlay */
.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(15, 23, 42, 0.7) 100%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-link:hover .portfolio-overlay {
    opacity: 1;
}

.read-more {
    color: #ffffff;
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: rgba(102, 126, 234, 0.9);
    border-radius: 25px;
    backdrop-filter: blur(10px);
}

.read-more i {
    font-size: 1.1rem;
}

/* Info Block */
.portfolio-info {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.portfolio-item-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0 0 12px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 3.4em;
}

.portfolio-detail {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

/* Button Block */
.portfolio-button-block {
    margin-top: 40px;
}

.portfolio-button {
    display: inline-block;
    padding: 14px 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
}

.portfolio-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.portfolio-button:hover::before {
    left: 100%;
}

.portfolio-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    color: #ffffff;
    text-decoration: none;
}

/* Empty State */
.portfolio-empty {
    padding: 60px 20px;
    color: #94a3b8;
}

/* Responsive Design */
@media (min-width: 768px) {
    .portfolio-carousel {
        gap: 24px;
    }
    
    .portfolio-item {
        max-width: 480px;
    }
}

@media (min-width: 1024px) {
    .portfolio-item {
        max-width: 558px;
    }
}

@media (max-width: 767px) {
    .portfolio-reviews-section {
        padding: 60px 0;
    }
    
    .portfolio-header {
        margin-bottom: 30px;
    }
    
    .portfolio-title {
        font-size: 1.75rem;
    }
    
    .portfolio-item {
        max-width: 85vw;
    }
    
    .portfolio-image-container {
        height: 280px;
    }
    
    .portfolio-info {
        padding: 20px;
    }
}

/* Performance optimizations */
.portfolio-item,
.portfolio-link,
.portfolio-image-container img {
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transform: translateZ(0);
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    .portfolio-item {
        animation: none;
    }
    
    .portfolio-link,
    .portfolio-image-container img,
    .portfolio-overlay {
        transition: none;
    }
    
    .portfolio-link:hover {
        transform: none;
    }
}




















