/* Carousel Container */
.project-carousel {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 40px auto;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    font-family: inherit;
}

/* Main Image Viewport */
.carousel-main {
    position: relative;
    width: 100%;
    height: 500px; /* Fixed height for uniformity */
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111;
}

.carousel-main img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: opacity 0.5s ease-in-out;
    opacity: 0;
}

.carousel-main img.fade-in {
    opacity: 1;
}

/* Navigation Arrows */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.4);
    color: white;
    border: none;
    padding: 15px 20px;
    cursor: pointer;
    font-size: 24px;
    border-radius: 50%;
    transition: background 0.3s, transform 0.2s;
    z-index: 10;
}

.carousel-btn:hover {
    background: rgba(241, 210, 4, 0.9); /* Theme yellow */
    transform: translateY(-50%) scale(1.1);
}

.prev-btn { left: 15px; }
.next-btn { right: 15px; }

/* Thumbnails Strip */
.carousel-thumbnails {
    display: flex;
    overflow-x: auto;
    padding: 10px;
    background: #222;
    gap: 10px;
    scrollbar-width: thin;
    scrollbar-color: #f1d204 #333;
}

/* Custom Scrollbar for Webkit */
.carousel-thumbnails::-webkit-scrollbar {
    height: 8px;
}
.carousel-thumbnails::-webkit-scrollbar-track {
    background: #333; 
}
.carousel-thumbnails::-webkit-scrollbar-thumb {
    background: #f1d204; 
    border-radius: 4px;
}

.carousel-thumb {
    height: 80px;
    width: 120px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.3s, transform 0.3s, border 0.3s;
    border: 2px solid transparent;
}

.carousel-thumb:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

.carousel-thumb.active {
    opacity: 1;
    border-color: #f1d204;
}

/* Responsive */
@media (max-width: 768px) {
    .carousel-main { height: 300px; }
    .carousel-btn { padding: 10px 15px; font-size: 18px; }
    .carousel-thumb { height: 60px; width: 90px; }
}
