/* Project Detail Page Styles */
body {
    font-family: 'Poppins', sans-serif;
    background-color: #121212;
    color: #ffffff;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.back-nav {
    padding: 1rem;
    background-color: rgba(0, 0, 0, 0.5);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(10px);
}

.back-button {
    color: #15aa29;
    text-decoration: none;
    display: flex;
    align-items: center;
    font-weight: 600;
    transition: all 0.3s ease;
}

.back-button:hover {
    transform: translateX(-5px);
    text-shadow: 0 0 10px rgba(21, 170, 41, 0.7);
}

.project-title {
    margin: 0;
    font-size: 1.5rem;
    color: #ffffff;
    text-align: center;
    flex-grow: 1;
}

.project-container {
    margin-top: 5rem;
    padding: 2rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 992px) {
    .project-container {
        grid-template-columns: 1fr 1fr;
    }
}

/* 3D Model Viewer */
.model-container {
    background-color: rgba(30, 30, 30, 0.7);
    border-radius: 10px;
    overflow: hidden;
    height: 500px;
    position: relative;
    box-shadow: 0 0 20px rgba(21, 170, 41, 0.3);
    border: 1px solid rgba(21, 170, 41, 0.2);
}

.model-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(21, 170, 41, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.model-viewer {
    width: 100%;
    height: 100%;
    border: none;
    background: #1e1e1e;
}

/* Project Info Section */
.project-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-card {
    background-color: rgba(30, 30, 30, 0.7);
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(21, 170, 41, 0.2);
    transition: all 0.3s ease;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(21, 170, 41, 0.3);
}

.info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: #15aa29;
}

.info-card h3 {
    margin-top: 0;
    color: #15aa29;
    font-size: 1.3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

.info-card p {
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

/* Tech Stack Section */
.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.tech-item {
    background-color: rgba(21, 170, 41, 0.15);
    border: 1px solid rgba(21, 170, 41, 0.3);
    border-radius: 20px;
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.tech-item::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #15aa29;
    border-radius: 50%;
}

/* Video Section */
.video-section {
    grid-column: 1 / -1;
    margin-top: 2rem;
}

.video-container {
    background-color: rgba(30, 30, 30, 0.7);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(21, 170, 41, 0.2);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    object-fit: cover;
    background: #000;
}

/* Gallery Section */
.gallery-section {
    grid-column: 1 / -1;
    margin-top: 2rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.gallery-item {
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 16/9;
    position: relative;
    cursor: pointer;
    border: 1px solid rgba(21, 170, 41, 0.2);
    transition: all 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.03);
    box-shadow: 0 0 20px rgba(21, 170, 41, 0.3);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* Futuristic Elements */
.futuristic-border {
    position: relative;
}

.futuristic-border::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid transparent;
    border-radius: 12px;
    background: linear-gradient(135deg, #15aa29, transparent) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask-composite: exclude;
    animation: borderGlow 3s infinite alternate;
    pointer-events: none;
}

@keyframes borderGlow {
    0% {
        box-shadow: 0 0 5px rgba(21, 170, 41, 0.3);
    }
    100% {
        box-shadow: 0 0 15px rgba(21, 170, 41, 0.7);
    }
}

/* Circuit Board Background Animation */
.circuit-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(21, 170, 41, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(21, 170, 41, 0.05) 1px, transparent 1px);
    background-size: 20px 20px;
    pointer-events: none;
    z-index: -1;
}

/* Blinking Indicators */
.indicator {
    display: inline-block;
    width: 10px;
    height: 10px;
    background-color: #15aa29;
    border-radius: 50%;
    margin-left: 10px;
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* Download STL Button */
.download-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 1rem;
    padding: 0.7rem 1.5rem;
    background-color: rgba(21, 170, 41, 0.2);
    color: #ffffff;
    border: 1px solid #15aa29;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    gap: 0.5rem;
}

.download-button:hover {
    background-color: rgba(21, 170, 41, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(21, 170, 41, 0.3);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 1001;
}
