/* ============================================
   PROJECT.CSS - Projects Page
   Color Palette: #141d2a (dark), #8186d5 (primary), 
                  #F5875D (accent), #6366f1/#8b5cf6 (gradients)
   ============================================ */

:root {
    --project-dark: #141d2a;
    --project-card-bg: #141d2a;
    --project-primary: #8186d5;
    --project-accent: #F5875D;
    --project-gradient-start: #6366f1;
    --project-gradient-end: #8b5cf6;
    --text-color: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.7);
    --project-border: rgba(129, 134, 213, 0.2);
    --container-shadow: 0 25px 60px rgba(0, 0, 0, 0.15);
    --card-hover-transform: translateY(-6px);
}

.projects-container,
.project-details-container {
    padding-bottom: 80px;
    background: #f8f9fc;
}

/* === HERO === */
.parallax-section {
    min-height: 320px;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    color: white;
}

.parallax-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(20, 29, 42, 0.8) 0%, rgba(20, 29, 42, 0.7) 100%);
}

/* === PROJECT CARDS === */
.project-card-link {
    text-decoration: none;
    display: block;
}

.project-card {
    background: var(--project-card-bg);
    border-radius: 20px;
    box-shadow: var(--container-shadow);
    overflow: hidden;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.3s ease;
    position: relative;
    height: 100%;
    min-height: 320px;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--project-border);
}

.project-card:hover {
    transform: var(--card-hover-transform);
    box-shadow: 0 20px 50px rgba(99, 102, 241, 0.2);
    border-color: rgba(129, 134, 213, 0.4);
}

.project-card-header {
    padding: 22px 22px 14px;
    border-bottom: 1px solid rgba(129, 134, 213, 0.15);
}

.project-title {
    color: var(--text-color);
    font-weight: 700;
    font-size: 1.15rem;
    margin-bottom: 10px;
    line-height: 1.4;
}

.project-date {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.project-date i {
    color: var(--project-primary);
}

.project-card-body {
    padding: 18px 22px;
    flex-grow: 1;
}

.project-description {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 0;
}

.project-card-footer {
    padding: 16px 22px 22px;
    border-top: 1px solid rgba(129, 134, 213, 0.15);
}

/* === FILES PREVIEW IN CARDS - ЗАПАЗЕНИ === */
.files-preview {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.file-thumbnail {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    overflow: hidden;
    background: rgba(129, 134, 213, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    border: 1px solid rgba(129, 134, 213, 0.2);
}

.file-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.file-thumbnail .document-icon {
    color: var(--project-primary);
    font-size: 1rem;
}

.file-thumbnail.more-files {
    background: linear-gradient(135deg, var(--project-gradient-start), var(--project-gradient-end));
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border: none;
}

.no-files {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-style: italic;
}

/* === HOVER OVERLAY === */
.project-card-hover {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(99, 102, 241, 0.9));
    padding: 50px 22px 22px;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

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

.view-details {
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
}

.view-details i {
    margin-right: 8px;
}

/* === NO PROJECTS === */
.no-projects {
    background: var(--project-card-bg);
    border-radius: 20px;
    padding: 70px 40px;
    color: var(--text-muted);
    border: 1px solid var(--project-border);
}

.no-projects i {
    color: var(--project-primary);
    opacity: 0.5;
}

.no-projects h4 {
    color: var(--text-color);
    margin-top: 0;
}

/* === RESPONSIVE === */
@media (max-width: 992px) {
    .project-card {
        min-height: 280px;
    }

    .parallax-section {
        background-attachment: scroll;
    }
}

@media (max-width: 768px) {
    .projects-container,
    .project-details-container {
        padding-bottom: 50px;
    }

    .parallax-section {
        min-height: 250px;
    }

    .parallax-section .display-4 {
        font-size: 1.5rem;
        word-break: break-word;
        overflow-wrap: break-word;
    }

    .project-card {
        min-height: auto;
        border-radius: 16px;
    }

    .project-card-hover {
        opacity: 1;
        position: relative;
        background: linear-gradient(135deg, var(--project-gradient-start), var(--project-gradient-end));
        padding: 14px 22px;
    }

    .project-card-header {
        padding: 18px 18px 12px;
    }

    .project-card-body {
        padding: 14px 18px;
    }

    .project-card-footer {
        padding: 14px 18px 18px;
    }
}