/* Projects.css - Clean, modern styles for projects page */
/* Designed for portfolio showcasing computer vision and data science projects */

/* ===== MAIN PROJECTS PAGE LAYOUT ===== */
.projects {
    margin: 0 auto;
    padding: 2rem;
    background-image: url(../assets/images/Background/Background-projects.gif);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    min-height: 100vh;
    position: relative;
}

/* Background overlay for better text readability */
.projects::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.7);
    z-index: 1;
}

.projects > * {
    position: relative;
    z-index: 2;
}

/* ===== HERO SECTION ===== */
.projects-hero {
    text-align: center;
    padding: 8rem 0 4rem;
    color: white;
}

.projects-hero h1 {
    margin-top: 30px;
    font-size: 3.5rem;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: fadeInUp 0.8s ease-out;
    gap: 2rem;
}

.projects-hero p {
    font-size: 1.3rem;
    margin-bottom: 3rem;
    opacity: 0.9;
    font-weight: 300;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

/* ===== PROJECT FILTERS ===== */
.project-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.8rem 1.8rem;
    border: 2px solid rgba(139, 92, 246, 0.3);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 0.9rem;
}

.filter-btn:hover {
    border-color: #8b5cf6;
    background: rgba(139, 92, 246, 0.2);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    border-color: transparent;
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.4);
}

/* ===== PROJECTS GRID LAYOUT ===== */
.projects-grid-section {
    padding: 2rem 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

/* ===== PROJECT CARD STYLES ===== */
.project-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.project-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 25px 50px rgba(139, 92, 246, 0.3);
}

/* Project image with hover effect */
.project-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.4s ease;
    position: relative;
}

.project-card:hover .project-image {
    transform: scale(1.08);
}

/* Project content area */
.project-content {
    padding: 2rem;
}

.project-header {
    display: block;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.2rem;
    gap: 1rem;
    color: whitesmoke;
    font-size: 1.4rem;
    line-height: 1.3;
}

.project-date {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.project-description {
    margin-top:10px;
    color: whitesmoke;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

/* ===== TECHNOLOGY TAGS ===== */
.project-tech {
    flex-wrap: wrap;
    gap: 0.6rem;
    margin: 1.5rem 0;
}

.tech-tag {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    backdrop-filter: blur(1);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: transform 0.2s ease;
    margin: 5px;
    display: inline-flex;
    text-wrap: wrap;
}

.tech-tag:hover {
    transform: scale(1.05);
}

/* ===== PROJECT LINKS ===== */
.project-links {
    display: inline-flex;
    gap: 1rem;
    margin-top: 10px;
    flex-wrap: wrap;
}

.project-link {
    padding: 0.7rem 1.5rem;
    border: 2px solid #8b5cf6;
    color: #8b5cf6;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.project-link:hover {
    background: #8b5cf6;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
}

.project-link.code {
    background: #8b5cf6;
    color: white;
}

.project-link.code:hover {
    background: #7c3aed;
    border-color: #7c3aed;
}

/* ===== CALL TO ACTION SECTION ===== */
.cta-section {
    text-align: center;
    padding: 5rem 0 3rem;
    color: white;
}

.cta-section h2 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.cta-section p {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    text-align: center;
    padding: 1rem 2.5rem;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.4);
}

/* ===== MODAL STYLES ===== */
.project-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal-content {
    background: white;
    max-width: 700px;
    width: 95%;
    max-height: 85vh;
    overflow-y: auto;
    border-radius: 20px;
    padding: 2.5rem;
    position: relative;
    animation: modalSlideIn 0.4s ease;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

.close-modal {
    position: absolute;
    top: 1.2rem;
    right: 1.5rem;
    font-size: 2.2rem;
    cursor: pointer;
    background: none;
    border: none;
    color: #64748b;
    transition: color 0.3s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-modal:hover {
    color: #8b5cf6;
    background: rgba(139, 92, 246, 0.1);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-30px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Reveal animation for scroll-triggered elements */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1024px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .projects {
        padding: 1.5rem;
    }
    
    .projects-hero h1 {
        font-size: 2.8rem;
    }
    
    .projects-hero p {
        font-size: 1.1rem;
    }
    
    .project-filters {
        flex-direction: column;
        align-items: center;
        gap: 0.8rem;
    }
    
    .filter-btn {
        width: 200px;
        text-align: center;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .project-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .project-date {
        align-self: flex-start;
    }
    
    .project-links {
        flex-direction: column;
    }
    
    .cta-section h2 {
        font-size: 2.2rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 200px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .projects {
        padding: 1rem;
    }
    
    .projects-hero {
        padding: 3rem 0 1rem;
    }
    
    .projects-hero h1 {
        font-size: 2.2rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .project-content {
        padding: 1.5rem;
    }
    
    .modal-content {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .cta-section {
        padding: 3rem 0 2rem;
    }
    
    .cta-section h2 {
        font-size: 1.8rem;
    }
}

/* ===== ACCESSIBILITY ===== */
/* Focus styles for keyboard navigation */
.filter-btn:focus,
.project-link:focus,
.btn:focus,
.close-modal:focus {
    outline: 2px solid #8b5cf6;
    outline-offset: 2px;
}