/* Reset & Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #111111;
    color: #ffffff;
    line-height: 1.6;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Header Section */
header {
    padding: 40px 0 20px;
    text-align: center;
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.logo {
    max-height: 80px;
    width: auto;
    object-fit: contain;
}

.tagline {
    font-size: 1.1rem;
    color: #aaaaaa;
    letter-spacing: 0.5px;
}

.social-links {
    display: flex;
    gap: 20px;
    margin-top: 5px;
}

.social-links a {
    color: #ffffff;
    font-size: 1.5rem;
    transition: color 0.2s ease;
}

.social-links a:hover {
    color: #ff5722;
}

/* Navigation Filter Buttons */
.filter-nav {
    margin: 20px 0 40px;
    text-align: center;
}

.filter-nav .container {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.filter-btn {
    background-color: #222222;
    color: #ffffff;
    border: none;
    padding: 10px 24px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.filter-btn:hover {
    background-color: #333333;
}

.filter-btn.active {
    background-color: #ff5722;
    color: #ffffff;
}

/* Gallery Grid */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding-bottom: 60px;
}

.gallery-item {
    background-color: #1a1a1a;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}

.gallery-item:hover {
    transform: translateY(-4px);
}

.gallery-item img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    display: block;
}

.model-card model-viewer {
    width: 100%;
    height: 350px;
    background-color: #1a1a1a;
}

.model-controls {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 2;
}

.topo-btn {
    background-color: rgba(0, 0, 0, 0.7);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.topo-btn:hover {
    background-color: rgba(255, 87, 34, 0.9);
    border-color: #ff5722;
}

.item-info {
    padding: 15px;
    background-color: #1a1a1a;
    text-align: center;
    font-size: 0.95rem;
    color: #cccccc;
    border-top: 1px solid #2a2a2a;
}

/* Lightbox Modal */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    align-items: center;
    justify-content: center;
}

.close {
    position: absolute;
    top: 25px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1010;
    transition: color 0.2s ease;
}

.close:hover {
    color: #ff5722;
}

.lightbox-content-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    max-width: 90%;
    max-height: 90vh;
}

.lightbox-image-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.lightbox-content {
    max-width: 100%;
    max-height: 80vh;
    width: auto;
    height: auto;
    object-fit: contain; /* Prevents image cropping */
    display: block;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

.lightbox-yt-btn {
    background-color: #ff0000;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background-color 0.2s ease;
}

.lightbox-yt-btn:hover {
    background-color: #cc0000;
}

.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1010;
    padding: 10px;
}

.lightbox-arrow img {
    width: 40px;
    height: 40px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
    transition: transform 0.2s ease;
}

.lightbox-arrow:hover img {
    transform: scale(1.1);
}

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

/* Footer */
footer {
    text-align: center;
    padding: 40px 0;
    color: #777777;
    font-size: 0.9rem;
    border-top: 1px solid #1a1a1a;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .gallery {
        grid-template-columns: 1fr;
    }
    
    .lightbox-arrow img {
        width: 30px;
        height: 30px;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
}
