/* Projects page specific styles */

/* Enhanced smooth scrolling */
.projects-page {
    scroll-padding-top: 100px;
}

/* Projects page layout */
.projects-page {
    padding-top: 5rem;
    min-height: 100vh;
}

.projects-page .container {
    position: relative;
    z-index: 1;
}

.projects-page .container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(168, 139, 250, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

/* Projects page title */
.projects-page-title {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 2.5rem;
    background: linear-gradient(90deg, #e879f9 10%, #f472b6 60%, #a78bfa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Project section wrapper for better separation */
.project-section-wrapper {
    position: relative;
    margin-bottom: 4rem;
}

.project-section-wrapper:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: -2rem;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    max-width: 400px;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, rgba(168, 139, 250, 0.2) 20%, rgba(34, 211, 238, 0.3) 50%, rgba(168, 139, 250, 0.2) 80%, transparent 100%);
    border-radius: 1px;
    opacity: 0.7;
    transition: all 0.3s ease;
}

/* Project section wrapper hover effects removed for better performance */

.project-section-wrapper:not(:last-child)::before {
    content: '';
    position: absolute;
    bottom: -2.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 8px;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.6) 0%, rgba(168, 139, 250, 0.4) 70%, transparent 100%);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(34, 211, 238, 0.3);
    transition: all 0.3s ease;
    animation: pulse-separator 3s ease-in-out infinite;
}

/* Project section wrapper before hover effects removed for better performance */

@keyframes pulse-separator {
    0%, 100% {
        box-shadow: 0 0 10px rgba(34, 211, 238, 0.3);
    }
    50% {
        box-shadow: 0 0 20px rgba(34, 211, 238, 0.6);
    }
}

/* Project detail cards */
.project-detail {
    background: var(--bg-card);
    border-radius: 1.5rem;
    margin-bottom: 0;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: 1px solid var(--glass-border);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(168, 139, 250, 0.1);
    position: relative;
}

/* Project detail hover effects removed for better performance */

.project-detail.expanded {
    transform: translateY(0);
    box-shadow: 0 25px 50px rgba(168, 139, 250, 0.3);
}

.project-detail.transitioning {
    pointer-events: none;
}

/* Project header */
.project-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(34, 211, 238, 0.05) 0%, rgba(168, 139, 250, 0.05) 100%);
}

.project-main-image {
    width: 120px;
    height: 120px;
    border-radius: 1rem;
    object-fit: cover;
    border: 2px solid var(--color-secondary);
    flex-shrink: 0;
}

.project-main-info h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.project-main-info .project-subtitle {
    color: var(--color-text-secondary);
    font-size: 1rem;
    margin-bottom: 1rem;
}

.project-main-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.project-main-tag {
    background: rgba(34, 211, 238, 0.15);
    color: var(--color-secondary);
    padding: 0.3rem 0.8rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Expandable content */
.project-expandable {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-detail.expanded .project-expandable {
    max-height: 2000px;
}

.project-expandable-content {
    padding: 0 2rem 2rem;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.4s ease 0.2s;
}

.project-detail.expanded .project-expandable-content {
    opacity: 1;
    transform: translateY(0);
}

/* Project sections */
.project-section {
    margin-bottom: 2rem;
}

.project-section h3 {
    color: var(--color-primary);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.project-section p {
    color: var(--color-text-secondary);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.project-section ul {
    color: var(--color-text-secondary);
    padding-left: 1.5rem;
}

.project-section li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

/* Technology grid */
.tech-grid, .tech-stack {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.8rem;
    margin-top: 1rem;
}

.tech-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1rem;
    background: rgba(34, 211, 238, 0.1);
    border-radius: 0.8rem;
    color: var(--color-text);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    border: 1px solid transparent;
}

/* Tech item hover effects removed for better performance */

.tech-icon {
    font-size: 1.2rem;
}

/* Node tags */
.node-tag {
    background: rgba(168, 139, 250, 0.15);
    color: var(--color-primary);
    padding: 0.2rem 0.6rem;
    border-radius: 0.4rem;
    font-size: 0.8rem;
    font-family: 'Courier New', monospace;
}

/* Project specific utility classes */
.key-nodes-title {
    margin-top: 1rem;
}

.node-tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.project-steps-list {
    list-style-type: decimal;
    padding-left: 1.5rem;
}

.project-step-item {
    margin-bottom: 1rem;
    padding-left: 0.5rem;
}

.project-step-item:last-child {
    padding-left: 0.5rem;
    margin-bottom: 0;
}

.resumate-links {
    margin: 2rem auto 2rem auto;
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.resumate-link-btn {
    display: inline-flex;
    align-items: center;
    background: var(--glass-bg);
    color: var(--color-secondary);
    text-decoration: none;
    padding: 0.7rem 1.4rem;
    border-radius: 0.7rem;
    transition: all 0.3s ease;
    border: 1.5px solid var(--color-secondary);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    font-weight: 600;
    box-shadow: 0 2px 12px rgba(34,211,238,0.08);
}

/* ResuMate button hover effects removed for better performance */

.dual-character-social-links {
    margin: 2rem auto;
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.dual-character-link-btn {
    display: inline-flex;
    align-items: center;
    background: var(--glass-bg);
    color: var(--color-secondary);
    text-decoration: none;
    padding: 0.7rem 1.4rem;
    border-radius: 0.7rem;
    transition: all 0.3s ease;
    border: 1.5px solid var(--color-secondary);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    font-weight: 600;
    box-shadow: 0 2px 12px rgba(34,211,238,0.08);
}
/* Dual character button hover effects removed for better performance */

.streamlit-logo {
    width: 22px;
    height: 22px;
    margin-right: 0.7rem;
    vertical-align: middle;
}

/* Project insights */
.project-insights ul {
    list-style: none;
    padding: 0;
}

.project-insights li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--color-text-secondary);
}

.project-insights li::before {
    content: '✨';
    position: absolute;
    left: 0;
    top: 0;
    color: var(--color-secondary);
}

/* Project image styling */
.project-image {
    width: 100%;
    max-width: 600px;
    border-radius: 1rem;
    margin-top: 1rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* Expansion indicator */
.expand-indicator {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(34, 211, 238, 0.2);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-secondary);
    transition: all 0.3s ease;
}

.project-detail.expanded .expand-indicator {
    transform: rotate(180deg);
    background: rgba(168, 139, 250, 0.2);
    color: var(--color-primary);
}

/* Back to top button for projects page */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 100;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    background-color: var(--color-secondary);
    color: var(--bg-dark);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(34, 211, 238, 0.3);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(34, 211, 238, 0.2);
}

/* Back to top hover effects removed for better performance */

.back-to-top:active {
    transform: translateY(-1px) scale(1.02);
}

/* Responsive design for projects page */
@media (max-width: 768px) {
    .projects-page-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .project-header {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
        padding: 1.5rem;
    }
    
    .project-main-image {
        width: 100px;
        height: 100px;
    }
    
    .project-main-info h2 {
        font-size: 1.5rem;
    }
    
    .tech-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 0.6rem;
    }
    
    .tech-item {
        padding: 0.6rem 0.8rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .projects-page {
        padding-top: 4rem;
    }
    
    .projects-page-title {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .project-section-wrapper {
        margin-bottom: 3rem;
    }
    
    .project-section-wrapper:not(:last-child)::after {
        width: 90%;
        height: 1px;
    }
    
    .project-section-wrapper:not(:last-child)::before {
        width: 6px;
        height: 6px;
        bottom: -2rem;
    }
    
    .project-header {
        padding: 1rem;
        gap: 1rem;
    }
    
    .project-main-image {
        width: 80px;
        height: 80px;
    }
    
    .project-main-info h2 {
        font-size: 1.2rem;
    }
    
    .project-main-info .project-subtitle {
        font-size: 0.9rem;
    }
    
    .project-expandable-content {
        padding: 0 1rem 1rem;
    }
    
    .tech-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .tech-item {
        padding: 0.5rem;
        font-size: 0.8rem;
    }
    
    .expand-indicator {
        width: 35px;
        height: 35px;
        top: 0.5rem;
        right: 0.5rem;
    }
    
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 15px;
        right: 15px;
    }
}

@media (max-width: 400px) {
    .projects-page-title {
        font-size: 1.2rem;
    }
    
    .project-main-info h2 {
        font-size: 1rem;
    }
    
    .project-section h3 {
        font-size: 1.1rem;
    }
    
    .tech-item {
        font-size: 0.75rem;
    }
}
