/*
 * TÜRKONFED Projects Page
 * Progress. Sharp. Brutal.
 */

/* ============================================
   PROJECTS STATS BAR
   ============================================ */

.projects-stats {
    background: var(--color-bg-dark);
    padding: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.projects-stats-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
}

.projects-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 4rem;
    position: relative;
}

.projects-stat::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 60px;
    background: linear-gradient(180deg, transparent, rgba(237, 27, 47, 0.5), transparent);
}

.projects-stat:last-child::after {
    display: none;
}

.projects-stat-value {
    font-family: var(--font-family-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 900;
    color: #fff;
    line-height: 1;
}

.projects-stat-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 0.5rem;
}

/* ============================================
   FEATURED PROJECTS
   ============================================ */

.projects-featured {
    padding: 5rem 0;
    background: var(--color-bg-light);
}

.featured-header {
    margin-bottom: 3rem;
}

.featured-label {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 0.75rem;
}

.featured-title {
    font-family: var(--font-family-heading);
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--color-text-primary);
}

.featured-projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.featured-project-card {
    display: flex;
    flex-direction: column;
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    text-decoration: none;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.featured-project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 4px;
    background: var(--color-accent);
    transition: width 0.3s ease;
}

.featured-project-card:hover::before {
    width: 100%;
}

.featured-project-card:hover {
    border-color: var(--color-accent);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.featured-project-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 1.5rem 0;
}

.featured-project-category {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    padding: 0.35rem 0.75rem;
    background: var(--color-bg-light);
    border: 1px solid var(--color-border);
}

.featured-project-status {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.35rem 0.75rem;
}

.featured-project-status.status-ongoing {
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.featured-project-status.status-completed {
    color: var(--color-accent);
    background: rgba(237, 27, 47, 0.1);
}

.featured-project-body {
    padding: 1.5rem;
    flex: 1;
}

.featured-project-title {
    font-family: var(--font-family-heading);
    font-size: 1.375rem;
    font-weight: 800;
    color: var(--color-text-primary);
    line-height: 1.3;
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.featured-project-card:hover .featured-project-title {
    color: var(--color-accent);
}

.featured-project-summary {
    font-size: 0.9375rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin: 0;
}

.featured-project-progress {
    padding: 0 1.5rem;
    margin-bottom: 1.5rem;
}

.progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.progress-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.progress-value {
    font-family: var(--font-family-heading);
    font-size: 0.875rem;
    font-weight: 800;
    color: var(--color-accent);
}

.progress-bar {
    height: 6px;
    background: var(--color-bg-light);
    position: relative;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--color-accent);
    transition: width 0.6s ease;
}

.featured-project-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    background: var(--color-bg-light);
    border-top: 1px solid var(--color-border);
}

.featured-project-timeline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
}

.featured-project-timeline svg {
    width: 16px;
    height: 16px;
}

.featured-project-partners {
    display: flex;
    gap: 0.5rem;
}

.partner-tag {
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-text-secondary);
    padding: 0.25rem 0.5rem;
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
}

.featured-project-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--color-border);
}

.featured-project-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    transition: all 0.3s ease;
}

.featured-project-link svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

.featured-project-card:hover .featured-project-link {
    color: var(--color-accent);
}

.featured-project-card:hover .featured-project-link svg {
    transform: translateX(4px);
}

/* ============================================
   PROJECTS FILTER
   ============================================ */

.projects-filter {
    background: var(--color-bg-white);
    padding: 2rem 0;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 80px;
    z-index: 50;
}

.filter-wrapper {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.filter-label {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    white-space: nowrap;
}

.filter-tabs {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filter-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    background: transparent;
    border: 1px solid var(--color-border);
    text-decoration: none;
    transition: all 0.3s ease;
}

.filter-tab:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.filter-tab.active {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: #fff;
}

.filter-tab-count {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    background: rgba(0, 0, 0, 0.1);
    color: inherit;
    opacity: 0.7;
}

.filter-tab.active .filter-tab-count {
    background: rgba(255, 255, 255, 0.2);
    opacity: 1;
}

/* ============================================
   PROJECTS GRID
   ============================================ */

.projects-grid-section {
    padding: 4rem 0 6rem;
    background: var(--color-bg-light);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

/* ============================================
   PROJECT CARD
   ============================================ */

.project-card {
    display: flex;
    flex-direction: column;
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    text-decoration: none;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--color-accent);
    transition: width 0.3s ease;
}

.project-card:hover::before {
    width: 100%;
}

.project-card:hover {
    border-color: var(--color-accent);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.project-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.25rem 0;
}

.project-card-category {
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.project-card-status {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.project-card-status.status-ongoing {
    color: #10b981;
}

.project-card-status.status-completed {
    color: var(--color-accent);
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

.project-card-body {
    padding: 1rem 1.25rem;
    flex: 1;
}

.project-card-title {
    font-family: var(--font-family-heading);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--color-text-primary);
    line-height: 1.4;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.project-card:hover .project-card-title {
    color: var(--color-accent);
}

.project-card-summary {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
}

.project-card-progress {
    padding: 0 1.25rem 1rem;
}

.progress-mini-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.35rem;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--color-text-muted);
}

.progress-mini-bar {
    height: 4px;
    background: var(--color-bg-light);
    overflow: hidden;
}

.progress-mini-fill {
    height: 100%;
    background: #10b981;
    transition: width 0.6s ease;
}

.project-card-meta {
    padding: 0 1.25rem 1rem;
}

.project-card-timeline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

.project-card-timeline svg {
    width: 14px;
    height: 14px;
}

.project-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-light);
}

.project-card-partners {
    display: flex;
    gap: 0.35rem;
}

.partner-mini-tag {
    font-size: 0.55rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    padding: 0.2rem 0.4rem;
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
}

.partner-more {
    color: var(--color-accent);
    border-color: rgba(237, 27, 47, 0.2);
    background: rgba(237, 27, 47, 0.05);
}

.project-card-arrow {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--color-border);
    transition: all 0.3s ease;
}

.project-card-arrow svg {
    width: 14px;
    height: 14px;
    color: var(--color-text-muted);
    transition: all 0.3s ease;
}

.project-card:hover .project-card-arrow {
    background: var(--color-accent);
    border-color: var(--color-accent);
}

.project-card:hover .project-card-arrow svg {
    color: #fff;
    transform: translateX(2px);
}

/* ============================================
   PROJECTS CTA
   ============================================ */

.projects-cta {
    padding: 6rem 0;
    background: var(--color-bg-light);
    position: relative;
}

.projects-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--color-accent);
}

.projects-cta-content {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 4rem;
}

.projects-cta-label {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 0.75rem;
}

.projects-cta-title {
    font-family: var(--font-family-heading);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    color: var(--color-text-primary);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.projects-cta-description {
    font-size: 1rem;
    color: var(--color-text-secondary);
    line-height: 1.7;
    max-width: 500px;
    margin: 0;
}

.projects-cta-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.projects-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.projects-cta-btn svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

.projects-cta-btn-primary {
    background: var(--color-accent);
    color: #fff;
}

.projects-cta-btn-primary:hover {
    background: var(--color-accent-dark);
    color: var(--color-text-light);
}

.projects-cta-btn-primary:hover svg {
    transform: translateX(4px);
}

.projects-cta-btn-secondary {
    background: transparent;
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
}

.projects-cta-btn-secondary:hover {
    background: var(--color-bg-white);
    border-color: var(--color-accent);
    color: var(--color-accent);
}

/* ============================================
   CARD ANIMATIONS
   ============================================ */

.project-card {
    opacity: 0;
    transform: translateY(20px);
    animation: cardReveal 0.5s ease forwards;
}

.project-card:nth-child(1) { animation-delay: 0.05s; }
.project-card:nth-child(2) { animation-delay: 0.1s; }
.project-card:nth-child(3) { animation-delay: 0.15s; }
.project-card:nth-child(4) { animation-delay: 0.2s; }
.project-card:nth-child(5) { animation-delay: 0.25s; }
.project-card:nth-child(6) { animation-delay: 0.3s; }
.project-card:nth-child(7) { animation-delay: 0.35s; }
.project-card:nth-child(8) { animation-delay: 0.4s; }

@keyframes cardReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.featured-project-card {
    opacity: 0;
    transform: translateY(20px);
    animation: cardReveal 0.5s ease forwards;
}

.featured-project-card:nth-child(1) { animation-delay: 0.1s; }
.featured-project-card:nth-child(2) { animation-delay: 0.2s; }

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
    .featured-projects-grid {
        grid-template-columns: 1fr;
    }

    .projects-cta-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .projects-cta-description {
        max-width: none;
        margin: 0 auto;
    }

    .projects-cta-actions {
        flex-direction: row;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .projects-stats-grid {
        flex-wrap: wrap;
        justify-content: space-around;
    }

    .projects-stat {
        flex: 1;
        min-width: 120px;
        padding: 1.5rem 1rem;
    }

    .projects-stat::after {
        display: none;
    }

    .filter-wrapper {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .filter-tabs {
        width: 100%;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.5rem;
    }

    .filter-tab {
        flex-shrink: 0;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .projects-cta {
        padding: 4rem 0;
    }

    .projects-cta-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .projects-stat-value {
        font-size: 1.75rem;
    }

    .projects-featured {
        padding: 3rem 0;
    }

    .featured-project-title {
        font-size: 1.125rem;
    }

    .project-card-header {
        padding: 1rem 1rem 0;
    }

    .project-card-body {
        padding: 0.875rem 1rem;
    }

    .project-card-progress {
        padding: 0 1rem 0.875rem;
    }

    .project-card-meta {
        padding: 0 1rem 0.875rem;
    }

    .project-card-footer {
        padding: 0.875rem 1rem;
    }
}

/* ============================================
   REDUCED MOTION
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    .project-card,
    .featured-project-card {
        opacity: 1;
        transform: none;
        animation: none;
    }

    .project-card,
    .featured-project-card,
    .progress-fill,
    .progress-mini-fill,
    .filter-tab {
        transition: none;
    }

    .project-card:hover,
    .featured-project-card:hover {
        transform: none;
    }
}

/* ============================================
   REAL PROJECT CARDS (From JSON Data)
   ============================================ */

.real-project-card {
    background: var(--color-bg-white);
    border-radius: var(--radius-xl);
    overflow: hidden;
    border: 1px solid var(--color-border-light);
    transition: all var(--transition-base);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.real-project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-accent);
}

.real-project-logo {
    padding: var(--space-8);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-white);
    border-bottom: 1px solid var(--color-border-light);
    min-height: 180px;
}

.real-project-logo img {
    max-width: 200px;
    max-height: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform var(--transition-base);
}

.real-project-card:hover .real-project-logo img {
    transform: scale(1.05);
}

.real-project-content {
    padding: var(--space-6);
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    flex: 1;
}

.real-project-title {
    font-size: var(--text-xl);
    font-weight: var(--font-bold);
    color: var(--color-text-primary);
    line-height: var(--leading-snug);
    margin: 0;
}

.real-project-description {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    line-height: var(--leading-relaxed);
    margin: 0;
    flex: 1;
}

.real-project-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    color: var(--color-accent);
    font-weight: var(--font-semibold);
    font-size: var(--text-sm);
    text-decoration: none;
    transition: gap var(--transition-fast);
    margin-top: auto;
}

.real-project-link:hover {
    gap: var(--space-3);
}

.real-project-link svg {
    transition: transform var(--transition-fast);
}

.real-project-link:hover svg {
    transform: translateX(4px);
}

.real-project-social {
    display: flex;
    gap: var(--space-2);
    margin-top: var(--space-2);
    padding-top: var(--space-3);
    border-top: 1px solid var(--color-border-light);
}

.social-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    background: var(--color-bg-light);
    color: var(--color-text-secondary);
    transition: all var(--transition-fast);
}

.social-icon:hover {
    background: var(--color-accent);
    color: var(--color-text-light);
    transform: translateY(-2px);
}

.social-icon svg {
    width: 16px;
    height: 16px;
}

/* Search */
.filter-search {
    position: relative;
    width: 100%;
    max-width: 500px;
}

.filter-search svg {
    position: absolute;
    left: var(--space-4);
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: var(--color-text-muted);
    pointer-events: none;
}

.filter-search-input {
    width: 100%;
    padding: var(--space-3) var(--space-4) var(--space-3) var(--space-12);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-lg);
    font-size: var(--text-base);
    font-family: var(--font-family-body);
    transition: all var(--transition-fast);
}

.filter-search-input:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent-glow);
}

.filter-search-input::placeholder {
    color: var(--color-text-muted);
}

/* No Results */
.no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-16) var(--space-6);
    text-align: center;
}

.no-results svg {
    width: 64px;
    height: 64px;
    color: var(--color-text-muted);
    margin-bottom: var(--space-4);
}

.no-results h3 {
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
    color: var(--color-text-primary);
    margin-bottom: var(--space-2);
}

.no-results p {
    font-size: var(--text-base);
    color: var(--color-text-secondary);
    margin: 0;
}
