/* --- Projects Page Specific Styles --- */

/* Note: This file should be loaded after home.css to inherit CSS variables */

/* --- Projects Hero Section --- */
.projects-hero {
    padding: 150px 0 100px;
    text-align: center;
    background: linear-gradient(135deg, rgba(0,0,0,0.3), rgba(0,0,0,0.5));
}

.projects-hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.projects-hero-content .subtitle {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: #888;
    margin-bottom: 20px;
    font-weight: 500;
}

.projects-hero-content h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 30px;
    line-height: 1.2;
    background: linear-gradient(135deg, #fff 0%, #a0a0a0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.projects-hero-content .hero-description {
    font-size: 1.15rem;
    color: #a0a0a0;
    line-height: 1.8;
    max-width: 600px;
    margin: 0 auto;
}

/* --- Filter Bar --- */
.projects-filter-section {
    padding: 40px 0;
    border-bottom: 1px solid var(--border-color);
}

.filter-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 12px 32px;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-color);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 30px;
    font-family: var(--primary-font);
    position: relative;
    overflow: hidden;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: var(--accent-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
    z-index: -1;
}

.filter-btn:hover::before {
    width: 300px;
    height: 300px;
}

.filter-btn:hover {
    color: #111;
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--accent-color);
    color: #111;
    border-color: var(--accent-color);
}

.filter-btn.active::before {
    background: #111;
}

.filter-btn.active:hover {
    color: #fff;
}

/* --- Projects Grid Section --- */
/* Note: These styles are scoped to .projects-grid-section to avoid conflicts with home.css */

.projects-grid-section .projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 60px;
}

/* --- Project Card --- */
.projects-grid-section .project-card {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease, transform 0.4s ease;
    display: flex;
    flex-direction: column;
}

.project-card.hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    height: 0;
    margin: 0;
    overflow: hidden;
}

.project-card-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    height: 100%;
    width: 100%;
}

.project-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 15px;
    margin-bottom: 25px;
    display: block;
    background: var(--card-background);
}

/* Skeleton Loading */
.project-image-wrapper.image-loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(26, 26, 26, 0) 0%,
        rgba(40, 40, 40, 0.6) 50%,
        rgba(26, 26, 26, 0) 100%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    z-index: 1;
    border-radius: 15px;
}

.project-image-wrapper.image-loaded::before {
    opacity: 0;
    pointer-events: none;
    animation: none;
}

@keyframes skeleton-loading {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.project-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
    display: block;
    opacity: 1;
}

.project-image-wrapper img:not(.loaded) {
    opacity: 0;
}

.project-image-wrapper img.loaded {
    opacity: 1;
}

.project-image-wrapper.image-loading {
    background: linear-gradient(135deg, #1a1a1a 0%, #252525 100%);
}

.project-image-wrapper.image-loaded {
    background: transparent;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 60%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.project-card-link:hover .project-image-wrapper img {
    transform: scale(1.05);
}

.project-card-link:hover .project-overlay {
    opacity: 1;
}

.project-content {
    padding: 0 5px;
    position: relative;
    z-index: 1;
    background: transparent;
    display: block;
    width: 100%;
    margin-top: 0;
}

.project-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #888;
    font-weight: 500;
}

.project-year,
.project-category {
    position: relative;
}

.project-category::before {
    content: '•';
    margin-right: 15px;
    color: var(--border-color);
}

.project-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: #e0e0e0;
    line-height: 1.3;
    transition: color 0.3s ease;
    display: block;
}

.project-card-link:hover .project-title {
    color: var(--accent-color);
}

.project-description {
    font-size: 0.95rem;
    color: #a0a0a0;
    line-height: 1.6;
    margin-bottom: 20px;
    display: block;
}

.project-cta {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-color);
    font-weight: 500;
    display: inline-block;
    padding: 12px 28px;
    border: 1px solid var(--accent-color);
    border-radius: 30px;
    background: transparent;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 10px;
}

.project-cta::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: var(--accent-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
    z-index: -1;
}

.project-card-link:hover .project-cta::before {
    width: 300px;
    height: 300px;
}

.project-card-link:hover .project-cta {
    color: #111;
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.2);
}

/* --- Empty State --- */
.projects-empty-state {
    text-align: center;
    padding: 100px 20px;
    color: #888;
    font-size: 1.1rem;
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .projects-grid-section .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }

    .projects-hero-content h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .projects-hero {
        padding: 80px 0 60px;
    }

    .projects-hero-content h1 {
        font-size: 2.5rem;
    }

    .projects-hero-content .hero-description {
        font-size: 1rem;
    }

    .projects-filter-section {
        padding: 30px 0;
        top: 70px;
    }

    .filter-bar {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 10px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 15px;
    }

    .filter-bar::-webkit-scrollbar {
        display: none;
    }

    .filter-btn {
        padding: 10px 24px;
        font-size: 0.8rem;
        white-space: nowrap;
        min-height: 44px;
    }

.projects-grid-section {
    padding: 60px 0;
}

    .projects-grid-section .projects-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        margin-top: 40px;
    }

    .project-image-wrapper {
        margin-bottom: 20px;
        overflow: hidden;
    }

    .project-image-wrapper img {
        transform: scale(1.15);
    }

    .project-image-wrapper img.zoom-more {
        transform: scale(1.3);
    }

    .project-image-wrapper img.show-bottom {
        object-position: center bottom;
    }

    /* Disable hover effects on mobile */
    .project-card-link:hover .project-image-wrapper img {
        transform: scale(1.15);
    }

    .project-card-link:hover .project-image-wrapper img.zoom-more {
        transform: scale(1.3);
    }

    .project-card-link:hover .project-image-wrapper img.show-bottom {
        object-position: center bottom;
    }

    .project-card-link:hover .project-overlay {
        opacity: 0;
    }

    .project-card-link:hover .project-title {
        color: #e0e0e0;
    }

    .project-card-link:hover .project-cta::before {
        width: 0;
        height: 0;
    }

    .project-card-link:hover .project-cta {
        color: var(--accent-color);
        border-color: var(--accent-color);
        transform: translateY(0);
        box-shadow: none;
    }

    .project-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .projects-hero-content h1 {
        font-size: 2rem;
    }

    .filter-btn {
        padding: 8px 20px;
        font-size: 0.75rem;
    }

    .project-title {
        font-size: 1.2rem;
    }
}

